Sfoglia il codice sorgente

feat: 门店、设备页面修改

pangqijun 3 mesi fa
parent
commit
e9379921f1
2 ha cambiato i file con 27 aggiunte e 4 eliminazioni
  1. 1 1
      src/views/business/shop.vue
  2. 26 3
      src/views/facility/facility.vue

+ 1 - 1
src/views/business/shop.vue

@@ -162,7 +162,7 @@
               label: '门店图片',
               prop: 'storeImage',
               type: 'upload',
-              listType: 'picture-card',
+              listType: 'picture-img',
               loadText: '上传中,请稍等',
               accept: 'image/png, image/jpeg',
               fileSize: 500,

+ 26 - 3
src/views/facility/facility.vue

@@ -30,7 +30,8 @@
 
       <template slot="facilityStatus" slot-scope="scope" >
         <el-tag v-if="scope.row.facilityStatus == '1'" type="success">在线</el-tag>
-        <el-tag v-if="scope.row.facilityStatus == '0'" type="danger">离线</el-tag>
+        <el-tag v-if="scope.row.facilityStatus == '2'" type="danger">离线</el-tag>
+        <el-tag v-if="scope.row.facilityStatus == '3'" type="danger">故障</el-tag>
       </template>
 
       <template slot-scope="scope" slot="menu">
@@ -102,6 +103,8 @@
               label: "所属门店",
               prop: "shopId",
               type: "select",
+              addDisplay: false,
+              editDisplay: false,
               dicUrl: "/api/business/shop/list?status=0&current=1&size=100",
               dicFormatter: function (res) {
                 return res.data.records;
@@ -109,10 +112,23 @@
               props: {
                 label: "storeName",
                 value: "id",
+              }
+            },
+            {
+              label: "所属商家",
+              prop: "merchantId",
+              type: "select",
+              dicUrl: "/api/system/usermerchant/page?parentId=0&current=1&size=99999",
+              dicFormatter: function (res) {
+                return res.data.records;
+              },
+              props: {
+                label: "merchantName",
+                value: "userId",
               },
               rules: [{
                 required: true,
-                message: "请选择门店",
+                message: "请选择商家",
                 trigger: "blur"
               }]
             },
@@ -180,7 +196,14 @@
                 required: true,
                 message: "请输入设备状态",
                 trigger: "blur"
-              }]
+              }],
+              type: "select",
+              dicUrl: "/api/blade-system/dict-biz/getEnumDict?enumName=FacilityStatusEnum",
+              props: {
+                label: "name",
+                value: "value"
+              },
+              dataType: "number",
             },
             {
               label: "最新上传数据时间",