|
@@ -17,7 +17,7 @@ Page({ |
|
@@ -17,7 +17,7 @@ Page({ |
|
17
|
detail:null,
|
17
|
detail:null,
|
|
18
|
user:_u,
|
18
|
user:_u,
|
|
19
|
},
|
19
|
},
|
|
20
|
-
|
20
|
+ hasSubmit:true,
|
|
21
|
/**
|
21
|
/**
|
|
22
|
* 生命周期函数--监听页面加载
|
22
|
* 生命周期函数--监听页面加载
|
|
23
|
*/
|
23
|
*/
|
|
@@ -109,12 +109,14 @@ Page({ |
|
@@ -109,12 +109,14 @@ Page({ |
|
109
|
}
|
109
|
}
|
|
110
|
},
|
110
|
},
|
|
111
|
saved() {
|
111
|
saved() {
|
|
|
|
112
|
+ if(!this.hasSubmit) return;
|
|
112
|
if(!this.user.name){
|
113
|
if(!this.user.name){
|
|
113
|
return util.toast('请填写姓名','none')
|
114
|
return util.toast('请填写姓名','none')
|
|
114
|
}
|
115
|
}
|
|
115
|
if(!this.user.phone){
|
116
|
if(!this.user.phone){
|
|
116
|
return util.toast('请填写手机','none')
|
117
|
return util.toast('请填写手机','none')
|
|
117
|
}
|
118
|
}
|
|
|
|
119
|
+ this.hasSubmit=false;
|
|
118
|
App.Customer.SetReserveInfo({
|
120
|
App.Customer.SetReserveInfo({
|
|
119
|
sid:this.options.sid,
|
121
|
sid:this.options.sid,
|
|
120
|
pnum:this.options.pnum,
|
122
|
pnum:this.options.pnum,
|
|
@@ -126,6 +128,7 @@ Page({ |
|
@@ -126,6 +128,7 @@ Page({ |
|
126
|
cusdem:this.user.remark||'',
|
128
|
cusdem:this.user.remark||'',
|
|
127
|
}).then(res=>{
|
129
|
}).then(res=>{
|
|
128
|
if(res.ret!=200){
|
130
|
if(res.ret!=200){
|
|
|
|
131
|
+ this.hasSubmit=true;
|
|
129
|
return util.toast(res.msg,'none');
|
132
|
return util.toast(res.msg,'none');
|
|
130
|
}
|
133
|
}
|
|
131
|
if(res.data.hasSetUserInfo){
|
134
|
if(res.data.hasSetUserInfo){
|