|
@@ -28,15 +28,15 @@
|
|
|
</uni-collapse>
|
|
</uni-collapse>
|
|
|
<view v-if="showSearch" class="search-block">
|
|
<view v-if="showSearch" class="search-block">
|
|
|
<view style="padding-left: 10px;padding-right: 10px;margin-top: 10px;">
|
|
<view style="padding-left: 10px;padding-right: 10px;margin-top: 10px;">
|
|
|
- <view>
|
|
|
|
|
|
|
+ <view v-if="permission.admin">
|
|
|
<uni-data-select v-model="cityRegionValue" :localdata="cityRegionData" @change="cityRegionChange"
|
|
<uni-data-select v-model="cityRegionValue" :localdata="cityRegionData" @change="cityRegionChange"
|
|
|
placeholder="请选择盟市"></uni-data-select>
|
|
placeholder="请选择盟市"></uni-data-select>
|
|
|
</view>
|
|
</view>
|
|
|
- <view style="margin-top: 10px;">
|
|
|
|
|
|
|
+ <view v-if="permission.admin || permission.orgAdmin" style="margin-top: 10px;">
|
|
|
<uni-data-select v-model="districtRegionValue" :localdata="districtRegionData"
|
|
<uni-data-select v-model="districtRegionValue" :localdata="districtRegionData"
|
|
|
@change="districtRegionChange" placeholder="请选择区旗县"></uni-data-select>
|
|
@change="districtRegionChange" placeholder="请选择区旗县"></uni-data-select>
|
|
|
</view>
|
|
</view>
|
|
|
- <view style="margin-top: 10px;">
|
|
|
|
|
|
|
+ <view v-if="permission.admin || permission.orgAdmin || permission.qiAdmin" style="margin-top: 10px;">
|
|
|
<uni-data-select v-model="townRegionValue" :localdata="townRegionData" @change="townRegionChange"
|
|
<uni-data-select v-model="townRegionValue" :localdata="townRegionData" @change="townRegionChange"
|
|
|
placeholder="请选择乡镇"></uni-data-select>
|
|
placeholder="请选择乡镇"></uni-data-select>
|
|
|
</view>
|
|
</view>
|
|
@@ -116,6 +116,9 @@
|
|
|
</template>
|
|
</template>
|
|
|
|
|
|
|
|
<script>
|
|
<script>
|
|
|
|
|
+ import {
|
|
|
|
|
+ role
|
|
|
|
|
+ } from "@/api/role.js";
|
|
|
import http from '@/http/api.js';
|
|
import http from '@/http/api.js';
|
|
|
export default {
|
|
export default {
|
|
|
components: {},
|
|
components: {},
|
|
@@ -125,10 +128,10 @@
|
|
|
permission: {
|
|
permission: {
|
|
|
'admin': false,
|
|
'admin': false,
|
|
|
'orgAdmin': false,
|
|
'orgAdmin': false,
|
|
|
|
|
+ 'qiAdmin': false,
|
|
|
'companyAdmin': false,
|
|
'companyAdmin': false,
|
|
|
'companyServciePerson': false,
|
|
'companyServciePerson': false,
|
|
|
- 'yjServicePerson': false,
|
|
|
|
|
- 'qiAdmin': false,
|
|
|
|
|
|
|
+ 'yjServicePerson': false
|
|
|
},
|
|
},
|
|
|
showSearch: true,
|
|
showSearch: true,
|
|
|
cityRegionValue: '',
|
|
cityRegionValue: '',
|
|
@@ -171,20 +174,26 @@
|
|
|
} else if (this.userInfo.role_name === role.yjServicePerson) {
|
|
} else if (this.userInfo.role_name === role.yjServicePerson) {
|
|
|
this.permission.yjServicePerson = true;
|
|
this.permission.yjServicePerson = true;
|
|
|
}
|
|
}
|
|
|
- if (this.subSystem == 1) {
|
|
|
|
|
- this.title = "管理工作台";
|
|
|
|
|
- this.getRegionTree();
|
|
|
|
|
- } else if (this.subSystem == 2) {
|
|
|
|
|
- this.title = "实时监测预警";
|
|
|
|
|
- this.getCityRegion({});
|
|
|
|
|
- this.$nextTick(() => {
|
|
|
|
|
- this.getYjPage({});
|
|
|
|
|
- })
|
|
|
|
|
- }
|
|
|
|
|
|
|
+ // if (this.subSystem == 1) {
|
|
|
|
|
+ // this.title = "管理工作台";
|
|
|
|
|
+ // this.getRegionTree();
|
|
|
|
|
+ // } else if (this.subSystem == 2) {
|
|
|
|
|
+ // this.title = "实时监测预警";
|
|
|
|
|
+ // this.getCityRegion({});
|
|
|
|
|
+ // this.$nextTick(() => {
|
|
|
|
|
+ // this.getYjPage({});
|
|
|
|
|
+ // })
|
|
|
|
|
+ // }
|
|
|
|
|
|
|
|
this.query = {};
|
|
this.query = {};
|
|
|
this.query['isHouseholder'] = 1;
|
|
this.query['isHouseholder'] = 1;
|
|
|
- this.getCityRegion({});
|
|
|
|
|
|
|
+ if (this.permission.admin) {
|
|
|
|
|
+ this.getCityRegion({});
|
|
|
|
|
+ } else if (this.permission.orgAdmin) {
|
|
|
|
|
+ this.getDistrictRegion({});
|
|
|
|
|
+ } else if (this.permission.qiAdmin || this.permission.yjServicePerson) {
|
|
|
|
|
+ this.getTownRegion({});
|
|
|
|
|
+ }
|
|
|
this.getPage();
|
|
this.getPage();
|
|
|
},
|
|
},
|
|
|
onShow() {
|
|
onShow() {
|
|
@@ -244,7 +253,11 @@
|
|
|
this.dangerAreaValue = '';
|
|
this.dangerAreaValue = '';
|
|
|
this.pageCurrent = 1;
|
|
this.pageCurrent = 1;
|
|
|
this.list = [];
|
|
this.list = [];
|
|
|
- this.query['dangerAreaCode'] = this.cityRegionValue;
|
|
|
|
|
|
|
+ if (this.permission.admin) {
|
|
|
|
|
+ this.query['dangerAreaCode'] = this.cityRegionValue;
|
|
|
|
|
+ } else {
|
|
|
|
|
+ this.query = {};
|
|
|
|
|
+ }
|
|
|
this.getPage({});
|
|
this.getPage({});
|
|
|
} else {
|
|
} else {
|
|
|
this.districtRegionValue = e;
|
|
this.districtRegionValue = e;
|
|
@@ -273,7 +286,11 @@
|
|
|
this.dangerAreaValue = '';
|
|
this.dangerAreaValue = '';
|
|
|
this.pageCurrent = 1;
|
|
this.pageCurrent = 1;
|
|
|
this.list = [];
|
|
this.list = [];
|
|
|
- this.query['dangerAreaCode'] = this.districtRegionValue;
|
|
|
|
|
|
|
+ if (this.permission.admin || this.permission.orgAdmin) {
|
|
|
|
|
+ this.query['dangerAreaCode'] = this.districtRegionValue;
|
|
|
|
|
+ } else {
|
|
|
|
|
+ this.query = {};
|
|
|
|
|
+ }
|
|
|
this.getPage({});
|
|
this.getPage({});
|
|
|
} else {
|
|
} else {
|
|
|
this.townRegionValue = e;
|
|
this.townRegionValue = e;
|