Merge branch 'bjxz-dev' of http://139.9.66.234:18023/dhp/zhgdyun into bjxz-dev
This commit is contained in:
commit
f443e75d50
@ -585,8 +585,10 @@
|
||||
<el-upload
|
||||
:action="$store.state.UPLOADURL"
|
||||
list-type="picture-card"
|
||||
:class="{'none_add':fileList.length >= 2}"
|
||||
multiple
|
||||
name="files"
|
||||
limit="2"
|
||||
:file-list="fileList"
|
||||
:on-success="handleSuccess"
|
||||
:on-remove="handleRemove"
|
||||
@ -1121,6 +1123,7 @@
|
||||
<span class="label">驾驶证:</span>
|
||||
<span
|
||||
class="value"
|
||||
style="margin-left: 5px"
|
||||
v-if="
|
||||
entityDetail.jsz &&
|
||||
JSON.parse(entityDetail.jsz).length > 0
|
||||
@ -1134,7 +1137,7 @@
|
||||
alt=""
|
||||
width="50px"
|
||||
height="50px"
|
||||
style="margin-right: 10px"
|
||||
:style="`margin-left: 5px;${index > 2 ? 'margin-top: 5px;':''}`"
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
@ -1146,6 +1149,7 @@
|
||||
<span class="label">行驶证:</span>
|
||||
<span
|
||||
class="value"
|
||||
style="margin-left: 5px"
|
||||
v-if="
|
||||
entityDetail.xsz &&
|
||||
JSON.parse(entityDetail.xsz).length > 0
|
||||
@ -1159,7 +1163,7 @@
|
||||
alt=""
|
||||
width="50px"
|
||||
height="50px"
|
||||
style="margin-right: 10px"
|
||||
:style="`margin-left: 5px;${index > 2 ? 'margin-top: 5px;':''}`"
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
@ -1169,6 +1173,7 @@
|
||||
<span class="label">交强险:</span>
|
||||
<span
|
||||
class="value"
|
||||
style="margin-left: 5px"
|
||||
v-if="
|
||||
entityDetail.jqx &&
|
||||
JSON.parse(entityDetail.jqx).length > 0
|
||||
@ -1182,7 +1187,7 @@
|
||||
alt=""
|
||||
width="50px"
|
||||
height="50px"
|
||||
style="margin-right: 10px"
|
||||
:style="`margin-left: 5px;${index > 2 ? 'margin-top: 5px;':''}`"
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
@ -1194,6 +1199,7 @@
|
||||
<span class="label">其他证明:</span>
|
||||
<span
|
||||
class="value"
|
||||
style="margin-left: 5px"
|
||||
v-if="
|
||||
entityDetail.otherProve &&
|
||||
JSON.parse(entityDetail.otherProve).length > 0
|
||||
@ -1209,7 +1215,7 @@
|
||||
alt=""
|
||||
width="50px"
|
||||
height="50px"
|
||||
style="margin-right: 10px"
|
||||
:style="`margin-left: 5px;${index > 2 ? 'margin-top: 5px;':''}`"
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
@ -2161,6 +2167,9 @@ export default {
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.none_add :deep(.el-upload--picture-card){
|
||||
display:none;
|
||||
}
|
||||
.carQrCode {
|
||||
position: absolute;
|
||||
top: 40px;
|
||||
@ -2180,7 +2189,7 @@ export default {
|
||||
}
|
||||
.value {
|
||||
float: left;
|
||||
width: calc(80% - 150px);
|
||||
width: calc(80% - 145px);
|
||||
margin-left: 10px;
|
||||
// text-overflow: ellipsis;
|
||||
// overflow: hidden;
|
||||
|
||||
@ -9,7 +9,9 @@
|
||||
人员手动校验
|
||||
</el-button>
|
||||
<!-- 车辆手动校验 -->
|
||||
<el-button @click="onStaffIsCarManualCheck(2)" type="primary"> 车辆手动校验 </el-button>
|
||||
<el-button @click="onStaffIsCarManualCheck(2)" type="primary">
|
||||
车辆手动校验
|
||||
</el-button>
|
||||
<!-- 批量同步 -->
|
||||
<el-button @click="onBatchSynchronization()" type="primary">
|
||||
批量同步
|
||||
@ -42,7 +44,8 @@
|
||||
<el-tab-pane label="车辆信息" name="4"></el-tab-pane>
|
||||
</el-tabs>
|
||||
<el-table class="tables" :data="tableList" @selection-change="handleSelectionChange">
|
||||
<el-table-column align="center" type="selection" width="55"> </el-table-column>
|
||||
<el-table-column align="center" type="selection" width="55">
|
||||
</el-table-column>
|
||||
<el-table-column show-overflow-tooltip v-if="activeName == '1'" align="center" prop="orgName"
|
||||
label="组织名称"></el-table-column>
|
||||
<el-table-column show-overflow-tooltip v-else-if="activeName == '2' || activeName == '3'" align="center"
|
||||
@ -53,20 +56,26 @@
|
||||
label="身份证号"></el-table-column>
|
||||
<el-table-column align="center" label="ISC校验结果">
|
||||
<template slot-scope="scope">
|
||||
<div :class="scope.row.existIsc == 1 ? 'refreshbtn' : 'unrefreshbtn'">{{ scope.row.existIsc == 1 ? '存在' : '不存在' }}</div>
|
||||
<div :class="scope.row.existIsc == 1 ? 'refreshbtn' : 'unrefreshbtn'">
|
||||
{{ scope.row.existIsc == 1 ? "存在" : "不存在" }}
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="平台校验结果">
|
||||
<template slot-scope="scope">
|
||||
<div :class="scope.row.existMyPlatform == 1 ? 'refreshbtn' : 'unrefreshbtn'" >{{ scope.row.existMyPlatform == 1 ? '存在' : '不存在' }}</div>
|
||||
<div :class="
|
||||
scope.row.existMyPlatform == 1 ? 'refreshbtn' : 'unrefreshbtn'
|
||||
">
|
||||
{{ scope.row.existMyPlatform == 1 ? "存在" : "不存在" }}
|
||||
</div>
|
||||
<!-- scope.row -->
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="同步结果">
|
||||
<template slot-scope="scope">
|
||||
<el-button class="synchronization" disabled
|
||||
:type="scope.row.syncResult == 1 ? 'info' : 'danger'">{{ scope.row.syncResult == 1 ? '未同步' :
|
||||
'同步失败' }}</el-button>
|
||||
<el-button class="synchronization" disabled :type="scope.row.syncResult == 1 ? 'info' : 'danger'">{{
|
||||
scope.row.syncResult == 1 ? "未同步" : "同步失败"
|
||||
}}</el-button>
|
||||
<!-- <el-button class="synchronization" disabled type="danger">同步失败</el-button>
|
||||
<el-button class="synchronization" disabled type="success">同步成功</el-button> -->
|
||||
</template>
|
||||
@ -74,8 +83,11 @@
|
||||
<el-table-column align="center" label="操作">
|
||||
<template slot-scope="scope">
|
||||
<!-- unrefreshbtn -->
|
||||
<div @click="onHikvisionSync(scope.row.id)" :class="scope.row.syncResult == 1 ? 'refreshbtn' : 'unrefreshbtn'" class="accessory"><i class="el-icon-refresh"></i> {{ scope.row.syncResult == 1 ? '同步' :
|
||||
'重试' }}</div>
|
||||
<div @click="onHikvisionSync(scope.row.id)"
|
||||
:class="scope.row.syncResult == 1 ? 'refreshbtn' : 'unrefreshbtn'" class="accessory">
|
||||
<i class="el-icon-refresh"></i>
|
||||
{{ scope.row.syncResult == 1 ? "同步" : "重试" }}
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
@ -92,6 +104,15 @@ import {
|
||||
getHikvisionSyncApi,
|
||||
getHikvisionManualCompareApi,
|
||||
} from "@/assets/js/api/laborPerson";
|
||||
import mqtt from "mqtt";
|
||||
var client = null;
|
||||
const options = {
|
||||
connectTimeout: 40000,
|
||||
clientId: "mqttjs_" + Math.random().toString(16).substr(2, 8),
|
||||
username: "root",
|
||||
password: "123456",
|
||||
clean: true,
|
||||
};
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
@ -105,6 +126,8 @@ export default {
|
||||
},
|
||||
tableList: [],
|
||||
multipleSelection: [],
|
||||
topicName: "topic",
|
||||
userId: "",
|
||||
};
|
||||
},
|
||||
created() {
|
||||
@ -128,49 +151,81 @@ export default {
|
||||
// carNumber: "G-320"
|
||||
// },
|
||||
// ];
|
||||
|
||||
},
|
||||
mounted() {
|
||||
this.userId = this.$store.state.userInfo.userId;
|
||||
this.topicName = this.$store.state.userInfo.scope;
|
||||
client = mqtt.connect(mqttUrl, options);
|
||||
this.mqttMSG();
|
||||
},
|
||||
methods: {
|
||||
// 监听mqtt下发信息然后刷新列表
|
||||
mqttMSG() {
|
||||
// mqtt连接 +"/#" +workerId
|
||||
client.on("connect", (e) => {
|
||||
// console.log('连接成功:', this.topicName + this.userId)
|
||||
client.subscribe(this.topicName + this.userId, { qos: 0 }, (error) => {
|
||||
if (!error) {
|
||||
// console.log('订阅成功123')
|
||||
} else {
|
||||
console.log("订阅失败");
|
||||
}
|
||||
});
|
||||
});
|
||||
// 接收消息处理
|
||||
client.on("message", (topic, message) => {
|
||||
// console.log(message);
|
||||
this.getHikvisionPage();
|
||||
});
|
||||
// 断开发起重连
|
||||
// client.on("reconnect", (error) => {
|
||||
// console.log("正在重连:", error);
|
||||
// });
|
||||
// 链接异常处理
|
||||
client.on("error", (error) => {
|
||||
console.log("连接失败:", error);
|
||||
});
|
||||
},
|
||||
// 批量同步 || 同步
|
||||
onBatchSynchronization() {
|
||||
if (this.multipleSelection.length == 0) {
|
||||
this.$message.warning("请选择需要同步的数据!");
|
||||
return
|
||||
return;
|
||||
}
|
||||
|
||||
console.log(this.multipleSelection);
|
||||
const ids = this.multipleSelection.map(item => item.id).join(',');
|
||||
onHikvisionSync(ids);
|
||||
const ids = this.multipleSelection.map((item) => item.id).join(",");
|
||||
this.onHikvisionSync(ids);
|
||||
},
|
||||
onHikvisionSync(ids){
|
||||
onHikvisionSync(ids) {
|
||||
getHikvisionSyncApi({
|
||||
projectSn: this.projectSn,
|
||||
ids,
|
||||
}).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.$message.success(res.message);
|
||||
this.getHikvisionPage();
|
||||
}else {
|
||||
} else {
|
||||
this.$message.error(res.result.msg);
|
||||
}
|
||||
})
|
||||
});
|
||||
},
|
||||
// 选中状态
|
||||
handleSelectionChange(val) {
|
||||
this.multipleSelection = val;
|
||||
},
|
||||
// 人员|车辆手动校验
|
||||
onStaffIsCarManualCheck(type) {
|
||||
onStaffIsCarManualCheck(type) {
|
||||
getHikvisionManualCompareApi({
|
||||
projectSn: this.projectSn,
|
||||
type: type,
|
||||
}).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.$message.success(res.message);
|
||||
}else {
|
||||
// this.getHikvisionPage();
|
||||
} else {
|
||||
this.$message.error(res.message);
|
||||
}
|
||||
})
|
||||
});
|
||||
},
|
||||
// 校验是否弹窗
|
||||
getHikvisionException() {
|
||||
@ -181,10 +236,10 @@ export default {
|
||||
console.log(res);
|
||||
if (res.code == 200) {
|
||||
this.getHikvisionPage();
|
||||
}else {
|
||||
} else {
|
||||
this.$message.error(res.result.msg);
|
||||
}
|
||||
})
|
||||
});
|
||||
},
|
||||
//获取信息
|
||||
getHikvisionPage() {
|
||||
@ -196,9 +251,9 @@ export default {
|
||||
}).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.tableList = res.result.records;
|
||||
this.pagInfo.total = res.result.total
|
||||
this.pagInfo.total = res.result.total;
|
||||
}
|
||||
})
|
||||
});
|
||||
},
|
||||
|
||||
//切换Tab记录类型
|
||||
@ -206,7 +261,7 @@ export default {
|
||||
// console.log(val.name);
|
||||
this.activeName = val.name;
|
||||
this.initClear();
|
||||
this.getHikvisionException();
|
||||
this.getHikvisionPage();
|
||||
},
|
||||
// 初始化
|
||||
initClear() {
|
||||
|
||||
@ -73,14 +73,14 @@
|
||||
align="center"
|
||||
:label="$t('message.personnelPosition.beaconManage.table.index')"
|
||||
></el-table-column>
|
||||
<el-table-column prop="type" label="安全履职规则类型" align="center">
|
||||
<el-table-column prop="type" label="规则类型名称" align="center">
|
||||
<!-- <template slot-scope="scope">
|
||||
<span>{{ scope.row.type | typeText(rulesTypeList) }}</span>
|
||||
</template> -->
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="dayNum"
|
||||
label="连续未履职天数"
|
||||
label="数值"
|
||||
align="center"
|
||||
></el-table-column>
|
||||
<el-table-column
|
||||
@ -211,6 +211,18 @@ export default {
|
||||
{ name: "一个月内缺勤超过", value: 3 },
|
||||
{ name: "一个月内迟到超过", value: 4 },
|
||||
{ name: "同一企业同一隐患连续检查到(x)次", value: 5 },
|
||||
{ name: "一级安全隐患未整改超过(x)分钟", value: 6 },
|
||||
{ name: "一级安全隐患未复查超过(x)分钟", value: 7 },
|
||||
{ name: "一级安全隐患未核验超过(x)分钟", value: 8 },
|
||||
{ name: "二级安全隐患未整改超过(x)分钟", value: 9 },
|
||||
{ name: "二级安全隐患未复查超过(x)分钟", value: 10 },
|
||||
{ name: "二级安全隐患未核验超过(x)分钟", value: 11 },
|
||||
{ name: "三级安全隐患未整改超过(x)分钟", value: 12 },
|
||||
{ name: "三级安全隐患未复查超过(x)分钟", value: 13 },
|
||||
{ name: "三级安全隐患未核验超过(x)分钟", value: 14 },
|
||||
{ name: "四级安全隐患未整改超过(x)分钟", value: 15 },
|
||||
{ name: "四级安全隐患未复查超过(x)分钟", value: 16 },
|
||||
{ name: "四级安全隐患未核验超过(x)分钟", value: 17 },
|
||||
],
|
||||
timeRange: [],
|
||||
searchForm: {
|
||||
|
||||
@ -298,6 +298,18 @@ export default {
|
||||
{ name: "一个月内缺勤超过", value: 3 },
|
||||
{ name: "一个月内迟到超过", value: 4 },
|
||||
{ name: "同一企业同一隐患连续检查到(x)次", value: 5 },
|
||||
{ name: "一级安全隐患未整改超过(x)分钟", value: 6 },
|
||||
{ name: "一级安全隐患未复查超过(x)分钟", value: 7 },
|
||||
{ name: "一级安全隐患未核验超过(x)分钟", value: 8 },
|
||||
{ name: "二级安全隐患未整改超过(x)分钟", value: 9 },
|
||||
{ name: "二级安全隐患未复查超过(x)分钟", value: 10 },
|
||||
{ name: "二级安全隐患未核验超过(x)分钟", value: 11 },
|
||||
{ name: "三级安全隐患未整改超过(x)分钟", value: 12 },
|
||||
{ name: "三级安全隐患未复查超过(x)分钟", value: 13 },
|
||||
{ name: "三级安全隐患未核验超过(x)分钟", value: 14 },
|
||||
{ name: "四级安全隐患未整改超过(x)分钟", value: 15 },
|
||||
{ name: "四级安全隐患未复查超过(x)分钟", value: 16 },
|
||||
{ name: "四级安全隐患未核验超过(x)分钟", value: 17 },
|
||||
],
|
||||
pageInfo: {
|
||||
total: 0,
|
||||
|
||||
@ -182,7 +182,7 @@
|
||||
}}</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div class="tab_btn_wrap" v-if="tableData.length > 0">
|
||||
<!-- <div class="tab_btn_wrap" v-if="tableData.length > 0">
|
||||
<el-button
|
||||
v-permission="{key: 'criterions_stop_open', menuPath: '/project/quality/criterion'}"
|
||||
type="primary"
|
||||
@ -203,7 +203,7 @@
|
||||
$t('message.quality.batch') + $t('message.quality.forbidden')
|
||||
}}</el-button
|
||||
>
|
||||
</div>
|
||||
</div> -->
|
||||
</div>
|
||||
</div>
|
||||
</vue-scroll>
|
||||
|
||||
@ -192,7 +192,7 @@
|
||||
</el-table-column>
|
||||
|
||||
</el-table>
|
||||
<div class="tab_btn_wrap" v-if="tableData.length > 0">
|
||||
<!-- <div class="tab_btn_wrap" v-if="tableData.length > 0">
|
||||
<el-button
|
||||
v-permission="{key: 'criterions_stop_open', menuPath: '/project/safeSame/criterion'}"
|
||||
type="primary"
|
||||
@ -213,7 +213,7 @@
|
||||
$t('message.quality.batch') + $t('message.quality.forbidden')
|
||||
}}</el-button
|
||||
>
|
||||
</div>
|
||||
</div> -->
|
||||
</div>
|
||||
</div>
|
||||
</vue-scroll>
|
||||
|
||||
@ -326,7 +326,7 @@
|
||||
{{ workDetail.assignmentPersonInChargeName }}
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="受限空间内原有介质名称" :label-width="formLabelWidthDetail">
|
||||
<el-form-item label="受限空间内原有介质名称:" :label-width="formLabelWidthDetail">
|
||||
{{ workDetail.limitSpaceMediumName }}
|
||||
</el-form-item>
|
||||
<el-form-item label="受限空间名称:" :label-width="formLabelWidthDetail">
|
||||
@ -345,10 +345,10 @@
|
||||
</el-date-picker>
|
||||
</el-form-item> -->
|
||||
<el-form-item label="可燃气体信息:" :label-width="formLabelWidthDetail">
|
||||
{{ workDetail.combustibleGasInformation && JSON.parse(workDetail.combustibleGasInformation).map(item => `${item.name?item.name:''}(${item.standard ? item.standard : ''})`).join('、') }}
|
||||
{{ workDetail.combustibleGasInformation && JSON.parse(workDetail.combustibleGasInformation).map(item => `${item.name && item.name != undefined ? item.name : ''}(${item.standard && item.standard != undefined ? item.standard : ''})`).join('、') }}
|
||||
</el-form-item>
|
||||
<el-form-item label="有毒有害气体:" :label-width="formLabelWidthDetail">
|
||||
{{ workDetail.toxicAndHarmfulGasInformation && JSON.parse(workDetail.toxicAndHarmfulGasInformation).map(item => `${item.name?item.name:''}(${item.standard ? item.standard : ''})`).join('、') }}
|
||||
{{ workDetail.toxicAndHarmfulGasInformation && JSON.parse(workDetail.toxicAndHarmfulGasInformation).map(item => `${item.name && item.name != undefined ?item.name:''}(${item.standard && item.standard != undefined ? item.standard : ''})`).join('、') }}
|
||||
</el-form-item>
|
||||
<el-form-item label="监护人:" :label-width="formLabelWidthDetail">
|
||||
{{ workDetail.guardianName }}
|
||||
@ -360,9 +360,6 @@
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="风险辨识结果:" :label-width="formLabelWidthDetail">
|
||||
{{ workDetail.riskIdentificationResult }}
|
||||
</el-form-item>
|
||||
<el-form-item label="关联的其他特殊作业及安全作业票编码:" :label-width="formLabelWidthDetail">
|
||||
{{ workDetail.otherRelatedSpecialTask }}
|
||||
</el-form-item>
|
||||
@ -396,6 +393,9 @@
|
||||
</el-image>
|
||||
</div>
|
||||
</el-form-item>
|
||||
<el-form-item label="风险辨识结果:" :label-width="formLabelWidthDetail">
|
||||
{{ workDetail.riskIdentificationResult }}
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label="安全作业票编码:" :label-width="formLabelWidthDetail">
|
||||
{{ workDetail.safetyWorkTicketCode }}
|
||||
</el-form-item> -->
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user