巡检代码提交

test
zhangdi 1 year ago
parent 043c050d7e
commit d4032ee24a
  1. 19
      api/api.js
  2. 12
      pages.json
  3. 23
      pages/inspection/components/plan-list.vue
  4. 129
      pages/inspection/plan.vue
  5. 271
      pages/inspection/planDetails.vue
  6. 16
      pages/inspection/quest.vue
  7. 7
      pages/inspection/questDetails.vue
  8. 26
      pages/inspection/questOrder.vue
  9. 2
      pages/inspection/records.vue
  10. 10
      utils/tabbar.js

@ -220,13 +220,17 @@ const install = (Vue, vm) => {
authorizations: true, authorizations: true,
isparams: false isparams: false
}) })
// 巡检计划 详情
// 获取巡检任务列表 lab-ops/maintenance/task-page let getPlanDetail = (params) => http.get('/lab-ops/maintenance/plan-detail', params, {
authorizations: true,
isparams: false
})
// 获取巡检任务列表
let getTaskPage = (params) => http.get('/lab-ops/maintenance/task-page', params, { let getTaskPage = (params) => http.get('/lab-ops/maintenance/task-page', params, {
authorizations: true, authorizations: true,
isparams: false isparams: false
}) })
// 获取巡检任务详情 lab-ops/maintenance/task-page // 获取巡检任务详情
let getTaskDetail = (params) => http.get('/lab-ops/maintenance/task-detail', params, { let getTaskDetail = (params) => http.get('/lab-ops/maintenance/task-detail', params, {
authorizations: true, authorizations: true,
isparams: false isparams: false
@ -236,14 +240,19 @@ const install = (Vue, vm) => {
authorizations: true, authorizations: true,
isparams: false isparams: false
}) })
//维修人员确认接收 lab-ops/maintenance/task-serviceman-receive //维修人员确认接收
let taskServicemanreceive = (params) => http.post('/lab-ops/maintenance/task-serviceman-receive', params, { let taskServicemanreceive = (params) => http.post('/lab-ops/maintenance/task-serviceman-receive', params, {
authorizations: true, authorizations: true,
isparams: false isparams: false
}) })
//维修人员更新上门时间
let taskServicemanUpdateTime = (params) => http.post('/lab-ops/maintenance/task-serviceman-update-time', params, {
authorizations: true,
isparams: false
})
// 将各个定义的接口名称,统一放进对象挂载到vm.$u.api(因为vm就是this,也即this.$u.api)下 // 将各个定义的接口名称,统一放进对象挂载到vm.$u.api(因为vm就是this,也即this.$u.api)下
vm.$u.api = { getTenantInfo, login, logout, registerUser, getworkbench, getLoginRecords, getEditRecords, subEditRecords, getChildList, getDeviceList, workOrderSave, getWorkOrderRecords, getBreakdownInfo, workOrderupdate, evaluateSign, getRepairPersons, getGoodsList, getDictionaryList, getUserList, workList, deviceList, upkeepStat, pieStat, getUserInfo, overview, sendOrders, cloneOrder, editData, repairReject, applySave, sendVerify, serviceman, servicemanReceive, servicemanSubmit, supervisorReject, supervisorconfirm, customerConfirm, customerReject, servicemanRepairSubmit, evaluateRepairReject, getDeviceDetail, getTaskPage, getTaskDetail,taskSupervisorconfirm,taskServicemanreceive,updateCoordinate }; vm.$u.api = { getTenantInfo, login, logout, registerUser, getworkbench, getLoginRecords, getEditRecords, subEditRecords, getChildList, getDeviceList, workOrderSave, getWorkOrderRecords, getBreakdownInfo, workOrderupdate, evaluateSign, getRepairPersons, getGoodsList, getDictionaryList, getUserList, workList, deviceList, upkeepStat, pieStat, getUserInfo, overview, sendOrders, cloneOrder, editData, repairReject, applySave, sendVerify, serviceman, servicemanReceive, servicemanSubmit, supervisorReject, supervisorconfirm, customerConfirm, customerReject, servicemanRepairSubmit, evaluateRepairReject, getDeviceDetail, getTaskPage, getTaskDetail,taskSupervisorconfirm,taskServicemanreceive,updateCoordinate ,taskServicemanUpdateTime,getPlanDetail};
} }
export default { export default {

@ -196,6 +196,18 @@
"titleNView": {} "titleNView": {}
} }
} }
},
{
"path": "pages/inspection/planDetails",
"style": {
"navigationBarTitleText": "巡检计划详情",
"enablePullDownRefresh": false,
"navigationBarTextStyle": "black",
"navigationBarBackgroundColor": "#F8F8F8",
"app-plus": {
"titleNView": {}
}
}
} }
], ],
"globalStyle": { "globalStyle": {

@ -3,8 +3,8 @@
<view class="page-search-top"> <view class="page-search-top">
<betone-new-input v-model="searchInfo.requirementCode" placeholder='搜索巡检单位名称' icon="search" <betone-new-input v-model="searchInfo.requirementCode" placeholder='搜索巡检单位名称' icon="search"
style="margin-bottom: 32rpx" @changevalue="searchData()" /> style="margin-bottom: 32rpx" @changevalue="searchData()" />
<u-tabs :list="tabList" :is-scroll="false" :current="current" @change="changeTab" <!-- <u-tabs :list="tabList" :is-scroll="false" :current="current" @change="changeTab"
bg-color="rgba(248, 248, 248, 1)"></u-tabs> bg-color="rgba(248, 248, 248, 1)"></u-tabs> -->
</view> </view>
<view class="order-box"> <view class="order-box">
<!-- @click="goPage(item, 'details')" --> <!-- @click="goPage(item, 'details')" -->
@ -26,6 +26,8 @@
<text class="con-title">创建时间{{ item.createTime }}</text> <text class="con-title">创建时间{{ item.createTime }}</text>
<view class="con-btn"> <view class="con-btn">
<u-button size="mini" plain style="margin-right: 32rpx"
@click="details(item)">查看</u-button>
<block v-if="item.status == 0 && dataTypes == 3"> <block v-if="item.status == 0 && dataTypes == 3">
<u-button size="mini" plain style="margin-right: 32rpx" <u-button size="mini" plain style="margin-right: 32rpx"
@click="assign(item)">指派</u-button> @click="assign(item)">指派</u-button>
@ -35,6 +37,7 @@
</view> </view>
</view> </view>
</view> </view>
<u-loadmore margin-top="10" margin-bottom="40" :status="loadingState" />
<!-- 分派人员--> <!-- 分派人员-->
<u-select v-model="sendOrdersShow" :list="sendOrdersList" @confirm="sendOrdersConfirm" :isShowsearch="true" <u-select v-model="sendOrdersShow" :list="sendOrdersList" @confirm="sendOrdersConfirm" :isShowsearch="true"
@ -212,6 +215,14 @@ export default {
} }
}) })
}, },
details(item) {
let param = {
id: item.id,
}
uni.navigateTo({
url: `/pages/inspection/planDetails${this.$u.queryParams(param)}`,
});
},
}, },
}; };
@ -219,10 +230,10 @@ export default {
<style lang="scss" scoped> <style lang="scss" scoped>
.page-css { .page-css {
padding: 0; padding: 0 !important;
.page-search-top { .page-search-top {
height: 210rpx; max-height: 210rpx;
background-color: rgba(248, 248, 248, 1); background-color: rgba(248, 248, 248, 1);
padding: 0 40rpx 0; padding: 0 40rpx 0;
} }
@ -231,7 +242,7 @@ export default {
margin-top: 20rpx; margin-top: 20rpx;
.order-item { .order-item {
min-height: 414rpx; min-height: 214rpx;
margin: 0 24rpx 20rpx; margin: 0 24rpx 20rpx;
border-radius: 20rpx; border-radius: 20rpx;
background: #fff; background: #fff;
@ -336,7 +347,7 @@ export default {
.con-btn { .con-btn {
margin-top: 56rpx; margin-top: 56rpx;
margin-bottom: 32rpx; // margin-bottom: 32rpx;
display: inline-block; display: inline-block;
text-align: right; text-align: right;
} }

@ -1,5 +1,5 @@
<template> <template>
<view class="page-css"> <view class="">
<view class="page-header-txt">科研医疗建筑运维平台</view> <view class="page-header-txt">科研医疗建筑运维平台</view>
<planList></planList> <planList></planList>
<betone-tabbar ref="tabbarRef" /> <betone-tabbar ref="tabbarRef" />
@ -44,132 +44,5 @@ export default {
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.page-css {
padding: 0;
padding-top: var(--status-bar-height);
.page-search-top {
height: 210rpx;
background-color: rgba(248, 248, 248, 1);
padding: 0 40rpx 0;
}
.order-box {
margin-top: 20rpx;
.order-item {
min-height: 414rpx;
margin: 0 24rpx 20rpx;
border-radius: 20rpx;
background: #fff;
display: flex;
flex-direction: column;
.item-top {
height: 114rpx;
border-bottom: 1px solid rgba(239, 239, 239, 1);
display: flex;
flex-direction: row;
width: 100%;
.item-left {
flex: 1;
text {
display: block;
}
.item-orderNo {
color: rgba(51, 51, 51, 1);
font-size: 28rpx;
padding: 12rpx 0 0 26rpx;
}
.item-time {
color: rgba(190, 190, 190, 1);
font-size: 24rpx;
padding: 12rpx 0 0 26rpx;
}
}
.item-right {
width: 132rpx;
height: 48rpx;
margin: 36rpx 24rpx 0 0;
}
}
.item-con {
flex: 1;
display: flex;
flex-direction: row;
margin-bottom: 24rpx;
.con-left {
width: 150rpx;
height: 150rpx;
margin: 24rpx 28rpx 0 28rpx;
image {
width: 100%;
height: 100%;
}
}
.con-right {
flex: 1;
margin-right: 24rpx;
display: flex;
flex-direction: column;
margin-left: 32rpx;
text {
display: block;
}
.con-title {
margin-top: 12rpx;
line-height: 60rpx;
color: rgba(0, 0, 0, 1);
font-size: 28rpx;
}
.con-content {
color: rgba(108, 108, 108, 1);
font-size: 24rpx;
// line-height: 36rpx;
margin-top: 14rpx;
flex: 1;
text {
display: -webkit-box;
-webkit-box-orient: vertical;
-webkit-line-clamp: 2;
overflow: hidden;
text-overflow: ellipsis;
line-height: 1.5em;
/* 这个值根据你的需求调整,这里假设为1.5倍行高 */
max-height: 3em;
/* 3行的高度 */
width: 100%;
/* 根据需要设置宽度 */
word-wrap: break-word;
/* 允许在单词内换行 */
word-break: break-all;
/* 允许在任意字符处换行 */
}
}
.con-btn {
margin-top: 56rpx;
margin-bottom: 32rpx;
display: inline-block;
text-align: right;
}
}
}
}
}
}
</style> </style>

@ -0,0 +1,271 @@
<template>
<view class="page-css">
<view class="info">
<view class="info_title">基本信息</view>
<view class="info_item">
<text class="item_left_txt">单位名称</text>
<text class="item_right_txt">{{ detailForm.deptName }}</text>
</view>
<view class="info_item">
<text class="item_left_txt">项目标题</text>
<text class="item_right_txt">{{ detailForm.planContent }}</text>
</view>
</view>
<view class="info">
<view class="info_title">巡检任务</view>
<!-- <detailsCollapse :data="detailForm.details" type="view"></detailsCollapse> -->
<u-collapse :accordion="false">
<u-collapse-item v-for="(item, index) in detailForm.details" :key="index">
<view slot="title">
<text class="collapse-title">实验室楼层{{ item.floorName }}</text>
</view>
<view v-for="(v, vindex) in item.details" :key="vindex" class="collapse-room">
<view>房间名称{{ v.deptName }}</view>
<view v-for="(s, sindex) in v.details" :key="sindex" class="collapse-major">
<view>专业分类{{ s.checkContent }}</view>
<view v-for="(n, nindex) in s.details" :key="nindex" class="n-box">
<u-tag :text="nindex + 1" type="info" class="left-tag" />
<!-- <u-tag text="已检" type="success" class="right-tag" /> -->
<view class="n-box-title"> 各排/出水口通水顺畅</view>
<view class="n-box-info"> 工艺内容工艺内容工艺内容工艺内容工艺内容工艺内容工艺内容</view>
<view class="info_item">
<text class="item_left_txt">状态</text>
<text class="item_right_txt">
<u-radio-group v-model="n.radioValue">
<u-radio name="1">正常</u-radio>
<u-radio name="0">异常</u-radio>
</u-radio-group>
</text>
</view>
<view class="info_item">
<text class="item_left_txt">现场照片</text>
<text class="item_right_txt">
<view class="btn">上传照片</view>
</text>
</view>
<view class="info_item">
<text class="item_left_txt">使用人签字</text>
<text class="item_right_txt">
<image v-if="n.qianzi" :src="n.qianzi" style="width: 144px;height: 77rpx;"
mode="widthFix" @click="toPop1(index, vindex, sindex, nindex)"></image>
<view v-else class="btn" @click="toPop1(index, vindex, sindex, nindex)">签字
</view>
</text>
</view>
<view class="info_item">
<text class="item_left_txt">备注</text>
<text class="item_right_txt">
<betone-new-input type="textarea" :placeholder="'请输入'"></betone-new-input>
</text>
</view>
</view>
</view>
</view>
</u-collapse-item>
</u-collapse>
</view>
</view>
</template>
<script>
import detailsCollapse from './components/detailsCollapse.vue'
export default {
components: {
detailsCollapse,
},
computed: {
dataTypes() {
return this.$store.state.dataType
},
},
data() {
return {
detailForm: {},
optionsType: '',//
planOrderId: '',//
}
},
onLoad(options) {
this.optionsType = options.type
this.planOrderId = options.id
this.getDetails()
},
methods: {
getDetails() {
let query_ = {
id: this.planOrderId
}
this.$u.api.getPlanDetail(query_).then(res => {
if (res.code == 200) {
this.detailForm = res.data
}
})
}
}
}
</script>
<style lang="scss" scoped>
.page-css {
width: 100%;
padding: 0;
padding-top: 26rpx;
.info {
margin: 0 24rpx 20rpx;
border-radius: 20rpx;
background-color: rgba(255, 255, 255, 1);
padding: 6rpx 0 34rpx;
.info_title {
line-height: 60rpx;
color: rgba(0, 0, 0, 1);
font-size: 32rpx;
text-align: left;
font-family: SourceHanSansSC-bold;
margin: 18rpx 0 0rpx 20rpx;
font-weight: bold;
}
.info_item {
padding: 4rpx 20rpx 0;
display: flex;
align-items: center;
justify-content: space-between;
.item_left_txt {
color: rgba(108, 108, 108, 1);
font-size: 28rpx;
text-align: left;
font-family: SourceHanSansSC-regular;
width: 210rpx;
margin-right: 20rpx;
line-height: 60rpx;
}
.item_right_txt {
max-width: calc(100% - 220rpx);
color: rgba(0, 0, 0, 1);
font-size: 28rpx;
// text-align: left;
text-align: justify;
font-family: SourceHanSansSC-regular;
}
}
}
.repair-btn {
width: 100%;
height: 150rpx;
display: flex;
justify-content: space-between;
/* 水平均匀分布 */
margin-top: 32rpx;
padding: 0 32rpx;
/deep/.u-btn {
width: 48%;
}
}
.collapse-title {
line-height: 60rpx;
color: rgba(0, 0, 0, 1);
font-size: 32rpx;
text-align: left;
font-family: SourceHanSansSC-bold;
margin: 18rpx 0 0rpx 20rpx;
}
.collapse-room {
margin: 0 32rpx 20rpx;
color: rgba(0, 0, 0, 1);
}
.collapse-major {
margin: 0 32rpx 20rpx;
color: rgba(0, 0, 0, 1);
margin: 12rpx 24rpx 12rpx;
.n-box {
border: 1px solid rgba(239, 239, 239, 1);
padding: 32rpx 54rpx 0;
margin-top: 24rpx;
margin-bottom: 24rpx;
position: relative;
.right-tag {
position: absolute;
right: 0;
top: 0;
}
.left-tag {
position: absolute;
left: 0;
top: 0;
padding-left: 10rpx;
padding-right: 10rpx;
}
.n-box-title {
color: rgba(0, 0, 0, 1);
font-size: 28rpx;
text-align: left;
}
.n-box-info {
line-height: 32rpx;
color: rgba(154, 154, 154, 1);
font-size: 24rpx;
padding-top: 12rpx;
padding-bottom: 12rpx;
}
.info_item {
width: 100%;
display: flex;
flex-direction: row;
margin: 24rpx 0 24rpx;
.item_left_txt {
color: rgba(108, 108, 108, 1);
font-size: 28rpx;
text-align: left;
width: 170rpx;
margin-right: 20rpx;
line-height: 60rpx;
}
.item_right_txt {
flex: 1;
max-width: calc(100% - 220rpx);
color: rgba(0, 0, 0, 1);
font-size: 28rpx;
// text-align: left;
text-align: justify;
font-family: SourceHanSansSC-regular;
/deep/.u-radio-group {
flex-wrap: nowrap;
padding-right: 48rpx;
}
.btn {
width: 260rpx;
height: 60rpx;
line-height: 60rpx;
border-radius: 8rpx;
background-color: rgba(255, 255, 255, 1);
color: rgba(58, 98, 215, 1);
font-size: 28rpx;
text-align: center;
border: 2rpx dashed rgba(58, 98, 215, 1);
}
}
}
}
}
}
</style>

@ -1,6 +1,7 @@
<template> <template>
<view class="page-css"> <view class="page-css">
<view class="page-header-txt">科研医疗建筑运维平台</view> <view class="page-header-txt">科研医疗建筑运维平台</view>
<view class="protocol-content"> <u-subsection :list="subsectionList" :current="subsectionCurrent"></u-subsection></view>
<view class="page-search-top"> <view class="page-search-top">
<betone-new-input v-model="searchInfo.requirementCode" placeholder="搜索巡检单单号" icon="search" <betone-new-input v-model="searchInfo.requirementCode" placeholder="搜索巡检单单号" icon="search"
style="margin-bottom: 32rpx" @changevalue="searchData()" /> style="margin-bottom: 32rpx" @changevalue="searchData()" />
@ -33,7 +34,8 @@
<block> <block>
<u-button size="mini" plain style="margin-right: 32rpx" <u-button size="mini" plain style="margin-right: 32rpx"
@click="taskDetails(item)">查看</u-button> @click="taskDetails(item)">查看</u-button>
<u-button size="mini" plain style="margin-right: 32rpx" @click="openWorkOrder(item)">接收</u-button> <u-button size="mini" plain style="margin-right: 32rpx"
@click="openWorkOrder(item)">接收</u-button>
</block> </block>
</view> </view>
</view> </view>
@ -109,7 +111,16 @@ export default {
currentPage: 1, currentPage: 1,
pageSize: 10, pageSize: 10,
}, },
subsectionList: [
{
name: '巡检任务'
},
{
name: '巡检维修'
},
],
subsectionCurrent:1,//
}; };
}, },
@ -250,6 +261,9 @@ export default {
background-color: rgba(248, 248, 248, 1); background-color: rgba(248, 248, 248, 1);
padding: 0 40rpx 0; padding: 0 40rpx 0;
} }
.protocol-content{
padding: 30rpx;
}
.order-box { .order-box {
margin-top: 20rpx; margin-top: 20rpx;

@ -55,15 +55,20 @@ export default {
return { return {
detailForm: {}, detailForm: {},
optionsType: '',// optionsType: '',//
planOrderId:'',//
} }
}, },
onLoad(options) { onLoad(options) {
this.optionsType = options.type this.optionsType = options.type
this.planOrderId = options.id
this.getDetails() this.getDetails()
}, },
methods: { methods: {
getDetails() { getDetails() {
this.$u.api.getTaskDetail().then(res => { let query_={
id:this.planOrderId
}
this.$u.api.getTaskDetail(query_).then(res => {
if (res.code == 200) { if (res.code == 200) {
this.detailForm = res.data this.detailForm = res.data
} }

@ -31,11 +31,10 @@
</view> --> </view> -->
<u-form labelPosition="left" ref="sendOrderForm" :model="detailForm" :label-width="200" class="repair_form"> <u-form labelPosition="left" ref="sendOrderForm" :model="detailForm" :label-width="200" class="repair_form">
<u-form-item label="巡检内容:" prop="dispatchTime" :border-bottom="false"> <u-form-item label="巡检内容:" prop="dispatchTime" :border-bottom="false">
<betone-new-input label="" v-model="detailForm.dispatchTime" placeholder="" /> <betone-new-input label="" v-model="detailForm.taskContent" placeholder="" />
</u-form-item> </u-form-item>
<u-form-item label="任务开始时间:" prop="planCompleteTime" :border-bottom="false"> <u-form-item label="任务开始时间:" prop="dispatchTime" :border-bottom="false">
<!-- <u-input v-model="sendOrder.planCompleteTime" type="select" @click="calendarShow = true" <betone-new-input label="" v-model="detailForm.startTime" placeholder="" />
:border="true" placeholder="请选择时间" /> -->
</u-form-item> </u-form-item>
<u-form-item label="预约上门时间:" prop="customerOpinion" :border-bottom="false"> <u-form-item label="预约上门时间:" prop="customerOpinion" :border-bottom="false">
<u-input v-model="reservationTime" type="select" @click="calendarShow = true" :border="true" <u-input v-model="reservationTime" type="select" @click="calendarShow = true" :border="true"
@ -111,13 +110,22 @@ export default {
let query = { let query = {
id: this.detailForm.id id: this.detailForm.id
} }
//
this.$u.api.taskServicemanreceive(query).then(res => { this.$u.api.taskServicemanreceive(query).then(res => {
if (res.code == 200) { if (res.code == 200) {
// setTimeout(() => { let query_ = {
// uni.navigateBack({ id: this.detailForm.id,
// delta: 1 // 1退 reservationTime: this.reservationTime
// }) }
// },500) this.$u.api.taskServicemanUpdateTime(query_).then(res => {
uni.showToast({ title: "接收成功", icon: "none" });
setTimeout(() => {
uni.navigateBack({
delta: 1 // 1退
})
}, 500)
})
} }
}) })
}, },

@ -1,5 +1,5 @@
<template> <template>
<view class="page-css"> <view class="">
<planList></planList> <planList></planList>
<betone-loading ref="BetLoading" /> <betone-loading ref="BetLoading" />

@ -4,6 +4,11 @@ const ordinary = [{
selectedIconPath: "photo-fill", selectedIconPath: "photo-fill",
text: "接单记录", text: "接单记录",
pagePath: "/pages/order/tasking", pagePath: "/pages/order/tasking",
}, {
iconPath: "setting",
selectedIconPath: "setting-fill",
text: "巡检任务",
pagePath: "/pages/inspection/quest",
},{ },{
iconPath: "account", iconPath: "account",
selectedIconPath: "account-fill", selectedIconPath: "account-fill",
@ -38,8 +43,8 @@ const manage = [{
}, { }, {
iconPath: "setting", iconPath: "setting",
selectedIconPath: "setting-fill", selectedIconPath: "setting-fill",
text: "巡检计划", text: "巡检任务",
pagePath: "/pages/inspection/plan", pagePath: "/pages/inspection/quest",
}, { }, {
iconPath: "account", iconPath: "account",
selectedIconPath: "account-fill", selectedIconPath: "account-fill",
@ -63,6 +68,7 @@ const repair = [{
text: "我的", text: "我的",
pagePath: "/pages/my/my", pagePath: "/pages/my/my",
}] }]
// 未审核的账号看到的菜单
const oathTab = [{ const oathTab = [{
iconPath: "photo", iconPath: "photo",
selectedIconPath: "photo-fill", selectedIconPath: "photo-fill",

Loading…
Cancel
Save