Browse Source

LY bug fix

ly 2 năm trước cách đây
mục cha
commit
de27e761ff

+ 15 - 0
master/src/main/java/com/ruoyi/common/utils/file/FileUtils.java

@@ -104,6 +104,21 @@ public class FileUtils extends org.apache.commons.io.FileUtils
         return filename.matches(FILENAME_PATTERN);
     }
 
+    /**
+     * 文件名称验证并替换
+     *
+     * @param filename 文件名称
+     * @return true 正常 false 非法
+     */
+    public static String isValidFilenameAndReplace(String filename)
+    {
+        if (filename.matches(FILENAME_PATTERN)) {
+            return filename;
+        } else {
+            return filename.replaceAll("[^a-zA-Z0-9_-|.\\u4e00-\\u9fa5]", "_");
+        }
+    }
+
     /**
      * 下载文件名重新编码
      *

+ 3 - 3
master/src/main/java/com/ruoyi/framework/task/byx/PlantproglistBYXTask.java

@@ -79,7 +79,7 @@ public class PlantproglistBYXTask extends BaseController {
         TAlarmtype alarmtype = alarmtypeService.selectTAlarmtypeById(AlarmtypeId);
         TPlantproglist query = new TPlantproglist();
         query.setDeptId(10010l);
-        List<TPlantproglist> plantproglist = plantproglistService.selectList(new TPlantproglist());
+        List<TPlantproglist> plantproglist = plantproglistService.selectList(query);
         HashSet<String> responsibilitys = new HashSet<>(); //责任人集合
         for (TPlantproglist t : plantproglist
         ) {
@@ -143,7 +143,7 @@ public class PlantproglistBYXTask extends BaseController {
                         if (t.getNexteditdate() == null) {//回顾日期为空的情况
                             continue;
                         }
-                        long diff = t.getNexteditdate().getTime() - now;
+                        long diff = t.getNextreviewdate().getTime() - now;
                         long nd = 1000 * 24 * 60 * 60;
                         long reviewDifference = diff / nd;
                         if (reviewDifference <= firstLevel) {
@@ -173,7 +173,7 @@ public class PlantproglistBYXTask extends BaseController {
     public void EditTask() {
         TPlantproglist query = new TPlantproglist();
         query.setDeptId(10010l);
-        List<TPlantproglist> plantproglist = plantproglistService.selectList(new TPlantproglist());
+        List<TPlantproglist> plantproglist = plantproglistService.selectList(query);
         HashSet<String> responsibilitys = new HashSet<>(); //责任人集合
         for (TPlantproglist t : plantproglist
         ) {

+ 4 - 2
master/src/main/java/com/ruoyi/project/sems/controller/TReportHiYlgdController.java

@@ -12,6 +12,7 @@ import com.alibaba.fastjson.JSON;
 import com.ruoyi.common.utils.StringUtils;
 import com.ruoyi.common.utils.document.PDFTemplateUtil;
 import com.ruoyi.common.utils.document.ZipUtil;
+import com.ruoyi.common.utils.file.FileUtils;
 import com.ruoyi.framework.config.RuoYiConfig;
 import com.ruoyi.project.sems.domain.*;
 import com.ruoyi.project.sems.service.ITReportYlgdService;
@@ -272,7 +273,7 @@ public class TReportHiYlgdController extends BaseController {
                 HistoricTaskInstanceQuery htiq = historyService.createHistoricTaskInstanceQuery();
                 List<HistoricTaskInstance> htiLists = htiq.processInstanceId(tReportHiYlgd.getApproveId()).finished().orderByHistoricTaskInstanceEndTime().asc().list();
                 logger.info("报告数据:" + JSON.toJSONString(htiLists));
-                if (htiLists != null) {
+                if (htiLists != null && htiLists.size() > 0) {
                     SimpleDateFormat sdf2 = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
                     map.put("inspectorOne", iSysUserService.selectUserById(Long.parseLong(htiLists.get(0).getAssignee())).getNickName());
                     map.put("inspectorOneEndTime", sdf2.format(htiLists.get(0).getEndTime()));
@@ -289,10 +290,11 @@ public class TReportHiYlgdController extends BaseController {
                 String pdfName = tReportHiYlgd.getPlantCode()
                         + "-" + sdf.format(tReportHiYlgd.getCheckDate())
                         + "-" + tReportHiYlgd.getDevno()
-                        + "-压力管道年度检查报告.pdf"
+                        + "-压力管道年度检查报告" +tReportHiYlgd.getReportId() + ".pdf"
                         .replace(" ", "")
                         .replace("\\s", "")
                         .replace("\n", "");
+                pdfName = FileUtils.isValidFilenameAndReplace(pdfName); //验证合规
                 // 生成PDF文件
                 PDFTemplateUtil.createPdf("yearYlgdFMaker.ftl", pdfName,
                         RuoYiConfig.getProfile() + "/reportHi/" + now,

+ 3 - 1
master/src/main/java/com/ruoyi/project/sems/controller/TReportHiYlrqController.java

@@ -13,6 +13,7 @@ import com.alibaba.fastjson.JSON;
 import com.ruoyi.common.utils.StringUtils;
 import com.ruoyi.common.utils.document.PDFTemplateUtil;
 import com.ruoyi.common.utils.document.ZipUtil;
+import com.ruoyi.common.utils.file.FileUtils;
 import com.ruoyi.framework.config.RuoYiConfig;
 import com.ruoyi.project.sems.domain.*;
 import com.ruoyi.project.sems.service.ITReportYlgdService;
@@ -194,10 +195,11 @@ public class TReportHiYlrqController extends BaseController {
             String pdfName = tReportHiYlrq.getPlantCode()
                     + "-" + check
                     + "-" + tReportHiYlrq.getDevno()
-                    + "-压力容器年度检查报告.pdf"
+                    + "-压力容器年度检查报告" +tReportHiYlrq.getReportId() + ".pdf"
                     .replace(" ", "")
                     .replace("\\s", "")
                     .replace("\n", "");
+            pdfName = FileUtils.isValidFilenameAndReplace(pdfName); //验证合规
             PDFTemplateUtil.exportPdf("yearYlrqFMaker.ftl", pdfName, "file:/" + RuoYiConfig.getProfile(), map, response);
         } catch (Exception e) {
             e.printStackTrace();

+ 10 - 0
master/src/main/java/com/ruoyi/project/sems/domain/TReportHiYlgd.java

@@ -153,6 +153,8 @@ public class TReportHiYlgd extends BaseEntity
     /** 修改时间 */
     private Date updatedate;
 
