qlg.tsgz.moe/static/app2/js/shop_indent.js
2020-06-10 13:23:50 +08:00

44 lines
1.1 KiB
JavaScript
Executable File

mui.init({
beforeback: function() { //获得父页面的webview
var list = plus.webview.currentWebview().opener(); //触发父页面的自定义事件(refresh),从而进行刷新
mui.fire(list, 'reload');
//返回true,继续页面关闭逻辑
return true;
}
})
mui.plusReady(function() {
var self = plus.webview.currentWebview();
//console.log(self);
var shopId=self.shopId;
var data_href = self.data_href;
if(data_href == 'all') {
$('.title').html('全部订单');
}
if(data_href == 'waitPay') {
$('.title').html('待付款');
}
if(data_href == 'waitDeliver') {
$('.title').html('待发货');
}
if(data_href == 'waitReceive') {
$('.title').html('待收货');
}
if(data_href == 'waitConfirm') {
$('.title').html('待确认');
}
if(data_href == 'abnormal') {
$('.title').html('退款/售后');
}
localStorage.setItem('shop_order_class', data_href);
var bSize = 64 + (+localStorage.getItem('ipxSizeTop')) + 'px';
var sub = plus.webview.create('shop_indentcon.html', data_href, {
top: bSize,
bottom: '0px',
scrollIndicator: 'none',
},{ shopId:shopId});
self.append(sub);
})