|
@@ -50,7 +50,7 @@
|
|
|
|
|
|
<el-table v-loading="loading" :data="principalList" @selection-change="handleSelectionChange" :height="clientHeight" border>
|
|
|
<el-table-column type="selection" width="55" align="center" />
|
|
|
- <el-table-column :label="$t('装置名称')" align="center" prop="plantCode" :formatter="plantCodeFormat" />
|
|
|
+ <el-table-column :label="$t('部门名称')" align="center" prop="deptName" />
|
|
|
<el-table-column :label="$t('负责人姓名')" align="center" prop="principalName" :show-overflow-tooltip="true"/>
|
|
|
<el-table-column :label="$t('负责人邮箱')" align="center" prop="principalEmail" :show-overflow-tooltip="true"/>
|
|
|
<el-table-column :label="$t('操作')" align="center" fixed="right" width="120" class-name="small-padding fixed-width">
|
|
@@ -84,24 +84,17 @@
|
|
|
<!-- 添加或修改预警管理负责人对话框 -->
|
|
|
<el-dialog v-dialogDrag :title="title" :visible.sync="open" width="500px" append-to-body>
|
|
|
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
|
|
|
- <el-form-item :label="$t('装置名称')" prop="plantCode">
|
|
|
- <el-select v-model="form.plantCode" :placeholder="$t('请选择') + $t('装置名称')">
|
|
|
- <el-option
|
|
|
- v-for="dict in plantCodeOptions"
|
|
|
- :key="dict.dictValue"
|
|
|
- :label="dict.dictLabel"
|
|
|
- :value="dict.dictValue"
|
|
|
- ></el-option>
|
|
|
- </el-select>
|
|
|
+ <el-form-item :label="$t('归属部门')" prop="deptId">
|
|
|
+ <treeselect v-model="form.deptId" :options="deptOptions" :show-count="true" :placeholder="$t('请选择') + $t('归属部门')" />
|
|
|
</el-form-item>
|
|
|
<el-form-item :label="$t('负责人姓名')" prop="principalName">
|
|
|
- <el-select v-model="form.staffid" filterable :placeholder="$t('请选择') + $t('负责人姓名')" @change="pricipalChange($event)">
|
|
|
+ <el-select v-model="form.staffid" filterable :placeholder="$t('请选择') + $t('负责人姓名')" filterable @change="pricipalChange($event)">
|
|
|
<el-option
|
|
|
v-for="dict in stffmgrOptions"
|
|
|
- :key="dict.staffid"
|
|
|
- :label="dict.name"
|
|
|
- :value="dict.staffid">
|
|
|
- <span style="float: left">{{ dict.name }}</span>
|
|
|
+ :key="dict.userId"
|
|
|
+ :label="dict.nickName"
|
|
|
+ :value="dict.staffId">
|
|
|
+ <span style="float: left">{{ dict.nickName }}</span>
|
|
|
<span style="float: right; color: #8492a6; font-size: 13px">{{ dict.staffid }}</span>
|
|
|
</el-option>
|
|
|
</el-select>
|
|
@@ -128,6 +121,7 @@ import { treeselect } from "@/api/system/dept";
|
|
|
import { getToken } from "@/utils/auth";
|
|
|
import Treeselect from "@riophae/vue-treeselect";
|
|
|
import "@riophae/vue-treeselect/dist/vue-treeselect.css";
|
|
|
+import {listPostUser} from "@/api/system/user";
|
|
|
|
|
|
export default {
|
|
|
name: "Principal",
|
|
@@ -243,8 +237,11 @@ export default {
|
|
|
},
|
|
|
//获取人员表
|
|
|
getStaffmar() {
|
|
|
- listStaffmgr(this.staffmgrQueryParams).then(response => {
|
|
|
- this.stffmgrOptions = response.rows;
|
|
|
+ // listStaffmgr(this.staffmgrQueryParams).then(response => {
|
|
|
+ // this.stffmgrOptions = response.rows;
|
|
|
+ // });
|
|
|
+ listPostUser(this.queryParams).then(response => {
|
|
|
+ this.stffmgrOptions = response;
|
|
|
});
|
|
|
},
|
|
|
// 取消按钮
|
|
@@ -267,7 +264,8 @@ export default {
|
|
|
updaterCode: null,
|
|
|
updatedate: null,
|
|
|
deptId: null,
|
|
|
- remarks: null
|
|
|
+ remarks: null,
|
|
|
+ name: null
|
|
|
};
|
|
|
this.resetForm("form");
|
|
|
},
|
|
@@ -275,9 +273,10 @@ export default {
|
|
|
pricipalChange(val) {
|
|
|
let _this = this
|
|
|
this.staffmgrQueryParams.staffid = val
|
|
|
+ console.log(val)
|
|
|
this.stffmgrOptions.forEach(function (item, index) {
|
|
|
- if (item.staffid == val) {
|
|
|
- _this.stffmgrEmail = item.mail
|
|
|
+ if (item.staffId == val) {
|
|
|
+ _this.stffmgrEmail = item.email
|
|
|
}
|
|
|
})
|
|
|
},
|