Commit 691dbca02c572919d5d508b00a3efd624073ae02

Authored by vking
1 parent c1dea71e

fix bug 1157419716001003717 1157419716001003719

@@ -75,18 +75,6 @@ App({ @@ -75,18 +75,6 @@ App({
75 console.log('onUpdateFailed',res) 75 console.log('onUpdateFailed',res)
76 }) 76 })
77 } 77 }
78 - try{  
79 - let sms_code= await this.getClipboardData();  
80 - wx.setClipboardData({  
81 - data:"?"  
82 - })  
83 - console.log('SMS.code',sms_code);  
84 - wx.reLaunch({  
85 - url:'/pages/customer/index?sms_code='+sms_code  
86 - });  
87 - }catch (e){  
88 - console.log('SMS.code.catch',e);  
89 - }  
90 }, 78 },
91 async getSystemInfo(){ 79 async getSystemInfo(){
92 this._getSystemInfo().then((res)=>{ 80 this._getSystemInfo().then((res)=>{
@@ -179,23 +167,6 @@ App({ @@ -179,23 +167,6 @@ App({
179 this.openid=openid 167 this.openid=openid
180 return openid; 168 return openid;
181 }, 169 },
182 - getClipboardData(){  
183 - return new Promise((success,fail)=>{  
184 - wx.getClipboardData({  
185 - success:(res)=>{  
186 - let match=res.data.match(/#(.*)#/);  
187 - if(match && res.data.indexOf('周到安排')>0){  
188 - success(match[1])  
189 - }else{  
190 - fail()  
191 - }  
192 - },  
193 - fail:()=>{  
194 - fail()  
195 - }  
196 - })  
197 - })  
198 - },  
199 onHide(){ 170 onHide(){
200 console.log('onHide'); 171 console.log('onHide');
201 PubSub.emit('appHide') 172 PubSub.emit('appHide')
@@ -277,7 +277,10 @@ Page({ @@ -277,7 +277,10 @@ Page({
277 rid: this.data.bookInfo.id, 277 rid: this.data.bookInfo.id,
278 status: util.attr(e, 'status'), 278 status: util.attr(e, 'status'),
279 cause: await this.getCause(), 279 cause: await this.getCause(),
280 - }).then(() => { 280 + }).then((res) => {
  281 + if(res.ret!=200){
  282 + util.toast(res.msg);
  283 + }
281 this.getDetail(this.data.bookInfo.id, true); 284 this.getDetail(this.data.bookInfo.id, true);
282 }); 285 });
283 }else{ 286 }else{
@@ -285,7 +288,10 @@ Page({ @@ -285,7 +288,10 @@ Page({
285 rid: this.data.bookInfo.id, 288 rid: this.data.bookInfo.id,
286 status: util.attr(e, 'status'), 289 status: util.attr(e, 'status'),
287 cause: await this.getCause(), 290 cause: await this.getCause(),
288 - }).then(() => { 291 + }).then((res) => {
  292 + if(res.ret!=200){
  293 + util.toast(res.msg);
  294 + }
289 this.getDetail(this.data.bookInfo.id, true); 295 this.getDetail(this.data.bookInfo.id, true);
290 }); 296 });
291 } 297 }
@@ -317,7 +323,10 @@ Page({ @@ -317,7 +323,10 @@ Page({
317 cause:await this.getCause('包间已订满'), 323 cause:await this.getCause('包间已订满'),
318 ac:param.auto||"0", 324 ac:param.auto||"0",
319 } 325 }
320 - App.Customer.SetReserveStatus(params).then(()=>{ 326 + App.Customer.SetReserveStatus(params).then((res)=>{
  327 + if(res.ret!=200){
  328 + util.toast(res.msg);
  329 + }
321 this.getDetail(this.data.bookInfo.id,true); 330 this.getDetail(this.data.bookInfo.id,true);
322 PubSub.emit('fulshReseveList') 331 PubSub.emit('fulshReseveList')
323 }) 332 })
@@ -349,7 +358,10 @@ Page({ @@ -349,7 +358,10 @@ Page({
349 this.setData({ 358 this.setData({
350 loaded:false, 359 loaded:false,
351 }) 360 })
352 - App.Customer.SetReserveStatus(params).then(()=>{ 361 + App.Customer.SetReserveStatus(params).then((res)=>{
  362 + if(res.ret!=200){
  363 + util.toast(res.msg);
  364 + }
353 this.getDetail(this.data.bookInfo.id,true); 365 this.getDetail(this.data.bookInfo.id,true);
354 PubSub.emit('fulshReseveList') 366 PubSub.emit('fulshReseveList')
355 }) 367 })