|
|
@@ -1,22 +1,6 @@
|
|
|
import { shallowRef } from 'vue'
|
|
|
import { useTableColumnStore } from '@/stores'
|
|
|
-
|
|
|
-/**
|
|
|
- * 获取表格列数据
|
|
|
- * @param tableKey
|
|
|
- * @returns
|
|
|
- */
|
|
|
-export function getTableColumns(tableKey: TableColumnKey) {
|
|
|
- const tableColumns = pcTableColumnMap.get(tableKey) ?? [] // *这里应该判断终端类型,有空再处理*
|
|
|
-
|
|
|
- return tableColumns.map((e) => {
|
|
|
- e.show = true
|
|
|
- if (e.prop === 'operate') {
|
|
|
- e.fixed = 'right'
|
|
|
- }
|
|
|
- return e
|
|
|
- })
|
|
|
-}
|
|
|
+import { TableColumnKey, pcTableColumnMap } from './columns'
|
|
|
|
|
|
export function useTableColumns(tableKey: string, operateColumn = true) {
|
|
|
const { tableColumns } = useTableColumnStore()
|
|
|
@@ -53,360 +37,20 @@ export function useTableColumns(tableKey: string, operateColumn = true) {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
-type TableColumnKey = typeof tableColumnKeys[number]
|
|
|
-const tableColumnKeys = ['system_menu', 'system_role', 'warehousing_diamond', 'warehousing_warehouse', 'mine_capital', 'listing_sellorder', 'listing_buyorder', 'listing_saleorder', 'listing_purchaseorder', 'listing_delisting', 'listing_bargain_buy', 'listing_bargain_sell', 'mine_address', 'mine_invoice', 'favorite', 'order', 'order_step', 'bargain_buy', 'bargain_sell', 'customs_cjjc', 'customs_bsfw', 'customs_bsfw_file', 'report_member', 'report_warehousing', 'report_trade'] as const
|
|
|
-
|
|
|
/**
|
|
|
- * PC端表格列
|
|
|
+ * 获取表格列数据
|
|
|
+ * @param tableKey
|
|
|
+ * @returns
|
|
|
*/
|
|
|
-const pcTableColumnMap = new Map<TableColumnKey, Ermcp.TableColumn[]>([
|
|
|
- // 系统管理-菜单管理
|
|
|
- ['system_menu', [
|
|
|
- { prop: 'resourcename', label: '菜单' },
|
|
|
- { prop: 'resourcecode', label: '代码' },
|
|
|
- { prop: 'component', label: '组件' },
|
|
|
- { prop: 'iconame', label: '图标' },
|
|
|
- { prop: 'operate', label: '操作' }
|
|
|
- ]],
|
|
|
- // 系统管理-角色管理
|
|
|
- ['system_role', [
|
|
|
- { prop: 'id', label: '序号', width: 100 },
|
|
|
- { prop: 'roleName', label: '角色名称' },
|
|
|
- { prop: 'createdAt', label: '创建时间' },
|
|
|
- { prop: 'updatedAt', label: '更新时间' },
|
|
|
- { prop: 'operate', label: '操作', width: 300 }
|
|
|
- ]],
|
|
|
- // 我的仓储-我的库存
|
|
|
- ['warehousing_diamond', [
|
|
|
- { prop: 'warehousenamedisplay', label: '仓库' },
|
|
|
- { prop: 'zsshapetypedisplay', label: '形状', width: 200 },
|
|
|
- { prop: 'zscolortype1display', label: '颜色' },
|
|
|
- { prop: 'zsclaritytype1display', label: '净度' },
|
|
|
- { prop: 'zscuttype1display', label: '切工' },
|
|
|
- { prop: 'zspolishtype1display', label: '抛光' },
|
|
|
- { prop: 'zssymmetrytype1display', label: '对称' },
|
|
|
- { prop: 'zsfluorescencetype1display', label: '荧光' },
|
|
|
- { prop: 'sizedisplay', label: '尺寸' },
|
|
|
- { prop: 'price', label: '价格' },
|
|
|
- { prop: 'weight', label: '克拉重量' },
|
|
|
- { prop: 'priceper', label: '克拉单价' },
|
|
|
- { prop: 'marketflag', label: '是否上架' },
|
|
|
- { prop: 'operate', label: '操作', width: 240 }
|
|
|
- ]],
|
|
|
- // 我的仓储-我的仓库
|
|
|
- ['warehousing_warehouse', [
|
|
|
- { prop: 'warehousecode', label: '仓库代码' },
|
|
|
- { prop: 'warehousename', label: '仓库名称' },
|
|
|
- { prop: 'address', label: '仓库地址' },
|
|
|
- { prop: 'contactname', label: '联系人' },
|
|
|
- { prop: 'contactnum', label: '联系电话' },
|
|
|
- { prop: 'createtime', label: '创建时间' },
|
|
|
- { prop: 'operate', label: '操作' }
|
|
|
- ]],
|
|
|
- // 挂牌大厅-出售大厅
|
|
|
- ['listing_sellorder', [
|
|
|
- { prop: 'sellusername', label: '卖方' },
|
|
|
- { prop: 'warehousenamedisplay', label: '仓库', width: 180 },
|
|
|
- { prop: 'zsshapetypedisplay', label: '形状', width: 200 },
|
|
|
- { prop: 'zscolortype1display', label: '颜色' },
|
|
|
- { prop: 'zsclaritytype1display', label: '净度' },
|
|
|
- { prop: 'zscuttype1display', label: '切工' },
|
|
|
- { prop: 'zspolishtype1display', label: '抛光' },
|
|
|
- { prop: 'zssymmetrytype1display', label: '对称' },
|
|
|
- { prop: 'zsfluorescencetype1display', label: '荧光' },
|
|
|
- { prop: 'sizedisplay', label: '尺寸' },
|
|
|
- { prop: 'price', label: '价格' },
|
|
|
- { prop: 'totalqty', label: '克拉重量' },
|
|
|
- { prop: 'fixedprice', label: '克拉单价' },
|
|
|
- { prop: 'operate', label: '操作', width: 180 }
|
|
|
- ]],
|
|
|
- // 挂牌大厅-求购大厅
|
|
|
- ['listing_buyorder', [
|
|
|
- { prop: 'buyusername', label: '买方' },
|
|
|
- { prop: 'zsshapetypedisplay', label: '形状', width: 200 },
|
|
|
- { prop: 'zscolortypedisplay', label: '颜色' },
|
|
|
- { prop: 'zsclaritytypedisplay', label: '净度' },
|
|
|
- { prop: 'zscuttypedisplay', label: '切工' },
|
|
|
- { prop: 'zspolishtypedisplay', label: '抛光' },
|
|
|
- { prop: 'zssymmetrytypedisplay', label: '对称' },
|
|
|
- { prop: 'zsfluorescencetypedisplay', label: '荧光' },
|
|
|
- { prop: 'zssize', label: '尺寸' },
|
|
|
- { prop: 'operate', label: '操作' }
|
|
|
- ]],
|
|
|
- // 挂牌大厅-我的出售
|
|
|
- ['listing_saleorder', [
|
|
|
- { prop: 'warehousenamedisplay', label: '仓库', width: 180 },
|
|
|
- { prop: 'zsshapetypedisplay', label: '形状', width: 200 },
|
|
|
- { prop: 'zscolortype1display', label: '颜色' },
|
|
|
- { prop: 'zsclaritytype1display', label: '净度' },
|
|
|
- { prop: 'zscuttype1display', label: '切工' },
|
|
|
- { prop: 'zspolishtype1display', label: '抛光' },
|
|
|
- { prop: 'zssymmetrytype1display', label: '对称' },
|
|
|
- { prop: 'zsfluorescencetype1display', label: '荧光' },
|
|
|
- { prop: 'sizedisplay', label: '尺寸' },
|
|
|
- { prop: 'price', label: '价格' },
|
|
|
- { prop: 'totalqty', label: '克拉重量' },
|
|
|
- { prop: 'fixedprice', label: '克拉单价' },
|
|
|
- { prop: 'operate', label: '操作', width: 180 }
|
|
|
- ]],
|
|
|
- // 挂牌大厅-我的求购
|
|
|
- ['listing_purchaseorder', [
|
|
|
- { prop: 'zsshapetypedisplay', label: '形状', width: 200 },
|
|
|
- { prop: 'zscolortypedisplay', label: '颜色' },
|
|
|
- { prop: 'zsclaritytypedisplay', label: '净度' },
|
|
|
- { prop: 'zscuttypedisplay', label: '切工' },
|
|
|
- { prop: 'zspolishtypedisplay', label: '抛光' },
|
|
|
- { prop: 'zssymmetrytypedisplay', label: '对称' },
|
|
|
- { prop: 'zsfluorescencetypedisplay', label: '荧光' },
|
|
|
- { prop: 'zssize', label: '尺寸' },
|
|
|
- { prop: 'operate', label: '操作', width: 180 }
|
|
|
- ]],
|
|
|
- // 挂牌大厅-我的摘牌
|
|
|
- ['listing_delisting', [
|
|
|
- { prop: 'buyorsell', label: '类型' },
|
|
|
- { prop: 'matchusername', label: '对手方' },
|
|
|
- { prop: 'zsshapetypedisplay', label: '形状' },
|
|
|
- { prop: 'zscolortype1display', label: '颜色' },
|
|
|
- { prop: 'zsclaritytype1display', label: '净度' },
|
|
|
- { prop: 'zscuttype1display', label: '切工' },
|
|
|
- { prop: 'zspolishtype1display', label: '抛光' },
|
|
|
- { prop: 'zssymmetrytype1display', label: '对称' },
|
|
|
- { prop: 'zsfluorescencetype1display', label: '荧光' },
|
|
|
- { prop: 'sizedisplay', label: '尺寸' },
|
|
|
- { prop: 'qty', label: '重量' },
|
|
|
- { prop: 'price', label: '价格' },
|
|
|
- { prop: 'exchangerate', label: '汇率' },
|
|
|
- { prop: 'tradeprice', label: '成交价格' },
|
|
|
- { prop: 'tradetime', label: '成交时间', width: 200 },
|
|
|
- { prop: 'operate', label: '操作' }
|
|
|
- ]],
|
|
|
- // 挂牌大厅-我的询价-求购
|
|
|
- ['listing_bargain_buy', [
|
|
|
- { prop: 'sellusername', label: '卖方' },
|
|
|
- { prop: 'warehousenamedisplay', label: '仓库' },
|
|
|
- { prop: 'zsshapetypedisplay', label: '形状', width: 200 },
|
|
|
- { prop: 'zscolortype1display', label: '颜色' },
|
|
|
- { prop: 'zsclaritytype1display', label: '净度' },
|
|
|
- { prop: 'zscuttype1display', label: '切工' },
|
|
|
- { prop: 'zspolishtype1display', label: '抛光' },
|
|
|
- { prop: 'zssymmetrytype1display', label: '对称' },
|
|
|
- { prop: 'zsfluorescencetype1display', label: '荧光' },
|
|
|
- { prop: 'sizedisplay', label: '尺寸' },
|
|
|
- { prop: 'price', label: '价格' },
|
|
|
- { prop: 'qty', label: '克拉重量' },
|
|
|
- { prop: 'priceper', label: '克拉单价' },
|
|
|
- { prop: 'applyprice', label: '我的出价' },
|
|
|
- { prop: 'applystatus', label: '申请状态' },
|
|
|
- { prop: 'applytime', label: '申请时间', width: 200 },
|
|
|
- { prop: 'operate', label: '操作', width: 180 }
|
|
|
- ]],
|
|
|
- // 挂牌大厅-我的询价-出售
|
|
|
- ['listing_bargain_sell', [
|
|
|
- { prop: 'buyusername', label: '买方' },
|
|
|
- { prop: 'zsshapetypedisplay', label: '形状', width: 200 },
|
|
|
- { prop: 'zscolortypedisplay', label: '颜色' },
|
|
|
- { prop: 'zsclaritytypedisplay', label: '净度' },
|
|
|
- { prop: 'zscuttypedisplay', label: '切工' },
|
|
|
- { prop: 'zspolishtypedisplay', label: '抛光' },
|
|
|
- { prop: 'zssymmetrytypedisplay', label: '对称' },
|
|
|
- { prop: 'zsfluorescencetypedisplay', label: '荧光' },
|
|
|
- { prop: 'zssizedisplay', label: '尺寸' },
|
|
|
- { prop: 'goodsno', label: '我的商品' },
|
|
|
- { prop: 'applyqty', label: '克拉重量' },
|
|
|
- { prop: 'applyprice', label: '我的出价' },
|
|
|
- { prop: 'applystatus', label: '申请状态' },
|
|
|
- { prop: 'applytime', label: '申请时间', width: 200 },
|
|
|
- { prop: 'operate', label: '操作', width: 180 }
|
|
|
- ]],
|
|
|
- // 会员中心-我的出入金
|
|
|
- ['mine_capital', [
|
|
|
- { prop: 'accountcode', label: '资金账户' },
|
|
|
- { prop: 'cusbankname', label: '托管银行' },
|
|
|
- { prop: 'executetype', label: '申请类型' },
|
|
|
- { prop: 'amount', label: '金额' },
|
|
|
- { prop: 'charge', label: '服务费' },
|
|
|
- { prop: 'updatetime', label: '申请时间' },
|
|
|
- { prop: 'applystatus', label: '状态' },
|
|
|
- ]],
|
|
|
- // 会员中心-我的地址
|
|
|
- ['mine_address', [
|
|
|
- { prop: 'receivername', label: '收货人' },
|
|
|
- { prop: 'cardtypeid', label: '证件类型' },
|
|
|
- { prop: 'cardnum', label: '证件号码' },
|
|
|
- { prop: 'phonenum', label: '联系电话' },
|
|
|
- { prop: 'address', label: '收货地址', width: 300 },
|
|
|
- { prop: 'isdefault', label: '是否默认' },
|
|
|
- { prop: 'operate', label: '操作', width: 250 }
|
|
|
- ]],
|
|
|
- // 会员中心-我的发票
|
|
|
- ['mine_invoice', [
|
|
|
- { prop: 'receipttype', label: '发票类型' },
|
|
|
- { prop: 'username', label: '发票抬头' },
|
|
|
- { prop: 'taxpayerid', label: '税号' },
|
|
|
- { prop: 'contactinfo', label: '企业电话' },
|
|
|
- { prop: 'information', label: '企业信息' },
|
|
|
- { prop: 'operate', label: '操作' }
|
|
|
- ]],
|
|
|
- // 我的收藏
|
|
|
- ['favorite', [
|
|
|
- { prop: 'warehousenamedisplay', label: '仓库' },
|
|
|
- { prop: 'zsshapetypedisplay', label: '形状' },
|
|
|
- { prop: 'zscolortype1display', label: '颜色' },
|
|
|
- { prop: 'zsclaritytype1display', label: '净度' },
|
|
|
- { prop: 'zscuttype1display', label: '切工' },
|
|
|
- { prop: 'zspolishtype1display', label: '抛光' },
|
|
|
- { prop: 'zssymmetrytype1display', label: '对称' },
|
|
|
- { prop: 'zsfluorescencetype1display', label: '荧光' },
|
|
|
- { prop: 'sizedisplay', label: '尺寸' },
|
|
|
- { prop: 'price', label: '价格' },
|
|
|
- { prop: 'weight', label: '克拉重量' },
|
|
|
- { prop: 'priceper', label: '克拉单价' },
|
|
|
- { prop: 'operate', label: '操作', width: 180 }
|
|
|
- ]],
|
|
|
- // 订单管理
|
|
|
- ['order', [
|
|
|
- { prop: 'zscategorydisplay', label: '商品分类' },
|
|
|
- { prop: 'goodsno', label: '商品编号' },
|
|
|
- { prop: 'zsshapetypedisplay', label: '形状' },
|
|
|
- { prop: 'zscolortype1display', label: '颜色' },
|
|
|
- { prop: 'sizedisplay', label: '尺寸' },
|
|
|
- { prop: 'zspolishtype1display', label: '重量' },
|
|
|
- { prop: 'price', label: '价格' },
|
|
|
- { prop: 'accountname', label: '对手方' },
|
|
|
- { prop: 'paidamount', label: '已付/已付金额' },
|
|
|
- { prop: 'freezeamountremain', label: '履约剩余冻结' },
|
|
|
- { prop: 'performancestatus', label: '履约状态' },
|
|
|
- { prop: 'steptypeid', label: '当前步骤' },
|
|
|
- { prop: 'remaindays', label: '剩余天数' },
|
|
|
- { prop: 'operate', label: '操作', width: 380 }
|
|
|
- ]],
|
|
|
- // 订单履约步骤
|
|
|
- ['order_step', [
|
|
|
- { prop: 'steptypename', label: '名称' },
|
|
|
- { prop: 'stepdays', label: '天数' },
|
|
|
- { prop: 'remaindays', label: '剩余天数' },
|
|
|
- { prop: 'stepvalue', label: '步骤值(%)' },
|
|
|
- { prop: 'stepamount', label: '金额' },
|
|
|
- { prop: 'realamount', label: '完成金额' },
|
|
|
- { prop: 'isauto', label: '是否自动' },
|
|
|
- { prop: 'steplanchtype', label: '启动类型' },
|
|
|
- { prop: 'starttime', label: '开始日期' },
|
|
|
- { prop: 'endtime', label: '结束日期' },
|
|
|
- { prop: 'stepstatus', label: '步骤状态' },
|
|
|
- { prop: 'remark', label: '步骤备注' },
|
|
|
- ]],
|
|
|
- // 询价消息-求购
|
|
|
- ['bargain_buy', [
|
|
|
- { prop: 'warehousenamedisplay', label: '仓库' },
|
|
|
- { prop: 'zsshapetypedisplay', label: '形状', width: 200 },
|
|
|
- { prop: 'zscolortype1display', label: '颜色' },
|
|
|
- { prop: 'zsclaritytype1display', label: '净度' },
|
|
|
- { prop: 'zscuttype1display', label: '切工' },
|
|
|
- { prop: 'zspolishtype1display', label: '抛光' },
|
|
|
- { prop: 'zssymmetrytype1display', label: '对称' },
|
|
|
- { prop: 'zsfluorescencetype1display', label: '荧光' },
|
|
|
- { prop: 'sizedisplay', label: '尺寸' },
|
|
|
- { prop: 'price', label: '价格' },
|
|
|
- { prop: 'qty', label: '克拉重量' },
|
|
|
- { prop: 'priceper', label: '克拉单价' },
|
|
|
- { prop: 'buyusername', label: '买方' },
|
|
|
- { prop: 'applyprice', label: '买方出价' },
|
|
|
- { prop: 'applystatus', label: '申请状态' },
|
|
|
- { prop: 'applytime', label: '申请时间', width: 200 },
|
|
|
- { prop: 'operate', label: '操作', width: 180 }
|
|
|
- ]],
|
|
|
- // 询价消息-出售
|
|
|
- ['bargain_sell', [
|
|
|
- { prop: 'zsshapetypedisplay', label: '形状', width: 200 },
|
|
|
- { prop: 'zscolortypedisplay', label: '颜色' },
|
|
|
- { prop: 'zsclaritytypedisplay', label: '净度' },
|
|
|
- { prop: 'zscuttypedisplay', label: '切工' },
|
|
|
- { prop: 'zspolishtypedisplay', label: '抛光' },
|
|
|
- { prop: 'zssymmetrytypedisplay', label: '对称' },
|
|
|
- { prop: 'zsfluorescencetypedisplay', label: '荧光' },
|
|
|
- { prop: 'zssizedisplay', label: '尺寸' },
|
|
|
- { prop: 'sellusername', label: '卖方' },
|
|
|
- { prop: 'goodsno', label: '卖方商品' },
|
|
|
- { prop: 'applyqty', label: '克拉重量' },
|
|
|
- { prop: 'applyprice', label: '卖方出价' },
|
|
|
- { prop: 'applystatus', label: '申请状态' },
|
|
|
- { prop: 'applytime', label: '申请时间', width: 200 },
|
|
|
- { prop: 'operate', label: '操作', width: 180 }
|
|
|
- ]],
|
|
|
- // 交易服务-出境检测
|
|
|
- ['customs_cjjc', [
|
|
|
- { prop: 'orderno', label: '单据编号', width: 180 },
|
|
|
- { prop: 'gzcjcategorytypedisplay', label: '货物品类' },
|
|
|
- { prop: 'gzcjdeliverytypedisplay', label: '收货方式', width: 200 },
|
|
|
- { prop: 'gzcjaccount', label: '送检账户' },
|
|
|
- { prop: 'undefined', label: '总数量(粒)' },
|
|
|
- { prop: 'undefined', label: '总重量(ct)' },
|
|
|
- { prop: 'totalamount', label: '总参考值(US$)' },
|
|
|
- { prop: 'contactname', label: '联系人姓名' },
|
|
|
- { prop: 'contactphoneno', label: '联系人电话' },
|
|
|
- { prop: 'gzcjstatusdisplay', label: '单据状态' },
|
|
|
- { prop: 'operate', label: '操作', width: 260 }
|
|
|
- ]],
|
|
|
- // 交易服务-保税服务
|
|
|
- ['customs_bsfw', [
|
|
|
- { prop: 'orderno', label: '单据编号', width: 180 },
|
|
|
- { prop: 'contentrange', label: '内容' },
|
|
|
- { prop: 'totalnetweigthct', label: '总净重(克拉)' },
|
|
|
- { prop: 'totalnetweightgm', label: '总净重(克)' },
|
|
|
- { prop: 'totalgrossweightgm', label: '总毛重(克)' },
|
|
|
- { prop: 'totalamount', label: '总值(美元)' },
|
|
|
- { prop: 'priceper', label: '单价(美元/克拉)', width: 160 },
|
|
|
- { prop: 'undefined', label: '备注' },
|
|
|
- { prop: 'gzbsstatusdisplay', label: '单据状态' },
|
|
|
- { prop: 'operate', label: '操作', width: 280 }
|
|
|
- ]],
|
|
|
- // 交易服务-保税服务-文件下载
|
|
|
- ['customs_bsfw_file', [
|
|
|
- { prop: 'filename', label: '文件名' },
|
|
|
- { prop: 'operatetime', label: '生成时间' },
|
|
|
- { prop: 'operate', label: '操作', width: 180 }
|
|
|
- ]],
|
|
|
- // 报表-会员报表
|
|
|
- ['report_member', [
|
|
|
- { prop: 'reckondate', label: '日期' },
|
|
|
- { prop: 'accountid', label: '资金账户' },
|
|
|
- { prop: 'balance', label: '期初余额' },
|
|
|
- { prop: 'currentbalance', label: '期末余额' },
|
|
|
- { prop: 'avaiablemoney', label: '可用资金' },
|
|
|
- { prop: 'avaiableoutmoney', label: '可出资金' },
|
|
|
- { prop: 'netvalue', label: '当前净值' },
|
|
|
- { prop: 'inamount', label: '入金金额' },
|
|
|
- { prop: 'outamount', label: '出金金额' },
|
|
|
- { prop: 'paycharge', label: '手续费支出' },
|
|
|
- { prop: 'deliveryamountin', label: '销售收入' },
|
|
|
- { prop: 'deliveryamountout', label: '购买支出' },
|
|
|
- { prop: 'otherfreezemargin', label: '其他冻结' },
|
|
|
- { prop: 'outamountfreeze', label: '出金冻结' },
|
|
|
- ]],
|
|
|
- // 报表-仓储报表
|
|
|
- ['report_warehousing', [
|
|
|
- { prop: 'reckondate', label: '日期' },
|
|
|
- { prop: 'zscategorydisplay', label: '商品分类' },
|
|
|
- { prop: 'zscurrencytypedisplay', label: '商品货币' },
|
|
|
- { prop: 'totalweight', label: '库存重量(ct)' },
|
|
|
- { prop: 'totalprice', label: '库存金额' },
|
|
|
- { prop: 'buytradeqty', label: '购买重量(ct)' },
|
|
|
- { prop: 'buytradeamount', label: '购买金额(¥)' },
|
|
|
- { prop: 'selltradeqty', label: '销售重量(ct)' },
|
|
|
- { prop: 'selltradeamount', label: '销售金额(¥)' },
|
|
|
- ]],
|
|
|
- // 报表-交易报表
|
|
|
- ['report_trade', [
|
|
|
- { prop: 'reckondate', label: '日期' },
|
|
|
- { prop: 'zscategorydisplay', label: '商品分类' },
|
|
|
- { prop: 'zscurrencytypedisplay', label: '商品货币' },
|
|
|
- { prop: 'buylistinglot', label: '买挂牌宗数' },
|
|
|
- { prop: 'selllistinglot', label: '卖挂牌宗数' },
|
|
|
- { prop: 'selllistingqty', label: '卖挂牌数量' },
|
|
|
- { prop: 'selltradeamount', label: '卖挂牌金额' },
|
|
|
- { prop: 'buytradeqty', label: '购买重量(ct)' },
|
|
|
- { prop: 'buytradeamount', label: '购买金额(¥)' },
|
|
|
- { prop: 'selltradeqty', label: '销售重量(ct)' },
|
|
|
- { prop: 'selltradeamount', label: '销售金额(¥)' },
|
|
|
- ]],
|
|
|
-])
|
|
|
+export function getTableColumns(tableKey?: TableColumnKey) {
|
|
|
+ if (tableKey) {
|
|
|
+ const tableColumns = pcTableColumnMap.get(tableKey) ?? [] // *这里应该判断终端类型,有空再处理*
|
|
|
+ return tableColumns.map((e) => {
|
|
|
+ if (e.prop === 'operate') {
|
|
|
+ e.fixed = 'right'
|
|
|
+ }
|
|
|
+ return e
|
|
|
+ })
|
|
|
+ }
|
|
|
+ return []
|
|
|
+}
|