heyang il y a 5 mois
Parent
commit
26820c5d0b

+ 25 - 1
pages.json

@@ -197,7 +197,31 @@
 						"navigationBarTitleText": "进出详情"
 					}
 				},
-				
+				/* 分级管控 */
+				{
+					"path": "views/gradingControl/gradingControl", //分级管控
+					"style": {
+						"navigationBarTitleText": "分级管控"
+					}
+				},
+				{
+					"path": "views/gradingControl/gradingControlFinish", //分级管控-完成列表
+					"style": {
+						"navigationBarTitleText": "分级管控"
+					}
+				},
+				{
+					"path": "views/gradingControl/gradingControlAdd", //分级管控-添加
+					"style": {
+						"navigationBarTitleText": "分级管控"
+					}
+				},
+				{
+					"path": "views/gradingControl/gradingControlDetail", //分级管控-详情
+					"style": {
+						"navigationBarTitleText": "分级管控"
+					}
+				},
 				{
 					"path": "views/signature/signature",
 					"style": {

+ 43 - 32
pages/views/pupilPage/pupilHome.vue

@@ -14,6 +14,10 @@
 				<img class="button-img" src="@/pages/images/newImage/icon_sy_aqzr@1x.png">
 				<view class="button-name">安全准入</view>
 			</view>
+			<view class="button-min" @click="goPage('securityCheck')">
+				<img class="button-img" src="@/pages/images/newImage/icon_sy_aqjc@1x.png">
+				<view class="button-name">安全检查</view>
+			</view>
 			<view class="button-min" @click="goPage()">
 				<img class="button-img" src="@/pages/images/newImage/icon_sy_hxp@1x.png">
 				<view class="button-name">化学品</view>
@@ -25,15 +29,14 @@
 		</view>
 		<view class="button-two-box">
 			<view class="button-big-box" @click="goPage('snapshotPupil')"
-			style="background-color: #DFF0FF;margin-right:20rpx;">
+				style="background-color: #DFF0FF;margin-right:20rpx;">
 				<img src="@/pages/images/newImage/icon_sy_ssp@1x.png">
 				<view class="button-min-box">
 					<view>随手拍</view>
 					<view>发现隐患</view>
 				</view>
 			</view>
-			<view class="button-big-box" @click="goPage('leaveCheckPupil')"
-			style="background-color: #D6EBDA;">
+			<view class="button-big-box" @click="goPage('leaveCheckPupil')" style="background-color: #D6EBDA;">
 				<img src="@/pages/images/newImage/img_sy_lkjc@1x.png">
 				<view class="button-min-box">
 					<view>离开检查</view>
@@ -62,30 +65,31 @@
 	import {
 		tabBar
 	} from '@/pages/component/tabBar.vue'
-	import {navBar} from '@/pages/component/navbar.vue'
+	import {
+		navBar
+	} from '@/pages/component/navbar.vue'
 	export default {
 		name: "pupilHome",
 		components: {
-      tabBar,
-      navBar,
+			tabBar,
+			navBar,
 		},
 		data() {
 			return {
-				pageType:2,
-        navHeight: uni.getStorageSync('navHeight'),
-        title: '实验室安全智慧化管控系统',
+				pageType: 2,
+				navHeight: uni.getStorageSync('navHeight'),
+				title: '实验室安全智慧化管控系统',
 				background: '#0183FA',
-				rectangleLogo:uni.getStorageSync('rectangleLogo')
+				rectangleLogo: uni.getStorageSync('rectangleLogo')
 			}
 		},
-		created() {
-		},
+		created() {},
 		mounted() {
 
 		},
 		methods: {
-			goPage(type){
-				if(!type){
+			goPage(type) {
+				if (!type) {
 					uni.showToast({
 						title: '暂未开放',
 						icon: "none",
@@ -103,31 +107,36 @@
 					});
 					return
 				}
-				if(type == 'securityExaminationPupil'){
+				if (type == 'securityExaminationPupil') {
 					//安全考试
-					
-				}else if(type == 'securityAdmittancePupil'){
+
+				} else if (type == 'securityAdmittancePupil') {
 					//安全准入
 					uni.navigateTo({
 						url: "/pages_student/views/accessApplication/safeAccess",
 					});
-				}else if(type == 'chemicalsPupil'){
+				} else if (type == 'securityCheck') {
+					//安全检查
+					uni.navigateTo({
+						url: "/pages_safetyCheck/views/safetyCheck",
+					});
+				} else if (type == 'chemicalsPupil') {
 					//化学品
-					
-				}else if(type == 'cageSiteSubscribePupil'){
+
+				} else if (type == 'cageSiteSubscribePupil') {
 					//笼位预约
-					
-				}else if(type == 'snapshotPupil'){
+
+				} else if (type == 'snapshotPupil') {
 					//随手拍
 					uni.navigateTo({
 						url: "/pages_safetyExamine/views/snapshotManage/snapshotAdd",
 					});
-				}else if(type == 'leaveCheckPupil'){
+				} else if (type == 'leaveCheckPupil') {
 					//离开检查
 					uni.navigateTo({
 						url: "/pages_basics/views/photoInspection",
 					});
-				}else if(type == 'violationRecordPupil'){
+				} else if (type == 'violationRecordPupil') {
 					//违规记录
 					uni.navigateTo({
 						url: "/pages_student/views/meViolation/meViolation",
@@ -145,13 +154,14 @@
 						list.forEach((item) => {
 							codeData[item.split("=")[0]] = item.split("=")[1];
 						})
-						if(codeData.type == 1 || codeData.type == 2 || codeData.type == 3 || codeData.type == 5 || codeData.type == 7 ||
-						codeData.type == 8 || codeData.type == 9 || codeData.type == 10 ||
-						codeData.type == 11 || codeData.type == 12){
+						if (codeData.type == 1 || codeData.type == 2 || codeData.type == 3 || codeData.type ==
+							5 || codeData.type == 7 ||
+							codeData.type == 8 || codeData.type == 9 || codeData.type == 10 ||
+							codeData.type == 11 || codeData.type == 12) {
 							uni.navigateTo({
 								url: '/pages/views/saoCode/saoCode?q=' + encodeURIComponent(res.result)
 							});
-						}else{
+						} else {
 							uni.showToast({
 								mask: true,
 								icon: "none",
@@ -169,13 +179,13 @@
 
 <style lang="stylus" scoped>
 	.pupilHome {
-		height:100%;
+		height: 100%;
 		flex: 1;
 		display: flex;
 		flex-direction: column;
 		overflow-y: scroll;
 		overflow-x: hidden;
-		padding-bottom:200rpx;
+		padding-bottom: 200rpx;
 
 		.top-page-title {
 			text-align: center;
@@ -328,8 +338,9 @@
 				}
 			}
 		}
+
 		.scan_btn {
-			z-index:10;
+			z-index: 10;
 			position: fixed;
 			bottom: 210rpx;
 			right: 0rpx;
@@ -337,4 +348,4 @@
 			height: 140rpx;
 		}
 	}
-</style>
+</style>

+ 3 - 3
pages/views/teacherPage/teacherHome.vue

@@ -138,7 +138,7 @@
 					});
 					return
 				}
-				if (!pageRestrictVerify(type)) {
+				/* if (!pageRestrictVerify(type)) {
 					uni.showToast({
 						title: '没有相关权限,请联系管理员',
 						icon: "none",
@@ -146,7 +146,7 @@
 						duration: 2000
 					});
 					return
-				}
+				} */
 				if (type == 'dataBoard') {
 					//数据看板
 					this.pageType = 1;
@@ -180,7 +180,7 @@
 				} else if (type == 'hierarchicalControl') {
 					//分级管控
 					uni.navigateTo({
-						url: "/pages_manage/views/gradingControl/gradingControl",
+						url: "/pages_basics/views/gradingControl/gradingControl",
 					});
 				} else if (type == 'securityResponsibility') {
 					//安全责任

+ 32 - 0
pages_basics/api/index.js

@@ -139,3 +139,35 @@ export const menuLinkPost  = (url,data) => {
         data: {...data}
     })
 };
+//分级管控未完成工作列表
+export const gradingControl  = (data) => {
+    return apiResquest({
+        url: `/laboratory/app/lab/manage/havingList`,
+        method: 'POST',
+        data: {...data}
+    })
+};
+//完成分级管控工作
+export const gradingControlAdd  = (data) => {
+    return apiResquest({
+        url: `/laboratory/app/lab/manage/finish`,
+        method: 'POST',
+        data: {...data}
+    })
+};
+//分级管控已完成工作列表
+export const gradingControlFinish  = (data) => {
+    return apiResquest({
+        url: `/laboratory/app/lab/manage/finishList`,
+        method: 'POST',
+        data: {...data}
+    })
+};
+//分级管控详细信息
+export const gradingControlDetail  = (data) => {
+    return apiResquest({
+        url: `/laboratory/app/lab/manage/getInfo/`+data,
+        method: 'GET',
+        //data: data,
+    })
+};

+ 7 - 6
pages_manage/views/laboratory/safetyCardScan.vue

@@ -22,7 +22,7 @@
 			<view class="lab-info">
 				<view class="lab-info-t">
 					<view>{{newData.levelName}}</view>
-					<view>{{newData.labClassTypeList[0].typeName}}</view>
+					<view>{{newData.typeName}}</view>
 					<view>{{newData.subName}}({{newData.roomNum}})</view>
 				</view>
 				<view class="lab-info-b">
@@ -262,10 +262,11 @@
 				}
 				if (type == 'securityCheck') {
 					//安全检查
-					if(this.identityData){
-						uni.navigateTo({
-							url: "/pages_safetyCheck/views/safetyCheck",
-						});
+					uni.navigateTo({
+						url: "/pages_safetyCheck/views/safetyCheck",
+					});
+					/* if(this.identityData){
+						
 					}else{
 						uni.showToast({
 							mask: true,
@@ -274,7 +275,7 @@
 							title: '您不是校/院级管理员或督导组成员,无法使用该功能.',
 							duration: 2000
 						});
-					}
+					} */
 				} else if (type == 'snapshot') {
 					//随手拍
 					uni.navigateTo({

+ 5 - 2
pages_safetyCheck/views/inspectManage/inspectAdd.vue

@@ -77,6 +77,7 @@
 </template>
 
 <script>
+	const myaudio  = uni.createInnerAudioContext();
 	import {
 		config
 	} from '@/api/request/config.js'
@@ -222,7 +223,9 @@
 			},
 			//提交
 			async submitForm(status) {
-				if(!this.form.checkFlag || status==2){
+				
+				console.log(this.form.checkFlag)
+				if(!this.form.checkFlag){
 					if(!this.form.hazardDescribe){
 						uni.showToast({
 							title: '请填写隐患描述!',
@@ -232,7 +235,7 @@
 						});
 						return
 					}
-					if(!this.form.photoList[0]){
+					if(!this.form.photoList[0] && !this.form.checkFlag){
 						uni.showToast({
 							title: '请选择现场照片!',
 							icon: "none",

+ 4 - 4
pages_safetyCheck/views/inspectManage/inspectList.vue

@@ -301,9 +301,9 @@
 						data
 					} = await securityAppCheckDangerReviewSubList(obj);
 					if (data.code == 200) {
-						if (data.data.records[0]) {
+						if (data.data[0] && data.data[0].stayExamineCheckNum !=0) {
 							//跳转检查项列表页面
-							let infoData = data.data.records[0];
+							let infoData = data.data[0];
 							infoData.pageType = this.tabIndexTow;
 							infoData.checkPlanSetVoList = this.optionData.checkPlanSetVoList;
 							uni.navigateTo({
@@ -328,9 +328,9 @@
 						data
 					} = await securityAppCheckDangerGetCheckDangerSubList(obj);
 					if (data.code == 200) {
-						if (data.data.records[0]) {
+						if (data.data[0]) {
 							//跳转检查项列表页面
-							let infoData = data.data.records[0];
+							let infoData = data.data[0];
 							infoData.pageType = this.tabIndexTow;
 							infoData.checkPlanSetVoList = this.optionData.checkPlanSetVoList;
 							uni.navigateTo({

+ 3 - 3
pages_safetyCheck/views/itemsManage/hiddenDangerItems.vue

@@ -51,8 +51,8 @@
 						</view>
 						<view v-if="pageType == 1">
 							<img v-if="curTabTow==0" src="@/pages_safetyCheck/images/icon_zg_zh@1x.png">
-							<img v-if="curTabTow==1" src="@/pages_safetyCheck/images/icon_xz_zg@1x.png">
-							<img v-if="curTabTow==2" src="@/pages_safetyCheck/images/icon_xz_fc@1x.png">
+							<img v-if="curTabTow==1" src="@/pages_safetyCheck/images/icon_xz_fc@1x.png">
+							<img v-if="curTabTow==2" src="@/pages_safetyCheck/images/icon_xz_zg@1x.png">
 						</view>
 						<view v-if="pageType == 2">
 							<img v-if="curTabTow==2" src="@/pages_safetyCheck/images/icon_zg_zh@1x.png">
@@ -76,7 +76,7 @@
 			<view class="get-data-null-p" v-if="getDataType">- 没有更多数据 -</view>
 		</scroll-view>
 		<checkItemModule :propsData="propsData" v-if="checkItemModuleType"></checkItemModule>
-		<view class="sub-btn" v-if="pageType==0 && curTabTow==0 && curTabTow==2 && total !=0">
+		<view class="sub-btn" v-if="pageType==0 && (curTabTow==0 || curTabTow==2) && total !=0">
 			<view @click="submitBtn(1)">开展检查</view>
 			<view @click="submitBtn(2)">检查完成</view>
 		</view>

+ 5 - 4
pages_safetyCheck/views/itemsManage/hiddenDangerItemsDetail.vue

@@ -61,7 +61,7 @@
 						</view>
 					</view>
 					<view v-if="item.rectifyCollapse && item.rectifyTime">
-						<view class="hidden-content">{{item.rectifyMeasure}}
+						<view v-if="item.rectifyMeasure" class="hidden-content">{{item.rectifyMeasure}}
 						</view>
 						<view class="photo"  @click="lockImg(item.rectifyUploadList)">
 							<img v-for="(item2,index2) in item.rectifyUploadList" :src="baseUrl+item2.fileUrl">
@@ -84,7 +84,7 @@
 						</view>
 					</view>
 					<view v-if="item.reviewCollapse && item.reviewTime">
-						<view class="hidden-content" >{{item.examineOpinion}}
+						<view v-if="item.examineOpinion" class="hidden-content" >{{item.examineOpinion}}
 						</view>
 						<view class="photo"  @click="lockImg(item.examineUploadList)">
 							<img v-for="(item3,index3) in item.examineUploadList" :src="baseUrl+item3.fileUrl">
@@ -105,10 +105,11 @@
 			<view @click="submitBtn(1)">编辑</view>
 			<view @click="submitBtn(2)">继续检查</view>
 		</view>
-		<view class="sub-btn" v-if="pageType==1 && !hiddenDangerRecordStatus">
+	<!-- 	<view class="sub-btn" v-if="pageType==1 && !hiddenDangerRecordStatus">
 			<view @click="submitBtn(1)">编辑</view>
 			<view @click="submitBtn(2)">继续复查</view>
-		</view>
+		</view> -->
+		<view class="sub-btn-tow" v-if="pageType==1 && !hiddenDangerRecordStatus" @click="submitBtn(2)">继续复查</view>
 		<view class="sub-btn" v-if="pageType==2 && !hiddenDangerRecordStatus && !newData.finishRectify">
 			<view @click="submitBtn(1)">编辑</view>
 			<view @click="submitBtn(2)">继续整改</view>

+ 7 - 6
pages_safetyCheck/views/itemsManage/hiddenDangerRectification.vue

@@ -56,7 +56,7 @@
 						</view>
 					</view>
 					<view v-if="item.rectifyCollapse && item.rectifyTime">
-						<view class="hidden-content">{{item.rectifyMeasure}}
+						<view v-if="item.rectifyMeasure" class="hidden-content">{{item.rectifyMeasure}}
 						</view>
 						<view class="photo"  @click="lockImg(item.rectifyUploadList)">
 							<img v-for="(item2,index2) in item.rectifyUploadList" :src="baseUrl+item2.fileUrl">
@@ -79,7 +79,7 @@
 						</view>
 					</view>
 					<view v-if="item.reviewCollapse && item.reviewTime">
-						<view class="hidden-content" >{{item.examineOpinion}}
+						<view v-if="item.examineOpinion" class="hidden-content" >{{item.examineOpinion}}
 						</view>
 						<view class="photo"  @click="lockImg(item.examineUploadList)">
 							<img v-for="(item3,index3) in item.examineUploadList" :src="baseUrl+item3.fileUrl">
@@ -180,6 +180,7 @@
 		},
 		onLoad(option) {
 			let optionData = JSON.parse(decodeURIComponent(option.infoData));
+			console.log('测试整改',optionData)
 			this.$set(this, 'pageType', optionData.pageType);
 			this.$set(this, 'optionData', optionData);
 			this.$set(this, 'editStatus', optionData.editStatus);
@@ -426,7 +427,7 @@
 			async submitForm(status) {
 				let self = this;
 				if(self.pageType==1){
-					if(!this.form.examineOpinion){
+					if(!this.form.examineOpinion && status==2){
 						uni.showToast({
 							title: '请填写复查验证描述!',
 							icon: "none",
@@ -435,7 +436,7 @@
 						});
 						return
 					}
-					if(!this.form.imgDtoList[0]){
+					if(!this.form.imgDtoList[0] && status==2){
 						uni.showToast({
 							title: '请选择现场照片!',
 							icon: "none",
@@ -470,7 +471,7 @@
 					
 					}
 				}else if(self.pageType==2){
-					if(!this.form.rectifyMeasure){
+					if(!this.form.rectifyMeasure && status==2){
 						uni.showToast({
 							title: '请填写隐患整改描述!',
 							icon: "none",
@@ -479,7 +480,7 @@
 						});
 						return
 					}
-					if(!this.form.imgDtoList[0]){
+					if(!this.form.imgDtoList[0] && status==2){
 						uni.showToast({
 							title: '请选择现场照片!',
 							icon: "none",

+ 3 - 0
pages_safetyCheck/views/safetyCheck.vue

@@ -137,6 +137,9 @@
 			},
 			//顶部tab点击
 			tabClick(index) {
+				this.$set(this.queryParams, 'page', 1);
+				this.$set(this, 'total', 0);
+				this.$set(this, 'dataList', []);
 				if (this.curTab != index) {
 					if (index == 0) {
 						//校级检查

+ 1 - 1
pages_safetyCheck/views/snapshotManage/snapshotDetail.vue

@@ -66,7 +66,7 @@
 				</view> -->
 			</view>
 		</scroll-view>
-		<view v-if="newData.rectifyStatus==0" class="sub-btn" @click="rectificationBtn">{{newData.rectifyStatus==0?'整改':'继续整改'}}</view>
+		<view v-if="newData.rectifyStatus==0 && newData.canRectify" class="sub-btn" @click="rectificationBtn">{{newData.rectifyStatus==0?'整改':'继续整改'}}</view>
 	</view>
 
 </template>

+ 4 - 1
pages_safetyCheck/views/snapshotManage/snapshotList.vue

@@ -333,6 +333,7 @@
 					data
 				} = await laboratorySubRelInfoGetRelList({
 					'searchValue': this.form.searchValue,
+					'subId':this.form.subId,
 				});
 				if (data.code == 200) {
 					if (data.data[0]) {
@@ -378,7 +379,9 @@
 						})
 						console.log('二维码', codeData)
 						if (codeData.code) {
-							self.laboratoryAppletGetSubDetailInfo(codeData.code);
+							self.$set(self.form, "subId", codeData.subId)
+							self.buildBySub();
+							self.popupType = true;
 						} else {
 							uni.showToast({
 								title: '请扫描正确的二维码',