退卡变动

This commit is contained in:
shijing 2023-07-19 15:18:48 +08:00
parent 50d140342d
commit 40a4998fcc
3 changed files with 171 additions and 13 deletions

View File

@ -2,8 +2,8 @@
"name" : "曲阳金隅EHS", "name" : "曲阳金隅EHS",
"appid" : "__UNI__B00D419", "appid" : "__UNI__B00D419",
"description" : "曲阳金隅EHS", "description" : "曲阳金隅EHS",
"versionName" : "1.01.42", "versionName" : "1.01.44",
"versionCode" : 101042, "versionCode" : 101044,
"transformPx" : false, "transformPx" : false,
/* 5+App */ /* 5+App */
"app-plus" : { "app-plus" : {

View File

@ -119,10 +119,50 @@
</view> </view>
</view> </view>
</view> </view>
<view class="wrap-view wrap-top"> <view class="wrap-view wrap-top" v-if="formData.cate_code=='space'||formData.cate_code=='fire'||formData.cate_code=='clear'||formData.cate_code=='preheat'">
<view class="item title"> <text class="blueLine"></text>气体检测记录</view> <view class="item title"> <text class="blueLine"></text>气体检测记录</view>
<view class="workersWrap"> <view class="checkWrap">
<view class="workersItem itemTitle"> <view v-for="item1 in gasList" :key="item1.id" style="border-bottom: 1upx solid #dddddd;">
<view class="checkItem">
<text class="checkItemLable">检测部位</text>
<text class="checkItemValue">{{item1.check_place}}</text>
</view>
<view class="checkItem">
<text class="checkItemLable">O₂</text>
<text class="checkItemValue">{{item1.o2}}</text>
</view>
<view class="checkItem">
<text class="checkItemLable">检测人</text>
<text class="checkItemValue">{{item1.checker_.name}}</text>
</view>
<view class="checkItem">
<text class="checkItemLable">CO</text>
<text class="checkItemValue">{{item1.co}}</text>
</view>
<view class="checkItem">
<text class="checkItemLable">检验结论</text>
<text class="checkItemValue" v-if="item1.is_ok">正常</text>
<text class="checkItemValue" v-else>异常</text>
</view>
<view class="checkItem" v-if="formData.cate_code=='fire'">
<text class="checkItemLable">可燃气体</text>
<text class="checkItemValue">{{item1.lel}}</text>
</view>
<view class="checkItem" v-if="formData.cate_code=='space'||formData.cate_code=='clear'">
<text class="checkItemLable">H₂S</text>
<text class="checkItemValue">{{item1.h2s}}</text>
</view>
<view class="checkItem" v-if="formData.cate_code=='preheat'">
<text class="checkItemLable">45</text>
<text class="checkItemValue">{{item1.f5}}</text>
</view>
<view class="checkItem" style="width: 100%;">
<text class="checkItemLable">检测时间</text>
<text class="checkItemValue">{{item1.check_time}}</text>
</view>
</view>
<!-- <view class="workersItem itemTitle">
<text class="workerCell">检测部位</text> <text class="workerCell">检测部位</text>
<text class="workerCell">可燃气体(V%LEL)</text> <text class="workerCell">可燃气体(V%LEL)</text>
<text class="workerCell">检验结论</text> <text class="workerCell">检验结论</text>
@ -134,7 +174,7 @@
<span v-if="item1.is_ok">正常</span> <span v-if="item1.is_ok">正常</span>
<span v-else>异常</span> <span v-else>异常</span>
</text> </text>
</view> </view> -->
</view> </view>
</view> </view>
<view id="workerWrap" v-if="detailLimited"> <view id="workerWrap" v-if="detailLimited">
@ -464,7 +504,26 @@
.workersWrap{ .workersWrap{
} }
.checkWrap{
font-size: 28upx;
align-items:center;
padding: 10upx 20upx;
}
.checkItem{
width: 50%;
color: #212121;
display: inline-block;
}
.checkItemLable{
color: #212121;
width: 140upx;
display: inline-block;
text-align: right;
margin-right: 6upx;
}
.checkItemValue{
color: #666666;
}
.workersItem{ .workersItem{
display: flex; display: flex;
font-size: 28upx; font-size: 28upx;

View File

@ -72,7 +72,32 @@
</view> </view>
</view> </view>
<button v-if="vuex_user.type=='employee'" type="warn" class="backCard" @click="bindBtl">退定位卡</button> <button v-if="vuex_user.type=='employee'" type="warn" class="backCard" @click="bindBtl">退定位卡</button>
<view id="detailWrap" v-if="detailLimited">
<view class="workerContainer">
<view v-if="itemDetail.employee_">
<view class="workerInfo">
<view class="infoTitle">姓名</view><view>{{itemDetail.employee_.name}}</view>
</view>
<view class="workerInfo">
<view class="infoTitle">手机</view><view>{{itemDetail.employee_.number}}</view>
</view>
<view class="workerInfo">
<view class="infoTitle">所属部门</view><view>{{itemDetail.employee_.belong_dept_name}}</view>
</view>
<view class="workerInfo">
<view class="infoTitle">所在岗位</view><view>{{itemDetail.employee_.post_name}}</view>
</view>
</view>
<view class="workerInfo">
<view class="infoTitle">Mac号</view><view v-if="itemDetail.code">{{itemDetail.code}}</view>
</view>
<view class="btnsWrap">
<view class="btns cancel" @click="closeWorkerDetail">取消</view>
<view class="btns equit" @click="tuika">退卡</view>
</view>
</view>
<!-- <icon class="closeDetailIcon" type="cancel" size="36" color="#fefefe" @click="closeWorkerDetail"/> -->
</view>
</view> </view>
</template> </template>
@ -85,6 +110,8 @@
limitedOperation:false, limitedOperation:false,
limitedRpj:false, limitedRpj:false,
limitedVisit:false, limitedVisit:false,
detailLimited:false,
itemDetail:{},
routerList: [{ routerList: [{
name: '新增作业', name: '新增作业',
icon: 'specialmatter.png', icon: 'specialmatter.png',
@ -101,6 +128,7 @@
path: 'index' path: 'index'
}, },
], ],
form:{},
myApplyArray: [], myApplyArray: [],
mytopimg: require("@/static/workSpace/bgimg-top.jpg"), mytopimg: require("@/static/workSpace/bgimg-top.jpg"),
} }
@ -117,18 +145,35 @@
let that = this; let that = this;
uni.scanCode({ uni.scanCode({
success: function (res) { success: function (res) {
that.detailLimited = true;
let form = {}; let form = {};
form.type = 20; form.type = 20;
form.code = res.result; form.code = res.result;
that.$u.api.thirdBltBind(form).then(res=>{ that.form = form;
uni.showToast({ that.$u.api.tdevice(form).then(res=>{
title: res, that.itemDetail = res.results[0];
icon: "none"
})
}) })
} }
}); });
}, },
tuika(){
let that = this;
that.$u.api.thirdBltBind(that.form).then(res=>{
uni.showToast({
title: res,
icon: "none"
})
that.detailLimited = false;
}).catch(res=>{
uni.showToast({
title: res,
icon: "none"
})
})
},
closeWorkerDetail(){
this.detailLimited = false;
},
goInto(index) { goInto(index) {
if (index == 0) { if (index == 0) {
uni.navigateTo({ uni.navigateTo({
@ -481,4 +526,58 @@
bottom: 80px; bottom: 80px;
right: 20px; right: 20px;
} }
#detailWrap{
height: 100%;
width: 100%;
position: fixed;
top: 0;
left: 0;
z-index: 100;
background: rgba(0,0,0,.6);
}
.workerContainer{
position: relative;
width: 90%;
left: 5%;
background: #ffffff;
padding: 40upx 40upx 80upx 40upx;
top: 50%;
transform: translateY(-50%);
max-height: 80%;
overflow-y: scroll;
border-radius: 20upx;
}
.workerInfo{
display: flex;
margin: 20upx 0;
}
.infoTitle{
width: 170upx;
}
.closeDetailIcon{
position: absolute;
bottom: 5%;
left: 50%;
transform: translateX(-50%);
}
.btnsWrap{
width: 100%;
display: flex;
position: absolute;
bottom: 0;
height: 80upx;
line-height: 80upx;
}
.btnsWrap>.btns{
width: 50%;
text-align: center;
color: #aaaaaa;
box-sizing: border-box;
border-top: 1upx solid #eeeeee;
}
.btnsWrap>.btns.equit{
color:#e64340 ;
border-left: 1upx solid #eeeeee;
}
</style> </style>