asd26269546 1 år sedan
förälder
incheckning
c1dd2d31d4
2 ändrade filer med 2 tillägg och 2 borttagningar
  1. 1 1
      src/views/customer/highseas/index.vue
  2. 1 1
      src/views/customer/privatesea/index.vue

+ 1 - 1
src/views/customer/highseas/index.vue

@@ -47,7 +47,7 @@ const getList = (type) => {
         res.data.rows = res.data.rows.map((item) => {
           return {
             ...item,
-            cityText: item.countryName + "," + item.provinceName + "," + item.cityName,
+            cityText: item.countryName + "," + (item.provinceName ? item.provinceName + "," : '')  + (item.cityName ? item.cityName + "," : ''),
           };
         });
       }

+ 1 - 1
src/views/customer/privatesea/index.vue

@@ -46,7 +46,7 @@ const getList = (type) => {
         res.data.rows = res.data.rows.map((item) => {
           return {
             ...item,
-            cityText: item.countryName + "," + item.provinceName + "," + item.cityName,
+            cityText: item.countryName + "," + (item.provinceName ? item.provinceName + "," : '')  + (item.cityName ? item.cityName + "," : ''),
           };
         });
       }