| | |
| | | return post("/user/sell.do", options); |
| | | } |
| | | |
| | | // 用户一键平仓 |
| | | export function allsell(options) { |
| | | return post("/user/allsell.do", options); |
| | | } |
| | | |
| | | // ***用户中心***/ |
| | | // 用户详情 |
| | | export function getUserInfo(options) { |
| | |
| | | </div> |
| | | |
| | | <div class="order_list" v-if="activeName == '0'"> |
| | | <el-button type="primary" style="margin-left: 16px;" @click="CloseAll">{{ $t("一鍵平倉") }}</el-button> |
| | | <el-table height="100%" :data="tableData" style="width: 100%" size="small" empty-text="No Data" |
| | | @row-click="Choice"> |
| | | <el-table-column prop="stockSpell" :label="$t('hj313')"> |
| | |
| | | times = null; |
| | | } |
| | | }, |
| | | // 一键平仓 |
| | | async CloseAll() { |
| | | const res = await api.allsell(); |
| | | if (res.status === 0) { |
| | | this.$message.success(res.msg); |
| | | } else { |
| | | this.$message.error(res.msg); |
| | | } |
| | | } |
| | | }, |
| | | }; |
| | | </script> |
| | |
| | | <div slot="prefix" class="inp_prefix flex-center">{{ $t("sp") }}</div> |
| | | </el-input> |
| | | |
| | | <el-input v-model="sform.num" style="text-align: end" oninput="value=value.replace(/[^\d.]/g,'')" disabled> |
| | | <el-input v-model="sform.num" style="text-align: end" oninput="value=value.replace(/[^\d.]/g,'')"> |
| | | <div slot="prefix" class="inp_prefix flex-center">{{ $t("sl") }}</div> |
| | | </el-input> |
| | | |
| | |
| | | </div> |
| | | |
| | | <div class="submit_btns"> |
| | | <!-- <div class="bt bt2 flex-center" @click="sell()">{{ $t("hj121") }}</div> --> |
| | | <div class="bt bt2 flex-center" @click="sell()">{{ $t("一鍵平倉") }}</div> |
| | | <div class="bt bt2 flex-center" @click="sell()">{{ $t("hj121") }}</div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | |
| | | let data = await api.findByPostionSn(res); |
| | | if (data.status === 0) { |
| | | this.pages = data.data; |
| | | this.sform.num = data.data.orderNum |
| | | } |
| | | }, |
| | | // 平仓 |