更换版本

This commit is contained in:
2024-01-22 18:48:00 +08:00
parent 9f65ea8fd9
commit 00e6dcaec0
1158 changed files with 70609 additions and 51780 deletions

132
pages/weizhang/add/index.js Normal file
View File

@@ -0,0 +1,132 @@
var a;
(a = getApp()),
Page({
data: {
info: [],
sheng: [],
jianum: 0,
fanum: 0,
mendian: "请选择",
carid: 0,
buttscan: !1,
},
updateUserInfo: function (t) {
var e = this;
a.util.getUserInfo(function (a) {
wx.setStorageSync("uid", a.memberInfo.uid), e.firstin(e);
}, t.detail);
},
bindPickerChange: function (a) {
this.setData({ mendian: this.data.sheng[a.detail.value] });
},
onShow: function () {},
firstin: function (t) {
a.util.request({
url: "entry/wxapp/Api",
data: {
m: "monai_market",
uid: wx.getStorageSync("uid"),
carid: t.data.carid,
r: "home.weizhang.addcar",
},
cachetime: "0",
success: function (a) {
t.setData({ info: a.data.data.car_info, sheng: a.data.data.sheng }),
t.data.carid > 0 &&
t.setData({ mendian: a.data.data.car_info.sheng });
},
});
},
onLoad: function (t) {
var e = this;
e.setData({ carid: t.id }),
a.util.getUserInfo(function (t) {
t.memberInfo || e.setData({ isShow: !0 }),
a.util.request({
url: "entry/wxapp/Api",
data: {
m: "monai_market",
r: "me.info",
uid: wx.getStorageSync("uid"),
},
success: function (a) {
console.log(a);
},
});
}),
e.firstin(e);
},
release: function (t) {
var e = this,
n = wx.getStorageSync("uid");
if (!e.data.buttscan) {
e.setData({ buttscan: !0 });
var i = e.data.mendian;
if ("" == i || "undefined" == i || "请选择" == i)
return (
a.util.message({ title: "请选择车牌号所属省会", type: "error" }),
void e.setData({ buttscan: !1 })
);
var o = t.detail.value.jia;
if ("" == o || "undefined" == o)
return (
a.util.message({ title: "请输入识别代号后6位", type: "error" }),
void e.setData({ buttscan: !1 })
);
var r = t.detail.value.car_num;
if ("" == r || "undefined" == r)
return (
a.util.message({ title: "请输入车牌号码", type: "error" }),
void e.setData({ buttscan: !1 })
);
var s = t.detail.value.fa;
if ("" == s || "undefined" == s)
return (
a.util.message({ title: "请输入发动机号后6位", type: "error" }),
void e.setData({ buttscan: !1 })
);
var u = {
r: "home.weizhang.addcar_in",
m: "monai_market",
fomid: t.detail.formId,
uid: n,
mendian: i,
jia: o,
car_num: r,
fa: s,
carid: e.data.carid,
};
a.util.request({
url: "entry/wxapp/Api",
data: u,
cachetime: "0",
success: function (a) {
a.data.data
? wx.showToast({
title: "提交成功",
icon: "success",
duration: 2e3,
})
: (console.log(a),
wx.showToast({
title: "提交失败",
icon: "success",
duration: 2e3,
})),
wx.navigateTo({ url: "/pages/weizhang/weizhang" });
},
fail: function (t) {
console.log(t),
a.util.message({ title: t.data.message, type: "error" }),
e.setData({ buttscan: !1 });
},
});
}
},
onReady: function () {},
onHide: function () {},
onUnload: function () {},
onPullDownRefresh: function () {},
onReachBottom: function () {},
onShareAppMessage: function () {},
});

View File

@@ -0,0 +1 @@
{ "navigationBarTitleText": "添加车辆", "usingComponents": {} }

View File

