Commit 0d7b4160 by 张立顺

fix bug修复

1 parent a74961ed
...@@ -45,10 +45,13 @@ Component({ ...@@ -45,10 +45,13 @@ Component({
subBtnShow: { subBtnShow: {
type: Boolean, type: Boolean,
value: true value: true
},
mode: {
type: Number,
} }
}, },
observers: { observers: {
'orderInfo.mode': function (value) { 'mode': function (value) {
// 先注释掉 // 先注释掉
// this.getYqStoreConfig() // this.getYqStoreConfig()
...@@ -67,10 +70,6 @@ Component({ ...@@ -67,10 +70,6 @@ Component({
first: value ? data.firstObjSimple : data.firstObj, first: value ? data.firstObjSimple : data.firstObj,
formRule: value ? data.formRuleSimple : data.formRule formRule: value ? data.formRuleSimple : data.formRule
}) })
// }
// }
}, },
// 'orderInfo.outTradeNo': function (value) { // 'orderInfo.outTradeNo': function (value) {
// console.log(value, 'outTradeNo') // console.log(value, 'outTradeNo')
...@@ -90,6 +89,8 @@ Component({ ...@@ -90,6 +89,8 @@ Component({
formData: {}, formData: {},
employeeList: [], employeeList: [],
disable: true, disable: true,
// firstObjSimple:data.firstObjSimple,
// formRuleSimple: data.formRuleSimple,
first: data.firstObjSimple, first: data.firstObjSimple,
formRule: data.formRuleSimple, formRule: data.formRuleSimple,
referrerPicker: false, referrerPicker: false,
...@@ -104,7 +105,7 @@ Component({ ...@@ -104,7 +105,7 @@ Component({
this.getEmployee() this.getEmployee()
this.getYqStoreConfig() this.getYqStoreConfig()
// this.setData({ // this.setData({
// first: Util.deepClone(data.firstObjSimple), // first: wx.$util.deepClone(data.firstObjSimple),
// formRule: Util.deepClone(data.formRuleSimple), // formRule: Util.deepClone(data.formRuleSimple),
// }) // })
} }
......
...@@ -45,6 +45,7 @@ Page({ ...@@ -45,6 +45,7 @@ Page({
carSeriesName: "", carSeriesName: "",
salesType: "售前", salesType: "售前",
}, },
mode:1,
quotationGoodsList: [], //权益商品列表 quotationGoodsList: [], //权益商品列表
// owner: { // owner: {
// owner: 'test2', // owner: 'test2',
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
</view> </view>
</navigation-bar> </navigation-bar>
<view class="layout {{showTips?'fullSucreen-tips':'' }} " style="padding-top:{{ navBarHeight }}px;"> <view class="layout {{showTips?'fullSucreen-tips':'' }} " style="padding-top:{{ navBarHeight }}px;">
<first-step id="FirstStep" serviceInfo="{{ owner }}" dataAttrName="{{ dataAttrName }}" orderInfo="{{ orderInfo }}" subBtnShow="{{ false }}" /> <first-step id="FirstStep" serviceInfo="{{ owner }}" dataAttrName="{{ dataAttrName }}" orderInfo="{{ orderInfo }}" subBtnShow="{{ false }}" mode="{{mode}}" />
<second-step id="SecondStep" orderInfo="{{ orderInfo }}" quotationGoodsList="{{ quotationGoodsList }}" bindconfirm="handleSecondConfirm" bindeditSave="handleEditSave" /> <second-step id="SecondStep" orderInfo="{{ orderInfo }}" quotationGoodsList="{{ quotationGoodsList }}" bindconfirm="handleSecondConfirm" bindeditSave="handleEditSave" />
</view> </view>
<view wx:if="{{showTips&&outTradeNo}}" class="btns {{isFullSucreen?'isFullSucreen-btn':''}}"> <view wx:if="{{showTips&&outTradeNo}}" class="btns {{isFullSucreen?'isFullSucreen-btn':''}}">
......
...@@ -74,7 +74,7 @@ Page({ ...@@ -74,7 +74,7 @@ Page({
if (showName == 'goodsBox') { if (showName == 'goodsBox') {
if (selectPayType == 0) return if (selectPayType == 0) return
if (goodsData.length < 1) { if (goodsData.length < 1) {
this.showToast('门店无配置商品') wx.$util.showToast('门店无配置商品')
return return
} }
} }
...@@ -169,20 +169,27 @@ Page({ ...@@ -169,20 +169,27 @@ Page({
console.log(key) console.log(key)
// debugger // debugger
if (key) { if (key) {
this.showToast(toastList[key]) wx.$util.showToast(toastList[key])
wx.pageScrollTo({ wx.pageScrollTo({
selector: `.${key}` selector: `.${key}`
}) })
return return
} }
if (!phoneRex.test(orderObj.owner.phone)) { if (!phoneRex.test(orderObj.owner.phone)) {
this.showToast('请输入正确的手机号') wx.$util.showToast('请输入正确的手机号')
return return
} }
if (orderObj.owner.carVin) { if (orderObj.owner.carVin) {
const vinRex = /[^\w]/g const vinRex = /[^\w]/g
if (vinRex.test(orderObj.owner.carVin)) { if (vinRex.test(orderObj.owner.carVin) || orderObj.owner.carVin.length != 17) {
this.showToast('请输入正确的VIN码') wx.$util.showToast('请输入正确的VIN码')
return
}
}
if (orderObj.owner.certificateNo) {
// const vinRex = /[^\w]/g
if (orderObj.owner.certificateNo.length != 18) {
wx.$util.showToast('请输入正确的身份证号')
return return
} }
} }
...@@ -322,7 +329,7 @@ Page({ ...@@ -322,7 +329,7 @@ Page({
this.setData(options) this.setData(options)
} }
}, },
init(userInfo) {}, init(userInfo) { },
remarkConfirm(e) { remarkConfirm(e) {
let value = e.detail let value = e.detail
...@@ -348,7 +355,7 @@ Page({ ...@@ -348,7 +355,7 @@ Page({
/** /**
* 生命周期函数--监听页面显示 * 生命周期函数--监听页面显示
*/ */
onShow: function () {}, onShow: function () { },
onRoute(id) { onRoute(id) {
// id = 1912 // id = 1912
id && this.getQuotationInfoById(id) id && this.getQuotationInfoById(id)
...@@ -361,25 +368,25 @@ Page({ ...@@ -361,25 +368,25 @@ Page({
/** /**
* 生命周期函数--监听页面隐藏 * 生命周期函数--监听页面隐藏
*/ */
onHide: function () {}, onHide: function () { },
onUnload: () => {}, onUnload: () => { },
/** /**
* 生命周期函数--监听页面卸载 * 生命周期函数--监听页面卸载
*/ */
onUnload: function () {}, onUnload: function () { },
/** /**
* 页面相关事件处理函数--监听用户下拉动作 * 页面相关事件处理函数--监听用户下拉动作
*/ */
onPullDownRefresh: function () {}, onPullDownRefresh: function () { },
/** /**
* 页面上拉触底事件的处理函数 * 页面上拉触底事件的处理函数
*/ */
onReachBottom: function () {}, onReachBottom: function () { },
/** /**
* 用户点击右上角分享 * 用户点击右上角分享
*/ */
onShareAppMessage: function () {} onShareAppMessage: function () { }
}) })
\ No newline at end of file \ No newline at end of file
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!