li.shaoyi 1 年間 前
コミット
5dd8ce5d24

+ 2 - 2
oem/thj/config/appconfig.json

@@ -1,8 +1,8 @@
 {
   "appId": "com.muchinfo.thj",
   "appName": "铁合金掌上行",
-  "version": "1.0.2",
-  "versionCode": "100002",
+  "version": "1.0.3",
+  "versionCode": "100003",
   "apiUrl": "http://192.168.31.167:8080/cfg?key=test_167",
   "tradeChannel": "ws",
   "modules": [

+ 1 - 1
public/config/appconfig.json

@@ -1,6 +1,6 @@
 {
   "appId": "com.muchinfo.app",
-  "appName": "多元世纪",
+  "appName": "多元世纪交易中心",
   "appTitle": "多元世纪交易中心",
   "version": "1.0.5",
   "versionCode": "10005",

+ 315 - 0
public/config/columns.json

@@ -129,5 +129,320 @@
                 "label": "仓单编号"
             }
         ]
+    },
+    {
+        "tableKey": "spot-order",
+        "columns": [
+            {
+                "field": "wrtradetype",
+                "label": "挂牌类型"
+            },
+            {
+                "field": "deliverygoodsname",
+                "label": "品种"
+            },
+            {
+                "field": "wrstandardname",
+                "label": "商品名称"
+            },
+            {
+                "field": "wrpricetype",
+                "label": "挂牌方式"
+            },
+            {
+                "field": "fixedprice",
+                "label": "价格"
+            },
+            {
+                "field": "orderqty",
+                "label": "挂牌数量"
+            },
+            {
+                "field": "tradeqty",
+                "label": "成交数量"
+            },
+            {
+                "field": "warehousename",
+                "label": "仓库"
+            },
+            {
+                "field": "ordertime",
+                "label": "挂牌时间"
+            },
+            {
+                "field": "wrtradeorderid",
+                "label": "挂牌单号"
+            }
+        ]
+    },
+    {
+        "tableKey": "spot-trade",
+        "columns": [
+            {
+                "field": "wrtradetype",
+                "label": "挂牌类型"
+            },
+            {
+                "field": "deliverygoodsname",
+                "label": "品种"
+            },
+            {
+                "field": "wrstandardname",
+                "label": "商品名称"
+            },
+            {
+                "field": "tradeprice",
+                "label": "成交价格"
+            },
+            {
+                "field": "tradeqty",
+                "label": "成交数量"
+            },
+            {
+                "field": "tradeamount",
+                "label": "成交金额"
+            },
+            {
+                "field": "chargevalue",
+                "label": "手续费"
+            },
+            {
+                "field": "matchusername",
+                "label": "对手方"
+            },
+            {
+                "field": "tradetime",
+                "label": "成交时间"
+            },
+            {
+                "field": "wrtradedetailid",
+                "label": "成交单号"
+            }
+        ]
+    },
+    {
+        "tableKey": "swap-order",
+        "columns": [
+            {
+                "field": "goodsname",
+                "label": "商品代码/名称"
+            },
+            {
+                "field": "buyorsell",
+                "label": "方向"
+            },
+            {
+                "field": "orderqty",
+                "label": "委托数量"
+            },
+            {
+                "field": "orderprice",
+                "label": "委托价格"
+            },
+            {
+                "field": "tradeqty",
+                "label": "成交数量"
+            },
+            {
+                "field": "orderstatus",
+                "label": "委托状态"
+            },
+            {
+                "field": "ordertime",
+                "label": "委托时间"
+            },
+            {
+                "field": "orderid",
+                "label": "委托单号"
+            }
+        ]
+    },
+    {
+        "tableKey": "swap-trade",
+        "columns": [
+            {
+                "field": "goodsname",
+                "label": "商品代码/名称"
+            },
+            {
+                "field": "buildtype",
+                "label": "类型"
+            },
+            {
+                "field": "buyorsell",
+                "label": "方向"
+            },
+            {
+                "field": "tradeprice",
+                "label": "成交价格"
+            },
+            {
+                "field": "tradeqty",
+                "label": "成交数量"
+            },
+            {
+                "field": "tradeamount",
+                "label": "成交金额"
+            },
+            {
+                "field": "closepl",
+                "label": "平仓盈亏"
+            },
+            {
+                "field": "charge",
+                "label": "手续费"
+            },
+            {
+                "field": "tradetime",
+                "label": "成交时间"
+            },
+            {
+                "field": "tradeid",
+                "label": "成交单号"
+            }
+        ]
+    },
+    {
+        "tableKey": "capital-inout",
+        "columns": [
+            {
+                "field": "amount",
+                "label": "金额"
+            },
+            {
+                "field": "executetype",
+                "label": "申请类型"
+            },
+            {
+                "field": "accountname",
+                "label": "姓名"
+            },
+            {
+                "field": "accountcode",
+                "label": "资金账号"
+            },
+            {
+                "field": "bankname",
+                "label": "开户行"
+            },
+            {
+                "field": "bankaccountno",
+                "label": "卡号"
+            },
+            {
+                "field": "charge",
+                "label": "手续费"
+            },
+            {
+                "field": "applystatus",
+                "label": "状态"
+            },
+            {
+                "field": "updatetime",
+                "label": "申请时间"
+            },
+            {
+                "field": "extoperateid",
+                "label": "流水号"
+            },
+            {
+                "field": "remark2",
+                "label": "备注"
+            }
+        ]
+    },
+    {
+        "tableKey": "query-spot-order",
+        "columns": [
+            {
+                "field": "wrtradetype",
+                "label": "挂牌类型"
+            },
+            {
+                "field": "deliverygoodsname",
+                "label": "品种"
+            },
+            {
+                "field": "wrstandardname",
+                "label": "商品名称"
+            },
+            {
+                "field": "wrpricetype",
+                "label": "挂牌方式"
+            },
+            {
+                "field": "wrtypename",
+                "label": "期货合约"
+            },
+            {
+                "field": "fixedprice",
+                "label": "价格/基差"
+            },
+            {
+                "field": "orderqty",
+                "label": "挂牌数量"
+            },
+            {
+                "field": "tradeqty",
+                "label": "成交数量"
+            },
+            {
+                "field": "warehousename",
+                "label": "仓库"
+            },
+            {
+                "field": "ordertime",
+                "label": "挂牌时间"
+            },
+            {
+                "field": "wrtradeorderid",
+                "label": "挂牌单号"
+            },
+            {
+                "field": "wrtradeorderstatus",
+                "label": "状态"
+            }
+        ]
+    },
+    {
+        "tableKey": "query-spot-trade",
+        "columns": [
+            {
+                "field": "buyorsell",
+                "label": "挂牌类型"
+            },
+            {
+                "field": "deliverygoodsname",
+                "label": "品种"
+            },
+            {
+                "field": "wrstandardname",
+                "label": "商品名称"
+            },
+            {
+                "field": "tradeprice",
+                "label": "成交价格"
+            },
+            {
+                "field": "tradeqty",
+                "label": "成交数量"
+            },
+            {
+                "field": "matchusername",
+                "label": "对手方"
+            },
+            {
+                "field": "warehousename",
+                "label": "仓库"
+            },
+            {
+                "field": "tradetime",
+                "label": "成交时间"
+            },
+            {
+                "field": "wrtradedetailid",
+                "label": "成交单号"
+            }
+        ]
     }
 ]

