master
e 7 months ago
parent 3b8552aa99
commit 6e4eecf329

Binary file not shown.

@ -126,4 +126,12 @@ export function UrgencyDegreeInsert(data) {
method: "post", method: "post",
data, data,
}); });
} }
//查询人
export function personnelList(data) {
return request({
url: "/tbRulesSetting/personnelList",
method: "post",
data,
});
}

@ -76,16 +76,16 @@
<template v-if="item.type === 'checkGroup'"> <template v-if="item.type === 'checkGroup'">
<el-checkbox-group <el-checkbox-group
v-model.trim="model[item.attrs.model]" v-bind="item.attrs"
v-model="model[item.attrs.model]"
v-on="item.listeners || {}" v-on="item.listeners || {}"
> >
<el-checkbox <el-checkbox
v-for="option in item.attrs.option" v-for="city in item.attrs.option"
:key="option.value" :key="city.value"
:label="option.name" :label="city.value"
>{{ city.name }}</el-checkbox
> >
{{ option.name }}
</el-checkbox>
</el-checkbox-group> </el-checkbox-group>
</template> </template>

@ -45,6 +45,17 @@ export const commonMixins = {
value: "1", value: "1",
}, },
], ],
//是否
isNoTextList: [
{
name: "是",
value: "是",
},
{
name: "否",
value: "否",
},
],
//是否正常 //是否正常
isZChangList: [ isZChangList: [
{ {
@ -276,51 +287,51 @@ export const commonMixins = {
pushList: [ pushList: [
{ {
name: "短信提醒", name: "短信提醒",
value: "0", value: "短信提醒",
}, },
{ {
name: "平台消息提醒", name: "平台消息提醒",
value: "1", value: "平台消息提醒",
}, },
{ {
name: "钉消息提醒", name: "钉消息",
value: "2", value: "钉消息",
}, },
], ],
pushObjList: [ pushObjList: [
{ {
name: "企业对象", name: "企业负责人",
value: "1", value: "企业负责人",
}, },
{ {
name: "镇海区公安局", name: "镇海区公安局",
value: "2", value: "镇海区公安局",
}, },
{ {
name: "镇海区交通局", name: "镇海区交通局",
value: "3", value: "镇海区交通局",
}, },
{ {
name: "市场监督管理局", name: "市场监督管理局",
value: "4", value: "市场监督管理局",
}, },
{ {
name: "区大数据中心", name: "区大数据中心",
value: "5", value: "区大数据中心",
}, },
], ],
remindList: [ remindList: [
{ {
name: "到期前一天", name: "到期前一天",
value: "0", value: "到期前一天",
}, },
{ {
name: "到期前三天", name: "到期前三天",
value: "1", value: "到期前三天",
}, },
{ {
name: "到期前五天", name: "到期前五天",
value: "2", value: "到期前五天",
}, },
], ],
personList: [ personList: [
@ -382,7 +393,7 @@ export const commonMixins = {
return ""; return "";
} }
}, },
/* formatTime(arr) { /* formatTime(arr) {
if (arr.length) { if (arr.length) {
let sTime = arr[0].format let sTime = arr[0].format
return [] return []

@ -44,7 +44,7 @@
style="width: 120px" style="width: 120px"
:min="0" :min="0"
:max="100" :max="100"
v-model="queryParam.rateProgress" v-model="queryParam.startRatio"
placeholder="" placeholder=""
></el-input-number> ></el-input-number>
<span style="color: #495e70; padding: 0 4px">-</span> <span style="color: #495e70; padding: 0 4px">-</span>
@ -52,7 +52,7 @@
style="width: 120px" style="width: 120px"
:min="0" :min="0"
:max="100" :max="100"
v-model="queryParam.max" v-model="queryParam.endRatio"
placeholder="" placeholder=""
></el-input-number> ></el-input-number>
</div> </div>

@ -5,7 +5,7 @@
<div class="searchWrap"> <div class="searchWrap">
<el-form :inline="true" :model="queryParam" class="demo-form-inline"> <el-form :inline="true" :model="queryParam" class="demo-form-inline">
<el-form-item label="消息类型:"> <el-form-item label="消息类型:">
<el-select clearable v-model="queryParam.infoType" placeholder=""> <el-select clearable v-model="queryParam.type" placeholder="">
<el-option <el-option
v-for="item in infoTypeList" v-for="item in infoTypeList"
:label="item.name" :label="item.name"
@ -15,9 +15,9 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="推送方式:"> <el-form-item label="推送方式:">
<el-select clearable v-model="queryParam.ts" placeholder=""> <el-select clearable v-model="queryParam.drivingWay" placeholder="">
<el-option <el-option
v-for="item in tipWayList" v-for="item in pushList"
:label="item.name" :label="item.name"
:key="item.name" :key="item.name"
:value="item.value" :value="item.value"
@ -25,9 +25,9 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="超期短信提醒:"> <el-form-item label="超期短信提醒:">
<el-select clearable v-model="queryParam.tx" placeholder=""> <el-select clearable v-model="queryParam.overdue" placeholder="">
<el-option <el-option
v-for="item in isNoList" v-for="item in isNoTextList"
:label="item.name" :label="item.name"
:key="item.name" :key="item.name"
:value="item.value" :value="item.value"
@ -61,12 +61,10 @@
</span> </span>
</template> </template>
<template v-slot:optSlot="{ scope }"> <template v-slot:optSlot="{ scope }">
<div class="tableOPtBtn" @click="ruleSet(scope.row)"> <div class="tableOPtBtn" @click="ruleSet(scope.row)"></div>
规则配置
</div>
</template> </template>
<template v-slot:isnSlot="{ scope }"> <template v-slot:isnSlot="{ scope }">
<gDict :options="isNoList" :value="scope.row.msg"></gDict> <gDict :options="isNoTextList" :value="scope.row.msg"></gDict>
</template> </template>
<template v-slot:infoTypeSlot="{ scope }"> <template v-slot:infoTypeSlot="{ scope }">
<gDict :options="infoTypeList" :value="scope.row.infoType"></gDict> <gDict :options="infoTypeList" :value="scope.row.infoType"></gDict>
@ -93,6 +91,8 @@
<script> <script>
import { tableListMixins } from "@/loveflow/mixins/tableListMixins"; import { tableListMixins } from "@/loveflow/mixins/tableListMixins";
import { commonMixins } from "@/loveflow/mixins/commonMixins"; import { commonMixins } from "@/loveflow/mixins/commonMixins";
import { UpdatePushSetting } from "@/api/enterpriseTeamWork/tipSet/index.js";
export default { export default {
mixins: [tableListMixins, commonMixins], mixins: [tableListMixins, commonMixins],
data() { data() {
@ -121,31 +121,31 @@ export default {
}, },
}, },
{ {
slot: "infoTypeSlot", //slot: "infoTypeSlot",
prop: "infoType", prop: "type",
label: "消息类型", label: "消息类型",
}, },
{ {
slot: "riskSlot", //slot: "riskSlot",
prop: "risk", prop: "control",
label: "管控扣分项", label: "管控扣分项",
}, },
{ {
prop: "node", prop: "drivingObject",
label: "推送对象", label: "推送对象",
}, },
{ {
slot: "tipWaySlot", //slot: "tipWaySlot",
prop: "tipWay", prop: "drivingWay",
label: "推送方式", label: "推送方式",
}, },
{ {
prop: "time", prop: "drivingTime",
label: "推送时间", label: "推送时间",
}, },
{ {
slot: "isnSlot", //slot: "isnSlot",
prop: "msg", prop: "overdue",
label: "是否短信提醒", label: "是否短信提醒",
}, },
{ {
@ -157,28 +157,6 @@ export default {
}, },
}, },
], ],
pushObjList: [
{
name: "企业对象",
value: "1",
},
{
name: "镇海区公安局",
value: "2",
},
{
name: "镇海区交通局",
value: "3",
},
{
name: "市场监督管理局",
value: "4",
},
{
name: "区大数据中心",
value: "5",
},
],
formItems: [ formItems: [
{ {
type: "select", type: "select",
@ -188,7 +166,7 @@ export default {
rules: this.requiredItem, rules: this.requiredItem,
}, },
attrs: { attrs: {
model: "jb", model: "drivingWay",
value: "", value: "",
option: [], option: [],
style: { style: {
@ -204,7 +182,7 @@ export default {
span: 12, span: 12,
}, },
attrs: { attrs: {
model: "date", model: "drivingTime",
value: "", value: "",
placeholder: "", placeholder: "",
style: {}, style: {},
@ -218,7 +196,7 @@ export default {
span: 24, span: 24,
}, },
attrs: { attrs: {
model: "tdx", model: "pushObjList",
value: [], value: [],
option: [], option: [],
}, },
@ -230,7 +208,7 @@ export default {
span: 12, span: 12,
}, },
attrs: { attrs: {
model: "dx", model: "overdue",
value: "", value: "",
option: [], option: [],
style: { style: {
@ -246,7 +224,7 @@ export default {
span: 12, span: 12,
}, },
attrs: { attrs: {
model: "cq", model: "overdueTime",
value: "", value: "",
option: [], option: [],
style: { style: {
@ -255,20 +233,51 @@ export default {
}, },
}, },
], ],
url: {
list: "/tbRulesSetting/PushSettingList",
},
}; };
}, },
mounted() { mounted() {
this.setFindItem("formItems", "jb").attrs.option = this.infoTypeList; console.log(this.pushObjList);
this.setFindItem("formItems", "tdx").attrs.option = this.pushObjList; this.setFindItem("formItems", "pushObjList").attrs.option =
this.setFindItem("formItems", "dx").attrs.option = this.isNoList; this.pushObjList;
this.setFindItem("formItems", "cq").attrs.option = this.dqList; this.setFindItem("formItems", "drivingWay").attrs.option = this.pushList;
this.setFindItem("formItems", "overdue").attrs.option = this.isNoTextList;
this.setFindItem("formItems", "overdueTime").attrs.option = this.remindList;
}, },
methods: { methods: {
ruleSet(obj) { ruleSet(obj) {
console.log(obj);
obj.pushObjList = [];
if (obj.drivingObject) {
obj.pushObjList = obj.drivingObject.split(",");
}
this.$refs.formDialog.openDialog("detail", obj, "推送规则设置"); this.$refs.formDialog.openDialog("detail", obj, "推送规则设置");
}, },
formSubmit(obj) { formSubmit(obj) {
console.log(obj); console.log(obj);
let drivingObject = obj.pushObjList.length
? obj.pushObjList.join(",")
: "";
let param = {
control: obj.control,
drivingObject: drivingObject,
drivingTime: obj.drivingTime,
drivingWay: obj.drivingWay,
id: 18478,
overdue: obj.overdue,
overdueTime: obj.overdueTime,
type: obj.type,
};
UpdatePushSetting(param).then((res) => {
if (res.code == 200) {
this.$message.success("操作成功");
this.$refs.formDialog.handleClose();
this.searchQuery();
}
});
}, },
}, },
}; };

@ -23,33 +23,33 @@
<div class="line"> <div class="line">
<div class="item"> <div class="item">
<div class="label">消息类型</div> <div class="label">消息类型</div>
<div class="value">{{ item.type }}</div> <div class="value">{{ item.messageType }}</div>
</div> </div>
<div class="item"> <div class="item">
<div class="label">推送方式</div> <div class="label">推送方式</div>
<div class="value">{{ item.way }}</div> <div class="value">{{ item.pushMode }}</div>
</div> </div>
</div> </div>
<div class="line"> <div class="line">
<div class="item"> <div class="item">
<div class="label">风险项</div> <div class="label">风险项</div>
<div class="value">{{ item.risk }}</div> <div class="value">{{ item.riskItem }}</div>
</div> </div>
<div class="item"> <div class="item">
<div class="label" style="width: 100px">要素异常明细</div> <div class="label" style="width: 100px">要素异常明细</div>
<div class="value">{{ item.ys }}</div> <div class="value">{{ item.exceptionDetail }}</div>
</div> </div>
</div> </div>
<div class="line"> <div class="line">
<div class="item"> <div class="item">
<div class="label">推送对象</div> <div class="label">推送对象</div>
<div class="value">{{ item.obj }}</div> <div class="value">{{ item.drivingObject }}</div>
</div> </div>
</div> </div>
<div class="line"> <div class="line">
<div class="item"> <div class="item">
<div class="label">提醒内容</div> <div class="label">提醒内容</div>
<div class="value">{{ item.nr }}</div> <div class="value">{{ item.drivingContent }}</div>
</div> </div>
</div> </div>
<div class="line"> <div class="line">
@ -101,11 +101,15 @@
<script> <script>
import { tableListMixins } from "@/loveflow/mixins/tableListMixins"; import { tableListMixins } from "@/loveflow/mixins/tableListMixins";
import { commonMixins } from "@/loveflow/mixins/commonMixins"; import { commonMixins } from "@/loveflow/mixins/commonMixins";
import {
SMSTemplateInsertOrUpdate,
SMSTemplateRemove,
} from "@/api/enterpriseTeamWork/tipSet/index.js";
export default { export default {
mixins: [tableListMixins, commonMixins], mixins: [tableListMixins, commonMixins],
data() { data() {
return { return {
disableMixinCreated: true,
columns: [ columns: [
{ {
prop: "id", prop: "id",
@ -121,7 +125,7 @@ export default {
rules: this.$rules.requiredItem, rules: this.$rules.requiredItem,
}, },
attrs: { attrs: {
model: "type", model: "messageType",
value: "", value: "",
option: [], option: [],
style: { style: {
@ -138,7 +142,7 @@ export default {
rules: this.$rules.requiredItem, rules: this.$rules.requiredItem,
}, },
attrs: { attrs: {
model: "way", model: "pushMode",
value: "", value: "",
option: [], option: [],
style: { style: {
@ -154,7 +158,7 @@ export default {
rules: this.$rules.requiredItem, rules: this.$rules.requiredItem,
}, },
attrs: { attrs: {
model: "risk", model: "riskItem",
value: "", value: "",
option: [], option: [],
style: { style: {
@ -171,7 +175,7 @@ export default {
rules: this.$rules.requiredItem, rules: this.$rules.requiredItem,
}, },
attrs: { attrs: {
model: "ys", model: "exceptionDetail",
value: "", value: "",
option: [], option: [],
style: { style: {
@ -187,7 +191,7 @@ export default {
rules: this.$rules.requiredItem, rules: this.$rules.requiredItem,
}, },
attrs: { attrs: {
model: "obj", model: "drivingObject",
value: [], value: [],
option: [], option: [],
}, },
@ -200,7 +204,7 @@ export default {
rules: this.$rules.requiredItem, rules: this.$rules.requiredItem,
}, },
attrs: { attrs: {
model: "nr", model: "drivingContent",
rows: 2, rows: 2,
value: "", value: "",
}, },
@ -213,7 +217,7 @@ export default {
rules: this.$rules.requiredItem, rules: this.$rules.requiredItem,
}, },
attrs: { attrs: {
model: "dx", model: "smsReminder",
value: "", value: "",
option: [], option: [],
style: { style: {
@ -230,7 +234,7 @@ export default {
rules: this.$rules.requiredItem, rules: this.$rules.requiredItem,
}, },
attrs: { attrs: {
model: "cq", model: "reminderTime",
value: "", value: "",
option: [], option: [],
style: { style: {
@ -239,45 +243,59 @@ export default {
}, },
}, },
], ],
url: {
list: "/tbRulesSetting/SMSTemplateList",
},
}; };
}, },
mounted() { mounted() {
this.setFindItem("formItems", "type").attrs.option = this.infoTypeList; this.setFindItem("formItems", "messageType").attrs.option =
this.setFindItem("formItems", "way").attrs.option = this.pushList; this.infoTypeList;
this.setFindItem("formItems", "risk").attrs.option = this.riskList; this.setFindItem("formItems", "pushMode").attrs.option = this.pushList;
this.setFindItem("formItems", "ys").attrs.option = this.elementList; this.setFindItem("formItems", "riskItem").attrs.option = this.riskList;
this.setFindItem("formItems", "obj").attrs.option = this.pushObjList; this.setFindItem("formItems", "exceptionDetail").attrs.option =
this.setFindItem("formItems", "dx").attrs.option = this.isNoList; this.elementList;
this.setFindItem("formItems", "cq").attrs.option = this.remindList; this.setFindItem("formItems", "drivingObject").attrs.option =
}, this.pushObjList;
created() { this.setFindItem("formItems", "smsReminder").attrs.option =
for (let i = 0; i < 20; i++) { this.isNoTextList;
this.dataSource.push({ this.setFindItem("formItems", "reminderTime").attrs.option =
id: i, this.remindList;
type: "风险提醒",
way: "短信提醒",
risk: "流动人员异常",
ys: "流动人员核查率异常",
obj: "企业负责人、镇海区公安局、石化工业区管委会",
nr: "您好X年X月X日贵单位的XXXXXXXX证书将过期需及时处置。",
});
}
}, },
created() {},
methods: { methods: {
add() { add() {
this.$refs.formDialog.openDialog("other", {}, "推送规则设置"); this.$refs.formDialog.openDialog("other", {}, "推送规则设置");
}, },
edit(obj) { edit(obj) {
if (obj.drivingObject) {
obj.drivingObject = obj.drivingObject.split(",");
}
this.$refs.formDialog.openDialog("other", obj, "编辑推送规则设置"); this.$refs.formDialog.openDialog("other", obj, "编辑推送规则设置");
}, },
del(item) { del(item) {
this.$message({ SMSTemplateRemove({ id: item.id }).then((res) => {
message: item.nr, if (res.code == 200) {
type: "success", this.$message({
message: "删除成功",
type: "success",
});
this.searchQuery();
}
}); });
}, },
formSubmit(obj) { formSubmit(obj) {
console.log(obj); console.log(obj);
obj.drivingObject = obj.drivingObject.length
? obj.drivingObject.join(",")
: "";
SMSTemplateInsertOrUpdate(obj).then((res) => {
if (res.code == 200) {
this.$message.success("操作成功");
this.$refs.formDialog.handleClose();
this.searchQuery();
}
});
}, },
}, },
}; };

@ -7,7 +7,12 @@
<div class="urNodeLine"> <div class="urNodeLine">
<div class="label">请选择单位</div> <div class="label">请选择单位</div>
<div class=""> <div class="">
<el-select clearable v-model="obj.unit" placeholder=""> <el-select
clearable
v-model="obj.unit"
placeholder=""
@change="unitChange"
>
<el-option <el-option
v-for="item in obj.unitList" v-for="item in obj.unitList"
:label="item.name" :label="item.name"
@ -33,6 +38,7 @@
</div> </div>
</template> </template>
<script> <script>
import { personnelList } from "@/api/enterpriseTeamWork/tipSet/index.js";
export default { export default {
props: { props: {
obj: { obj: {
@ -49,11 +55,23 @@ export default {
}, },
}, },
data() { data() {
return {}; return {
personList: [],
};
}, },
created() { created() {
console.log(this.obj); console.log(this.obj);
}, },
methods: {
unitChange(val) {
console.log(val);
/* personnelList({ unitid: val }).then((res) => {
if (res.code == 200) {
let data = res.data || [];
}
}); */
},
},
}; };
</script> </script>

@ -86,6 +86,28 @@ export default {
title: "", title: "",
nodeList: [], nodeList: [],
nid: "", nid: "",
personList: [
{
name: "杨怡伶",
value: "杨怡伶",
},
{
name: "李彦志",
value: "李彦志",
},
{
name: "吴淑霞",
value: "吴淑霞",
},
{
name: "张雅泰",
value: "张雅泰",
},
{
name: "张三",
value: "张三",
},
],
}; };
}, },
created() { created() {
@ -94,7 +116,7 @@ export default {
mounted() {}, mounted() {},
methods: { methods: {
flowSet(obj) { flowSet(obj) {
console.log(obj); console.log("this.personList:", this.personList);
this.title = obj.title; this.title = obj.title;
UrgencyDegreeList({ degree: obj.title }).then((res) => { UrgencyDegreeList({ degree: obj.title }).then((res) => {
if (res.code == 200) { if (res.code == 200) {
@ -130,7 +152,7 @@ export default {
}, },
sure() { sure() {
console.log(this.nodeList); console.log(this.nodeList);
if (this.nodeList.length) { if (!this.nodeList.length) {
this.$message("请设置节点"); this.$message("请设置节点");
return; return;
} }

Loading…
Cancel
Save