From f1d0c08bbef3ffef0b9bbd0c181d2047c9866a7f Mon Sep 17 00:00:00 2001
From: peng <peng.com>
Date: 星期六, 11 十月 2025 14:42:40 +0800
Subject: [PATCH] 定制模板
---
pages/order/fillorder.vue | 38 ++++++++++++++++++++++++++++++++++++--
1 files changed, 36 insertions(+), 2 deletions(-)
diff --git a/pages/order/fillorder.vue b/pages/order/fillorder.vue
index 667add2..1edb5df 100644
--- a/pages/order/fillorder.vue
+++ b/pages/order/fillorder.vue
@@ -400,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,
@@ -454,6 +457,17 @@
storeAddress: "",
originOrderData:"", // 鍘熷璁㈠崟鏁版嵁
+ pageSessionNo:"",
+ sendOnShow:false,
+ actionParam:{
+ sessionId:'',
+ actionType:"PAGE",
+ joinType:"SELF",
+ pageCode:"FILL_ORDER",
+ pageParams:"{}",
+ pageStatus:"JOIN",
+ pageType:"DETAIL"
+ }
};
},
watch: {
@@ -516,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;
@@ -713,7 +747,7 @@
});
} else {
this.navigateTo(
- `/pages/cart/payment/payOrder?trade_sn=${res.data.result.sn}`
+ `/pages/cart/payment/payOrder?trade_sn=${res.data.result.sn}&template=${this.routerVal.template}`
);
}
} else {
--
Gitblit v1.8.0