You've already forked qlg.frontend
展示商户收款详情
This commit is contained in:
@ -1,8 +1,8 @@
|
||||
var is_app = 1;
|
||||
// var imgUrl = 'http://img.zgqlg.com.cn/';
|
||||
var imgUrl = 'http://img.zgqlg.com.cn/';
|
||||
// var webUrl = 'http://www.zgqlg.com.cn/';
|
||||
// var webUrl1 = 'http://www.zgqlg.com.cn/';
|
||||
var imgUrl = 'http://qlg.qgmzbxs.com/';
|
||||
// var imgUrl = 'http://qlg.qgmzbxs.com/';
|
||||
var webUrl = 'http://qlg.qgmzbxs.com/';
|
||||
var webUrl1 = 'http://qlg.qgmzbxs.com/';
|
||||
var cssUrl = localStorage.getItem("cssUrl");
|
||||
|
@ -3,6 +3,17 @@ var wxChannel = null; // 微信支付
|
||||
var aliChannel = null; // 支付宝支付
|
||||
var channel = null; //支付通道
|
||||
mui.init();
|
||||
|
||||
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("复制成功");
|
||||
}
|
||||
|
||||
let payPics = [];
|
||||
|
||||
mui.plusReady(function() {
|
||||
var self = plus.webview.currentWebview();
|
||||
from_id = self.from?self.from:1
|
||||
@ -49,6 +60,9 @@ mui.plusReady(function() {
|
||||
}
|
||||
});
|
||||
});
|
||||
$("#shopRecieveInfo")
|
||||
.on('click', '.copy_name', function(){copyToClip($("#shopRecieveInfo > ._name").text())})
|
||||
.on('click', '.copy_card', function(){copyToClip($("#shopRecieveInfo > ._card").text())});
|
||||
|
||||
$('.con').on('tap', '.address', function() {
|
||||
var addressId = $(this).attr('data-addressId');
|
||||
@ -158,6 +172,18 @@ mui.plusReady(function() {
|
||||
var couponIds = [];
|
||||
var areaId2 = '';
|
||||
// //console.log(type)
|
||||
$("#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'
|
||||
});
|
||||
});
|
||||
|
||||
mui.ajax(qlgUrl('app/carts/settlement'), {
|
||||
data: {
|
||||
@ -607,13 +633,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) {
|
||||
|
@ -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) {
|
||||
|
@ -158,7 +158,7 @@ const app = new Vue({
|
||||
Math.cos(radLat1)*Math.cos(radLat2)*Math.pow(Math.sin(b/2),2)));
|
||||
s = s *6378.137 ;// EARTH_RADIUS;
|
||||
if (s < 1.5) {
|
||||
return `${s * 1000}m`;
|
||||
return `${(s * 1000).toFixed(2)}m`;
|
||||
}
|
||||
if (s > 50) {
|
||||
return `>50km`;
|
||||
|
Reference in New Issue
Block a user