|
|
@@ -33,7 +33,7 @@ import { BuyOrSell } from '@/constants/order'
|
|
|
import { useComponent } from '@/hooks/component'
|
|
|
import { useComposeTable } from '@pc/components/base/table'
|
|
|
import { queryWrTradeOrderDetail } from '@/services/api/transfer'
|
|
|
-import { useFuturesStore } from '@/stores'
|
|
|
+import { useFuturesStore, i18n } from '@/stores'
|
|
|
import AppTable from '@pc/components/base/table/index.vue'
|
|
|
import service from '@/services'
|
|
|
|
|
|
@@ -52,9 +52,10 @@ const componentMap = new Map<string, unknown>([
|
|
|
const futuresStore = useFuturesStore()
|
|
|
const quote = futuresStore.getGoodsQuote(props.goodsId)
|
|
|
const oem = service.getConfig('oem')
|
|
|
+const { t } = i18n.global
|
|
|
|
|
|
const { rowKey, expandKeys, selectedRow, rowClick } = useComposeTable<Model.WrTradeOrderDetailRsp>({ rowKey: 'orderid' })
|
|
|
-const { componentRef, componentId, openComponent, closeComponent } = useComponent()
|
|
|
+const { componentRef, componentId, closeComponent } = useComponent()
|
|
|
|
|
|
const { dataList: buyList, run: getBuyList } = useRequest(queryWrTradeOrderDetail, {
|
|
|
params: {
|
|
|
@@ -73,19 +74,19 @@ const { dataList: sellList, run: getSellList } = useRequest(queryWrTradeOrderDet
|
|
|
})
|
|
|
|
|
|
const buyColumns = shallowRef<Model.TableColumn[]>(
|
|
|
- oem != 'zrwyt' ? [{ field: 'orderprice', label: '买价' },
|
|
|
- { field: 'orderqty', label: '买量' },
|
|
|
- { field: 'username', label: '购买方' }] :
|
|
|
- [{ field: 'orderprice', label: '买价' },
|
|
|
- { field: 'orderqty', label: '买量' }]
|
|
|
+ oem != 'zrwyt' ? [{ field: 'orderprice', label: t('quote.bid') },
|
|
|
+ { field: 'orderqty', label: t('quote.bidvolume') },
|
|
|
+ { field: 'username', label: t('quote.buyusername') }] :
|
|
|
+ [{ field: 'orderprice', label: t('quote.bid') },
|
|
|
+ { field: 'orderqty', label: t('quote.bidvolume') }]
|
|
|
)
|
|
|
|
|
|
const sellColumns = shallowRef<Model.TableColumn[]>(
|
|
|
- oem != 'zrwyt' ? [{ field: 'orderprice', label: '卖价' },
|
|
|
- { field: 'orderqty', label: '卖量' },
|
|
|
- { field: 'username', label: '销售方' }] :
|
|
|
- [{ field: 'orderprice', label: '卖价' },
|
|
|
- { field: 'orderqty', label: '卖量' }]
|
|
|
+ oem != 'zrwyt' ? [{ field: 'orderprice', label: t('quote.ask') },
|
|
|
+ { field: 'orderqty', label: t('quote.askvolume') },
|
|
|
+ { field: 'username', label: t('quote.sellusername') }] :
|
|
|
+ [{ field: 'orderprice', label: t('quote.ask') },
|
|
|
+ { field: 'orderqty', label: t('quote.askvolume') }]
|
|
|
)
|
|
|
|
|
|
// const showComponent = (componentName: string, row: Model.WrTradeOrderDetailRsp) => {
|