更换版本
This commit is contained in:
81
packageA/pages/caresgznew/carpg/carpg.js
Normal file
81
packageA/pages/caresgznew/carpg/carpg.js
Normal file
@@ -0,0 +1,81 @@
|
||||
var e;
|
||||
(e = getApp()),
|
||||
Page({
|
||||
data: { curs: 1 },
|
||||
onLoad: function (a) {
|
||||
this.getDetail(a.orderid);
|
||||
},
|
||||
getDetail: function (a) {
|
||||
var t = this,
|
||||
o = { orderid: a };
|
||||
e.getdata(o, "escgzid").then((e) => {
|
||||
if ((console.log("回调数据:", e), e)) {
|
||||
t.setData({
|
||||
orderid: a,
|
||||
cardata: e.data,
|
||||
salesdesc: e.data.carName,
|
||||
makeyear: e.data.regdate,
|
||||
carjson: JSON.parse(e.data.cardata),
|
||||
}),
|
||||
console.log("回调数据jsion:", JSON.parse(e.data.cardata));
|
||||
var o = JSON.parse(e.data.record);
|
||||
console.log(o);
|
||||
var d = o;
|
||||
t.setData({
|
||||
bad: d.retdata.car_normal,
|
||||
good: d.retdata.car_excellent,
|
||||
normal: d.retdata.car_good,
|
||||
}),
|
||||
t.data.cardata.carId;
|
||||
}
|
||||
});
|
||||
},
|
||||
getData: function (e) {
|
||||
var t = this;
|
||||
a.default.getValuation({ appType: "WECHAT", id: e }).then(function (a) {
|
||||
console.log(a),
|
||||
"1000" === a.error_code
|
||||
? t.setData({
|
||||
salesdesc: a.data.vehicle.salesdesc,
|
||||
brandname: a.data.vehicle.brandname,
|
||||
familyname: a.data.vehicle.familyname,
|
||||
factoryname: a.data.vehicle.factoryname,
|
||||
makeyear: a.data.vehicle.makeyear,
|
||||
geartype: a.data.vehicle.geartype,
|
||||
emission: a.data.vehicle.emission,
|
||||
output: a.data.vehicle.output,
|
||||
prov: a.data.bloBs.prov,
|
||||
city: a.data.bloBs.city,
|
||||
regdate: a.data.bloBs.regdate,
|
||||
mileage: a.data.bloBs.mileage,
|
||||
price: a.data.bloBs.price,
|
||||
bad: JSON.parse(a.data.bloBs.bad),
|
||||
good: JSON.parse(a.data.bloBs.good),
|
||||
normal: JSON.parse(a.data.bloBs.normal),
|
||||
})
|
||||
: wx.showToast({ title: a.message, icon: "none", duration: 3e3 });
|
||||
});
|
||||
},
|
||||
chenagestatus: function (a) {
|
||||
var e = a.currentTarget.dataset.status;
|
||||
this.setData({ curs: e });
|
||||
},
|
||||
onReady: function () {},
|
||||
onShow: function () {},
|
||||
onHide: function () {},
|
||||
onUnload: function () {},
|
||||
onPullDownRefresh: function () {},
|
||||
onReachBottom: function () {},
|
||||
onShareAppMessage: function () {
|
||||
return {
|
||||
title: this.data.salesdesc + "汽车估值报告",
|
||||
path: "/packageA/pages/caresgz/carpg/carpg?id=" + this.data.id,
|
||||
};
|
||||
},
|
||||
onShareTimeline: function () {
|
||||
return {
|
||||
title: this.data.salesdesc + "汽车估值报告",
|
||||
path: "/packageA/pages/caresgz/carpg/carpg?id=" + this.data.id,
|
||||
};
|
||||
},
|
||||
});
|
||||
3
packageA/pages/caresgznew/carpg/carpg.json
Normal file
3
packageA/pages/caresgznew/carpg/carpg.json
Normal file
@@ -0,0 +1,3 @@
|
||||
{
|
||||
"usingComponents": {}
|
||||
}
|
||||
93
packageA/pages/caresgznew/carpg/carpg.wxml
Normal file
93
packageA/pages/caresgznew/carpg/carpg.wxml
Normal file
@@ -0,0 +1,93 @@
|
||||
<view class="base_view">
|
||||
<view class="vehicle_title">{{salesdesc}}</view>
|
||||
<view class="lineview"></view>
|
||||
<view class="vehicle_set">
|
||||
<view class="vehicle-th">
|
||||
<text class="vehicle-td nnhui">购买时间</text>
|
||||
<text class="vehicle-td nnhui">上牌日期</text>
|
||||
<text class="vehicle-td nnhui">行驶里程</text>
|
||||
<text class="vehicle-td nnhui">指导价</text>
|
||||
</view>
|
||||
<view class="vehicle-th" style="margin-top: 10rpx;">
|
||||
<text class="vehicle-td">{{makeyear}}</text>
|
||||
<text class="vehicle-td">{{carjson.estimate_regdate}}</text>
|
||||
<text class="vehicle-td">{{carjson.estimate_miles}}</text>
|
||||
<text class="vehicle-td">{{carjson.g_price}}万</text>
|
||||
</view>
|
||||
<view class="vehicle-th" style="margin-top: 40rpx;">
|
||||
<text class="vehicle-td nnhui">排放标准</text>
|
||||
<text class="vehicle-td nnhui">年款</text>
|
||||
<text class="vehicle-td nnhui">变速箱</text>
|
||||
<text class="vehicle-td nnhui">排量</text>
|
||||
</view>
|
||||
<view class="vehicle-th" style="margin-top: 10rpx;">
|
||||
<text class="vehicle-td">{{carjson.c_environmentalstandards}}</text>
|
||||
<text class="vehicle-td">{{carjson.c_cyear}}</text>
|
||||
<text class="vehicle-td">{{carjson.c_bsxlx}}</text>
|
||||
<text class="vehicle-td">{{carjson.c_displacement}}</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="valuation_view">
|
||||
<view class="valuation_title">车辆估值</view>
|
||||
<view class="valuation_status">
|
||||
<view bindtap="chenagestatus" class="v_status {{curs=='1'?'s_active':''}}" data-status="1">车况一般</view>
|
||||
<view bindtap="chenagestatus" class="v_status {{curs=='2'?'s_active':''}}" data-status="2">车况较好</view>
|
||||
<view bindtap="chenagestatus" class="v_status {{curs=='3'?'s_active':''}}" data-status="3">车况优秀</view>
|
||||
</view>
|
||||
<view class="price_view">
|
||||
<view class="price_moyb">
|
||||
<text>当时新车指导价:{{carjson.g_price}}万</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="price_view {{curs=='1'?'':'noneview'}}">
|
||||
<view class="price_title">
|
||||
<text>车商零售价(万)</text>
|
||||
<text>个人零售价(万)</text>
|
||||
</view>
|
||||
<view class="price_moy">
|
||||
<text>{{bad.car_retail}}</text>
|
||||
<text>{{bad.car_personal}}</text>
|
||||
</view>
|
||||
<view class="c_price_title">车商收购价区间</view>
|
||||
<view class="c_price">
|
||||
<text>{{bad.car_purchase}}万元</text>
|
||||
<text>-</text>
|
||||
<text>{{bad.car_personal}}万元</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="price_view {{curs=='2'?'':'noneview'}}">
|
||||
<view class="price_title">
|
||||
<text>车商零售价(万)</text>
|
||||
<text>个人零售价(万)</text>
|
||||
</view>
|
||||
<view class="price_moy">
|
||||
<text>{{normal.car_retail}}</text>
|
||||
<text>{{normal.car_personal}}</text>
|
||||
</view>
|
||||
<view class="c_price_title">车商收购价区间</view>
|
||||
<view class="c_price">
|
||||
<text>{{normal.car_purchase}}万元</text>
|
||||
<text>-</text>
|
||||
<text>{{normal.car_personal}}万元</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="price_view {{curs=='3'?'':'noneview'}}">
|
||||
<view class="price_title">
|
||||
<text>车商零售价(万)</text>
|
||||
<text>个人零售价(万)</text>
|
||||
</view>
|
||||
<view class="price_moy">
|
||||
<text>{{good.car_retail}}</text>
|
||||
<text>{{good.car_personal}}</text>
|
||||
</view>
|
||||
<view class="c_price_title">车商收购价区间</view>
|
||||
<view class="c_price">
|
||||
<text>{{good.car_purchase}}万元</text>
|
||||
<text>-</text>
|
||||
<text>{{good.car_personal}}万元</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="memo">新车指导价:{{price}}万元</view>
|
||||
<view class="memo">*信息仅供参考,以实际交易为准!</view>
|
||||
</view>
|
||||
145
packageA/pages/caresgznew/carpg/carpg.wxss
Normal file
145
packageA/pages/caresgznew/carpg/carpg.wxss
Normal file
@@ -0,0 +1,145 @@
|
||||
page {
|
||||
background-color: #f1f5f6;
|
||||
height: auto;
|
||||
width: 100%;
|
||||
}
|
||||
.base_view {
|
||||
background-color: #fff;
|
||||
margin-top: 20rpx;
|
||||
width: 100%;
|
||||
}
|
||||
.vehicle_title {
|
||||
font-size: 32rpx;
|
||||
font-weight: 700;
|
||||
height: 100rpx;
|
||||
line-height: 100rpx;
|
||||
margin-left: 30rpx;
|
||||
}
|
||||
.lineview {
|
||||
background-color: #eee;
|
||||
height: 1rpx;
|
||||
width: 100%;
|
||||
}
|
||||
.vehicle_set {
|
||||
margin-top: 30rpx;
|
||||
padding-bottom: 20rpx;
|
||||
}
|
||||
.vehicle-th {
|
||||
width: 100%;
|
||||
}
|
||||
.vehicle-td {
|
||||
display: inline-block;
|
||||
font-size: 28rpx;
|
||||
text-align: center;
|
||||
width: 25%;
|
||||
}
|
||||
.nnhui {
|
||||
color: #aaa;
|
||||
}
|
||||
.valuation_view {
|
||||
background-color: #fff;
|
||||
margin-top: 20rpx;
|
||||
padding-bottom: 20rpx;
|
||||
width: 100%;
|
||||
}
|
||||
.valuation_title {
|
||||
font-size: 32rpx;
|
||||
font-weight: 700;
|
||||
height: 100rpx;
|
||||
line-height: 100rpx;
|
||||
text-align: center;
|
||||
}
|
||||
.valuation_status {
|
||||
display: -webkit-flex;
|
||||
display: flex;
|
||||
justify-content: space-around;
|
||||
width: 100%;
|
||||
}
|
||||
.v_status {
|
||||
background-color: #eee;
|
||||
border-radius: 8rpx;
|
||||
color: #aaa;
|
||||
font-size: 30rpx;
|
||||
height: 60rpx;
|
||||
line-height: 60rpx;
|
||||
text-align: center;
|
||||
width: 180rpx;
|
||||
}
|
||||
.s_active {
|
||||
background-color: #3d61f0;
|
||||
color: #fff;
|
||||
}
|
||||
.price_view {
|
||||
background-color: #fafafa;
|
||||
border-radius: 8rpx;
|
||||
margin: 20rpx;
|
||||
}
|
||||
.noneview {
|
||||
display: none;
|
||||
}
|
||||
.price_title {
|
||||
width: 100%;
|
||||
}
|
||||
.price_title text {
|
||||
display: inline-block;
|
||||
font-size: 32rpx;
|
||||
height: 80rpx;
|
||||
line-height: 80rpx;
|
||||
text-align: center;
|
||||
width: 50%;
|
||||
}
|
||||
.price_moy {
|
||||
width: 100%;
|
||||
}
|
||||
.price_moy text {
|
||||
color: #ff4500;
|
||||
display: inline-block;
|
||||
font-size: 60rpx;
|
||||
font-weight: 700;
|
||||
height: 90rpx;
|
||||
line-height: 90rpx;
|
||||
text-align: center;
|
||||
width: 50%;
|
||||
}
|
||||
.price_moyb {
|
||||
width: 100%;
|
||||
}
|
||||
.price_moyb text {
|
||||
color: #ff4500;
|
||||
display: inline-block;
|
||||
font-size: 28rpx;
|
||||
font-weight: 19000;
|
||||
height: 90rpx;
|
||||
line-height: 90rpx;
|
||||
text-align: center;
|
||||
width: 50%;
|
||||
}
|
||||
.c_price_title {
|
||||
background-color: #fff;
|
||||
border: 1rpx solid #eee;
|
||||
border-radius: 8rpx;
|
||||
font-size: 32rpx;
|
||||
height: 80rpx;
|
||||
line-height: 80rpx;
|
||||
margin-left: 25%;
|
||||
margin-top: 10rpx;
|
||||
text-align: center;
|
||||
width: 50%;
|
||||
}
|
||||
.c_price {
|
||||
width: 100%;
|
||||
}
|
||||
.c_price text {
|
||||
display: inline-block;
|
||||
font-size: 32rpx;
|
||||
height: 60rpx;
|
||||
line-height: 60rpx;
|
||||
text-align: center;
|
||||
width: 33%;
|
||||
}
|
||||
.memo {
|
||||
color: #aaa;
|
||||
font-size: 30rpx;
|
||||
margin-left: 50rpx;
|
||||
margin-top: 10rpx;
|
||||
}
|
||||
258
packageA/pages/caresgznew/index.js
Normal file
258
packageA/pages/caresgznew/index.js
Normal file
@@ -0,0 +1,258 @@
|
||||
var a, e;
|
||||
(a = getApp()),
|
||||
(e = getApp()),
|
||||
Page({
|
||||
data: {
|
||||
regdate: "",
|
||||
mileage: "",
|
||||
carName: "",
|
||||
cityName: "",
|
||||
cityid: 0,
|
||||
provid: 0,
|
||||
carId: 0,
|
||||
page: 1,
|
||||
type: 3,
|
||||
},
|
||||
mileageChanage: function (a) {
|
||||
this.setData({ mileage: a.detail.value });
|
||||
},
|
||||
queryVolation: function () {
|
||||
if (wx.getStorageSync("uid")) {
|
||||
var a = this;
|
||||
"" == a.data.carName
|
||||
? wx.showToast({ title: "车型不能为空", icon: "none", duration: 2e3 })
|
||||
: "" == a.data.cityName
|
||||
? wx.showToast({ title: "地区不能为空", icon: "none", duration: 2e3 })
|
||||
: "" == a.data.regdate
|
||||
? wx.showToast({
|
||||
title: "上牌日期不能为空",
|
||||
icon: "none",
|
||||
duration: 2e3,
|
||||
})
|
||||
: "" == a.data.mileage
|
||||
? wx.showToast({ title: "里程不能为空", icon: "none", duration: 2e3 })
|
||||
: (wx.showLoading({ title: "请求中" }), a.queryVinb());
|
||||
} else
|
||||
wx.showModal({
|
||||
title: "温馨提示",
|
||||
content: "请去个人中心授权登录用户信息",
|
||||
success: function (a) {
|
||||
a.confirm
|
||||
? wx.reLaunch({ url: "/pages/mine/index" })
|
||||
: console.log("点击取消回调");
|
||||
},
|
||||
});
|
||||
},
|
||||
queryVinb: function () {
|
||||
"iosb" == a.getSystemPlatform()
|
||||
? wx.showModal({
|
||||
title: "温馨提示",
|
||||
content: "iOS不支持小程序,请使用公众号查询",
|
||||
success: function (a) {
|
||||
a.confirm
|
||||
? wx.navigateTo({
|
||||
url:
|
||||
"/pages/website/website?url=https://mp.weixin.qq.com/s?__biz=MzIwOTYxMTI2Nw==&mid=2247483888&idx=1&sn=1f5deda3e1a2d5e109dfaf8000520030&chksm=97707e9ca007f78a7ade8b1b57eda40183c6de47a6a115836fdb77748fc248c320a29e3309c6&token=1742855998&lang=zh_CN#rd&img=" +
|
||||
wx.getStorageSync("gzhurl"),
|
||||
})
|
||||
: console.log("点击取消回调");
|
||||
},
|
||||
})
|
||||
: this.queryVin();
|
||||
},
|
||||
orderid: function () {
|
||||
let a = "";
|
||||
for (var e = 0; e < 8; e++) a += Math.floor(10 * Math.random());
|
||||
(a = "D" + new Date().getTime() + a), this.setData({ orderid: a });
|
||||
},
|
||||
queryVin: function () {
|
||||
var a = this;
|
||||
a.orderid(),
|
||||
console.log(wx.getStorageSync("uid")),
|
||||
wx.getStorageSync("uid")
|
||||
? (console.log(wx.getStorageSync("uid")),
|
||||
e.util.request({
|
||||
url: "entry/wxapp/paynum",
|
||||
data: {
|
||||
m: "monai_market",
|
||||
type: "escgz_money",
|
||||
orderid: a.data.orderid,
|
||||
uid: wx.getStorageSync("uid"),
|
||||
},
|
||||
success: function (t) {
|
||||
t.data && t.data.data && 1e3 == t.data.message
|
||||
? e.util.request({
|
||||
url: "entry/wxapp/Api",
|
||||
data: {
|
||||
m: "monai_market",
|
||||
uid: wx.getStorageSync("uid"),
|
||||
r: "home.weizhang.paynum",
|
||||
orderid: t.data.data.orderid,
|
||||
},
|
||||
success: function (e) {
|
||||
wx.showModal({ content: e.data.message }),
|
||||
a.setData({
|
||||
weizhang_num: 1 * a.data.weizhang_num + 10,
|
||||
}),
|
||||
a.getDetailpay();
|
||||
},
|
||||
})
|
||||
: t.data &&
|
||||
t.data.data &&
|
||||
!t.data.errno &&
|
||||
wx.requestPayment({
|
||||
timeStamp: t.data.data.timeStamp,
|
||||
nonceStr: t.data.data.nonceStr,
|
||||
package: t.data.data.package,
|
||||
signType: "MD5",
|
||||
paySign: t.data.data.paySign,
|
||||
success: function (i) {
|
||||
e.util.request({
|
||||
url: "entry/wxapp/Api",
|
||||
data: {
|
||||
m: "monai_market",
|
||||
uid: wx.getStorageSync("uid"),
|
||||
r: "home.weizhang.paynum",
|
||||
orderid: t.data.data.orderid,
|
||||
},
|
||||
success: function (e) {
|
||||
a.setData({
|
||||
weizhang_num: 1 * a.data.weizhang_num + 10,
|
||||
}),
|
||||
wx.showModal({ content: e.data.message }),
|
||||
a.getDetailpay();
|
||||
},
|
||||
});
|
||||
},
|
||||
});
|
||||
},
|
||||
}))
|
||||
: wx.showModal({
|
||||
title: "温馨提醒",
|
||||
content: "使用本功能请先登录后在使用~",
|
||||
showCancel: !1,
|
||||
success: function (a) {
|
||||
a.confirm && wx.reLaunch({ url: "/pages/mine/index" });
|
||||
},
|
||||
});
|
||||
},
|
||||
getDetailpay: function (e) {
|
||||
var t = this,
|
||||
i = this.data,
|
||||
n = {
|
||||
cardata: t.data.cardata,
|
||||
uid: wx.getStorageSync("uid"),
|
||||
carName: i.carName,
|
||||
cityName: i.cityName,
|
||||
regdate: i.regdate,
|
||||
cityid: i.cityid,
|
||||
provid: i.provid,
|
||||
carId: i.carId,
|
||||
mileage: i.mileage,
|
||||
orderid: t.data.orderid,
|
||||
};
|
||||
a.getdata(n, "escgzapinew").then((a) => {
|
||||
console.log("回调数据:", a),
|
||||
a &&
|
||||
wx.navigateTo({
|
||||
url:
|
||||
"/packageA/pages/caresgznew/carpg/carpg?orderid=" +
|
||||
t.data.orderid,
|
||||
});
|
||||
});
|
||||
},
|
||||
toDetailExample: function () {
|
||||
wx.navigateTo({
|
||||
url: "../caresgznew/carpg/carpg?orderid=D165026490694147402592",
|
||||
});
|
||||
},
|
||||
toSelectCar: function () {
|
||||
wx.navigateTo({ url: "../caresgznew/selectCar/selectCar" });
|
||||
},
|
||||
toSelectCity: function () {
|
||||
wx.navigateTo({ url: "../caresgznew/selectCity/selectCity" });
|
||||
},
|
||||
toSelectTime: function () {
|
||||
wx.navigateTo({ url: "../caresgznew/selectTime/selectTime" });
|
||||
},
|
||||
onLoad: function (a) {
|
||||
wx.getStorageSync("uid") || getApp().wxlogin(),
|
||||
this.orderid(),
|
||||
wx.removeStorageSync("carvehicle"),
|
||||
wx.removeStorageSync("carprov"),
|
||||
wx.removeStorageSync("carcity"),
|
||||
wx.removeStorageSync("cartime"),
|
||||
wx.removeStorageSync("cardatawx");
|
||||
},
|
||||
onReady: function () {},
|
||||
onShow: function () {
|
||||
a.appdengl();
|
||||
var e = wx.getStorageSync("carvehicle"),
|
||||
t = wx.getStorageSync("carprov"),
|
||||
i = wx.getStorageSync("carcity"),
|
||||
n = wx.getStorageSync("cartime"),
|
||||
o = "";
|
||||
"" != i && null != i && (o = t.name + "-" + i.name),
|
||||
console.log("" == e),
|
||||
"" != e &&
|
||||
"" != n &&
|
||||
parseInt(n.split("-")[0]) < parseInt(e.makeyear) &&
|
||||
(n = ""),
|
||||
this.setData({
|
||||
cardata: e,
|
||||
carName: e.fullname,
|
||||
cityName: o,
|
||||
regdate: n,
|
||||
cityid: i.id,
|
||||
provid: t.id,
|
||||
carId: e.id,
|
||||
}),
|
||||
this.getDetail(1);
|
||||
},
|
||||
onPullDownRefresh: function () {
|
||||
this.clearCache(), this.getArticles(1);
|
||||
},
|
||||
onReachBottom: function () {
|
||||
console.log("加上"), this.getDetail(this.data.page);
|
||||
},
|
||||
clearCache: function () {
|
||||
this.setData({ repairList: [], page: 1 });
|
||||
},
|
||||
getDetail: function (e) {
|
||||
var t = this,
|
||||
i = { uid: wx.getStorageSync("uid"), type: t.data.type, page: e };
|
||||
a.getdata(i, "carqxcx").then((a) => {
|
||||
if ((console.log("回调数据:", a), a.data && 0 == a.errno))
|
||||
if (1 == e) t.setData({ repairList: a.data, page: t.data.page + 1 });
|
||||
else {
|
||||
var i = t.data.repairList;
|
||||
i.push.apply(i, a.data),
|
||||
t.setData({ repairList: i, page: t.data.page + 1 });
|
||||
}
|
||||
});
|
||||
},
|
||||
onHide: function () {},
|
||||
onUnload: function () {},
|
||||
onShareAppMessage: function () {},
|
||||
showRenMsg: function () {
|
||||
wx.showToast({
|
||||
title: "人工查询中,请稍等",
|
||||
icon: "none",
|
||||
duration: 3e3,
|
||||
});
|
||||
},
|
||||
showGaoMsg: function () {
|
||||
wx.showToast({
|
||||
title: "查不到记录,建议使用高级出险查询。",
|
||||
icon: "none",
|
||||
duration: 3e3,
|
||||
});
|
||||
},
|
||||
getDangerDetail: function (a) {
|
||||
var e = a.currentTarget.dataset.orderid;
|
||||
wx.navigateTo({
|
||||
url: "/packageA/pages/caresgznew/carpg/carpg?orderid=" + e,
|
||||
success: function () {},
|
||||
});
|
||||
},
|
||||
});
|
||||
3
packageA/pages/caresgznew/index.json
Normal file
3
packageA/pages/caresgznew/index.json
Normal file
@@ -0,0 +1,3 @@
|
||||
{
|
||||
"usingComponents": {}
|
||||
}
|
||||
56
packageA/pages/caresgznew/index.wxml
Normal file
56
packageA/pages/caresgznew/index.wxml
Normal file
@@ -0,0 +1,56 @@
|
||||
<view class="search-title">二手车估值</view>
|
||||
<view class="search-text">根据车型和市场查询到市场行情,车商收车价,市场成交价。</view>
|
||||
<view class="vin-input">
|
||||
<text class="opt-name">车型</text>
|
||||
<block wx:if="{{carName==''}}">
|
||||
<text bindtap="toSelectCar" class="opt-input">请选择车型</text>
|
||||
<text class="arrow"></text>
|
||||
</block>
|
||||
<text bindtap="toSelectCar" class="opt-input suredata" wx:else>{{carName}}</text>
|
||||
</view>
|
||||
<view class="vin-input">
|
||||
<text class="opt-name">所在地区</text>
|
||||
<block wx:if="{{cityName==''}}">
|
||||
<text bindtap="toSelectCity" class="opt-input">请选择地区</text>
|
||||
<text class="arrow"></text>
|
||||
</block>
|
||||
<text bindtap="toSelectCity" class="opt-input suredata" wx:else>{{cityName}}</text>
|
||||
</view>
|
||||
<view class="vin-input">
|
||||
<text class="opt-name">首次上牌</text>
|
||||
<block wx:if="{{regdate==''}}">
|
||||
<text bindtap="toSelectTime" class="opt-input">请选择上牌日期</text>
|
||||
<text class="arrow"></text>
|
||||
</block>
|
||||
<text bindtap="toSelectTime" class="opt-input suredata" wx:else>{{regdate}}</text>
|
||||
</view>
|
||||
<view class="vin-input">
|
||||
<text class="opt-name" style="width: 50%">里程(万公里)</text>
|
||||
<input bindinput="mileageChanage" class="opt-input" placeholder="请输入公里数" placeholderStyle="color:#b1b1b1" style="width: 40%;color:#000;margin-right:5%" type="digit" value="{{mileage}}"></input>
|
||||
</view>
|
||||
<button bindtap="queryVolation" class="search-button">开始估值</button>
|
||||
<view class="help-view">
|
||||
<text bindtap="toDetailExample" class="help-example">样例报告</text>
|
||||
</view>
|
||||
<view style="height:10rpx;"></view>
|
||||
<view class="topbb" wx:if="{{repairList.length>0}}">
|
||||
<view class="title">
|
||||
<view class="main">二手车估值查询记录</view>
|
||||
</view>
|
||||
<view data-index="{{index}}" wx:for="{{repairList}}" wx:key="index">
|
||||
<view class="contentView">
|
||||
<text bindtap="copyText" class="orderNum" data-text="{{item.vin}}">订单编号:{{item.orderid}}</text>
|
||||
<view class="lineView"></view>
|
||||
<view bindtap="{{item.queryStatus=='2'?'getDangerDetail':item.queryStatus=='4'?'showRenMsg':item.queryStatus=='3'?'showGaoMsg':''}}" data-brand="{{item.car}}" data-logo="{{item.logo}}" data-orderid="{{item.orderid}}" data-querytype="{{item.queryType}}" data-time="{{item.queryTimeStr}}" data-version="{{item.queryVersion}}">
|
||||
<image class="logo-img" mode="widthFix" src="{{item.logo}}"></image>
|
||||
<view class="text-view">
|
||||
<text class="name-text">{{item.carName}}</text>
|
||||
<text class="statusView {{item.queryStatus=='1'?'underwayView':item.queryStatus=='2'?'ingView':item.queryStatus=='4'?'underwayView':'successView'}}">{{item.queryStatus=='1'?'查询中...':item.queryStatus=='2'?'已出报告':item.queryStatus=='4'?'人工处理':'无记录'}}</text>
|
||||
<text class="{{item.hasRefund=='2'?'refundView successView':'noneView'}}">{{item.hasRefund=='2'?'已退款':'退款中...'}}</text>
|
||||
<text class="hui-text">{{item.vin}}</text>
|
||||
<text class="hui-text">{{item.time}}</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
125
packageA/pages/caresgznew/index.wxss
Normal file
125
packageA/pages/caresgznew/index.wxss
Normal file
@@ -0,0 +1,125 @@
|
||||
@import "/graceUI/reporlist.wxss";
|
||||
.topbb {
|
||||
height: 215px;
|
||||
margin: 10px;
|
||||
top: 20px;
|
||||
}
|
||||
.top,
|
||||
.topbb {
|
||||
position: relative;
|
||||
}
|
||||
.top {
|
||||
height: 135px;
|
||||
}
|
||||
.top .title .main {
|
||||
background: #3d61f0;
|
||||
border: 1px solid #3d61f0;
|
||||
border-radius: 0.5rem 3rem 3rem 3rem;
|
||||
color: #fff;
|
||||
display: inline-block;
|
||||
font-weight: 300;
|
||||
margin: 16px 10px 10px;
|
||||
padding: 8px;
|
||||
}
|
||||
.top .title .sub {
|
||||
color: #636364;
|
||||
font-size: 1rem;
|
||||
font-weight: 300;
|
||||
margin: 10px;
|
||||
width: 180px;
|
||||
}
|
||||
.top image {
|
||||
bottom: -1rem;
|
||||
position: absolute;
|
||||
right: 0;
|
||||
width: 10rem;
|
||||
z-index: 10;
|
||||
}
|
||||
.search-title {
|
||||
font-size: 50rpx;
|
||||
font-weight: 700;
|
||||
margin-bottom: 60rpx;
|
||||
margin-top: 120rpx;
|
||||
text-align: center;
|
||||
}
|
||||
.search-text {
|
||||
border-radius: 10rpx;
|
||||
color: #86868b;
|
||||
font-size: 35rpx;
|
||||
font-size: 34rpx;
|
||||
line-height: 40rpx;
|
||||
margin: auto auto 120rpx;
|
||||
width: 89%;
|
||||
}
|
||||
.vin-input {
|
||||
background: #f2f2f2;
|
||||
display: -webkit-flex;
|
||||
display: flex;
|
||||
height: 100rpx;
|
||||
margin-bottom: 20rpx;
|
||||
margin-left: 5%;
|
||||
width: 90%;
|
||||
}
|
||||
.opt-name {
|
||||
font-weight: 700;
|
||||
margin-left: 6%;
|
||||
width: 30%;
|
||||
}
|
||||
.opt-input,
|
||||
.opt-name {
|
||||
height: 100rpx;
|
||||
line-height: 100rpx;
|
||||
}
|
||||
.opt-input {
|
||||
color: #b1b1b1;
|
||||
margin-right: 7%;
|
||||
text-align: right;
|
||||
width: 60%;
|
||||
}
|
||||
.search-button {
|
||||
background: #3d61f0 !important;
|
||||
border-radius: 10rpx;
|
||||
color: #fff !important;
|
||||
height: 100rpx !important;
|
||||
line-height: 100rpx !important;
|
||||
margin-top: 40rpx;
|
||||
padding: 0rpx !important;
|
||||
width: 93% !important;
|
||||
}
|
||||
.help-view {
|
||||
font-size: 31rpx;
|
||||
padding: 30rpx;
|
||||
}
|
||||
.help-example {
|
||||
color: #3d61f0;
|
||||
float: left;
|
||||
}
|
||||
.help-wht {
|
||||
color: #f0803e;
|
||||
float: right;
|
||||
}
|
||||
.camera-nav {
|
||||
display: inline-block;
|
||||
}
|
||||
.camera-img {
|
||||
height: 66rpx;
|
||||
margin-bottom: -14rpx;
|
||||
width: 75rpx;
|
||||
}
|
||||
.arrow {
|
||||
border-right: 1px solid #b1b1b1;
|
||||
border-top: 1px solid #b1b1b1;
|
||||
color: #b1b1b1;
|
||||
height: 10px;
|
||||
margin-top: 38rpx;
|
||||
position: absolute;
|
||||
right: 60rpx;
|
||||
transform: rotate(45deg);
|
||||
width: 10px;
|
||||
}
|
||||
.suredata {
|
||||
color: #000;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
177
packageA/pages/caresgznew/selectCar/selectCar.js
Normal file
177
packageA/pages/caresgznew/selectCar/selectCar.js
Normal file
@@ -0,0 +1,177 @@
|
||||
var t;
|
||||
(t = getApp()),
|
||||
Page({
|
||||
data: {
|
||||
showLetter: "",
|
||||
winHeight: 0,
|
||||
tHeight: 0,
|
||||
bHeight: 0,
|
||||
startPageY: 0,
|
||||
carList: [],
|
||||
isShowLetter: !1,
|
||||
scrollTop: 0,
|
||||
three_none: "none",
|
||||
two_none: "none",
|
||||
hasback: "none",
|
||||
car_series: [],
|
||||
car_ser: null,
|
||||
searchLetter: [
|
||||
"*",
|
||||
"A",
|
||||
"B",
|
||||
"C",
|
||||
"D",
|
||||
"E",
|
||||
"F",
|
||||
"G",
|
||||
"H",
|
||||
"J",
|
||||
"K",
|
||||
"L",
|
||||
"M",
|
||||
"N",
|
||||
"P",
|
||||
"Q",
|
||||
"R",
|
||||
"S",
|
||||
"T",
|
||||
"W",
|
||||
"X",
|
||||
"Y",
|
||||
"Z",
|
||||
],
|
||||
car_vend_ser: [],
|
||||
},
|
||||
onLoad: function () {
|
||||
var e = this;
|
||||
wx.showLoading({ title: "请求中" }),
|
||||
t.getdata({ type: 1, pid: 0 }, "carallnew").then((t) => {
|
||||
var a = t.data;
|
||||
console.log("回调数据汽车:", t), e.crCarList(a);
|
||||
});
|
||||
for (
|
||||
var a = e.data.searchLetter,
|
||||
n = wx.getSystemInfoSync().windowHeight,
|
||||
o = n / a.length,
|
||||
r = [],
|
||||
s = 0;
|
||||
s < a.length;
|
||||
s++
|
||||
) {
|
||||
var i = {};
|
||||
(i.name = a[s]),
|
||||
(i.tHeight = s * o),
|
||||
(i.bHeight = (s + 1) * o),
|
||||
r.push(i);
|
||||
}
|
||||
e.setData({ winHeight: n, itemH: o, searchLetter: r });
|
||||
},
|
||||
searchStart: function (t) {
|
||||
var e = t.currentTarget.dataset.letter,
|
||||
a = t.touches[0].pageY;
|
||||
this.setScrollTop(this, e),
|
||||
this.nowLetter(a, this),
|
||||
this.setData({ showLetter: e, startPageY: a, isShowLetter: !0 });
|
||||
},
|
||||
searchMove: function (t) {
|
||||
var e = t.touches[0].pageY,
|
||||
a = this.data.startPageY,
|
||||
n = this.data.tHeight,
|
||||
o = this.data.bHeight;
|
||||
console.log(e),
|
||||
a - e > 0
|
||||
? e < n && this.nowLetter(e, this)
|
||||
: e > o && this.nowLetter(e, this);
|
||||
},
|
||||
searchEnd: function (t) {
|
||||
var e = this;
|
||||
setTimeout(function () {
|
||||
e.setData({ isShowLetter: !1 });
|
||||
}, 1e3);
|
||||
},
|
||||
nowLetter: function (t, e) {
|
||||
for (
|
||||
var a = this.data.searchLetter, n = 0, o = 0, r = "", s = 0;
|
||||
s < a.length;
|
||||
s++
|
||||
)
|
||||
if (a[s].tHeight <= t && t <= a[s].bHeight) {
|
||||
(n = a[s].bHeight), (o = a[s].tHeight), (r = a[s].name);
|
||||
break;
|
||||
}
|
||||
this.setScrollTop(e, r),
|
||||
e.setData({ bHeight: n, tHeight: o, showLetter: r, startPageY: t });
|
||||
},
|
||||
setScrollTop: function (t, e) {
|
||||
for (
|
||||
var a = 0, n = t.data.carList, o = 0, r = 0, s = 0;
|
||||
s < n.length;
|
||||
s++
|
||||
) {
|
||||
if (e == n[s].shou_zm) {
|
||||
a = 30 * r + 41 * o;
|
||||
break;
|
||||
}
|
||||
console.log("数字", s),
|
||||
console.log(n[s]),
|
||||
r++,
|
||||
(o += n[s].carInfo.length);
|
||||
}
|
||||
t.setData({ scrollTop: a });
|
||||
},
|
||||
btn_pinpai: function (e) {
|
||||
var a = this,
|
||||
n = { type: 2, pid: e.currentTarget.dataset.brand };
|
||||
t.getdata(n, "carallnew").then((t) => {
|
||||
var e = t.data;
|
||||
console.log("回调数据汽车:", e),
|
||||
a.setData({
|
||||
three_none: "none",
|
||||
two_none: "block",
|
||||
hasback: "block",
|
||||
car_series: e,
|
||||
});
|
||||
});
|
||||
},
|
||||
btn_name: function (e) {
|
||||
var a = this,
|
||||
n = { type: 3, pid: e.currentTarget.dataset.familyid };
|
||||
t.getdata(n, "carallnew").then((t) => {
|
||||
var e = t.data;
|
||||
console.log("回调数据汽车xiang:", e),
|
||||
a.setData({ three_none: "block", hasback: "block", car_vend_ser: e });
|
||||
});
|
||||
},
|
||||
btn_sel_name: function (t) {
|
||||
var e = t.currentTarget.dataset.item;
|
||||
console.log(e),
|
||||
wx.setStorageSync("carvehicle", e),
|
||||
wx.navigateBack({ delta: 1 });
|
||||
},
|
||||
crCarList: function (t) {
|
||||
for (var e = this.data.searchLetter, a = [], n = 1; n < e.length; n++) {
|
||||
var o = e[n].name,
|
||||
r = [],
|
||||
s = {};
|
||||
s.shou_zm = o;
|
||||
for (var i = 0; i < t.length; i++) o == t[i].sort && r.push(t[i]);
|
||||
(s.carInfo = r), a.push(s);
|
||||
}
|
||||
this.setData({ carList: a }), wx.hideLoading();
|
||||
},
|
||||
crFamilyList: function (t) {
|
||||
var e = {};
|
||||
for (var a in (console.log(t), t)) {
|
||||
var n = t[a].factory;
|
||||
null == e[n] ? (e[n] = [t[a]]) : e[n].push(t[a]);
|
||||
}
|
||||
console.log(e), this.setData({ car_series: e });
|
||||
},
|
||||
goback: function () {
|
||||
"block" == this.data.three_none
|
||||
? this.setData({ three_none: "none" })
|
||||
: "block" == this.data.two_none
|
||||
? this.setData({ two_none: "none", hasback: "none" })
|
||||
: this.setData({ hasback: "none" });
|
||||
},
|
||||
});
|
||||
3
packageA/pages/caresgznew/selectCar/selectCar.json
Normal file
3
packageA/pages/caresgznew/selectCar/selectCar.json
Normal file
@@ -0,0 +1,3 @@
|
||||
{
|
||||
"usingComponents": {}
|
||||
}
|
||||
25
packageA/pages/caresgznew/selectCar/selectCar.wxml
Normal file
25
packageA/pages/caresgznew/selectCar/selectCar.wxml
Normal file
@@ -0,0 +1,25 @@
|
||||
<view>
|
||||
<view class="searchLetter touchClass">
|
||||
<view catchtouchend="searchEnd" catchtouchmove="searchMove" catchtouchstart="searchStart" data-letter="{{item.name}}" style="height:{{itemH}}px" wx:for="{{searchLetter}}" wx:key="index"> {{item.name}} </view>
|
||||
</view>
|
||||
<view class="showSlectedLetter" wx:if="{{isShowLetter}}"> {{showLetter}} </view>
|
||||
<scroll-view scrollTop="{{scrollTop}}" scrollY="true" style="height:{{winHeight}}px">
|
||||
<view class="selection" wx:if="{{carList.length>0}}" wx:for="{{carList}}" wx:key="index">
|
||||
<view class="item_letter">{{item.shou_zm}}</view>
|
||||
<view bindtap="btn_pinpai" class="item_city" data-brand="{{ct.brand_id}}" wx:for="{{item.carInfo}}" wx:for-item="ct" wx:key="index"> {{ct.name}} </view>
|
||||
</view>
|
||||
</scroll-view>
|
||||
<scroll-view class="scoll_car_service" scrollY="true" style="height:{{car_type_hight}};display:{{two_none}}">
|
||||
<view class="selection" wx:for="{{car_series}}" wx:key="index">
|
||||
<label bindtap="btn_name" class="tab2" data-brandid="{{item.brand_id}}" data-familyid="{{item.series_id}}"> {{item.series_name}} </label>
|
||||
</view>
|
||||
</scroll-view>
|
||||
<scroll-view class="scoll_vender_service" scrollY="true" style="height:{{car_type_hight}};display:{{three_none}}">
|
||||
<view wx:for="{{car_vend_ser}}" wx:key="index">
|
||||
<text bindtap="btn_sel_name" class="tab3" data-item="{{item}}">{{item.fullname}}</text>
|
||||
</view>
|
||||
</scroll-view>
|
||||
</view>
|
||||
<view bindtap="goback" class="goback" style="display:{{hasback}}">
|
||||
<text class="arrow"></text>
|
||||
</view>
|
||||
125
packageA/pages/caresgznew/selectCar/selectCar.wxss
Normal file
125
packageA/pages/caresgznew/selectCar/selectCar.wxss
Normal file
@@ -0,0 +1,125 @@
|
||||
.searchLetter {
|
||||
color: #666;
|
||||
display: -webkit-flex;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
height: 100%;
|
||||
justify-content: center;
|
||||
position: fixed;
|
||||
right: 0;
|
||||
text-align: center;
|
||||
width: 40px;
|
||||
z-index: 1;
|
||||
}
|
||||
.tab2 {
|
||||
height: 70rpx;
|
||||
line-height: 70rpx;
|
||||
width: 560rpx;
|
||||
}
|
||||
.tab2,
|
||||
.tab3 {
|
||||
border-bottom: 1px solid #eaeaea;
|
||||
color: #2a2a2a;
|
||||
font-size: 30rpx;
|
||||
padding-left: 30rpx;
|
||||
}
|
||||
.tab3 {
|
||||
word-wrap: break-word;
|
||||
display: block;
|
||||
overflow: hidden;
|
||||
padding-bottom: 20rpx;
|
||||
padding-top: 20rpx;
|
||||
}
|
||||
.scoll_car_service {
|
||||
left: 25%;
|
||||
width: 75%;
|
||||
z-index: 5;
|
||||
}
|
||||
.scoll_car_service,
|
||||
.scoll_vender_service {
|
||||
background-color: #f5f5f5;
|
||||
box-shadow: 0 0 3px 3px #999;
|
||||
display: -webkit-flex;
|
||||
display: flex;
|
||||
height: 100%;
|
||||
position: fixed;
|
||||
top: 1px;
|
||||
}
|
||||
.scoll_vender_service {
|
||||
left: 50%;
|
||||
width: 50%;
|
||||
z-index: 10;
|
||||
}
|
||||
.searchLetter view {
|
||||
height: 70rpx;
|
||||
}
|
||||
.touchClass {
|
||||
color: #a56e0a;
|
||||
font-size: 28rpx;
|
||||
}
|
||||
.showSlectedLetter {
|
||||
align-items: center;
|
||||
background-color: rgba(0, 0, 0, 0.5);
|
||||
border-radius: 10px;
|
||||
color: #fff;
|
||||
font-size: 26px;
|
||||
height: 100px;
|
||||
justify-content: center;
|
||||
left: 50%;
|
||||
margin: -50px;
|
||||
position: fixed;
|
||||
top: 50%;
|
||||
width: 100px;
|
||||
z-index: 1;
|
||||
}
|
||||
.selection,
|
||||
.showSlectedLetter {
|
||||
display: -webkit-flex;
|
||||
display: flex;
|
||||
}
|
||||
.selection {
|
||||
flex-direction: column;
|
||||
width: 100%;
|
||||
}
|
||||
.item_letter {
|
||||
align-items: center;
|
||||
background-color: #f8f8f8;
|
||||
color: #896a0d;
|
||||
display: -webkit-flex;
|
||||
display: flex;
|
||||
font-size: 26rpx;
|
||||
height: 30px;
|
||||
padding-left: 10px;
|
||||
}
|
||||
.item_city {
|
||||
background-color: #f5f5f5;
|
||||
border-bottom: 1px solid #eaeaea;
|
||||
color: #2a2a2a;
|
||||
font-size: 30rpx;
|
||||
height: 40px;
|
||||
line-height: 40px;
|
||||
padding-left: 10px;
|
||||
}
|
||||
.car_img {
|
||||
height: 80rpx;
|
||||
width: 100rpx;
|
||||
}
|
||||
.goback {
|
||||
border: 2rpx solid #aaa;
|
||||
border-radius: 50%;
|
||||
bottom: 60rpx;
|
||||
height: 80rpx;
|
||||
position: fixed;
|
||||
right: 40rpx;
|
||||
width: 80rpx;
|
||||
z-index: 99;
|
||||
}
|
||||
.arrow {
|
||||
border-bottom: 3px solid #999;
|
||||
border-left: 3px solid #999;
|
||||
display: block;
|
||||
height: 14px;
|
||||
margin: 24rpx 30rpx;
|
||||
transform: rotate(45deg);
|
||||
width: 14px;
|
||||
}
|
||||
47
packageA/pages/caresgznew/selectCity/selectCity.js
Normal file
47
packageA/pages/caresgznew/selectCity/selectCity.js
Normal file
@@ -0,0 +1,47 @@
|
||||
var t;
|
||||
(t = getApp()),
|
||||
Page({
|
||||
data: {
|
||||
winHeight: 0,
|
||||
tHeight: 0,
|
||||
bHeight: 0,
|
||||
startPageY: 0,
|
||||
scrollTop: 0,
|
||||
two_none: "none",
|
||||
hasback: "none",
|
||||
prov_list: [],
|
||||
city_list: [],
|
||||
},
|
||||
onLoad: function () {
|
||||
var a = this;
|
||||
wx.showLoading({ title: "请求中" }),
|
||||
t.getdata("", "carcitynew").then((t) => {
|
||||
var e = t.data;
|
||||
console.log("回调数据汽车:", e), a.setData({ prov_list: e });
|
||||
});
|
||||
var e = wx.getSystemInfoSync().windowHeight;
|
||||
a.setData({ winHeight: e });
|
||||
},
|
||||
btn_pinpai: function (t) {
|
||||
var a = t.currentTarget.dataset.name;
|
||||
wx.setStorageSync("carprov", a),
|
||||
this.setData({
|
||||
two_none: "block",
|
||||
hasback: "block",
|
||||
city_list: t.currentTarget.dataset.item,
|
||||
});
|
||||
},
|
||||
btn_sel_name: function (t) {
|
||||
var a = t.currentTarget.dataset.item;
|
||||
console.log(a),
|
||||
wx.setStorageSync("carcity", a),
|
||||
wx.navigateBack({ delta: 1 });
|
||||
},
|
||||
goback: function () {
|
||||
"block" == this.data.three_none
|
||||
? this.setData({ three_none: "none" })
|
||||
: "block" == this.data.two_none
|
||||
? this.setData({ two_none: "none", hasback: "none" })
|
||||
: this.setData({ hasback: "none" });
|
||||
},
|
||||
});
|
||||
3
packageA/pages/caresgznew/selectCity/selectCity.json
Normal file
3
packageA/pages/caresgznew/selectCity/selectCity.json
Normal file
@@ -0,0 +1,3 @@
|
||||
{
|
||||
"usingComponents": {}
|
||||
}
|
||||
15
packageA/pages/caresgznew/selectCity/selectCity.wxml
Normal file
15
packageA/pages/caresgznew/selectCity/selectCity.wxml
Normal file
@@ -0,0 +1,15 @@
|
||||
<view>
|
||||
<scroll-view scrollY="true" style="height:{{winHeight}}px">
|
||||
<view class="selection" wx:for="{{prov_list}}" wx:key="index">
|
||||
<view bindtap="btn_pinpai" class="item_city" data-item="{{item.child}}" data-name="{{item}}"> {{item.name}} </view>
|
||||
</view>
|
||||
</scroll-view>
|
||||
<scroll-view class="scoll_car_service" scrollY="true" style="height:{{car_type_hight}};display:{{two_none}}">
|
||||
<view class="selection" wx:for="{{city_list}}" wx:key="index">
|
||||
<label bindtap="btn_sel_name" class="tab2" data-item="{{item}}"> {{item.name}} </label>
|
||||
</view>
|
||||
</scroll-view>
|
||||
</view>
|
||||
<view bindtap="goback" class="goback" style="display:{{hasback}}">
|
||||
<text class="arrow"></text>
|
||||
</view>
|
||||
125
packageA/pages/caresgznew/selectCity/selectCity.wxss
Normal file
125
packageA/pages/caresgznew/selectCity/selectCity.wxss
Normal file
@@ -0,0 +1,125 @@
|
||||
.searchLetter {
|
||||
color: #666;
|
||||
display: -webkit-flex;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
height: 100%;
|
||||
justify-content: center;
|
||||
position: fixed;
|
||||
right: 0;
|
||||
text-align: center;
|
||||
width: 40px;
|
||||
z-index: 1;
|
||||
}
|
||||
.tab2 {
|
||||
height: 80rpx;
|
||||
line-height: 80rpx;
|
||||
width: 560rpx;
|
||||
}
|
||||
.tab2,
|
||||
.tab3 {
|
||||
border-bottom: 1px solid #eaeaea;
|
||||
color: #2a2a2a;
|
||||
font-size: 30rpx;
|
||||
padding-left: 30rpx;
|
||||
}
|
||||
.tab3 {
|
||||
word-wrap: break-word;
|
||||
display: block;
|
||||
overflow: hidden;
|
||||
padding-bottom: 20rpx;
|
||||
padding-top: 20rpx;
|
||||
}
|
||||
.scoll_car_service {
|
||||
left: 25%;
|
||||
width: 75%;
|
||||
z-index: 5;
|
||||
}
|
||||
.scoll_car_service,
|
||||
.scoll_vender_service {
|
||||
background-color: #f5f5f5;
|
||||
box-shadow: 0 0 3px 3px #999;
|
||||
display: -webkit-flex;
|
||||
display: flex;
|
||||
height: 100%;
|
||||
position: fixed;
|
||||
top: 1px;
|
||||
}
|
||||
.scoll_vender_service {
|
||||
left: 50%;
|
||||
width: 50%;
|
||||
z-index: 10;
|
||||
}
|
||||
.searchLetter view {
|
||||
height: 70rpx;
|
||||
}
|
||||
.touchClass {
|
||||
color: #a56e0a;
|
||||
font-size: 28rpx;
|
||||
}
|
||||
.showSlectedLetter {
|
||||
align-items: center;
|
||||
background-color: rgba(0, 0, 0, 0.5);
|
||||
border-radius: 10px;
|
||||
color: #fff;
|
||||
font-size: 26px;
|
||||
height: 100px;
|
||||
justify-content: center;
|
||||
left: 50%;
|
||||
margin: -50px;
|
||||
position: fixed;
|
||||
top: 50%;
|
||||
width: 100px;
|
||||
z-index: 1;
|
||||
}
|
||||
.selection,
|
||||
.showSlectedLetter {
|
||||
display: -webkit-flex;
|
||||
display: flex;
|
||||
}
|
||||
.selection {
|
||||
flex-direction: column;
|
||||
width: 100%;
|
||||
}
|
||||
.item_letter {
|
||||
align-items: center;
|
||||
background-color: #f8f8f8;
|
||||
color: #896a0d;
|
||||
display: -webkit-flex;
|
||||
display: flex;
|
||||
font-size: 26rpx;
|
||||
height: 30px;
|
||||
padding-left: 10px;
|
||||
}
|
||||
.item_city {
|
||||
background-color: #f5f5f5;
|
||||
border-bottom: 1px solid #eaeaea;
|
||||
color: #2a2a2a;
|
||||
font-size: 30rpx;
|
||||
height: 34px;
|
||||
line-height: 34px;
|
||||
padding-left: 10px;
|
||||
}
|
||||
.car_img {
|
||||
height: 80rpx;
|
||||
width: 100rpx;
|
||||
}
|
||||
.goback {
|
||||
border: 2rpx solid #aaa;
|
||||
border-radius: 50%;
|
||||
bottom: 60rpx;
|
||||
height: 80rpx;
|
||||
position: fixed;
|
||||
right: 40rpx;
|
||||
width: 80rpx;
|
||||
z-index: 99;
|
||||
}
|
||||
.arrow {
|
||||
border-bottom: 3px solid #999;
|
||||
border-left: 3px solid #999;
|
||||
display: block;
|
||||
height: 14px;
|
||||
margin: 24rpx 30rpx;
|
||||
transform: rotate(45deg);
|
||||
width: 14px;
|
||||
}
|
||||
56
packageA/pages/caresgznew/selectTime/selectTime.js
Normal file
56
packageA/pages/caresgznew/selectTime/selectTime.js
Normal file
@@ -0,0 +1,56 @@
|
||||
Page({
|
||||
data: {
|
||||
winHeight: 0,
|
||||
two_none: "none",
|
||||
hasback: "none",
|
||||
year_list: [],
|
||||
mouth_list: [
|
||||
"01",
|
||||
"02",
|
||||
"03",
|
||||
"04",
|
||||
"05",
|
||||
"06",
|
||||
"07",
|
||||
"08",
|
||||
"09",
|
||||
"10",
|
||||
"11",
|
||||
"12",
|
||||
],
|
||||
year: "",
|
||||
},
|
||||
onLoad: function () {
|
||||
var t = wx.getSystemInfoSync().windowHeight;
|
||||
this.setData({ winHeight: t, year_list: this.getsortyear() });
|
||||
},
|
||||
getsortyear: function () {
|
||||
var t = [],
|
||||
e = wx.getStorageSync("carvehicle"),
|
||||
a = new Date().getFullYear();
|
||||
if (null != e && "" != e && null != e.makeyear)
|
||||
for (var n = 0; n < a && a - n >= parseInt(e.makeyear); n++)
|
||||
t.push(a - n);
|
||||
else for (var o = 0; o < 18; o++) t.push(a--);
|
||||
return t;
|
||||
},
|
||||
btn_pinpai: function (t) {
|
||||
this.setData({
|
||||
two_none: "block",
|
||||
hasback: "block",
|
||||
year: t.currentTarget.dataset.year,
|
||||
});
|
||||
},
|
||||
btn_sel_name: function (t) {
|
||||
var e = t.currentTarget.dataset.mouth;
|
||||
wx.setStorageSync("cartime", this.data.year + "-" + e),
|
||||
wx.navigateBack({ delta: 1 });
|
||||
},
|
||||
goback: function () {
|
||||
"block" == this.data.three_none
|
||||
? this.setData({ three_none: "none" })
|
||||
: "block" == this.data.two_none
|
||||
? this.setData({ two_none: "none", hasback: "none" })
|
||||
: this.setData({ hasback: "none" });
|
||||
},
|
||||
});
|
||||
3
packageA/pages/caresgznew/selectTime/selectTime.json
Normal file
3
packageA/pages/caresgznew/selectTime/selectTime.json
Normal file
@@ -0,0 +1,3 @@
|
||||
{
|
||||
"usingComponents": {}
|
||||
}
|
||||
15
packageA/pages/caresgznew/selectTime/selectTime.wxml
Normal file
15
packageA/pages/caresgznew/selectTime/selectTime.wxml
Normal file
@@ -0,0 +1,15 @@
|
||||
<view>
|
||||
<scroll-view scrollY="true" style="height:{{winHeight}}px">
|
||||
<view class="selection" wx:for="{{year_list}}" wx:key="index">
|
||||
<view bindtap="btn_pinpai" class="item_city" data-year="{{item}}"> {{item}} </view>
|
||||
</view>
|
||||
</scroll-view>
|
||||
<scroll-view class="scoll_car_service" scrollY="true" style="height:{{car_type_hight}};display:{{two_none}}">
|
||||
<view class="selection" wx:for="{{mouth_list}}" wx:key="index">
|
||||
<label bindtap="btn_sel_name" class="tab2" data-mouth="{{item}}"> {{item}} </label>
|
||||
</view>
|
||||
</scroll-view>
|
||||
</view>
|
||||
<view bindtap="goback" class="goback" style="display:{{hasback}}">
|
||||
<text class="arrow"></text>
|
||||
</view>
|
||||
125
packageA/pages/caresgznew/selectTime/selectTime.wxss
Normal file
125
packageA/pages/caresgznew/selectTime/selectTime.wxss
Normal file
@@ -0,0 +1,125 @@
|
||||
.searchLetter {
|
||||
color: #666;
|
||||
display: -webkit-flex;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
height: 100%;
|
||||
justify-content: center;
|
||||
position: fixed;
|
||||
right: 0;
|
||||
text-align: center;
|
||||
width: 40px;
|
||||
z-index: 1;
|
||||
}
|
||||
.tab2 {
|
||||
height: 80rpx;
|
||||
line-height: 80rpx;
|
||||
width: 560rpx;
|
||||
}
|
||||
.tab2,
|
||||
.tab3 {
|
||||
border-bottom: 1px solid #eaeaea;
|
||||
color: #2a2a2a;
|
||||
font-size: 30rpx;
|
||||
padding-left: 30rpx;
|
||||
}
|
||||
.tab3 {
|
||||
word-wrap: break-word;
|
||||
display: block;
|
||||
overflow: hidden;
|
||||
padding-bottom: 20rpx;
|
||||
padding-top: 20rpx;
|
||||
}
|
||||
.scoll_car_service {
|
||||
left: 25%;
|
||||
width: 75%;
|
||||
z-index: 5;
|
||||
}
|
||||
.scoll_car_service,
|
||||
.scoll_vender_service {
|
||||
background-color: #f5f5f5;
|
||||
box-shadow: 0 0 3px 3px #999;
|
||||
display: -webkit-flex;
|
||||
display: flex;
|
||||
height: 100%;
|
||||
position: fixed;
|
||||
top: 1px;
|
||||
}
|
||||
.scoll_vender_service {
|
||||
left: 50%;
|
||||
width: 50%;
|
||||
z-index: 10;
|
||||
}
|
||||
.searchLetter view {
|
||||
height: 70rpx;
|
||||
}
|
||||
.touchClass {
|
||||
color: #a56e0a;
|
||||
font-size: 28rpx;
|
||||
}
|
||||
.showSlectedLetter {
|
||||
align-items: center;
|
||||
background-color: rgba(0, 0, 0, 0.5);
|
||||
border-radius: 10px;
|
||||
color: #fff;
|
||||
font-size: 26px;
|
||||
height: 100px;
|
||||
justify-content: center;
|
||||
left: 50%;
|
||||
margin: -50px;
|
||||
position: fixed;
|
||||
top: 50%;
|
||||
width: 100px;
|
||||
z-index: 1;
|
||||
}
|
||||
.selection,
|
||||
.showSlectedLetter {
|
||||
display: -webkit-flex;
|
||||
display: flex;
|
||||
}
|
||||
.selection {
|
||||
flex-direction: column;
|
||||
width: 100%;
|
||||
}
|
||||
.item_letter {
|
||||
align-items: center;
|
||||
background-color: #f8f8f8;
|
||||
color: #896a0d;
|
||||
display: -webkit-flex;
|
||||
display: flex;
|
||||
font-size: 26rpx;
|
||||
height: 30px;
|
||||
padding-left: 10px;
|
||||
}
|
||||
.item_city {
|
||||
background-color: #f5f5f5;
|
||||
border-bottom: 1px solid #eaeaea;
|
||||
color: #2a2a2a;
|
||||
font-size: 30rpx;
|
||||
height: 34px;
|
||||
line-height: 34px;
|
||||
padding-left: 10px;
|
||||
}
|
||||
.car_img {
|
||||
height: 80rpx;
|
||||
width: 100rpx;
|
||||
}
|
||||
.goback {
|
||||
border: 2rpx solid #aaa;
|
||||
border-radius: 50%;
|
||||
bottom: 60rpx;
|
||||
height: 80rpx;
|
||||
position: fixed;
|
||||
right: 40rpx;
|
||||
width: 80rpx;
|
||||
z-index: 99;
|
||||
}
|
||||
.arrow {
|
||||
border-bottom: 3px solid #999;
|
||||
border-left: 3px solid #999;
|
||||
display: block;
|
||||
height: 14px;
|
||||
margin: 24rpx 30rpx;
|
||||
transform: rotate(45deg);
|
||||
width: 14px;
|
||||
}
|
||||
Reference in New Issue
Block a user