diff --git a/app.json b/app.json
index d69c339..80beaae 100644
--- a/app.json
+++ b/app.json
@@ -53,12 +53,12 @@
"pages/order/editLicenseImg/index",
"pages/order/editInsImg/index",
"pages/order/editOtherImg/index",
+ "pages/order/editImg/index",
"pages/order/editInvoiceImg/index",
"pages/storeData/index",
"pages/storeData/customerData/index",
"pages/storeData/wechatData/index",
"pages/storeData/orderData/index",
- "pages/order/editDeliveryckimg/index",
"pages/order/editQVImg/index",
"pages/order/editVoucherImg/index",
"pages/dataAnalysis/detail/index",
diff --git a/commons/css/base/imgSize.wxss b/commons/css/base/imgSize.wxss
index 6853128..a07cfa3 100644
--- a/commons/css/base/imgSize.wxss
+++ b/commons/css/base/imgSize.wxss
@@ -27,6 +27,7 @@
.img-300x230{width:300rpx;height:230rpx;box-sizing:border-box;}
.img-400x400{width:400rpx;height:400rpx;box-sizing:border-box;}
.img-500x500{width:500rpx;height:500rpx;box-sizing:border-box;}
+.img-530x300{width:530rpx;height:300rpx;box-sizing:border-box;}
.img-750x250{width:750rpx;height:250rpx;box-sizing:border-box;}
.img-750x422{width:100%;height:422rpx;box-sizing:border-box;}
diff --git a/commons/js/config.js b/commons/js/config.js
index 3b99ad4..ed4cca6 100644
--- a/commons/js/config.js
+++ b/commons/js/config.js
@@ -121,7 +121,7 @@ api = {
appCusorderV2: 'app/cusorderV2', //新建订单 /获取订单列表 /订单详情 /修改订单信息
appCusorderV2Tabs: 'app/cusorderV2/tabs', //获取订单列表tab
appCusorderdata: 'app/Cusorderdata', //获取订单图片 /上传编辑国补资料
- appCusorderV2Info: 'app/cusorderV2/info', //修改订单基本信息
+ appCusorderInfo: 'app/cusorder/info', //修改订单基本信息
appCusorderV2Status: 'app/cusorderV2/status', //删除订单
appSytactivityTabs: 'app/sytactivity/tabs', //私域通_tab
diff --git a/commons/js/utils/apiQuery.js b/commons/js/utils/apiQuery.js
index c6c0d2d..beaca71 100644
--- a/commons/js/utils/apiQuery.js
+++ b/commons/js/utils/apiQuery.js
@@ -174,7 +174,7 @@ apiQuery.postAppCusorder = function (params) {
})
}
-//修改付款方式 /修改委托协议
+//修改订单
apiQuery.putAppCusorder = function (params) {
return new Promise(function (resolve, reject) {
HttpRequest(false, Config.api.appCusorder, 2, params, "PUT", resolve, reject)
@@ -707,9 +707,9 @@ apiQuery.putAppCusorderV2 = function (params) {
}
//修改订单基本信息
-apiQuery.putAppCusorderV2Info = function (params) {
+apiQuery.putAppCusorderInfo = function (params) {
return new Promise(function (resolve, reject) {
- HttpRequest(true, Config.api.appCusorderV2Info, 2, params, "PUT", resolve, reject)
+ HttpRequest(true, Config.api.appCusorderInfo, 2, params, "PUT", resolve, reject)
})
}
diff --git a/commons/js/utils/stringEncrypt.js b/commons/js/utils/stringEncrypt.js
index dc49e6d..980941b 100644
--- a/commons/js/utils/stringEncrypt.js
+++ b/commons/js/utils/stringEncrypt.js
@@ -134,7 +134,6 @@ let combineUrl = (DATA) => {
let toEncrypt = (DATA) => {
// let secretKey = randomString()
let data = combineUrl(DATA)
- // console.log(data)//加密原始数据
return md5.hex_md5(data);
}
diff --git a/pages/order/detail/index2.js b/pages/order/detail/index2.js
index ee88cbd..dd4caec 100644
--- a/pages/order/detail/index2.js
+++ b/pages/order/detail/index2.js
@@ -13,13 +13,17 @@ Page({
carToolList:[],//随车随车工具选项
ckcarTool:[],//随车工具选中内容
+ pay_img:{},//支付凭证照片
+ contract_img:{},//合同图片照片
+ equity_ck_img:{},//权益确认书照片
+ bill_img:{},//发票照片
+ car_auth_img:{},//车机实名认证
+ delivery_ck_img:{},//交车确认图片
+
cardida:{},//身份证正面照片
cardidb:{},//身份证反面照片
business_licence:{},//营业执照照片
car_img:{},//行驶证照片
- register_img:{},//登记证照片
- //ins_img:[],//保险照片
- other_img:[],//交车合照
isShowCK:false,
isShowBill:false,
isShowConfirm: false, //是否显示确认窗口
@@ -75,30 +79,6 @@ Page({
info:res.data,
})
- if(res.data.ckcar_status==1){
- this.setData({
- remark:res.data.ckcar_data.remark,//补充说明
- ckcarInfo:res.data.ckcar_data.info,//随车资料选中内容
- ckcarTool:res.data.ckcar_data.tool,//随车工具选中内容
- })
- this.getAppDelivery()
- }
-
- //匹配上牌城市
- if(!!res.data.c_city_id){
- _.apiQuery.getAppCityOncard().then(res1 => {
- if(res1.data.list.length>0){
- res1.data.list.forEach((item,index) => {
- if(item.city_id == res.data.c_city_id){
- this.setData({
- c_city_name:item.name,
- })
- }
- })
- }
- })
- }
-
wx.stopPullDownRefresh()
})
@@ -118,68 +98,19 @@ Page({
cardidb:res.data.imgs.cardidb.length==0?{}:res.data.imgs.cardidb,
business_licence:res.data.imgs.business_licence.length==0?{}:res.data.imgs.business_licence,
car_img:res.data.imgs.car_img.length==0?{}:res.data.imgs.car_img,
- register_img:res.data.imgs.register_img.length==0?{}:res.data.imgs.register_img,
- //ins_img:res.data.imgs.ins_img.length==0?[]:res.data.imgs.ins_img,
- other_img:res.data.imgs.other_img.length==0?[]:res.data.imgs.other_img,
+ pay_img:res.data.imgs.pay_img.length==0?[]:res.data.imgs.pay_img,
+ contract_img:res.data.imgs.contract_img.length==0?[]:res.data.imgs.contract_img,
+ equity_ck_img:res.data.imgs.equity_ck_img.length==0?[]:res.data.imgs.equity_ck_img,
+ bill_img:res.data.imgs.bill_img.length==0?[]:res.data.imgs.bill_img,
+ car_auth_img:res.data.imgs.car_auth_img.length==0?[]:res.data.imgs.car_auth_img,
+ delivery_ck_img:res.data.imgs.delivery_ck_img.length==0?[]:res.data.imgs.delivery_ck_img,
})
- if('delivery_ck_img' in res.data.imgs){
- this.setData({
- delivery_ck_img:res.data.imgs.delivery_ck_img.length==0?{}:res.data.imgs.delivery_ck_img,
- })
- }
}
wx.stopPullDownRefresh()
})
},
- //获取车辆确认交付车辆
- getAppDelivery(){
- _.apiQuery.getAppDelivery().then(res=>{
-
- let delivery = res.data
- let carInfoList = []
- let ckcar_data = this.data.info.ckcar_data
- delivery.info.forEach(item => {
- carInfoList.push({
- title:item,
- checked:false,
- })
- })
- if(ckcar_data.info.length>0){
- carInfoList.forEach(item1 => {
- ckcar_data.info.forEach(item2 => {
- if(item1.title == item2){
- item1.checked = true
- }
- })
- })
- }
- let carToolList = []
- delivery.tool.forEach(item => {
- carToolList.push({
- title:item,
- checked:false,
- })
- })
- if(ckcar_data.tool.length>0){
- carToolList.forEach(item1 => {
- ckcar_data.tool.forEach(item2 => {
- if(item1.title == item2){
- item1.checked = true
- }
- })
- })
- }
-
- this.setData({
- carInfoList,
- carToolList,
- })
-
- })
- },
-
//显示短信弹框
showMessage(e){
this.setData({
@@ -394,50 +325,6 @@ Page({
})
}
- //上传登记证
- if(e.currentTarget.dataset.type=='register_img'){
- wx.chooseImage({
- count: 1, // 默认9
- sizeType: ['original', 'compressed'], // 可以指定是原图还是压缩图,默认二者都有
- sourceType: ['album', 'camera'], // 可以指定来源是相册还是相机,默认二者都有
- success(res) {
- wx.showLoading({
- title: '上传中',
- })
- wx.uploadFile({
- url:_.config.api.upImg,
- filePath:res.tempFilePaths[0],
- name: 'img',
- formData: {
- 'app': 'liche'
- },
- success: (resp) => {
- resp.data = JSON.parse(resp.data);
- wx.hideLoading();
- if (resp.data.code == 200) {
- let params = {};
- params['id'] = that.data.id;
- params['register_img'] = resp.data.data.url;
- _.apiQuery.putAppCusorderdata(params).then(res2 => {
- that.setData({
- 'register_img.value':resp.data.data.url,
- 'register_img.img':resp.data.data.full_url,
- })
- })
- }
- },
- })
- },
- fail: res => {
- wx.showToast({
- title: '文件选择失败',
- icon: 'none',
- duration: 2000
- })
- }
- })
- }
-
//上传行驶证
if(e.currentTarget.dataset.type=='car_img'){
wx.chooseImage({
@@ -714,13 +601,6 @@ Page({
urls,
})
}
- else if(e.currentTarget.dataset.type=='bill_ck_img'){
- let urls = this.data.imgInfo.imgs.bill_ck_img
- wx.previewImage({
- current:e.currentTarget.dataset.current,
- urls,
- })
- }
else if(e.currentTarget.dataset.type=='cardida'){
wx.previewImage({
current:this.data.imgInfo.imgs.cardida.img,
@@ -739,12 +619,6 @@ Page({
urls:[this.data.imgInfo.imgs.business_licence.img],
})
}
- else if(e.currentTarget.dataset.type=='register_img'){
- wx.previewImage({
- current:this.data.imgInfo.imgs.register_img.img,
- urls:[this.data.imgInfo.imgs.register_img.img],
- })
- }
else if(e.currentTarget.dataset.type=='car_img'){
wx.previewImage({
current:this.data.imgInfo.imgs.car_img.img,
@@ -779,12 +653,6 @@ Page({
urls:img,
})
}
- else if(e.currentTarget.dataset.type=='delivery_ck_img'){
- wx.previewImage({
- current:this.data.imgInfo.imgs.delivery_ck_img.img,
- urls:[this.data.imgInfo.imgs.delivery_ck_img.img],
- })
- }
else if(e.currentTarget.dataset.type=='wx_img'){
wx.previewImage({
current:this.data.imgInfo.imgs.wx_img.img,
@@ -797,12 +665,6 @@ Page({
urls:[this.data.imgInfo.imgs.mut_wx_img.img],
})
}
- else if(e.currentTarget.dataset.type=='destory_img'){
- wx.previewImage({
- current:this.data.imgInfo.imgs.destory_img.img,
- urls:[this.data.imgInfo.imgs.destory_img.img],
- })
- }
else if(e.currentTarget.dataset.type=='notify'){
let img = []
this.data.info.notify_file.forEach(item => {
diff --git a/pages/order/detail/index2.wxml b/pages/order/detail/index2.wxml
index 912097b..5756b58 100644
--- a/pages/order/detail/index2.wxml
+++ b/pages/order/detail/index2.wxml
@@ -6,7 +6,7 @@
购车人信息
-
+
@@ -25,7 +25,7 @@
订单信息
-
+
@@ -58,7 +58,7 @@
-
+
{{key}}
{{value}}
@@ -77,52 +77,18 @@
已付意向金{{info.inten_money}}元
-
-
-
-
- 合格证
-
-
-
-
-
-
-
-
-
-
-
-
-
- 发票
-
- {{info.bill_img?'更新':'上传'}}
-
-
-
-
-
-
-
-
-
+
身份证
{{cardida.value||cardidb.value?'更新':'上传'}}
-
-
-
+
营业执照
{{business_licence.value?'更新':'上传'}}
-
-
+
+
+ 订单合同
+
+ {{contract_img.value?'更新':'上传'}}
+
+
+
+
+ 付款凭证
+
+ {{pay_img.value?'更新':'上传'}}
+
+
+
+
+ 权益确认书
+
+ {{equity_ck_img.value?'更新':'上传'}}
+
+
+
+
+ 发票
+
+ {{bill_img.value?'更新':'上传'}}
+
+
+
+
+ 车机实名认证
+
+ {{car_auth_img.value?'更新':'上传'}}
+
+
-
+
行驶证
- {{register_img.value||car_img.value?'更新':'上传'}}
+ {{car_img.value?'更新':'上传'}}
-
-
-
+
保险单
{{imgInfo.imgs.accident_img.value||imgInfo.imgs.insurance_img.value||imgInfo.imgs.business_img.value?'更新':'上传'}}
-
-
+
交车合照
- {{other_img.length>0?'更新':'上传'}}
+ {{delivery_ck_img.value?'更新':'上传'}}
-
-
-
-
- 企微信息
-
- {{imgInfo.imgs.wx_img.value||imgInfo.imgs.mut_wx_img.value?'更新':'上传'}}
-
-
-
-
-
- 实名认证资料
-
- {{imgInfo.imgs.destory_img.value?'更新':'上传'}}
-
-
-
-
- 交付确认单
-
-
-
-
-
@@ -436,7 +337,6 @@
-
diff --git a/pages/order/edit/index2.js b/pages/order/edit/index2.js
index 3de71fc..68174e4 100644
--- a/pages/order/edit/index2.js
+++ b/pages/order/edit/index2.js
@@ -46,7 +46,6 @@ Page({
checkCount: 2,
checktext: '3s',
- if_zero_firstpay: 0, //是否零首付
firstPayArr: ['现金', '0首付', '按揭', ], //首付类型
firstPayIndex: 0, //首付类型
is_get_brand: 0, //是否店内上牌
@@ -87,18 +86,17 @@ Page({
brand_id: res.data.brand_id,
series_id: res.data.series_id,
car_id: res.data.car_id,
- if_zero_firstpay: res.data.if_zero_firstpay,
+ firstPayIndex: res.data.downpayment_type - 1,
delry_time: res.data.delry_time,
- loan_amount: res.data.money_json.loan_amount, //贷款额度
- loan_periods: res.data.money_json.loan_periods, //贷款期数
- monthly_payment: res.data.money_json.monthly_payment, //月供
- register_amount: res.data.money_json.register_amount, //上牌费
- confirm_amount: res.data.money_json.confirm_amount, //定⾦
- discount_amount: res.data.money_json.discount_amount, //⻋身优惠
+ loan_amount: res.data.money_json.loan_amount ?? '', //贷款额度
+ loan_periods: res.data.money_json.loan_periods ?? '', //贷款期数
+ monthly_payment: res.data.money_json.monthly_payment ?? '', //月供
+ register_amount: res.data.money_json.register_amount ?? '', //上牌费
+ confirm_amount: res.data.money_json.confirm_amount ?? '', //定⾦
+ discount_amount: res.data.money_json.discount_amount ?? '', //⻋身优惠
is_get_brand: parseInt(res.data.if_num),
is_get_insure: parseInt(res.data.if_insure),
})
- console.log(this.data.discount_amount)
/*匹配车辆信息*/
//匹配品牌
if (!!res.data.brand_id) {
@@ -183,22 +181,10 @@ Page({
paymentIndex: paymentIndex,
})
- if (paymentIndex == 1) {
- if (res.data.if_zero_firstpay == 1) {
- if (res.data.price_loan0 > 0) {
- this.setData({
- firstPayIndex: 2,
- })
- } else {
- this.setData({
- firstPayIndex: 1,
- })
- }
- } else {
- this.setData({
- firstPayIndex: 0,
- })
- }
+ if (res.data.payway == 0) {
+ this.setData({
+ firstPayIndex: res.data.downpayment_type - 1,
+ })
}
}
@@ -218,21 +204,14 @@ Page({
case 1:
this.setData({
mobile: this.trimAll(this.data.mobile),
- cardid: this.trimAll(this.data.cardid),
- owner_mobile: this.trimAll(this.data.owner_mobile),
- owner_cardid: this.trimAll(this.data.owner_cardid),
+ cardid: this.trimAll(this.data.cardid)
})
- if (this.data.customerIndex == -1) {
- wx.showToast({
- title: '请选择客户',
- icon: 'none'
- })
- } else if (this.data.name == '') {
+ if (this.data.main_type == 0 && this.data.name == '') {
wx.showToast({
title: '请输入客户姓名',
icon: 'none'
})
- } else if (!/^1[3456789]\d{9}$/.test(this.data.mobile)) {
+ } else if (this.data.mobile != this.data.org_mobile && !/^1[3456789]\d{9}$/.test(this.data.mobile)) {
wx.showToast({
title: '请输入客户手机号',
icon: 'none'
@@ -242,22 +221,12 @@ Page({
title: '请填写正确客户身份证',
icon: 'none'
})
- } else if (this.data.main_type == 0 && !/^1[3456789]\d{9}$/.test(this.data.owner_mobile)) {
- wx.showToast({
- title: '请填写车主手机号',
- icon: 'none'
- })
- } else if (this.data.main_type == 0 && (this.data.owner_cardid == '' || !/^\d{6}(18|19|20)?\d{2}(0[1-9]|1[012])(0[1-9]|[12]\d|3[01])\d{3}(\d|[xX])$/.test(this.data.owner_cardid))) {
- wx.showToast({
- title: '请填写正确车主身份证',
- icon: 'none'
- })
- } else if (this.data.main_type == 1 && this.data.company == '') {
+ } else if (this.data.main_type == 1 && this.data.name == '') {
wx.showToast({
title: '请填写企业名称',
icon: 'none'
})
- } else if (this.data.main_type == 1 && this.data.credit == '') {
+ } else if (this.data.main_type == 1 && this.data.cardid == '') {
wx.showToast({
title: '请填写企业信用代码',
icon: 'none'
@@ -293,12 +262,7 @@ Page({
})
} else if (this.data.delry_time == '') {
wx.showToast({
- title: '请输入期望交付时间',
- icon: 'none'
- })
- } else if (this.data.if_zero_firstpay != 1 && (!this.data.priceinfo.sdeposit || this.data.priceinfo.sdeposit == '')) {
- wx.showToast({
- title: '请选择定金',
+ title: '请选择交付时间',
icon: 'none'
})
} else {
@@ -425,7 +389,7 @@ Page({
changeModel(e) {
if (this.data.modelIndex != e.detail.value && e.detail.value >= 0) {
this.setData({
- car_id: this.data.modelList[e.detail.value].id,
+ series_id: this.data.modelList[e.detail.value].id,
modelIndex: e.detail.value,
car_id: '', //车辆版本id
carArray: [], //车辆版本列表
@@ -451,12 +415,8 @@ Page({
if (this.data.paymentIndex != e.detail.value && e.detail.value >= 0) {
this.setData({
paymentIndex: e.detail.value,
- price_loan0: '',
- if_zero_firstpay: 0,
firstPayIndex: 0,
})
- //代办列表
- this.getAppServices()
}
},
@@ -481,59 +441,33 @@ Page({
submitFlag: true,
})
- let fines = []
- that.data.fines.forEach(item => {
- if (item.txt != '') {
- fines.push(item)
- }
- });
-
let params = {};
params['id'] = that.data.id;
+ params['brand_id'] = that.data.brand_id;
+ params['series_id'] = that.data.series_id;
params['car_id'] = that.data.car_id;
- params['v_id'] = that.data.v_id;
-
- params['price'] = that.data.priceinfo.price;
- if (that.data.if_zero_firstpay != 1) {
- params['deposit'] = that.data.priceinfo.sdeposit;
+ if (this.data.color) {
+ params['color'] = this.data.color;
+ }
+ if (this.data.in_color) {
+ params['in_color'] = this.data.in_color;
}
params['payway'] = that.data.paymentIndex == 0 ? '1' : '0';
params['delry_time'] = that.data.delry_time;
- params['business_id'] = that.data.priceinfo.id;
- params['disc_money'] = that.data.priceinfo.sdisc_money ? that.data.priceinfo.sdisc_money : 0;
-
- params['sa'] = that.data.sa;
-
- if (that.data.priceinfo.show_local_bill) {
- params['if_local_bill'] = that.data.if_local_bill;
- }
if (that.data.paymentIndex == 1) {
- params['if_zero_firstpay'] = that.data.if_zero_firstpay;
+ params['downpayment_type'] = parseInt(that.data.firstPayIndex) + 1;
}
- if (that.data.price_loan0 > 0) {
- params['price_loan0'] = that.data.price_loan0;
+ params['loan_amount'] = that.data.loan_amount;
+ params['loan_periods'] = that.data.loan_periods;
+ params['monthly_payment'] = that.data.monthly_payment;
+ params['if_num'] = that.data.is_get_brand;
+ params['if_insure'] = that.data.is_get_insure;
+ if (that.data.is_get_brand) {
+ params['register_amount'] = that.data.register_amount;
}
- let srv_arr = []
- that.data.agencyList.forEach(item => {
- if (item.checked) {
- srv_arr.push({
- id: item.id,
- key: item.key,
- price: item.sprice,
- })
- }
- })
- params['srv_arr'] = srv_arr;
-
- params['fines'] = fines;
- //精品优惠金额
- // if(that.data.priceinfo.fine_money){
- // params['if_fine'] = that.data.if_fine?'1':'0';
- // if(that.data.if_fine&&!!that.data.priceinfo.sdisc_fine_money&&that.data.priceinfo.sdisc_fine_money!= ''){
- // params['disc_fine_money'] = that.data.priceinfo.sdisc_fine_money;
- // }
- // }
- _.apiQuery.putAppCusorderV2(params).then(res => {
+ params['confirm_amount'] = that.data.confirm_amount;
+ params['discount_amount'] = that.data.discount_amount;
+ _.apiQuery.putAppCusorder(params).then(res => {
//刷新列表页
let pages = getCurrentPages();
@@ -581,13 +515,6 @@ Page({
})
},
- //显示隐藏意向金备注
- optShowRemarks() {
- this.setData({
- isShowRemarks: !this.data.isShowRemarks,
- })
- },
-
//输入
inputTx(e) {
this.setData({
@@ -621,218 +548,16 @@ Page({
})
},
- //委托代办
- changeAgency(e) {
- let agencyList = this.data.agencyList
- let values = e.detail.value
- let srv_total = 0
- agencyList.forEach(item1 => {
- item1.checked = false
- values.forEach(item2 => {
- if (item1.id == item2) {
- item1.checked = true
- if (parseFloat(item1.sprice) > 0) {
- srv_total = srv_total + parseFloat(item1.sprice)
- }
- }
- })
- })
+ changeIsGetBrand(e) {
this.setData({
- agencyList,
- srv_total,
+ is_get_brand: e.detail.value ? 1 : 0
})
},
- //精品尊享版
- changeFineBag() {
+ changeIsGetInsure(e) {
this.setData({
- if_fine: !this.data.if_fine,
- 'priceinfo.sdisc_fine_money': '',
- })
- },
-
- //添加精品
- addFine() {
- this.data.fines.push({
- txt: '',
- price: '',
- })
- this.setData({
- fines: this.data.fines,
- })
- },
-
- //添加精品
- inputFines(e) {
- if (e.currentTarget.dataset.type == 'txt') {
- this.setData({
- ['fines[' + e.currentTarget.dataset.index + '].txt']: e.detail.value,
- })
- }
- if (e.currentTarget.dataset.type == 'price') {
- this.setData({
- ['fines[' + e.currentTarget.dataset.index + '].price']: Number(e.detail.value),
- })
- let fine_total = 0
- this.data.fines.forEach(item => {
- if (parseFloat(item.price) > 0) {
- fine_total = fine_total + parseFloat(item.price)
- }
- })
- this.setData({
- fine_total,
- })
- }
- },
-
- //快截输入代办价格
- fillAgency(e) {
- this.setData({
- ['agencyList[' + e.currentTarget.dataset.index + '].sprice']: parseFloat(e.currentTarget.dataset.sprice),
- })
- let srv_total = 0
- this.data.agencyList.forEach(item => {
- if (item.checked && parseFloat(item.sprice) > 0) {
- srv_total = srv_total + parseFloat(item.sprice)
- }
- })
- this.setData({
- srv_total,
- })
- },
-
- //修改代办金额
- inputAgency(e) {
- this.setData({
- ['agencyList[' + e.currentTarget.dataset.index + '].sprice']: parseFloat(e.detail.value),
- })
- let srv_total = 0
- this.data.agencyList.forEach(item => {
- if (item.checked && parseFloat(item.sprice) > 0) {
- srv_total = srv_total + parseFloat(item.sprice)
- }
- })
- this.setData({
- srv_total,
- })
- },
-
- //判断修改代办金额
- inputBlurAgency(e) {
- if (!this.data.agencyList[e.currentTarget.dataset.index].sprice || this.data.agencyList[e.currentTarget.dataset.index].price > parseFloat(this.data.agencyList[e.currentTarget.dataset.index].sprice)) {
- wx.showToast({
- title: '代办费设置过低',
- icon: 'none'
- })
- this.setData({
- ['agencyList[' + e.currentTarget.dataset.index + '].sprice']: this.data.agencyList[e.currentTarget.dataset.index].price,
- })
- let srv_total = 0
- this.data.agencyList.forEach(item => {
- if (item.checked && parseFloat(item.sprice) > 0) {
- srv_total = srv_total + parseFloat(item.sprice)
- }
- })
- this.setData({
- srv_total,
- })
- }
- },
-
- //选择定金
- fillDeposit(e) {
- this.setData({
- 'priceinfo.sdeposit': parseFloat(e.currentTarget.dataset.deposit),
- })
- },
-
- //修改定金
- inputDeposit(e) {
- this.setData({
- 'priceinfo.sdeposit': parseFloat(e.detail.value),
- })
- },
-
- //判断修改定金是否小于限制
- inputBlurDeposit(e) {
- if (!this.data.priceinfo.sdeposit || this.data.priceinfo.deposit > parseFloat(this.data.priceinfo.sdeposit)) {
- wx.showToast({
- title: '定金设置过低',
- icon: 'none'
- })
- this.setData({
- 'priceinfo.sdeposit': this.data.priceinfo.deposit,
- })
- }
- },
-
- //选择车身优惠
- fillDisc_money(e) {
- this.setData({
- 'priceinfo.sdisc_money': parseFloat(e.currentTarget.dataset.disc_money),
- })
- },
-
- //修改车身优惠
- inputDisc_money(e) {
- this.setData({
- 'priceinfo.sdisc_money': parseFloat(e.detail.value),
- })
- },
-
- //判断修改车身优惠是否小于限制
- inputBlurDisc_money(e) {
- if (this.data.priceinfo.dis_money < parseFloat(this.data.priceinfo.sdisc_money)) {
- wx.showToast({
- title: '车身优惠设置过高',
- icon: 'none'
- })
- this.setData({
- 'priceinfo.sdisc_money': this.data.priceinfo.dis_money,
- })
- } else if (!this.data.priceinfo.sdisc_money) {
- this.setData({
- 'priceinfo.sdisc_money': '',
- })
- }
- },
-
- //选择精品优惠
- fillDisc_fine_money(e) {
- this.setData({
- 'priceinfo.sdisc_fine_money': parseFloat(e.currentTarget.dataset.disc_fine_money),
- })
- },
-
- //修改精品优惠
- inputDisc_fine_money(e) {
- this.setData({
- 'priceinfo.sdisc_fine_money': parseFloat(e.detail.value),
- })
- },
-
- //判断修改精品优惠是否小于限制
- inputBlurDisc_fine_money(e) {
- if (this.data.priceinfo.dis_fine_money < parseFloat(this.data.priceinfo.sdisc_fine_money)) {
- wx.showToast({
- title: '精品优惠设置过高',
- icon: 'none'
- })
- this.setData({
- 'priceinfo.sdisc_fine_money': this.data.priceinfo.dis_fine_money,
- })
- } else if (!this.data.priceinfo.sdisc_fine_money) {
- this.setData({
- 'priceinfo.sdisc_fine_money': '',
- })
- }
- },
-
- //需开具本地发票
- switchAddrDef: function (e) {
- this.setData({
- if_local_bill: e.detail.value ? 1 : 0
+ is_get_insure: e.detail.value ? 1 : 0
})
},
@@ -856,18 +581,7 @@ Page({
if (this.data.firstPayIndex != e.detail.value && e.detail.value >= 0) {
this.setData({
firstPayIndex: e.detail.value,
- price_loan0: '',
- 'priceinfo.sdeposit': '',
})
- if (this.data.firstPayArr[this.data.firstPayIndex] == '0首付' || this.data.firstPayArr[this.data.firstPayIndex] == '按揭') {
- this.setData({
- if_zero_firstpay: 1,
- })
- } else {
- this.setData({
- if_zero_firstpay: 0,
- })
- }
}
},
diff --git a/pages/order/edit/index2.wxml b/pages/order/edit/index2.wxml
index d20fdee..467bd56 100644
--- a/pages/order/edit/index2.wxml
+++ b/pages/order/edit/index2.wxml
@@ -160,30 +160,16 @@
车辆版本
- {{levelArray[levelIndex]}}
+ {{carArray[carIndex]}}
-
+
车身颜色
- {{colorArray[colorIndex]}}
+ {{color}}
-
+
内饰颜色
- {{interiorArray[interiorIndex]}}
+ {{in_color}}
-
-
- 选装
- {{options_total}}元
-
-
-
- {{item.title}}
-
- {{item.price}}元
-
-
-
-
其他信息
付款方式
@@ -193,89 +179,48 @@
期望交付时间
{{delry_time}}
-
- 平台售价
- {{priceinfo.price}}元
+
+
+ 首付类型
+ {{firstPayArr[firstPayIndex]}}
+
+
+ 贷款额度
+ {{loan_amount}}元
+
+
+ 贷款期数
+ {{loan_periods}}
+
+
+ 月供
+ {{monthly_payment}}元
+
+
+
+
+ 是否店内上牌
+ {{is_get_brand?'是':'否'}}
+
-
- 颜色加价
- {{priceinfo.price_color}}元
+
+
+ 是否店内投保
+ {{is_get_insure?'是':'否'}}
+
-
- 公司加价
- {{priceinfo.price_coplus}}元
+
+ 上牌费
+ {{register_amount}}元
-
- 首付类型
- {{firstPayArr[firstPayIndex]}}
-
-
- 首付按揭金额
- {{price_loan0}}
-
-
+
定金
- {{priceinfo.sdeposit}}元
+ {{confirm_amount}}元
-
- 最终售价
- {{options_total+priceinfo.price+priceinfo.price_color+priceinfo.price_coplus-(priceinfo.sdisc_money>0?priceinfo.sdisc_money:0)}}元
+
+ 车身优惠
+ {{discount_amount}}元
-
- 优惠
- {{priceinfo.sdisc_money}}元
-
-
-
-
- 委托代办
- {{srv_total}}元
-
-
-
- {{item.title}}
-
- {{item.sprice}}元
- {{item.text}}
-
-
-
-
- 精品选装
- {{fine_total}}元
-
-
-
- {{item.txt}}
-
- {{item.price}}元
-
-
-
-
-
-
-
- {{item.txt}}
- {{item.price>0?item.price:0}}元
-
-
-
-
- 需开具本地发票
- {{if_local_bill?'需要':'不需要'}}
-
-
- 特别约定
- {{sa}}
-
@@ -322,16 +267,4 @@
{{checktext}}
-
-
-
-
-
-
- 意向金:旨在客户尚未明确购车决策时(车型、付款方式等),在不需要签订合同的情况下,收取订车费用锁定客户
-
-
- 知道了
-
-
\ No newline at end of file
diff --git a/pages/order/editBuyer/index.js b/pages/order/editBuyer/index.js
index e19de95..8010253 100644
--- a/pages/order/editBuyer/index.js
+++ b/pages/order/editBuyer/index.js
@@ -2,9 +2,10 @@ import _ from '../../../commons/js/commons'
const app = getApp()
Page({
data: {
- name:'',//姓名
- mobile:'',//手机号
- cardid:'',//身份证
+ name: '', //姓名
+ mobile: '', //手机号
+ cardid: '', //身份证
+ main_type: '', //类型
},
onLoad: function (options) {
for (let key in options) {
@@ -14,21 +15,22 @@ Page({
}
this.getAppCusorderV2()
-
+
},
onShow: function () {
},
//获取订单详情
- getAppCusorderV2(){
+ getAppCusorderV2() {
let params = {};
params['id'] = this.data.id;
- _.apiQuery.getAppCusorderDetails(params).then(res=>{
+ _.apiQuery.getAppCusorderDetails(params).then(res => {
this.setData({
- name:res.data.name?res.data.name:'',
- mobile:res.data.mobile?res.data.mobile:'',
- cardid:res.data.cardid?res.data.cardid:'',
+ name: res.data.name ? res.data.name : '',
+ mobile: res.data.mobile ? res.data.mobile : '',
+ cardid: res.data.cardid ? res.data.cardid : '',
+ main_type: res.data.main_type ? res.data.main_type : ''
})
wx.stopPullDownRefresh()
@@ -39,27 +41,30 @@ Page({
//修改订单基本信息
putAppCusorderV2Info() {
this.setData({
- mobile:this.trimAll(this.data.mobile),
- cardid:this.trimAll(this.data.cardid),
+ name: this.trimAll(this.data.name),
+ cardid: this.trimAll(this.data.cardid),
})
- if (this.data.name == '' ) {
+ if (this.data.main_type == 0 && this.data.name == '') {
wx.showToast({
title: '请输入客户姓名',
icon: 'none'
})
- }else if (this.data.mobile != this.data.org_mobile && !/^1[3456789]\d{9}$/.test(this.data.mobile)){
- wx.showToast({
- title: '请输入客户手机号',
- icon: 'none'
- })
- }
- else if(this.data.cardid == ''|| !/^\d{6}(18|19|20)?\d{2}(0[1-9]|1[012])(0[1-9]|[12]\d|3[01])\d{3}(\d|[xX])$/.test(this.data.cardid)){
+ } else if (this.data.main_type == 0 && (this.data.cardid == '' || !/^\d{6}(18|19|20)?\d{2}(0[1-9]|1[012])(0[1-9]|[12]\d|3[01])\d{3}(\d|[xX])$/.test(this.data.cardid))) {
wx.showToast({
title: '请填写正确客户身份证',
icon: 'none'
})
- }
- else{
+ } else if (this.data.main_type == 1 && this.data.name == '') {
+ wx.showToast({
+ title: '请输入企业名称',
+ icon: 'none'
+ })
+ } else if (this.data.main_type == 1 && this.data.cardid == '') {
+ wx.showToast({
+ title: '请输入企业信用代码',
+ icon: 'none'
+ })
+ } else {
let that = this
that.setData({
submitFlag: true,
@@ -67,16 +72,15 @@ Page({
let params = {};
params['id'] = that.data.id;
params['name'] = that.data.name;
- params['mobile'] = that.data.mobile;
params['cardid'] = that.data.cardid;
- _.apiQuery.putAppCusorderV2Info(params).then(res => {
+ _.apiQuery.putAppCusorderInfo(params).then(res => {
//刷新详情页
let pages = getCurrentPages();
let prevPage = null; //上一个页面
if (pages.length >= 2) {
prevPage = pages[pages.length - 2]; //上一个页面
- if(prevPage.route == 'pages/order/detail/index2'){
+ if (prevPage.route == 'pages/order/detail/index2') {
prevPage.onPullDownRefresh()
}
}
@@ -91,7 +95,7 @@ Page({
})
}, 500)
- }).catch(res=>{
+ }).catch(res => {
that.setData({
submitFlag: false,
})
@@ -100,8 +104,8 @@ Page({
},
//推送链接
- pushLink(e){
- if(e.currentTarget.dataset.url){
+ pushLink(e) {
+ if (e.currentTarget.dataset.url) {
_.$router.openUrlScheme(e.currentTarget.dataset.url)
}
},
@@ -111,7 +115,7 @@ Page({
let that = this
//上传身份证正面-车主身份证
//上传身份证正面-客户身份证
- if(e.currentTarget.dataset.type=='customer'){
+ if (e.currentTarget.dataset.type == 'customer') {
wx.chooseImage({
count: 1, // 默认9
sizeType: ['original', 'compressed'], // 可以指定是原图还是压缩图,默认二者都有
@@ -121,8 +125,8 @@ Page({
title: '识别中',
})
wx.uploadFile({
- url:_.config.api.upImg,
- filePath:res.tempFilePaths[0],
+ url: _.config.api.upImg,
+ filePath: res.tempFilePaths[0],
name: 'img',
formData: {
'app': 'liche'
@@ -135,8 +139,8 @@ Page({
_.apiQuery.getAppIdcardInfo(params).then(res2 => {
wx.hideLoading();
that.setData({
- cardid:res2.data.IdNum,
- name:res2.data.Name,
+ cardid: res2.data.IdNum,
+ name: res2.data.Name,
})
})
}
@@ -158,11 +162,11 @@ Page({
},
//去除空格
- trimAll(ele){
- if(typeof ele === 'string'){
- return ele.split(' ').join('');
- }else{
- console.error(`${typeof ele} is not the expected type, but the string type is expected`)
+ trimAll(ele) {
+ if (typeof ele === 'string') {
+ return ele.split(' ').join('');
+ } else {
+ console.error(`${typeof ele} is not the expected type, but the string type is expected`)
}
},
diff --git a/pages/order/editBuyer/index.wxml b/pages/order/editBuyer/index.wxml
index e065315..a6487e8 100644
--- a/pages/order/editBuyer/index.wxml
+++ b/pages/order/editBuyer/index.wxml
@@ -5,26 +5,45 @@
客户手机号码*
-
+
-
- 客户身份证*
-
-
+
+
+ 企业名称*
+
+
+
-
-
-
- 客户姓名*
-
-
+
+ 企业信用代码*
+
+
+
-
+
+
+
+ 客户姓名*
+
+
+
+
+
+ 客户身份证*
+
+
+
+
+
+
+
-
+
《理车用户注册协议》
和
《理车用户隐私政策》
diff --git a/pages/order/editCardid/index.js b/pages/order/editCardid/index.js
index 37fcd45..b36834c 100644
--- a/pages/order/editCardid/index.js
+++ b/pages/order/editCardid/index.js
@@ -38,7 +38,6 @@ Page({
cardidb:res.data.imgs.cardidb.length==0?{}:res.data.imgs.cardidb,
business_licence:res.data.imgs.business_licence.length==0?{}:res.data.imgs.business_licence,
car_img:res.data.imgs.car_img.length==0?{}:res.data.imgs.car_img,
- register_img:res.data.imgs.register_img.length==0?{}:res.data.imgs.register_img,
ins_img:res.data.imgs.ins_img.length==0?[]:res.data.imgs.ins_img,
other_img:res.data.imgs.other_img.length==0?[]:res.data.imgs.other_img,
})
diff --git a/pages/order/editDeliveryckimg/index.js b/pages/order/editDeliveryckimg/index.js
deleted file mode 100644
index 35b9c37..0000000
--- a/pages/order/editDeliveryckimg/index.js
+++ /dev/null
@@ -1,106 +0,0 @@
-import _ from '../../../commons/js/commons'
-const app = getApp()
-Page({
- data: {
- delivery_ck_img:{},//交付确认单
- },
- onLoad: function (options) {
- for (let key in options) {
- this.setData({
- [key]: options[key]
- })
- }
-
- this.getAppCusorderdata()
-
- },
- onShow: function () {
-
- },
-
- //获取订单图片
- getAppCusorderdata(){
- let params = {};
- params['id'] = this.data.id;
- _.apiQuery.getAppCusorderdata(params).then(res=>{
- this.setData({
- imgInfo:res.data,
- })
- if(res.data.img_status == 1){
- this.setData({
- delivery_ck_img:res.data.imgs.delivery_ck_img.length==0?{}:res.data.imgs.delivery_ck_img,
- })
- }
- wx.stopPullDownRefresh()
- })
- },
-
- //选择图片
- chooseImg(e) {
- let that = this
-
- //上传登记证
- if(e.currentTarget.dataset.type=='delivery_ck_img'){
- wx.chooseImage({
- count: 1, // 默认9
- sizeType: ['original', 'compressed'], // 可以指定是原图还是压缩图,默认二者都有
- sourceType: ['album', 'camera'], // 可以指定来源是相册还是相机,默认二者都有
- success(res) {
- wx.showLoading({
- title: '上传中',
- })
- wx.uploadFile({
- url:_.config.api.upImg,
- filePath:res.tempFilePaths[0],
- name: 'img',
- formData: {
- 'app': 'liche'
- },
- success: (resp) => {
- resp.data = JSON.parse(resp.data);
- if (resp.data.code == 200) {
- let params = {};
- params['id'] = that.data.id;
- params['delivery_ck_img'] = resp.data.data.url;
- _.apiQuery.putAppCusorderdata(params).then(res2 => {
- wx.hideLoading();
- that.setData({
- 'delivery_ck_img.value':resp.data.data.url,
- 'delivery_ck_img.img':resp.data.data.full_url,
- })
- }).catch(res2=>{
- wx.hideLoading();
- });
- }else{
- wx.hideLoading();
- wx.showToast({
- title: '上传失败',
- icon: 'none',
- duration: 2000
- })
- }
- },
- })
- },
- fail: res => {
- wx.showToast({
- title: '文件选择失败',
- icon: 'none',
- duration: 2000
- })
- }
- })
- }
- },
-
- //查看图片
- previewImage: function (e) {
- if(e.currentTarget.dataset.type=='delivery_ck_img'){
- wx.previewImage({
- current:this.data.imgInfo.imgs.delivery_ck_img.img,
- urls:[this.data.imgInfo.imgs.delivery_ck_img.img],
- })
- }
- },
-
-})
\ No newline at end of file
diff --git a/pages/order/editDeliveryckimg/index.json b/pages/order/editDeliveryckimg/index.json
deleted file mode 100644
index 8af75d1..0000000
--- a/pages/order/editDeliveryckimg/index.json
+++ /dev/null
@@ -1,4 +0,0 @@
-{
- "navigationBarTitleText": "交付确认单信息",
- "usingComponents": {}
-}
\ No newline at end of file
diff --git a/pages/order/editDeliveryckimg/index.wxml b/pages/order/editDeliveryckimg/index.wxml
deleted file mode 100644
index 3598776..0000000
--- a/pages/order/editDeliveryckimg/index.wxml
+++ /dev/null
@@ -1,10 +0,0 @@
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/pages/order/editDeliveryckimg/index.wxss b/pages/order/editDeliveryckimg/index.wxss
deleted file mode 100644
index 0995e1f..0000000
--- a/pages/order/editDeliveryckimg/index.wxss
+++ /dev/null
@@ -1 +0,0 @@
-/* pages/order/editDeliveryckimg/index.wxss */
\ No newline at end of file
diff --git a/pages/order/editImg/index.js b/pages/order/editImg/index.js
new file mode 100644
index 0000000..21aa126
--- /dev/null
+++ b/pages/order/editImg/index.js
@@ -0,0 +1,148 @@
+import _ from '../../../commons/js/commons'
+const app = getApp()
+Page({
+ data: {
+ type: "",
+ title: "",
+ row: ""
+ },
+ onLoad: function (options) {
+ for (let key in options) {
+ this.setData({
+ [key]: options[key]
+ })
+ }
+ wx.setNavigationBarTitle({
+ title: this.data.title
+ })
+ if (this.data.type == "") {
+ wx.showModal({
+ title: '参数错误',
+ icon: "none"
+ })
+ } else {
+ this.getAppCusorderdata()
+ }
+ },
+ onShow: function () {
+
+ },
+
+ //获取订单图片
+ getAppCusorderdata() {
+ let params = {};
+ params['id'] = this.data.id;
+ _.apiQuery.getAppCusorderdata(params).then(res => {
+ this.setData({
+ imgInfo: res.data,
+ })
+ let key = this.data.type
+ console.log()
+ if (res.data.img_status == 1) {
+ let img = res.data.imgs['' + key + '']
+ this.setData({
+ row: img.length == 0 ? [] : img,
+ })
+ }
+ wx.stopPullDownRefresh()
+ })
+ },
+
+ //选择图片
+ chooseImg(e) {
+ let that = this
+ wx.chooseImage({
+ count: 1, // 默认9
+ sizeType: ['original', 'compressed'], // 可以指定是原图还是压缩图,默认二者都有
+ sourceType: ['album', 'camera'], // 可以指定来源是相册还是相机,默认二者都有
+ success(res) {
+ wx.showLoading({
+ title: '上传中',
+ })
+ wx.uploadFile({
+ url: _.config.api.upImg,
+ filePath: res.tempFilePaths[0],
+ name: 'img',
+ formData: {
+ 'app': 'liche'
+ },
+ success: (resp) => {
+ resp.data = JSON.parse(resp.data);
+ if (resp.data.code == 200) {
+ let params = {};
+ params['id'] = that.data.id;
+ params['' + that.data.type + ''] = resp.data.data.url;
+ _.apiQuery.putAppCusorderdata(params).then(res2 => {
+ wx.hideLoading();
+ that.setData({
+ 'row.value': resp.data.data.url,
+ 'row.img': resp.data.data.full_url,
+ })
+ }).catch(res2 => {
+ wx.hideLoading();
+ });
+ } else {
+ wx.hideLoading();
+ wx.showToast({
+ title: '上传失败',
+ icon: 'none',
+ duration: 2000
+ })
+ }
+ },
+ })
+ },
+ fail: res => {
+ wx.showToast({
+ title: '文件选择失败',
+ icon: 'none',
+ duration: 2000
+ })
+ }
+ })
+ },
+
+ // 编辑页面删除图片
+ delImg(e) {
+ if (e.currentTarget.dataset.type == 'ins_img') {
+ let ins_img = this.data.ins_img
+ ins_img.splice(e.currentTarget.dataset.index, 1)
+ let params = {};
+ params['id'] = this.data.id;
+ let img = []
+ ins_img.forEach(item => {
+ img.push(item.value)
+ })
+ params['ins_imgs'] = img;
+ _.apiQuery.putAppCusorderdata(params).then(res => {
+ this.setData({
+ ins_img,
+ })
+ })
+ } else if (e.currentTarget.dataset.type == 'other_img') {
+ let other_img = this.data.other_img
+ other_img.splice(e.currentTarget.dataset.index, 1)
+ let params = {};
+ params['id'] = this.data.id;
+ let img = []
+ other_img.forEach(item => {
+ img.push(item.value)
+ })
+ params['other_imgs'] = img;
+ _.apiQuery.putAppCusorderdata(params).then(res => {
+ this.setData({
+ other_img,
+ })
+ })
+ }
+ },
+
+ //查看图片
+ previewImage: function (e) {
+ wx.previewImage({
+ current: e.currentTarget.dataset.url,
+ urls: [e.currentTarget.dataset.url],
+ })
+ },
+
+})
\ No newline at end of file
diff --git a/pages/order/editImg/index.json b/pages/order/editImg/index.json
new file mode 100644
index 0000000..f306fa1
--- /dev/null
+++ b/pages/order/editImg/index.json
@@ -0,0 +1,4 @@
+{
+ "navigationBarTitleText": "修改图片",
+ "usingComponents": {}
+}
\ No newline at end of file
diff --git a/pages/order/editImg/index.wxml b/pages/order/editImg/index.wxml
new file mode 100644
index 0000000..9442c6e
--- /dev/null
+++ b/pages/order/editImg/index.wxml
@@ -0,0 +1,23 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 上传{{title}}
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/pages/order/editImg/index.wxss b/pages/order/editImg/index.wxss
new file mode 100644
index 0000000..5648be2
--- /dev/null
+++ b/pages/order/editImg/index.wxss
@@ -0,0 +1 @@
+/* pages/order/editImg/index.wxss */
\ No newline at end of file
diff --git a/pages/order/editInsImg/index.wxml b/pages/order/editInsImg/index.wxml
index 8953e4c..67ad1e5 100644
--- a/pages/order/editInsImg/index.wxml
+++ b/pages/order/editInsImg/index.wxml
@@ -22,7 +22,7 @@
-
+
@@ -102,7 +103,7 @@
-
+
-
+
-
-
-
-
-
-
-
-
-
-
-
- 上传登记证
-
-
-
-
-
+
-
+
上传行驶证
-
+
diff --git a/pages/order/register/index.js b/pages/order/register/index.js
index e99a81a..06f2b23 100644
--- a/pages/order/register/index.js
+++ b/pages/order/register/index.js
@@ -53,7 +53,6 @@ Page({
isShowSuccess: false, //是否显示成功提示
isShowContract: false, //是否显示生成合同
- if_zero_firstpay: 0, //是否零首付
firstPayArr: ['现金', '0首付', '按揭', ], //首付类型
firstPayIndex: 0, //首付类型
is_get_brand: 0, //20240526是否店内上牌
@@ -99,7 +98,7 @@ Page({
mobile: this.trimAll(this.data.mobile),
cardid: this.trimAll(this.data.cardid),
})
- if (this.data.name == '') {
+ if (this.data.main_type == 0 && this.data.name == '') {
wx.showToast({
title: '请输入客户姓名',
icon: 'none'
@@ -114,12 +113,12 @@ Page({
title: '请填写正确客户身份证',
icon: 'none'
})
- } else if (this.data.main_type == 1 && this.data.company == '') {
+ } else if (this.data.main_type == 1 && this.data.name == '') {
wx.showToast({
title: '请填写企业名称',
icon: 'none'
})
- } else if (this.data.main_type == 1 && this.data.credit == '') {
+ } else if (this.data.main_type == 1 && this.data.cardid == '') {
wx.showToast({
title: '请填写企业信用代码',
icon: 'none'
@@ -299,7 +298,6 @@ Page({
if (this.data.paymentIndex != e.detail.value && e.detail.value >= 0) {
this.setData({
paymentIndex: e.detail.value,
- if_zero_firstpay: 0,
firstPayIndex: 0,
})
}
@@ -308,7 +306,9 @@ Page({
//购车主体
changeMain(e) {
this.setData({
- main_type: e.detail.value
+ main_type: e.detail.value,
+ name: '',
+ cardid: ''
})
},
@@ -344,7 +344,7 @@ Page({
params['payway'] = that.data.paymentIndex == 0 ? '1' : '0';
params['delry_time'] = that.data.delry_time;
if (that.data.paymentIndex == 1) {
- params['downpayment_type'] = that.data.if_zero_firstpay;
+ params['downpayment_type'] = parseInt(that.data.firstPayIndex) + 1;
}
params['loan_amount'] = that.data.loan_amount;
params['loan_periods'] = that.data.loan_periods;
@@ -356,7 +356,6 @@ Page({
}
params['confirm_amount'] = that.data.confirm_amount;
params['discount_amount'] = that.data.discount_amount;
- console.log(params)
_.apiQuery.postAppCusorder(params).then(res => {
//刷新列表页
@@ -374,15 +373,6 @@ Page({
details: res.data,
})
- if (that.data.owner_cardidpic != '') {
- let oparams = {};
- oparams['id'] = res.data.id;
- oparams['cardida'] = that.data.owner_cardidpic;
- _.apiQuery.putAppCusorderdata(oparams).then(res2 => {
-
- })
- }
-
// wx.showModal({
// title: '登记成功',
// content: '',
@@ -426,14 +416,6 @@ Page({
})
},
- //精品尊享版
- changeFineBag() {
- this.setData({
- if_fine: !this.data.if_fine,
- 'priceinfo.sdisc_fine_money': '',
- })
- },
-
//推送链接
viewDetails(e) {
wx.redirectTo({
diff --git a/pages/order/register/index.wxml b/pages/order/register/index.wxml
index 0b49504..3438623 100644
--- a/pages/order/register/index.wxml
+++ b/pages/order/register/index.wxml
@@ -53,13 +53,13 @@
企业名称*
-
+
企业信用代码*
-
+
@@ -293,7 +293,7 @@
{{is_get_insure?'是':'否'}}
-
+
上牌费
{{register_amount}}元
diff --git a/pages/signup/code.js b/pages/signup/code.js
index 26ba63e..6a9ea4d 100644
--- a/pages/signup/code.js
+++ b/pages/signup/code.js
@@ -97,7 +97,7 @@ Page({
_.apiQuery.getappSignConf().then(res => {
this.setData({
qrcode_img: res.data.qcode,
- qrcode_count_time: res.data.qrcode_count_time,
+ qrcode_count_time: parseInt(res.data.qrcode_count_time),
loading: false,
info: res.data
}, () => {