@@ -0,0 +1,15 @@
<form bindreset="formReset" bindsubmit="release" reportSubmit="true">
<view class="modle"> 车牌号码 <text class="must_red">*</text>
<input class="modle_right" name="car_num" placeholder="请输入车牌号码" placeholderStyle="color: #9295A8;" type="text" value="{{info.car_num}}"></input>
<picker bindchange="bindPickerChange" class="modle_choose" data-value="{{index}}" range="{{sheng}}"> {{mendian}} <image class="modle_choose_img" src="../../image/dingweixjt_btn.png"></image>
</picker>
</view>
<view class="modle"> 识别代号 <text class="must_red">*</text>
<input class="modle_right" name="jia" placeholder="请输入识别代号后6位" placeholderStyle="color: #9295A8;" type="text" value="{{info.jia}}"></input>
</view>
<view class="modle"> 发动机号 <text class="must_red">*</text>
<input class="modle_right" name="fa" placeholder="请输入发动机号后6位" placeholderStyle="color: #9295A8;" type="text" value="{{info.fa}}"></input>
</view>
<button class="bufa_btn" formType="submit" wx:if="{{carid==0}}">添加</button>
<button class="bufa_btn" formType="submit" wx:else>修改</button>
</form>

View File

@@ -0,0 +1,232 @@
@import "/pages/alert/index.wxss";
.xiaoxi {
background: #3d61f0;
border-bottom: 20rpx solid #f9f9f9;
height: 88rpx;
padding-top: 1rpx;
width: 100%;
}
.text_area,
.xiaoxi {
display: block;
margin: 0 auto;
}
.text_area {
background: #f0f0f0;
border-radius: 10rpx;
color: #555;
font-size: 24rpx;
height: 288rpx;
padding: 20rpx;
width: 650rpx;
}
.xiaoxi_leftImg {
float: left;
height: 40rpx;
margin-top: 24rpx;
padding-left: 30rpx;
padding-right: 15rpx;
width: 40rpx;
}
.xiaoxi_right_btn {
border: 1px solid #fff;
border-radius: 5rpx;
color: #fff;
font-size: 24rpx;
height: 45rpx;
line-height: 45rpx;
margin-left: 30rpx;
margin-top: 21.5rpx;
position: absolute;
right: 20rpx;
text-align: center;
width: 100rpx;
}
.show_diandian,
.update_scroll_modle {
overflow: hidden;
white-space: nowrap;
word-break: keep-all;
}
.update_scroll_modle {
color: #fff;
float: left;
padding-right: 150rpx;
position: relative;
text-overflow: ellipsis;
width: 505rpx;
z-index: 15;
}
.modle,
.update_scroll_modle {
font-size: 28rpx;
height: 88rpx;
line-height: 88rpx;
}
.modle {
border-bottom: 1rpx solid #f0f0f0;
color: #333;
margin-left: 5%;
width: 90%;
}
.modle_right {
width: 250rpx;
}
.modle_choose,
.modle_right {
color: #9295a8;
display: block;
float: right;
font-size: 24rpx;
height: 88rpx;
margin: 0;
padding: 0;
text-align: right;
}
.modle_choose {
width: 150rpx;
}
.modle_choose_img {
height: 30rpx;
padding-left: 20rpx;
vertical-align: middle;
width: 30rpx;
}
.modle_btn {
background: #fff;
border: 1px solid #3d61f0;
border-radius: 8rpx;
color: #3d61f0;
float: right;
font-size: 24rpx;
height: 48rpx;
line-height: 46rpx;
margin: 21.5rpx 0 0 30rpx;
padding: 0;
text-align: center;
width: 120rpx;
}
.shangchuan_view {
display: inline-block;
height: 165rpx;
margin-left: 19rpx;
margin-top: 20rpx;
width: 165rpx;
}
.shangchuan_Img {
height: 165rpx;
position: absolute;
width: 165rpx;
}
.shangchuan_Img_close {
float: right;
height: 38rpx;
position: relative;
width: 38rpx;
z-index: 5;
}
.bufa_btn {
background: #3d61f0;
border-radius: 15rpx;
color: #fff;
display: block;
font-size: 28rpx;
height: 72rpx;
line-height: 72rpx;
margin: 40rpx auto 0;
text-align: center;
width: 690rpx;
}
.jinggao {
color: #9295a8;
font-size: 24rpx;
line-height: 80rpx;
text-align: center;
width: 100%;
}
.must_red {
color: red;
}
.textarea_text {
color: #888;
font-size: 24rpx;
height: 310rpx;
margin: -310rpx auto 0;
padding-left: 20rpx;
padding-right: 20rpx;
position: relative;
width: 650rpx;
z-index: 1000;
}
.textarea_text_active {
color: #333;
}
.dizhi_area {
color: #9295a8;
display: inline-block;
font-size: 24rpx;
height: 110rpx;
line-height: 50rpx;
margin-left: 20rpx;
margin-top: 18rpx;
width: 385rpx;
}
.car_messageView {
border-bottom: 1rpx solid #f0f0f0;
height: 88rpx;
margin: 0 auto;
width: 690rpx;
}
.car_messageView_input {
color: #333;
float: left;
font-size: 24rpx;
height: 88rpx;
width: 600rpx;
}
.car_messageView_sc {
color: #f75f5f;
float: left;
font-size: 24rpx;
height: 88rpx;
line-height: 88rpx;
text-align: right;
width: 90rpx;
}
.shangchuan_view_border {
margin-top: -15rpx;
width: 100%;
}
.kefu_modle {
background: #fff;
margin: 0;
padding: 0;
position: fixed;
right: 10rpx;
top: 70rpx;
width: 150rpx;
z-index: 999;
}
.kefu_modle_img {
background: #fff;
border-radius: 100%;
display: block;
height: 100rpx;
margin: 0 auto;
width: 100rpx;
}
.kefu_modle_title {
color: #666;
font-size: 27rpx;
line-height: 80rpx;
text-align: center;
width: 100%;
}
button::after {
border: none;
}
.btm_input {
position: absolute;
right: 180rpx;
width: 340rpx;
}

