|
|
@@ -21,150 +21,153 @@
|
|
|
size="small"
|
|
|
:inline="true"
|
|
|
v-show="showSearch"
|
|
|
- label-width="70px"
|
|
|
+ label-width="90px"
|
|
|
>
|
|
|
- <el-form-item prop="checkType" label="任务类型" >
|
|
|
- <el-select
|
|
|
- prop="checkType"
|
|
|
- label="任务类型"
|
|
|
- v-model="queryParams.checkType"
|
|
|
- placeholder="请选择任务类型"
|
|
|
- clearable
|
|
|
- >
|
|
|
- <el-option
|
|
|
- v-for="dict in dict.type.check_type"
|
|
|
- :key="dict.value"
|
|
|
- :label="dict.label"
|
|
|
- :value="dict.value"
|
|
|
- />
|
|
|
- </el-select>
|
|
|
- </el-form-item>
|
|
|
- <el-form-item prop="execOrgType" label="检查机构类型" v-if="false">
|
|
|
- <el-select
|
|
|
- prop="execOrgType"
|
|
|
- label="检查机构类型"
|
|
|
- v-model="queryParams.execOrgType"
|
|
|
- placeholder="请选择检查机构类型"
|
|
|
- clearable
|
|
|
- >
|
|
|
- <el-option
|
|
|
- v-for="dict in dict.type.sys_org_type"
|
|
|
- :key="dict.value"
|
|
|
- :label="dict.label"
|
|
|
- :value="dict.value"
|
|
|
- />
|
|
|
- </el-select>
|
|
|
- </el-form-item>
|
|
|
- <el-form-item prop="checkOrgType" label="受检机构类型" v-if="false">
|
|
|
- <el-select
|
|
|
- prop="checkOrgType"
|
|
|
- label="受检机构类型"
|
|
|
- v-model="queryParams.checkOrgType"
|
|
|
- placeholder="请选择受检机构类型"
|
|
|
- clearable
|
|
|
- >
|
|
|
- <el-option
|
|
|
- v-for="dict in dict.type.sys_org_type"
|
|
|
- :key="dict.value"
|
|
|
- :label="dict.label"
|
|
|
- :value="dict.value"
|
|
|
- />
|
|
|
- </el-select>
|
|
|
- </el-form-item>
|
|
|
+ <el-row>
|
|
|
+ <el-form-item prop="checkType" label="任务类型">
|
|
|
+ <el-select
|
|
|
+ prop="checkType"
|
|
|
+ label="任务类型"
|
|
|
+ v-model="queryParams.checkType"
|
|
|
+ placeholder="请选择任务类型"
|
|
|
+ clearable
|
|
|
+ >
|
|
|
+ <el-option
|
|
|
+ v-for="dict in dict.type.check_type"
|
|
|
+ :key="dict.value"
|
|
|
+ :label="dict.label"
|
|
|
+ :value="dict.value"
|
|
|
+ />
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item prop="execOrgType" label="检查机构类型" v-if="false">
|
|
|
+ <el-select
|
|
|
+ prop="execOrgType"
|
|
|
+ label="检查机构类型"
|
|
|
+ v-model="queryParams.execOrgType"
|
|
|
+ placeholder="请选择检查机构类型"
|
|
|
+ clearable
|
|
|
+ >
|
|
|
+ <el-option
|
|
|
+ v-for="dict in dict.type.sys_org_type"
|
|
|
+ :key="dict.value"
|
|
|
+ :label="dict.label"
|
|
|
+ :value="dict.value"
|
|
|
+ />
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item prop="checkOrgType" label="受检机构类型" v-if="false">
|
|
|
+ <el-select
|
|
|
+ prop="checkOrgType"
|
|
|
+ label="受检机构类型"
|
|
|
+ v-model="queryParams.checkOrgType"
|
|
|
+ placeholder="请选择受检机构类型"
|
|
|
+ clearable
|
|
|
+ >
|
|
|
+ <el-option
|
|
|
+ v-for="dict in dict.type.sys_org_type"
|
|
|
+ :key="dict.value"
|
|
|
+ :label="dict.label"
|
|
|
+ :value="dict.value"
|
|
|
+ />
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
|
|
|
- <el-form-item prop="checkRole" label="检查人员">
|
|
|
- <el-select
|
|
|
- @visible-change="getRolesByOrg"
|
|
|
- prop="checkRole"
|
|
|
- label="检查人员"
|
|
|
- v-model="queryParams.checkRole"
|
|
|
- placeholder="请选择用户角色"
|
|
|
- clearable
|
|
|
- >
|
|
|
- <el-option
|
|
|
- v-for="dict in resumptionRoles"
|
|
|
- :key="dict.index"
|
|
|
- :label="dict.roleName"
|
|
|
- :value="dict.id"
|
|
|
+ <el-form-item prop="checkRole" label="检查人员">
|
|
|
+ <el-select
|
|
|
+ @visible-change="getRolesByOrg"
|
|
|
+ prop="checkRole"
|
|
|
+ label="检查人员"
|
|
|
+ v-model="queryParams.checkRole"
|
|
|
+ placeholder="请选择用户角色"
|
|
|
+ clearable
|
|
|
+ >
|
|
|
+ <el-option
|
|
|
+ v-for="dict in resumptionRoles"
|
|
|
+ :key="dict.index"
|
|
|
+ :label="dict.roleName"
|
|
|
+ :value="dict.id"
|
|
|
+ />
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item prop="planCycle" label="任务周期">
|
|
|
+ <el-select
|
|
|
+ prop="planCycle"
|
|
|
+ label="任务周期"
|
|
|
+ v-model="queryParams.planCycle"
|
|
|
+ placeholder="请选择任务周期"
|
|
|
+ clearable
|
|
|
+ >
|
|
|
+ <el-option
|
|
|
+ v-for="item in dict.type.check_cycle"
|
|
|
+ :key="item.value"
|
|
|
+ :label="item.label"
|
|
|
+ :value="item.value"
|
|
|
+ >
|
|
|
+ </el-option>
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ </el-row>
|
|
|
+ <el-row>
|
|
|
+ <el-form-item prop="planStatus" label="任务状态">
|
|
|
+ <el-select
|
|
|
+ prop="planStatus"
|
|
|
+ label="任务状态"
|
|
|
+ v-model="queryParams.planStatus"
|
|
|
+ placeholder="请选择任务状态"
|
|
|
+ clearable
|
|
|
+ >
|
|
|
+ <el-option
|
|
|
+ v-for="item in dict.type.check_status"
|
|
|
+ :key="item.value"
|
|
|
+ :label="item.label"
|
|
|
+ :value="item.value"
|
|
|
+ >
|
|
|
+ </el-option>
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item prop="planName" label="任务名称">
|
|
|
+ <el-input
|
|
|
+ v-model="queryParams.planName"
|
|
|
+ :maxlength="50"
|
|
|
+ name="planName"
|
|
|
+ placeholder="请输入关键字"
|
|
|
+ clearable
|
|
|
/>
|
|
|
- </el-select>
|
|
|
- </el-form-item>
|
|
|
- <el-form-item prop="planCycle" label="任务周期">
|
|
|
- <el-select
|
|
|
- prop="planCycle"
|
|
|
- label="任务周期"
|
|
|
- v-model="queryParams.planCycle"
|
|
|
- placeholder="请选择任务周期"
|
|
|
- clearable
|
|
|
- >
|
|
|
- <el-option
|
|
|
- v-for="item in dict.type.check_cycle"
|
|
|
- :key="item.value"
|
|
|
- :label="item.label"
|
|
|
- :value="item.value"
|
|
|
+ </el-form-item>
|
|
|
+ </el-row>
|
|
|
+ <el-row>
|
|
|
+ <el-form-item>
|
|
|
+ <el-button
|
|
|
+ type="primary"
|
|
|
+ icon="el-icon-search"
|
|
|
+ size="mini"
|
|
|
+ @click="getList"
|
|
|
+ >搜索</el-button
|
|
|
>
|
|
|
- </el-option>
|
|
|
- </el-select>
|
|
|
- </el-form-item>
|
|
|
- <el-form-item prop="planStatus" label="任务状态">
|
|
|
- <el-select
|
|
|
- prop="planStatus"
|
|
|
- label="任务状态"
|
|
|
- v-model="queryParams.planStatus"
|
|
|
- placeholder="请选择任务状态"
|
|
|
- clearable
|
|
|
- >
|
|
|
- <el-option
|
|
|
- v-for="item in dict.type.check_status"
|
|
|
- :key="item.value"
|
|
|
- :label="item.label"
|
|
|
- :value="item.value"
|
|
|
+ <el-button icon="el-icon-refresh" size="mini" @click="resetQuery"
|
|
|
+ >重置</el-button
|
|
|
+ ><el-button
|
|
|
+ type="primary"
|
|
|
+ icon="el-icon-plus"
|
|
|
+ size="mini"
|
|
|
+ @click="handleAdd()"
|
|
|
+ v-hasPermi="['core:checkplan:add']"
|
|
|
+ >新增任务</el-button
|
|
|
>
|
|
|
- </el-option>
|
|
|
- </el-select>
|
|
|
- </el-form-item>
|
|
|
- <el-form-item prop="planName" label="任务名称">
|
|
|
- <el-input
|
|
|
- v-model="queryParams.planName"
|
|
|
- :maxlength="50"
|
|
|
- name="planName"
|
|
|
- placeholder="请输入关键字"
|
|
|
- clearable
|
|
|
- />
|
|
|
- </el-form-item>
|
|
|
-
|
|
|
- <el-form-item>
|
|
|
- <el-button
|
|
|
- type="primary"
|
|
|
- icon="el-icon-search"
|
|
|
- size="mini"
|
|
|
- @click="getList"
|
|
|
- >搜索</el-button
|
|
|
- >
|
|
|
- <el-button icon="el-icon-refresh" size="mini" @click="resetQuery"
|
|
|
- >重置</el-button
|
|
|
- ><el-button
|
|
|
- type="primary"
|
|
|
- icon="el-icon-plus"
|
|
|
- size="mini"
|
|
|
- @click="handleAdd()"
|
|
|
- v-hasPermi="['core:checkplan:add']"
|
|
|
- >新增任务</el-button
|
|
|
- >
|
|
|
- </el-form-item>
|
|
|
+ </el-form-item>
|
|
|
+ </el-row>
|
|
|
</el-form>
|
|
|
|
|
|
- <!-- 按纽 -->
|
|
|
+ <!-- 按纽
|
|
|
<el-row :gutter="10" class="mb8">
|
|
|
- <el-col :span="1.5">
|
|
|
-
|
|
|
- </el-col>
|
|
|
+ <el-col :span="1.5"> </el-col>
|
|
|
<right-toolbar
|
|
|
:showSearch.sync="showSearch"
|
|
|
@queryTable="getList"
|
|
|
:columns="columns"
|
|
|
></right-toolbar>
|
|
|
- </el-row>
|
|
|
+ </el-row> -->
|
|
|
|
|
|
<el-table
|
|
|
border
|
|
|
@@ -177,6 +180,7 @@
|
|
|
:tree-props="{ children: 'children' }"
|
|
|
>
|
|
|
<el-table-column
|
|
|
+ align="center"
|
|
|
type="index"
|
|
|
label="序号"
|
|
|
width="80px"
|
|
|
@@ -187,7 +191,7 @@
|
|
|
label="任务名称"
|
|
|
v-if="columns[1].visible"
|
|
|
></el-table-column>
|
|
|
-
|
|
|
+
|
|
|
<el-table-column
|
|
|
prop="checkType"
|
|
|
label="任务类型"
|
|
|
@@ -210,20 +214,13 @@
|
|
|
>
|
|
|
</el-table-column>
|
|
|
|
|
|
- <el-table-column
|
|
|
- prop="execOrgType"
|
|
|
- label="检查主体"
|
|
|
- >
|
|
|
+ <el-table-column prop="execOrgType" label="检查主体">
|
|
|
<template slot-scope="r"
|
|
|
>{{ getLabel(dict.type.sys_org_type, `${r.row.execOrgType}`) }}
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
|
|
|
- <el-table-column
|
|
|
- prop="checkOrgType"
|
|
|
- label="受检机构"
|
|
|
- width="120px"
|
|
|
- >
|
|
|
+ <el-table-column prop="checkOrgType" label="受检机构" width="120px">
|
|
|
<template slot-scope="r"
|
|
|
>{{ getLabel(dict.type.sys_org_type, `${r.row.checkOrgType}`) }}
|
|
|
</template>
|
|
|
@@ -252,6 +249,7 @@
|
|
|
</el-table-column>
|
|
|
|
|
|
<el-table-column
|
|
|
+ align="center"
|
|
|
prop="count"
|
|
|
label="任务次数"
|
|
|
v-if="columns[6].visible"
|
|
|
@@ -326,7 +324,7 @@
|
|
|
<el-button
|
|
|
size="mini"
|
|
|
type="text"
|
|
|
- icon="el-icon-arrow-down"
|
|
|
+ icon="el-icon-top-left"
|
|
|
v-if="chehui(r.row)"
|
|
|
@click="chhuile(r.row)"
|
|
|
v-hasPermi="['core:checkplan:distribute']"
|
|
|
@@ -469,8 +467,8 @@ export default {
|
|
|
(row.planOfOrgType == 3 &&
|
|
|
row.planStatus != 1 &&
|
|
|
row.planCreateOrgId == this.orgId) ||
|
|
|
- (row.planStatus == 2 && row.parentId != -1 && row.planOfOrgType == 1)||
|
|
|
- (row.planStatus != 1&&(row.execOrgType == 1||row.execOrgType == 2))
|
|
|
+ (row.planStatus == 2 && row.parentId != -1 && row.planOfOrgType == 1) ||
|
|
|
+ (row.planStatus != 1 && (row.execOrgType == 1 || row.execOrgType == 2))
|
|
|
) {
|
|
|
return true;
|
|
|
}
|
|
|
@@ -573,11 +571,21 @@ export default {
|
|
|
},
|
|
|
//开始撤回
|
|
|
chhuile(row) {
|
|
|
- this.loading = true;
|
|
|
- api.cheHui(row.id).then((response) => {
|
|
|
- this.getList();
|
|
|
- this.loading = false;
|
|
|
- });
|
|
|
+ this.$modal
|
|
|
+ .confirm("撤回计划会清除本周期所有任务!", "提示")
|
|
|
+ .then(() => {
|
|
|
+ // 用户点击了确认按钮
|
|
|
+ // console.log("执行操作...");
|
|
|
+ this.loading = true;
|
|
|
+ api.cheHui(row.id).then((response) => {
|
|
|
+ this.getList();
|
|
|
+ this.loading = false;
|
|
|
+ });
|
|
|
+ })
|
|
|
+ .catch(() => {
|
|
|
+ // 用户点击了取消按钮
|
|
|
+ // console.log("取消操作...");
|
|
|
+ });
|
|
|
},
|
|
|
//已下发的显示撤回
|
|
|
chehui(row) {
|
|
|
@@ -595,7 +603,7 @@ export default {
|
|
|
.confirm('是否确认删除名称为"' + name + '"的数据项?')
|
|
|
.then(() => {
|
|
|
// 用户点击了确认按钮
|
|
|
- console.log("执行操作...");
|
|
|
+ // console.log("执行操作...");
|
|
|
this.loading = true;
|
|
|
api
|
|
|
.delelte(id)
|
|
|
@@ -610,7 +618,7 @@ export default {
|
|
|
})
|
|
|
.catch(() => {
|
|
|
// 用户点击了取消按钮
|
|
|
- console.log("取消操作...");
|
|
|
+ // console.log("取消操作...");
|
|
|
});
|
|
|
},
|
|
|
// 多选框选中数据
|