diff --git a/src/components/negative/verify.vue b/src/components/negative/verify.vue index b71a81a..cd38d7e 100644 --- a/src/components/negative/verify.vue +++ b/src/components/negative/verify.vue @@ -597,7 +597,7 @@
- + @@ -1303,7 +1303,7 @@ function getFormData() { } } -function handleAddPersomal() { +function handleAddPersonal() { form.value.blames.push({ type: BlameType.PERSONAL, problems: [{}], @@ -1344,13 +1344,14 @@ function handleChangeLead(val, blame) { watch( () => form.value.accountabilityTarget, (val) => { - if ( - val === AccountabilityTarget.PERSONAL && - !form.value.blames.filter( - (item) => item.type === BlameType.PERSONAL - ).length - ) { - handleAddPersomal(); + if (val === AccountabilityTarget.PERSONAL) { + if ( + form.value.blames.filter( + (item) => item.type === BlameType.PERSONAL + ).length === 0 + ) { + handleAddPersonal(); + } form.value.blames.forEach((item) => { if (item.type === BlameType.DEPARTMENT) { handleRemovePersonal(item); @@ -1363,10 +1364,9 @@ watch( handleRemovePersonal(item); } }); - if ( - !form.value.blames.filter( + if (form.value.blames.filter( (item) => item.type === BlameType.DEPARTMENT - ).length + ).length === 0 ) { form.value.blames.push({ type: BlameType.DEPARTMENT, @@ -1376,17 +1376,15 @@ watch( form.value.blameLeaders = []; } if (val === AccountabilityTarget.PERSONAL_AND_DEPARTMENT) { - if ( - !form.value.blames.filter( + if (form.value.blames.filter( (item) => item.type === BlameType.PERSONAL - ).length + ).length === 0 ) { - handleAddPersomal(); + handleAddPersonal(); } - if ( - !form.value.blames.filter( + if (form.value.blames.filter( (item) => item.type === BlameType.DEPARTMENT - ).length + ).length === 0 ) { form.value.blames.push({ type: BlameType.DEPARTMENT, @@ -1405,7 +1403,7 @@ function handleChangeCheckStatus(val, item) { form.value.accountabilityTarget !== AccountabilityTarget.DEPARTMENT && form.value.blames.length === 0 ) { - handleAddPersomal(); + handleAddPersonal(); } } @@ -1427,7 +1425,6 @@ function handleChangeSubjectiveAspect(val, item) { } function handleChangeProblem(node, problem) { - debugger; if (node.level === 3) { problem.threeLevelContent = node.label; problem.oneLevelCode = node.parent.parent.key; diff --git a/src/views/sensitivePerception/RiskPersonnel.vue b/src/views/sensitivePerception/RiskPersonnel.vue index 6c27b02..478e402 100644 --- a/src/views/sensitivePerception/RiskPersonnel.vue +++ b/src/views/sensitivePerception/RiskPersonnel.vue @@ -99,10 +99,7 @@ prop="controlDepartName" width="120" /> - + @@ -167,83 +164,118 @@
-
风险人员基本情况
- - - -
-
- -
-
-
- - {{ activeRow.name }} -
-
- - {{ getGender(activeRow.gender) }} -
-
- - {{ activeRow.idCode }} -
-
-
- - {{ activeRow.age }} -
-
- - {{ - activeRow.controlDepartName - }} -
-
- - {{ activeRow.mobileNumber }} + +
+
{{ item.riskName }}
+
+ {{ risk.riskName }} +
+
+
+ + + +

风险人员基本情况

+ + + + + + + +
+
+ + {{ activeRow.name }} +
+
+ + {{ + getGender(activeRow.gender) + }} +
+
+ + {{ activeRow.age }} +
+
+ + {{ activeRow.idCode }} +
+
+ + {{ + activeRow.mobileNumber + }} +
+
+ + {{ + activeRow.controlDepartName + }} +
+
+
+
+ +
+
+ {{ personal.riskPersonal.riskScore.toFixed(1) }}
+ 风险指数
+
+
+
+
+
{{ item.riskName }}
+ + + + + + + +
- - - -
-
- {{ personal.riskPersonal.riskScore.toFixed(1) }} -
- 风险指数
-
-
-
{{ item.riskName }}
- - - - - - - - -
-
@@ -326,7 +358,7 @@ import { listRiskPersonnel, getRiskPersonnel, } from "@/api/sensitivePerception/riskPersonnel"; -import { ref } from "vue"; +import { listRiskScoreRuleTree } from "@/api/sensitivePerception/riskScoreRule"; import { alarmNotificationCommit } from "~/api/work/alarm"; import feedback from "~/utils/feedback"; import { listPoliceAll } from "~/api/system/police"; @@ -436,8 +468,12 @@ function reset() { getList(); } +const rules = ref([]); onMounted(() => { getList(); + listRiskScoreRuleTree().then((data) => { + rules.value = data; + }); }); const activeRow = ref({}); @@ -506,8 +542,8 @@ const tags = [ value: "涉违法犯罪人员", }, { - label: "涉举报投诉信访人员", - value: "涉举报投诉信访人员", + label: "涉投诉举报信访人员", + value: "涉投诉举报信访人员", }, { label: "涉诉讼人员", @@ -560,6 +596,18 @@ const riskReasons = [ label: "重点上访人员", value: "重点上访人员", }, + { + label: "已被打击处理", + value: "已被打击处理", + }, + { + label: "受到刑政处罚", + value: "受到刑政处罚", + }, + { + label: "受到刑事处罚", + value: "受到刑事处罚", + }, { label: "取保候审", value: "取保候审", @@ -572,6 +620,7 @@ const riskReasons = [ label: "其它潜在危害人员", value: "其它潜在危害人员", }, + { label: "殴打他人", value: "殴打他人", @@ -589,8 +638,20 @@ const riskReasons = [ value: "精神障碍患者", }, { - label: '"扬言滋事、自杀等行为”', - value: "扬言滋事、自杀等行为”", + label: "厌世情绪", + value: "厌世情绪", + }, + { + label: "报复社会", + value: "报复社会", + }, + { + label: "遭遇不公", + value: "遭遇不公", + }, + { + label: "自杀", + value: "自杀", }, { label: "家暴", @@ -620,24 +681,24 @@ const riskReasons = [ ]; const educations = [ { - label: "小学", - value: "小学", + label: "小学及以下", + value: "小学及以下", }, { label: "初中", value: "初中", }, { - label: "中专/高中", - value: "中专/高中", + label: "高中/中专", + value: "高中/中专", }, { - label: "专科/本科", - value: "专科/本科", + label: "大学", + value: "大学", }, { - label: "研究生以上", - value: "研究生以上", + label: "大学以上", + value: "大学以上", }, ]; @@ -664,17 +725,68 @@ const ages = [ }, ]; -function getTagType(item) { - if (item.includes('在逃') || item.includes('重大刑事犯罪') || item.includes('个人极端') || item.includes('涉稳人员') - || item.includes('涉毒') || item.includes('重点上访人员')) { - return 'danger'; +function getSmallTags(val) { + if (!val) { + return []; + } + const arr = val.split(",").map((tag) => { + return getSmallTagObj(tag); + }); + arr.sort((a, b) => a.sort - b.sort); + return arr; +} + +function getSmallTagObj(item) { + if ( + item.includes("在逃") || + item.includes("重大刑事犯罪") || + item.includes("个人极端") || + item.includes("涉稳人员") || + item.includes("涉毒") || + item.includes("重点上访人员") || + item.includes("已被打击处理") || + item.includes("受到刑政处罚") || + item.includes("受到刑事处罚") + ) { + return { + type: "danger", + sort: 1, + value: item, + }; } - if (item.includes('取保候审') || item.includes('监视居住') || item.includes('其它潜在危害人员') || item.includes('殴打他人') - || item.includes('故意伤害') || item.includes('寻衅滋事') || item.includes('精神障碍患者') || item.includes('扬言滋事') - || item.includes('家暴') || item.includes('离婚') || item.includes('酗酒') || item.includes('纠纷') || item.includes('无业人员')) { - return 'warning'; + if ( + item.includes("取保候审") || + item.includes("监视居住") || + item.includes("其它潜在危害人员") || + item.includes("殴打他人") || + item.includes("故意伤害") || + item.includes("寻衅滋事") || + item.includes("精神障碍患者") || + item.includes("扬言滋事") || + item.includes("家暴") || + item.includes("离婚") || + item.includes("酗酒") || + item.includes("纠纷") || + item.includes("无业人员") + ) { + return { + type: "warning", + sort: 2, + value: item, + }; } - return 'info' + return { + type: "info", + sort: 3, + value: item, + }; +} + +function getColor(score) { + if (score >= 80) { + return "red"; + } + return "#333"; } \ No newline at end of file diff --git a/src/views/sensitivePerception/RiskScoreRule.vue b/src/views/sensitivePerception/RiskScoreRule.vue index 1768841..8946ac4 100644 --- a/src/views/sensitivePerception/RiskScoreRule.vue +++ b/src/views/sensitivePerception/RiskScoreRule.vue @@ -292,7 +292,7 @@ async function handleCalculate() { } function getChildWeightSum(row) { - const arr = row.children.map(item => item.weight || 0); + const arr = row.children.filter(item => item.status).map(item => item.weight || 0); if (arr.length === 0) { return 0; }