Browse Source

Merge branch 'data-page-V4.3.1' of http://120.46.222.128:10021/elink-star/epmet-work-mp into xiaowang_V_4.3.1

# Conflicts:
#	subpages/safetyinspection/pages/safetyinspection/safetyinspection.js
#	subpages/safetyinspection/pages/safetyinspection/safetyinspection.wxml
#	subpages/safetyinspection/pages/safetyinspection/safetyinspection.wxss
lisu_V4.3.1
是小王呀\24601 1 year ago
parent
commit
24b5413c99
  1. 2
      pages/index/index.js
  2. 2
      pages/resiAndHouse/resiAndHouse.wxml
  3. 2
      pages/work2/work2.js
  4. 500
      subpages/InspectionReport/pages/InspectionReport/InspectionReport.js
  5. 4
      subpages/InspectionReport/pages/InspectionReport/InspectionReport.json
  6. 141
      subpages/InspectionReport/pages/InspectionReport/InspectionReport.wxml
  7. 414
      subpages/InspectionReport/pages/InspectionReport/InspectionReport.wxss
  8. 2
      subpages/addhouse/pages/addhouse/addhouse.js
  9. 9
      subpages/addhouse/pages/addhouse/addhouse.wxss
  10. 42
      subpages/safetyinspection/pages/safetyinspection/safetyinspection.js
  11. 62
      subpages/safetyinspection/pages/safetyinspection/safetyinspection.wxml
  12. 7
      subpages/safetyinspection/pages/safetyinspection/safetyinspection.wxss
  13. 6
      subpages/securityCheck/pages/securityCheck.js
  14. 20
      subpages/securityCheck/pages/securityCheck.wxml
  15. 10
      utils/api.js

2
pages/index/index.js

