|
|
<template>
|
|
|
<view>
|
|
|
<!-- 头部区域 -->
|
|
|
<view class="topWrap">
|
|
|
<view class="topItem">
|
|
|
<view class="topLeft">
|
|
|
状态
|
|
|
</view>
|
|
|
<view class="topRight">
|
|
|
<image class="topImg" src="../../../static/image/icon_daiducha.png" mode=""></image>
|
|
|
<!-- <image class="topImg" src="../../../static/image/icon_yiducha.png" mode=""></image> -->
|
|
|
</view>
|
|
|
</view>
|
|
|
<view class="topItem">
|
|
|
<view class="topLeft">
|
|
|
检查时间<span>*</span>
|
|
|
</view>
|
|
|
<view class="topRight" @tap="visibleMinute=true">
|
|
|
<text :class="{activeTxt: checkTime != '请选择'}">{{checkTime}}</text>
|
|
|
<image class="rightImg" src="../../../static/image/icon_arrow.png" mode=""></image>
|
|
|
</view>
|
|
|
</view>
|
|
|
<w-picker
|
|
|
:visible.sync="visibleMinute"
|
|
|
mode="date"
|
|
|
:current="true"
|
|
|
fields="day"
|
|
|
@confirm="onConfirm($event,'minute')"
|
|
|
@cancel="onCancel"
|
|
|
:disabled-after="false"
|
|
|
ref="date"
|
|
|
>检查时间</w-picker>
|
|
|
<view class="topItem">
|
|
|
<view class="topLeft">
|
|
|
检查人员<span>*</span>
|
|
|
</view>
|
|
|
<view class="topRight">
|
|
|
{{companyInfo.STORED == 1 ? companyInfo.MISSIONPERSON : userInfo.name}}
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
<!-- 按钮区域 -->
|
|
|
<view class="btnWrap">
|
|
|
<view class="btn active" @click="archive">
|
|
|
交办
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
import wPicker from "@/components/w-picker/w-picker.vue"
|
|
|
export default {
|
|
|
data() {
|
|
|
return {
|
|
|
companyInfo:{},
|
|
|
userInfo:{},
|
|
|
companyid:'',
|
|
|
visibleMinute:false,
|
|
|
checkTime:'请选择'
|
|
|
}
|
|
|
},
|
|
|
components:{
|
|
|
wPicker
|
|
|
},
|
|
|
onBackPress(e) {
|
|
|
console.log('用户操作返回',e)
|
|
|
uni.redirectTo({
|
|
|
url:'check'
|
|
|
})
|
|
|
return true
|
|
|
},
|
|
|
onShow() {
|
|
|
this.getData()
|
|
|
},
|
|
|
onLoad(option) {
|
|
|
this.companyid = option.companyid
|
|
|
if(uni.getStorageSync('token')){
|
|
|
uni.request({
|
|
|
url:this.apiUrl + 'getLoginUser',
|
|
|
data:{},
|
|
|
method:'get',
|
|
|
header:{
|
|
|
Authorization:'Bearer '+uni.getStorageSync('token')
|
|
|
},
|
|
|
success: (res) => {
|
|
|
console.log('获取当前登录用户信息',res)
|
|
|
if(res.data.code == 200){
|
|
|
this.userInfo = res.data.data
|
|
|
}else{
|
|
|
setTimeout(()=>{
|
|
|
uni.showToast({
|
|
|
title:'登录超时,请重新登录',
|
|
|
icon:'none'
|
|
|
})
|
|
|
},500)
|
|
|
uni.reLaunch({
|
|
|
url:'../../login/login'
|
|
|
})
|
|
|
}
|
|
|
}
|
|
|
})
|
|
|
}else{
|
|
|
uni.reLaunch({
|
|
|
url:'../../login/login'
|
|
|
})
|
|
|
}
|
|
|
|
|
|
},
|
|
|
methods: {
|
|
|
getData(){
|
|
|
//企业状态查询
|
|
|
uni.request({
|
|
|
url:this.apiUrl + 'license/getCompany',
|
|
|
data:{companyId:this.companyid},
|
|
|
method:'get',
|
|
|
success: (res) => {
|
|
|
console.log('归档状态查询',res)
|
|
|
this.companyInfo = res.data.data
|
|
|
uni.setNavigationBarTitle({
|
|
|
title: this.companyInfo.OWNERCOMPANY //这是修改后的导航栏文字
|
|
|
})
|
|
|
}
|
|
|
})
|
|
|
},
|
|
|
onCancel(){
|
|
|
|
|
|
},
|
|
|
onConfirm(e,pickerType){
|
|
|
this.checkTime = e.result
|
|
|
},
|
|
|
showSubCheck(index){
|
|
|
if(this.keyList[index].subKeyList.length > 0){
|
|
|
if(this.keyList[index].show == 0){
|
|
|
this.keyList[index].show = 1
|
|
|
}else{
|
|
|
this.keyList[index].show = 0
|
|
|
}
|
|
|
}else{
|
|
|
uni.navigateTo({
|
|
|
url:'checkDetail?param='+JSON.stringify(this.keyList[index].param)+'&companyid='+this.companyid
|
|
|
})
|
|
|
}
|
|
|
},
|
|
|
archive(){
|
|
|
if(this.checkTime == '请选择'){
|
|
|
uni.showToast({
|
|
|
title:'请选择检查时间',
|
|
|
icon:'none'
|
|
|
})
|
|
|
return
|
|
|
}
|
|
|
/* uni.request({
|
|
|
url:this.apiUrl + 'license/updateStatus?account='+this.userInfo.account+'&companyId='+this.companyid+'&date='+this.checkTime,
|
|
|
data:{},
|
|
|
method:'post',
|
|
|
success: (res) => {
|
|
|
console.log('保存归档',res)
|
|
|
}
|
|
|
}) */
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
</script>
|
|
|
|
|
|
<style lang="scss">
|
|
|
page{background: #f7f8fa;}
|
|
|
/* 头部区域 */
|
|
|
.topWrap{padding: 0 32rpx;background: #fff;}
|
|
|
.topWrap .topItem{display: flex;justify-content: space-between;align-items: center;height: 104rpx;font-size: 30rpx;border-top: 2rpx solid #f2f3f5;}
|
|
|
.topItem .topLeft{color: #646566;}
|
|
|
.topLeft span{color: red;}
|
|
|
.topItem .topRight{display: flex;align-items: center;}
|
|
|
.topRight text{color: #c8c9cc;}
|
|
|
.topRight .activeTxt{color: #323232;}
|
|
|
.topRight .topImg{width: 104rpx;height: 104rpx;}
|
|
|
.topRight .rightImg{width: 32rpx;height: 32rpx;}
|
|
|
/* 底部区域 */
|
|
|
.bottomWrap{padding: 0 32rpx;background: #fff;}
|
|
|
.bottomWrap .bottomItem{display: flex;justify-content: space-between;align-items: center;height: 104rpx;font-size: 30rpx;}
|
|
|
.bottomItem.bottomLine{border-bottom: 2rpx solid #f2f3f5;}
|
|
|
.bottomItem .bottomLeft{display: flex;align-items: center;}
|
|
|
.bottomLeft .completeImg{width: 60rpx;display: flex;align-items: center;}
|
|
|
.completeImg image{width: 40rpx;height: 40rpx;}
|
|
|
.bottomRight image{width: 32rpx;height: 32rpx;}
|
|
|
.subCheckWrap{padding: 0 32rpx 0 64rpx;}
|
|
|
.subCheckWrap .subCheckItem{display: flex;justify-content: space-between;align-items: center;height: 96rpx;color: #646566;font-size: 28rpx;}
|
|
|
.subCheckItem image{width: 32rpx;height: 32rpx;}
|
|
|
/* 按钮区域 */
|
|
|
.btnWrap{padding: 16rpx 60rpx;background: #fff;margin-top: 32rpx;}
|
|
|
.btnWrap .btn{height: 100rpx;background: #dcdee0;border-radius: 28rpx;text-align: center;line-height: 100rpx;color: #fff;font-size: 34rpx;margin-top: 16rpx;}
|
|
|
.btn.active{background: $theme-color;}
|
|
|
</style> |
...
|
...
|
|