|
|
@@ -86,12 +86,12 @@
|
|
|
<span>{{ parseTime(scope.row.createTime) }}</span>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
-
|
|
|
+
|
|
|
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
|
|
<template slot-scope="scope">
|
|
|
|
|
|
<router-link :to="'/system/dept-extend/extend/'+ scope.row.id " class="link-type">
|
|
|
-
|
|
|
+
|
|
|
<el-button
|
|
|
size="mini"
|
|
|
type="text"
|
|
|
@@ -139,7 +139,7 @@
|
|
|
<el-dialog :title="title" :visible.sync="open" width="600px" append-to-body>
|
|
|
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
|
|
|
<el-row>
|
|
|
- <el-col :span="24" v-if="form.parentId > 0">
|
|
|
+ <el-col :span="24">
|
|
|
<el-form-item label="上级机构" prop="parentId">
|
|
|
<treeselect v-model="form.parentId" :options="deptOptions" :normalizer="normalizer" placeholder="选择上级机构" />
|
|
|
</el-form-item>
|
|
|
@@ -296,15 +296,6 @@ export default {
|
|
|
changeCheckBox(){
|
|
|
this.getList();
|
|
|
},
|
|
|
- /** 查询机构列表 */
|
|
|
- getList() {
|
|
|
- this.loading = true;
|
|
|
- listDept(this.queryParams).then(response => {
|
|
|
- this.deptList = response.rows;
|
|
|
- this.total = response.total;
|
|
|
- this.loading = false;
|
|
|
- });
|
|
|
- },
|
|
|
/** 查询机构下拉树结构 */
|
|
|
getDeptTree() {
|
|
|
deptTreeSelect().then(response => {
|
|
|
@@ -329,7 +320,6 @@ export default {
|
|
|
getList() {
|
|
|
this.loading = true;
|
|
|
listDept(this.queryParams).then(response => {
|
|
|
- // this.deptList = this.handleTree(response.data, "id");
|
|
|
this.deptList = response.rows;
|
|
|
this.total = response.total;
|
|
|
this.loading = false;
|
|
|
@@ -377,14 +367,12 @@ export default {
|
|
|
/** 新增按钮操作 */
|
|
|
handleAdd(row) {
|
|
|
this.reset();
|
|
|
- if (row != undefined) {
|
|
|
- this.form.parentId = row.id;
|
|
|
+ if (this.queryParams.parentId != undefined) {
|
|
|
+ this.form.parentId = this.queryParams.parentId;
|
|
|
}
|
|
|
this.open = true;
|
|
|
this.title = "添加机构";
|
|
|
- listDept().then(response => {
|
|
|
- this.deptOptions = this.handleTree(response.data, "id");
|
|
|
- });
|
|
|
+
|
|
|
},
|
|
|
/** 展开/折叠操作 */
|
|
|
toggleExpandAll() {
|