|
|
@@ -2,6 +2,10 @@
|
|
|
<template>
|
|
|
<div class="app-goods-detail-order">
|
|
|
<app-table class="sell" :data="sellList" v-model:columns="sellColumns" >
|
|
|
+ <!-- 价格 -->
|
|
|
+ <template #orderprice="{ row }">
|
|
|
+ <span>{{ row.pricemode === 3 ? estimateprice(row) : row.orderprice }}</span>
|
|
|
+ </template>
|
|
|
<!-- 操作 -->
|
|
|
<template #operate="{ row }">
|
|
|
<el-button type="primary" size="small" :disabled="isDisable(row)"
|
|
|
@@ -9,6 +13,10 @@
|
|
|
</template>
|
|
|
</app-table>
|
|
|
<app-table class="buy" :data="buyList" v-model:columns="buyColumns">
|
|
|
+ <!-- 价格 -->
|
|
|
+ <template #orderprice="{ row }">
|
|
|
+ <span>{{ row.pricemode === 3 ? estimateprice(row) : row.orderprice }}</span>
|
|
|
+ </template>
|
|
|
<!-- 操作 -->
|
|
|
<template #operate="{ row }">
|
|
|
<el-button type="primary" size="small" :disabled="isDisable(row)" @click="onDelisting(row)">{{
|
|
|
@@ -30,6 +38,7 @@ import {useFuturesStore } from '@/stores'
|
|
|
import AppTable from '@pc/components/base/table/index.vue'
|
|
|
import eventBus from '@/services/bus'
|
|
|
import { getUserId } from '@/services/methods/user'
|
|
|
+import { formatDecimal } from '@/filters'
|
|
|
|
|
|
const selectedRow = shallowRef<Model.TjmdTradeOrderDetailRsp>()
|
|
|
|
|
|
@@ -51,6 +60,12 @@ const componentMap = new Map<string, unknown>([
|
|
|
|
|
|
const futuresStore = useFuturesStore()
|
|
|
const quote = futuresStore.getGoodsQuote(props.quoteGoods?.refgoodsid ?? 0)
|
|
|
+/// 估算价格
|
|
|
+const estimateprice = (row: Model.TjmdTradeOrderDetailRsp) => {
|
|
|
+ const decimalplace = (props.quoteGoods?.decimalplace ?? 2.0)
|
|
|
+ return formatDecimal((row.marketmaxsub+(quote.value?.last ?? 0.0)), decimalplace)
|
|
|
+}
|
|
|
+
|
|
|
/// 查询用户掉期协议签署表
|
|
|
const { dataList: protocolList } = useRequest(queryMdUserSwapProtocol, {
|
|
|
params: {
|