Handy_Cao vor 1 Jahr
Ursprung
Commit
00fd6af7ab

+ 1 - 1
public/locales/en-US.json

@@ -1365,7 +1365,7 @@
             "tips4": "Offline notification",
             "tips5": "The account has been logged out",
             "tips6": "Switching language changes require a re-login to take effect!",
-            "tips7": "Dear user: Hello, please pay the full amount for your pre-order before 04:00 on Saturday to ensure shipment, otherwise our platform will cancel the pre-order according to the agreement."
+            "tips7": "Dear user: Hello, please pay the full amount for your pre-order before 04:00 on Saturday to ensure shipment, otherwise our platform will cancel the pre-order according to the agreement."
         },
         "register": {
             "title": "User Register",

+ 17 - 8
src/packages/mobile/views/pricing/trade/Index.vue

@@ -144,14 +144,14 @@
             </template>
         </Tabs>
         <template #footer>
-            <component ref="componentRef" :is="componentMap.get(componentId)" v-bind="{ goodsCode, goodsid }"
+            <component ref="componentRef" :is="componentMap.get(componentId)" v-bind="{ goodsCode, goodsid, selectedRow }"
             @closed="closeComponent" v-if="componentId" />
         </template> 
     </app-view>
 </template>
 
 <script lang="ts" setup>
-import { useFuturesStore, usePositionStore, useUserStore, i18n } from '@/stores'
+import { useFuturesStore, useUserStore, i18n } from '@/stores'
 import { useNavigation } from '@mobile/router/navigation'
 import { shallowRef, onMounted, computed, defineAsyncComponent } from 'vue'
 import { Form, Field, Button, FieldRule, FormInstance, Radio, RadioGroup, CellGroup, Icon, Tab, Tabs } from 'vant'
@@ -159,7 +159,7 @@ import { useOrder } from '@/business/trade'
 import { BuyOrSell, getBuyOrSellList, BuildType, getPricemode2List, PriceMode } from '@/constants/order'
 import { useComponent } from '@/hooks/component'
 import { fullloading, dialog } from '@/utils/vant'
-import { formatDecimal, handleNumberValue, handleRequestBigNumber } from '@/filters'
+import { formatDecimal, handleNumberValue } from '@/filters'
 // import service from '@/services'
 import Stepper from '@mobile/components/base/stepper/index.vue'
 import eventBus from '@/services/bus'
@@ -180,11 +180,13 @@ const quoteminunit = quote.value?.quoteminunit ?? 1.0
 const decimalvalue = Math.pow(10.0, -decimalplace)*(quoteminunit == 0 ? 1 : quoteminunit)
 const isTrademode16 = computed(() => quote.value?.trademode === 16)
 
+const selectedRow = shallowRef<Model.SBYJMyOrderRsp>()
+
 const { getSystemParamValue } = useUserStore()
 const system_1012 = getSystemParamValue('1012') ?? '1'
 
 // const accountStore = useAccountStore()
-const positionStore = usePositionStore()
+// const positionStore = usePositionStore()
 
 const { formData, formSubmit } = useOrder()
 const formRef = shallowRef<FormInstance>()
@@ -201,9 +203,14 @@ const position = shallowRef<Model.TradePositionRsp[]>([])
 // const oem = service.getConfig('oem')
 
 // 点击返回
-const itemBack = (isPosition: number, buyorsell: BuyOrSell, tradeId: string) => {
+const itemBack = (isPosition: number, buyorsell: BuyOrSell, tradeId: string, item: Model.SBYJMyOrderRsp) => {
     formData.BuyOrSell = buyorsell === BuyOrSell.Buy ? BuyOrSell.Sell : BuyOrSell.Buy
-    if (isPosition === 2) { formData.RelatedID = handleRequestBigNumber(tradeId)}
+    if (isPosition === 2) { 
+        // formData.RelatedID = handleRequestBigNumber(tradeId)
+        selectedRow.value = item
+        // 打开退订
+        openComponent('transfer')
+    }
 }
 
 const { componentRef, componentId, openComponent, closeComponent } = useComponent()
@@ -229,10 +236,12 @@ const components = [{
     name: 'holdlb2',
     title: t('pcroute.bottom.bottom_pricing_detail2'),
     component: defineAsyncComponent(() => import('../trade/holdlb2/Index.vue')),
+    detail: defineAsyncComponent(() => import('@mobile/views/order/position/components/pricing/detail2/Index.vue')),
 }]
     
 const componentMap = new Map<string, unknown>([
     ['detail', defineAsyncComponent(() => import('./components/detail/Index.vue'))],
+    ['transfer', defineAsyncComponent(() => import('@mobile/views/order/position/components/pricing/detail2/components/transfer/Index.vue'))]
 ])
 
 // // const sl = shallowRef(false) // 止损
@@ -272,9 +281,9 @@ const marketPrice = computed(() => {
 })
 
 // 买方向持仓数量
-const buyQty = computed(() => positionStore.getOrderQty(BuyOrSell.Buy, goodsCode))
+// const buyQty = computed(() => positionStore.getOrderQty(BuyOrSell.Buy, goodsCode))
 // 卖方向持仓数量
-const sellQty = computed(() => positionStore.getOrderQty(BuyOrSell.Sell, goodsCode))
+// const sellQty = computed(() => positionStore.getOrderQty(BuyOrSell.Sell, goodsCode))
 
 // 表单验证规则
 const formRules: { [key in keyof Proto.OrderReq]?: FieldRule[] } = {

+ 2 - 2
src/packages/mobile/views/pricing/trade/holdlb2/Index.vue

@@ -1,6 +1,6 @@
 <!-- 我的持仓-明细 -->
 <template>
-    <app-pull-refresh ref="pullRefreshRef" v-model:loading="loading" v-model:error="error" @refresh="run">
+    <app-pull-refresh ref="pullRefreshRef" v-model:loading="loading" v-model:error="error">
         <div class="g-order-list">
             <div class="g-order-list__box" v-for="(item, index) in dataList" :key="index">
                 <div class="g-order-list__titlebar">
@@ -95,7 +95,7 @@ const pullRefreshRef = shallowRef()
 
 const emit = defineEmits(['callBack'])
 const callBack = (item: Model.SBYJMyOrderRsp) => {
-    emit('callBack', 2, item.tHDetailEx.buyOrSell, item.tHDetailEx.tradeID)
+    emit('callBack', 2, item.tHDetailEx.buyOrSell, item.tHDetailEx.tradeID, item)
 }
 
 // 可用重量

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

@@ -102,7 +102,7 @@ const formRef = shallowRef<FormInstance>()
 // 数量步长列表
 const qtyStepList = computed(() => {
     const system_1009 = Number(getSystemParamValue('1009')) ?? 1
-    return [1*system_1009, 10*system_1009, 100*system_1009]
+    return [1*system_1009, 5*system_1009, 10*system_1009]
 }) 
 const qtyStep = shallowRef(qtyStepList.value[0]) // 数量步长
 const { t } = i18n.global