Bladeren bron

切换服务商修改

yanym 3 weken geleden
bovenliggende
commit
1d2d159e1f
1 gewijzigde bestanden met toevoegingen van 7 en 2 verwijderingen
  1. 7 2
      src/views/AIDesign/design.vue

+ 7 - 2
src/views/AIDesign/design.vue

@@ -1288,8 +1288,13 @@ export default class extends Vue {
     formData.append('projectid', projectId);
     GetProjectlist(formData).then(response => {
       if (response.StatusCode == 200) {
-        that.checkedProject = response.Data[0];
-        that.radioClick(response.Data[0].servicecode,'',false);
+        const serviceCodeIndex = that.fwsList.findIndex(item => item.shop_code == response.Data[0].servicecode);
+        if (serviceCodeIndex == -1){
+            that.radioClick(that.fwsList[0].shop_code,'',true);
+        }else {
+            that.checkedProject = response.Data[0];
+            that.radioClick(response.Data[0].servicecode,'',false);
+        }
       } else {
         // console.log(response.Info)
       }