feat: 新增商品详情搭配优惠组件和客服弹窗

refactor: 优化页面样式和交互逻辑

fix: 修复洗车券列表和详情页的数据展示问题

style: 调整用户页面按钮样式和布局

chore: 移除无用页面和代码,更新项目配置

docs: 更新单次启动页面的使用说明和注意事项

perf: 优化网络请求和数据处理逻辑

build: 更新依赖和配置文件

test: 更新测试用例以适应新功能

ci: 调整CI配置以适应新项目结构
This commit is contained in:
2026-01-03 11:26:51 +08:00
parent b80b33c81f
commit 95eed74b96
68 changed files with 1197 additions and 2036 deletions

36
app.js
View File

@@ -3,31 +3,15 @@ var t = require("./utils/login.js");
// 引入
require("./utils/xstat.js");
function generateRandomCode(length) {
let result = '';
const characters = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789';
const charactersLength = characters.length;
for (let i = 0; i < length; i++) {
result += characters.charAt(Math.floor(Math.random() * charactersLength));
}
return result;
}
App({
xstatConfig: {
appKey: wx.getAccountInfoSync().miniProgram.appId, // 自动获取 小程序appid
debug: true, //是否打开调试模式
// 上报地址
LOG_URL: 'https://t-jm.v0750.com/v2/stat/send',
LOG_URL: 'https://t-jm.v0750.com/send',
},
onLaunch: function (e) {
// 40 位的随机码
if (!wx.getStorageSync("session")) {
wx.setStorageSync("session", generateRandomCode(40));
}
onLaunch: function(e) {
console.log("options", e), this.globalData.options = e, t.getLogin(this, !0);
try {
var o = wx.getSystemInfoSync();
@@ -41,16 +25,16 @@ App({
});
}
},
onShow: function (e) {
onShow: function(e) {
console.log("onshowwwwwwwoptions", e);
var o = e.scene;
[1011, 1012, 1013, 1024, 1047, 1048, 1049].indexOf(o) > -1 && (console.log("扫码进入的"),
t.getDevicecode(this, e));
[ 1011, 1012, 1013, 1024, 1047, 1048, 1049 ].indexOf(o) > -1 && (console.log("扫码进入的"),
t.getDevicecode(this, e));
},
computeNavigateBarHeight: function (t) {
computeNavigateBarHeight: function(t) {
var e = wx.getMenuButtonBoundingClientRect(), o = e.bottom + 6, i = t.windowHeight, n = e.top, a = e.height;
i < 10 && (i = t.windowHeight, a = o - (n = t.statusBarHeight)), o < 10 && (console.log("更新"),
o = 68, /iPhone X|MI 8|PAAM00|COR-AL00/.test(t.model) ? o = 88 : /iPhone/.test(t.model) && (o = 64));
o = 68, /iPhone X|MI 8|PAAM00|COR-AL00/.test(t.model) ? o = 88 : /iPhone/.test(t.model) && (o = 64));
var s = t.windowWidth;
this.globalData.screen_data = {
windowWidth: s,
@@ -74,12 +58,6 @@ App({
isneedUpload: !1,
needJumpUrl: !1,
devicecode: "",
deviceData: {
type: 'machine',
devicecode: '',
options: {},
title: '',
},
protocol: {},
tips: ""
}

View File

@@ -23,11 +23,7 @@
"pages/user/user",
"pages/webview/webview",
"pages/wangdian/wangdian",
"pages/duiquan/duiquan",
"pages/refund/refund",
"pages/washing/washing",
"pages/substituteWash/substituteWash",
"pages/OnlineCarHailing/OnlineCarHailing"
"pages/duiquan/duiquan"
],
"window": {
"backgroundTextStyle": "light",

View File

@@ -125,7 +125,7 @@
bottom: 0;
color: #fff;
font-size: 44rpx;
height: 126rpx;
height: 136rpx;
left: 0;
line-height: 106rpx;
position: fixed;
@@ -133,6 +133,7 @@
width: 100vw;
z-index: 6;
border-radius: 40rpx 40rpx 0 0;
overflow: hidden;
}
.scan-btn .sha {
animation: shake 2s infinite;
@@ -183,7 +184,6 @@
font-size: 26rpx;
justify-content: center;
line-height: 40rpx;
border:none;
}
.index-href-box,.service-tel {
@@ -208,6 +208,15 @@
background-image: linear-gradient(to bottom, #C7E1F9, #fff);
}
.index-href-box button.item {
border: 0;
padding: 0;
}
.index-href-box button.item .name {
line-height: 40rpx;
}
.index-href-box .item_b {
width: 100%;
height: 100%;

83
img/iconfont---.svg Normal file

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 36 KiB

BIN
img/logo2.jpeg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 22 KiB

View File

@@ -1,118 +0,0 @@
// pages/OnlineCarHailing/OnlineCarHailing.js
var t = require("../../utils/login.js");
Page({
/**
* 页面的初始数据
*/
data: {
},
onSubmitToGroup(e) {
const mobile = e.detail.value.code
if (!mobile) {
wx.showToast({
title: '请输入手机号码',
icon: 'none'
})
return
}
// 手机号格式验证
if (!/^1[3-9]\d{9}$/.test(mobile)) {
wx.showToast({
title: '请输入正确的手机号码',
icon: 'none'
})
return
}
// 二次确认
wx.showModal({
title: '确认提示',
content: '确定要将此手机号设置为网约车用户吗?',
success: (res) => {
if (res.confirm) {
wx.showLoading({
title: '提交中...'
})
t.request('/miniprogram/user/onlineCarHailing', { mobile }, !0).then((res) => {
wx.hideLoading()
if (res.code == 200) {
wx.showToast({
title: '设置成功',
icon: 'success'
})
setTimeout(() => {
wx.navigateBack()
}, 1500)
} else {
wx.showToast({
title: res.message || '设置失败',
icon: 'none'
})
}
})
}
}
})
},
/**
* 生命周期函数--监听页面加载
*/
onLoad(options) {
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady() {
},
/**
* 生命周期函数--监听页面显示
*/
onShow() {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide() {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload() {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh() {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom() {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage() {
}
})

View File

@@ -1,3 +0,0 @@
{
"usingComponents": {}
}

View File

@@ -1,9 +0,0 @@
<view class="contain">
<view class="content">
<view class="title">设置网约车用户</view>
<form bindsubmit="onSubmitToGroup">
<input class="input" name="code" auto-focus placeholder="请填写用户手机号码"/>
<button class="button" form-type="submit" type="primary">设置网约车用户</button>
</form>
</view>
</view>

View File

@@ -1,25 +0,0 @@
.contain {
box-sizing: border-box;
min-height: 100vh;
background-color: #fafafa;
}
.content {
padding: 60rpx 40rpx;
}
.title {
font-size: 36rpx;
line-height: 1;
font-weight: 700;
color: #0056A3;
}
.input {
margin: 40rpx 0;
padding: 22rpx;
border-radius: 10rpx;
background-color: #fff;
border: 2rpx solid #eee;
box-shadow: 0 6rpx 10rpx rgba(0, 0, 0, 0.1);
}

View File

@@ -1,16 +1,20 @@
<template name="pageList">
<view class="index-href-box">
<block wx:for="{{urlList}}" wx:key="index">
<button wx:if="{{item.phone}}" class="item" open-type="contact" show-message-card="true">
<view class="item_b" style="background-image:url('{{item.img}}')">
<view class="name">{{item.name}}</view>
</view>
</button>
<view wx:else bindtap="toPage" class="item" data-needlogin="{{item.needlogin}}" data-refresh="{{item.refresh}}" data-showimg="{{item.showimg}}" data-url="{{item.url}}" data-phone="{{item.phone}}">
<view class="item_b" style="background-image:url('{{item.img}}')">
<view class="name">{{item.name}}</view>
</view>
<block wx:for="{{urlList}}" wx:key="index">
<view bindtap="toPage" class="item" data-needlogin="{{item.needlogin}}" data-refresh="{{item.refresh}}" data-showimg="{{item.showimg}}" data-url="{{item.url}}" wx:if="{{item.needlogin || item.refresh || item.showimg || item.url}}">
<view class="item_b" style="background-image:url({{item.img}}) ;">
<view class="name">{{item.name}}</view>
</view>
</view>
<button class="item" size="mini" type="default" plain="ture" open-type="contact" wx:else>
<view class="item_b" style="background-image:url({{item.img}}) ;">
<view class="name">{{item.name}}</view>
</view>
</button>
</block>
</view>
</template>

0
pages/common/common.wxss Normal file
View File

View File

@@ -1,13 +1,12 @@
var e = getApp(), t = require("../../utils/login.js");
var t = require("../../utils/login.js");
Page({
data: {
pic: "https://jm-static.v0750.com/image/dui.jpg",
tips: "温馨提示:\n1、请在30分钟内完成兑换超时作废\n2、请在兑换完成后在本页面点击\"确认兑换\"\n3、兑换成功后将在3个工作日内发放奖品",
code: ''
},
onLoad() {
t.request('/miniprogram/coupons/index', {}, !0).then((res) => {
t.request('/miniprogram/coupons', {}, !0).then((res) => {
if (res.code == 200) {
this.setData({
tips: res.data.tips,
@@ -16,58 +15,7 @@ Page({
}
})
},
toScan: function () {
e.globalData.needJumpUrl = !1;
var a = this;
wx.scanCode({
success: function (i) {
console.log(i), wx.showLoading({
title: ""
}), e.globalData.qrcode = i.result, t.request("/miniprogram/identify/index", i, !0).then(function (t) {
console.log("data", t), wx.hideLoading();
// 保存设备编号
getApp().globalData.deviceData = t.data || getApp().globalData.deviceData || {};
getApp().globalData.devicecode = t.data.devicecode || getApp().globalData.devicecode;
a.startup();
}).catch(function (e) {
wx.hideLoading();
});
}
});
},
// 启动
startup: function () {
if (getApp().globalData.deviceData.devicecode) {
// 合并参数 t.globalData.deviceData 与 washcode
let params = Object.assign(getApp().globalData.deviceData, {
washcode: this.data.code
});
// 已扫码,启动机器
t.request('/miniprogram/' + getApp().globalData.deviceData.type + '/carwashcodestartup', params, !0).then((startRes) => {
if (startRes.code == 200) {
wx.showToast({ title: startRes.message || '启动成功', icon: 'success' });
// 跳转到洗车券列表页面
wx.redirectTo({
// url: "/pages/washing/washing"
url: "/pages/index/index"
})
} else {
wx.redirectTo({
url: "/pages/washCodeList/washCodeList"
});
wx.showToast({ title: startRes.message || '启动失败', icon: 'none' });
}
});
} else {
// 未扫码,提示
wx.showToast({
title: '请先扫码',
icon: 'none'
})
}
},
onSubmitToGroup(e) {
const code = e.detail.value.code
if (!code) {
@@ -84,43 +32,15 @@ Page({
t.request('/miniprogram/coupons/importDouyin', { code: code }, !0).then((res) => {
wx.hideLoading()
if (res.code == 200) {
// 在当前页面记下券码
this.setData({
code: res.data.code
})
wx.showModal({
wx.showToast({
title: '兑换成功',
content: '是否立即使用?',
success: (result) => {
if (result.confirm) {
// 判断是否已扫码
if (getApp().globalData.devicecode) {
wx.showModal({
title: "提示",
content: "你当前将要使用的机器编号是:".concat(getApp().globalData.deviceData.title || getApp().globalData.deviceData.devicecode, ",确认开机吗?"),
success: (res) => {
if (res.confirm) {
// 用户点击了确认按钮,执行开机操作
this.startup();
} else {
// 用户点击了取消按钮,跳转到洗车券列表页面
wx.navigateTo({ url: '/pages/washCodeList/washCodeList' });
}
}
});
} else {
// 未扫码,打开扫码页面
this.toScan(); // 调用toScan方法跳转到扫码页面
}
} else {
wx.navigateTo({ url: '/pages/washCodeList/washCodeList' });
}
}
icon: 'success'
});
setTimeout(() => {
wx.navigateTo({
url: '/pages/washCodeList/washCodeList'
})
})
} else {
wx.showToast({
title: res.message || '兑换失败',

View File

@@ -20,14 +20,11 @@
.input {
margin: 30rpx 0;
padding: 0 22rpx;
height: 88rpx;
line-height: 88rpx;
padding: 22rpx;
border-radius: 10rpx;
background-color: #fff;
border: 2rpx solid #eee;
box-shadow: 0 6rpx 10rpx rgba(0, 0, 0, 0.1);
color: #333;
}
.tips {

View File

@@ -39,7 +39,7 @@ Page({
return e.default.wrap(function(e) {
for (;;) switch (e.prev = e.next) {
case 0:
return s, e.prev = 1, e.next = 4, n.request("https://t-jm.v0750.com/shop/details", {
return s, e.prev = 1, e.next = 4, n.request(n.baseUrl + "shop/details", {
id: s.data.id
}, !0);

View File

@@ -0,0 +1,7 @@
Component({
properties: {},
data: {
showDialog: !1
},
methods: {}
});

View File

@@ -0,0 +1,4 @@
{
"component": true,
"usingComponents": {}
}

View File

@@ -0,0 +1,37 @@
<view>
<view class="keufubox">
<view class="kebox">
<view class="mykefu ">
<view class="le">
<image src="http://q990.img.aiyichuan.com/urm_huodong/20190416/1555414945804.jpg"></image>
<view class="box">
<view class="title">霸王餐福利</view>
<view class="desc">加客服进「声色福利群」</view>
</view>
</view>
<view class="btn">点我添加</view>
</view>
</view>
</view>
<view class="modal-dialog" wx:if="{{showDialog}}">
<view class="modal">
<view class="infopop-wrap">
<view class="infopop-content">
<view class="info-buy_notice">
<view class="top">
<view class="_top"></view>
<view class="title">购买须知</view>
</view>
<view style="max-height: 280px; overflow: auto;">
<view class="txt">
<view class="txt_p">此券属平台与商家补贴,一经售出无法退款,请确认后再下单。</view>
</view>
</view>
<button class="btn">我知道了</button>
</view>
</view>
<button class="infopop-close">×</button>
</view>
</view>
</view>
</view>

View File

@@ -0,0 +1,189 @@
.keufubox:last-child {
margin-bottom: -5.333vw;
}
.kebox {
border-radius: 1.6vw;
width: 92vw;
}
.kebox,.mykefu {
background: #fff;
}
.mykefu {
-webkit-box-pack: justify;
-ms-flex-pack: justify;
height: 17.067vw;
justify-content: space-between;
}
.mykefu .le {
-webkit-box-flex: 1;
flex: 1;
}
.mykefu,.mykefu .le {
-webkit-box-align: center;
-ms-flex-align: center;
align-items: center;
display: -webkit-box;
display: -ms-flexbox;
display: -webkit-flex;
display: flex;
}
.mykefu .le image {
border-radius: 50%;
height: 9.6vw;
margin-right: 3.467vw;
max-width: 100%;
width: 9.6vw;
}
.mykefu .le .box {
width: 57.333vw;
}
.mykefu .le .title {
color: #2a2a2a;
font-size: 3.733vw;
}
.mykefu .le .desc,.mykefu .le .title {
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.mykefu .le .desc {
color: #969696;
font-size: 3.2vw;
line-height: 4.133vw;
width: 57.333vw;
}
.kebox .btn {
border-radius: 6.667vw;
color: #fff;
font-size: 3.2vw;
height: 8.667vw;
line-height: 8.667vw;
position: relative;
text-align: center;
}
.mykefu .btn {
background: #28c418;
font-size: 3.2vw;
width: 18.267vw;
}
.modal-dialog {
position: fixed;
z-index: 20;
}
.modal-dialog,.modal-dialog .modal {
height: 100%;
left: 0;
top: 0;
width: 100%;
}
.modal-dialog .modal {
background: rgba(0,0,0,.5);
position: absolute;
transition: all .3s;
}
.infopop-wrap {
left: 50%;
position: absolute;
top: 45%;
transform: translate(-50%,-50%);
}
.infopop-content {
background-color: #fff;
border-radius: 2.133vw;
color: #666;
font-size: 4vw;
line-height: 5.333vw;
overflow: hidden;
padding-bottom: 6.667vw;
text-align: center;
width: 69.867vw;
}
.info-buy_notice .top {
color: #fff;
height: 21.867vw;
margin-bottom: 3.467vw;
overflow: hidden;
position: relative;
}
.info-buy_notice ._top {
background: #06a2b3;
border-radius: 0 0 50% 50%;
height: 100%;
left: 50%;
margin-bottom: 4vw;
position: absolute;
top: 0;
transform: translateX(-50%);
width: 120%;
}
.info-buy_notice .top .title {
color: #fff;
font-size: 4.8vw;
left: 0;
position: absolute;
text-align: center;
top: 50%;
transform: translateY(-50%);
width: 100%;
}
.info-buy_notice .txt {
font-size: 3.733vw;
line-height: 5.333vw;
padding: 0 4vw;
text-align: left;
}
.info-buy_notice .btn {
background-color: #06a2b3;
border-radius: 10.667vw;
color: #fff;
font-size: 4vw;
height: 10.667vw;
line-height: 10.667vw;
margin-bottom: -2.133vw;
margin-top: 5.333vw;
text-align: center;
width: 34.667vw;
}
.infopop-close {
background-color: #fff;
border-radius: 50%;
color: rgba(0,0,0,.6);
font-size: 8.267vw;
height: 8.533vw;
left: 50%;
line-height: 8.033vw;
margin: 4.267vw 0 0 -4.267vw;
padding: 0;
position: absolute;
text-align: center;
top: 100%;
width: 8.533vw;
}
.info-buy_notice .btn::after,.info-buy_notice .btn::before {
background: transparent;
border: none;
}

View File

@@ -0,0 +1,5 @@
Component({
properties: {},
data: {},
methods: {}
});

View File

@@ -0,0 +1,4 @@
{
"component": true,
"usingComponents": {}
}

View File

@@ -0,0 +1,34 @@
<view>
<view class="match-wrap">
<navigator class="goods-match" href="/pages/goodsDetails/goodsDetails">
<view class="til">
<image class="hot" src="/img/hot.png"></image> 为您搭配更优惠 </view>
<view class="item">
<view class="hd">
<view class="image-box __100">
<image lazyLoad="true" src="http://q990.img.aiyichuan.com/urm_huodong/20200331/1585643794622.jpg?imageView2/1/w/400/h/400"></image>
</view>
</view>
<view class="bd">
<view class="bd_name">【新会】椰子鸡再次返场9.9元起抢「骨汁恋·星汇店」100元代金券</view>
<view class="_btm">
<view class="_btm_lt">
<view class="bd_price">
<view class="now-price __normal">
<view class="symbol">¥</view>
<view class="buck">9.</view>
<view class="cent">90</view>
<view></view>
</view>
<view class="old">¥100.00</view>
</view>
</view>
<view class="_btm_rt">
<view class="bd_btn">立即抢购</view>
</view>
</view>
</view>
</view>
</navigator>
</view>
</view>

View File

@@ -0,0 +1,171 @@
.match-wrap {
border-top: 2.667vw solid #f8f8f8;
}
.goods-match {
background-color: #fff;
border-radius: 2.133vw;
display: block;
padding: 12vw 3.6vw 3.6vw;
position: relative;
}
.goods-match .til {
-webkit-box-align: center;
-ms-flex-align: center;
align-items: center;
background-color: #06a2b3;
border-radius: .533vw 2.933vw 2.933vw .533vw;
color: #fff;
display: -webkit-box;
display: -ms-flexbox;
display: -webkit-flex;
display: flex;
font-size: 3.2vw;
height: 5.867vw;
left: -.267vw;
padding-left: 1.467vw;
position: absolute;
top: 2.667vw;
width: 33.333vw;
}
.goods-match .til view {
margin-right: 1.333vw;
}
.goods-match .item {
display: -webkit-box;
display: -ms-flexbox;
display: -webkit-flex;
display: flex;
}
.goods-match .hd {
-webkit-box-flex: 25.333vw;
border-radius: 1.6vw;
flex: 25.333vw 0 0;
height: 25.333vw;
overflow: hidden;
width: 25.333vw;
}
.image-box.__100 {
padding-top: 100%;
}
.image-box {
background-color: #ebebeb;
height: 0;
overflow: hidden;
position: relative;
}
.image-box image {
height: 100%;
left: 0;
position: absolute;
top: 0;
width: 100%;
}
.goods-match .bd {
-webkit-box-flex: 1;
-webkit-box-orient: vertical;
-webkit-box-direction: normal;
-webkit-box-pack: justify;
-ms-flex-pack: justify;
display: -webkit-box;
display: -ms-flexbox;
display: -webkit-flex;
display: flex;
flex: 1;
flex-direction: column;
justify-content: space-between;
padding: 0 0 0 2.667vw;
}
.goods-match .bd_name {
-webkit-box-orient: vertical;
-webkit-line-clamp: 3;
color: #2a2a2a;
display: -webkit-box;
font-size: 3.733vw;
height: 16vw;
line-height: 5.333vw;
overflow: hidden;
text-overflow: ellipsis;
word-break: break-all;
}
.goods-match .bd ._btm {
-webkit-box-align: end;
-ms-flex-align: end;
align-items: flex-end;
display: -webkit-box;
display: -ms-flexbox;
display: -webkit-flex;
display: flex;
}
.goods-match .bd ._btm_lt {
-webkit-box-flex: 1;
flex: 1;
}
.goods-match .bd_price {
-webkit-box-align: center;
-ms-flex-align: center;
align-items: center;
display: -webkit-box;
display: -ms-flexbox;
display: -webkit-flex;
display: flex;
}
.now-price {
color: #eb5252;
font-family: DIN;
font-size: 3.2vw;
line-height: 1.75em;
}
.goods-match .bd_price .old {
color: #9b9b9b;
font-family: DIN;
font-size: 3.2vw;
margin-left: 1.333vw;
text-decoration: line-through;
}
.goods-match .bd_btn {
background-color: #06a2b3;
border-radius: 3.333vw;
color: #fff;
font-size: 3.2vw;
height: 6.667vw;
line-height: 6.667vw;
padding: 0 3.6vw;
text-align: center;
}
.now-price .symbol {
display: inline;
margin: 0 .267vw 0 0;
}
.now-price.__normal .buck {
display: inline;
font-size: 4.8vw;
}
.cent {
display: inline;
}
.hot {
display: inline-block;
height: 13px;
margin-right: 4px;
width: 13px;
}

View File

@@ -64,7 +64,7 @@ Page({
case 2:
return r.setData({
loading: !0
}), r, t.prev = 4, t.next = 7, s.request("https://t-jm.v0750.com/shop/search", {
}), r, t.prev = 4, t.next = 7, s.request(s.baseUrl + "shop/search", {
keyword: r.data.kw
}, !0);

View File

@@ -16,10 +16,7 @@ Page({
tabStatus: {
coupon: !1,
shop: !1
},
showOneTimeOptions: !1,
oneTimeOptions: [],
oneTimeLoading: !1
}
},
bindViewTap: function () {
wx.navigateTo({
@@ -89,22 +86,22 @@ Page({
}, 50);
});
});
e.globalData.devicecode = "1840001"; // 强制设置扫码状态
},
getData: function () {
var a = this;
// 获取首页数据
t.request('/miniprogram/index/balance', e.globalData.deviceData, !0).then(function (e) {
t.request('/miniprogram/index/balance', {}, !0).then(function (e) {
a.setData({
user: e.data || [],
});
// 存储进度订单
wx.setStorageSync('progressorder', e.data.progressorder || []);
});
},
load: function (e) {
console.log(e);
},
openLocation: function (e) {
openLocation: function(e) {
var latitude = Number(e.currentTarget.dataset.latitude);
var longitude = Number(e.currentTarget.dataset.longitude);
var name = e.currentTarget.dataset.name;
@@ -128,19 +125,7 @@ Page({
}), (this.getData(), this.isneedUpload = !1);
},
toPage: function (t) {
if (t.currentTarget.dataset.phone) {
// 打开客服聊天窗口
return wx.openCustomerServiceChat();
// 增加打电话
wx.makePhoneCall({
phoneNumber: "" + t.currentTarget.dataset.phone
});
return;
}
console.info(t);
var a = t.currentTarget.dataset, i = a.url, o = a.needlogin, n = a.showimg;
if (console.log("showImg", n), i) {
this.isneedUpload = !0;
@@ -164,13 +149,11 @@ Page({
success: function (i) {
console.log(i), wx.showLoading({
title: ""
}), e.globalData.qrcode = i.result, t.request("/miniprogram/identify/index", i, !0).then(function (t) {
console.log("data", t), wx.hideLoading(),
e.globalData.deviceData = t.data || e.globalData.deviceData || {};
e.globalData.devicecode = t.data.devicecode || e.globalData.devicecode;
a.setData({
isScan: !!t.data.devicecode
});
}), e.globalData.qrcode = i.result, t.request("/miniprogram/identify", i, !0).then(function (t) {
console.log("data", t), wx.hideLoading(), e.globalData.devicecode = t.data.devicecode || e.globalData.devicecode,
a.setData({
isScan: !!t.data.devicecode
});
}).catch(function (e) {
wx.hideLoading();
});
@@ -187,140 +170,41 @@ Page({
e.globalData.needJumpUrl = !1, this.isneedUpload = !0;
var t = this;
if (console.log("this.isSubmit", this.isSubmit), this.isSubmit) return !1;
wx.showActionSheet({
itemList: ["单次消费", "立即启动"],
success: function (res) {
if (res.tapIndex === 0) {
t.openOneTimeOptions();
} else {
if (t.data.user.money == 0) {
wx.showModal({
title: "提示",
content: "您的洗车金额为0元是否需要购买洗车金额",
confirmText: "去购买",
cancelText: "取消",
success: function (m) {
if (m.confirm) {
wx.navigateTo({
url: "/pages/voucher/voucher"
}), t.isneedUpload = !0;
}
}
});
return;
}
else if (t.data.user.money < 10) {
wx.showModal({
title: "提示",
content: "洗车金额不足10元是否需要购买洗车金额还是直接开机",
confirmText: "去购买",
cancelText: "直接开机",
success: function (m) {
if (m.confirm) {
wx.navigateTo({
url: "/pages/voucher/voucher"
}), t.isneedUpload = !0;
} else {
t.startup();
}
}
});
return;
}
t.startup();
}
}
});
},
openOneTimeOptions: function () {
var a = this;
if (a.data.oneTimeLoading) return !1;
a.setData({ oneTimeLoading: !0 });
// 获取单次洗车配置
t.request('/miniprogram/single/getAgentConfig', e.globalData.deviceData || {}, !0).then(function (res) {
a.setData({
oneTimeOptions: (res.data && Array.isArray(res.data)) ? res.data : (res.data && res.data.list ? res.data.list : []),
showOneTimeOptions: !0,
oneTimeLoading: !1
});
}).catch(function () {
a.setData({ oneTimeLoading: !1 });
});
},
closeOneTimeOptions: function () {
this.setData({ showOneTimeOptions: !1 });
},
payOneTime: function (evt) {
var a = this, i = evt.currentTarget.dataset.token;
if (!i) return !1;
wx.showLoading({ title: "" });
t.request('/miniprogram/single/create', {
token: i
}, !0).then(function (res) {
if (wx.hideLoading(), 200 != res.code) return wx.showModal({
if (t.data.user.money <= 0) return t.startup(), !1;
if (t.data.user.money < 10) {
if (this.isshowModal) return t.startup(), !1;
this.isshowModal = !0, wx.showModal({
title: "提示",
content: res.message || ""
}), !1;
var r = res.data.result;
var orderid = res.data.orderid;
wx.requestPayment({
timeStamp: r.timeStamp,
nonceStr: r.nonceStr,
package: r.package,
signType: r.signType,
paySign: r.paySign,
success: function () {
a.setData({ showOneTimeOptions: !1 });
var poll = function () {
t.request('/miniprogram/single/notify', {
orderid: orderid
}, !0).then(function (res) {
if (200 == res.code) {
wx.showModal({
title: "提示",
content: "支付成功"
});
wx.navigateTo({
url: "/pages/voucher/voucher"
});
return;
}
}).catch(function (err) {
if (err && err.code == 202) {
setTimeout(poll, 1500);
return;
}
if (err && err.code == 201) {
wx.showModal({
title: "提示",
content: err.message || ""
});
}
});
};
poll();
content: "账户余额小于10元是否立即充值",
confirmText: "去充值",
cancelText: "立即启动",
success: function (e) {
e.confirm ? (wx.navigateTo({
url: "/pages/voucher/voucher"
}), t.isneedUpload = !0) : t.startup();
},
fail: function (e) {
console.log("fail:", e);
}
});
}).catch(function () {
wx.hideLoading();
});
} else t.startup();
},
startup: function () {
var a = this;
wx.showModal({
title: "提示",
content: "你当前将要使用的机器编号是:".concat(e.globalData.deviceData.title || e.globalData.deviceData.devicecode, ",确认开机吗?"),
content: "你当前将要使用的机器编号是:".concat(e.globalData.devicecode, ",确认开机吗?"),
success: function (i) {
i.confirm && (a.isSubmit = !0, wx.showLoading({
title: "正在启动"
}), t.request('/miniprogram/' + e.globalData.deviceData.type + '/startup', e.globalData.deviceData || {}, !0).then(function (e) {
}), t.request(e.globalData.config.machine.startup, {
washcode: a.data.selectID
}, !0).then(function (e) {
a.isSubmit = !1, wx.hideLoading(), 200 == e.code && (wx.showModal({
title: "",
content: e.message
}), a.data.tmplIds.length > 0 && a.requestSubscribeMessage(), wx.redirectTo({
// url: "/pages/washing/washing"
url: "/pages/index/index"
url: "/pages/user/user"
}), a.isneedUpload = !0), 888 == e.code && (wx.navigateTo({
url: "/pages/voucher/voucher"
}), a.isneedUpload = !0);

View File

@@ -6,35 +6,19 @@
<view class="money">
<my-money user="{{user}}"></my-money>
<view class="marquee-wrap" wx:if="{{notice}}">
<view bindtap="toPage" class="marquee-content" data-refresh="1" data-url="{{noticeurl}}">
{{notice}}
</view>
<view bindtap="toPage" class="marquee-content" data-refresh="1" data-url="{{noticeurl}}"> {{notice}} </view>
</view>
<navigator class="washing" hoverClass="hover" url="/pages/washing/washing" wx:if="{{user.progressorder}}">
<view class="l">您有一笔洗车订单进行中...</view>
<view class="r">点击查看></view>
</navigator>
</view>
<template is="pageList" data="{{urlList:urlList}}"></template>
<template is="wangdianList" data="{{wangdianList:wangdianList}}"></template>
<service-tel></service-tel>
<view bindtap="toScan" class="scan-btn" wx:if="{{!isScan}}">
<view class="sha">扫码启动</view>
</view>
<view bindtap="toStart" class="scan-btn" wx:if="{{isScan}}">
<view class="sha">立即启动</view>
</view>
<view class="one-time-modal" wx:if="{{showOneTimeOptions}}">
<view class="one-time-inner">
<view class="one-time-title">选择单次消费档位</view>
<view class="one-time-tip">限单次洗车</view>
<view class="one-time-list">
<view class="one-time-item" wx:for="{{oneTimeOptions}}" wx:key="index" bindtap="payOneTime" data-token="{{item.token}}">
<view>{{item.title}}</view>
<view>支付{{item.actualprice}}元 · 洗车时间最长{{item.usetime}}分钟</view>
</view>
</view>
<view bindtap="closeOneTimeOptions" class="one-time-cancel">取消</view>
</view>
<view bindtap="toScan" class="scan-btn" wx:if="{{!isScan}}"><view class="sha">扫码启动</view></view>
<view class="scan-btn two-btn" wx:if="{{isScan}}">
<view bindtap="toPage" data-needlogin="true" data-refresh="" data-showimg="" data-url="singleStart/singleStart" class="two-btns danci">
<view>单次启动</view>
</view>
<view bindtap="toStart" class="two-btns yue">
<view>余额启动</view>
</view>
</view>
</view>

View File

@@ -32,6 +32,17 @@
position: static;
}
.two-btn .two-btns {
float: left;
width: 50%;
height: 126rpx;
padding-top: 10rpx;
}
.two-btns.yue {
background-color: #f60;
}
.start-btn-box .scan-subscribe {
margin-right: 10rpx;
}
@@ -118,7 +129,7 @@
top: -20rpx;
color: #fff;
background-color: #0056A3;
font-size: 22rpx;
font-size: 24rpx;
padding: 0 12rpx;
line-height: 36rpx;
border-radius: 0 0 0 20rpx;
@@ -158,68 +169,3 @@
display: block;
background-color: #37CE05;
}
.washing {
justify-content: space-between;
margin: 30rpx 0 0;
padding: 20rpx 28rpx;
display: flex;
background-color: #0056A3;
color: #fff;
font-size: 28rpx;
}
.washing .l {
flex: 1;
}
/* 单次消费弹窗 */
.one-time-modal {
position: fixed;
left: 0;
right: 0;
top: 0;
bottom: 0;
background: rgba(0,0,0,0.5);
z-index: 1000;
display: flex;
align-items: center;
justify-content: center;
}
.one-time-inner {
width: 84%;
background: #fff;
border-radius: 16rpx;
padding: 24rpx 24rpx 16rpx;
box-shadow: 0 10rpx 30rpx rgba(0,0,0,.2);
}
.one-time-title {
font-size: 32rpx;
font-weight: 600;
color: #333;
text-align: center;
}
.one-time-tip {
font-size: 24rpx;
color: #999;
text-align: center;
margin-top: 8rpx;
}
.one-time-list {
margin-top: 20rpx;
}
.one-time-item {
border: 1px solid #eee;
border-radius: 12rpx;
padding: 20rpx;
margin-bottom: 16rpx;
}
.one-time-cancel {
margin-top: 8rpx;
background-color: #06a2b3;
color: #fff;
text-align: center;
line-height: 80rpx;
height: 80rpx;
border-radius: 12rpx;
}

View File

@@ -15,7 +15,7 @@ Page({
this.setData({
type: a.type
}), wx.setNavigationBarTitle({
title: "invest" == a.type ? "购买记录" : "消费明细"
title: "invest" == a.type ? "充值记录" : "消费明细"
}), e.pageStart(t).then(function(t) {
n.getContent();
});
@@ -45,7 +45,7 @@ Page({
wx.showLoading({
title: ""
});
var a = this, n = "invest" == this.data.type ? '/miniprogram/recharge/log' : '/miniprogram/consume/index';
var a = this, n = "invest" == this.data.type ? t.globalData.config.recharge.log : t.globalData.config.consume.init;
e.request(n, {
page: this.data.page.next_page
}, !0).then(function(t) {

View File

@@ -7,7 +7,7 @@
<view class="item" wx:for="{{list}}" wx:key="index">
<view class="name">{{item.message}}</view>
<view class="footer">
<view class="time">{{item.created_at}}</view>
<view class="time">{{item.timestamp}}</view>
<view class="num">{{item.symbol}}{{item.amount}}</view>
</view>
</view>
@@ -17,5 +17,5 @@
<view>暂无相关数据</view>
</view>
<service-tel></service-tel>
<view bindtap="toPage" class="scan-btn" wx:if="{{type=='invest'}}"> 立即购买洗车金额 </view>
<view bindtap="toPage" class="scan-btn" wx:if="{{type=='invest'}}"> 立即充值 </view>
</view>

View File

@@ -54,7 +54,7 @@ Page({
return a.default.wrap(function(t) {
for (;;) switch (t.prev = t.next) {
case 0:
return e, t.prev = 1, t.next = 4, r.request("https://t-jm.v0750.com/shop/home", {}, !0);
return e, t.prev = 1, t.next = 4, r.request(r.baseUrl + "shop/home", {}, !0);
case 4:
o = t.sent, (s = o.data).recommendedList.forEach(function(e) {
@@ -99,7 +99,7 @@ Page({
case 3:
return s.setData({
loading: !0
}), e.prev = 4, e.next = 7, r.request("https://t-jm.v0750.com/shop/home/shopList", {
}), e.prev = 4, e.next = 7, r.request(r.baseUrl + "shop/home/shopList", {
type: s.data.tab,
point: {
lng: s.longitude,

View File

@@ -39,8 +39,10 @@
<view class="map">
<map bindmarkertap="bindmarkertap" bindtap="closeshop" id="map" latitude="{{latitude}}" longitude="{{longitude}}" markers="{{markers}}" scale="{{zoomsize}}" showLocation="{{showLocation}}"></map>
<cover-view class="custom-btn">
<cover-view bindtap="callUs" class="btn">
<cover-view class="btn">
<button size="mini" type="default" plain="ture" open-type="contact" >
<cover-image class="img" src="/img/service.png"></cover-image>
</button>
</cover-view>
<cover-view bindtap="tolocation" class="btn">
<cover-image class="img" src="/img/local.png"></cover-image>

View File

@@ -8,6 +8,11 @@
position: fixed;
}
.custom-btn .btn button {
border: 0;
}
.custom-btn .btn {
background: #fff;
border: 2rpx solid #e4e4e4;
@@ -20,6 +25,7 @@
text-align: center;
width: 88rpx;
z-index: 130;
overflow: hidden;
}
.iconfont {

View File

@@ -26,7 +26,7 @@ Page({
return e.default.wrap(function(e) {
for (;;) switch (e.prev = e.next) {
case 0:
return i, o = i.data.orderid, e.prev = 2, e.next = 5, t.request("https://t-jm.v0750.com/shop/order/detail", {
return i, o = i.data.orderid, e.prev = 2, e.next = 5, t.request(t.baseUrl + "shop/order/detail", {
orderid: o
}, !0);

View File

@@ -82,7 +82,7 @@ Page({
return t.default.wrap(function(t) {
for (;;) switch (t.prev = t.next) {
case 0:
return t.prev = 0, t.next = 3, a.request("https://t-jm.v0750.com/shop/order/create", {
return t.prev = 0, t.next = 3, a.request(a.baseUrl + "shop/order/create", {
token: n.data.token
}, !0);
@@ -119,7 +119,7 @@ Page({
return t.default.wrap(function(t) {
for (;;) switch (t.prev = t.next) {
case 0:
return t.prev = 0, t.next = 3, a.request("https://t-jm.v0750.com/shop/order/num", {
return t.prev = 0, t.next = 3, a.request(a.baseUrl + "shop/order/num", {
uniqid: n.data.shoppingCartList.uniqid,
cartnum: n.data.num
}, !0);

View File

@@ -70,7 +70,7 @@ Page({
case 2:
return r.setData({
loading: !0
}), t.prev = 3, t.next = 6, n.request("https://t-jm.v0750.com/shop/order/lists", {
}), t.prev = 3, t.next = 6, n.request(n.baseUrl + "shop/order/lists", {
page: r.data.next_page,
typeid: r.data.tab
}, !0);
@@ -108,7 +108,7 @@ Page({
case 0:
return s = a.currentTarget.dataset, i = s.orderid, o = s.index, wx.showLoading({
title: "正在删除"
}), t.prev = 2, t.next = 5, n.request("https://t-jm.v0750.com/shop/order/delete", {
}), t.prev = 2, t.next = 5, n.request(n.baseUrl + "shop/order/delete", {
orderid: i
}, !0);

View File

@@ -41,7 +41,7 @@ Page({
return e.default.wrap(function(e) {
for (;;) switch (e.prev = e.next) {
case 0:
return r, e.prev = 1, e.next = 4, a.request("https://t-jm.v0750.com/shop/order/submit", {
return r, e.prev = 1, e.next = 4, a.request(a.baseUrl + "shop/order/submit", {
uniqid: r.data.uniqid,
name: r.data.name,
mobile: r.data.mobile,
@@ -74,7 +74,7 @@ Page({
return e.default.wrap(function(e) {
for (;;) switch (e.prev = e.next) {
case 0:
return n, s = n.data.orderid || n.data.data.orderid, e.prev = 2, e.next = 5, a.request("https://t-jm.v0750.com/shop/order/detail", {
return n, s = n.data.orderid || n.data.data.orderid, e.prev = 2, e.next = 5, a.request(a.baseUrl + "shop/order/detail", {
orderid: s
}, !0);
@@ -143,7 +143,7 @@ Page({
return e.abrupt("return", !1);
case 7:
return r.ispay = !0, n = r, e.prev = 9, e.next = 12, a.request("https://t-jm.v0750.com/shop/order/pay", {
return r.ispay = !0, n = r, e.prev = 9, e.next = 12, a.request(a.baseUrl + "shop/order/pay", {
token: r.data.token,
mark: r.data.tips
}, !0);

View File

@@ -0,0 +1,5 @@
Component({
properties: {},
data: {},
methods: {}
});

View File

@@ -0,0 +1,4 @@
{
"component": true,
"usingComponents": {}
}

View File

@@ -0,0 +1,23 @@
<view class="info-wrap">
<view class="module-title">
<view class="tit">搭配更优惠 <view class="line"></view>
</view>
</view>
<navigator class="tuijian-goods" href="#/info/index?id=764&amp;cid=99999991" wx:for="{{2}}">
<view class="lt">
<image mode="widthFix" src="http://q990.img.aiyichuan.com/urm_huodong/20200331/1585643794622.jpg?imageView2/1/w/400/h/400"></image>
</view>
<view class="tuijian-rt">
<view class="goods-name">【新会】椰子鸡再次返场9.9元起抢「骨汁恋·星汇店」100元代金券</view>
<view class="goods-info">
<view class="price">
<view class="lt">
<view class="now-price">¥9.90</view>
<view class="old-price">¥100.00</view>
</view>
<view class="btn">立即抢购</view>
</view>
</view>
</view>
</navigator>
</view>

View File

@@ -0,0 +1,137 @@
.info-wrap {
background-color: #fff;
border-top: 3.2vw solid #f8f8f8;
padding: 0 4vw 5.333vw;
}
.module-title {
color: #2a2a2a;
font-size: 4.267vw;
font-weight: 700;
line-height: 1;
margin: 5.333vw 0 8.533vw;
text-align: center;
}
.module-title .tit {
display: inline-block;
position: relative;
vertical-align: top;
}
.module-title .line {
background-color: #06a2b3;
border-radius: .8vw;
height: .8vw;
left: 35%;
margin-top: 2.133vw;
position: absolute;
top: 100%;
width: 30%;
}
.tuijian-goods {
border-radius: 1.6vw;
box-shadow: 0 1.067vw 2.667vw 0 rgba(0,0,0,.08);
display: -webkit-box;
display: -ms-flexbox;
display: -webkit-flex;
display: flex;
padding: 3.6vw;
}
.tuijian-goods .lt {
-ms-flex-negative: 0;
flex-shrink: 0;
}
.tuijian-goods .lt image {
display: block;
height: 26vw;
width: 26vw;
}
.tuijian-goods .tuijian-rt {
-webkit-box-orient: vertical;
-webkit-box-direction: normal;
-webkit-box-pack: justify;
-ms-flex-pack: justify;
-webkit-box-flex: 1;
display: -webkit-box;
display: -ms-flexbox;
display: -webkit-flex;
display: flex;
flex: 1;
flex-direction: column;
justify-content: space-between;
margin-left: 3.2vw;
}
.tuijian-goods .vip-price {
width: max-content;
}
.tuijian-goods .goods-name {
-webkit-box-orient: vertical;
-webkit-line-clamp: 2;
color: #2a2a2a;
display: -webkit-box;
font-size: 3.733vw;
font-weight: 500;
overflow: hidden;
text-overflow: ellipsis;
word-break: break-all;
}
.tuijian-goods .goods-info .price {
-webkit-box-align: center;
-ms-flex-align: center;
-webkit-box-pack: justify;
-ms-flex-pack: justify;
align-items: center;
display: -webkit-box;
display: -ms-flexbox;
display: -webkit-flex;
display: flex;
justify-content: space-between;
}
.tuijian-goods .goods-info .now-price {
color: #eb5252;
font-size: 3.467vw;
font-weight: 500;
margin-right: 3.2vw;
}
.tuijian-goods .goods-info .old-price {
color: #9b9b9b;
font-size: 3.2vw;
text-decoration: line-through;
}
.tuijian-goods .goods-info .btn {
-ms-flex-negative: 0;
background-color: #06a2b3;
border-radius: .933vw;
color: #fff;
flex-shrink: 0;
font-size: 3.2vw;
height: 6.667vw;
line-height: 6.667vw;
text-align: center;
width: 18.667vw;
}
.vip-price {
-webkit-box-align: center;
-ms-flex-align: center;
align-items: center;
background-color: #2a2a2a;
border-radius: .8vw;
display: -webkit-box;
display: -ms-flexbox;
display: -webkit-flex;
display: flex;
font-size: 2.933vw;
margin-right: 2.667vw;
}

View File

@@ -22,7 +22,7 @@ Page({
return e.default.wrap(function(e) {
for (;;) switch (e.prev = e.next) {
case 0:
return n, e.prev = 1, a = n.data.orderid, e.next = 5, i.request("https://t-jm.v0750.com/shop/notify/paymentSuccessful", {
return n, e.prev = 1, a = n.data.orderid, e.next = 5, i.request(i.baseUrl + "shop/notify/paymentSuccessful", {
orderid: a
}, !0);

View File

@@ -1,149 +0,0 @@
var t = require("../../utils/login.js");
Page({
data: {
userInfo: {
mobile: '',
uid: '',
givenamount: "0.00",
money: "0.00",
principal: "0.00",
}, // 用户查询结果
list: [], // 退款记录列表
showResult: false // 控制查询结果显示
},
onSubmitToGroup(e) {
const mobile = e.detail.value.code
if (!mobile) {
wx.showToast({
title: '请输入手机号码',
icon: 'none'
})
return
}
// 手机号格式验证
if (!/^1[3-9]\d{9}$/.test(mobile)) {
wx.showToast({
title: '请输入正确的手机号码',
icon: 'none'
})
return
}
wx.showLoading({
title: '查询中...'
})
t.request('/miniprogram/refund/query', { mobile }, !0).then((res) => {
wx.hideLoading()
if (res.code == 200) {
this.setData({
userInfo: res.data.user,
list: res.data.list,
showResult: true
})
} else {
wx.showToast({
title: res.message || '查询失败',
icon: 'none'
})
}
})
},
// 线上退款
onSubmitToGroup1() {
wx.showModal({
title: '确认退款',
content: '确定退款,将清零用户赠送金额,退还本金',
success: (res) => {
if (res.confirm) {
wx.showLoading({
title: '退款中...'
})
if (!this.data.userInfo.recharge || !this.data.userInfo.token) {
wx.showToast({
title: '退款信息不完整',
icon: 'none'
})
return
}
t.request('/miniprogram/pay/refund', {token: this.data.userInfo.token}, !0).then((res) => {
wx.hideLoading()
if (res.code == 200) {
wx.showToast({
title: '退款成功',
icon: 'success'
})
// 刷新页面数据
this.setData({
showResult: false,
userInfo: {
mobile: '',
uid: '',
givenamount: "0.00",
money: "0.00",
principal: "0.00"
}
})
} else {
wx.showToast({
title: res.message || '退款失败',
icon: 'none'
})
}
})
}
}
})
},
// 线下退款
onSubmitToGroup2() {
wx.showModal({
title: '确认退款',
content: `确定退款金额:${this.data.userInfo.money}`,
success: (res) => {
if (res.confirm) {
wx.showLoading({
title: '退款中...'
})
if (!this.data.userInfo.token) {
wx.showToast({
title: '退款信息不完整',
icon: 'none'
})
return
}
t.request('/miniprogram/pay/refundOffline', {token: this.data.userInfo.token}, !0).then((res) => {
wx.hideLoading()
if (res.code == 200) {
wx.showToast({
title: '退款成功',
icon: 'success'
})
// 刷新页面数据
this.setData({
showResult: false,
userInfo: {
mobile: '',
uid: '',
givenamount: "0.00",
money: "0.00",
principal: "0.00"
}
})
} else {
wx.showToast({
title: res.message || '退款失败',
icon: 'none'
})
}
})
}
}
})
}
})

View File

@@ -1,3 +0,0 @@
{
"usingComponents": {}
}

View File

@@ -1,61 +0,0 @@
<view class="contain">
<view class="content">
<view class="title">退款</view>
<form bindsubmit="onSubmitToGroup"> <!-- 查询前 -->
<input class="input" name="code" auto-focus placeholder="请填写用户手机号码"/>
<button class="button" form-type="submit" type="primary">查询用户订单</button>
</form>
<!-- 显示用户信息 .userInfo -->
<view class="userInfo" wx:if="{{showResult && userInfo}}">
<view class="info">
<view>手机号:<text>{{userInfo.mobile}}</text></view>
<view>用户ID<text>{{userInfo.uid}}</text></view>
<view class="balance-info">
<view class="balance-item">
<view class="label">总余额</view>
<view class="value r">{{userInfo.money}}</view>
</view>
<view class="balance-item">
<view class="label">洗车金</view>
<view class="value g">{{userInfo.principal}}</view>
</view>
<view class="balance-item">
<view class="label">赠送金额</view>
<view class="value b">{{userInfo.givenamount}}</view>
</view>
</view>
</view>
</view>
<block wx:if="{{showResult && userInfo}}">
<form bindsubmit="onSubmitToGroup1" wx:if="{{userInfo.refundType === 'online'}}"> <!-- 查询后 线上退款 -->
<view class="info">
<view>本金:<text class="r">{{userInfo.recharge.money || ''}}</text></view>
<view>赠送:{{userInfo.recharge.bonusamount || ''}}</view>
<view class="mt">订单号:{{userInfo.recharge.orderid || ''}}</view>
<view>购买时间:<text class="r">{{userInfo.recharge.date || ''}}</text></view>
<view>网点:<text class="r">{{userInfo.recharge.agent || ''}}</text></view>
</view>
<button class="button" form-type="submit" type="primary">线上退款</button>
</form>
<form bindsubmit="onSubmitToGroup2" wx:if="{{userInfo.refundType === 'offline'}}"> <!-- 查询后 线下退款 -->
<view class="info">
<view>本金:<text class="r">{{userInfo.recharge.money || ''}}</text></view>
<view>赠送:{{userInfo.recharge.bonusamount || ''}}</view>
<view class="mt">订单号:{{userInfo.recharge.orderid || ''}}</view>
<view>购买时间:<text class="r">{{userInfo.recharge.date || ''}}</text></view>
<view>网点:<text class="r">{{userInfo.recharge.agent || ''}}</text></view>
</view>
<button class="button" form-type="submit" type="warn">线下退款</button>
</form>
<view wx:if="{{userInfo.refundType === 'none'}}" class="no-refund-info"> <!-- 没有可退款记录 -->
<view class="info">
<view class="no-refund-text">没有可退款记录</view>
</view>
</view>
</block>
</view>
</view>

View File

@@ -1,93 +0,0 @@
.contain {
box-sizing: border-box;
min-height: 100vh;
background-color: #fafafa;
}
.content {
padding: 60rpx 40rpx;
}
.title {
font-size: 36rpx;
line-height: 1;
font-weight: 700;
color: #0056A3;
}
.input {
margin: 40rpx 0;
padding: 22rpx;
border-radius: 10rpx;
background-color: #fff;
border: 2rpx solid #eee;
box-shadow: 0 6rpx 10rpx rgba(0, 0, 0, 0.1);
}
.userInfo {
padding-top: 22rpx;
border-top: 2rpx solid #eee;
}
.info {
padding: 22rpx 32rpx;
border-radius: 10rpx;
background-color: #fff;
border: 2rpx solid #eee;
box-shadow: 0 6rpx 10rpx rgba(0, 0, 0, 0.1);
margin-bottom: 30rpx;
line-height: 2;
}
.info .mt {
margin-top: 30rpx;
}
.info .r {
color: #C13700;
font-weight: 700;
}
.info .g {
color: #60BB46;
font-weight: 700;
}
.balance-info {
display: flex;
justify-content: space-between;
margin-top: 20rpx;
padding: 20rpx 0;
border-top: 2rpx solid #eee;
}
.balance-item {
flex: 1;
text-align: center;
}
.balance-item .label {
font-size: 24rpx;
color: #666;
margin-bottom: 10rpx;
}
.balance-item .value {
font-size: 32rpx;
font-weight: 700;
}
.balance-item .b {
color: #0056A3;
}
.no-refund-info {
margin-top: 20rpx;
}
.no-refund-text {
text-align: center;
color: #999;
font-size: 28rpx;
padding: 40rpx 0;
}

View File

@@ -1,12 +1,75 @@
<view class="container">
<head-swiper banner="{{banner}}"></head-swiper>
<view class="title-tips">请选择单次洗车金额</view>
<view class="list">
<view bindtap="selectItem" class="{{selectIndex==index?'active item':'item'}}" data-index="{{index}}" wx:for="{{5}}" wx:key="index"> 6.00元 </view>
<!-- 推荐 -->
<view bindtap="selectItem" class="item select" data-id="{{item.id}}">
<view class="g">3元<view class="u">购</view></view>
<view class="j">5<view class="p">洗车金</view></view>
<view class="t">
<text>1、洗车金用完机器自动停止。\n 2、洗车金没用完到达[ <text class="b">10分钟</text> ]机器自动停止。</text>
</view>
</view>
<!-- 常态 选中 -->
<view bindtap="selectItem" class="item active" data-id="{{item.id}}">
<view class="g">6元<view class="u">购</view></view>
<view class="j">10<view class="p">洗车金</view></view>
<view class="t">
<text>1、洗车金用完机器自动停止。\n 2、洗车金没用完到达[ <text class="b">20分钟</text> ]机器自动停止。</text>
</view>
</view>
<!-- 常态 -->
<view bindtap="selectItem" class="item" data-id="{{item.id}}">
<view class="g">10元<view class="u">购</view></view>
<view class="j">15<view class="p">洗车金</view></view>
<view class="t">
<text>1、洗车金用完机器自动停止。\n 2、洗车金没用完到达[ <text class="b">30分钟</text> ]机器自动停止。</text>
</view>
</view>
<!-- 推荐 选中 -->
<view bindtap="selectItem" class="item active select" data-id="{{item.id}}">
<view class="g">10元<view class="u">购</view></view>
<view class="j">15<view class="p">洗车金</view></view>
<view class="t">
<text>1、洗车金用完机器自动停止。\n 2、洗车金没用完到达[ <text class="b">30分钟</text> ]机器自动停止。</text>
</view>
</view>
</view>
<view class="no-content" wx:if="{{false}}">
<image src="/img/nocontent.png"></image>
<view>暂无相关数据</view>
</view>
<view class="no-content" wx:if="{{list.length==0&&!loading}}">
<image src="/img/nocontent.png"></image>
<view>暂无相关数据</view>
</view>
<view bindtap="tobuyNow" class="tobuy-btn {{approve?'':'disabled'}}">立即启动·单次洗车</view>
<checkbox-group bindchange="change">
<label class="provision">
<checkbox checked value="{{approve}}"></checkbox> 启动单次洗车表示同意 <navigator class="text" url="/pages/webview/webview?url={{protocol.url}}">《聚美汽服购买协议》</navigator>
</label>
</checkbox-group>
<view class="warm-prompt">
<view class="title">注意事项:</view>
<view class="content">
<view>1、<b>没有完成洗车,请勿按红色“结束”按钮</b></view>
<view>2、单次洗车不支持余额支付</view>
<view>3、单次洗车仅限1次洗车不得分开多次使用</view>
<view>4、购买单次洗车后将获得相应的洗车金和洗车时长</view>
<view>5、购买单次洗车后洗车机将立即启动请确保你在洗车机前</view>
<view>6、洗车金为本次最多可用金额按量扣费</view>
<view>7、洗车时长为本次最长可用时间洗车机启动后开始计时</view>
<view>8、当洗车金为0或达到洗车时长洗车机将自动结束洗车</view>
</view>
</view>
<service-tel tel="{{servicetel}}"></service-tel>
<view class="footer-btn-box">
<view class="btn yellow">余额洗车</view>
<view class="btn">单次启动</view>
</view>
</view>

View File

@@ -11,42 +11,163 @@
padding: 0;
}
.item {
background-color: #fff;
border-radius: 18rpx;
box-shadow: 0 0rpx 9rpx 4rpx hsla(0,0%,40%,.3);
color: #333;
font-size: 87rpx;
height: 180rpx;
line-height: 180rpx;
margin-bottom: 32rpx;
text-align: center;
.list .item {
position: relative;
padding-left: 286rpx;
background: #fff;
border: 5rpx solid #0281db;
border-radius: 26rpx;
box-sizing: border-box;
color: #0281db;
flex-direction: column;
height: 158rpx;
justify-content: center;
margin: 0 0 28rpx;
width: 100%;
overflow: hidden;
}
.item.active {
box-shadow: 0 0rpx 9rpx 4rpx rgba(255,102,0,.3);
color: #f60;
.list .item .g, .list .item .j {
position: absolute;
}
.list .item .g {
left: 0;
top: 0;
height: 153rpx;
width: 158rpx;
line-height: 153rpx;
text-align: center;
background-color: #0281db;
color: #fff;
font-size: 50rpx;
}
.footer-btn-box {
bottom: 0;
color: #fff;
display: flex;
font-size: 44rpx;
left: 0;
position: fixed;
width: 100vw;
.list .item .g .u {
position: absolute;
right: -25rpx;
top: 55rpx;
width: 40rpx;
height: 40rpx;
font-size: 26rpx;
line-height: 40rpx;
border-radius: 100rpx;
border: 5rpx solid #0281db;
color: #0281db;
background-color: #fff;
}
.footer-btn-box .btn {
align-items: center;
background: #4cadf1;
display: inline-flex;
flex: 1;
height: 104rpx;
justify-content: center;
.list .item .j {
left: 158rpx;
top: 0;
height: 153rpx;
width: 138rpx;
font-size: 66rpx;
line-height: 108rpx;
text-align: center;
}
.btn.yellow {
background: #fccaa9;
.list .item .j .p {
font-size: 26rpx;
line-height: 1;
}
.list .item .t {
font-size: 25rpx;
height: 153rpx;
display: flex;
align-items: center;
justify-content: center;
padding: 0 20rpx;
background-color: #eee;
}
.list .item .t .b {
font-weight: 700;
color: #1baa1c;
}
.list .item.select, .list .item.select .g .u {
border-color: #f50;
color: #f50;
}
.list .item.select .g {
background-color: #f50;
}
.list .item.active, .list .item.active .g .u {
border-color: #4cadf1;
color: #4cadf1;
}
.list .item.active .g {
background-color: #4cadf1;
}
.list .item.active.select, .list .item.active.select .g .u {
border-color: #f90;
color: #f90;
}
.list .item.active.select .g {
background-color: #f90;
}
.tobuy-btn {
align-items: center;
background: #1baa1c;
border: 2rpx solid #218721;
border-radius: 18rpx;
color: #fff;
display: flex;
font-size: 33rpx;
height: 91rpx;
justify-content: center;
margin-top: 3rpx;
}
.tobuy-btn.disabled {
opacity: .7;
}
.provision {
display: block;
margin: 40rpx 0 0;
font-size: 26rpx;
}
.provision .text {
color: #0281db;
display: inline-block;
}
.warm-prompt {
padding: 60rpx 0;
}
.warm-prompt .title {
color: #f30;
font-size: 32rpx;
font-weight: 600;
margin-bottom: 16rpx;
}
.warm-prompt .content {
color: #666;
font-size: 26rpx;
line-height: 1.8;
}
.warm-prompt .content .view {
margin-bottom: 10rpx;
}
.warm-prompt .content view b {
font-weight: 700;
color: red;
}
.scan-btn {
background-color: #218721;
}

View File

@@ -1,199 +0,0 @@
var t = getApp(), e = require("../../utils/login.js");
Page({
/**
* 页面的初始数据
*/
data: {
userInfo: {},
balance: 0,
loading: true,
paySuccess: false,
orderInfo: {},
token: '',
},
/**
* 生命周期函数--监听页面加载
*/
onShow(options) {
var a = this;
// 等待全局接口执行完成后再初始化页面
e.pageStart(t).then(function () {
a.initPage();
});
},
/**
* 初始化页面数据
*/
initPage() {
var a = this;
a.setData({
loading: true
});
e.request('/miniprogram/substituteWash/index', {}, true).then(function (res) {
a.setData({
loading: false
});
if (res.code === 200 && res.data) {
a.setData({
orderInfo: res.data.orderInfo || {},
balance: res.data.balance || 0,
token: res.data.token || '',
});
} else {
wx.showToast({
title: res.message || '获取数据失败',
icon: 'none',
duration: 2000
});
}
}).catch(function (err) {
a.setData({
loading: false
});
wx.showToast({
title: '获取数据失败',
icon: 'none',
duration: 2000
});
});
},
/**
* 确认洗车
*/
confirmWash() {
var a = this;
wx.showModal({
title: '确认洗车',
content: '确定要进行帮洗服务吗?',
success: (res) => {
if (res.confirm) {
a.payForWash();
}
}
});
},
/**
* 支付洗车费用
*/
payForWash() {
var a = this;
wx.showLoading({
title: '处理中',
mask: true
});
e.request('/miniprogram/substituteWash/pay', { token: a.data.token }, true).then(function (res) {
wx.hideLoading();
if (res.code === 200) {
wx.showToast({
title: '支付成功',
icon: 'success',
duration: 2000
});
// 更新余额信息和支付状态
let updateData = {
paySuccess: true
};
if (res.data && res.data.balance !== undefined) {
updateData.balance = res.data.balance;
}
if (res.data && res.data.orderInfo) {
updateData.orderInfo = res.data.orderInfo;
}
a.setData(updateData);
// 可以在这里添加支付成功后的其他操作
} else {
wx.showModal({
title: '支付失败',
content: res.message || '请稍后再试',
showCancel: false
});
}
}).catch(function (err) {
wx.hideLoading();
});
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady() {
},
/**
* 生命周期函数--监听页面显示
*/
onShow() {
// 如果不是支付成功状态,则重新初始化页面
if (!this.data.paySuccess) {
var a = this;
e.pageStart(t).then(function () {
a.initPage();
});
}
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide() {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload() {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh() {
var a = this;
e.pageStart(t).then(function () {
a.initPage();
wx.stopPullDownRefresh();
});
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom() {
},
/**
* 禁止页面分享
*/
onShareAppMessage: null,
/**
* 返回首页
*/
backToIndex() {
wx.redirectTo({
url: '/pages/index/index'
});
}
})

View File

@@ -1,8 +0,0 @@
{
"navigationBarTitleText": "帮洗服务",
"enablePullDownRefresh": true,
"backgroundColor": "#f8f8f8",
"usingComponents": {
"service-tel": "/template/serviceTel/serviceTel"
}
}

View File

@@ -1,109 +0,0 @@
<view class="container">
<!-- 加载中 -->
<view class="loading-container" wx:if="{{loading}}">
<view class="spinner">
<view class="spinner-container container1">
<view class="circle1"></view>
<view class="circle2"></view>
<view class="circle3"></view>
<view class="circle4"></view>
</view>
<view class="spinner-container container2">
<view class="circle1"></view>
<view class="circle2"></view>
<view class="circle3"></view>
<view class="circle4"></view>
</view>
<view class="spinner-container container3">
<view class="circle1"></view>
<view class="circle2"></view>
<view class="circle3"></view>
<view class="circle4"></view>
</view>
</view>
<view class="loading-text">加载中...</view>
</view>
<!-- 内容区域 -->
<view class="content" wx:else>
<!-- 支付成功界面 -->
<view class="success-content" wx:if="{{paySuccess}}">
<view class="success-icon">
<icon type="success" size="80"></icon>
</view>
<view class="success-title">支付成功</view>
<view class="success-info">
<view class="info-item">
<text class="label">洗车网点</text>
<text class="value">{{orderInfo.agentname || userInfo.nickname || '---'}}</text>
</view>
<view class="info-item">
<text class="label">订单编号</text>
<text class="value">{{orderInfo.orderNo || '---'}}</text>
</view>
<view class="info-item">
<text class="label">支付金额</text>
<text class="value highlight">{{orderInfo.amount || '0'}} 元</text>
</view>
<view class="info-item">
<text class="label">账户余额</text>
<text class="value balance">{{balance}} 元</text>
</view>
</view>
<view class="success-tips">
<view class="tips-title">温馨提示</view>
<view class="tips-content">
<view class="tips-item">1. 请向工作人员出示此页面</view>
<view class="tips-item">2. 确认支付成功后即可开始洗车服务</view>
<view class="tips-item">3. 如有疑问请联系客服</view>
</view>
</view>
<view class="btn-area">
<button class="back-btn" type="default" bindtap="backToIndex">返回首页</button>
</view>
</view>
<!-- 确认洗车界面 -->
<view class="confirm-content" wx:else>
<view class="header">
<view class="title">帮洗服务</view>
<view class="subtitle">让洗车更便捷</view>
</view>
<view class="user-info">
<view class="info-item">
<text class="label">洗车网点</text>
<text class="value">{{orderInfo.agentname || userInfo.nickname || '---'}}</text>
</view>
<view class="info-item">
<text class="label">洗车费用</text>
<text class="value">{{orderInfo.amount || '0'}} 元</text>
</view>
<view class="info-item">
<text class="label">账户余额</text>
<text class="value balance">{{balance}} 元</text>
</view>
</view>
<view class="wash-info">
<view class="wash-title">服务说明</view>
<view class="wash-desc">
<view class="desc-item">1. 帮洗服务由专业人员提供</view>
<view class="desc-item">2. 确认后将从您的账户余额中扣除相应费用</view>
<view class="desc-item">3. 服务完成后可在订单中查看详情</view>
</view>
</view>
<view class="btn-area">
<button class="confirm-btn" type="primary" bindtap="confirmWash">确认洗车</button>
</view>
</view>
</view>
<!-- 客服电话组件 -->
<service-tel></service-tel>
</view>

View File

@@ -1,292 +0,0 @@
.container {
padding: 0;
font-size: 28rpx;
background-color: #f8f8f8;
min-height: 100vh;
border: none;
}
/* 加载动画 */
.loading-container {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
height: 100vh;
}
.spinner {
margin: 0 auto;
width: 120rpx;
height: 120rpx;
position: relative;
}
.spinner .spinner-container {
position: absolute;
width: 100%;
height: 100%;
}
.container1 > view, .container2 > view, .container3 > view {
width: 20rpx;
height: 20rpx;
background-color: #1aad19;
border-radius: 100%;
position: absolute;
-webkit-animation: bouncedelay 1.2s infinite ease-in-out;
animation: bouncedelay 1.2s infinite ease-in-out;
-webkit-animation-fill-mode: both;
animation-fill-mode: both;
}
.container2 {
-webkit-transform: rotateZ(45deg);
transform: rotateZ(45deg);
}
.container3 {
-webkit-transform: rotateZ(90deg);
transform: rotateZ(90deg);
}
.circle1 { top: 0; left: 0; }
.circle2 { top: 0; right: 0; }
.circle3 { right: 0; bottom: 0; }
.circle4 { left: 0; bottom: 0; }
.container1 .circle1 {
-webkit-animation-delay: -1.1s;
animation-delay: -1.1s;
}
.container2 .circle1 {
-webkit-animation-delay: -1.0s;
animation-delay: -1.0s;
}
.container3 .circle1 {
-webkit-animation-delay: -0.9s;
animation-delay: -0.9s;
}
.container1 .circle2 {
-webkit-animation-delay: -0.8s;
animation-delay: -0.8s;
}
.container2 .circle2 {
-webkit-animation-delay: -0.7s;
animation-delay: -0.7s;
}
.container3 .circle2 {
-webkit-animation-delay: -0.6s;
animation-delay: -0.6s;
}
.container1 .circle3 {
-webkit-animation-delay: -0.5s;
animation-delay: -0.5s;
}
.container2 .circle3 {
-webkit-animation-delay: -0.4s;
animation-delay: -0.4s;
}
.container3 .circle3 {
-webkit-animation-delay: -0.3s;
animation-delay: -0.3s;
}
.container1 .circle4 {
-webkit-animation-delay: -0.2s;
animation-delay: -0.2s;
}
.container2 .circle4 {
-webkit-animation-delay: -0.1s;
animation-delay: -0.1s;
}
.container3 .circle4 {
-webkit-animation-delay: 0s;
animation-delay: 0s;
}
@-webkit-keyframes bouncedelay {
0%, 80%, 100% { -webkit-transform: scale(0.0) }
40% { -webkit-transform: scale(1.0) }
}
@keyframes bouncedelay {
0%, 80%, 100% {
transform: scale(0.0);
-webkit-transform: scale(0.0);
} 40% {
transform: scale(1.0);
-webkit-transform: scale(1.0);
}
}
.loading-text {
margin-top: 30rpx;
color: #999;
}
/* 内容区域 */
.content {
padding: 30rpx;
}
.header {
text-align: center;
margin-bottom: 60rpx;
padding-top: 40rpx;
}
.title {
font-size: 48rpx;
font-weight: bold;
color: #333;
}
.subtitle {
font-size: 28rpx;
color: #666;
margin-top: 10rpx;
}
.user-info {
background-color: #fff;
border-radius: 12rpx;
padding: 0 30rpx;
margin-bottom: 30rpx;
box-shadow: 0 2rpx 10rpx rgba(0, 0, 0, 0.05);
}
.info-item {
display: flex;
justify-content: space-between;
padding: 20rpx 0;
border-bottom: 1rpx solid #f0f0f0;
}
.info-item:last-child {
border-bottom: none;
}
.label {
color: #666;
}
.value {
color: #333;
font-weight: 500;
}
.balance {
color: #1aad19;
font-weight: bold;
font-size: 32rpx;
}
.wash-info {
background-color: #fff;
border-radius: 12rpx;
padding: 30rpx;
margin-bottom: 60rpx;
box-shadow: 0 2rpx 10rpx rgba(0, 0, 0, 0.05);
}
.wash-title {
font-size: 32rpx;
font-weight: bold;
color: #333;
margin-bottom: 20rpx;
}
.wash-desc {
color: #666;
}
.desc-item {
line-height: 1.8;
margin-bottom: 10rpx;
}
.btn-area {
padding: 40rpx 60rpx;
}
.confirm-btn {
width: 100%;
height: 88rpx;
line-height: 88rpx;
font-size: 32rpx;
border-radius: 44rpx;
background-color: #1aad19;
}
/* 支付成功样式 */
.success-content {
display: flex;
flex-direction: column;
align-items: center;
padding: 30rpx;
}
.success-icon {
margin: 40rpx 0;
}
.success-title {
font-size: 48rpx;
font-weight: bold;
color: #1aad19;
margin-bottom: 60rpx;
}
.success-info {
width: 100%;
background-color: #fff;
border-radius: 12rpx;
padding: 0 30rpx;
margin-bottom: 30rpx;
box-shadow: 0 2rpx 10rpx rgba(0, 0, 0, 0.05);
}
.highlight {
color: #ff6600;
font-weight: bold;
font-size: 32rpx;
}
.success-tips {
width: 100%;
background-color: #fff;
border-radius: 12rpx;
padding: 30rpx;
margin-bottom: 30rpx;
box-shadow: 0 2rpx 10rpx rgba(0, 0, 0, 0.05);
}
.tips-title {
font-size: 32rpx;
font-weight: bold;
color: #333;
margin-bottom: 20rpx;
}
.tips-content {
color: #666;
}
.tips-item {
line-height: 1.8;
margin-bottom: 10rpx;
}
.back-btn {
width: 100%;
height: 88rpx;
line-height: 88rpx;
font-size: 32rpx;
border-radius: 44rpx;
background-color: #f8f8f8;
color: #333;
border: 1rpx solid #ddd;
}

View File

@@ -6,22 +6,22 @@ Page({
urlList: [],
user: {}
},
onLoad: function (n) {
onLoad: function(n) {
var o = this;
e.pageStart(t).then(function (t) {
e.pageStart(t).then(function(t) {
o.getContent();
});
},
onShow: function () {
onShow: function() {
this.refresh && this.getContent();
},
onPullDownRefresh: function () { },
onShareAppMessage: function () { },
getContent: function () {
onPullDownRefresh: function() {},
onShareAppMessage: function() {},
getContent: function() {
var n = this;
wx.showLoading({
title: ""
}), e.request('/miniprogram/user', {}, !0).then(function (t) {
}), e.request('/miniprogram/user', {}, !0).then(function(t) {
if (wx.hideLoading(), 200 != t.code) return wx.showModal({
title: "提示",
content: t.message
@@ -30,18 +30,18 @@ Page({
showLoding: !1,
user: t.data.user,
urlList: t.data.menu
}, function () { });
}).catch(function (t) {
}, function() {});
}).catch(function(t) {
wx.hideLoading();
});
},
islogin: function () {
islogin: function() {
wx.showLoading({
title: "加载中"
});
},
refresh: 0,
toPage: function (t) {
toPage: function(t) {
var e = t.currentTarget.dataset, n = (e.refresh, e.url);
n ? wx.navigateTo({
url: "/pages/".concat(n)
@@ -51,29 +51,29 @@ Page({
duration: 2e3
}), this.refresh = 1;
},
callUs: function () {
callUs: function() {
if (!t.globalData.servicetel) return !1;
wx.makePhoneCall({
phoneNumber: "" + t.globalData.servicetel
});
},
updateUserAvatar: function () {
updateUserAvatar: function() {
var that = this;
wx.chooseMedia({
count: 1,
mediaType: ['image'],
sourceType: ['album', 'camera'],
success: function (res) {
success: function(res) {
wx.uploadFile({
url: 'https://t-jm.v0750.com/miniprogram/user/upload',
url: 'https://t-jm.v0750.com/miniprogram/upload',
filePath: res.tempFiles[0].tempFilePath,
name: 'file',
success: function (uploadRes) {
success: function(uploadRes) {
var data = JSON.parse(uploadRes.data);
if (data.code == 200) {
e.request('/miniprogram/user/update', {
avatar: data.data.url
}, true).then(function (res) {
}, true).then(function(res) {
if (res.code == 200) {
that.getContent();
wx.showToast({
@@ -93,18 +93,18 @@ Page({
}
});
},
updateUserNickname: function () {
updateUserNickname: function() {
var that = this;
wx.showModal({
title: '修改昵称',
editable: true,
placeholderText: '请输入新昵称',
success: function (res) {
success: function(res) {
if (res.confirm && res.content) {
// 发送请求到后端,更新用户昵称
e.request('/miniprogram/user/update', {
nickname: res.content
}, true).then(function (res) {
}, true).then(function(res) {
if (res.code == 200) {
that.getContent();
wx.showToast({

View File

@@ -11,14 +11,14 @@
<view class="tel">{{user.mobile}}</view>
</view>
<view class="right">
<image class="xunzhang" mode="widthFix" src="https://jm-static.v0750.com/image/xunzhang.png" wx:if="{{user.groupid==6}}"></image>
<image class="zhe" mode="widthFix" src="https://jm-static.v0750.com/image/zhe.png" wx:if="{{user.isdiscount}}"></image>
<image class="xunzhang" mode="widthFix" src="http://jm.v0750.com/image/xunzhang.png" wx:if="{{user.groupid==6}}"></image>
<image class="zhe" mode="widthFix" src="http://jm.v0750.com/image/zhe.png" wx:if="{{user.isdiscount}}"></image>
</view>
</view>
<view class="my-capital shadow">
<view class="title">
<view class="text">我的资产</view>
<view bindtap="toPage" class="btn" data-refresh="1" data-url="voucher/voucher">立即购买 ></view>
<view bindtap="toPage" class="btn" data-refresh="1" data-url="voucher/voucher">立即充值 ></view>
</view>
<view class="money-box">
<view class="item">
@@ -62,14 +62,17 @@
<text class="iconfont icon-{{item.img}}"></text>
<view class="name">{{item.name}}</view>
</view>
<!-- <view bindtap="callUs" class="item" openType="contact">
<view class="item" openType="contact">
<button size="mini" type="default" plain="ture" open-type="contact" >
<text class="iconfont icon-10"></text>
<view class="name">联系客服</view>
</view> -->
</button>
</view>
</view>
<view class="footer-btn">
<navigator class="btn" hoverClass="hover" url="/pages/index/index">首页</navigator>
<view class="btn">扫一扫</view>
<navigator class="btn" hoverClass="hover" url="/pages/voucher/voucher">购买洗车金额</navigator>
<navigator class="btn" hoverClass="hover" url="/pages/voucher/voucher">充值</navigator>
</view>
</view>

View File

@@ -194,8 +194,23 @@ button::after {
width: 33.33%;
}
.url-list .item button {
border: 0;
padding: 0;
margin: 0;
width: 100%;
}
.url-list .item button .iconfont {
line-height: 52rpx;
}
.url-list .item button .name {
margin-top: -2rpx;
}
.url-list .item .name {
margin-top: 22rpx;
line-height: 1;
}
.footer-btn {

View File

@@ -118,54 +118,47 @@ Page({
icon: "none"
}), !1;
if (!this.data.selectItemID || this.isSubmit) return wx.showToast({
title: "请选择购买洗车金额~",
title: "请选择充值金额~",
icon: "none"
}), !1;
this.isSubmit = !0, wx.showLoading({
title: ""
});
var i = this;
wx.showModal({
title: "提示",
content: "购买洗车金额后不可退,请谨慎购买",
success: function (res) {
if (!res.confirm) return !1;
i.isSubmit = !0, wx.showLoading({
title: ""
});
e.request('/miniprogram/recharge/create', {
id: i.data.selectItemID
}, !0).then(function (t) {
if (wx.hideLoading(), i.isSubmit = !1, 200 != t.code) return wx.showModal({
title: "提示",
content: t.message
}), !1;
var r = t.data.result;
wx.requestPayment({
timeStamp: r.timeStamp,
nonceStr: r.nonceStr,
package: r.package,
signType: r.signType,
paySign: r.paySign,
success: function (o) {
e.request('/miniprogram/recharge/create', {
id: i.data.selectItemID
}, !0).then(function (t) {
if (wx.hideLoading(), i.isSubmit = !1, 200 != t.code) return wx.showModal({
title: "提示",
content: t.message
}), !1;
var r = t.data.result;
wx.requestPayment({
timeStamp: r.timeStamp,
nonceStr: r.nonceStr,
package: r.package,
signType: r.signType,
paySign: r.paySign,
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);
});
}
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({
url: "/pages/index/index"
});
}
getCurrentPages().length > 1 ? wx.navigateBack({}) : wx.redirectTo({
url: "/pages/index/index"
});
}).catch(function (t) {
wx.hideLoading(), i.isSubmit = !1;
});
}
}
});
}).catch(function (t) {
wx.hideLoading(), i.isSubmit = !1;
});
},
showprovision: function () {

View File

@@ -15,7 +15,8 @@
</view>
</view>
<view bindtap="tobuy" class="buy-btn" data-id="{{item.id}}">
<text decode="true">优惠购买</text>
<text decode="true">优惠
购买</text>
</view>
</view>
</view>
@@ -24,13 +25,13 @@
</block>
<block wx:if="{{edition==1}}">
<view class="edition1-money">
<view class="l">选择购买洗车金额</view>
<view class="l">选择充值金额</view>
<view class="r">余额:{{user.money}}</view>
</view>
<view class="edition1-list">
<view bindtap="selectItem" class="{{selectItemID==item.id?item.special?'edition1-item edition1-select active':'edition1-item active':item.special?'edition1-item edition1-select':'edition1-item'}}" data-id="{{item.id}}" wx:for="{{list}}" wx:key="index">
<view class="now">{{item.paymentamount}}元</view>
<view class="origin">赠送{{item.bonusamount*1}}洗车金额</view>
<view class="origin">{{item.paymentamount}}元购买</view>
<view class="now">{{(item.bonusamount*1+item.paymentamount*1)}}<em>洗车金</em></view>
</view>
<view></view>
<view></view>
@@ -40,10 +41,10 @@
<image src="/img/nocontent.png"></image>
<view>暂无相关数据</view>
</view>
<view bindtap="tobuyNow" class="tobuy-btn {{approve?'':'disabled'}}" wx:if="{{list.length>0}}">立即购买</view>
<view bindtap="tobuyNow" class="tobuy-btn {{approve?'':'disabled'}}" wx:if="{{list.length>0}}">立即充值</view>
<checkbox-group bindchange="change">
<label class="provision">
<checkbox checked value="{{approve}}"></checkbox> 购买即表示同意 <navigator class="text" url="/pages/webview/webview?url={{protocol.url}}">《{{protocol.name}}》</navigator>
<checkbox checked value="{{approve}}"></checkbox> 充值即表示同意 <navigator class="text" url="/pages/webview/webview?url={{protocol.url}}">《{{protocol.name}}》</navigator>
</label>
</checkbox-group>
<view catchtap="showprovision" class="provision-box" wx:if="{{showTips}}">

View File

@@ -59,6 +59,11 @@
margin-right: 50rpx;
}
.edition1-item .now em {
font-size: 24rpx;
padding-left: 4rpx;
}
.info .origin {
color: #999;
text-decoration: line-through;

View File

@@ -11,7 +11,7 @@ Page({
wx.showLoading({
title: ""
}), this.setData({
id: t.id || 0
id: t.id || 1
}), i.pageStart(e).then(function (e) {
o.getList();
});
@@ -20,7 +20,7 @@ Page({
var o = this;
wx.showLoading({
title: ""
}), i.request('/miniprogram/coupons/details', {
}), i.request('/miniprogram/carwashcoupon/details', {
id: this.data.id
}, !0).then(function (e) {
if (wx.hideLoading(), 200 != e.code) return wx.showModal({
@@ -40,7 +40,7 @@ Page({
received: function () {
if (this.isSubmit) return !1;
var t = this;
this.isSubmit = !0, wx.showLoading(), console.log("received"), i.request('/miniprogram/coupons/receive', {
this.isSubmit = !0, wx.showLoading(), console.log("received"), i.request('/miniprogram/carwashcoupon/receive', {
id: t.data.id,
token: t.data.info.token
}, !0).then(function (e) {

View File

@@ -35,15 +35,6 @@ Page({
});
},
selectItem: function (t) {
// 1. 提示用户先绑定设备, isScan
if (!this.data.isScan) return wx.showModal({
title: "提示",
content: "请先扫码设备~"
}), !1;
var e = t.currentTarget.dataset, a = (e.index, e.code);
if (1 != e.available) return wx.showToast({
title: "该洗车券不可用~",
@@ -86,12 +77,11 @@ Page({
success: function (i) {
wx.showLoading({
title: ""
}), t.globalData.qrcode = i.result, e.request("/miniprogram/identify/index", i, !0).then(function (e) {
}), t.globalData.qrcode = i.result, e.request("/miniprogram/identify", i, !0).then(function (e) {
if (wx.hideLoading(), 200 != e.code) return wx.showModal({
title: "提示",
content: e.message
}), !1;
t.globalData.deviceData = e.data || t.globalData.deviceData || {};
t.globalData.devicecode = e.data.devicecode || t.globalData.devicecode, a.setData({
isScan: !!e.data.devicecode
}), a.getList();
@@ -118,22 +108,15 @@ Page({
var a = this;
wx.showModal({
title: "提示",
content: "你当前将要使用的机器编号是:".concat(t.globalData.deviceData.title || t.globalData.deviceData.devicecode, ",确认开机吗?"),
content: "你当前将要使用的机器编号是:".concat(t.globalData.devicecode, ",确认开机吗?"),
success: function (i) {
// 合并参数 t.globalData.deviceData 与 washcode
let params = Object.assign(t.globalData.deviceData, {
washcode: a.data.selectID
});
i.confirm && (a.isSubmit = !0, wx.showLoading({
title: "正在启动"
}), e.request('/miniprogram/' + t.globalData.deviceData.type + '/carwashcodestartup', params, !0).then(function (t) {
// 成功后返回提示
wx.showToast({ title: t.message || '启动成功', icon: 'success' });
// 成功后跳转
}), e.request('/miniprogram/machine/carwashcodestartup', {
washcode: a.data.selectID
}, !0).then(function (t) {
a.isSubmit = !1, wx.hideLoading(), 200 == t.code && wx.redirectTo({
url: "/pages/washing/washing"
url: "/pages/user/user"
});
}).catch(function (t) {
a.isSubmit = !1, wx.hideLoading();

View File

@@ -5,15 +5,11 @@
<view bindtap="selectItem" class="{{item.available!=1?'item item-notavailable':selectID==item.code?'active item':'item'}}" data-available="{{item.available}}" data-code="{{item.code}}" wx:for="{{list}}" wx:key="index">
<view class="top">
<view class="radio"></view>
<view class="code">{{item.title}}</view>
<view class="code">{{item.code}}</view>
</view>
<view class="location">可使用网点:<block wx:for="{{item.agent}}" wx:for-index="i" wx:for-item="s">{{s.t_name}}{{ i< item.agent.length-1?'、':''}}</block>
<block wx:if="{{item.agent.length==0}}">不限</block>
<view class="location">可使用网点:<block wx:for="{{item.agent}}" wx:for-index="i" wx:for-item="s">{{s.t_name+(i<item.agent.length-1?'、':'')}} </block>
</view>
<view class="indate">有效期:{{item.starttime}} - {{item.deadline}}</view>
<view class="indate">兑换时间:{{item.created_at}}, 兑换码: {{item.code}}</view>
<!-- 如果有note -->
<view class="indate" wx:if="{{item.note}}">{{item.note}}</view>
</view>
</view>
<view class="no-content" wx:if="{{list.length==0&&!loading}}">

View File

@@ -72,7 +72,6 @@
border-radius: 18rpx;
box-shadow: 0 0rpx 9rpx 4rpx hsla(0,0%,80%,.75);
padding: 14rpx 20rpx 14rpx 14rpx;
margin-bottom: 20rpx;
}
.item .top {

View File

@@ -1,179 +0,0 @@
var t = getApp(), e = require("../../utils/login.js");
Page({
/**
* 页面的初始数据
*/
data: {
countdown: '',
agentname: '',
devicecode: '',
remainingTime: 0,
orderid: '',
title: getApp().globalData.deviceData.title || getApp().globalData.deviceData.devicecode
},
/**
* 生命周期函数--监听页面加载
*/
onLoad(options) {
var a = this;
e.request('/miniprogram/index/balance', getApp().globalData.deviceData, !0).then(function (res) {
if (!res.data || !res.data.progressorder) {
wx.showToast({
title: '没有进行中的订单',
icon: 'none',
duration: 3000
});
setTimeout(() => {
// 跳转到首页
wx.redirectTo({
url: '/pages/index/index'
});
}, 1000);
return;
}
const orderInfo = res.data.progressorder;
const currentTime = Math.floor(Date.now() / 1000);
const remainingTime = Math.max(0, orderInfo.timestamp + orderInfo.siteoccupationTime * 60 - currentTime);
a.setData({
agentname: orderInfo.agentname,
devicecode: orderInfo.devicecode,
remainingTime: remainingTime,
orderid: orderInfo.id
});
if (remainingTime > 0) {
a.countdown();
}
}).catch(function (err) {
wx.showToast({
title: '获取订单信息失败',
icon: 'none',
duration: 2000
});
setTimeout(() => {
wx.redirectTo({
url: '/pages/index/index'
});
}, 1000);
});
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady() {
},
/**
* 生命周期函数--监听页面显示
*/
onShow() {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide() {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload() {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh() {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom() {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage() {
},
handleSettlement() {
wx.showModal({
title: '确认结算',
content: '确定要结算此次洗车订单吗?',
success: (res) => {
if (res.confirm) {
e.request('/miniprogram/' + getApp().globalData.deviceData.type + '/shutdown', {
orderid: this.data.orderid
}, true).then((res) => {
if (res.code === 200) {
wx.showToast({
title: res.message || '结算成功',
icon: 'success',
duration: 2000
});
setTimeout(() => {
wx.removeStorageSync('progressorder');
wx.redirectTo({
url: '/pages/index/index'
});
}, 2000);
}
}).catch((err) => {
// setTimeout(() => {
// wx.removeStorageSync('progressorder');
// wx.reLaunch({
// url: '/pages/index/index'
// });
// }, 2000);
})
}
}
});
},
countdown() {
// 没有 Cannot read property 'remainingTime' of undefined
if (!this.data.remainingTime) {
this.setData({
countdown: '00:00'
});
return;
}
if (this.data.remainingTime <= 0) {
this.setData({
countdown: '00:00'
});
return;
}
const minute = Math.floor(this.data.remainingTime / 60);
const second = this.data.remainingTime % 60;
const formattedMinute = minute < 10 ? '0' + minute : minute;
const formattedSecond = second < 10 ? '0' + second : second;
this.setData({
countdown: formattedMinute + ':' + formattedSecond,
remainingTime: this.data.remainingTime - 1
});
setTimeout(this.countdown, 1000);
},
})

View File

@@ -1,5 +0,0 @@
{
"usingComponents": {
"service-tel": "../../template/serviceTel/serviceTel"
}
}

View File

@@ -1,42 +0,0 @@
<view class="spinner">
<view class="time">
<text class="wangdian">{{agentname}}</text>
<text class="mactime">{{countdown}}</text>
<text class="macid">{{title}}</text>
</view>
<view class="spinner-container container1">
<view class="circle1"></view>
<view class="circle2"></view>
<view class="circle3"></view>
<view class="circle4"></view>
</view>
<view class="spinner-container container2">
<view class="circle1"></view>
<view class="circle2"></view>
<view class="circle3"></view>
<view class="circle4"></view>
</view>
<view class="spinner-container container3">
<view class="circle1"></view>
<view class="circle2"></view>
<view class="circle3"></view>
<view class="circle4"></view>
</view>
<view class="spinner-container container4">
<view class="circle1"></view>
<view class="circle2"></view>
<view class="circle3"></view>
<view class="circle4"></view>
</view>
<view class="spinner-container container5">
<view class="circle1"></view>
<view class="circle2"></view>
<view class="circle3"></view>
<view class="circle4"></view>
</view>
</view>
<view class="btn">
<button type="primary" bindtap="handleSettlement">结 算 洗 车</button>
</view>
<service-tel></service-tel>

View File

@@ -1,167 +0,0 @@
.btn {
padding: 80rpx 100rpx 40rpx;
}
.spinner {
margin: 200rpx auto 80rpx;
width: 400rpx;
height: 400rpx;
position: relative;
border-radius: 400rpx;
border: 10rpx solid green;
}
.spinner .time {
font-family: 'Consolas', 'Lucida Console', 'DejaVu Sans Mono', monospace;
position: absolute;
width: 400rpx;
height: 320rpx;
padding-top: 80rpx;
text-align: center;
color: green;
}
.spinner .time text {
display: block;
}
.wangdian, .macid {
line-height: 2;
font-size: 40rpx;
}
.mactime {
font-size: 80rpx;
font-weight: 700;
}
.container1 > view, .container2 > view, .container3 > view, .container4 > view, .container5 > view {
width: 20rpx;
height: 20rpx;
background-color: green;
border-radius: 100%;
position: absolute;
-webkit-animation: bouncedelay 2.2s infinite ease-in-out;
animation: bouncedelay 2.2s infinite ease-in-out;
-webkit-animation-fill-mode: both;
animation-fill-mode: both;
}
.spinner .spinner-container {
position: absolute;
width: 100%;
height: 100%;
}
.container2 {
-webkit-transform: rotateZ(22.5deg);
transform: rotateZ(22.5deg);
}
.container3 {
-webkit-transform: rotateZ(45deg);
transform: rotateZ(45deg);
}
.container4 {
-webkit-transform: rotateZ(67.5deg);
transform: rotateZ(67.5deg);
}
.container5 {
-webkit-transform: rotateZ(90deg);
transform: rotateZ(90deg);
}
.circle1 { top: 0; left: 0; }
.circle2 { top: 0; right: 0; }
.circle3 { right: 0; bottom: 0; }
.circle4 { left: 0; bottom: 0; }
.container1 .circle1 {
-webkit-animation-delay: -2s;
animation-delay: -2s;
}
.container2 .circle1 {
-webkit-animation-delay: -1.9s;
animation-delay: -1.9s;
}
.container3 .circle1 {
-webkit-animation-delay: -1.8s;
animation-delay: -1.8s;
}
.container4 .circle1 {
-webkit-animation-delay: -1.7s;
animation-delay: -1.7s;
}
.container5 .circle1 {
-webkit-animation-delay: -1.6s;
animation-delay: -1.6s;
}
.container1 .circle2 {
-webkit-animation-delay: -1.5s;
animation-delay: -1.5s;
}
.container2 .circle2 {
-webkit-animation-delay: -1.4s;
animation-delay: -1.4s;
}
.container3 .circle2 {
-webkit-animation-delay: -1.3s;
animation-delay: -1.3s;
}
.container4 .circle2 {
-webkit-animation-delay: -1.2s;
animation-delay: -1.2s;
}
.container5 .circle2 {
-webkit-animation-delay: -1.1s;
animation-delay: -1.1s;
}
.container1 .circle3 {
-webkit-animation-delay: -1s;
animation-delay: -1s;
}
.container2 .circle3 {
-webkit-animation-delay: -0.9s;
animation-delay: -0.9s;
}
.container3 .circle3 {
-webkit-animation-delay: -0.8s;
animation-delay: -0.8s;
}
.container4 .circle3 {
-webkit-animation-delay: -0.7s;
animation-delay: -0.7s;
}
.container5 .circle3 {
-webkit-animation-delay: -0.6s;
animation-delay: -0.6s;
}
.container1 .circle4 {
-webkit-animation-delay: -0.5s;
animation-delay: -0.5s;
}
.container2 .circle4 {
-webkit-animation-delay: -0.4s;
animation-delay: -0.4s;
}
.container3 .circle4 {
-webkit-animation-delay: -0.3s;
animation-delay: -0.3s;
}
.container4 .circle4 {
-webkit-animation-delay: -0.2s;
animation-delay: -0.2s;
}
.container5 .circle4 {
-webkit-animation-delay: -0.1s;
animation-delay: -0.1s;
}
@-webkit-keyframes bouncedelay {
0%, 80%, 100% { -webkit-transform: scale(0.0) }
40% { -webkit-transform: scale(2.0) }
}
@keyframes bouncedelay {
0%, 80%, 100% {
transform: scale(0.0);
-webkit-transform: scale(0.0);
} 40% {
transform: scale(2.0);
-webkit-transform: scale(2.0);
}
}

View File

@@ -0,0 +1,22 @@
{
"description": "项目私有配置文件。此文件中的内容将覆盖 project.config.json 中的相同字段。项目的改动优先同步到此文件中。详见文档https://developers.weixin.qq.com/miniprogram/dev/devtools/projectconfig.html",
"projectname": "%E8%81%9A%E7%BE%8E%E6%B1%BD%E6%9C%8D%2B",
"setting": {
"compileHotReLoad": true,
"urlCheck": false
},
"condition": {
"miniprogram": {
"list": [
{
"name": "pages/wangdian/wangdian",
"pathName": "pages/wangdian/wangdian",
"query": "number=T1000126",
"launchMode": "default",
"scene": null
}
]
}
},
"libVersion": "3.13.0"
}

View File

@@ -5,6 +5,6 @@
<view class="loader"></view>
</view>
</view>
<image class="logo" src="/img/logo.png"></image>
<image class="logo" src="/img/logo2.jpeg"></image>
</view>
</view>

View File

@@ -1,5 +1,3 @@
<view class="service-tel">
<!-- <view>=客服电话=</view>
<view bindtap="callUs">{{tel}}</view> -->
<!-- <button class="service-tel" open-type="contact" show-message-card="true">联系客服</button> -->
<button size="mini" type="default" plain="ture" open-type="contact" >== 联系客服 ==</button>
</view>

View File

@@ -11,14 +11,11 @@ function t() {
}
function n(a) {
var baseUrl = "https://t-jm.v0750.com/v3";
var t = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : {};
// a 是否 https, 如果不是自动补全
if (!/^https/.test(a)) {
a = baseUrl + a;
a = 'https://t-jm.v0750.com' + a;
}
// method 默认为 GET
@@ -30,7 +27,6 @@ function n(a) {
return wx.showLoading(), new Promise(function (n, c) {
console.log("requestdevicecode", o.globalData.devicecode);
var i = Object.assign({}, {
devicecode: o.globalData.devicecode
}, o.globalData.options, t);
@@ -40,7 +36,7 @@ function n(a) {
header: {
"content-type": "application/json",
Accept: "application/json, text/plain",
Cookie: "XPHP_SESSION_ID=" + wx.getStorageSync("session"),
Cookie: "_miucms_session=" + wx.getStorageSync("_miucms_session"),
token: wx.getStorageSync("session") || ""
},
method: method,
@@ -95,7 +91,7 @@ function n(a) {
}
function c(e, a) {
console.log("appstart", e), o = a, n("/miniprogram/index", {
console.log("appstart", e), o = a, n("https://t-jm.v0750.com/miniprogram", {
code: e
}, !0).then(function (e) {
var o = e.data;
@@ -106,6 +102,7 @@ function c(e, a) {
}
module.exports = {
initial_url: "https://t-jm.v0750.com/miniprogram",
login: t,
request: n,
pageStart: function (e) {
@@ -122,13 +119,11 @@ module.exports = {
c(res.code, e);
});
},
baseUrl: "https://t-jm.v0750.com/",
getDevicecode: function (e, a) {
o = e, n("/miniprogram/identify/reload", a, !0).then(function (e) {
o = e, n("https://t-jm.v0750.com/miniprogram/identify/reload", a, !0).then(function (e) {
var a = e.data;
if (e.code == 200) {
o.globalData.deviceData = a || {};
o.globalData.devicecode = a.devicecode || '';
}
console.log("onshow获取到的数据", a), o.globalData.devicecode = a.devicecode || o.globalData.devicecode;
});
}
};