交互上稍微调整
Showing
1 changed file
with
23 additions
and
11 deletions
... | @@ -72,6 +72,8 @@ export default { | ... | @@ -72,6 +72,8 @@ export default { |
72 | modalIcon: "succ", | 72 | modalIcon: "succ", |
73 | modalContent: "", | 73 | modalContent: "", |
74 | 74 | ||
75 | lastPolicyCode: "", | ||
76 | |||
75 | // 国际号码区号列表 | 77 | // 国际号码区号列表 |
76 | nationsPhoneCodeList: [], | 78 | nationsPhoneCodeList: [], |
77 | // 国际地区区号 | 79 | // 国际地区区号 |
... | @@ -330,10 +332,13 @@ export default { | ... | @@ -330,10 +332,13 @@ export default { |
330 | // 获取省份 | 332 | // 获取省份 |
331 | this.provinceList = getCnProvinceList(this.$i18n.locale); | 333 | this.provinceList = getCnProvinceList(this.$i18n.locale); |
332 | 334 | ||
333 | if (this.dataInit) { | 335 | // if (this.dataInit) { |
336 | // return; | ||
337 | // } | ||
338 | if (this.loading) { | ||
334 | return; | 339 | return; |
335 | } | 340 | } |
336 | if (this.loading) { | 341 | if (!this.selectedPolicies || this.selectedPolicies.length == 0) { |
337 | return; | 342 | return; |
338 | } | 343 | } |
339 | // this.data = null; | 344 | // this.data = null; |
... | @@ -342,6 +347,12 @@ export default { | ... | @@ -342,6 +347,12 @@ export default { |
342 | policyId: this.selectedPolicies[0].id, | 347 | policyId: this.selectedPolicies[0].id, |
343 | policyCode: this.selectedPolicies[0].code | 348 | policyCode: this.selectedPolicies[0].code |
344 | }; | 349 | }; |
350 | |||
351 | if (this.lastPolicyCode == param.policyCode) { | ||
352 | return; | ||
353 | } | ||
354 | this.lastPolicyCode = param.policyCode; | ||
355 | |||
345 | httpPost({ | 356 | httpPost({ |
346 | url: api.policyContactDetailApi, | 357 | url: api.policyContactDetailApi, |
347 | data: param, | 358 | data: param, |
... | @@ -361,6 +372,7 @@ export default { | ... | @@ -361,6 +372,7 @@ export default { |
361 | } | 372 | } |
362 | }) | 373 | }) |
363 | .catch(res => { | 374 | .catch(res => { |
375 | this.loading = false; | ||
364 | if (res.code == "404") { | 376 | if (res.code == "404") { |
365 | this.$refs.auth.noAuth(); | 377 | this.$refs.auth.noAuth(); |
366 | } | 378 | } |
... | @@ -384,7 +396,7 @@ export default { | ... | @@ -384,7 +396,7 @@ export default { |
384 | console.error(e); | 396 | console.error(e); |
385 | } | 397 | } |
386 | }, | 398 | }, |
387 | uploadExcel() {}, | 399 | uploadExcel() { }, |
388 | // aaa(){ | 400 | // aaa(){ |
389 | // httpPost({ | 401 | // httpPost({ |
390 | // url: api.indexManageListApi, | 402 | // url: api.indexManageListApi, |
... | @@ -401,25 +413,25 @@ export default { | ... | @@ -401,25 +413,25 @@ export default { |
401 | // } | 413 | // } |
402 | }, | 414 | }, |
403 | watch: { | 415 | watch: { |
404 | "data.mobile": function() { | 416 | "data.mobile": function () { |
405 | this.errorTips.e1 = ""; | 417 | this.errorTips.e1 = ""; |
406 | }, | 418 | }, |
407 | "data.address": function() { | 419 | "data.address": function () { |
408 | this.errorTips.e2 = ""; | 420 | this.errorTips.e2 = ""; |
409 | }, | 421 | }, |
410 | "data.email": function() { | 422 | "data.email": function () { |
411 | this.errorTips.e3 = ""; | 423 | this.errorTips.e3 = ""; |
412 | }, | 424 | }, |
413 | "data.mobileAreaCode": function() { | 425 | "data.mobileAreaCode": function () { |
414 | this.errorTips.e4 = ""; | 426 | this.errorTips.e4 = ""; |
415 | }, | 427 | }, |
416 | "data.countryId": function() { | 428 | "data.countryId": function () { |
417 | this.errorTips.e5 = ""; | 429 | this.errorTips.e5 = ""; |
418 | }, | 430 | }, |
419 | "data.provinceId": function() { | 431 | "data.provinceId": function () { |
420 | this.errorTips.e6 = ""; | 432 | this.errorTips.e6 = ""; |
421 | }, | 433 | }, |
422 | "data.cityId": function() { | 434 | "data.cityId": function () { |
423 | this.errorTips.e7 = ""; | 435 | this.errorTips.e7 = ""; |
424 | } | 436 | } |
425 | }, | 437 | }, |
... | @@ -430,7 +442,7 @@ export default { | ... | @@ -430,7 +442,7 @@ export default { |
430 | this.$root.eventBus.$on("langChange", () => { | 442 | this.$root.eventBus.$on("langChange", () => { |
431 | try { | 443 | try { |
432 | this.initData(); | 444 | this.initData(); |
433 | } catch (e) {} | 445 | } catch (e) { } |
434 | }); | 446 | }); |
435 | } | 447 | } |
436 | }; | 448 | }; | ... | ... |
-
Please register or sign in to post a comment