View File

@@ -0,0 +1,29 @@
var a;
(a = getApp()),
Page({
data: { carid: 0, info: [], weizhang: [] },
onLoad: function (t) {
var e = this;
e.setData({ carid: t.id }),
a.util.request({
url: "entry/wxapp/Api",
data: {
m: "monai_market",
carid: e.data.carid,
r: "home.weizhang.select_car",
uid: wx.getStorageSync("uid"),
},
success: function (t) {
e.setData({ info: t.data.data.car }),
200 != t.data.data.weizhang.resultcode
? a.util.message({
title: t.data.data.weizhang.reason,
type: "error",
})
: e.setData({ weizhang: t.data.data.weizhang.result.lists }),
console.log(e.data.weizhang);
},
});
},
onReachBottom: function () {},
});

View File

@@ -0,0 +1 @@
{ "navigationBarTitleText": "违章查询", "usingComponents": {} }

View File

View File

@@ -0,0 +1,30 @@
.nav_border {
background: #fff;
}
.nav {
color: #333;
font-size: 34rpx;
font-weight: 700;
height: 72rpx;
line-height: 72rpx;
margin: 0 auto;
padding: 30rpx 0;
width: 690rpx;
}
.nav_img {
border-radius: 100%;
float: right;
height: 72rpx;
width: 72rpx;
}
.text_border {
border-top: 1rpx solid rgba(0, 0, 0, 0.1);
margin: 0 auto;
padding: 15rpx 0 30rpx;
width: 690rpx;
}
.text_border_modle {
color: #333;
font-size: 28rpx;
margin-top: 15rpx;
}

108
pages/weizhang/weizhang.js Normal file
View File