+ 1 - 1
src/packages/mobile/views/order/position/components/swap/close/Index.vue

@@ -52,7 +52,7 @@
                             </ul>
                         </div>
                         <div class="g-order-list__btnbar">
-                            <Button size="small" v-if="useStore.userType === 5" @click="onCloseSubmit(item)"
+                            <Button size="small" v-if="useStore.userType === 5 && [1, 3].includes(quote?.goodstradetype ?? 0)" @click="onCloseSubmit(item)"
                                 round>平仓</Button>
                         </div>
                     </div>

+ 8 - 14
src/packages/pc/views/footer/capital/inoutapply/index.vue

@@ -19,24 +19,18 @@
 <script lang="ts" setup>
 import { shallowRef } from 'vue'
 import { formatDate } from '@/filters'
+import { getInOutApplyStatusName, getInOutExecuteTypeName } from '@/constants/order'
 import { useRequest } from '@/hooks/request'
 import { queryAccountInOutApply } from '@/services/api/bank'
+import { useTableColumnsStore } from '@/stores'
 import AppTable from '@pc/components/base/table/index.vue'
-import { getInOutApplyStatusName, getInOutExecuteTypeName } from '@/constants/order'
+
+const { getTableColumns } = useTableColumnsStore()
+const tableColumns = shallowRef<Model.TableColumn[]>([])
 
 const { loading, dataList } = useRequest(queryAccountInOutApply, {})
 
-const tableColumns = shallowRef<Model.TableColumn[]>([
-    { field: 'extoperateid', label: '流水号' },
-    { field: 'amount', label: '金额' },
-    { field: 'executetype', label: '申请类型' },
-    { field: 'applystatus', label: '状态' },
-    { field: 'accountname', label: '姓名' },
-    { field: 'accountcode', label: '资金账号' },
-    { field: 'bankname', label: '开户银行' },
-    { field: 'bankaccountno', label: '卡号' },
-    { field: 'charge', label: '手续费' },
-    { field: 'updatetime', label: '申请时间' },
-    { field: 'remark2', label: '备注' }
-])
+getTableColumns('capital-inout').then((res) => {
+    tableColumns.value = res
+})
 </script>

+ 1 - 1
src/packages/pc/views/footer/presell/transferorder/index.vue

@@ -5,7 +5,7 @@
         :expand-row-keys="expandKeys" @row-click="rowClick">
         <!-- 商品代码/名称 -->
         <template #goodsname="{ row }">
-            {{ row.goodscode }}/{{ row.goodsname }}
+            {{ row.goodsname }}/{{ row.goodscode }}
         </template>
         <!-- 商品代码/名称 -->
 

+ 13 - 18
src/packages/pc/views/footer/presell/transferposition/index.vue

@@ -2,6 +2,10 @@
 <template>
     <app-table :data="dataList" v-model:columns="tableColumns" :loading="loading" :row-key="rowKey"
         :expand-row-keys="expandKeys" @row-click="rowClick">
+        <!-- 商品代码/名称-->
+        <template #goodscode="{ row }">
+            {{ row.goodsname }}/{{ row.goodscode }}
+        </template>
         <!-- 可用数量-->
         <template #enableqty="{ row }">
             {{ row.buycurpositionqty - row.buyfrozenqty }}
@@ -37,13 +41,14 @@
 </template>
 
 <script lang="ts" setup>