+    private String reportUrll;
+
     public void setId(Long id)
     {
         this.id = id;
@@ -550,6 +552,14 @@ public class TReportHiYlgd extends BaseEntity
         return updatedate;
     }
 
+    public String getReportUrll() {
+        return reportUrll;
+    }
+
+    public void setReportUrll(String reportUrll) {
+        this.reportUrll = reportUrll;
+    }
+
     @Override
     public String toString() {
         return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)

+ 2 - 2
master/src/main/resources/freeMaker/yearYlgdFMaker.ftl

@@ -129,7 +129,7 @@
 				<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; padding-left:5.4pt; padding-right:5.4pt; vertical-align:middle; width:270.4pt">
 					<p style="margin:0pt; text-align:center">
 						<span style="font-family:SimSun; font-size:16pt">
-							<#if devYlgd.useno??>${devYlgd.useno}</#if>
+							<#if devYlgd.useno??>${devYlgd.useno?html}</#if>
 						</span>
 					</p>
 				</td>
@@ -226,7 +226,7 @@
 				</td>
 				<td colspan="2" style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; padding-left:5.03pt; padding-right:5.03pt; vertical-align:middle; width:110pt">
 					<p style="margin:0pt; text-align:center">
-						<span style="font-family:SimSun; font-size:11pt">${devYlgd.starting}-${devYlgd.ending}</span>
+						<span style="font-family:SimSun; font-size:11pt">${devYlgd.starting?html}-${devYlgd.ending?html}</span>
 					</p>
 				</td>
 				<td colspan="3" style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; padding-left:5.03pt; padding-right:5.03pt; vertical-align:middle; width:70pt">

+ 1 - 1
master/src/main/resources/mybatis/document/TPlantproglistMapper.xml

@@ -53,7 +53,7 @@
             <if test="revision != null  and revision != ''"> and revision = #{revision}</if>
             <if test="rccode != null  and rccode != ''"> and rccode = #{rccode}</if>
             <if test="carrier != null  and carrier != ''"> and carrier = #{carrier}</if>
