2025-06-16 15:57:53 +08:00
|
|
|
|
<template>
|
|
|
|
|
|
<div class="app-container">
|
2025-06-19 10:40:59 +08:00
|
|
|
|
<h3 style="font-weight: bold;">摄像头设置</h3>
|
2025-06-16 15:57:53 +08:00
|
|
|
|
<div style="width: 100%;margin: 10px auto;border: 1px solid #ccc;padding: 10px;border-radius: 10px;">
|
|
|
|
|
|
<div style="font-weight: bold;border-left: 4px solid #1890FF;padding-left: 4px;">摄像头设置</div>
|
|
|
|
|
|
<div class="item">
|
|
|
|
|
|
<div>
|
|
|
|
|
|
<div>
|
|
|
|
|
|
<span class="item-label">实名抓拍:</span>
|
2025-06-19 10:40:59 +08:00
|
|
|
|
<el-switch @change="changeSwitch"
|
2025-06-16 18:16:22 +08:00
|
|
|
|
v-model="camera_real_name_capture"
|
2025-06-16 15:57:53 +08:00
|
|
|
|
active-value="1" active-text="开启"
|
|
|
|
|
|
inactive-value="2" inactive-text="关闭">
|
|
|
|
|
|
</el-switch>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
<div style="color: #999;font-size: 14px;margin-top: 10px">说明:开启后仅上传摄像头人脸识别成功的员工违规抓拍记录</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
<div class="item">
|
|
|
|
|
|
<div>
|
|
|
|
|
|
<div>
|
|
|
|
|
|
<span class="item-label">人脸识别相似度:</span>
|
|
|
|
|
|
<el-input
|
2025-06-16 18:16:22 +08:00
|
|
|
|
v-model="camera_face_recognition_similarity" style="width: 200px;margin-left: 50px;"
|
2025-06-16 15:57:53 +08:00
|
|
|
|
auto-complete="off" maxlength="9"
|
|
|
|
|
|
placeholder="70"
|
|
|
|
|
|
></el-input>
|
|
|
|
|
|
<span class="item-unit">%</span>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
<div style="color: #999;font-size: 14px;margin-top: 10px">说明:旷世分析盒用于识别人脸的配置参数,违规照片人脸识别分超过本参数且分数最高的将被确定为违规人员,如果违规人员识别率偏高,可将本参数调高来减少误识别</div>
|
|
|
|
|
|
</div>
|
2025-06-19 10:40:59 +08:00
|
|
|
|
<div style="display: flex;padding-left: 40px;">
|
|
|
|
|
|
<el-button type="primary" @click="save41">保存</el-button>
|
|
|
|
|
|
<el-button type="info" @click="reset41">恢复默认</el-button>
|
|
|
|
|
|
</div>
|
2025-06-16 15:57:53 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
<div class="item">
|
|
|
|
|
|
<div>
|
|
|
|
|
|
<div>
|
|
|
|
|
|
<span class="item-label">摄像头抓拍设置:</span>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
<div style="color: #999;font-size: 14px;margin-top: 10px">说明:同一摄像头对同一个人的同一种违规类型的抓拍时间范围和抓拍频率设置。</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
<div class="item" >
|
2025-06-23 10:10:35 +08:00
|
|
|
|
<div style="width: 80%;height: auto;border: 1px solid #e0e0e0;">
|
|
|
|
|
|
<el-table v-loading="loading" :data="tableList">
|
|
|
|
|
|
<el-table-column label="违规类型" align="center" prop="itemDescription" :show-overflow-tooltip="true" />
|
|
|
|
|
|
<el-table-column label="抓拍时间" align="center" :show-overflow-tooltip="true">
|
|
|
|
|
|
<template slot-scope="scope">
|
|
|
|
|
|
<el-time-picker
|
|
|
|
|
|
is-range v-model="scope.row.timeList" style="width: 100%;"
|
2025-06-16 15:57:53 +08:00
|
|
|
|
range-separator="至" format="HH:mm:ss" value-format="HH:mm:ss"
|
|
|
|
|
|
start-placeholder="00:00:00" end-placeholder="23:59:59"
|
2025-06-23 10:10:35 +08:00
|
|
|
|
@change="changeOrderTimeList(scope.row)"
|
2025-06-16 15:57:53 +08:00
|
|
|
|
placeholder="选择时间范围"></el-time-picker>
|
2025-06-23 10:10:35 +08:00
|
|
|
|
</template>
|
|
|
|
|
|
</el-table-column>
|
|
|
|
|
|
<el-table-column label="抓拍频率" align="center" prop="frequency" :show-overflow-tooltip="true">
|
|
|
|
|
|
<template slot-scope="scope">
|
|
|
|
|
|
<el-input v-model="scope.row.frequency" style="width: 60%;" maxlength="9"
|
|
|
|
|
|
auto-complete="off" placeholder="60"></el-input><span class="item-unit">秒</span>
|
|
|
|
|
|
</template>
|
|
|
|
|
|
</el-table-column>
|
|
|
|
|
|
<el-table-column label="操作" align="center" width="300" class-name="small-padding fixed-width">
|
|
|
|
|
|
<template slot-scope="scope">
|
|
|
|
|
|
<el-button
|
|
|
|
|
|
type="primary"
|
|
|
|
|
|
@click="save42(scope.row)"
|
|
|
|
|
|
>保存</el-button>
|
|
|
|
|
|
<el-button
|
|
|
|
|
|
type="info"
|
|
|
|
|
|
@click="reset42(scope.row)"
|
|
|
|
|
|
>恢复默认</el-button>
|
|
|
|
|
|
</template>
|
|
|
|
|
|
</el-table-column>
|
|
|
|
|
|
</el-table>
|
2025-06-19 10:40:59 +08:00
|
|
|
|
</div>
|
2025-06-23 10:10:35 +08:00
|
|
|
|
<!-- <div style="width: 30%;display: flex;padding-left: 40px;align-self: self-end;">
|
|
|
|
|
|
<el-button type="primary" @click="save42">保存</el-button>
|
|
|
|
|
|
<el-button type="info" @click="reset42">恢复默认</el-button>
|
|
|
|
|
|
</div> -->
|
2025-06-16 15:57:53 +08:00
|
|
|
|
</div>
|
2025-06-19 10:40:59 +08:00
|
|
|
|
|
2025-06-16 15:57:53 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
|
|
<script>
|
2025-06-23 10:10:35 +08:00
|
|
|
|
import { getSettingListApi,batchEditSettingApi,batchResetSettingApi,getCameraSettingListApi,batchEditCameraSettingApi,batchResetCameraSettingApi } from "@/api/kitchen/setting.js";
|
2025-06-16 15:57:53 +08:00
|
|
|
|
export default {
|
|
|
|
|
|
name: "",
|
|
|
|
|
|
dicts: [],
|
|
|
|
|
|
data() {
|
2025-06-16 18:16:22 +08:00
|
|
|
|
return {
|
|
|
|
|
|
//摄像头设置
|
|
|
|
|
|
camera_real_name_capture:1,
|
|
|
|
|
|
camera_face_recognition_similarity:null,
|
2025-06-23 10:10:35 +08:00
|
|
|
|
loading:false,
|
|
|
|
|
|
tableList:[],
|
2025-06-16 18:16:22 +08:00
|
|
|
|
timeList1:[],
|
|
|
|
|
|
camera_capture_without_hat_frequency:null,
|
|
|
|
|
|
timeList2:[],
|
|
|
|
|
|
camera_capture_without_mask_frequency:null,
|
|
|
|
|
|
timeList3:[],
|
|
|
|
|
|
camera_capture_without_uniform_frequency:null,
|
|
|
|
|
|
timeList4:[],
|
|
|
|
|
|
camera_capture_without_glove_frequency:null,
|
|
|
|
|
|
timeList5:[],
|
|
|
|
|
|
camera_capture_smoking_frequency:null,
|
|
|
|
|
|
timeList6:[],
|
|
|
|
|
|
camera_capture_calling_frequency:null,
|
|
|
|
|
|
timeList7:[],
|
|
|
|
|
|
camera_capture_trash_no_cover_frequency:null,
|
|
|
|
|
|
timeList8:[],
|
|
|
|
|
|
camera_capture_found_mouse_frequency:null,
|
|
|
|
|
|
timeList9:[],
|
|
|
|
|
|
camera_capture_fire_without_staff_frequency:null,
|
|
|
|
|
|
timeList10:[],
|
|
|
|
|
|
camera_capture_unauthorized_entry_frequency:null,
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-06-16 15:57:53 +08:00
|
|
|
|
};
|
|
|
|
|
|
},
|
|
|
|
|
|
created() {
|
2025-06-19 10:40:59 +08:00
|
|
|
|
|
2025-06-16 18:16:22 +08:00
|
|
|
|
},
|
|
|
|
|
|
mounted(){
|
2025-06-23 10:10:35 +08:00
|
|
|
|
this.query41()
|
|
|
|
|
|
this.query42()
|
2025-06-16 15:57:53 +08:00
|
|
|
|
},
|
2025-06-23 10:10:35 +08:00
|
|
|
|
methods: {
|
2025-06-19 10:40:59 +08:00
|
|
|
|
changeSwitch(e){
|
|
|
|
|
|
console.log(e)
|
2025-06-16 18:16:22 +08:00
|
|
|
|
let param = [
|
2025-06-19 10:40:59 +08:00
|
|
|
|
{"itemName": "camera_real_name_capture","itemValue":this.camera_real_name_capture}
|
2025-06-16 18:16:22 +08:00
|
|
|
|
]
|
|
|
|
|
|
batchEditSettingApi(param).then(response => {
|
2025-06-19 10:40:59 +08:00
|
|
|
|
this.$message.success("修改成功");
|
2025-06-23 10:10:35 +08:00
|
|
|
|
this.query41()
|
2025-06-16 18:16:22 +08:00
|
|
|
|
});
|
|
|
|
|
|
},
|
2025-06-23 10:10:35 +08:00
|
|
|
|
query41(){
|
|
|
|
|
|
getSettingListApi({"itemName": "camera_real_name_capture"}).then(response => {
|
|
|
|
|
|
this.camera_real_name_capture = response.rows[0].itemValue
|
|
|
|
|
|
});
|
|
|
|
|
|
getSettingListApi({"itemName": "camera_face_recognition_similarity"}).then(response => {
|
|
|
|
|
|
this.camera_face_recognition_similarity = response.rows[0].itemValue
|
|
|
|
|
|
});
|
|
|
|
|
|
},
|
2025-06-19 10:40:59 +08:00
|
|
|
|
save41(){
|
2025-06-16 18:16:22 +08:00
|
|
|
|
let param = [
|
2025-06-19 10:40:59 +08:00
|
|
|
|
{"itemName": "camera_face_recognition_similarity","itemValue":this.camera_face_recognition_similarity}
|
2025-06-16 18:16:22 +08:00
|
|
|
|
]
|
|
|
|
|
|
batchEditSettingApi(param).then(response => {
|
|
|
|
|
|
this.$message.success("保存成功");
|
2025-06-23 10:10:35 +08:00
|
|
|
|
this.query41()
|
2025-06-16 18:16:22 +08:00
|
|
|
|
});
|
|
|
|
|
|
},
|
2025-06-19 10:40:59 +08:00
|
|
|
|
reset41(){
|
2025-06-16 18:16:22 +08:00
|
|
|
|
let param = [
|
2025-06-19 10:40:59 +08:00
|
|
|
|
{"itemName": "camera_face_recognition_similarity"}
|
2025-06-16 18:16:22 +08:00
|
|
|
|
]
|
|
|
|
|
|
batchResetSettingApi(param).then(response => {
|
|
|
|
|
|
this.$message.success("恢复成功");
|
2025-06-23 10:10:35 +08:00
|
|
|
|
this.query41()
|
2025-06-16 18:16:22 +08:00
|
|
|
|
});
|
|
|
|
|
|
},
|
2025-06-23 10:10:35 +08:00
|
|
|
|
query42(){
|
|
|
|
|
|
this.loading=true;
|
|
|
|
|
|
getCameraSettingListApi().then(response => {
|
|
|
|
|
|
this.tableList = response.rows;
|
|
|
|
|
|
this.tableList.forEach(item=>{
|
|
|
|
|
|
this.$set(item,"timeList",[item.startTime,item.endTime])
|
|
|
|
|
|
})
|
|
|
|
|
|
this.loading=false
|
2025-06-16 18:16:22 +08:00
|
|
|
|
});
|
|
|
|
|
|
},
|
2025-06-23 10:10:35 +08:00
|
|
|
|
changeOrderTimeList(row){
|
|
|
|
|
|
console.log(row)
|
|
|
|
|
|
row.startTime = row.timeList[0]
|
|
|
|
|
|
row.endTime = row.timeList[1]
|
|
|
|
|
|
},
|
|
|
|
|
|
save42(row){
|
|
|
|
|
|
let param = [row]
|
|
|
|
|
|
batchEditCameraSettingApi(param).then(response => {
|
2025-06-16 18:16:22 +08:00
|
|
|
|
this.$message.success("保存成功");
|
2025-06-23 10:10:35 +08:00
|
|
|
|
this.query42()
|
2025-06-16 18:16:22 +08:00
|
|
|
|
});
|
|
|
|
|
|
},
|
2025-06-23 10:10:35 +08:00
|
|
|
|
reset42(row){
|
|
|
|
|
|
let param = [{"itemName":row.itemName}]
|
|
|
|
|
|
batchResetCameraSettingApi(param).then(response => {
|
2025-06-16 18:16:22 +08:00
|
|
|
|
this.$message.success("恢复成功");
|
2025-06-23 10:10:35 +08:00
|
|
|
|
this.query42()
|
2025-06-16 18:16:22 +08:00
|
|
|
|
});
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-06-16 15:57:53 +08:00
|
|
|
|
}
|
|
|
|
|
|
};
|
|
|
|
|
|
</script>
|
|
|
|
|
|
<style scoped>
|
|
|
|
|
|
.item{
|
2025-06-19 10:40:59 +08:00
|
|
|
|
width: 96%;margin: 10px auto;padding: 20px 10px;border-radius: 8px;display: flex;align-items: center;
|
2025-06-16 15:57:53 +08:00
|
|
|
|
}
|
|
|
|
|
|
.item-label{
|
|
|
|
|
|
display: inline-block;
|
|
|
|
|
|
width: 240px;
|
|
|
|
|
|
}
|
|
|
|
|
|
.item-unit{
|
|
|
|
|
|
margin-left: 10px;
|
|
|
|
|
|
}
|
|
|
|
|
|
.item-th{
|
|
|
|
|
|
width: 100%;height: 60px;display: flex;line-height: 60px;
|
|
|
|
|
|
}
|
|
|
|
|
|
</style>
|
|
|
|
|
|
|