| | |
| | | import '@/components/uview-components/uview-ui' |
| | | import * as API_Trade from "@/api/trade"; |
| | | import {payCallback} from '@/api/members' |
| | | import { getSessionId, userAction } from "@/api/userAction.js"; |
| | | export default { |
| | | data() { |
| | | return { |
| | |
| | | walletValue: 0.0, |
| | | // 支付倒计时 |
| | | autoCancel: 0, |
| | | pageSessionNo:"", |
| | | actionParam:{ |
| | | sessionId:'', |
| | | actionType:"PAGE", |
| | | joinType:"SELF", |
| | | pageCode:"PAY_ORDER", |
| | | pageParams:"{}", |
| | | pageStatus:"JOIN", |
| | | pageType:"DETAIL" |
| | | } |
| | | |
| | | }; |
| | | }, |
| | | onUnload() { |
| | | let param = this.actionParam; |
| | | if (this.sendOnShow)return |
| | | param.pageStatus = "LEAVE" |
| | | userAction(param) |
| | | }, |
| | | onHide() { |
| | | this.startHidenTime = Date.now() |
| | | let param = this.actionParam; |
| | | this.sendOnShow = true; |
| | | param.pageStatus = "LEAVE" |
| | | userAction(param) |
| | | }, |
| | | onShow() { |
| | | getSessionId().then(res=>{ |
| | | this.pageSessionNo = res.data.data |
| | | if(this.pageSessionNo){ |
| | | let param = this.actionParam; |
| | | param.sessionId = this.pageSessionNo |
| | | userAction(param) |
| | | } |
| | | }) |
| | | }, |
| | | onLoad(val) { |
| | | this.routerVal = val; |
| | | |
| | | this.actionParam.pageParams = JSON.stringify(val) |
| | | //初始化参数 |
| | | // #ifdef APP-PLUS |
| | | this.paymentType = "APP"; |