li.shaoyi 2 lat temu
rodzic
commit
b3239c369c

+ 2 - 2
src/packages/mobile/views/boot/index.vue

@@ -15,7 +15,7 @@
 </template>
 
 <script lang="ts" setup>
-import { reactive } from 'vue'
+import { reactive,onUnmounted } from 'vue'
 import { useRoute, useRouter } from 'vue-router'
 import { Swipe, SwipeItem } from 'vant'
 import { showLoading, dialog } from '@/utils/vant'
@@ -57,7 +57,6 @@ const skip = (promise: Promise<void>) => {
   const toast = logining.value ? showLoading() : undefined
 
   promise.then(() => {
-    plus.exitFullSreen()
     localStorage.setItem('thj_app_showguide', 'false')
     const redirect = route.query.redirect
     if (redirect) {
@@ -91,6 +90,7 @@ const tryInit = (message: string) => {
 }
 
 plus.setFullSreen()
+onUnmounted(() => plus.exitFullSreen())
 </script>
 
 <style lang="less" scoped>

+ 1 - 1
src/packages/mobile/views/mine/order/detail/purchasetrade/components/transfer/index.less

@@ -11,7 +11,7 @@
         }
 
         .van-field__label {
-            width: 2.2rem;
+            width: 2.4rem;
         }
     }
 }

+ 10 - 16
src/packages/mobile/views/mine/order/detail/purchasetrade/index.vue

@@ -36,25 +36,19 @@
             </CellGroup>
             <CellGroup title="点价信息"
                 v-if="detail.pointflag && (detail.buyuserid === detail.firstbuyuserid || ['2', '3'].includes(type.toString()))">
-                <Cell title="已点价格" :value="detail.pointprice + '元/吨'" />
-                <Cell title="点收益" :value="detail.pointincome + '元'" />
+                <Cell title="今日点价收益" :value="detail.todaypointincome + '元'" />
+                <Cell title="点价总收益" :value="detail.pointincome + '元'" />
             </CellGroup>
         </div>
         <div v-else>
             <Empty />
         </div>
         <template #footer>
-            <div class="g-form__footer" v-if="detail">
-                <!-- 参数类型为 2 时只显示点价按钮 -->
-                <template v-if="type.toString() === '2'">
-                    <Button :class="spotgoods?.priceflag ? '' : 'van-button--disabled'" block round type="primary"
-                        v-if="detail.buyuserid === detail.firstbuyuserid && detail.availabletime > 0 && detail.presalestatus === 2 && detail.orderstatus === 1"
-                        @click="spotPricingSubmit">点价</Button>
-                </template>
-                <template v-else-if="type.toString() !== '3'">
-                    <Button :class="spotgoods?.priceflag ? '' : 'van-button--disabled'" block round type="primary"
-                        v-if="detail.buyuserid === detail.firstbuyuserid && detail.availabletime > 0 && detail.presalestatus === 2 && detail.orderstatus === 1"
-                        @click="spotPricingSubmit">点价</Button>
+            <div class="g-form__footer" v-if="detail && type.toString() !== '3'">
+                <Button :class="spotgoods?.priceflag ? '' : 'van-button--disabled'" block round type="primary"
+                    v-if="detail.buyuserid === detail.firstbuyuserid && detail.availabletime > 0 && detail.presalestatus === 2 && detail.orderstatus === 1"
+                    @click="spotPricingSubmit">点价</Button>
+                <template v-if="type.toString() !== '2'">
                     <Button block round type="primary"
                         v-if="detail.thjdeliverymode === 1 && detail.presalestatus === 2 && detail.orderstatus === 1"
                         @click="openComponent('transfer')">合同转让</Button>
@@ -123,10 +117,10 @@ const { data: spotgoods } = useRequest(querySpotgoodsPrice, {
 // 确认点价
 const spotPricingSubmit = () => {
     const { availabletime = 0, pointtimes = 0 } = detail.value ?? {}
-    const { priceflag, wrstandardname, spotgoodsprice = 0 } = spotgoods.value ?? {}
+    const { priceflag, ystspotgoodsprice, todayspotgoodsprice, diffprice } = spotgoods.value ?? {}
 
     if (priceflag) {
-        let message = `${wrstandardname}当前现货价为${spotgoodsprice},是否点价?\n`
+        let message = `今日差价${diffprice}(昨结${ystspotgoodsprice},今开${todayspotgoodsprice}),是否点价?\n`
         message += `<span style="color:red;">剩余点价次数${availabletime}/${pointtimes}</span>`
 
         dialog({
@@ -146,7 +140,7 @@ const spotPricingSubmit = () => {
             })
         })
     } else {
-        dialog('河钢招标价未公布或当前订单价格低于下单价格')
+        dialog('价格未公布或当前差价不大于0')
     }
 }
 

+ 1 - 1
src/packages/mobile/views/purchase/detail/index.less

@@ -40,7 +40,7 @@
         }
 
         .van-field__label {
-            width: 2.2rem;
+            width: 2.4rem;
         }
     }
 

+ 4 - 0
src/types/model/market.d.ts

@@ -30,14 +30,18 @@ declare namespace Model {
 
     /** 查询行情-现货列表 响应 */
     interface SpotgoodsPriceRsp {
+        diffprice: number; // 差价
         prespotgoodsprice: number; // 上日价格
         priceflag: number; // 点价标识(1:为可点价-本月招标价已发布,否则为0)
         spotgoodsprice: number; // 当前价格
         spotgoodsqty: number; // 招标量
+        todayspotgoodsprice: number; // 今开价格
         tradedate: string; // 交易日(yyyyMMdd)
+        tradedate2: string; // 交易日-期货(yyyyMMdd)
         wrstandardcode: string; // 现货商品代码
         wrstandardid: number; // 现货商品ID(通用则为0)
         wrstandardname: string; // 现货商品名称
+        ystspotgoodsprice: number; // 昨结价格
     }
 
     /** 期货行情 */

+ 1 - 0
src/types/model/order.d.ts

@@ -321,6 +321,7 @@ declare namespace Model {
         thjdeliverymodedisplay: string
         /// 状态
         thjorderstatusdisplay: string
+        todaypointincome: number
         /// 摘牌总货款
         tradeamount: number
         /// 交易日(yyyyMMdd)