@@ -0,0 +1,108 @@
var a;
(a = getApp()),
Page({
data: { list: [], weizhang_num: 0 },
onLoad: function () {
var t = this;
a.util.request({
url: "entry/wxapp/Api",
data: {
m: "monai_market",
r: "home.weizhang.index",
uid: wx.getStorageSync("uid"),
},
success: function (a) {
a.data.data &&
t.setData({
list: a.data.data.list,
weizhang_num: a.data.data.weizhang_num,
});
},
});
},
onReachBottom: function () {},
addcar: function () {
wx.navigateTo({ url: "/pages/weizhang/add/index" });
},
editcar: function (a) {
wx.navigateTo({
url: "/pages/weizhang/add/index?id=" + a.currentTarget.dataset.id,
});
},
selectcar: function (t) {
var e = this;
a.util.request({
url: "entry/wxapp/Api",
data: {
m: "monai_market",
r: "home.weizhang.weizhang_num",
uid: wx.getStorageSync("uid"),
},
success: function (n) {
e.setData({ weizhang_num: n.data.data.weizhang_num }),
0 == n.data.data.weizhang_num || n.data.data.weizhang_num < 1
? a.util.message({ title: "查询次数不足!", type: "error" })
: wx.navigateTo({
url:
"/pages/weizhang/selectcar/index?id=" +
t.currentTarget.dataset.id,
});
},
});
},
paynum: function () {
var t = this;
console.log(wx.getStorageSync("uid")),
a.util.request({
url: "entry/wxapp/paynum",
data: {
m: "monai_market",
type: "weizhang_money",
uid: wx.getStorageSync("uid"),
},
success: function (e) {
e.data && e.data.data && 1e3 == e.data.message
? a.util.request({
url: "entry/wxapp/Api",
data: {
m: "monai_market",
uid: wx.getStorageSync("uid"),
r: "home.weizhang.paynum",
orderid: e.data.data.orderid,
},
success: function (a) {
wx.showModal({ content: a.data.message }),
t.setData({ weizhang_num: 1 * t.data.weizhang_num + 10 });
},
})
: e.data &&
e.data.data &&
!e.data.errno &&
wx.requestPayment({
timeStamp: e.data.data.timeStamp,
nonceStr: e.data.data.nonceStr,
package: e.data.data.package,
signType: "MD5",
paySign: e.data.data.paySign,
success: function (n) {
a.util.request({
url: "entry/wxapp/Api",
data: {
m: "monai_market",
uid: wx.getStorageSync("uid"),
r: "home.weizhang.paynum",
orderid: e.data.data.orderid,
},
success: function (a) {
t.setData({
weizhang_num: 1 * t.data.weizhang_num + 10,
}),
wx.showModal({ content: a.data.message });
},
});
},
});
},
});
},
});

View File

@@ -0,0 +1 @@
{ "navigationBarTitleText": "我的车辆", "usingComponents": {} }

View File

@@ -0,0 +1,11 @@
<view class="nav_border">
<view class="nav" wx:if="{{list.length>0}}" wx:for="{{list}}">
<view bindtap="selectcar" data-id="{{item.id}}" style="width:400rpx;float:left">
<image class="nav_img" src="../image/qiche_icn.png"></image> {{item.sheng}}{{item.car_num}}</view>
<text bindtap="editcar" class="nav_xiugai" data-id="{{item.id}}">修改</text>
</view>
</view>
<view class="nav_tishiText">剩余可查询次数{{weizhang_num}}次,
<text bindtap="paynum" class="nav_tishiText_color">【点击充值】</text>
10次</view>
<button bindtap="addcar" class="btm_btn">添加车辆</button>

View File

@@ -0,0 +1,58 @@
page {
background: #f4f4f4;
}
.nav_border {
background: #fff;
}
.nav {
border-bottom: 1rpx solid rgba(0, 0, 0, 0.1);
color: #333;
font-size: 34rpx;
font-weight: 700;
height: 72rpx;
line-height: 72rpx;
margin: 0 auto;
padding: 30rpx 0;
width: 690rpx;
}
.nav_img {
border-radius: 100%;
height: 72rpx;
margin-right: 20rpx;
margin-top: -5rpx;
vertical-align: middle;
width: 72rpx;
}
.nav_xiugai {
color: #3d61f0;
float: right;
font-size: 28rpx;
font-weight: 400;
}
.nav_tishiText {
color: #7a7a7a;
font-size: 24rpx;
margin-top: 60rpx;
text-align: center;
}
.nav_tishiText_color {
color: #3d61f0;
}
.nav:last-child {
border: none;
}
.btm_btn {
background: #3d61f0;
border-radius: 20rpx;
color: #fff;
font-size: 30rpx;
height: 72rpx;
left: 0rpx;
line-height: 72rpx;
margin: 20rpx auto 0;
right: 0rpx;
width: 630rpx;
}
button::after {
border: none;
}