Handy_Cao 1 jaar geleden
bovenliggende
commit
ecea36045d

+ 1 - 1
src/packages/pc/views/market/trade/mall/index.vue

@@ -48,9 +48,9 @@ const componentMap = new Map<string, unknown>([
 
 const onRowClick = (row: Model.GoodsQuote) => {
     if (param1012 !== '0') {
-        futuresStore.selectedGoodsId = row.goodsid
         openComponent('detail')
     }
+    futuresStore.selectedGoodsId = row.goodsid
 }
 
 const openImageViewer = (url?: string) => {

+ 2 - 3
src/packages/pc/views/market/trade/pricing/list/listing/index.vue

@@ -352,14 +352,13 @@ const getOrderPrice = () => {
     }
 }
 
-watch([selectedGoodsId, orderPriceType], () => {
-    console.log(buyOrSell)
+watch([selectedGoodsId, buyOrSell, orderPriceType], () => {
     // 商城模式只有买方向
     if (selectedGoods.value?.trademode === 53) {
         formData.BuyOrSell = BuyOrSell.Buy
         formData.PriceMode = PriceMode.Market
     }
-    // formData.BuyOrSell = buyOrSell
+    formData.BuyOrSell = buyOrSell.value
     formData.OrderPrice = getOrderPrice()
 })
 

+ 1 - 2
src/packages/pc/views/market/trade/pricing/v2/index.vue

@@ -62,8 +62,7 @@ const onRowClick = (row: Model.GoodsQuote) => {
 }
 
 const onBuyOrSellClick = (buyOrSell: number) => {
-    console.log(buyOrSell)
-    // futuresStore.buyOrSell = buyOrSell
+    futuresStore.buyOrSell = buyOrSell
 }
 
 const openImageViewer = (url?: string) => {

+ 1 - 0
src/stores/modules/futures.ts

@@ -33,6 +33,7 @@ export const useFuturesStore = defineStore(() => {
         goodsList: <(Model.GoodsRsp & Partial<Model.MemberGoodsLimitConfigRsp>)[]>[], // 商品列表
         quotationList: <Model.GoodsQuote[]>[], // 行情列表
         selectedGoodsId: <number | undefined>undefined, // 当前选中的商品ID
+        buyOrSell: <number>0,
     })
 
     // 指定市场ID的商品列表