You've already forked qlg.frontend
展示商户收款详情
This commit is contained in:
@ -34,12 +34,29 @@ mui.init({
|
||||
});
|
||||
var count = 1;
|
||||
|
||||
setInterval(function() {
|
||||
var pr = mui('#pullrefresh').pullRefresh();
|
||||
if ($("#qlg_pay_pwd").is(":visible")) {
|
||||
if (!pr.stopped) mui('#pullrefresh').pullRefresh().setStopped(!pr.stopped);
|
||||
} else {
|
||||
if (pr.stopped) mui('#pullrefresh').pullRefresh().setStopped(!pr.stopped);
|
||||
}
|
||||
}, 1000)
|
||||
|
||||
function pullupRefresh() {
|
||||
count += 1;
|
||||
getData(count);
|
||||
mui('#pullrefresh').pullRefresh().endPullupToRefresh();
|
||||
}
|
||||
|
||||
function copyToClip (text) {
|
||||
var Context = plus.android.importClass("android.content.Context");
|
||||
var main = plus.android.runtimeMainActivity();
|
||||
var clip = main.getSystemService(Context.CLIPBOARD_SERVICE);
|
||||
plus.android.invoke(clip,"setText",text.toString());
|
||||
mui.toast("复制成功");
|
||||
}
|
||||
|
||||
/**
|
||||
* 下拉刷新具体业务实现
|
||||
*/
|
||||
@ -131,6 +148,9 @@ function getData(page) {
|
||||
isLoad = false;
|
||||
})
|
||||
}
|
||||
|
||||
let payPics = [];
|
||||
|
||||
mui.plusReady(function() {
|
||||
|
||||
// window.addEventListener('refresh', function(e) { //执行刷新
|
||||
@ -141,7 +161,18 @@ mui.plusReady(function() {
|
||||
order_class = '';
|
||||
}
|
||||
getData(count);
|
||||
|
||||
$("#shopRecieveInfo")
|
||||
.on('click', '.copy_name', function(){copyToClip($("#shopRecieveInfo > ._name").text())})
|
||||
.on('click', '.copy_card', function(){copyToClip($("#shopRecieveInfo > ._card").text())})
|
||||
.on('click', 'img', function(){
|
||||
var index = $(this).parent().index();
|
||||
if (payPics.length < index) return;
|
||||
plus.nativeUI.previewImage(payPics, {
|
||||
current: index,
|
||||
loop: true,
|
||||
indicator: 'number'
|
||||
});
|
||||
});
|
||||
//支付插件
|
||||
plus.payment.getChannels(function(channels) {
|
||||
for (var i in channels) {
|
||||
@ -373,13 +404,28 @@ mui.plusReady(function() {
|
||||
// //console.log(JSON.stringify(data))
|
||||
if (data.status == 1) {
|
||||
$('.pay').css('display', 'none');
|
||||
$('#qlg_pay_pwd').css('display', 'block');
|
||||
$('#qlg_pay_pwd').css('display', 'flex');
|
||||
if (data.data.payPwd == '0') {
|
||||
mui.alert('还未设置支付密码请先设置操作密码!');
|
||||
var url = 'setting_fogetPayPwd';
|
||||
JZL.openWindow(url + '.html', url + '.html');
|
||||
//return;
|
||||
}
|
||||
if (!$.isEmptyObject(data.data.shopPaymentInfo)) {
|
||||
payPics = [
|
||||
hyhImgUrl(data.data.shopPaymentInfo.alipayRecive),
|
||||
hyhImgUrl(data.data.shopPaymentInfo.wechatRecive),
|
||||
];
|
||||
$("#shopRecieveInfo").show()
|
||||
.find("._shortBankName").text(data.data.shopPaymentInfo.bankName).end()
|
||||
.find("._card").text(data.data.shopPaymentInfo.bankNo).end()
|
||||
.find("._name").text(data.data.shopPaymentInfo.realname).end()
|
||||
.find("._alipay > img").attr("src", hyhImgUrl(data.data.shopPaymentInfo.alipayRecive)).end()
|
||||
.find("._wechat > img").attr("src", hyhImgUrl(data.data.shopPaymentInfo.wechatRecive)).end();
|
||||
} else {
|
||||
payPics = [];
|
||||
$("#shopRecieveInfo").hide();
|
||||
}
|
||||
$('#totalMoney').html('付款总额:¥<o>' + data.data.needPay + '</o>');
|
||||
$('#productNum').val(data.data.product.useProduct);
|
||||
if (data.data.product.useProduct > 0) {
|
||||
|
Reference in New Issue
Block a user