Explorar o código

增加旗县角色功能开发

dylan %!s(int64=2) %!d(string=hai) anos
pai
achega
8a66bb0fbb

+ 6 - 0
api/home.js

@@ -131,6 +131,11 @@ const orgAdminNavButton = [false, true, true, true, true, true, true, true, true
 	false, false, false
 ];
 
+const qiAdminNavButton = [false, true, true, true, true, true, true, true, true, false, false, false, false, false,
+	false, false, false
+];
+
+
 //获取运维公司管理员导航按钮
 const companyAdminNavButton = [true, true, true, true, true, true, true, false, false, true, true, true, false, false,
 	false, false, false
@@ -153,6 +158,7 @@ export default {
 	yjNavButtons,
 	sysAdminNavButton,
 	orgAdminNavButton,
+	qiAdminNavButton,
 	companyAdminNavButton,
 	companyServicePersonNavButton,
 	yjAdminNavButton,

+ 35 - 18
pages-yj/yjxt/resident/dangerarearesidentrecordlist.vue

@@ -28,15 +28,15 @@
 		</uni-collapse>
 		<view v-if="showSearch" class="search-block">
 			<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"
 						placeholder="请选择盟市"></uni-data-select>
 				</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"
 						@change="districtRegionChange" placeholder="请选择区旗县"></uni-data-select>
 				</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"
 						placeholder="请选择乡镇"></uni-data-select>
 				</view>
@@ -116,6 +116,9 @@
 </template>
 
 <script>
+	import {
+		role
+	} from "@/api/role.js";
 	import http from '@/http/api.js';
 	export default {
 		components: {},
@@ -125,10 +128,10 @@
 				permission: {
 					'admin': false,
 					'orgAdmin': false,
+					'qiAdmin': false,
 					'companyAdmin': false,
 					'companyServciePerson': false,
-					'yjServicePerson': false,
-					'qiAdmin': false,
+					'yjServicePerson': false
 				},
 				showSearch: true,
 				cityRegionValue: '',
@@ -171,20 +174,26 @@
 			} else if (this.userInfo.role_name === role.yjServicePerson) {
 				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['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();
 		},
 		onShow() {
@@ -244,7 +253,11 @@
 					this.dangerAreaValue = '';
 					this.pageCurrent = 1;
 					this.list = [];
-					this.query['dangerAreaCode'] = this.cityRegionValue;
+					if (this.permission.admin) {
+						this.query['dangerAreaCode'] = this.cityRegionValue;
+					} else {
+						this.query = {};
+					}
 					this.getPage({});
 				} else {
 					this.districtRegionValue = e;
@@ -273,7 +286,11 @@
 					this.dangerAreaValue = '';
 					this.pageCurrent = 1;
 					this.list = [];
-					this.query['dangerAreaCode'] = this.districtRegionValue;
+					if (this.permission.admin || this.permission.orgAdmin) {
+						this.query['dangerAreaCode'] = this.districtRegionValue;
+					} else {
+						this.query = {};
+					}
 					this.getPage({});
 				} else {
 					this.townRegionValue = e;

+ 12 - 34
pages-yj/yjxt/warn/yjwarndetail.vue

@@ -22,10 +22,12 @@
 								<template v-slot:body>
 									<view class="list-item-block">
 										<view class="line">
-											<view class="text">责任人:<span style="color: deepskyblue;"></span></view>
+											<view class="text">责任人:<span
+													style="color: deepskyblue;">{{item.pcaName}}</span></view>
 										</view>
 										<view class="line">
-											<view class="text">责任人类型:<span style="color: deepskyblue;"></span></view>
+											<view class="text">责任人类型:<span
+													style="color: deepskyblue;">{{item.commType}}</span></view>
 										</view>
 										<view class="line">
 											<view class="text">反馈情况:<span
@@ -38,15 +40,15 @@
 										<!-- 	<view>反馈内容:<span style="color: skyblue;"></span></view> -->
 										<view class="line">
 											<view class="text">是否收到预警短信:<span
-													style="color: deepskyblue;">{{item.isReceive}}</span></view>
+													style="color: deepskyblue;">{{item.dxjs}}</span></view>
 										</view>
 										<view class="line">
-											<view class="text">是否发生沟道山洪:<span
-													style="color: deepskyblue;">{{item.isFloodBoot}}</span></view>
+											<view class="text">是否发生山洪:<span
+													style="color: deepskyblue;">{{item.gdsh}}</span></view>
 										</view>
 										<view class="line">
-											<view class="text">山洪是否出沟:<span
-													style="color: deepskyblue;">{{item.isFloodOut}}</span></view>
+											<view class="text">山洪是否已进村:<span
+													style="color: deepskyblue;">{{item.sfcg}}</span></view>
 										</view>
 										<view class="line">
 											<view class="text">降雨是否持续:<span
@@ -54,11 +56,11 @@
 										</view>
 										<view class="line">
 											<view class="text">是否人员转移:<span
-													style="color: deepskyblue;">{{item.isTrans}}</span></view>
+													style="color: deepskyblue;">{{item.ryzy}}</span></view>
 										</view>
 										<view class="line">
 											<view class="text">有无人员伤亡:<span
-													style="color: deepskyblue;">{{item.isDeady}}</span></view>
+													style="color: deepskyblue;">{{item.rysw}}</span></view>
 										</view>
 									</view>
 								</template>
@@ -208,35 +210,10 @@
 				</view>
 			</view>
 		</view>
-		<!-- 		<uni-card title="预警信息" :is-shadow="false">
-			<view>预警名称:<span style="color: skyblue;">{{formData.warnName}}</span></view>
-			<view>预警时间:<span style="color: skyblue;">{{formData.warnTime}}</span></view>
-			<view>预警状态:<span style="color: skyblue;">{{formData.warnStatusText}}</span></view>
-			<view>审核状态:<span style="color: skyblue;">{{formData.reviewStatusText}}</span></view>
-			<view>预警信息:<span style="color: skyblue;">{{formData.warnInfo}}</span></view>
-			<view>预警政区:<span style="color: skyblue;">{{formData.warnAdcd}}</span></view>
-			<view>预警点经纬度:<span style="color: skyblue;">{{formData.warnLgtd}},{{formData.warnLttd}}</span></view>
-		</uni-card>
-		<uni-card title="站点信息" :is-shadow="false">
-			<view>测站编码:<span style="color: skyblue;">{{formData.stcd}}</span></view>
-			<view>站类:<span style="color: skyblue;">{{formData.typeText}}</span></view>
-			<view>雨量站预警频率:<span style="color: skyblue;">{{formData.rainWarnRateText}}</span></view>
-			<view>降雨时段:<span style="color: skyblue;">{{formData.intv}}</span></view>
-			<view>降雨总量:<span style="color: skyblue;">{{formData.drp}}</span></view>
-			<view v-if="formData.z">河道水位:<span style="color: skyblue;">{{formData.z}}</span></view>
-			<view v-if="formData.q">河道流量:<span style="color: skyblue;">{{formData.q}}</span></view>
-			<view v-if="formData.wptn">河道水势:<span style="color: skyblue;">{{formData.wptn}}</span></view>
-			<view v-if="formData.rz">水库水位:<span style="color: skyblue;">{{formData.rz}}</span></view>
-			<view v-if="formData.rwptn">水库水势:<span style="color: skyblue;">{{formData.rwptn}}</span></view>
-			<view v-if="formData.inq">水库流量:<span style="color: skyblue;">{{formData.inq}}</span></view>
-		</uni-card> -->
 	</view>
 </template>
 
 <script>
-	// import {
-	// 	role
-	// } from "@/api/role.js";
 	import http from '@/http/api.js';
 	export default {
 		data() {
@@ -268,6 +245,7 @@
 				}).then(res => {
 					if (res && res.success) {
 						that.data = res.data;
+
 					}
 				}).catch(err => {
 					console.log(JOSN.stringify(err))

+ 2 - 1
pages/check-order/checkorderlist.vue

@@ -433,7 +433,7 @@
 			onCheckOrderChangeClick(item) {
 				let contactUserName = '无';
 				if (item.orderConfirm == 1) {
-					contactUserName = item.contactUserName;
+					contactUserName = item.processorName;
 				}
 				let url = '/pages/check-order/orderprocesschange?orderId=' + item.id + "&contactUserName=" +
 					contactUserName;
@@ -553,6 +553,7 @@
 					},
 					data: postData,
 				}).then(res => {
+					console.log(JSON.stringify(res.data))
 					if (res.data.records != null) {
 						that.list = res.data.records;
 					}

+ 8 - 15
pages/check-order/orderprocesschange.vue

@@ -36,8 +36,6 @@
 
 <script>
 	import http from '@/http/api.js';
-
-
 	export default {
 		components: {
 
@@ -57,27 +55,22 @@
 				desc: '',
 			}
 		},
-		computed: {
-		},
-		onShow() {
-		},
-		created() {
-		},
+		computed: {},
+		onShow() {},
+		created() {},
 		methods: {
 			toBack() {
 				uni.navigateBack({
 					delta: 1
 				})
 			},
-			selectChange(e) {
-			},
+			selectChange(e) {},
 			getServicePersonList() {
 				let that = this;
 				http.request({
-					url: '/galaxy-business/serviceperson/list',
+					url: '/galaxy-business/serviceperson/yw/list',
 					method: 'GET',
 				}).then(res => {
-					//console.log("list " + JSON.stringify(res))
 					if (res.success) {
 						let persons = res.data.map(function(item) {
 							let person = {};
@@ -95,8 +88,8 @@
 				let that = this;
 				var postData = {};
 				postData['id'] = '' + this.orderId;
-				postData['servicePersonId'] = '' + this.selectedPersonId;
-				//console.log(postData)
+				postData['servicePersonId'] =  this.selectedPersonId;
+				
 				http.request({
 					url: '/galaxy-business/rtu/check/order/change',
 					method: 'POST',
@@ -137,4 +130,4 @@
 
 <style lang="scss" scoped>
 
-</style>
+</style>

+ 8 - 1
pages/home/home.vue

@@ -28,7 +28,7 @@
 			</block>
 		</uni-nav-bar>
 		<!-- 菜单切换 -->
-		<uni-swipe-action v-if="permission.admin || permission.orgAdmin" ref="swipeAction">
+		<uni-swipe-action v-if="permission.admin || permission.orgAdmin || permission.qiAdmin" ref="swipeAction">
 			<uni-swipe-action-item :right-options="systemOptions" :show="swipeStatus" :auto-close="false"
 				@change="swipeChange" @click="swipeBindClick">
 				<view class="view-flex-block-center" style="height: 50px;width: 100%;background-color: aliceblue;"
@@ -653,6 +653,7 @@
 				permission: {
 					'admin': false,
 					'orgAdmin': false,
+					'qiAdmin': false,
 					'companyAdmin': false,
 					'companyServciePerson': false,
 					'yjServicePerson': false,
@@ -726,6 +727,7 @@
 		onLoad() {
 			this.permission.admin = false;
 			this.permission.orgAdmin = false;
+			this.permission.qiAdmin = false;
 			this.permission.companyAdmin = false;
 			this.permission.companyServciePerson = false;
 			this.permission.yjServicePerson = false;
@@ -741,6 +743,11 @@
 				this.currentRole = role.orgAdmin;
 				this.navButtonIndex = navBtns.orgAdminNavButton;
 				this.yjNavButtonIndex = navBtns.yjAdminNavButton;
+			} else if (this.userInfo.role_name === role.qiAdmin) {
+				this.permission.qiAdmin = true;
+				this.currentRole = role.qiAdmin;
+				this.navButtonIndex = navBtns.qiAdminNavButton;
+				this.yjNavButtonIndex = navBtns.yjAdminNavButton;
 			} else if (this.userInfo.role_name === role.companyAdmin) {
 				this.permission.companyAdmin = true;
 				this.currentRole = role.companyAdmin;