no message

This commit is contained in:
小陌 2024-03-20 18:16:30 +08:00
parent 6fe05463fa
commit edc6a1df50
8 changed files with 106 additions and 81 deletions

View File

@ -11,7 +11,7 @@ Page({
}, { }, {
img: "video", img: "video",
name: "洗车教程", name: "洗车教程",
url: "webview/webview?url=https://jm.v0750.com/video", url: "webview/webview?url=https://jmqf.v0750.com/video",
needlogin: !1 needlogin: !1
}, { }, {
img: "xichequan", img: "xichequan",
@ -121,7 +121,7 @@ Page({
success: function(i) { success: function(i) {
console.log(i), wx.showLoading({ console.log(i), wx.showLoading({
title: "" title: ""
}), e.globalData.qrcode = i.result, t.request("https://jm.v0750.com/miniprogram/identify", i, !0).then(function(t) { }), e.globalData.qrcode = i.result, t.request("https://jmqf.v0750.com/miniprogram/identify", i, !0).then(function(t) {
console.log("data", t), wx.hideLoading(), e.globalData.devicecode = t.data.devicecode || e.globalData.devicecode, console.log("data", t), wx.hideLoading(), e.globalData.devicecode = t.data.devicecode || e.globalData.devicecode,
a.setData({ a.setData({
isScan: !!t.data.devicecode isScan: !!t.data.devicecode
@ -193,7 +193,7 @@ Page({
wx.requestSubscribeMessage({ wx.requestSubscribeMessage({
tmplIds: this.data.tmplIds, tmplIds: this.data.tmplIds,
success: function(e) { success: function(e) {
console.log("requestSubscribeMessage", e), t.request("https://jm.v0750.com/miniprogram/index/newtmpl", e, !0).then(function(e) {}).catch(function(e) {}); console.log("requestSubscribeMessage", e), t.request("https://jmqf.v0750.com/miniprogram/index/newtmpl", e, !0).then(function(e) {}).catch(function(e) {});
}, },
fail: function(e) { fail: function(e) {
console.log("requestSubscribeMessagefail", e); console.log("requestSubscribeMessagefail", e);

View File

@ -3,7 +3,7 @@ var e = getApp(), o = require("../../utils/login.js");
Page({ Page({
data: { data: {
logs: [], logs: [],
isnotInfo: 1 isnotInfo: 2
}, },
fromPage: "", fromPage: "",
onLoad: function(e) { onLoad: function(e) {
@ -20,7 +20,7 @@ Page({
"getUserInfo:ok" == e.detail.errMsg ? (this.setData({ "getUserInfo:ok" == e.detail.errMsg ? (this.setData({
isnotInfo: 2 isnotInfo: 2
}), this.userInfo = e.detail) : wx.redirectTo({ }), this.userInfo = e.detail) : wx.redirectTo({
url: "/pages/register/register" url: "/pages/login/login"
}); });
}, },
userInfo: {}, userInfo: {},
@ -53,7 +53,7 @@ Page({
} }
}), !1; }), !1;
wx.redirectTo({ wx.redirectTo({
url: "/pages/register/register" url: "/pages/login/login"
}); });
} }
}); });

View File

@ -90,7 +90,7 @@ Page({
wx.hideLoading(), 200 == e.code ? (e.data.list.forEach(function(t, e) { wx.hideLoading(), 200 == e.code ? (e.data.list.forEach(function(t, e) {
t.id = e, t.width = 32, t.height = 32, t.latitude = 1 * t.latitude, t.longitude = 1 * t.longitude, t.id = e, t.width = 32, t.height = 32, t.latitude = 1 * t.latitude, t.longitude = 1 * t.longitude,
t.iconPath = "/img/location-blue.png", t.callout = { t.iconPath = "/img/location-blue.png", t.callout = {
content: t.t_name content: t.name
}; };
}), t.setData({ }), t.setData({
weather: e.data.weather, weather: e.data.weather,
@ -157,7 +157,7 @@ Page({
wx.openLocation({ wx.openLocation({
latitude: this.data.shop.latitude, latitude: this.data.shop.latitude,
longitude: this.data.shop.longitude, longitude: this.data.shop.longitude,
name: this.data.shop.t_name, name: this.data.shop.name,
address: this.data.shop.address address: this.data.shop.address
}); });
} }

View File

@ -23,7 +23,7 @@
</cover-view> </cover-view>
</cover-view> </cover-view>
<cover-view class="{{showshop?'showshop shop':'shop'}}"> <cover-view class="{{showshop?'showshop shop':'shop'}}">
<cover-view class="name">{{shop.t_name}}</cover-view> <cover-view class="name">{{shop.name}}</cover-view>
<cover-view class="border"></cover-view> <cover-view class="border"></cover-view>
<cover-view class="add"> <cover-view class="add">
<cover-view class="l"> <cover-view class="l">

View File

@ -17,27 +17,27 @@ Page({
showTips: !1, showTips: !1,
approve: !0 approve: !0
}, },
onLoad: function(a) { onLoad: function (a) {
var i = this; var i = this;
e.pageStart(t).then(function(e) { e.pageStart(t).then(function (e) {
i.getList(), i.setData({ i.getList(), i.setData({
servicetel: t.globalData.servicetel servicetel: t.globalData.servicetel
}); });
}); });
}, },
onShow: function(e) { onShow: function (e) {
t.globalData.isneedUpload && (this.getList(), t.globalData.isneedUpload = !1); t.globalData.isneedUpload && (this.getList(), t.globalData.isneedUpload = !1);
}, },
onPullDownRefresh: function() { onPullDownRefresh: function () {
this.setData({ this.setData({
list: [] list: []
}), this.getList(); }), this.getList();
}, },
onReachBottom: function() { onReachBottom: function () {
this.getList(); this.getList();
}, },
onShareAppMessage: function() {}, onShareAppMessage: function () { },
getList: function() { getList: function () {
var a = this; var a = this;
if (this.data.loading) return !1; if (this.data.loading) return !1;
this.setData({ this.setData({
@ -46,7 +46,7 @@ Page({
title: "" title: ""
}), e.request(t.globalData.config.recharge.init, { }), e.request(t.globalData.config.recharge.init, {
page: this.data.page.next_page page: this.data.page.next_page
}, !0).then(function(t) { }, !0).then(function (t) {
if (wx.hideLoading(), a.setData({ if (wx.hideLoading(), a.setData({
loading: !1 loading: !1
}), 200 != t.code) return wx.showModal({ }), 200 != t.code) return wx.showModal({
@ -59,47 +59,60 @@ Page({
user: t.data.user, user: t.data.user,
protocol: t.data.protocol, protocol: t.data.protocol,
tips: t.data.tips.split("\n") tips: t.data.tips.split("\n")
}, function() {}); }, function () { });
}).catch(function(t) { }).catch(function (t) {
wx.hideLoading(); wx.hideLoading();
}); });
}, },
tobuy: function(a) { tobuy: function (a) {
var i = a.currentTarget.dataset.id; var i = a.currentTarget.dataset.id;
console.log(i), wx.showLoading({ wx.showLoading({
title: "" title: ""
}), e.request(t.globalData.config.recharge.create, { }), e.request(t.globalData.config.recharge.create, {
id: i id: i
}, !0).then(function(t) { }, !0).then(function (t) {
if (wx.hideLoading(), 200 != t.code) return wx.showModal({ if (wx.hideLoading(), 200 != t.code) return wx.showModal({
title: "提示", title: "提示",
content: t.message content: t.message
}), !1; }), !1;
var e = t.data.result; var e = t.data.result;
console.log('tobuy', e, t);
wx.requestPayment({ wx.requestPayment({
timeStamp: e.timestamp, timeStamp: e.timeStamp,
nonceStr: e.nonceStr, nonceStr: e.nonceStr,
package: e.package, package: e.package,
signType: e.signType, signType: e.signType,
paySign: e.paySign, paySign: e.paySign,
success: function(t) { success: function (t) {
// 加载回调接口
e.request(t.data.notify_url, {
orderid: t.data.orderid
}, !0).then(function (t) {
console.log('pay_success', t);
}).catch(function (t) {
console.log('pay_success', t);
});
getCurrentPages().length > 1 ? wx.navigateBack({}) : wx.redirectTo({ getCurrentPages().length > 1 ? wx.navigateBack({}) : wx.redirectTo({
url: "/pages/index/index" url: "/pages/index/index"
}); });
} }
}); });
}).catch(function(t) { }).catch(function (t) {
wx.hideLoading(); wx.hideLoading();
}); });
}, },
selectItem: function(t) { selectItem: function (t) {
var e = t.currentTarget.dataset.id; var e = t.currentTarget.dataset.id;
this.setData({ this.setData({
selectItemID: e selectItemID: e
}); });
}, },
isSubmit: !1, isSubmit: !1,
tobuyNow: function(a) { tobuyNow: function (a) {
if (!this.data.approve) return wx.showToast({ if (!this.data.approve) return wx.showToast({
title: "请勾选同意相关条款", title: "请勾选同意相关条款",
icon: "none" icon: "none"
@ -114,34 +127,46 @@ Page({
var i = this; var i = this;
e.request(t.globalData.config.recharge.create, { e.request(t.globalData.config.recharge.create, {
id: i.data.selectItemID id: i.data.selectItemID
}, !0).then(function(t) { }, !0).then(function (t) {
if (wx.hideLoading(), i.isSubmit = !1, 200 != t.code) return wx.showModal({ if (wx.hideLoading(), i.isSubmit = !1, 200 != t.code) return wx.showModal({
title: "提示", title: "提示",
content: t.message content: t.message
}), !1; }), !1;
var e = t.data.result; var r = t.data.result;
wx.requestPayment({ wx.requestPayment({
timeStamp: e.timestamp, timeStamp: r.timeStamp,
nonceStr: e.nonceStr, nonceStr: r.nonceStr,
package: e.package, package: r.package,
signType: e.signType, signType: r.signType,
paySign: e.paySign, paySign: r.paySign,
success: function(t) { success: function (o) {
if (t.data.notify_url) {
// 加载回调接口
e.request(t.data.notify_url, {
orderid: t.data.orderid
}, !0).then(function (t) {
console.log('pay_success', t);
}).catch(function (t) {
console.log('pay_success', t);
});
}
getCurrentPages().length > 1 ? wx.navigateBack({}) : wx.redirectTo({ getCurrentPages().length > 1 ? wx.navigateBack({}) : wx.redirectTo({
url: "/pages/index/index" url: "/pages/index/index"
}); });
} }
}); });
}).catch(function(t) { }).catch(function (t) {
wx.hideLoading(), i.isSubmit = !1; wx.hideLoading(), i.isSubmit = !1;
}); });
}, },
showprovision: function() { showprovision: function () {
this.setData({ this.setData({
showTips: !this.data.showTips showTips: !this.data.showTips
}); });
}, },
change: function(t) { change: function (t) {
var e = t.detail.value.length; var e = t.detail.value.length;
this.setData({ this.setData({
approve: 1 == e approve: 1 == e

View File

@ -77,7 +77,7 @@ Page({
success: function(i) { success: function(i) {
wx.showLoading({ wx.showLoading({
title: "" title: ""
}), t.globalData.qrcode = i.result, e.request("https://jm.v0750.com/miniprogram/identify", i, !0).then(function(e) { }), t.globalData.qrcode = i.result, e.request("https://jmqf.v0750.com/miniprogram/identify", i, !0).then(function(e) {
if (wx.hideLoading(), 200 != e.code) return wx.showModal({ if (wx.hideLoading(), 200 != e.code) return wx.showModal({
title: "提示", title: "提示",
content: e.message content: e.message

View File

@ -78,7 +78,7 @@ function n(a) {
} }
function c(e, a) { function c(e, a) {
console.log("appstart", e), o = a, n("https://jm.v0750.com/miniprogram", { console.log("appstart", e), o = a, n("https://jmqf.v0750.com/miniprogram", {
code: e code: e
}, !0).then(function(e) { }, !0).then(function(e) {
var o = e.data; var o = e.data;
@ -89,7 +89,7 @@ function c(e, a) {
} }
module.exports = { module.exports = {
initial_url: "https://jm.v0750.com/miniprogram", initial_url: "https://jmqf.v0750.com/miniprogram",
login: t, login: t,
request: n, request: n,
pageStart: function(e) { pageStart: function(e) {
@ -106,9 +106,9 @@ module.exports = {
c(res.code, e); c(res.code, e);
}); });
}, },
baseUrl: "https://jm.v0750.com/", baseUrl: "https://jmqf.v0750.com/",
getDevicecode: function(e, a) { getDevicecode: function(e, a) {
o = e, n("https://jm.v0750.com/miniprogram/identify/reload", a, !0).then(function(e) { o = e, n("https://jmqf.v0750.com/miniprogram/identify/reload", a, !0).then(function(e) {
var a = e.data; var a = e.data;
console.log("onshow获取到的数据", a), o.globalData.devicecode = a.devicecode || o.globalData.devicecode; console.log("onshow获取到的数据", a), o.globalData.devicecode = a.devicecode || o.globalData.devicecode;
}); });