-            <if test="responsibility != null  and responsibility != ''"> and responsibility = #{responsibility}</if>
+            <if test="responsibility != null  and responsibility != ''"> and responsibility like concat(concat('%',#{responsibility}),'%')</if>
             <if test="filedate != null "> and filedate = #{filedate}</if>
             <if test="reviewdate != null "> and reviewdate = #{reviewdate}</if>
             <if test="nextreviewdate != null "> and nextreviewdate = #{nextreviewdate}</if>

+ 11 - 1
ui/src/views/components/PlantProgList/index.vue

@@ -10,6 +10,16 @@
           @input="handleQuery"
         />
       </el-form-item>
+      <el-form-item :label="$t('更新负责人')" prop="filename">
+        <el-input
+          v-model="queryParams.responsibility"
+          :placeholder="$t('请输入') + $t('更新负责人')"
+          clearable
+          size="small"
+          @input="handleQuery"
+        />
+      </el-form-item>
+
       <el-form-item>
         <el-button type="cyan" icon="el-icon-search" size="mini" @click="handleQuery">{{ $t('搜索') }}</el-button>
         <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">{{ $t('重置') }}</el-button>
@@ -107,7 +117,7 @@
       <el-table-column :label="$t('下次修订日期')" align="center" prop="nexteditdate" width="100">
         <template slot-scope="scope">
           <span style="vertical-align:middle">{{ parseTime(scope.row.nexteditdate, '{y}-{m}-{d}') }}</span>
-          <svg-icon v-if="scope.row.item !== 5" :icon-class="changeColorPiont(scope.row.nexteditdate)"
+          <svg-icon  :icon-class="changeColorPiont(scope.row.nexteditdate)"
                     style="font-size: 8px"></svg-icon>
         </template>
       </el-table-column>

+ 10 - 10
ui/src/views/front/acrylicTank.vue

@@ -18,45 +18,45 @@
           <img src="@/assets/image/Spherical2.png" style="height: 100px;width: 80px; margin-top: 0.7rem" v-if="20<=(dashboarddata.acrOne) && (dashboarddata.acrOne)<40">
           <img src="@/assets/image/Spherical3.png" style="height: 100px;width: 80px; margin-top: 0.7rem" v-if="40<=(dashboarddata.acrOne) && (dashboarddata.acrOne)<60">
           <img src="@/assets/image/Spherical4.png" style="height: 100px;width: 80px; margin-top: 0.7rem" v-if="60<=(dashboarddata.acrOne) && (dashboarddata.acrOne)<80">
-          <img src="@/assets/image/Spherical5.png" style="height: 100px;width: 80px; margin-top: 0.7rem" v-if="80<=(dashboarddata.acrOne) ">
+          <img src="@/assets/image/Spherical5.png" style="height: 100px;width: 80px; margin-top: 0.7rem" v-if="80<=(dashboarddata.acrOne) && (dashboarddata.acrOne)<100">
           <span class="modelTop pos1">STT1011</span>
-          <div class="ModelFont">{{ dashboarddata.acrOne }}</div>
+          <div class="ModelFont">{{ dashboarddata.acrOne }}%</div>
         </div>
         <div style="position: relative;">
           <img src="@/assets/image/Spherical1.png" style="height: 100px;width: 80px; margin-top: 0.1rem" v-if="0<=(dashboarddata.acrTwo) && (dashboarddata.acrTwo)<20">
           <img src="@/assets/image/Spherical2.png" style="height: 100px;width: 80px; margin-top: 0.1rem" v-if="20<=(dashboarddata.acrTwo) && (dashboarddata.acrTwo)<40">
           <img src="@/assets/image/Spherical3.png" style="height: 100px;width: 80px; margin-top: 0.1rem" v-if="40<=(dashboarddata.acrTwo) && (dashboarddata.acrTwo)<60">
           <img src="@/assets/image/Spherical4.png" style="height: 100px;width: 80px; margin-top: 0.1rem" v-if="60<=(dashboarddata.acrTwo) && (dashboarddata.acrTwo)<80">
-          <img src="@/assets/image/Spherical5.png" style="height: 100px;width: 80px; margin-top: 0.1rem" v-if="80<=(dashboarddata.acrTwo) ">
+          <img src="@/assets/image/Spherical5.png" style="height: 100px;width: 80px; margin-top: 0.1rem" v-if="80<=(dashboarddata.acrTwo) && (dashboarddata.acrTwo)<100">
           <span class="modelTop pos2">STT1012</span>
-          <div class="ModelFont">{{ dashboarddata.acrTwo }}</div>
+          <div class="ModelFont">{{ dashboarddata.acrTwo }}%</div>
         </div>
         <div style="position: relative;">
           <img src="@/assets/image/Spherical1.png" style="height: 100px;width: 80px; margin-top: 0.7rem" v-if="0<=(dashboarddata.acrThree) && (dashboarddata.acrThree)<20">
           <img src="@/assets/image/Spherical2.png" style="height: 100px;width: 80px; margin-top: 0.7rem" v-if="20<=(dashboarddata.acrThree) && (dashboarddata.acrThree)<40">
           <img src="@/assets/image/Spherical3.png" style="height: 100px;width: 80px; margin-top: 0.7rem" v-if="40<=(dashboarddata.acrThree) && (dashboarddata.acrThree)<60">
           <img src="@/assets/image/Spherical4.png" style="height: 100px;width: 80px; margin-top: 0.7rem" v-if="60<=(dashboarddata.acrThree) && (dashboarddata.acrThree)<80">
-          <img src="@/assets/image/Spherical5.png" style="height: 100px;width: 80px; margin-top: 0.7rem" v-if="80<=(dashboarddata.acrThree) ">
+          <img src="@/assets/image/Spherical5.png" style="height: 100px;width: 80px; margin-top: 0.7rem" v-if="80<=(dashboarddata.acrThree) && (dashboarddata.acrThree)<100">
           <span class="modelTop pos3">STT1013</span>
-          <div class="ModelFont">{{ dashboarddata.acrThree }}</div>
+          <div class="ModelFont">{{ dashboarddata.acrThree }}%</div>
         </div>
         <div style="position: relative;">
           <img src="@/assets/image/Spherical1.png" style="height: 100px;width: 80px; margin-top: 0.1rem" v-if="0<=(dashboarddata.acrFour) && (dashboarddata.acrFour)<20">
           <img src="@/assets/image/Spherical2.png" style="height: 100px;width: 80px; margin-top: 0.1rem" v-if="20<=(dashboarddata.acrFour) && (dashboarddata.acrFour)<40">
           <img src="@/assets/image/Spherical3.png" style="height: 100px;width: 80px; margin-top: 0.1rem" v-if="40<=(dashboarddata.acrFour) && (dashboarddata.acrFour)<60">
           <img src="@/assets/image/Spherical4.png" style="height: 100px;width: 80px; margin-top: 0.1rem" v-if="60<=(dashboarddata.acrFour) && (dashboarddata.acrFour)<80">
-          <img src="@/assets/image/Spherical5.png" style="height: 100px;width: 80px; margin-top: 0.1rem" v-if="80<=(dashboarddata.acrFour) ">
+          <img src="@/assets/image/Spherical5.png" style="height: 100px;width: 80px; margin-top: 0.1rem" v-if="80<=(dashboarddata.acrFour) && (dashboarddata.acrFour)<100">
           <span class="modelTop pos4">STT1014</span>
-          <div class="ModelFont">{{ dashboarddata.acrFour }}</div>
+          <div class="ModelFont">{{ dashboarddata.acrFour }}%</div>
         </div>
         <div style="position: relative;">
           <img src="@/assets/image/Spherical1.png" style="height: 100px;width: 80px; margin-top: 0.7rem" v-if="0<=(dashboarddata.acrZero) && (dashboarddata.acrZero)<20">
           <img src="@/assets/image/Spherical2.png" style="height: 100px;width: 80px; margin-top: 0.7rem" v-if="20<=(dashboarddata.acrZero) && (dashboarddata.acrZero)<40">
           <img src="@/assets/image/Spherical3.png" style="height: 100px;width: 80px; margin-top: 0.7rem" v-if="40<=(dashboarddata.acrZero) && (dashboarddata.acrZero)<60">
           <img src="@/assets/image/Spherical4.png" style="height: 100px;width: 80px; margin-top: 0.7rem" v-if="60<=(dashboarddata.acrZero) && (dashboarddata.acrZero)<80">
-          <img src="@/assets/image/Spherical5.png" style="height: 100px;width: 80px; margin-top: 0.7rem" v-if="80<=(dashboarddata.acrZero) ">
+          <img src="@/assets/image/Spherical5.png" style="height: 100px;width: 80px; margin-top: 0.7rem" v-if="80<=(dashboarddata.acrZero) && (dashboarddata.acrZero)<100">
           <span class="modelTop pos5">STT1040</span>
-          <div class="ModelFont">{{ dashboarddata.acrZero }}</div>
+          <div class="ModelFont">{{ dashboarddata.acrZero }}%</div>
         </div>
       </div>
     </div>

+ 10 - 10
ui/src/views/front/ethyleneTank.vue

@@ -18,18 +18,18 @@
             <img src="@/assets/image/cylindrical2.png" style="width:40px;height: 170px;" v-if="20<=(dashboarddata.ehtOne) && (dashboarddata.ehtOne)<40">
             <img src="@/assets/image/cylindrical3.png" style="width:40px;height: 170px;" v-if="40<=(dashboarddata.ehtOne) && (dashboarddata.ehtOne)<60">
             <img src="@/assets/image/cylindrical4.png" style="width:40px;height: 170px;" v-if="60<=(dashboarddata.ehtOne) && (dashboarddata.ehtOne)<80">
-            <img src="@/assets/image/cylindrical5.png" style="width:40px;height: 170px;" v-if="80<=(dashboarddata.ehtOne)">
+            <img src="@/assets/image/cylindrical5.png" style="width:40px;height: 170px;" v-if="80<=(dashboarddata.ehtOne) && (dashboarddata.ehtOne)<100">
             <span class="modelTop pos">STT1061</span>
-            <span class="ModelFont">{{ dashboarddata.ehtOne }}</span>
+            <span class="ModelFont">{{ dashboarddata.ehtOne }}%</span>
         </div>
         <div style="position: relative; margin-left: 8% ;">
           <img src="@/assets/image/cylindrical1.png" style="width:40px;height: 170px;" v-if="0<=(dashboarddata.ehtTwo) && (dashboarddata.ehtTwo)<20">
           <img src="@/assets/image/cylindrical2.png" style="width:40px;height: 170px;" v-if="20<=(dashboarddata.ehtTwo) && (dashboarddata.ehtTwo)<40">
           <img src="@/assets/image/cylindrical3.png" style="width:40px;height: 170px;" v-if="40<=(dashboarddata.ehtTwo) && (dashboarddata.ehtTwo)<60">
           <img src="@/assets/image/cylindrical4.png" style="width:40px;height: 170px;" v-if="60<=(dashboarddata.ehtTwo) && (dashboarddata.ehtTwo)<80">
-          <img src="@/assets/image/cylindrical5.png" style="width:40px;height: 170px;" v-if="80<=(dashboarddata.ehtTwo)">
+          <img src="@/assets/image/cylindrical5.png" style="width:40px;height: 170px;" v-if="80<=(dashboarddata.ehtTwo) && (dashboarddata.ehtTwo)<100">
             <span class="modelTop pos">STT1062</span>
-            <span class="ModelFont">{{ dashboarddata.ehtTwo }}</span>
+            <span class="ModelFont">{{ dashboarddata.ehtTwo }}%</span>
         </div>
 
         <div style="position: relative;margin-left: 8% ;">
@@ -37,27 +37,27 @@
           <img src="@/assets/image/cylindrical2.png" style="width:40px;height: 170px;" v-if="20<=(dashboarddata.ehtThree) && (dashboarddata.ehtThree)<40">
           <img src="@/assets/image/cylindrical3.png" style="width:40px;height: 170px;" v-if="40<=(dashboarddata.ehtThree) && (dashboarddata.ehtThree)<60">
           <img src="@/assets/image/cylindrical4.png" style="width:40px;height: 170px;" v-if="60<=(dashboarddata.ehtThree) && (dashboarddata.ehtThree)<80">
-          <img src="@/assets/image/cylindrical5.png" style="width:40px;height: 170px;" v-if="80<=(dashboarddata.ehtThree)">
+          <img src="@/assets/image/cylindrical5.png" style="width:40px;height: 170px;" v-if="80<=(dashboarddata.ehtThree) && (dashboarddata.ehtThree)<100">
           <span class="modelTop pos">STT1063</span>
-          <span class="ModelFont">{{ dashboarddata.ehtThree }}</span>
+          <span class="ModelFont">{{ dashboarddata.ehtThree }}%</span>
         </div>
         <div style="position: relative;margin-left: 8% ;">
           <img src="@/assets/image/cylindrical1.png" style="width:40px;height: 170px;" v-if="0<=(dashboarddata.ehtFour) && (dashboarddata.ehtFour)<20">
           <img src="@/assets/image/cylindrical2.png" style="width:40px;height: 170px;" v-if="20<=(dashboarddata.ehtFour) && (dashboarddata.ehtFour)<40">
           <img src="@/assets/image/cylindrical3.png" style="width:40px;height: 170px;" v-if="40<=(dashboarddata.ehtFour) && (dashboarddata.ehtFour)<60">
           <img src="@/assets/image/cylindrical4.png" style="width:40px;height: 170px;" v-if="60<=(dashboarddata.ehtFour) && (dashboarddata.ehtFour)<80">
-          <img src="@/assets/image/cylindrical5.png" style="width:40px;height: 170px;" v-if="80<=(dashboarddata.ehtFour)">
+          <img src="@/assets/image/cylindrical5.png" style="width:40px;height: 170px;" v-if="80<=(dashboarddata.ehtFour) && (dashboarddata.ehtFour)<100">
           <span class="modelTop pos">STT1064</span>
-          <span class="ModelFont">{{ dashboarddata.ehtFour }}</span>
+          <span class="ModelFont">{{ dashboarddata.ehtFour }}%</span>
         </div>
         <div style="position: relative;margin-left: 8% ;">
           <img src="@/assets/image/cylindrical1.png" style="width:40px;height: 170px;" v-if="0<=(dashboarddata.ehtFive) && (dashboarddata.ehtFive)<20">
           <img src="@/assets/image/cylindrical2.png" style="width:40px;height: 170px;" v-if="20<=(dashboarddata.ehtFive) && (dashboarddata.ehtFive)<40">
           <img src="@/assets/image/cylindrical3.png" style="width:40px;height: 170px;" v-if="40<=(dashboarddata.ehtFive) && (dashboarddata.ehtFive)<60">
           <img src="@/assets/image/cylindrical4.png" style="width:40px;height: 170px;" v-if="60<=(dashboarddata.ehtFive) && (dashboarddata.ehtFive)<80">
-          <img src="@/assets/image/cylindrical5.png" style="width:40px;height: 170px;" v-if="80<=(dashboarddata.ehtFive)">
+          <img src="@/assets/image/cylindrical5.png" style="width:40px;height: 170px;" v-if="80<=(dashboarddata.ehtFive) && (dashboarddata.ehtFive)<100">
           <span class="modelTop pos">STT1065</span>
-          <span class="ModelFont">{{ dashboarddata.ehtFive }}</span>
+          <span class="ModelFont">{{ dashboarddata.ehtFive }}%</span>
         </div>
       </div>
     </div>

+ 6 - 6
ui/src/views/front/napTank.vue

@@ -19,8 +19,8 @@
           <img src="@/assets/image/warehouse2.png" style="height: 100px;width:120px;margin-top: 0.3rem" v-if="20<=(dashboarddata.napOne) && (dashboarddata.napOne)<40">
           <img src="@/assets/image/warehouse3.png" style="height: 100px;width:120px;margin-top: 0.3rem" v-if="40<=(dashboarddata.napOne) && (dashboarddata.napOne)<60">
           <img src="@/assets/image/warehouse1.png" style="height: 100px;width:120px;margin-top: 0.3rem" v-if="60<=(dashboarddata.napOne) && (dashboarddata.napOne)<80">
-          <img src="@/assets/image/warehouse1.png" style="height: 100px;width:120px;margin-top: 0.3rem" v-if="80<=(dashboarddata.napOne)">
-          <div class="ModelFont">{{ dashboarddata.napOne }}</div>
+          <img src="@/assets/image/warehouse1.png" style="height: 100px;width:120px;margin-top: 0.3rem" v-if="80<=(dashboarddata.napOne) && (dashboarddata.napOne)<100">
+          <div class="ModelFont">{{ dashboarddata.napOne }}%</div>
         </div>
         <div style="position: relative;margin: 0 3%;">
           <span class="span-num2">T1622</span>
@@ -28,8 +28,8 @@
           <img src="@/assets/image/warehouse2.png" style="height: 100px;width:120px;margin-top: 0.3rem" v-if="20<=(dashboarddata.napTwo) && (dashboarddata.napTwo)<40">
           <img src="@/assets/image/warehouse3.png" style="height: 100px;width:120px;margin-top: 0.3rem" v-if="40<=(dashboarddata.napTwo) && (dashboarddata.napTwo)<60">
           <img src="@/assets/image/warehouse1.png" style="height: 100px;width:120px;margin-top: 0.3rem" v-if="60<=(dashboarddata.napTwo) && (dashboarddata.napTwo)<80">
-          <img src="@/assets/image/warehouse1.png" style="height: 100px;width:120px;margin-top: 0.3rem" v-if="80<=(dashboarddata.napTwo) ">
-          <div class="ModelFont">{{ dashboarddata.napTwo }}</div>
+          <img src="@/assets/image/warehouse1.png" style="height: 100px;width:120px;margin-top: 0.3rem" v-if="80<=(dashboarddata.napTwo) && (dashboarddata.napTwo)<100">
+          <div class="ModelFont">{{ dashboarddata.napTwo }}%</div>
         </div>
         <div style="position: relative;">
           <span class="span-num3">T1623</span>
@@ -37,8 +37,8 @@
           <img src="@/assets/image/warehouse2.png" style="height: 100px;width:120px;margin-top: 0.3rem" v-if="20<=(dashboarddata.napThree) && (dashboarddata.napThree)<40">
           <img src="@/assets/image/warehouse3.png" style="height: 100px;width:120px;margin-top: 0.3rem" v-if="40<=(dashboarddata.napThree) && (dashboarddata.napThree)<60">
           <img src="@/assets/image/warehouse1.png" style="height: 100px;width:120px;margin-top: 0.3rem" v-if="60<=(dashboarddata.napThree) && (dashboarddata.napThree)<80">
-          <img src="@/assets/image/warehouse1.png" style="height: 100px;width:120px;margin-top: 0.3rem" v-if="80<=(dashboarddata.napThree) ">
-          <div class="ModelFont">{{ dashboarddata.napThree }}</div>
+          <img src="@/assets/image/warehouse1.png" style="height: 100px;width:120px;margin-top: 0.3rem" v-if="80<=(dashboarddata.napThree) && (dashboarddata.napThree)<100">
+          <div class="ModelFont">{{ dashboarddata.napThree }}%</div>
         </div>
       </div>
     </div>

+ 8 - 8
ui/src/views/front/productTank.vue

@@ -18,8 +18,8 @@
           <img src="@/assets/image/warehouse2.png" style="height: 124px;margin-top: 0.3rem" v-if="20<=(dashboarddata.proTwo) && (dashboarddata.proTwo)<40">
           <img src="@/assets/image/warehouse3.png" style="height: 124px;margin-top: 0.3rem" v-if="40<=(dashboarddata.proTwo) && (dashboarddata.proTwo)<60">
           <img src="@/assets/image/warehouse1.png" style="height: 124px;margin-top: 0.3rem" v-if="60<=(dashboarddata.proTwo) && (dashboarddata.proTwo)<80">
-          <img src="@/assets/image/warehouse1.png" style="height: 124px;margin-top: 0.3rem" v-if="80<=(dashboarddata.proTwo)">
-          <div class="ModelFont" style="margin-left: 55px;margin-top: 7px">{{ dashboarddata.proTwo }}</div>
+          <img src="@/assets/image/warehouse1.png" style="height: 124px;margin-top: 0.3rem" v-if="80<=(dashboarddata.proTwo) && (dashboarddata.proTwo)<100">
+          <div class="ModelFont" style="margin-left: 55px;margin-top: 7px">{{ dashboarddata.proTwo }}%</div>
           <span class="modelTop pos1">STT1520</span>
         </div>
         <div style="float: left; margin-left: 5%;position: relative">
@@ -28,8 +28,8 @@
             <img src="@/assets/image/warehouse2.png" style="height:80px" v-if="20<=(dashboarddata.proOne) && (dashboarddata.proOne)<40">
             <img src="@/assets/image/warehouse3.png" style="height:80px" v-if="40<=(dashboarddata.proOne) && (dashboarddata.proOne)<60">
             <img src="@/assets/image/warehouse1.png" style="height:80px" v-if="60<=(dashboarddata.proOne) && (dashboarddata.proOne)<80">
-            <img src="@/assets/image/warehouse1.png" style="height:80px" v-if="80<=(dashboarddata.proOne) ">
-            <div class="ModelFont ModelFont2" style="top: 80px;left: 80px;">{{ dashboarddata.proOne }}</div>
+            <img src="@/assets/image/warehouse1.png" style="height:80px" v-if="80<=(dashboarddata.proOne) && (dashboarddata.proOne)<100">
+            <div class="ModelFont ModelFont2" style="top: 80px;left: 80px;">{{ dashboarddata.proOne }}%</div>
             <span class="modelTop pos2">STT1510</span>
           </div>
           <div style="text-align: center;; margin-top: 0.2rem">
@@ -37,15 +37,15 @@
             <img src="@/assets/image/warehouse2.png" style="height:80px" v-if="20<=(dashboarddata.proThree) && (dashboarddata.proThree)<40">
             <img src="@/assets/image/warehouse3.png" style="height:80px" v-if="40<=(dashboarddata.proThree) && (dashboarddata.proThree)<60">
             <img src="@/assets/image/warehouse1.png" style="height:80px" v-if="60<=(dashboarddata.proThree) && (dashboarddata.proThree)<80">
-            <img src="@/assets/image/warehouse1.png" style="height:80px" v-if="80<=(dashboarddata.proThree) ">
-            <div class="ModelFont ModelFont2"  style="top: 185px;left: 25px;">{{ dashboarddata.proThree }}</div>
+            <img src="@/assets/image/warehouse1.png" style="height:80px" v-if="80<=(dashboarddata.proThree) && (dashboarddata.proThree)<100">
+            <div class="ModelFont ModelFont2"  style="top: 185px;left: 25px;">{{ dashboarddata.proThree }}%</div>
             <span class="modelTop pos3">STT1360</span>
             <img src="@/assets/image/warehouse1.png" style="height:80px; margin-left: 0.2rem" v-if="0<=(dashboarddata.proFour) && (dashboarddata.proFour)<20">
             <img src="@/assets/image/warehouse2.png" style="height:80px; margin-left: 0.2rem" v-if="20<=(dashboarddata.proFour) && (dashboarddata.proFour)<40">
             <img src="@/assets/image/warehouse3.png" style="height:80px; margin-left: 0.2rem" v-if="40<=(dashboarddata.proFour) && (dashboarddata.proFour)<60">
             <img src="@/assets/image/warehouse1.png" style="height:80px; margin-left: 0.2rem" v-if="60<=(dashboarddata.proFour) && (dashboarddata.proFour)<80">
-            <img src="@/assets/image/warehouse1.png" style="height:80px; margin-left: 0.2rem" v-if="80<=(dashboarddata.proFour)">
-            <div class="ModelFont ModelFont2"  style="top: 185px;left: 140px;">{{ dashboarddata.proFour }}</div>
+            <img src="@/assets/image/warehouse1.png" style="height:80px; margin-left: 0.2rem" v-if="80<=(dashboarddata.proFour) && (dashboarddata.proFour)<100">
+            <div class="ModelFont ModelFont2"  style="top: 185px;left: 140px;">{{ dashboarddata.proFour }}%</div>
             <span class="modelTop pos4">STT1410</span>
           </div>
         </div>

+ 9 - 0
ui/src/views/plant/organization/branch.vue

@@ -84,6 +84,7 @@
           <branch :dataArray="item.children" :count="currentCount"></branch>
         </template>
       </li>
+
     </ul>
 </template>
 
@@ -283,4 +284,12 @@ export default {
   ul.level li.odd:nth-last-child(2):after{
     content: none;
   }
+  .org-chart ul li .line {
+    width: 2px;
+    height: 30px;
+    background-color: #ccc;
+    position: absolute;
+    left: -5px;
+    top: 0;
+  }
 </style>