From b09b6361f6348c22d2d02f99391ca76350b45102 Mon Sep 17 00:00:00 2001
From: jinlin <jinlin>
Date: 星期四, 14 三月 2024 14:41:14 +0800
Subject: [PATCH] 修改

---
 web/src/views/modules/basicInfo/TyProductModel-AddOrUpdate.vue                                                 |   69 ++-------
 web/src/views/modules/basicInfo/SelectPicture.vue                                                              |   14 -
 modules/mainPart/src/main/java/com/zt/life/modules/sysPictureBase/model/SysPictureBase.java                    |   16 -
 web/src/views/modules/basicInfo/XhProductModel.vue                                                             |   21 --
 modules/mainPart/src/main/java/com/zt/life/modules/sysPictureBase/controller/SysPictureBaseController.java     |   22 +-
 modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/dao/XhProductModelDao.java               |    2 
 modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/model/TyProductModel.java                |   12 -
 web/src/views/modules/basicInfo/ParamData.vue                                                                  |    2 
 modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/controller/TyProductModelController.java |   18 --
 modules/mainPart/src/main/java/com/zt/life/modules/sysPictureBase/dao/SysPictureBaseDao.java                   |    2 
 modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/service/XhProductModelService.java       |    8 -
 web/src/views/modules/sysPictureBase/SysPictureBase.vue                                                        |    9 
 web/src/views/modules/taskReliability/ConfigNode/index.vue                                                     |    6 
 modules/mainPart/src/main/resources/mapper/sysPictureBase/SysPictureBaseDao.xml                                |   13 +
 web/src/views/modules/sysPictureBase/SysPictureBase-AddOrUpdate.vue                                            |   33 +---
 web/src/views/modules/taskReliability/ModelRbd.vue                                                             |    2 
 web/src/views/modules/basicInfo/TyProductModel.vue                                                             |   23 --
 modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/controller/XhProductModelController.java |   18 --
 modules/mainPart/src/main/java/com/zt/life/modules/sysPictureBase/service/SysPictureBaseService.java           |    7 
 web/src/views/modules/basicInfo/XhProductModel-AddOrUpdate.vue                                                 |   54 +------
 modules/mainPart/src/main/resources/mapper/basicInfo/XhProductModelDao.xml                                     |   14 -
 modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/model/XhProductModel.java                |   15 -
 22 files changed, 108 insertions(+), 272 deletions(-)