@ -217,7 +217,7 @@ onScrollToLower(e){
this.clearOneMessage(e.currentTarget.dataset.item.id)
if(e.currentTarget.dataset.item.msgType == 'resident_base_info'){
wx.navigateTo({
url: `/subpages/addResi/pages/addResi/addResi?type=edit&resiId=${e.currentTarget.dataset.item.targetId}`,
url: `/subpages/searchResult/pages/resiInfo/resiInfo?resiId=${e.currentTarget.dataset.item.targetId}`,
})
}else if(e.currentTarget.dataset.item.msgType == 'community_house'){
wx.navigateTo({

2
pages/resiAndHouse/resiAndHouse.wxml

@ -20,7 +20,7 @@
</view>
<view class="inout_box">
<image src="../../images/work/search.png" mode="" class="search_img" />
<input type="text" placeholder="姓名/手机/身份证" bindinput="handelBlurKeyWord" bindblur="handelBlurKeyWord" value="{{keyWord}}" />
<input type="text" placeholder="{{selectVale === 'resi'?'姓名/手机/身份证':'小区/楼栋/单元'}}" bindinput="handelBlurKeyWord" bindblur="handelBlurKeyWord" value="{{keyWord}}" />
<view class="btn_box" bind:tap="handelClickSearch">
<image src="../../images/cardIcon.png" mode="" wx:if="{{selectVale == 'resi'}}" class="OCR_img" bind:tap="handelClickToOcr" />
<text>搜索</text>

2
pages/work2/work2.js

@ -117,7 +117,7 @@ Page({
onData(){
// wx.switchTab({
wx.navigateTo({
url: '../../subpages/securityCheck/pages/securityCheck'
url: '/subpages/securityCheck/pages/securityCheck'
})
}
// onAddHouse(){

500
subpages/InspectionReport/pages/InspectionReport/InspectionReport.js

@ -1,12 +1,177 @@
// subpages/InspectionReport/pages/InspectionReport/InspectionReport.js
// // subpages/InspectionReport/pages/InspectionReport/InspectionReport.js
// const QQMapWX = require('../../../../utils/qqmap-wx-jssdk')
// import addRecord from "../../../../utils/api"
// import {securityCheckk} from "../../../../utils/api"
// Page({
// /**
// * 页面的初始数据
// */
// data: {
// pageNo: 1,
// pageSize: 10,
// id: 0,
// addressContent:'',
// fmData: {
// gridId: '',
// attachmentList:[],//图片
// voiceList:[],
// latitude:"",
// longitude:"",
// resiId:"",
// happenTime:"",
// content:"",//内容
// address:"",//地址
// namesArray:[],
// checkPersons:''
// },
// },
// /**
// * 生命周期函数--监听页面加载
// */
// onLoad(options) {
// this.data.qqMapWX = new QQMapWX({
// key: 'CMJBZ-4DECI-JXGGN-5B4WU-QLV2H-B5BEJ'
// })
// this.reverseLocation()
// // this.ToaddRecord()
// this.getList()
// },
// getList() {
// securityCheckk({
// pageNo: this.data.pageNo,
// pageSize: this.data.pageSize,
// }).then(({data}) => {
// console.log("123131",data.list)
// this.setData({
// marsi: data.list,
// total: data.total
// })
// this.setData({
// 'fmData.namesArray': data.list.map(item => ({ id: item.id, name: item.name })),
// 'fmData.checkPersons': data.list.map(item => item.checkPersons)
// });
// // console.log("123131", this.data.fmData.checkPersons);
// });
// },
// /**
// * 生命周期函数--监听页面初次渲染完成
// */
// onReady() {
// },
// /**
// * 生命周期函数--监听页面显示
// */
// onShow() {
// this.reverseLocation
// },
// /**
// * 生命周期函数--监听页面隐藏
// */
// onHide() {
// },
// /**
// * 生命周期函数--监听页面卸载
// */
// onUnload() {
// },
// /**
// * 页面相关事件处理函数--监听用户下拉动作
// */
// onPullDownRefresh() {
// },
// /**
// * 页面上拉触底事件的处理函数
// */
// onReachBottom() {
// },
// /**
// * 用户点击右上角分享
// */
// onShareAppMessage() {},
// //跳转地图选点
// toughGetLocation() {
// // this.getLocation(false);
// wx.chooseLocation({
// success: res => {
// console.log('resadddres', res)
// const {
// fmData
// } = this.data;
// this.setData({
// fmData: {
// ...fmData,
// address: res.address,
// longitude: res.longitude,
// latitude: res.latitude
// },
// addressContent: res.address
// });
// console.log(this.data.fmData);
// }
// })
// },
// //
// reverseLocation() {
// const _this = this
// this.data.qqMapWX.reverseGeocoder({
// success(res) {
// console.log(res);
// _this.setData({
// addressContent:res.result.address,
// 'fmData.address': res.result.address,
// 'fmData.longitude':res.result.location.lng,
// 'fmData.latitude':res.result.location.lat,
// })
// },
// fail(err) {
// console.debug(err)
// }
// })
// },
// ToaddRecord(){
// addRecord().then(res=>{
// console.log(res)
// })
// }
// })
// subpages/safetyinspection/pages/safetyinspection/safetyinspection.js
const QQMapWX = require('../../../../utils/qqmap-wx-jssdk')
import addRecord from "../../../../utils/api"
const App = getApp()
import {addRecord,securityCheckk,inspectionStaff} from "../../../../utils/api"
Page({
/**
* 页面的初始数据
*/
data: {
addRecord:[],
attachmentUrl:'',
reviewTime:'',
hazardDesc:'',
checkResultFlag:'',
checkPersonsIdList:[],
pageNo: 1,
pageSize: 10,
id: 0,
addressContent:'',
fmData: {
gridId: '',
@ -18,27 +183,105 @@ Page({
happenTime:"",
content:"",//内容
address:"",//地址
namesArray:[],
AllnamesArray:[],
checkPersons:''
},
imageUrl:'',
remarks:'',//备注
getData:'',
gridName:'',
array: ['不合格', '合格'], // 选择器的数据源
result: ['a', 'b', 'c'],
arrlist:[],
fileList: [],
companyId: '',
showPopup: false, // 控制弹出层显示/隐藏的状态
selectedOptions: [], // 选中的复选框项
selectedNames:[],//显示检察人员
// 用于存放复选框选择的结果
result: [],
// 用于存放输入框的值
newPassword: '',
arr:[
// {value:"1",name:'小王'},
// {value:"2",name:'李四'},
// {value:"3",name:'张三'}
],
arr1:[
// {value:"1",name:'1.车间一些软件设备出现生锈断裂情况严重'},
// {value:"2",name:'2.还有部分货运车辆已过年检。'},
],
},
/**
* 生命周期函数--监听页面加载
*/
onLoad(options) {
this.data.qqMapWX = new QQMapWX({
key: 'CMJBZ-4DECI-JXGGN-5B4WU-QLV2H-B5BEJ'
})
this.reverseLocation()
this.ToaddRecord()
console.log(options.resiId)
this.setData({
companyId: options.resiId
})
this.data.qqMapWX = new QQMapWX({
key: 'CMJBZ-4DECI-JXGGN-5B4WU-QLV2H-B5BEJ'
})
this.reverseLocation()
// this.ToaddRecord()
this.getList()
},
submitBiao(){
console.log("122131")
const currentDate = new Date();
addRecord({
companyId: this.data.companyId,
checkTime:currentDate,
checkPersonsIdList: this.data.checkPersonsIdList,
checkResultFlag: this.data.checkResultFlag,
reviewTime:this.data.reviewTime,
hazardDesc:[{hazardStatus:2},{hazardDesc:this.data.hazardDesc}],
attachmentUrls:[{fileName:'文件'},{attachmentUrl:'http://tmp/2JqHQVjACkEA00497265d7c287d505d1c20123e0470c.png'}],
remark:'123'
}).then(({data}) => {
console.log('data',data)
});
},
getList() {
securityCheckk({
pageNo: this.data.pageNo,
pageSize: this.data.pageSize,
}).then(({data}) => {
// console.log("123131",data.list)
this.setData({
marsi: data.list,
total: data.total
})
this.setData({
'fmData.AllnamesArray': data.list.map(item => ({ id: item.id, name: item.name })),
'fmData.namesArray': data.list.map(item => (item.name)),
'fmData.checkPersons': data.list.map((item, index) => ({ value: index, name: item.checkPersons })),
});
// console.log("123131", this.data.fmData.namesArray.map(item => item.name));
});
inspectionStaff({
orgId: App.globalData.user.agencyId,
orgType:'agency',
pageNo:1,
pageSize:100
}).then(({data}) => {
this.setData({
arr: data.staffList
})
});
///
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady() {
},
onReady() {},
/**
* 生命周期函数--监听页面显示
@ -58,72 +301,211 @@ Page({
* 生命周期函数--监听页面卸载
*/
onUnload() {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh() {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom() {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage() {},
//跳转地图选点
toughGetLocation() {
// this.getLocation(false);
wx.chooseLocation({
success: res => {
console.log('resadddres', res)
onShareAppMessage() {
},
onChange(event) {
console.log(event)
this.setData({
result: event.detail
});
// event.detail 为当前输入的值
console.log(this.data.selectedOptions);
},
afterRead(event) {
const {
file
} = event.detail;
console.log(file)
// 当设置 mutiple 为 true 时, file 为数组格式,否则为对象格式
wx.uploadFile({
url: 'https://example.weixin.qq.com/upload', // 仅为示例,非真实的接口地址
filePath: file.url,
name: 'file',
formData: {
user: 'test'
},
success(res) {
// 上传完成需要更新 fileList
const {
fmData
fileList = []
} = this.data;
fileList.push({
...file,
url: res.data
});
this.setData({
fmData: {
...fmData,
address: res.address,
longitude: res.longitude,
latitude: res.latitude
},
addressContent: res.address
fileList
});
console.log(this.data.fmData);
},
});
},
showPopup() {
this.setData({ showPopup: true }); // 点击按钮显示弹出层
},
onClose() {
this.setData({ showPopup: false }); // 关闭弹出层
},
onChange1(event) {
console.log(event)
this.setData({
selectedOptions: event.detail
});
console.log(this.data.selectedOptions)
},confirmSelection() {
// 点击确定按钮后触发,处理选中的复选框项
console.log("选中的项:", this.data.selectedOptions);
const selectedName = this.data.selectedOptions;
this.setData({
showPopup: false,
selectedNames: selectedName
});
const matchedStaffIds = [];
this.data.arr.forEach(item => {
if (selectedName.includes(item.name)) {
matchedStaffIds.push(item.staffId);
}
});
this.setData({
checkPersonsIdList: matchedStaffIds
});
// 关闭弹出层
},
changeNewPassword(e){
console.log("执行了")
this.setData({
newPassword: e.detail.value
});
console.log(this.data.newPassword)
},
addAnother() {
// // 获取输入框的值
// const newPassword = this.data.newPassword;
// // 将值添加到arr数组中
// const arr = this.data.arr.concat(newPassword);
// // 更新数据
// this.setData({
// arr: arr,
// // 清空输入框的值
// newPassword: ''
// });
let newValue = this.data.arr1.length + 1; // 根据数组长度确定新值
let newArr = this.data.arr1.concat({ value: newValue.toString(), name: this.data.newPassword });
this.setData({
arr1: newArr,
newPassword: '', // 清空输入框的值
});
console.log('添加后的数组:', this.data.arr1);
},
pickerChange: function(e) {
// 更新当前选中的索引
console.log(e.detail.value),
this.setData({
gridName: this.data.array[e.detail.value]
});
this.data.checkResultFlag = e.detail.value
console.log(this.data.gridName)
// 在这里可以根据选择的值进行相应的逻辑处理
},
pickerChange1: function(e) {
// 更新当前选中的索引
console.log(e.detail.value),
this.setData({
getData: e.detail.value
});
this.data.reviewTime = e.detail.value
console.log(this.data.getData)
// 在这里可以根据选择的值进行相应的逻辑处理
},
pickerChange2: function(e) {
// 更新当前选中的索引
this.setData({
gridNName: this.data.fmData.namesArray[e.detail.value]
});
this.data.addRecord = this.data.fmData.AllnamesArray[e.detail.value].id
},
bindRemarkInput(e){
this.setData({
remarks: e.detail.value
});
console.log(this.data.remarks)
},
chooseImage() {
wx.chooseMedia({
count: 1,
sizeType: ['original', 'compressed'],
sourceType: ['album', 'camera'],
success(res) {
console.log(res)
const tempFilePaths = res.tempFilePaths;
// 将选定的图片显示在页面上
this.setData({
imageUrl: tempFilePaths[0]
});
console.log(this.data.imageUrl)
}
})
},
//
reverseLocation() {
const _this = this
this.data.qqMapWX.reverseGeocoder({
success(res) {
console.log(res);
_this.setData({
addressContent:res.result.address,
'fmData.address': res.result.address,
'fmData.longitude':res.result.location.lng,
'fmData.latitude':res.result.location.lat,
})
},
fail(err) {
console.debug(err)
}
})
},
ToaddRecord(){
addRecord().then(res=>{
console.log(res)
})
}
//跳转地图选点
toughGetLocation() {
// this.getLocation(false);
wx.chooseLocation({
success: res => {
console.log('resadddres', res)
const {
fmData
} = this.data;
this.setData({
fmData: {
...fmData,
address: res.address,
longitude: res.longitude,
latitude: res.latitude
},
addressContent: res.address
});
console.log(this.data.fmData);
}
})
},
//
reverseLocation() {
const _this = this
this.data.qqMapWX.reverseGeocoder({
success(res) {
console.log(res);
_this.setData({
addressContent:res.result.address,
'fmData.address': res.result.address,
'fmData.longitude':res.result.location.lng,
'fmData.latitude':res.result.location.lat,
})
},
fail(err) {
console.debug(err)
}
})
},
})
})

4
subpages/InspectionReport/pages/InspectionReport/InspectionReport.json

@ -3,6 +3,8 @@
"usingComponents": {
"van-uploader": "@vant/weapp/uploader/index",
"van-checkbox": "@vant/weapp/checkbox/index",
"van-checkbox-group": "@vant/weapp/checkbox-group/index"
"van-checkbox-group": "@vant/weapp/checkbox-group/index",
"van-popup": "@vant/weapp/popup/index",
"van-picker": "@vant/weapp/picker/index"
}
}

141
subpages/InspectionReport/pages/InspectionReport/InspectionReport.wxml

@ -1,5 +1,5 @@
<!--subpages/InspectionReport/pages/InspectionReport/InspectionReport.wxml-->
<view class="header">
<!-- <view class="header">
<view class="header_left">
<image src="../../../../images/location.png" class="header_img"></image>
<view class="inside">
@ -91,4 +91,141 @@
</view>
<view class="text-wrapper_11">
<text lines="1" class="text_29">提交</text>
</view>
</view> -->
<!--subpages/safetyinspection/pages/safetyinspection/safetyinspection.wxml-->
<view class="header">
<view class="header_left">
<image src="../../../../images/location.png" class="header_img"></image>
<view class="inside">
<text class="text1">{{addressContent}}</text>
<text class="text2">如定位不在事发地,请重新选择定位</text>
</view>
</view>
<view class="header_right" bind:tap="toughGetLocation">
<text class="text3">重新定位</text>
</view>
</view>
<view class="from">
<view class="prosecutors">
<view class="conclusion">
<text class="prosecutors_req">*</text>
<text class="prosecutors_pre">企业名称</text>
<picker class="prosecutors_name" bindchange="pickerChange2" value="{{index}}" range="{{fmData.namesArray}}">
<view class="{{gridNName?'':'gray'}}">
{{gridNName?gridNName:'请选择'}}
</view>
</picker>
</view>
<view class="conclusion_right">
<image src="../../../../images/right.png" class="prosecutors_img"></image>
</view>
</view>
<view class="prosecutors" bind:tap="showPopup">
<view>
<text class="prosecutors_req">*</text>
<text class="prosecutors_pre">检查人员</text>
<text class="prosecutors_name">{{ selectedNames }}</text>
</view>
<view>
<image src="../../../../images/right.png" class="prosecutors_img"></image>
</view>
</view>
<view class="pitfall">
<view class="prosecutors">
<view>
<text class="prosecutors_req">*</text>
<text class="prosecutors_pre">隐患明细</text>
</view>
</view>
<view class="checkbox1">
<van-checkbox-group value="{{ result }}" bind:change="onChange">
<van-checkbox name="{{item.value}}" wx:for="{{arr1}}" >{{item.name}}</van-checkbox>
</van-checkbox-group>
</view>
<view class="input1">
<input bindinput="changeNewPassword" type="text" placeholder=" 请输入" />
</view>
<view class="add" bind:tap="addAnother">
<image src="../../../../images/add.png" class="add_img"></image>
<text>再添加一条</text>
</view>
</view>
<view class="pitfall">
<view class="prosecutors">
<view>
<text class="prosecutors_req">*</text>
<text class="prosecutors_pre">整改要求</text>
</view>
</view>
<!-- <view class="checkbox1">
<van-checkbox-group value="{{ hazardDesc }}">
<van-checkbox name="hazardDesc">{{ hazardDesc }}</van-checkbox>
</van-checkbox-group>
</view> -->
<view class="input1">
<input bindinput="changeHazardDesc" type="text" placeholder="请输入" value="{{ hazardDesc }}" />
</view>
</view>
<view class="prosecutors">
<view class="conclusion">
<text class="prosecutors_req">*</text>
<text class="prosecutors_pre">检查结论</text>
<picker class="prosecutors_name" bindchange="pickerChange" value="{{index}}" range="{{array}}">
<view class="{{gridName?'':'gray'}}">
{{gridName?gridName:'请选择'}}
</view>
</picker>
</view>
<view class="conclusion_right">
<image src="../../../../images/right.png" class="prosecutors_img"></image>
</view>
</view>
<view class="prosecutors">
<view class="prosecutors_data">
<text class="prosecutors_req">*</text>
<text class="prosecutors_pre">拟复查时间</text>
<view>
<picker mode="date" class="prosecutors_name" bindchange="pickerChange1" value="{{data}}">
<view class="{{getData?'':'gray'}}">
{{getData?getData:'请选择'}}
</view>
</picker>
</view>
</view>
<view>
<image src="../../../../images/right.png" class="prosecutors_img"></image>
</view>
</view>
<view class="attachment">
<text class="text1">附件</text>
<van-uploader file-list="{{ fileList }}" bind:after-read="afterRead" />
<text class="text1">备注</text>
<view class="textarea1">
<textarea placeholder-style="color: #C1C1C1;" bindinput="bindRemarkInput" maxlength="100" placeholder-class="gray" placeholder="请输入" />
</view>
</view>
</view>
<view class="footer">
<view class="btn" bind:tap="submitBiao">
<text class="btn_text">提交</text>
</view>
</view>
<van-popup show="{{ showPopup }}" closeable close-icon="close" position="bottom" custom-style="height: 50%" bind:close="onClose">
<view class="popup-content">
<van-checkbox-group value="{{selectedOptions}}" bind:change="onChange1">
<van-checkbox name="{{item.name}}" data-value="{{item.value}}" wx:for="{{arr}}">{{item.name}}</van-checkbox>
</van-checkbox-group>
<button bindtap="confirmSelection">确定</button>
</view>
</van-popup>

414
subpages/InspectionReport/pages/InspectionReport/InspectionReport.wxss

@ -1,4 +1,4 @@
page {
/* page {
width: 100%;
height: auto;
overflow-y: auto;
@ -164,6 +164,19 @@ page {
margin-left: 40rpx;
height: 90rpx;
}
.input_pre{
width: 650rpx;
overflow-wrap: break-word;
color: rgba(51,51,51,1);
font-size: 32rpx;
font-weight: normal;
text-align: left;
white-space: nowrap;
line-height: 42rpx;
margin-left: 60rpx;
}
.add{
display: flex;
flex-direction: row;
@ -232,4 +245,403 @@ page {
white-space: nowrap;
line-height: 60rpx;
margin: 25rpx 0 0 284rpx;
} */
page {
width: 100%;
min-height: 100vh;
overflow-y: auto;
background-color: #f7f7f7;
}
.from{
width: 100%;
height: 100%;
display: flex;
flex-direction: column;
border-radius: 15rpx;
background-color: rgb(255, 255, 255);
margin: 30rpx;
}
.prosecutors{
display: flex;
flex-direction:row;
align-items: center;
margin: 20rpx;
justify-content: space-between;
height: 50rpx;
border-bottom: 1px solid #EAEAEA;
}
.conclusion{
display: flex;
flex-direction: row;
}
.prosecutors_req{
color: red;
margin: 5rpx
}
.prosecutors_pre{
width: 125rpx;
height: 30rpx;
overflow-wrap: break-word;
color: rgba(102,102,102,1);
font-size:32rpx;
font-weight: normal;
text-align: left;
white-space: nowrap;
line-height: 42rpx;
margin-left: 6rpx;
}
.prosecutors_name{
width: 150px;
height: 30rpx;
overflow-wrap: break-word;
color: rgba(51,51,51,1);
font-size: 32rpx;
font-weight: normal;
text-align: left;
white-space: nowrap;
line-height: 42rpx;
margin-left: 60rpx;
}
.prosecutors_img{
width: 40rpx;
height: 30rpx;
margin-right: 30rpx;
}
.prosecutors_top{
display: flex;
flex-direction: column;
}
.prosecutors_but{
display: flex;
flex-direction: column;
margin: 15rpx;
}
.prosecutors_chex{
margin: 20rpx;
}
.checkbox{
font-size: 32rpx;
}
.prosecutors_group{
margin: 20rpx;
}
.prosecutors_add{
display: flex;
flex-direction: row;
justify-content: center;
align-items: center;
}
.prosecutors_data{
display: flex;
flex-direction: row;
}
.input{
margin-left: 100rpx;
font-size: 32rpx;
}
.attachment{
display: flex;
flex-direction: column;
margin: 20rpx;
}
.image1{
margin-top: 20rpx;
margin-bottom: 20rpx;
width: 200rpx;
height: 200rpx;
}
.text1{
width: 62rpx;
height: 30rpx;
overflow-wrap: break-word;
color: rgba(102,102,102,1);
font-size: 32rpx;
font-family: PingFang-SC-Regular;
font-weight: normal;
text-align: left;
white-space: nowrap;
line-height: 42rpx;
margin-bottom: 30rpx;
}
.textarea1{
margin-top: 20rpx;
background-color:#f7f7f7 ;
width: 100%;
height: 200rpx;
}
/* .text2{
width: 133rpx;
height: 32rpx;
overflow-wrap: break-word;
color: rgba(51,51,51,1);
font-size: 34rpx;
font-family: PingFang-SC-Bold;
font-weight: 700;
text-align: left;
white-space: nowrap;
line-height: 52rpx;
margin: 31rpx 0 0 29rpx;
} */
.logsBox {
border-left: 3rpx solid #DADEE5;
margin-left: -18rpx;
padding-left: 12rpx;
}
.logs-top {
display: flex;
justify-content: space-between;
position: relative;
top: -32rpx;
padding-left: 12rpx;
}
.logs-top-title {
height: 31rpx;
font-family: PingFang SC;
font-weight: 500;
font-size: 32rpx;
color: #333333;
line-height: 41rpx;
}
.logs-top-time {
height: 20rpx;
font-family: PingFang SC;
font-weight: 500;
font-size: 26rpx;
color: #BDBDBD;
line-height: 40rpx;
}
.logs-content {
position: relative;
top: -24rpx;
padding-top: 12rpx;
padding-bottom: 24rpx;
display: flex;
justify-content: space-between;
font-family: PingFang SC;
font-weight: 500;
font-size: 30rpx;
color: #999999;
line-height: 52rpx;
}
.logs-content-left {
width: 48%;
}
.logs-content-right {
width: 48%;
}
.logs-content-txt {
color: #333333;
}
.item-dian {
position: relative;
left: -28rpx;
width: 32rpx;
height: 32rpx;
box-sizing: border-box;
background: #FFFFFF;
border-radius: 50%;
border: 1px solid #3A80E7;
display: flex;
align-items: center;
justify-content: center;
}
.neidian {
width: 18rpx;
height: 18rpx;
background: #3A80E7;
border-radius: 50%;
}
.text3{
width: 138rpx;
height: 27rpx;
overflow-wrap: break-word;
color: rgba(51,51,51,1);
font-size: 28rpx;
font-family: PingFang-SC-Medium;
font-weight: 500;
text-align: left;
white-space: nowrap;
line-height: 48rpx;
margin-bottom: 20rpx;
}
.hidden{
display: flex;
flex-direction: column;
}
.hidden_top{
display: flex;
flex-direction:column;
align-items: center;
justify-content: space-between;
height: 50rpx;
}
.text8{
display: flex;
flex-direction: row;
}
.text9{
display: flex;
}
.pitfall{
display: flex;
flex-direction: column;
box-sizing: border-box;
}
.pitfall_header{
display: flex;
flex-direction: row;
}
.checkbox1{
display: flex;
flex-direction:column;
margin-left: 50rpx;
margin-bottom: 20rpx;
}
.input1{
width: 650rpx;
height: 90rpx;
background-color: #F7F7F7;
border-radius: 10rpx;
margin-left: 50rpx;
}
.add{
display: flex;
flex-direction: row;
box-sizing: border-box;
justify-content: center;
align-items: center;
margin: 20rpx;
}
.add_img{
width: 40rpx;
height: 40rpx;
}
.conclusion_right{
display: flex;
flex-direction: row;
}
.btn{
display: flex;
margin: 20rpx;
background-color: #3974F6;
width: 630rpx;
height: 86rpx;
border-radius: 43rpx;
justify-content: center;
align-items: center;
margin-bottom: 30px;
}
.btn_text{
width: 80rpx;
height: 31rpx;
font-family: PingFang SC;
font-weight: bold;
font-size: 32rpx;
color: #FFFFFF;
line-height: 60rpx;
margin-bottom: 20rpx;
}
.footer{
width: 100%;
height: 100rpx;
display: flex;
justify-content: center;
align-items: center;
z-index: 2;
position:fixed;
left: 0;
bottom: 0;
}
.image-box {
width: 100%;
height: auto;
border-radius: 16rpx;
background: #fff;
margin-top: 20rpx;
box-sizing: border-box;
padding: 34rpx 24rpx;
position: relative;
}
.header{
height: 80rpx;
display: flex;
background-color: white;
flex-direction: row;
justify-content: space-between;
}
.header_left{
display:flex;
flex-direction: row;
margin-left: 20rpx;
}
.header_img{
width: 36rpx;
height: 36rpx;
margin-top: 10rpx;
}
.inside{
display: flex;
flex-direction: column;
margin-left: 10rpx;
}
.text1{
width: 374rpx;
height: 30rpx;
overflow-wrap: break-word;
color: rgba(51,51,51,1);
font-size: 32rpx;
font-family: PingFang-SC-Regular;
font-weight: normal;
text-align: left;
white-space: nowrap;
line-height: 42rpx;
margin-left: 1rpx;
}
.text2{
width: 382rpx;
height: 24rpx;
overflow-wrap: break-word;
color: rgba(172,172,172,1);
font-size: 24rpx;
font-family: PingFang-SC-Regular;
font-weight: normal;
text-align: left;
white-space: nowrap;
line-height: 42rpx;
margin-bottom: 10rpx;
margin-top: -7px;
}
.header_right{
display: flex;
justify-content: center;
align-items: center;
margin-right: 30rpx;
}
.text3{
width: 118rpx;
height: 28rpx;
overflow-wrap: break-word;
color: rgba(56,135,248,1);
font-size: 30rpx;
font-family: PingFang-SC-Regular;
font-weight: normal;
text-align: left;
white-space: nowrap;
line-height: 42rpx;
}

2
subpages/addhouse/pages/addhouse/addhouse.js

@ -167,7 +167,7 @@ Page({
getQuartersOptions(gridId){
let parm = {
gridId,
agencyId:this.data.agecyId
agencyId:app.globalData.user.agencyId
}
api.getQuartersOptions(parm).then(res=>{
this.setData({

9
subpages/addhouse/pages/addhouse/addhouse.wxss

@ -15,10 +15,6 @@ page {
width: 100%;
height: 444rpx;
overflow: hidden;
/* position: fixed;
top: 0;
left: 0;
z-index: 1000; */
}
.header .header-bg {
width: 100%;
@ -191,4 +187,7 @@ page {
color: #fff;
margin: 30rpx auto 0;
line-height: 86rpx;
}
}

42
subpages/safetyinspection/pages/safetyinspection/safetyinspection.js

@ -1,4 +1,6 @@
// subpages/safetyinspection/pages/safetyinspection/safetyinspection.js
const App = getApp()
import {
showRecord,addRecord,inspectionStaff
} from "../../../../utils/api"
@ -17,7 +19,7 @@ Page({
remarks:'',//备注
getData:'',
gridName:'',
array: ['选项1', '选项2', '选项3', '选项4'], // 选择器的数据源
array: ['合格', '不合格'], // 选择器的数据源
result: ['a', 'b', 'c'],
arrlist:[],
fileList: [],
@ -30,9 +32,6 @@ Page({
// 用于存放输入框的值
newPassword: '',
arr:[
{value:"1",name:'小王'},
{value:"2",name:'李四'},
{value:"3",name:'张三'}
],
arr1:[
{value:"1",name:'1.车间一些软件设备出现生锈断裂情况严重'},
@ -48,12 +47,15 @@ Page({
* 生命周期函数--监听页面加载
*/
onLoad(options) {
console.log(options.resiId)
this.setData({
companyId: options.resiId
companyId: options.resiId,
orgid:App.globalData.user.agencyId
})
console.log(App.globalData)
this.showRecordData()
this.addRecordData()
this.toOinspectionStaff()
},
/**
@ -144,8 +146,27 @@ Page({
console.log(this.data.showList)
})
},
toOinspectionStaff(){
console.log("我执行了")
let parm = {
orgId:this.data.orgid,
      orgType:"agency",
      pageNo:1,
      pageSize:100
}
inspectionStaff(parm).then(res=>{
console.log(res.data.staffList)
this.setData({
arr:res.data.staffList
})
})
},
addRecordData(){
let parm=({
})
addRecord(parm).then(res => {
console.log("")
this.setData({
@ -171,9 +192,9 @@ Page({
// 点击确定按钮后触发,处理选中的复选框项
console.log("选中的项:", this.data.selectedOptions);
console.log(this.data.arr)
console.log(this.data.arr.filter(item => this.data.selectedOptions.includes(item.value)).map(item => item.name));
console.log(this.data.arr.filter(item => this.data.selectedOptions.includes(item.staffId)).map(item => item.name));
console.log(this.data.arr.filter(item => this.data.selectedOptions.includes(item.value)));
const selectedName = this.data.arr.filter(item => this.data.selectedOptions.includes(item.value)).map(item => item.name);
const selectedName = this.data.arr.filter(item => this.data.selectedOptions.includes(item.staffId)).map(item => item.name);
console.log("选中的名称:", selectedName);
this.setData({
showPopup: false,
@ -295,7 +316,8 @@ if (that.data.imageUrls) {
})
},
})
})

62
subpages/safetyinspection/pages/safetyinspection/safetyinspection.wxml

@ -20,7 +20,7 @@
</view>
<view class="checkbox1">
<van-checkbox-group value="{{ result }}" bind:change="onChange">
<van-checkbox custom-class="group1" name="{{item.value}}" wx:for="{{arr1}}" >{{item.name}}</van-checkbox>
<van-checkbox custom-class="group" name="{{item.value}}" wx:for="{{arr1}}">{{item.name}}</van-checkbox>
</van-checkbox-group>
</view>
<view class="input1">
@ -66,17 +66,17 @@
<van-uploader file-list="{{ fileList }}" bind:after-read="afterRead" />
<text class="text1">备注</text>
<view class="textarea1">
<textarea placeholder-style="color: #C1C1C1;" bindinput="bindRemarkInput" maxlength="100" placeholder-class="gray" placeholder="请输入" />
<textarea placeholder-style="color: #C1C1C1;" bindinput="bindRemarkInput" maxlength="100" placeholder-class="gray" placeholder="请输入" />
</view>
</view>
</view>
<view class="from">
<view>
<text class="text2">巡检记录</text>
<text class="text2">巡检记录</text>
</view>
<view style="margin-top: 32rpx;padding: 0 35rpx;">
<view class="logsBox" wx:for="{{showList}}" wx:for-index="index">
<view class="logsBox" wx:for="{{showList}}" wx:for-index="index">
<view class="item-dian {{index!=0?'item-dian1':''}}">
<view class="neidian"></view>
</view>
@ -87,7 +87,7 @@
<view class="logs-content-left">
<view>
<text class="logs-content-title">检察人员:</text>
<text class="logs-content-txt">{{item.checkPersons}}</text>
<text class="logs-content-txt">{{item.chekPersons}}</text>
</view>
<view>
<text class="logs-content-title">检查结论:</text>
@ -95,7 +95,7 @@
</view>
<view>
<text class="logs-content-title">隐患明细:</text>
<text class="logs-content-txt" wx:for="{{item.hiddenDangeList}}" >{{item.hazardDesc}}</text>
<text class="logs-content-txt" wx:for="{{item.hiddenDangeList}}">{{item.hazardDesc}}</text>
</view>
<view>
<text class="logs-content-title">整改要求:</text>
@ -106,8 +106,8 @@
<text class="logs-content-txt">{{item.reviewTime}}</text>
</view>
<view>
<text class="logs-content-title" >附件:</text>
<text class="logs-content-txt" wx:for="{{item.attachmentUrls}}" >{{item.fileName}}</text>
<text class="logs-content-title">附件:</text>
<text class="logs-content-txt" wx:for="{{item.attachmentUrls}}">{{item.fileName}}</text>
</view>
<view>
<text class="logs-content-title">备注:</text>
@ -116,35 +116,43 @@
<view>
<text class="logs-content-title">巡查定位:</text>
<text class="logs-content-txt">--</text>
<text class="logs-content-txt">{{item.name}}</text>
</view>
</view>
</view>
</view>
</view>
</view>
<view class="footer">
<view class="btn">
<text class="btn_text">提交</text>
</view>
<view class="footer">
<view class="btn">
<text class="btn_text">提交</text>
</view>
</view>
<view class="image-box">
<view class="field-text">上传图片</view>
<view wx:for="{{imageUrls}}">
<image wx:if="{{imageUrls}}" src="{{item.tempFilePath}}" mode="aspectFit" style="width: 200rpx; height: 300px;"></image>
</view>
<image src="../../../../images/addphoto.png" bindtap="chooseImage" />
</view>
<!-- <view class="{{ uploadImageList.length < 4 ? 'image-list' : uploadImageList.length > 3 && uploadImageList.length < 7 ? 'image-list image-list-2' : uploadImageList.length > 6 && uploadImageList.length < 10 ? 'image-list image-list-3' : 'image-list image-list-4' }}">
<view class=" image-list-label">
<view class="field-text">上传图片</view>
</view>
<view class="image-item" wx:for="{{uploadImageList}}" wx:for-index="index" wx:for-item="item" wx:key="imageId">
<image class="issue-image" src="{{item.ossUrl.url}}" />
<image wx:if="{{!item.uploaded}}" class="loading" src="../../../images/loading.gif" />
<image bindtap="deleteImage" data-imageid="{{item.imageId}}" class="close" wx:else src="../../../images/sc.png" />
</view>
<image src="../../../../images/addphoto.png" bindtap="chooseImage" />
</view> -->
</view>
<view class="image-box">
<view class="field-text">上传图片</view>
<view wx:for="{{imageUrls}}">
<image wx:if="{{imageUrls}}" src="{{item.tempFilePath}}" mode="aspectFit" style="width: 200rpx; height: 300px;"></image>
</view>
<image src="../../../../images/addphoto.png" bindtap="chooseImage" />
</view>
<van-popup show="{{ showPopup }}" closeable close-icon="close" position="bottom" custom-style="height: 50%" bind:close="onClose">
<view class="popup-content">
<van-checkbox-group value="{{selectedOptions}}" bind:change="onChange1">
<van-checkbox name="{{item.value}}" data-value="{{item.value}}" wx:for="{{arr}}">{{item.name}}</van-checkbox>
<van-checkbox name="{{item.staffId}}" data-value="{{item.value}}" wx:for="{{arr}}">{{item.name}}</van-checkbox>
</van-checkbox-group>
<button bindtap="confirmSelection">确定</button>
</view>
</van-popup>
</van-popup>

7
subpages/safetyinspection/pages/safetyinspection/safetyinspection.wxss

@ -1,3 +1,4 @@
page {
width: 100%;
min-height: 100vh;
@ -296,6 +297,8 @@ page {
margin-bottom: 30px;
}
.btn_text{
justify-content: center;
align-items: center;
width: 80rpx;
height: 31rpx;
font-family: PingFang SC;
@ -323,6 +326,6 @@ margin-bottom: 20rpx;
padding: 34rpx 24rpx;
position: relative;
}
.group1{
margin-top: 20rpx;
.group{
margin-bottom: 20rpx;
}

6
subpages/securityCheck/pages/securityCheck.js

@ -19,6 +19,12 @@ Page({
this.getList()
},
handleTap() {
console.log('Movable view clicked');
wx.navigateTo({
url: '/subpages/InspectionReport/pages/InspectionReport/InspectionReport'
})
},
getList() {
securityCheckk({
pageNo: this.data.pageNo,

20
subpages/securityCheck/pages/securityCheck.wxml

@ -22,10 +22,10 @@
</view>
</view>
<movable-area class="movable-area">
<movable-view class="movable-view" direction="all" x="250" y="300">
<image src="../../images/xuncha.png" class="image-wrapper"></image>
</movable-view>
</movable-area>
<movable-view class="movable-view" bind:tap="handleTap" direction="all" x="250" y="300">
<image src="../../../images/xuncha.png" class="image-wrapper" catchtouchend="handleTap"></image>
</movable-view>
</movable-area>
</scroll-view>
@ -40,11 +40,13 @@
<view class="title_mall">拟复查时间: {{item.reviewTime}}</view>
</view>
</view>
<movable-area class="movable-area">
<movable-view class="movable-view" direction="all" x="250" y="300" bind:tap="toAddEnterprise">
<image src="../../../images/xuncha.png" class="image-wrapper"></image>
</movable-view>
</movable-area>
<movable-area class="movable-area">
<movable-view class="movable-view" bind:tap="handleTap" direction="all" x="250" y="300">
<image src="../../../images/xuncha.png" class="image-wrapper" catchtouchend="handleTap"></image>
</movable-view>
</movable-area>
</scroll-view>
</view>
</view>

10
utils/api.js

@ -80,7 +80,8 @@ module.exports = {
overView,
getFamilyRelationshipListByHouseId,
addRecord,
showRecord
showRecord,
inspectionStaff
}
// 获取公钥
@ -415,9 +416,12 @@ function overView(parm){
function addRecord(parm){
return fly.post(`actual/base/companyInfo/addRecord`,parm)
}
//巡查巨鹿--展示
//巡查记录--展示
function showRecord(parm){
return fly.post(`actual/base/companyInfo/showRecord`,parm)
}
//检查人员
function inspectionStaff(parm){
return fly.post(`data/aggregator/org/stafflist`,parm)
}

Loading…
Cancel
Save