|
@@ -1,7 +1,6 @@
|
|
|
<template>
|
|
|
<div class="app-container">
|
|
|
- <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="100px"
|
|
|
- @submit.native.prevent>
|
|
|
+ <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" @submit.native.prevent>
|
|
|
<el-form-item label="项目名称" prop="projectName">
|
|
|
<el-input
|
|
|
v-model="queryParams.projectName"
|
|
@@ -31,6 +30,15 @@
|
|
|
></el-option>
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
+ <el-form-item prop="deptId">
|
|
|
+ <template slot="label">
|
|
|
+ <span @click="changeQueryType" v-if="queryParams.deptName === 0">本级及下级</span>
|
|
|
+ <span @click="changeQueryType" v-if="queryParams.deptName === 1">只查询本级</span>
|
|
|
+ </template>
|
|
|
+ <treeselect v-model="queryParams.deptId" :options="deptOptions" multiple:false :show-count="true"
|
|
|
+ placeholder="请选择部门" @select="hx" :noResultsText="'空'" :noOptionsText="'空'" style="width: 240px"/>
|
|
|
+ <el-input v-model="queryParams.deptName" v-if="false"/>
|
|
|
+ </el-form-item>
|
|
|
<el-form-item>
|
|
|
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
|
|
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
|
@@ -718,6 +726,7 @@ export default {
|
|
|
latitude: null,
|
|
|
cameraSystem: null,
|
|
|
deptId: null,
|
|
|
+ deptName: 0,
|
|
|
introduction: null,
|
|
|
parkLongitude: null,
|
|
|
parkLatitude: null,
|
|
@@ -1031,9 +1040,14 @@ export default {
|
|
|
},
|
|
|
/** 重置按钮操作 */
|
|
|
resetQuery() {
|
|
|
+ this.queryParams.deptName = 0;
|
|
|
this.resetForm("queryForm");
|
|
|
this.handleQuery();
|
|
|
},
|
|
|
+ // 点击按钮修改是否只查询本级部门用户
|
|
|
+ changeQueryType() {
|
|
|
+ this.queryParams.deptName = this.queryParams.deptName === 0 ? 1 : 0;
|
|
|
+ },
|
|
|
resetHistoryQuery() {
|
|
|
this.resetForm("historyForm");
|
|
|
this.handleHistoryQuery();
|