|
|
@@ -482,13 +482,15 @@ export default {
|
|
|
computed: {
|
|
|
...mapState([]),
|
|
|
...mapGetters(["orgId", "orgName"]),
|
|
|
- orgTypeOptions(){
|
|
|
- if(!this.dict || !this.dict.type.sys_org_type==null) {
|
|
|
- return []
|
|
|
- }
|
|
|
-
|
|
|
- return this.dict.type.sys_org_type.filter(t=>!["7","8"].includes(t.value))
|
|
|
- }
|
|
|
+ orgTypeOptions() {
|
|
|
+ if (!this.dict || !this.dict.type.sys_org_type == null) {
|
|
|
+ return [];
|
|
|
+ }
|
|
|
+
|
|
|
+ return this.dict.type.sys_org_type.filter(
|
|
|
+ (t) => !["7", "8"].includes(t.value)
|
|
|
+ );
|
|
|
+ },
|
|
|
},
|
|
|
methods: {
|
|
|
...mapMutations([]),
|
|
|
@@ -511,8 +513,8 @@ export default {
|
|
|
//行社的计划,或检查机构类型是省联社、办事处,走单个下发
|
|
|
if (
|
|
|
row.planOfOrgType == 3 ||
|
|
|
- row.checkOrgType == 1 ||
|
|
|
- row.checkOrgType == 2
|
|
|
+ row.execOrgType == 1 ||
|
|
|
+ row.execOrgType == 2
|
|
|
) {
|
|
|
this.onSinglePlanDistribute(row);
|
|
|
} else {
|
|
|
@@ -524,7 +526,7 @@ export default {
|
|
|
if (row.planStatus == 0) {
|
|
|
if (row.planCycle == 6) {
|
|
|
//无周期任务,
|
|
|
- let msg = "无周期任务下发后将立即生成任务,确定下发?";
|
|
|
+ let msg = "确定下发任务并立即生成任务?";
|
|
|
this.$modal.confirm(msg).then(() => {
|
|
|
this.distributeSingle(row.id, true);
|
|
|
});
|
|
|
@@ -609,7 +611,7 @@ export default {
|
|
|
},
|
|
|
showDelete(row) {
|
|
|
//本机构创建的计划,才能删除
|
|
|
- return row.planCreateOrgId == this.orgId;
|
|
|
+ return row.planCreateOrgId == this.orgId && row.planOfOrgId == this.orgId;
|
|
|
},
|
|
|
showWithDraw(row) {
|
|
|
//本机构创建是自己+状态为使用中
|
|
|
@@ -641,7 +643,7 @@ export default {
|
|
|
if (row.planStatus == 0) {
|
|
|
if (row.planCycle == 6) {
|
|
|
//无周期任务,
|
|
|
- let msg = "无周期任务下发后将立即生成任务,确定下发?";
|
|
|
+ let msg = "确定下发任务并立即生成任务?";
|
|
|
this.$modal.confirm(msg).then(() => {
|
|
|
this.distributeInner(selectList, true);
|
|
|
});
|
|
|
@@ -667,11 +669,9 @@ export default {
|
|
|
} else {
|
|
|
msg = "因存在已完成任务,是否确定从下周期生成任务?";
|
|
|
}
|
|
|
- this.$modal
|
|
|
- .confirm(msg)
|
|
|
- .then(() => {
|
|
|
- this.distributeInner(selectList, false);
|
|
|
- });
|
|
|
+ this.$modal.confirm(msg).then(() => {
|
|
|
+ this.distributeInner(selectList, false);
|
|
|
+ });
|
|
|
} else {
|
|
|
this.distributeInner(selectList, false);
|
|
|
}
|
|
|
@@ -691,9 +691,16 @@ export default {
|
|
|
|
|
|
//开始撤回
|
|
|
chhuile(row) {
|
|
|
+ if (row.planCycle == "6" && row.taskHasCompleted == 1) {
|
|
|
+ //无周期任务有已完成时,不能撤回
|
|
|
+ this.$modal.alertSuccess(
|
|
|
+ "存在已完成任务,无周期任务不允许撤回,如需删除下发任务请点击“删除”。"
|
|
|
+ );
|
|
|
+ return;
|
|
|
+ }
|
|
|
let msg;
|
|
|
-
|
|
|
- if (row.taskHasCompleted != 1) {
|
|
|
+
|
|
|
+ if (row.taskHasCompleted != 1) {
|
|
|
msg = "因不存在已完成任务,撤回后将删除所有生成任务?";
|
|
|
} else {
|
|
|
msg = "因存在已完成任务,撤回后下周期起将不再生成任务?";
|
|
|
@@ -764,18 +771,10 @@ export default {
|
|
|
if (row.planStatus == 0) {
|
|
|
msg = '是否确认删除名称为"' + row.planName + '"的任务?';
|
|
|
} else if (row.planStatus == 1) {
|
|
|
- if (row.planCycle == 1) {
|
|
|
- msg = "本次删除将强制删除今日所有任务?";
|
|
|
- } else {
|
|
|
- msg = "本次删除将强制删除当前任务时间及以后所有任务";
|
|
|
- }
|
|
|
+ msg = "本次删除将强制删除当前任务时间及以后所有任务";
|
|
|
} else if (row.planStatus == 2) {
|
|
|
if (row.hasTaskCurrentCycle) {
|
|
|
- if (row.planCycle == 1) {
|
|
|
- msg = "本次删除将强制删除今日所有任务?";
|
|
|
- } else {
|
|
|
- msg = "本次删除将强制删除当前任务时间及以后所有任务";
|
|
|
- }
|
|
|
+ msg = "本次删除将强制删除当前任务时间及以后所有任务";
|
|
|
} else {
|
|
|
msg = '是否确认删除名称为"' + row.planName + '"的任务?';
|
|
|
}
|
|
|
@@ -799,7 +798,7 @@ export default {
|
|
|
});
|
|
|
})
|
|
|
.catch((ex) => {
|
|
|
- console.error(ex)
|
|
|
+ console.error(ex);
|
|
|
// 用户点击了取消按钮
|
|
|
// console.log("取消操作...");
|
|
|
});
|