Commit f4a16cce authored by dlkong's avatar dlkong
Browse files

四色图增加评分判断

parent 5b3ed6c5
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -62,6 +62,8 @@ export default {
        "riskExecution",
        "riskAssess",
        "riskApprove",
        "taskList",
        "taskDetail"

      ],
      // cachePage预先定义的缓存页面
+14 −1
Original line number Diff line number Diff line
@@ -218,6 +218,20 @@ export default {
                   if (!this.isViews || item.position.type == 'thorough') { //添加页面不显示颜色
                        item.position.c = '#e6e5e5'
                    }else{
                         /** 
                         *  根据风险评分来匹配相应的颜色
                         *  score 风险评分字段
                         */
                        // item.score = Number(item.score)
                        // if (item.score>=21 && item.score <= 27) { //优
                        //     item.position.c = this.colorList[3]
                        // }else if(item.score>=14 && item.score <=20){ //良
                        //     item.position.c = this.colorList[2]
                        // }else if (item.score>=7&& item.score <= 13) { //中
                        //     item.position.c = this.colorList[1]
                        // }else if (item.score>=0 && item.score <= 6) { //差
                        //     item.position.c = this.colorList[0]
                        // }
                        item.position.c = this.colorList[Math.floor(Math.random()*4)]
                    }
                   this.layout.push(item.position)
@@ -440,7 +454,6 @@ export default {
.vue-grid-layout {
    background: #f0f1f5;
}

.vue-grid-item:not(.vue-grid-placeholder) {
    background: #ccc;
    border: 1px solid black;