|
@@ -12,7 +12,7 @@
|
|
|
:config="table_config"
|
|
|
:loading="table_loading"
|
|
|
:handle-row="table_handle_row"
|
|
|
- @issue="handleVisible('issue')"
|
|
|
+ @issue="(params) => handleVisible('issue', params)"
|
|
|
@detail="handleVisible('template')"
|
|
|
@delete="handleDelete"
|
|
|
></simple-table>
|
|
@@ -51,27 +51,17 @@
|
|
|
@confirm="handleIssue"
|
|
|
:visible="issue_visible"
|
|
|
>
|
|
|
- <el-form label-width="100px" :model="form">
|
|
|
+ <el-form label-width="100px" :model="issue_form">
|
|
|
<el-form-item label="填报事由">
|
|
|
- <el-input v-model="form.reason"></el-input>
|
|
|
+ <el-input v-model="issue_form.reason"></el-input>
|
|
|
</el-form-item>
|
|
|
<el-form-item label="填报注意事项">
|
|
|
- <el-input v-model="form.note"></el-input>
|
|
|
+ <el-input v-model="issue_form.precautions"></el-input>
|
|
|
</el-form-item>
|
|
|
<el-form-item label="截止时间">
|
|
|
- <el-date-picker v-model="form.date" type="date">
|
|
|
+ <el-date-picker v-model="issue_form.endTime" type="date">
|
|
|
</el-date-picker>
|
|
|
</el-form-item>
|
|
|
- <el-form-item label="">
|
|
|
- <el-upload
|
|
|
- drag
|
|
|
- action="https://jsonplaceholder.typicode.com/posts/"
|
|
|
- multiple
|
|
|
- >
|
|
|
- <i class="el-icon-upload"></i>
|
|
|
- <div>上传附件</div>
|
|
|
- </el-upload>
|
|
|
- </el-form-item>
|
|
|
</el-form>
|
|
|
</simple-dialog>
|
|
|
<simple-dialog
|
|
@@ -83,64 +73,10 @@
|
|
|
@confirm="handleVisible('add')"
|
|
|
@cancel="handleVisible('add')"
|
|
|
>
|
|
|
- <el-form inline :model="form" label-width="100px">
|
|
|
- <el-form-item label="绩效类型">
|
|
|
- <el-select v-model="form.type">
|
|
|
- <el-option label="部门绩效" value="部门绩效"></el-option
|
|
|
- ><el-option
|
|
|
- label="员工绩效"
|
|
|
- value="员工绩效"
|
|
|
- ></el-option> </el-select
|
|
|
- ></el-form-item>
|
|
|
- <el-form-item label="绩效分类">
|
|
|
- <el-select v-model="form.class">
|
|
|
- <el-option label="GS" value="GS"></el-option
|
|
|
- ><el-option
|
|
|
- label="KPI"
|
|
|
- value="KPI"
|
|
|
- ></el-option> </el-select
|
|
|
- ></el-form-item>
|
|
|
- <el-form-item label="">
|
|
|
- <el-button type="primary" @click="handleVisible('power')"
|
|
|
- >权限设置</el-button
|
|
|
- >
|
|
|
- </el-form-item>
|
|
|
- </el-form>
|
|
|
+ <el-form inline :model="form" label-width="100px"> </el-form>
|
|
|
<simple-sheet />
|
|
|
<template v-slot:footer><div></div></template>
|
|
|
</simple-dialog>
|
|
|
- <simple-dialog
|
|
|
- title="权限设置"
|
|
|
- :visible="power_visible"
|
|
|
- :reload="reload"
|
|
|
- width="700px"
|
|
|
- @confirm="handleVisible('power')"
|
|
|
- @cancel="handleVisible('power')"
|
|
|
- >
|
|
|
- <el-form :model="form" label-width="100px">
|
|
|
- <el-form-item label="可编辑列"
|
|
|
- ><el-input v-model="form.editrows"
|
|
|
- /></el-form-item>
|
|
|
- <el-form-item label="权限规则">
|
|
|
- <el-select v-model="form.rule">
|
|
|
- <el-option
|
|
|
- v-for="item in ruleoptions"
|
|
|
- :key="item.value"
|
|
|
- :label="item.label"
|
|
|
- :value="item.value"
|
|
|
- ></el-option> </el-select
|
|
|
- ></el-form-item>
|
|
|
- <el-form-item label="负责人">
|
|
|
- <div>
|
|
|
- <el-cascader-panel
|
|
|
- v-model="form.charge"
|
|
|
- :options="charge_options"
|
|
|
- clearable
|
|
|
- @change="handleCascader"
|
|
|
- ></el-cascader-panel></div
|
|
|
- ></el-form-item>
|
|
|
- </el-form>
|
|
|
- </simple-dialog>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
@@ -167,47 +103,19 @@ export default {
|
|
|
total: 0,
|
|
|
form: {},
|
|
|
reload: 0,
|
|
|
- ruleoptions: [
|
|
|
- {
|
|
|
- value: "按行号",
|
|
|
- label: "按行号",
|
|
|
- },
|
|
|
- {
|
|
|
- value: "按科室分配",
|
|
|
- label: "按科室分配",
|
|
|
- },
|
|
|
- {
|
|
|
- value: "按负责人分配",
|
|
|
- label: "按负责人分配",
|
|
|
- },
|
|
|
- {
|
|
|
- value: "所有人员",
|
|
|
- label: "",
|
|
|
- },
|
|
|
- ],
|
|
|
- charge_options: [
|
|
|
- {
|
|
|
- label: "科室名称1",
|
|
|
- value: "科室名称1",
|
|
|
- children: [
|
|
|
- {
|
|
|
- label: "负责人",
|
|
|
- value: "负责人",
|
|
|
- children: [{ label: "尹强", value: "尹强" }],
|
|
|
- },
|
|
|
- ],
|
|
|
- },
|
|
|
- ],
|
|
|
add_visible: false,
|
|
|
- power_visible: false,
|
|
|
template_visible: false,
|
|
|
+ // issue
|
|
|
issue_visible: false,
|
|
|
+ issue_form: {},
|
|
|
+ issue_id: null,
|
|
|
+ // table
|
|
|
table_loading: false,
|
|
|
table_search: {},
|
|
|
table_form: [
|
|
|
{
|
|
|
label: "模板名称",
|
|
|
- props: "template_name",
|
|
|
+ props: "templateName",
|
|
|
type: "input",
|
|
|
},
|
|
|
],
|
|
@@ -236,15 +144,15 @@ export default {
|
|
|
table_config: [
|
|
|
{
|
|
|
label: "模板名称",
|
|
|
- props: "template_name",
|
|
|
+ props: "templateName",
|
|
|
},
|
|
|
{
|
|
|
label: "配置时间",
|
|
|
- props: "template_date",
|
|
|
+ props: "updateTime",
|
|
|
},
|
|
|
{
|
|
|
- label: "配置工号",
|
|
|
- props: "template_number",
|
|
|
+ label: "配置人员",
|
|
|
+ props: "createId",
|
|
|
},
|
|
|
{
|
|
|
label: "模板分类",
|
|
@@ -252,11 +160,12 @@ export default {
|
|
|
},
|
|
|
{
|
|
|
label: "模板状态",
|
|
|
- props: "template_status",
|
|
|
- },
|
|
|
- {
|
|
|
- label: "模板类型",
|
|
|
- props: "template_type",
|
|
|
+ props: "status",
|
|
|
+ type: "dictionary",
|
|
|
+ dictionary: {
|
|
|
+ 0: "在用",
|
|
|
+ 1: "停用",
|
|
|
+ },
|
|
|
},
|
|
|
],
|
|
|
};
|
|
@@ -264,82 +173,86 @@ export default {
|
|
|
methods: {
|
|
|
async handleInit() {
|
|
|
this.table_loading = true;
|
|
|
- const data = [];
|
|
|
- let index = 0;
|
|
|
- while (index < 1) {
|
|
|
- data.push(...JSON.parse(sessionStorage.global_data));
|
|
|
- index = index + 1;
|
|
|
- }
|
|
|
- this.total = index;
|
|
|
- this.table_list = data;
|
|
|
- this.table_loading = false;
|
|
|
+ this.$http({
|
|
|
+ url: "/market/CMKFileTemplate/CMKFileTemplateList",
|
|
|
+ method: "post",
|
|
|
+ headers: {
|
|
|
+ "Content-Type": "application/json",
|
|
|
+ },
|
|
|
+ data: {
|
|
|
+ page: this.page,
|
|
|
+ pageSize: this.rows,
|
|
|
+ templateName: this.table_search.templateName,
|
|
|
+ },
|
|
|
+ }).then(({ data: { count, data } }) => {
|
|
|
+ this.total = count;
|
|
|
+ this.table_list = data;
|
|
|
+ this.table_loading = false;
|
|
|
+ });
|
|
|
},
|
|
|
- handleSearch({ template_name }) {
|
|
|
- this.table_search = { template_name };
|
|
|
+ handleSearch({ templateName }) {
|
|
|
+ this.table_search = { templateName };
|
|
|
this.handleReset();
|
|
|
this.handleInit();
|
|
|
},
|
|
|
handleAdd() {},
|
|
|
- // 级联选择
|
|
|
- handleCascader(data) {
|
|
|
- console.log(data, "data");
|
|
|
- },
|
|
|
- handlePower() {},
|
|
|
handleChange(page) {
|
|
|
this.page = page;
|
|
|
this.handleInit();
|
|
|
},
|
|
|
- handleVisible(props) {
|
|
|
+ handleVisible(props, params) {
|
|
|
switch (props) {
|
|
|
case "add":
|
|
|
this.add_visible = !this.add_visible;
|
|
|
break;
|
|
|
- case "power":
|
|
|
- this.power_visible = !this.power_visible;
|
|
|
- break;
|
|
|
case "template":
|
|
|
this.template_visible = !this.template_visible;
|
|
|
break;
|
|
|
case "issue":
|
|
|
this.issue_visible = !this.issue_visible;
|
|
|
+ this.issue_id = params?.id;
|
|
|
break;
|
|
|
}
|
|
|
},
|
|
|
handleReset() {
|
|
|
this.page = 1;
|
|
|
},
|
|
|
- handleDelete() {
|
|
|
- sessionStorage.setItem("global_data", JSON.stringify([]));
|
|
|
- sessionStorage.setItem("global_process", JSON.stringify([]));
|
|
|
- this.$message.success("删除成功");
|
|
|
- this.handleInit();
|
|
|
+ handleDelete({ id }) {
|
|
|
+ this.$http({
|
|
|
+ url: "/market/CMKFileTemplate/delCMKFileTemplateById",
|
|
|
+ method: "post",
|
|
|
+ headers: {
|
|
|
+ "Content-Type": "application/json",
|
|
|
+ },
|
|
|
+ data: {
|
|
|
+ templateId: id,
|
|
|
+ },
|
|
|
+ }).then(() => {
|
|
|
+ this.$message.success("删除成功");
|
|
|
+ this.handleInit();
|
|
|
+ });
|
|
|
},
|
|
|
handleIssue() {
|
|
|
- const array = [
|
|
|
- {
|
|
|
- ...JSON.parse(sessionStorage.global_data)[0],
|
|
|
- department_status: "待处理",
|
|
|
- issue_status: 1,
|
|
|
- performance_type: "GS",
|
|
|
- reason: this.form.reason,
|
|
|
- note: this.form.note,
|
|
|
- date: this.form.date,
|
|
|
- receiver: `刘洁,李方岩,吴磊,孙震,赵洪松,孙川,韦琳娜`,
|
|
|
+ this.$http({
|
|
|
+ url: "/market/CMKFileTemplate/issuedCMKFileTemplateById",
|
|
|
+ method: "post",
|
|
|
+ headers: {
|
|
|
+ "Content-Type": "application/json",
|
|
|
},
|
|
|
- ];
|
|
|
- sessionStorage.setItem("global_data", JSON.stringify(array));
|
|
|
- const process_array = JSON.parse(sessionStorage.global_process);
|
|
|
- process_array.push({
|
|
|
- link: "发起工单",
|
|
|
- creatperson: `ADMIN ${this.$formatDate(new Date(), "YYYY-MM-DD")}`,
|
|
|
- explain: "",
|
|
|
+ data: {
|
|
|
+ ...this.issue_form,
|
|
|
+ endTime: this.$formatDate(
|
|
|
+ this.issue_form.endTime,
|
|
|
+ "YYYY-MM-DD"
|
|
|
+ ),
|
|
|
+ templateId: this.issue_id,
|
|
|
+ },
|
|
|
+ }).then(() => {
|
|
|
+ this.handleVisible("issue");
|
|
|
+ this.$message.success("下发成功");
|
|
|
+
|
|
|
+ this.handleInit();
|
|
|
});
|
|
|
- sessionStorage.setItem(
|
|
|
- "global_process",
|
|
|
- JSON.stringify(process_array)
|
|
|
- );
|
|
|
- this.$message.success("下发成功");
|
|
|
- this.handleVisible("issue");
|
|
|
},
|
|
|
},
|
|
|
mounted() {
|