diff --git a/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/controller/TyProductModelController.java b/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/controller/TyProductModelController.java
index 84387dc..dca2ce2 100644
--- a/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/controller/TyProductModelController.java
+++ b/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/controller/TyProductModelController.java
@@ -76,22 +76,8 @@
     @ApiOperation("淇℃伅")
     public Result<TyProductModel> get(@PathVariable("id") Long id){
         TyProductModel data = tyProductModelService.get(id);
-        Long busid = null;
-        String fileName = "";
-        if (StringUtils.isNotBlank(data.getOperationalStatus())&&sysOssService.get(Long.parseLong(data.getOperationalStatus()))!=null){
-            busid =sysOssService.get(Long.parseLong(data.getOperationalStatus())).getBusiId();
-            fileName =sysPictureBaseService.get(busid).getName();
-            data.setOperationalStatus(fileName);
-        }
-        if (StringUtils.isNotBlank(data.getStandbyState())&&sysOssService.get(Long.parseLong(data.getStandbyState()))!=null){
-            busid =sysOssService.get(Long.parseLong(data.getStandbyState())).getBusiId();
-            fileName =sysPictureBaseService.get(busid).getName();
-            data.setStandbyState(fileName);
-        }
-        if (StringUtils.isNotBlank(data.getFaultState())&&sysOssService.get(Long.parseLong(data.getFaultState()))!=null){
-            busid =sysOssService.get(Long.parseLong(data.getFaultState())).getBusiId();
-            fileName =sysPictureBaseService.get(busid).getName();
-            data.setFaultState(fileName);
+        if (data.getOperatImg() != null) {
+            data.setOperatImgName(sysPictureBaseService.get(data.getOperatImg()).getName());
         }
         return Result.ok(data);
     }
diff --git a/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/controller/XhProductModelController.java b/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/controller/XhProductModelController.java
index a8ad858..4716cef 100644
--- a/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/controller/XhProductModelController.java
+++ b/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/controller/XhProductModelController.java
@@ -83,22 +83,8 @@
     @ApiOperation("淇℃伅")
     public Result<XhProductModel> get(@PathVariable("id") Long id){
         XhProductModel data = xhProductModelService.get(id);
-        Long busid = null;
-        String fileName = "";
-        if (StringUtils.isNotBlank(data.getOperationalStatus())&&sysOssService.get(Long.parseLong(data.getOperationalStatus()))!=null){
-            busid =sysOssService.get(Long.parseLong(data.getOperationalStatus())).getBusiId();
-            fileName =sysPictureBaseService.get(busid).getName();
-            data.setOperationalStatus(fileName);
-        }
-        if (StringUtils.isNotBlank(data.getStandbyState())&&sysOssService.get(Long.parseLong(data.getStandbyState()))!=null){
-            busid =sysOssService.get(Long.parseLong(data.getStandbyState())).getBusiId();
-            fileName =sysPictureBaseService.get(busid).getName();
-            data.setStandbyState(fileName);
-        }
-        if (StringUtils.isNotBlank(data.getFaultState())&&sysOssService.get(Long.parseLong(data.getFaultState()))!=null){
-            busid =sysOssService.get(Long.parseLong(data.getFaultState())).getBusiId();
-            fileName =sysPictureBaseService.get(busid).getName();
-            data.setFaultState(fileName);
+        if (data.getOperatImg() != null) {
+            data.setOperatImgName(sysPictureBaseService.get(data.getOperatImg()).getName());
         }
         return Result.ok(data);
     }
diff --git a/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/dao/XhProductModelDao.java b/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/dao/XhProductModelDao.java
index 1338d4f..44c3490 100644
--- a/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/dao/XhProductModelDao.java
+++ b/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/dao/XhProductModelDao.java
@@ -28,6 +28,4 @@
     List<XhProductModel> getProductList();
 
     List<ProductImg> getProduct(Long productId);
-
-    String getDefaultImg();
 }
diff --git a/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/model/TyProductModel.java b/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/model/TyProductModel.java
index e3c2269..12cc60b 100644
--- a/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/model/TyProductModel.java
+++ b/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/model/TyProductModel.java
@@ -44,14 +44,12 @@
 	@ApiModelProperty(value = "缁翠慨鍒嗗竷")
 	private Integer repairDistrib;
 
-	@ApiModelProperty(value = "杩愯鐘舵�佸浘鐗嘔D")
-	private String operationalStatus;
+	@ApiModelProperty(value = "杩愯鍥剧墖ID")
+	private Long operatImg;
 
-	@ApiModelProperty(value = "寰呮満鐘舵�佸浘鐗嘔D")
-	private String standbyState;
-
-	@ApiModelProperty(value = "鏁呴殰鐘舵�佸浘鐗嘔D")
-	private String faultState;
+	@TableField(exist = false)
+	@ApiModelProperty(value = "鍥剧墖鍚嶇О")
+	private String operatImgName;
 
 	@ApiModelProperty(value = "鎺掑簭")
 	private Integer sort;
diff --git a/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/model/XhProductModel.java b/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/model/XhProductModel.java
index 3a2f572..d205ef8 100644
--- a/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/model/XhProductModel.java
+++ b/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/model/XhProductModel.java
@@ -35,17 +35,12 @@
 	@ApiModelProperty(value = "鑺傜偣绫诲瀷")
 	private String productType;
 
-	@ApiModelProperty(value = "榛樿鍥剧墖")
-	private String defaultImg;
+	@ApiModelProperty(value = "杩愯鍥剧墖")
+	private Long operatImg;
 
-	@ApiModelProperty(value = "杩愯鐘舵�佸浘鐗�")
-	private String operationalStatus;
-
-	@ApiModelProperty(value = "寰呮満鐘舵�佸浘鐗�")
-	private String standbyState;
-
-	@ApiModelProperty(value = "鏁呴殰鐘舵�佸浘鐗�")
-	private String faultState;
+	@TableField(exist = false)
+	@ApiModelProperty(value = "鍥剧墖鍚嶇О")
+	private String operatImgName;
 
 	@ApiModelProperty(value = "鎺掑簭")
 	private Integer sort;
diff --git a/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/service/XhProductModelService.java b/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/service/XhProductModelService.java
index cee7108..45e9f6e 100644
--- a/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/service/XhProductModelService.java
+++ b/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/basicInfo/service/XhProductModelService.java
@@ -34,14 +34,6 @@
      */
     public List<XhProductModel> page(QueryFilter queryFilter) {
         List<XhProductModel> list = baseDao.getList(queryFilter.getQueryParams());
-        for (XhProductModel productModel : list) {
-            if (productModel.getProductType().equals("1")) {
-                productModel.setDefaultImg(baseDao.getDefaultImg());
-                if (productModel.getId() != null) {
-                    this.update(productModel);
-                }
-            }
-        }
         return list;
     }
 
diff --git a/modules/mainPart/src/main/java/com/zt/life/modules/sysPictureBase/controller/SysPictureBaseController.java b/modules/mainPart/src/main/java/com/zt/life/modules/sysPictureBase/controller/SysPictureBaseController.java
index 20da472..1b43a66 100644
--- a/modules/mainPart/src/main/java/com/zt/life/modules/sysPictureBase/controller/SysPictureBaseController.java
+++ b/modules/mainPart/src/main/java/com/zt/life/modules/sysPictureBase/controller/SysPictureBaseController.java
@@ -63,7 +63,7 @@
     @ApiImplicitParams({
             @ApiImplicitParam(name = Constant.Q.ORDER_FIELD, value = Constant.QV.ORDER_FIELD, dataType = Constant.QT.STRING),
             @ApiImplicitParam(name = Constant.Q.ORDER, value = Constant.QV.ORDER, dataType = Constant.QT.STRING),
-            @ApiImplicitParam(name = "contentType", value = "妫�绱㈠叧閿瓧", dataType = Constant.QT.STRING, format = "CONTENT_TYPE^LK"), @ApiImplicitParam(name = "systemMark", value = "绯荤粺鏍囪瘑", dataType = Constant.QT.STRING, format = "SYSTEM_MARK^LK")})
+            @ApiImplicitParam(name = "productType", value = "妫�绱㈠叧閿瓧", dataType = Constant.QT.STRING, format = "CONTENT_TYPE^LK"), @ApiImplicitParam(name = "systemMark", value = "绯荤粺鏍囪瘑", dataType = Constant.QT.STRING, format = "SYSTEM_MARK^LK")})
     public Result<List<SysPictureBase>> page(@ApiIgnore @QueryParam QueryFilter queryFilter) {
 
         return Result.ok(sysPictureBaseService.page(queryFilter));
@@ -79,31 +79,29 @@
     @PostMapping("save")
     @ApiOperation("淇濆瓨")
     @LogOperation("淇濆瓨")
-    public Result save(@RequestBody MultipartFile file, Long id, String type, String subType,
-                       String name, String contentType, String systemMark, Integer sortNo, String remark) {
+    public Result save(@RequestBody MultipartFile file, Long id, Integer isDefault,
+                       String name, String contentType, Integer productType,  String remark) {
         SysPictureBase sysPictureBase;
         if (id != 0) {
             sysPictureBase = sysPictureBaseService.get(id);
-            sysPictureBase.setType(type);
-            sysPictureBase.setSubType(subType);
+            sysPictureBase.setIsDefault(isDefault);
             sysPictureBase.setName(name);
             sysPictureBase.setContentType(contentType);
-            sysPictureBase.setSystemMark(systemMark);
-            sysPictureBase.setSortNo(sortNo);
+            sysPictureBase.setProductType(productType);
             sysPictureBase.setRemark(remark);
             sysPictureBaseService.update(sysPictureBase);
         } else {
             sysPictureBase = new SysPictureBase();
-            sysPictureBase.setType(type);
-            sysPictureBase.setSubType(subType);
+            sysPictureBase.setIsDefault(isDefault);
             sysPictureBase.setName(name);
             sysPictureBase.setContentType(contentType);
-            sysPictureBase.setSystemMark(systemMark);
-            Integer no = sysPictureBaseService.getNo();
-            sysPictureBase.setSortNo(no + 1);
+            sysPictureBase.setProductType(productType);
             sysPictureBase.setRemark(remark);
             sysPictureBaseService.insert(sysPictureBase);
         }
+        if (sysPictureBase.getIsDefault()==1){
+            sysPictureBaseService.updateByDefault(sysPictureBase.getId(),sysPictureBase.getProductType());
+        }
         if (file != null) {
             BufferedImage bufferedImage = null;
             try {
diff --git a/modules/mainPart/src/main/java/com/zt/life/modules/sysPictureBase/dao/SysPictureBaseDao.java b/modules/mainPart/src/main/java/com/zt/life/modules/sysPictureBase/dao/SysPictureBaseDao.java
index 6acefce..78f39ea 100644
--- a/modules/mainPart/src/main/java/com/zt/life/modules/sysPictureBase/dao/SysPictureBaseDao.java
+++ b/modules/mainPart/src/main/java/com/zt/life/modules/sysPictureBase/dao/SysPictureBaseDao.java
@@ -20,5 +20,5 @@
 
     List<SysPictureBase> getList(Map<String, Object> params);
 
-    Integer getNo();
+    void updateByDefault(Long id, Integer productType);
 }
diff --git a/modules/mainPart/src/main/java/com/zt/life/modules/sysPictureBase/model/SysPictureBase.java b/modules/mainPart/src/main/java/com/zt/life/modules/sysPictureBase/model/SysPictureBase.java
index a8e8f1c..755d19e 100644
--- a/modules/mainPart/src/main/java/com/zt/life/modules/sysPictureBase/model/SysPictureBase.java
+++ b/modules/mainPart/src/main/java/com/zt/life/modules/sysPictureBase/model/SysPictureBase.java
@@ -24,11 +24,8 @@
 public class SysPictureBase extends BusiEntity {
 	private static final long serialVersionUID = 1L;
 
-	@ApiModelProperty(value = "绫诲瀷")
-	private String type;
-
-	@ApiModelProperty(value = "瀛愮被鍨�")
-	private String subType;
+	@ApiModelProperty(value = "鏄惁榛樿")
+	private Integer isDefault;
 
 	@ApiModelProperty(value = "鍥剧墖鍚嶇О")
 	private String name;
@@ -42,16 +39,11 @@
 	@ApiModelProperty(value = "妫�绱㈠叧閿瓧")
 	private String contentType;
 
-	@ApiModelProperty(value = "绯荤粺鏍囪瘑")
-	private String systemMark;
-
-	@ApiModelProperty(value = "鎺掑簭")
-	private Integer sortNo;
+	@ApiModelProperty(value = "浜у搧绫诲瀷")
+	private Integer productType;
 
 	@ApiModelProperty(value = "")
 	private String remark;
 
-	@TableField(exist = false)
-	private MultipartFile file;
 
 }
diff --git a/modules/mainPart/src/main/java/com/zt/life/modules/sysPictureBase/service/SysPictureBaseService.java b/modules/mainPart/src/main/java/com/zt/life/modules/sysPictureBase/service/SysPictureBaseService.java
index b8aeb12..984c4d1 100644
--- a/modules/mainPart/src/main/java/com/zt/life/modules/sysPictureBase/service/SysPictureBaseService.java
+++ b/modules/mainPart/src/main/java/com/zt/life/modules/sysPictureBase/service/SysPictureBaseService.java
@@ -42,10 +42,7 @@
         super.deleteLogic(ids);
     }
 
-    public Integer getNo() {
-        if (baseDao.getNo() == null){
-            return 0;
-        }
-        return baseDao.getNo();
+    public void updateByDefault(Long id, Integer productType) {
+        baseDao.updateByDefault(id,productType);
     }
 }
diff --git a/modules/mainPart/src/main/resources/mapper/basicInfo/XhProductModelDao.xml b/modules/mainPart/src/main/resources/mapper/basicInfo/XhProductModelDao.xml
index 94f638d..478e530 100644
--- a/modules/mainPart/src/main/resources/mapper/basicInfo/XhProductModelDao.xml
+++ b/modules/mainPart/src/main/resources/mapper/basicInfo/XhProductModelDao.xml
@@ -43,12 +43,12 @@
           and a.product_type = 5
     </select>
     <select id="getProduct" resultType="com.zt.life.modules.mainPart.basicInfo.model.ProductImg">
-        SELECT a.default_img               as imgPath,
+        SELECT a.operat_img               as imgPath,
                a.`NAME`                    as imgName,
                'node'                      as nodeType,
                ''                          as nodeTypeExt,
-               s.width                          as imgWidth,
-               s.height                          as imgHeight,
+               s.width                     as imgWidth,
+               s.height                    as imgHeight,
                a.id                        as dataId,
                ''                          as statusImg,
                d.dict_code                 as productType,
@@ -61,15 +61,9 @@
         FROM product_model a
                  left join sys_dict_data d on d.DICT_VALUE = a.product_type and dict_type_id = '1728965873022050306'
                  left join param_data p on p.product_id = a.id and p.page_code = 'expect'
-                 left join sys_picture_base s on s.id = a.default_img
+                 left join sys_picture_base s on s.id = a.operat_img
         WHERE a.is_delete = 0
           AND a.PID = ${productId}
 
-    </select>
-    <select id="getDefaultImg" resultType="java.lang.String">
-        SELECT a.id
-        FROM sys_picture_base a
-        WHERE a.IS_DELETE = 0
-          AND a.CONTENT_TYPE = '榛樿璁惧'
     </select>
 </mapper>
diff --git a/modules/mainPart/src/main/resources/mapper/sysPictureBase/SysPictureBaseDao.xml b/modules/mainPart/src/main/resources/mapper/sysPictureBase/SysPictureBaseDao.xml
index 1c0969c..eaba2a7 100644
--- a/modules/mainPart/src/main/resources/mapper/sysPictureBase/SysPictureBaseDao.xml
+++ b/modules/mainPart/src/main/resources/mapper/sysPictureBase/SysPictureBaseDao.xml
@@ -2,6 +2,13 @@
 <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
 
 <mapper namespace="com.zt.life.modules.sysPictureBase.dao.SysPictureBaseDao">
+    <update id="updateByDefault">
+        update sys_picture_base
+        set is_default=2
+        where id = ${id}
+          and product_type = ${productType}
+          and is_delete = 0
+    </update>
 
     <select id="getList" resultType="com.zt.life.modules.sysPictureBase.model.SysPictureBase">
         select a.*
@@ -16,10 +23,4 @@
             ORDER BY ${orderBySql}
         </if>
     </select>
-    <select id="getNo" resultType="java.lang.Integer">
-        SELECT COUNT(*)
-        FROM sys_picture_base
-        WHERE is_delete = 0;
-    </select>
-
 </mapper>
diff --git a/web/src/views/modules/basicInfo/ParamData.vue b/web/src/views/modules/basicInfo/ParamData.vue
index d0eb084..9952de6 100644
--- a/web/src/views/modules/basicInfo/ParamData.vue
+++ b/web/src/views/modules/basicInfo/ParamData.vue
@@ -8,7 +8,7 @@
       </el-col>
       <el-col :span="19">
         <div class="mod-basicInfo-paramData}">
-          <zt-table-wraper ref="tableObj" :query-url=queryUrl
+          <zt-table-wraper ref="tableObj" defaultNotQuery="true" :query-url=queryUrl
                            :delete-url=deleteUrl
                            @dataLoaded="dataLoaded"
                            v-slot="{ table }"
diff --git a/web/src/views/modules/basicInfo/SelectPicture.vue b/web/src/views/modules/basicInfo/SelectPicture.vue
index 29203ab..2b66296 100644
--- a/web/src/views/modules/basicInfo/SelectPicture.vue
+++ b/web/src/views/modules/basicInfo/SelectPicture.vue
@@ -12,7 +12,7 @@
             <el-table-column prop="name" label="鍥剧墖鍚嶇О"/>
             <el-table-column label="鍥剧墖" align="center">
               <template v-slot="{ row }">
-                <el-image v-if="row.accessoryMap" :src="getPath(row)" style="height: 50px;width: 50px"></el-image>
+                <el-image v-if="row.id" :src="url+row.id" style="height: 50px;width: 50px"></el-image>
               </template>
             </el-table-column>
           </el-table>
@@ -23,13 +23,16 @@
 </template>
 
 <script>
+  import Cookies from 'js-cookie'
 
   export default {
     data() {
       return {
+        url: `${window.SITE_CONFIG['apiURL']}/sysPictureBase/getProductImg?token=${Cookies.get('token')}&id=`,
         name: 'SelectPicture',
         type: '',
         dataForm: {
+          id:'',
           contentType: '',
           systemMark: '',
           sortNo: ''
@@ -41,17 +44,10 @@
       init(type) {
         this.type = type
       },
-      getPath(row) {
-        if (row.accessoryMap) {
-          for (let key in row.accessoryMap) {
-            return key
-          }
-        }
-      },
       async selectedPicture(row) {
         await this.$tip.success()
         this.$refs.dialog.close()
-        this.$emit('setPicture', row, this.type)
+        this.$emit('setPicture', row)
       }
     }
   }
diff --git a/web/src/views/modules/basicInfo/TyProductModel-AddOrUpdate.vue b/web/src/views/modules/basicInfo/TyProductModel-AddOrUpdate.vue
index 8904e43..8cd13a7 100644
--- a/web/src/views/modules/basicInfo/TyProductModel-AddOrUpdate.vue
+++ b/web/src/views/modules/basicInfo/TyProductModel-AddOrUpdate.vue
@@ -1,7 +1,7 @@
 <template>
-  <zt-dialog ref="dialog"  @confirm="formSubmit" append-to-body>
+  <zt-dialog ref="dialog" @confirm="formSubmit" append-to-body>
     <el-form :model="dataForm" ref="dataForm" :disabled="dataForm.disabled" label-width="120px">
-      <zt-form-item label="涓婄骇绯荤粺" prop="pid" >
+      <zt-form-item label="涓婄骇绯荤粺" prop="pid">
         <zt-select v-model="dataForm.pid" placeholder=" " :datas="productList"/>
       </zt-form-item>
       <zt-form-item label="鍚嶇О" prop="name" rules="required">
@@ -22,14 +22,8 @@
       <zt-form-item label="缁翠慨鍒嗗竷" prop="repairDistrib">
         <zt-dict v-model="dataForm.repairDistrib" dict="RepairDistribType" placeholder="璇烽�夋嫨缁翠慨鍒嗗竷绫诲瀷"></zt-dict>
       </zt-form-item>
-      <zt-form-item label="杩愯鐘舵�佸浘" prop="operationalStatus">
-        <el-input v-model="dataForm.operationalStatus" @focus="selectPicture('operational')"   :readonly="readonly"></el-input>
-      </zt-form-item>
-      <zt-form-item label="寰呮満鐘舵�佸浘" prop="standbyState">
-        <el-input v-model="dataForm.standbyState" @focus="selectPicture('standby')"   :readonly="readonly"></el-input>
-      </zt-form-item>
-      <zt-form-item label="鏁呴殰鐘舵�佸浘" prop="faultState">
-        <el-input v-model="dataForm.faultState" @focus="selectPicture('fault')"   :readonly="readonly"></el-input>
+      <zt-form-item label="杩愯鍥剧墖" prop="operatImg">
+        <el-input v-model="dataForm.operatImgName" @focus="selectPicture()" :readonly="readonly"></el-input>
       </zt-form-item>
       <zt-form-item label="鎺掑簭" prop="sort">
         <el-input v-model="dataForm.sort" :readonly="readonly"></el-input>
@@ -46,9 +40,8 @@
   export default {
     data() {
       return {
-        map: new Map(),
-        fileId:'',
-        productList:[],
+        fileId: '',
+        productList: [],
         dataForm: {
           id: '',
           pid: '',
@@ -58,56 +51,33 @@
           taskCompute: '',
           reliabDistrib: '',
           repairDistrib: '',
-          operationalStatus:'',
-          standbyState:'',
-          faultState:'',
+          operatImg: '',
+          operatImgName:'',
           sort: '',
         }
       }
     },
-    components:{
+    components: {
       PictureSelect
     },
     methods: {
       init() {
         this.getProductList()
+
       },
       // 鑾峰彇绯荤粺鍒楄〃
       async getProductList() {
         let res = await this.$http.get('/basicInfo/TyProductModel/getProductList')
         this.productList = res.data
-        console.log(this.productList,'getProductList')
+        console.log(this.productList, 'getProductList')
       },
-      selectPicture(type){
-        this.$refs.pictureSelect.$refs.dialog.init(type)
+      selectPicture() {
+        this.$refs.pictureSelect.$refs.dialog.init()
       },
-      openAddWin(row,type){
-        console.log(type,'openAddWin(row)')
-        if (type==='operational'){
-          this.dataForm.operationalStatus = row.name
-          for (let key in row.accessoryMap) {
-            let id = /_zt_oss_id=(\d+)/.exec(key)
-            this.fileId = id ? id[1] : ''
-          }
-          this.map.set(this.dataForm.operationalStatus,this.fileId);
-          console.log(this.map,'openAddWin(row)')
-        }else if(type==='standby'){
-          this.dataForm.standbyState = row.name
-          for (let key in row.accessoryMap) {
-            let id = /_zt_oss_id=(\d+)/.exec(key)
-            this.fileId = id ? id[1] : ''
-          }
-          this.map.set(this.dataForm.standbyState,this.fileId);
-          console.log(this.map,'openAddWin(row)')
-        }else if(type==='fault'){
-          this.dataForm.faultState = row.name
-          for (let key in row.accessoryMap) {
-            let id = /_zt_oss_id=(\d+)/.exec(key)
-            this.fileId = id ? id[1] : ''
-          }
-          this.map.set(this.dataForm.faultState,this.fileId);
-          console.log(this.map,'openAddWin(row)')
-        }
+      openAddWin(row) {
+        this.dataForm.operatImgName = row.name
+        this.dataForm.operatImg = row.id
+        console.log(row, 'openAddWin(row)')
       },
       // 鑾峰彇淇℃伅
       async getInfo() {
@@ -116,13 +86,10 @@
           ...this.dataForm,
           ...res.data
         }
-        console.log(this.map,'getInfo')
+        console.log(this.map, 'getInfo')
       },
       // 琛ㄥ崟鎻愪氦
       async formSubmit() {
-        this.dataForm.operationalStatus = this.map.get(this.dataForm.operationalStatus)
-        this.dataForm.standbyState = this.map.get(this.dataForm.standbyState)
-        this.dataForm.faultState = this.map.get(this.dataForm.faultState)
         let res = await this.$http[!this.dataForm.id ? 'post' : 'put']('/basicInfo/TyProductModel/', this.dataForm)
         if (res.success) {
           await this.$tip.success()
diff --git a/web/src/views/modules/basicInfo/TyProductModel.vue b/web/src/views/modules/basicInfo/TyProductModel.vue
index c362169..3438ece 100644
--- a/web/src/views/modules/basicInfo/TyProductModel.vue
+++ b/web/src/views/modules/basicInfo/TyProductModel.vue
@@ -31,20 +31,10 @@
           <zt-table-column-dict prop="taskCompute" label="浠诲姟璁$畻" dict="is_or_not"/>
           <zt-table-column-dict prop="reliabDistrib" label="鍙潬鎬у垎甯�" dict="ReliabDistribType"/>
           <zt-table-column-dict prop="repairDistrib" label="缁翠慨鍒嗗竷" dict="RepairDistribType"/>
-          <el-table-column prop="operationalStatus" label="杩愯鐘舵�佸浘" align="center">
+          <el-table-column prop="operatImg" label="杩愯鍥剧墖" align="center">
             <template v-slot="{ row }">
-              <el-image v-if="row.operationalStatus" :src="getPath(row.operationalStatus)" style="height: 50px;width: 50px"></el-image>
-            </template >
-          </el-table-column>
-          <el-table-column prop="standbyState" label="寰呮満鐘舵�佸浘" align="center">
-            <template v-slot="{ row }">
-              <el-image v-if="row.standbyState" :src="getPath(row.standbyState)" style="height: 50px;width: 50px"></el-image>
-            </template >
-          </el-table-column>
-          <el-table-column prop="faultState" label="鏁呴殰鐘舵�佸浘" align="center">
-            <template v-slot="{ row }">
-              <el-image v-if="row.faultState" :src="getPath(row.faultState)" style="height: 50px;width: 50px"></el-image>
-            </template >
+              <el-image v-if="row.operatImg" :src="url+row.operatImg" style="height: 50px;width: 50px"></el-image>
+            </template>
           </el-table-column>
           <el-table-column prop="sort" label="鎺掑簭"/>
           <zt-table-column-handle :table="table"/>
@@ -58,10 +48,12 @@
 
 <script>
   import AddOrUpdate from './TyProductModel-AddOrUpdate'
+  import Cookies from "js-cookie";
 
   export default {
     data() {
       return {
+        url: `${window.SITE_CONFIG['apiURL']}/sysPictureBase/getProductImg?token=${Cookies.get('token')}&id=`,
         dataForm: {
           operationalStatus:'',
           standbyState:'',
@@ -81,10 +73,7 @@
           return 'text-align: left !important;'
         }
       },
-      getPath(id){
-        console.log(id,'path')
-        return `${window.SITE_CONFIG['apiURL']}/sys/oss/content2?fileId=${id}`
-      }
+
     }
   }
 </script>
diff --git a/web/src/views/modules/basicInfo/XhProductModel-AddOrUpdate.vue b/web/src/views/modules/basicInfo/XhProductModel-AddOrUpdate.vue
index f7fae5a..cb15cbf 100644
--- a/web/src/views/modules/basicInfo/XhProductModel-AddOrUpdate.vue
+++ b/web/src/views/modules/basicInfo/XhProductModel-AddOrUpdate.vue
@@ -10,15 +10,9 @@
       <zt-form-item label="鑺傜偣绫诲瀷" prop="productType" rules="required">
         <zt-dict v-model="dataForm.productType" dict="product"></zt-dict>
       </zt-form-item>
-      <zt-form-item label="杩愯鐘舵�佸浘" prop="operationalStatus" v-if="isShow">
-        <el-input v-model="dataForm.operationalStatus" @focus="selectPicture('operational')"
+      <zt-form-item label="杩愯鐘舵�佸浘" prop="operatImg" v-if="isShow">
+        <el-input v-model="dataForm.operatImgName" @focus="selectPicture()"
                   :readonly="readonly"></el-input>
-      </zt-form-item>
-      <zt-form-item label="寰呮満鐘舵�佸浘" prop="standbyState" v-if="isShow">
-        <el-input v-model="dataForm.standbyState" @focus="selectPicture('standby')" :readonly="readonly"></el-input>
-      </zt-form-item>
-      <zt-form-item label="鏁呴殰鐘舵�佸浘" prop="faultState" v-if="isShow">
-        <el-input v-model="dataForm.faultState" @focus="selectPicture('fault')" :readonly="readonly"></el-input>
       </zt-form-item>
       <zt-form-item label="鎺掑簭" prop="sort">
         <el-input v-model="dataForm.sort" :readonly="readonly"></el-input>
@@ -37,7 +31,6 @@
       return {
         isTree: false,
         isShow: true,
-        map: new Map(),
         fileId: '',
         productList: [],
         dataForm: {
@@ -45,9 +38,8 @@
           pid: '',
           name: '',
           productType: '',
-          operationalStatus: '',
-          standbyState: '',
-          faultState: '',
+          operatImg: '',
+          operatImgName:'',
           sort: '',
           status: ''
         }
@@ -72,36 +64,13 @@
         this.productList = res.data
         console.log(this.productList, 'getProductList')
       },
-      selectPicture(type) {
-        this.$refs.pictureSelect.$refs.dialog.init(type)
+      selectPicture() {
+        this.$refs.pictureSelect.$refs.dialog.init()
       },
-      openAddWin(row, type) {
-        console.log(type, 'openAddWin(row)')
-        if (type === 'operational') {
-          this.dataForm.operationalStatus = row.name
-          for (let key in row.accessoryMap) {
-            let id = /_zt_oss_id=(\d+)/.exec(key)
-            this.fileId = id ? id[1] : ''
-          }
-          this.map.set(this.dataForm.operationalStatus, this.fileId);
-          console.log(this.map, 'openAddWin(row)')
-        } else if (type === 'standby') {
-          this.dataForm.standbyState = row.name
-          for (let key in row.accessoryMap) {
-            let id = /_zt_oss_id=(\d+)/.exec(key)
-            this.fileId = id ? id[1] : ''
-          }
-          this.map.set(this.dataForm.standbyState, this.fileId);
-          console.log(this.map, 'openAddWin(row)')
-        } else if (type === 'fault') {
-          this.dataForm.faultState = row.name
-          for (let key in row.accessoryMap) {
-            let id = /_zt_oss_id=(\d+)/.exec(key)
-            this.fileId = id ? id[1] : ''
-          }
-          this.map.set(this.dataForm.faultState, this.fileId);
-          console.log(this.map, 'openAddWin(row)')
-        }
+      openAddWin(row) {
+        this.dataForm.operatImgName = row.name
+        this.dataForm.operatImg = row.id
+        console.log(row, 'openAddWin(row)')
       },
       // 鑾峰彇淇℃伅
       async getInfo() {
@@ -113,9 +82,6 @@
       },
       // 琛ㄥ崟鎻愪氦
       async formSubmit() {
-        this.dataForm.operationalStatus = this.map.get(this.dataForm.operationalStatus)
-        this.dataForm.standbyState = this.map.get(this.dataForm.standbyState)
-        this.dataForm.faultState = this.map.get(this.dataForm.faultState)
         let res = await this.$http[!this.dataForm.id ? 'post' : 'put']('/basicInfo/XhProductModel/', this.dataForm)
         if (res.success) {
           await this.$tip.success()
diff --git a/web/src/views/modules/basicInfo/XhProductModel.vue b/web/src/views/modules/basicInfo/XhProductModel.vue
index 35a464b..38c680e 100644
--- a/web/src/views/modules/basicInfo/XhProductModel.vue
+++ b/web/src/views/modules/basicInfo/XhProductModel.vue
@@ -8,7 +8,7 @@
       </el-col>
       <el-col :span="19">
         <div class="mod-basicInfo-xhProductModel}">
-          <zt-table-wraper ref="tableObj" query-url="/basicInfo/XhProductModel/page"
+          <zt-table-wraper ref="tableObj"  defaultNotQuery="true" query-url="/basicInfo/XhProductModel/page"
                            delete-url="/basicInfo/XhProductModel/ "
                            :paging='false'
                            v-slot="{ table }">
@@ -28,22 +28,9 @@
             >
               <el-table-column prop="name" label="鍚嶇О"/>
               <zt-table-column-dict prop="productType" label="鑺傜偣绫诲瀷" dict="product"/>
-              <el-table-column prop="operationalStatus" label="杩愯鐘舵�佸浘" align="center">
+              <el-table-column prop="operatImg" label="杩愯鍥剧墖" align="center">
                 <template v-slot="{ row }">
-                  <el-image v-if="row.operationalStatus" :src="getPath(row.operationalStatus)"
-                            style="height: 50px;width: 50px"></el-image>
-                </template>
-              </el-table-column>
-              <el-table-column prop="standbyState" label="寰呮満鐘舵�佸浘" align="center">
-                <template v-slot="{ row }">
-                  <el-image v-if="row.standbyState" :src="getPath(row.standbyState)"
-                            style="height: 50px;width: 50px"></el-image>
-                </template>
-              </el-table-column>
-              <el-table-column prop="faultState" label="鏁呴殰鐘舵�佸浘" align="center">
-                <template v-slot="{ row }">
-                  <el-image v-if="row.faultState" :src="getPath(row.faultState)"
-                            style="height: 50px;width: 50px"></el-image>
+                  <el-image v-if="row.operatImg" :src="url+row.operatImg" style="height: 50px;width: 50px"></el-image>
                 </template>
               </el-table-column>
               <el-table-column prop="sort" label="鎺掑簭"/>
@@ -63,10 +50,12 @@
   import AddOrUpdate from './XhProductModel-AddOrUpdate'
   import SelectTyModel from './SelectTyModel'
   import ProductModelTree from "./ProductModelTree";
+  import Cookies from "js-cookie";
 
   export default {
     data() {
       return {
+        url: `${window.SITE_CONFIG['apiURL']}/sysPictureBase/getProductImg?token=${Cookies.get('token')}&id=`,
         dataForm: {
           name: '',
           productType: '',
diff --git a/web/src/views/modules/sysPictureBase/SysPictureBase-AddOrUpdate.vue b/web/src/views/modules/sysPictureBase/SysPictureBase-AddOrUpdate.vue
index 1968216..6ae2af8 100644
--- a/web/src/views/modules/sysPictureBase/SysPictureBase-AddOrUpdate.vue
+++ b/web/src/views/modules/sysPictureBase/SysPictureBase-AddOrUpdate.vue
@@ -1,25 +1,19 @@
 <template>
   <zt-dialog ref="dialog" @confirm="formSubmit">
     <el-form :model="dataForm" ref="dataForm" :disabled="dataForm.disabled" label-width="120px">
-      <zt-form-item label="绫诲瀷" prop="type">
-        <el-input v-model="dataForm.type"></el-input>
-      </zt-form-item>
-      <zt-form-item label="瀛愮被鍨�" prop="subType">
-        <el-input v-model="dataForm.subType"></el-input>
-      </zt-form-item>
+
       <zt-form-item label="鍥剧墖鍚嶇О" prop="name" rules="required">
         <el-input v-model="dataForm.name"></el-input>
+      </zt-form-item>
+      <zt-form-item label="浜у搧绫诲瀷" prop="productType" rules="required">
+        <zt-dict v-model="dataForm.productType" dict="product"></zt-dict>
+      </zt-form-item>
+      <zt-form-item label="鏄惁榛樿" prop="isDefault" rules="required">
+        <zt-dict v-model="dataForm.isDefault" dict="is_or_not"></zt-dict>
       </zt-form-item>
       <zt-form-item label="妫�绱㈠叧閿瓧" prop="contentType">
         <el-input v-model="dataForm.contentType"></el-input>
       </zt-form-item>
-      <zt-form-item label="绯荤粺鏍囪瘑" prop="systemMark">
-        <zt-dict v-model="dataForm.systemMark" dict="product"></zt-dict>
-      </zt-form-item>
-      <zt-form-item label="鎺掑簭" prop="sortNo">
-        <el-input v-model="dataForm.sortNo" :readonly="readonly" @input=""></el-input>
-      </zt-form-item>
-
       <div class="el-flex img-src" style="height: 20px">
         <el-form-item class="marginTopAndMarginBottom" style="width: 100%">
           <!--<config-uploader :lineHeight="true" busi-type="sys_picture" model-name="dataForm" :dataForm="dataForm"
@@ -44,12 +38,10 @@
         fileList: [],
         dataForm: {
           id: '',
-          type: '',
-          subType: '',
+          isDefault: '',
           name: '',
           contentType: '',
-          systemMark: '',
-          sortNo: '',
+          productType: '',
           remark: ''
         },
         readonly: {
@@ -100,12 +92,11 @@
           this.dataForm.id = 0
         }
         params.append('id', this.dataForm.id)
-        params.append('type', this.dataForm.type)
-        params.append('subType', this.dataForm.subType)
+        params.append('isDefault', this.dataForm.isDefault)
         params.append('name', this.dataForm.name)
         params.append('contentType', this.dataForm.contentType)
-        params.append('systemMark', this.dataForm.systemMark)
-        params.append('sortNo', this.dataForm.sortNo)
+        params.append('productType', this.dataForm.productType)
+        params.append('remark', this.dataForm.remark)
         console.log(params, 'async formSubmit()')
         let res = await this.$http.post('/sysPictureBase/save', params)
         if (res.success) {
diff --git a/web/src/views/modules/sysPictureBase/SysPictureBase.vue b/web/src/views/modules/sysPictureBase/SysPictureBase.vue
index 03fd11b..c4c67c9 100644
--- a/web/src/views/modules/sysPictureBase/SysPictureBase.vue
+++ b/web/src/views/modules/sysPictureBase/SysPictureBase.vue
@@ -10,7 +10,7 @@
 
           </el-form-item>
           <el-form-item>
-            <zt-dict v-model="dataForm.systemMark" dict="product" placeholder="璇烽�夋嫨绯荤粺鏍囪瘑" clearable></zt-dict>
+            <zt-dict v-model="dataForm.productType" dict="product" placeholder="璇烽�夋嫨浜у搧绫诲瀷" clearable></zt-dict>
           </el-form-item>
           <el-form-item>
             <zt-button type="query" @click="table.query()"/>
@@ -21,15 +21,15 @@
         <el-table v-loading="table.dataLoading" :data="table.dataList" height="100px" v-adaptive="{bottomOffset:70}"
                   border @selection-change="table.selectionChangeHandle">
           <el-table-column type="selection" width="40" align="center"/>
-          <el-table-column prop="sortNo" label="鎺掑簭"/>
           <el-table-column prop="name" label="鍥剧墖鍚嶇О"/>
+          <zt-table-column-dict prop="isDefault" label="鏄惁榛樿" dict="is_or_not"/>
           <el-table-column label="鍥剧墖" align="center">
             <template v-slot="{ row }">
               <el-image v-if="row.id" :src="url+row.id" style="height: 50px;width: 50px"></el-image>
             </template>
           </el-table-column>
           <el-table-column prop="contentType" label="妫�绱㈠叧閿瓧"/>
-          <zt-table-column-dict prop="systemMark" label="绯荤粺鏍囪瘑" dict="product"/>
+          <zt-table-column-dict prop="productType" label="浜у搧绫诲瀷" dict="product"/>
           <zt-table-column-handle :table="table"
                                   delete-perm="sysPictureBase::delete"/>
         </el-table>
@@ -50,8 +50,7 @@
         url: `${window.SITE_CONFIG['apiURL']}/sysPictureBase/getProductImg?token=${Cookies.get('token')}&id=`,
         dataForm: {
           contentType: '',
-          systemMark: '',
-          sortNo: ''
+          productType: '',
         },
       }
     },
diff --git a/web/src/views/modules/taskReliability/ConfigNode/index.vue b/web/src/views/modules/taskReliability/ConfigNode/index.vue
index 8be9eae..d8d41d0 100644
--- a/web/src/views/modules/taskReliability/ConfigNode/index.vue
+++ b/web/src/views/modules/taskReliability/ConfigNode/index.vue
@@ -48,7 +48,8 @@
           </el-col>
         </el-row>
         <el-row :gutter="5" v-show="nodeType=='node'" align="middle" style="margin-top:20px;">
-          <el-col :span=24>
+          <el-col :span=8 style="font-size: 16px;line-height: 32px">MTBCF</el-col>
+          <el-col :span=16>
             <el-input  type="number" v-model="globalGridAttr.taskMtbcf" @change="onTaskMtbcfChange"></el-input>
           </el-col>
         </el-row>
@@ -79,7 +80,8 @@
             </el-col>
           </el-row>
           <el-row :gutter="5"  align="middle" style="margin-top:20px;">
-            <el-col :span=24>
+            <el-col :span=8 style="font-size: 16px;line-height: 32px">MTTCR</el-col>
+            <el-col :span=16>
               <el-input  type="number" v-model="globalGridAttr.repairMttcr" @change="onRepairMttcrChange"></el-input>
             </el-col>
           </el-row>
diff --git a/web/src/views/modules/taskReliability/ModelRbd.vue b/web/src/views/modules/taskReliability/ModelRbd.vue
index a73e8eb..ec99f55 100644
--- a/web/src/views/modules/taskReliability/ModelRbd.vue
+++ b/web/src/views/modules/taskReliability/ModelRbd.vue
@@ -31,7 +31,7 @@
               <zt-table-column-handle :table="table"
                                       delete-perm="taskReliability::delete" :has-view="false" width="180px">
                 <template v-slot="{ row }">
-                  <el-button type="primary" @click="drawRBD(row)">妯″瀷璁捐</el-button>
+                  <el-button  @click="drawRBD(row)">妯″瀷璁捐</el-button>
                 </template>
               </zt-table-column-handle>
             </el-table>

--
Gitblit v1.9.1