Parcourir la Source

[FE]AI报警角标调整

liuwenxun 4 ans auparavant
Parent
commit
6b8b5abe55

+ 3 - 3
security-protection-platform/src/layout/components/Sidebar/SidebarItem.vue

89
      const icon = onlyOneChild.meta && onlyOneChild.meta.icon ? <t-icon icon={onlyOneChild.meta.icon} /> : ''
89
      const icon = onlyOneChild.meta && onlyOneChild.meta.icon ? <t-icon icon={onlyOneChild.meta.icon} /> : ''
90
90
91
      if (item.path === '/alarm') {
91
      if (item.path === '/alarm') {
92
        var confirmedCount = 0
92
        // var confirmedCount = 0
93
        var unconfirmedCount = 0
93
        var unconfirmedCount = 0
94
        if (AiAlarmCount.length > 0) {
94
        if (AiAlarmCount.length > 0) {
95
          confirmedCount = AiAlarmCount[1].value
95
          // confirmedCount = AiAlarmCount[1].value
96
          unconfirmedCount = AiAlarmCount[0].value
96
          unconfirmedCount = AiAlarmCount[0].value
97
        }
97
        }
98
98
103
103
104
            <div class="badge-group">
104
            <div class="badge-group">
105
              <t-badge color="danger" count={unconfirmedCount} max={99} ></t-badge>
105
              <t-badge color="danger" count={unconfirmedCount} max={99} ></t-badge>
106
              <t-badge color="danger" count={confirmedCount} max={99} ></t-badge>
106
107
            </div>
107
            </div>
108
108
109
          </t-menu-item>
109
          </t-menu-item>

+ 1 - 0
security-protection-platform/src/layout/components/Sidebar/index.vue

78
      let res = await aialarmapi.getAiAlarmCount()
78
      let res = await aialarmapi.getAiAlarmCount()
79
79
80
      this.AiAlarmCount = res.data.data
80
      this.AiAlarmCount = res.data.data
81
      console.log('数据是', this.AiAlarmCount)
81
    }
82
    }
82
  }
83
  }
83
}
84
}

+ 9 - 0
security-protection-platform/src/modules/access/index.vue

105
              <div>
105
              <div>
106
                <!-- 修改-->
106
                <!-- 修改-->
107
                <img src="@/assets/images/Identify_the_successful.png" alt="" srcset="">
107
                <img src="@/assets/images/Identify_the_successful.png" alt="" srcset="">
108

108
              </div>
109
              </div>
109
              <div>
110
              <div>
110
                <img :src="rowdata.alarmInfo.headerImage" alt="" srcset="" style="width:100%;height:160px; border-radius: 5px;">
111
                <img :src="rowdata.alarmInfo.headerImage" alt="" srcset="" style="width:100%;height:160px; border-radius: 5px;">
225

226

226
      if (res.data.success) {
227
      if (res.data.success) {
227
        // this.rowdata = res.data.data
228
        // this.rowdata = res.data.data
229

228
        this.rowdata.pictureInfo = res.data.data.pictureInfo
230
        this.rowdata.pictureInfo = res.data.data.pictureInfo
229
        console.log('数据', this.rowdata.pictureInfo)
231
        console.log('数据', this.rowdata.pictureInfo)
230
        this.rowdata.alarmInfo = res.data.data.alarmInfo
232
        this.rowdata.alarmInfo = res.data.data.alarmInfo
231
        console.log('数据', this.rowdata.alarmInfo)
233
        console.log('数据', this.rowdata.alarmInfo)
234
        console.log('相似度数据', this.rowdata.alarmInfo.simi, typeof this.rowdata.alarmInfo.simi)
232
        // this.rowdata.alarmInfo.newImg = this.rowdata.pictureInfo.fileUrl
235
        // this.rowdata.alarmInfo.newImg = this.rowdata.pictureInfo.fileUrl
233

236

234
        this.getImage()
237
        this.getImage()
447
        that.mainimage = base64
450
        that.mainimage = base64
448
      })
451
      })
449
    }
452
    }
453
    // //将分数转换为小数
454
    // toPoint (percent) {
455
    //   var str = percent.replace('%', '')
456
    //   str = str / 100
457
    //   return str
458
    // }
450

459

451
  }
460
  }
452
}
461
}

+ 7 - 2
security-protection-platform/src/modules/aialarm/index.vue

75
        <template slot-scope="scope">
75
        <template slot-scope="scope">
76

76

77
          <a href="javascript:void(0)" size="sm" style="color:#0089D4" @click="handleClick(scope,0)">详情</a>
77
          <a href="javascript:void(0)" size="sm" style="color:#0089D4" @click="handleClick(scope,0)">详情</a>
78
          <a v-if="scope.row.status=='RUN'||scope.row.status=='FAL'" style="color:#0089D4" @click="handleClick(scope,1)">关闭</a>
79
          <a v-if="scope.row.status=='INI'" style="color:#0089D4" @click="handleClick(scope,1)">处理</a>
78
          <div class="caozuo">
79
            <a v-if="scope.row.status=='RUN'||scope.row.status=='FAL'" style="color:#0089D4" @click="handleClick(scope,1)">关闭</a>
80
            <a v-if="scope.row.status=='INI'" style="color:#0089D4" @click="handleClick(scope,1)">处理</a>
81
          </div>
80
        </template>
82
        </template>
81
      </t-table-column>
83
      </t-table-column>
82
    </t-table>
84
    </t-table>
441
    font-size: 14px;
443
    font-size: 14px;
442
    line-height: 22px;
444
    line-height: 22px;
443
  }
445
  }
446
  .caozuo {
447
    display: inline;
448
  }
444
  .table th,
449
  .table th,
445
  .table td {
450
  .table td {
446
    padding: 0 0 0 21px;
451
    padding: 0 0 0 21px;