From c61f03cfe1fcf023c7128f77f3d692aef309f77f Mon Sep 17 00:00:00 2001
From: peng <peng.com>
Date: 星期四, 30 十月 2025 14:59:59 +0800
Subject: [PATCH] 页面优化
---
pages/order/fillorder.vue | 66 ++++++++++++++++++++++++++++----
1 files changed, 57 insertions(+), 9 deletions(-)
diff --git a/pages/order/fillorder.vue b/pages/order/fillorder.vue
index d22f3d7..fe2921f 100644
--- a/pages/order/fillorder.vue
+++ b/pages/order/fillorder.vue
@@ -148,6 +148,11 @@
"
:span="3"
>
+<!-- <video v-if="val.goodsSku.goodsVideo" :src="val.goodsSku.goodsVideo"
+ style="width: 200rpx;height: 200rpx;border-radius: 10rpx;"
+ :initial-time="0"
+ :controls="false" object-fit="contain" :show-play-btn="false" :show-center-play-btn="false"
+ ></video> -->
<u-image
borderRadius="10rpx"
width="200rpx"
@@ -379,9 +384,10 @@
<div class="tabbar-right">鎻愪氦璁㈠崟</div>
<!-- #endif -->
<!-- #ifdef MP-WEIXIN -->
- <div class="tabbar-right">寰俊鏀粯</div>
+ <div class="tabbar-right">绔嬪嵆鏀粯</div>
<!-- #endif -->
</div>
+
</div>
</div>
</template>
@@ -394,9 +400,12 @@
import LiLiWXPay from "@/js_sdk/lili-pay/wx-pay.js";
import invoices from "@/pages/order/invoice/setInvoice";
import { mapState } from "vuex";
+import { getSessionId, userAction } from "@/api/userAction.js";
export default {
onLoad: function (val) {
this.routerVal = val;
+ this.actionParam.pageParams = JSON.stringify(val)
+ console.log('鑾峰彇鐨勫弬鏁�-----------銆�',JSON.stringify(decodeURIComponent(this.routerVal.template)))
},
components: {
invoices,
@@ -448,6 +457,17 @@
storeAddress: "",
originOrderData:"", // 鍘熷璁㈠崟鏁版嵁
+ pageSessionNo:"",
+ sendOnShow:false,
+ actionParam:{
+ sessionId:'',
+ actionType:"PAGE",
+ joinType:"SELF",
+ pageCode:"FILL_ORDER",
+ pageParams:"{}",
+ pageStatus:"JOIN",
+ pageType:"DETAIL"
+ }
};
},
watch: {
@@ -510,8 +530,28 @@
return true; //闃绘榛樿杩斿洖琛屼负
}
},
-
+ onUnload() {
+ let param = Object.assign({}, this.actionParam);
+ if (this.sendOnShow)return
+ param.pageStatus = "LEAVE"
+ userAction(param)
+ },
+ onHide() {
+ this.startHidenTime = Date.now()
+ let param = Object.assign({}, this.actionParam);
+ this.sendOnShow = true;
+ param.pageStatus = "LEAVE"
+ userAction(param)
+ },
async onShow() {
+ getSessionId().then(res=>{
+ this.pageSessionNo = res.data.data
+ this.actionParam.sessionId = this.pageSessionNo
+ if(this.pageSessionNo){
+ let param = Object.assign({}, this.actionParam);
+ userAction(param)
+ }
+ })
// 鍒ゆ柇鏄惁瀛樺湪鍐欒繃澶囨敞淇℃伅鐨勫晢鍝�
if (this.remark && this.remark.length > 0) {
this.remarkFlag = true;
@@ -535,6 +575,7 @@
mounted() {},
methods: {
+
//鍙戠エ鍥炶皟 閫夋嫨鍙戠エ涔嬪悗鍒锋柊璐墿杞�
async callbackInvoice(val) {
this.invoiceFlag = false;
@@ -699,22 +740,29 @@
duration: 2000,
icon: "none",
});
+ debugger;
+ console.log('--------------缁戝畾妯℃澘------------------>',decodeURIComponent(this.routerVal.template))
+ //鍒ゆ柇濡傛灉鏈塼emplate閭d箞灏辩洿鎺ユ牴鎹畉rade鐨剆n缂栧彿鍘诲皢璁㈠崟涓庢ā鏉跨粦瀹�
+ if(this.routerVal.template){
+ let parms = {};
+ const template = JSON.parse(decodeURIComponent(this.routerVal.template))
+ parms.sn = res.data.result.sn;
+ parms.templateId = template.templateId;
+ parms.templateName = template.templateName;
+ parms.chooseImage = template.chooseImage;
+ parms.chooseImageId = template.chooseImageId;
+ parms.templateForm = template.templateForm;
+ API_Trade.bindingTemplate(parms)
+ }
// 濡傛灉褰撳墠浠锋牸涓�0璺宠浆鍒拌鍗曞垪琛�
if (this.orderMessage.priceDetailDTO.billPrice == 0) {
uni.navigateTo({
url: "/pages/order/myOrder?status=0",
});
} else {
- // #ifdef MP-WEIXIN
- // 寰俊灏忕▼搴忎腑鐐瑰嚮鍒涘缓璁㈠崟鐩存帴寮�濮嬫敮浠�
- this.pay(res.data.result.sn);
- // #endif
-
- // #ifndef MP-WEIXIN
this.navigateTo(
`/pages/cart/payment/payOrder?trade_sn=${res.data.result.sn}`
);
- // #endif
}
} else {
uni.showToast({
--
Gitblit v1.8.0