-import { ref, defineAsyncComponent } from 'vue'
+import { shallowRef, defineAsyncComponent } from 'vue'
 import { parsePercent, formatDecimal } from '@/filters'
 import { useRequest } from '@/hooks/request'
 import { queryMineTradePositionExs } from '@/services/api/transfer'
 import { getPayStatusName, PayStatus } from '@/constants/order'
 import { useComponent } from '@/hooks/component'
 import { useComposeTable } from '@pc/components/base/table'
+import { useTableColumnsStore } from '@/stores'
 import AppTable from '@pc/components/base/table/index.vue'
 
 const componentMap = new Map<string, unknown>([
@@ -52,6 +57,9 @@ const componentMap = new Map<string, unknown>([
     ['listing', defineAsyncComponent(() => import('./listing/index.vue'))], // 转让
 ])
 
+const { getTableColumns } = useTableColumnsStore()
+const tableColumns = shallowRef<Model.TableColumn[]>([])
+
 const { loading, dataList, run } = useRequest(queryMineTradePositionExs, {})
 
 const { componentRef, componentId, openComponent, closeComponent } = useComponent(() => {
@@ -60,25 +68,12 @@ const { componentRef, componentId, openComponent, closeComponent } = useComponen
 
 const { selectedRow, rowKey, expandKeys, rowClick } = useComposeTable<Model.MineTradePositionExsRsp>({ rowKey: 'goodsid' })
 
-const tableColumns = ref<Model.TableColumn[]>([
-    { field: 'goodscode', label: '代码' },
-    { field: 'goodsname', label: '名称' },
-    { field: 'buycurholderamount', label: '持仓金额' },
-    { field: 'buycurpositionqty', label: '持仓量' },
-    { field: 'buyfrozenqty', label: '冻结量' },
-    { field: 'enableqty', label: '可用量' },
-    { field: 'sellname', label: '发售方' },
-    { field: 'presaleprice', label: '订货价' },
-    { field: 'totalamount', label: '总货款' },
-    { field: 'transferdepositratio', label: '转让订金比例' },
-    { field: 'transferdeposit', label: '转让订金' },
-    { field: 'depositremain', label: '未付订金' },
-    { field: 'paystatus', label: '支付状态' },
-    { field: 'lasttradedate', label: '最后交易日' }
-])
-
 const showComponent = (componentName: string, row?: Model.MineTradePositionExsRsp) => {
     selectedRow.value = row
     openComponent(componentName)
 }
+
+getTableColumns('transfer-position').then((res) => {
+    tableColumns.value = res
+})
 </script>

+ 7 - 15
src/packages/pc/views/footer/spot/order/index.vue

@@ -40,12 +40,16 @@ import { queryWrOrderDetail } from '@/services/api/order'
 import { useComponent } from '@/hooks/component'
 import { getWrTradeTypeName, getWRTradeOrderStatusName, getWrPriceTypeName } from '@/constants/order'
 import { useComposeTable } from '@pc/components/base/table'
+import { useTableColumnsStore } from '@/stores'
 import AppTable from '@pc/components/base/table/index.vue'
 
 const componentMap = new Map<string, unknown>([
     ['cancel', defineAsyncComponent(() => import('./cancel/index.vue'))],
 ])
 
+const { getTableColumns } = useTableColumnsStore()
+const tableColumns = shallowRef<Model.TableColumn[]>([])
+
 const { loading, dataList, run } = useRequest(queryWrOrderDetail, {
     params: {
         wrtradetype: 1,
@@ -62,24 +66,12 @@ const { componentRef, componentId, openComponent, closeComponent } = useComponen
 const { rowKey, expandKeys, rowClick } = useComposeTable<Model.WrOrderDetailRsp>({ rowKey: 'wrtradeorderid' })
 const selectedRow = shallowRef<Model.WrOrderDetailRsp>()
 
-const tableColumns = shallowRef<Model.TableColumn[]>([
-    { field: 'wrtradeorderid', label: '挂牌单号' },
-    { field: 'wrtradetype', label: '挂牌类型' },
-    { field: 'wrtradeorderstatus', label: '委托状态' },
-    { field: 'deliverygoodsname', label: '品种' },
-    { field: 'wrstandardname', label: '商品' },
-    { field: 'warehousename', label: '仓库' },
-    { field: 'wrpricetype', label: '挂牌方式' },
-    // { field: 'goodsname', label: '期货合约' },
-    { field: 'fixedprice', label: '价格' },
-    { field: 'orderqty', label: '挂牌量' },
-    { field: 'tradeqty', label: '成交量' },
-    { field: 'ordertime', label: '挂牌时间' }
-])
-
 const showComponent = (componentName: string, row: Model.WrOrderDetailRsp) => {
     selectedRow.value = row
     openComponent(componentName)
 }
 
+getTableColumns('spot-order').then((res) => {
+    tableColumns.value = res
+})
 </script>

+ 8 - 13
src/packages/pc/views/footer/spot/position/index.vue

@@ -28,7 +28,7 @@ import { useRequest } from '@/hooks/request'
 import { useComponent } from '@/hooks/component'
 import { queryHoldLB } from '@/services/api/order'
 import { useComposeTable } from '@pc/components/base/table'
-import { useUserStore } from '@/stores'
+import { useUserStore ,useTableColumnsStore} from '@/stores'
 import AppTable from '@pc/components/base/table/index.vue'
 
 const componentMap = new Map<string, unknown>([
@@ -38,6 +38,9 @@ const componentMap = new Map<string, unknown>([
 
 const userStore = useUserStore()
 const hasTradeMode17 = userStore.hasMarket('TRADEMODE_SPOT_WRTRADE')
+const { getTableColumns } = useTableColumnsStore()
+const tableColumns = shallowRef<Model.TableColumn[]>([])
+
 const { loading, dataList, run } = useRequest(queryHoldLB)
 
 const { componentRef, componentId, openComponent, closeComponent } = useComponent(() => {
@@ -47,20 +50,12 @@ const { componentRef, componentId, openComponent, closeComponent } = useComponen
 const { rowKey, expandKeys, rowClick } = useComposeTable<Model.HoldLBRsp>({ rowKey: 'ladingbillid' })
 const selectedRow = shallowRef<Model.HoldLBRsp>()
 
-const tableColumns = shallowRef<Model.TableColumn[]>([
-    { field: 'wrholdeno', label: '仓单编号' },
-    { field: 'deliverygoodsname', label: '品种' },
-    { field: 'wrstandardname', label: '商品' },
-    { field: 'warehousename', label: '仓库' },
-    { field: 'qty', label: '库存量' },
-    { field: 'freezerqty', label: '冻结量' },
-    { field: 'pledgeqty', label: '质押量' },
-    { field: 'enableqty', label: '可用量' },
-    { field: 'createtime', label: '过户时间' }
-])
-
 const showComponent = (componentName: string, row: Model.HoldLBRsp) => {
     selectedRow.value = row
     openComponent(componentName)
 }
+
+getTableColumns('spot-position').then((res) => {
+    tableColumns.value = res
+})
 </script>

+ 7 - 13
src/packages/pc/views/footer/spot/trade/index.vue

@@ -22,8 +22,12 @@ import { formatDate, formatDecimal } from '@/filters'
 import { useRequest } from '@/hooks/request'
 import { queryWrTradeDetail } from '@/services/api/order'
 import { getWrTradeTypeName } from '@/constants/order'
+import { useTableColumnsStore } from '@/stores'
 import AppTable from '@pc/components/base/table/index.vue'
 
+const { getTableColumns } = useTableColumnsStore()
+const tableColumns = shallowRef<Model.TableColumn[]>([])
+
 const { loading, dataList } = useRequest(queryWrTradeDetail, {
     params: {
         marketid: 17201,
@@ -31,17 +35,7 @@ const { loading, dataList } = useRequest(queryWrTradeDetail, {
     },
 })
 
-const tableColumns = shallowRef<Model.TableColumn[]>([
-    { field: 'wrtradedetailid', label: '成交单号' },
-    { field: 'wrtradetype', label: '类型' },
-    { field: 'deliverygoodsname', label: '品种' },
-    { field: 'wrstandardname', label: '商品' },
-    { field: 'warehousename', label: '仓库' },
-    { field: 'tradeprice', label: '成交价格' },
-    { field: 'tradeqty', label: '成交量' },
-    { field: 'tradeamount', label: '成交金额 ' },
-    { field: 'chargevalue', label: '手续费' },
-    { field: 'matchusername', label: '对手方' },
-    { field: 'tradetime', label: '成交时间' }
-])
+getTableColumns('spot-trade').then((res) => {
+    tableColumns.value = res
+})
 </script>

+ 7 - 12
src/packages/pc/views/footer/swap/order/index.vue

@@ -44,12 +44,16 @@ import { queryTradeOrderDetail } from '@/services/api/order'
 import { useComponent } from '@/hooks/component'
 import { getWRTradeOrderStatusName, getBuyOrSellName } from '@/constants/order'
 import { useComposeTable } from '@pc/components/base/table'
+import { useTableColumnsStore } from '@/stores'
 import AppTable from '@pc/components/base/table/index.vue'
 
 const componentMap = new Map<string, unknown>([
     ['cancel', defineAsyncComponent(() => import('./cancel/index.vue'))],
 ])
 
+const { getTableColumns } = useTableColumnsStore()
+const tableColumns = shallowRef<Model.TableColumn[]>([])
+
 const { loading, dataList, run } = useRequest(queryTradeOrderDetail, {
     params: {
         tradeMode: '46'
@@ -63,21 +67,12 @@ const { componentRef, componentId, openComponent, closeComponent } = useComponen
 const { rowKey, expandKeys, rowClick } = useComposeTable<Model.TradeOrderDetailRsp>({ rowKey: 'orderid' })
 const selectedRow = shallowRef<Model.TradeOrderDetailRsp>()
 
-const tableColumns = shallowRef<Model.TableColumn[]>([
-    { field: 'orderid', label: '委托单号' },
-    { field: 'goodsname', label: '商品代码/名称' },
-    { field: 'buyorsell', label: '方向' },
-    { field: 'pricemode', label: '类型' },
-    { field: 'orderqty', label: '委托量' },
-    { field: 'orderprice', label: '委托价格' },
-    { field: 'tradeqty', label: '成交量' },
-    { field: 'orderstatus', label: '委托状态' },
-    { field: 'ordertime', label: '委托时间' }
-])
-
 const showComponent = (componentName: string, row: Model.TradeOrderDetailRsp) => {
     selectedRow.value = row
     openComponent(componentName)
 }
 
+getTableColumns('swap-order').then((res) => {
+    tableColumns.value = res
+})
 </script>

+ 7 - 12
src/packages/pc/views/footer/swap/trade/index.vue

@@ -26,24 +26,19 @@ import { formatDate } from '@/filters'
 import { useRequest } from '@/hooks/request'
 import { queryTradeDetail } from '@/services/api/order'
 import { getBuildTypeName, getBuyOrSellName } from '@/constants/order'
+import { useTableColumnsStore } from '@/stores'
 import AppTable from '@pc/components/base/table/index.vue'
 
+const { getTableColumns } = useTableColumnsStore()
+const tableColumns = shallowRef<Model.TableColumn[]>([])
+
 const { loading, dataList } = useRequest(queryTradeDetail, {
     params: {
         tradeMode: '46'
     },
 })
 
-const tableColumns = shallowRef<Model.TableColumn[]>([
-    { field: 'tradeid', label: '成交单号' },
-    { field: 'goodsname', label: '商品代码/名称' },
-    { field: 'buildtype', label: '类型' },
-    { field: 'buyorsell', label: '方向' },
-    { field: 'tradeprice', label: '成交价格' },
-    { field: 'charge', label: '手续费' },
-    { field: 'tradeqty', label: '成交数量' },
-    { field: 'tradeamount', label: '成交金额 ' },
-    { field: 'closepl', label: '平仓盈亏' },
-    { field: 'tradetime', label: '成交时间' },
-])
+getTableColumns('swap-trade').then((res) => {
+    tableColumns.value = res
+})
 </script>

+ 10 - 18
src/packages/pc/views/query/inoutapply/history/index.vue

@@ -4,8 +4,8 @@
         <template #headerLeft>
             <app-filter :options="filterOptons">
                 <template #before>
-                    <el-date-picker type="daterange" effect="dark" start-placeholder="开始日期" end-placeholder="结束日期" value-format="YYYYMMDD"
-                        v-model="filterDate" />
+                    <el-date-picker type="daterange" effect="dark" start-placeholder="开始日期" end-placeholder="结束日期"
+                        value-format="YYYYMMDD" v-model="filterDate" />
                 </template>
             </app-filter>
         </template>
@@ -31,11 +31,16 @@ import { useDataFilter } from '@/hooks/datatable'
 import { useRequest } from '@/hooks/request'
 import { queryAccountInOutApply } from '@/services/api/bank'
 import { getInOutApplyStatusName, getInOutExecuteTypeName, getInOutApplyStatusList } from '@/constants/order'
+import { useTableColumnsStore } from '@/stores'
 import AppTable from '@pc/components/base/table/index.vue'
 import AppFilter from '@pc/components/base/table-filter/index.vue'
 
+const { getTableColumns } = useTableColumnsStore()
 const { filterOptons, getQueryParams } = useDataFilter<Model.AccountInOutApplyReq>()
 const filterDate = shallowRef<string[]>([])
+const tableColumns = shallowRef<Model.TableColumn[]>([])
+
+const { loading, dataList, run } = useRequest(queryAccountInOutApply, { manual: true })
 
 filterOptons.buttonList = [
     { lable: '重置', className: 'el-button--info', onClick: () => onSearch(true) },
@@ -58,22 +63,6 @@ filterOptons.selectList = [
     }
 ]
 
-const { loading, dataList, run } = useRequest(queryAccountInOutApply, { manual: true })
-
-const tableColumns = shallowRef<Model.TableColumn[]>([
-    { field: 'extoperateid', label: '流水号' },
-    { field: 'amount', label: '金额' },
-    { field: 'executetype', label: '申请类型' },
-    { field: 'applystatus', label: '状态' },
-    { field: 'accountname', label: '姓名' },
-    { field: 'accountcode', label: '资金账号' },
-    { field: 'bankname', label: '开户银行' },
-    { field: 'bankaccountno', label: '卡号' },
-    { field: 'charge', label: '手续费' },
-    { field: 'updatetime', label: '申请时间' },
-    { field: 'remark2', label: '备注' }
-])
-
 const onSearch = (clear = false) => {
     if (clear) {
         filterDate.value = []
@@ -85,4 +74,7 @@ const onSearch = (clear = false) => {
     }, clear)
 }
 
+getTableColumns('capital-inout').then((res) => {
+    tableColumns.value = res
+})
 </script>

+ 8 - 16
src/packages/pc/views/query/inoutapply/list/index.vue

@@ -26,10 +26,15 @@ import { useDataFilter } from '@/hooks/datatable'
 import { useRequest } from '@/hooks/request'
 import { queryAccountInOutApply } from '@/services/api/bank'
 import { getInOutApplyStatusName, getInOutExecuteTypeName, getInOutApplyStatusList } from '@/constants/order'
+import { useTableColumnsStore } from '@/stores'
 import AppTable from '@pc/components/base/table/index.vue'
 import AppFilter from '@pc/components/base/table-filter/index.vue'
 
 const { filterOptons, getQueryParams } = useDataFilter<Model.AccountInOutApplyReq>()
+const { getTableColumns } = useTableColumnsStore()
+const tableColumns = shallowRef<Model.TableColumn[]>([])
+
+const { loading, dataList, run } = useRequest(queryAccountInOutApply)
 
 filterOptons.buttonList = [
     { lable: '查询', className: 'el-button--info', onClick: () => onSearch() },
@@ -52,24 +57,11 @@ filterOptons.selectList = [
     }
 ]
 
-const { loading, dataList, run } = useRequest(queryAccountInOutApply, { })
-
-const tableColumns = shallowRef<Model.TableColumn[]>([
-    { field: 'extoperateid', label: '流水号' },
-    { field: 'amount', label: '金额' },
-    { field: 'executetype', label: '申请类型' },
-    { field: 'applystatus', label: '状态' },
-    { field: 'accountname', label: '姓名' },
-    { field: 'accountcode', label: '资金账号' },
-    { field: 'bankname', label: '开户银行' },
-    { field: 'bankaccountno', label: '卡号' },
-    { field: 'charge', label: '手续费' },
-    { field: 'updatetime', label: '申请时间' },
-    { field: 'remark2', label: '备注' }
-])
-
 const onSearch = (clear = false) => {
     getQueryParams((qs) => { run(qs) }, clear)
 }
 
+getTableColumns('capital-inout').then((res) => {
+    tableColumns.value = res
+})
 </script>

+ 7 - 15
src/packages/pc/views/query/order/spot/history/index.vue

@@ -40,11 +40,14 @@ import { useDateRange } from '@/hooks/date-picker'
 import { useRequest } from '@/hooks/request'
 import { queryWrOrderDetail } from '@/services/api/order'
 import { getWrTradeTypeName, getWrPriceTypeName, getWRTradeOrderStatusName } from '@/constants/order'
+import { useTableColumnsStore } from '@/stores'
 import AppTable from '@pc/components/base/table/index.vue'
 import AppFilter from '@pc/components/base/table-filter/index.vue'
 
+const { getTableColumns } = useTableColumnsStore()
 const { filterOptons, getQueryParams } = useDataFilter<Model.WrOrderDetailRsp>()
 const { dateValue, valueformat, visibleChange, calendarChange, disabledDate } = useDateRange()
+const tableColumns = ref<Model.TableColumn[]>([])
 const dataList = ref<Model.WrOrderDetailRsp[]>([])
 
 const begindate = computed(() => dateValue.value[0])
@@ -67,21 +70,6 @@ const { loading, run, pageIndex, pageCount } = useRequest(queryWrOrderDetail, {
     }
 })
 
-const tableColumns = ref<Model.TableColumn[]>([
-    { field: 'wrtradeorderid', label: '挂牌单号' },
-    { field: 'wrtradetype', label: '挂牌类型' },
-    { field: 'deliverygoodsname', label: '品种' },
-    { field: 'wrstandardname', label: '商品' },
-    { field: 'warehousename', label: '仓库' },
-    { field: 'wrpricetype', label: '挂牌方式' },
-    { field: 'wrtypename', label: '期货合约' },
-    { field: 'fixedprice', label: '价格/基差' },
-    { field: 'orderqty', label: '挂牌量' },
-    { field: 'tradeqty', label: '成交量' },
-    { field: 'ordertime', label: '挂牌时间' },
-    { field: 'wrtradeorderstatus', label: '状态' },
-])
-
 filterOptons.selectList = [
     {
         key: 'wrtradetype',
@@ -117,4 +105,8 @@ const onSearch = () => {
         run(qs)
     })
 }
+
+getTableColumns('query-spot-order').then((res) => {
+    tableColumns.value = res
+})
 </script>

+ 7 - 14
src/packages/pc/views/query/order/spot/list/index.vue

@@ -26,8 +26,12 @@ import { formatDate } from '@/filters'
 import { useRequest } from '@/hooks/request'
 import { queryWrOrderDetail } from '@/services/api/order'
 import { getWrTradeTypeName, getWrPriceTypeName, getWRTradeOrderStatusName } from '@/constants/order'
+import { useTableColumnsStore } from '@/stores'
 import AppTable from '@pc/components/base/table/index.vue'
 
+const { getTableColumns } = useTableColumnsStore()
+const tableColumns = shallowRef<Model.TableColumn[]>([])
+
 const { loading, dataList } = useRequest(queryWrOrderDetail, {
     params: {
         wrtradetype: 1,
@@ -36,18 +40,7 @@ const { loading, dataList } = useRequest(queryWrOrderDetail, {
     },
 })
 
-const tableColumns = shallowRef<Model.TableColumn[]>([
-    { field: 'wrtradeorderid', label: '挂牌单号' },
-    { field: 'wrtradetype', label: '挂牌类型' },
-    { field: 'deliverygoodsname', label: '品种' },
-    { field: 'wrstandardname', label: '商品' },
-    { field: 'warehousename', label: '仓库' },
-    { field: 'wrpricetype', label: '挂牌方式' },
-    { field: 'wrtypename', label: '期货合约' },
-    { field: 'fixedprice', label: '价格/基差' },
-    { field: 'orderqty', label: '挂牌量' },
-    { field: 'tradeqty', label: '成交量' },
-    { field: 'ordertime', label: '挂牌时间' },
-    { field: 'wrtradeorderstatus', label: '状态' },
-])
+getTableColumns('query-spot-order').then((res) => {
+    tableColumns.value = res
+})
 </script>

+ 7 - 12
src/packages/pc/views/query/order/swap/history/index.vue

@@ -44,11 +44,14 @@ import { useDateRange } from '@/hooks/date-picker'
 import { useRequest } from '@/hooks/request'
 import { queryHisTradeOrderDetail } from '@/services/api/order'
 import { getBuyOrSellName, getWRTradeOrderStatusName, getWRTradeOrderStatusList } from '@/constants/order'
+import { useTableColumnsStore } from '@/stores'
 import AppTable from '@pc/components/base/table/index.vue'
 import AppFilter from '@pc/components/base/table-filter/index.vue'
 
+const { getTableColumns } = useTableColumnsStore()
 const { filterOptons, getQueryParams } = useDataFilter<Model.HisTradeOrderDetailReq>()
 const { dateValue, valueformat, visibleChange, calendarChange, disabledDate } = useDateRange()
+const tableColumns = ref<Model.TableColumn[]>([])
 const dataList = ref<Model.HisTradeOrderDetailRsp[]>([])
 
 const startDate = computed(() => dateValue.value[0])
@@ -71,18 +74,6 @@ const { loading, run, pageIndex, pageCount } = useRequest(queryHisTradeOrderDeta
     }
 })
 
-const tableColumns = ref<Model.TableColumn[]>([
-    { field: 'orderid', label: '委托单号' },
-    { field: 'goodsname', label: '商品代码/名称' },
-    { field: 'buyorsell', label: '方向' },
-    { field: 'pricemode', label: '类型' },
-    { field: 'orderqty', label: '委托量' },
-    { field: 'orderprice', label: '委托价格' },
-    { field: 'tradeqty', label: '成交量' },
-    { field: 'orderstatus', label: '委托状态' },
-    { field: 'ordertime', label: '委托时间' },
-])
-
 filterOptons.selectList = [
     {
         key: 'orderStatus',
@@ -115,4 +106,8 @@ const onSearch = () => {
         run(qs)
     })
 }
+
+getTableColumns('swap-order').then((res) => {
+    tableColumns.value = res
+})
 </script>

+ 7 - 11
src/packages/pc/views/query/order/swap/list/index.vue

@@ -30,23 +30,19 @@ import { formatDate } from '@/filters'
 import { useRequest } from '@/hooks/request'
 import { queryTradeOrderDetail } from '@/services/api/order'
 import { getBuyOrSellName, getWRTradeOrderStatusName } from '@/constants/order'
+import { useTableColumnsStore } from '@/stores'
 import AppTable from '@pc/components/base/table/index.vue'
 
+const { getTableColumns } = useTableColumnsStore()
+const tableColumns = shallowRef<Model.TableColumn[]>([])
+
 const { loading, dataList } = useRequest(queryTradeOrderDetail, {
     params: {
         tradeMode: '46'
     },
 })
 
-const tableColumns = shallowRef<Model.TableColumn[]>([
-    { field: 'orderid', label: '委托单号' },
-    { field: 'goodsname', label: '商品代码/名称' },
-    { field: 'buyorsell', label: '方向' },
-    { field: 'pricemode', label: '类型' },
-    { field: 'orderqty', label: '委托量' },
-    { field: 'orderprice', label: '委托价格' },
-    { field: 'tradeqty', label: '成交量' },
-    { field: 'orderstatus', label: '委托状态' },
-    { field: 'ordertime', label: '委托时间' }
-])
+getTableColumns('swap-order').then((res) => {
+    tableColumns.value = res
+})
 </script>

+ 7 - 13
src/packages/pc/views/query/trade/spot/history/index.vue

@@ -32,11 +32,14 @@ import { useDataFilter } from '@/hooks/datatable'
 import { useDateRange } from '@/hooks/date-picker'
 import { queryWrTradeDetail } from '@/services/api/order'
 import { getBuildTypeName } from '@/constants/order'
+import { useTableColumnsStore } from '@/stores'
 import AppTable from '@pc/components/base/table/index.vue'
 import AppFilter from '@pc/components/base/table-filter/index.vue'
 
+const { getTableColumns } = useTableColumnsStore()
 const { filterOptons, getQueryParams } = useDataFilter<Model.WrTradeDetailRsp>()
 const { dateValue, valueformat, visibleChange, calendarChange, disabledDate } = useDateRange()
+const tableColumns = ref<Model.TableColumn[]>([])
 const dataList = ref<Model.WrTradeDetailRsp[]>([])
 
 const begindate = computed(() => dateValue.value[0])
@@ -58,19 +61,6 @@ const { loading, run, pageIndex, pageCount } = useRequest(queryWrTradeDetail, {
     }
 })
 
-const tableColumns = ref<Model.TableColumn[]>([
-    { field: 'wrtradedetailid', label: '成交单号' },
-    { field: 'buyorsell', label: '类型' },
-    { field: 'deliverygoodsname', label: '品种' },
-    { field: 'wrstandardname', label: '商品' },
-    { field: 'warehousename', label: '仓库' },
-    { field: 'tradeprice', label: '成交价格' },
-    { field: 'tradeqty', label: '成交量' },
-    { field: 'chargevalue', label: '手续费' },
-    { field: 'matchusername', label: '对手方' },
-    { field: 'tradetime', label: '成交时间' },
-])
-
 filterOptons.buttonList = [
     {
         lable: '查询',
@@ -94,4 +84,8 @@ const onSearch = () => {
         run(qs)
     })
 }
+
+getTableColumns('query-spot-trade').then((res) => {
+    tableColumns.value = res
+})
 </script>

+ 7 - 12
src/packages/pc/views/query/trade/spot/list/index.vue

@@ -18,8 +18,12 @@ import { formatDate } from '@/filters'
 import { useRequest } from '@/hooks/request'
 import { queryWrTradeDetail } from '@/services/api/order'
 import { getBuildTypeName } from '@/constants/order'
+import { useTableColumnsStore } from '@/stores'
 import AppTable from '@pc/components/base/table/index.vue'
 
+const { getTableColumns } = useTableColumnsStore()
+const tableColumns = shallowRef<Model.TableColumn[]>([])
+
 const { loading, dataList } = useRequest(queryWrTradeDetail, {
     params: {
         marketid: 17201,
@@ -27,16 +31,7 @@ const { loading, dataList } = useRequest(queryWrTradeDetail, {
     },
 })
 
-const tableColumns = shallowRef<Model.TableColumn[]>([
-    { field: 'wrtradedetailid', label: '成交单号' },
-    { field: 'buyorsell', label: '类型' },
-    { field: 'deliverygoodsname', label: '品种' },
-    { field: 'wrstandardname', label: '商品' },
-    { field: 'warehousename', label: '仓库' },
-    { field: 'tradeprice', label: '成交价格' },
-    { field: 'tradeqty', label: '成交量' },
-    { field: 'chargevalue', label: '手续费' },
-    { field: 'matchusername', label: '对手方' },
-    { field: 'tradetime', label: '成交时间' },
-])
+getTableColumns('query-spot-trade').then((res) => {
+    tableColumns.value = res
+})
 </script>

+ 9 - 15
src/packages/pc/views/query/trade/swap/history/index.vue

@@ -6,7 +6,8 @@
                 <template #before>
                     <el-date-picker type="daterange" effect="dark" :editable="false" :clearable="false"
                         start-placeholder="开始日期" end-placeholder="结束日期" :value-format="valueformat" v-model="dateValue"
-                        @visible-change="visibleChange" @calendar-change="calendarChange" :disabled-date="disabledDate" />
+                        @visible-change="visibleChange" @calendar-change="calendarChange"
+                        :disabled-date="disabledDate" />
                 </template>
             </app-filter>
         </template>
@@ -44,11 +45,14 @@ import { useDataFilter } from '@/hooks/datatable'
 import { useDateRange } from '@/hooks/date-picker'
 import { queryHisTradeDetail, } from '@/services/api/order'
 import { getBuildTypeName, getBuyOrSellName, getBuildTypeList } from '@/constants/order'
+import { useTableColumnsStore } from '@/stores'
 import AppTable from '@pc/components/base/table/index.vue'
 import AppFilter from '@pc/components/base/table-filter/index.vue'
 
+const { getTableColumns } = useTableColumnsStore()
 const { filterOptons, getQueryParams } = useDataFilter<Model.HisTradeDetailReq>()
 const { dateValue, valueformat, visibleChange, calendarChange, disabledDate } = useDateRange()
+const tableColumns = ref<Model.TableColumn[]>([])
 const dataList = ref<Model.HisTradeDetailRsp[]>([])
 
 const startDate = computed(() => dateValue.value[0])
@@ -81,20 +85,6 @@ filterOptons.selectList = [
     }
 ]
 
-const tableColumns = ref<Model.TableColumn[]>([
-    { field: 'tradeid', label: '成交单号' },
-    { field: 'goodsname', label: '商品代码/名称' },
-    { field: 'buildtype', label: '类型' },
-    { field: 'buyorsell', label: '方向' },
-    { field: 'tradeprice', label: '成交价格' },
-    { field: 'charge', label: '手续费' },
-    { field: 'tradeqty', label: '成交量' },
-    { field: 'tradeamount', label: '成交金额 ' },
-    { field: 'closepl', label: '平仓盈亏' },
-    { field: 'matchaccountid', label: '成交对手' },
-    { field: 'tradetime', label: '成交时间' },
-])
-
 filterOptons.buttonList = [
     {
         lable: '查询',
@@ -118,4 +108,8 @@ const onSearch = () => {
         run(qs)
     })
 }
+
+getTableColumns('swap-trade').then((res) => {
+    tableColumns.value = res
+})
 </script>

+ 7 - 13
src/packages/pc/views/query/trade/swap/list/index.vue

@@ -30,25 +30,19 @@ import { formatDate, tmMatchAccountID } from '@/filters'
 import { useRequest } from '@/hooks/request'
 import { queryTradeDetail } from '@/services/api/order'
 import { getBuildTypeName, getBuyOrSellName } from '@/constants/order'
+import { useTableColumnsStore } from '@/stores'
 import AppTable from '@pc/components/base/table/index.vue'
 
+const { getTableColumns } = useTableColumnsStore()
+const tableColumns = shallowRef<Model.TableColumn[]>([])
+
 const { loading, dataList } = useRequest(queryTradeDetail, {
     params: {
         tradeMode: '46'
     },
 })
 
-const tableColumns = shallowRef<Model.TableColumn[]>([
-    { field: 'tradeid', label: '成交单号' },
-    { field: 'goodsname', label: '商品代码/名称' },
-    { field: 'buildtype', label: '类型' },
-    { field: 'buyorsell', label: '方向' },
-    { field: 'tradeprice', label: '成交价格' },
-    { field: 'charge', label: '手续费' },
-    { field: 'tradeqty', label: '成交量' },
-    { field: 'tradeamount', label: '成交金额 ' },
-    { field: 'closepl', label: '平仓盈亏' },
-    { field: 'matchaccountid', label: '成交对手' },
-    { field: 'tradetime', label: '成交时间' },
-])
+getTableColumns('swap-trade').then((res) => {
+    tableColumns.value = res
+})
 </script>