huangbin 4 years ago
parent
commit
71a2da6e50

+ 2 - 2
src/services/socket/quota/adapter/index.ts

@@ -123,9 +123,9 @@ export function parseReceivePush(quotationData: any) {
         }
         const quoteDayInfo = APP.getRef('quoteDayInfo');
         const itemQuote = quoteDayInfo.value.find((el: QueryQuoteDayRsp) => {
-            const goodcode = el.refgoodscode || el.goodscode
+            // const goodcode = el.refgoodscode || el.goodscode
             // console.log(el.goodscode, el.refgoodscode, goodsQuoteTik.goodscode)
-            return goodcode === goodsQuoteTik.goodscode
+            return el.goodscode === goodsQuoteTik.goodscode
         });
         if (itemQuote) {
             const goods = getGoodsByCode(itemQuote.goodscode);

+ 1 - 1
src/views/order/commodity_contract/components/commodity_contract_summary/index.vue

@@ -33,7 +33,7 @@
       </template>
       <!-- 持仓盈亏 -->
       <template #profitloss="{ record }">
-        <span>{{ record.averageprice ? useProfitloss(record, findGoodsCode(record.goodsid, record.goodscode, swapList)) : '--' }}</span>
+        <span>{{ record.averageprice ? useProfitloss(record) : '--' }}</span>
       </template>
       <template #buyorsell="{ record }">
         <span>{{ getBuyOrSellName(record.buyorsell) }}</span>