代码提交

test
zhangdi 1 year ago
parent 90444aef03
commit 2a68026277
  1. 35
      App.vue
  2. 18
      api/api.js
  3. 15
      common/betone_components/betone-list.vue
  4. 4
      main.js
  5. 2
      manifest.json
  6. 10
      pages/home/index.vue
  7. 274
      pages/inspection/components/detailsCollapse.vue
  8. 2
      pages/inspection/planDetails.vue
  9. 17
      pages/inspection/quest.vue
  10. 2
      pages/inspection/questDetails.vue
  11. 26
      pages/inspection/questOrder.vue
  12. 46
      pages/order/location.vue
  13. 8
      pages/submission/components/subForm.vue

@ -1,9 +1,9 @@
<script>
export default {
onLaunch: function (options) {
onLaunch(options) {
uni.hideTabBar()
const Pages = options.path;
this.updatePosition()
//
const WHITE = [
"pages/login/login",
@ -24,6 +24,7 @@ export default {
if (userInfo) {
//
this.$store.dispatch("changeTabbar", userInfo);
}
}
@ -32,9 +33,37 @@ export default {
onReady() {
},
onShow: function () {
onShow() {
},
methods: {
updatePosition() {
const userInfo = uni.getStorageSync("userinfo");
console.log(333333,this.$store.state.dataType)
// if (this.$store.state.dataType == 4) {
// uni.getLocation({
// type: 'wgs84',
// success: (res) => {
let query = {
id: userInfo.user_id,
// "addressLon": res.longitude,
// "addressLat": res.latitude
"addressLon": 120.4732160947301,
"addressLat": 36.17767397801995
}
this.$u.api.updatePosition(query).then(res => {
})
// },
// fail: (err) => {
// this.error = err;
// console.error(':', err);
// }
// });
// }
},
},
onHide: function () {
console.log("App Hide");

@ -235,6 +235,11 @@ const install = (Vue, vm) => {
authorizations: true,
isparams: false
})
// 获取巡检维修详情
let getRepairDetail = (params) => http.get('/lab-ops/maintenance/repair-detail', params, {
authorizations: true,
isparams: false
})
// 主管审核并指定维修人员
let taskSupervisorconfirm = (params) => http.post('/lab-ops/maintenance/task-supervisor-confirm', params, {
authorizations: true,
@ -332,8 +337,19 @@ const install = (Vue, vm) => {
authorizations: true,
isparams: false
})
// 更新维修人员经纬度
let updatePosition = (params) => http.post('/blade-system/user/updateCoordinate', params, {
authorizations: true,
isparams: false
})
// 获取
let getPosition = (params) => http.get('/blade-system/user/getCoordinate', params, {
authorizations: true,
isparams: false
})
// 将各个定义的接口名称,统一放进对象挂载到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, taskServicemanUpdateTime, getPlanDetail, getRepairPage, updateDetaile, taskServicemanSubmit, taskCustomerConfirm, taskCustomerRefuse, taskSolutionSave, taskSolutionSubmit, repairSolutionSupervisor, repairSolutionRefuse, repairSolutionCustomer, repairCustomerRefuse, repairServicemanSubmit,repairConfirmFinish,repairRefuseFinish ,confirmPayment};
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, getRepairPage, updateDetaile, taskServicemanSubmit, taskCustomerConfirm, taskCustomerRefuse, taskSolutionSave, taskSolutionSubmit, repairSolutionSupervisor, repairSolutionRefuse, repairSolutionCustomer, repairCustomerRefuse, repairServicemanSubmit,repairConfirmFinish,repairRefuseFinish ,confirmPayment,getPosition,getRepairDetail,updatePosition};
}
export default {

@ -3,8 +3,7 @@
<view class="page-search-top">
<betone-new-input v-model="searchInfo.requirementCode" :placeholder="dataTypes == 1 ? '搜索单号' : '搜索单号或单位名称'"
icon="search" style="margin-bottom: 32rpx" @changevalue="searchData()" />
<u-tabs :list="tabList" :is-scroll="true" :current="current" @change="changeTab"
></u-tabs>
<u-tabs :list="tabList" :is-scroll="true" :current="current" @change="changeTab"></u-tabs>
</view>
<view class="order-box">
<!-- @click="goPage(item, 'details')" -->
@ -47,7 +46,7 @@
:hair-line="true" type="primary" @click="orderConfirm(item)">确认方案</u-button>
<u-button v-if="item.status == 5" size="mini" :plain="true" style="margin-right: 32rpx"
:hair-line="true" type="primary" @click="goPage(item, 'location')">查看位置</u-button>
:hair-line="true" type="primary" @click="goPageLocation(item)">查看位置</u-button>
<u-button v-if="item.status == 6" size="mini" :plain="true" style="margin-right: 32rpx"
:hair-line="true" type="primary" @click="openEvaluate(item)">评价</u-button>
</block>
@ -531,6 +530,16 @@ export default {
this.getRecordsList()
}
})
},
goPageLocation(item) {
let param = {
userid: item.repairPerson,
}
//
uni.navigateTo({
url: `/pages/order/location${this.$u.queryParams(param)}`,
})
}
},
};

@ -17,10 +17,12 @@ const app = new Vue({
...App,
store
})
app.$mount()
import request from '@/utils/request.js';
Vue.use(request, app);
// http接口API集中管理引入部分
import httpApi from '@/api/api.js'
Vue.use(httpApi, app)
// require('@/utils/request.js')(app)
app.$mount()

@ -110,7 +110,7 @@
//"ignoreVersion" : true //trueHBuilderX1.9.0
"quickapp" : {},
"mp-weixin" : {
"appid" : "",
"appid" : "wx81368cd255de5182",
"setting" : {
"urlCheck" : true
},

@ -5,7 +5,7 @@
<view class="logo-txt">科研医疗建筑运维平台</view>
<!-- <u-icon class="logo-scan" style="padding-right:12rpx" @click="scanCode" size="45" name="scan"></u-icon> -->
<!-- <u-swiper height="444" :list="swiperList" mode="none"></u-swiper> -->
<image :src="swiperList[0]" style="padding-right:12rpx;height:444rpx"></image>
<image :src="swiperList[0]" style="padding-right:12rpx;height:444rpx;width:100%"></image>
</view>
<view class="work-title">工作台</view>
<view class="workbench">
@ -56,10 +56,10 @@ export default {
onShow() {
this.$nextTick(() => {
this.$refs.tabbarRef.getPermission();
this.BetLoading.show();
setTimeout(() => {
this.BetLoading.hide();
}, 1000);
// this.BetLoading.show();
// setTimeout(() => {
// this.BetLoading.hide();
// }, 1000);
});
//
this.getUserInfo()

@ -1,274 +0,0 @@
<template>
<view>
<u-collapse :accordion="false">
<u-collapse-item v-for="(item, index) in itemList" :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.xitong }}</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"> {{ n.checkContent }}</view>
<view class="n-box-info"> {{ n.craft }}</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>
<!-- 提交按钮 -->
<jp-signature-popup ref="signature1" popup v-model="image2" @change="signChange" />
</view>
</template>
<script>
export default {
props:{
type:{
type:String,
default:''
},
collapseData:{
type:Array,
default:null
}
},
computed: {
disabled() {
return this.type=='view'
},
},
mounted(){
console.log(2222222,this.collapseData)
this.itemList = this.collapseData
},
data() {
return {
image2: '',//
signIndex: [],
satisfactionList: [
{
text: '正常',
value: 1
},
{
text: '异常',
value: 0
}
],
itemList: [
// {
// title: '',
// fangjian: [
// {
// fangjianmingcheng: '',
// neirong: [{
// xitong: '',
// detection: [
// {
// title1: '1',
// radioValue: null,
// qianzi: '',//
// },
// {
// title1: '2',
// radioValue: null,
// qianzi: '',//
// }
// ]
// }]
// },
// {
// fangjianmingcheng: '',
// neirong: [{
// xitong: '',
// detection: [
// {
// title1: '1',
// radioValue: 0
// },
// {
// title1: '2',
// radioValue: 1
// }
// ]
// }, {
// xitong: '2',
// detection: [
// {
// title1: '1',
// radioValue: 0
// },
// {
// title1: '2',
// radioValue: 1
// }
// ]
// }]
// }
// ]
// },
// {
// title: '',
// fangjian: [
// {
// fangjianmingcheng: '',
// neirong: [{
// xitong: ''
// }]
// }
// ]
// }
],
}
},
methods: {
toPop1(index, vindex, sindex, nindex) {
this.signIndex = [index, vindex, sindex, nindex]
this.$refs.signature1.toPop()
},
signChange(e) {
this.itemList[this.signIndex[0]].fangjian[this.signIndex[1]].neirong[this.signIndex[2]].detection[this.signIndex[3]].qianzi = e
}
}
}
</script>
<style lang="scss" scoped>
.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>

@ -61,10 +61,8 @@
</view>
</template>
<script>
import detailsCollapse from './components/detailsCollapse.vue'
export default {
components: {
detailsCollapse,
},
computed: {
dataTypes() {

@ -41,14 +41,14 @@
<!-- 巡检任务 客户 确认-->
<block v-if="subsectionCurrent == '0' && dataTypes == 1 && item.taskStatus == 3">
<u-button size="mini" plain style="margin-right: 32rpx"
@click.stop="openWorkOrder(item)">确认</u-button>
@click.stop="openWorkOrder(item,'tsak')">确认</u-button>
</block>
<!--巡检任务 维修人员 接单 提交-->
<block v-if="subsectionCurrent == '0' && dataTypes == 4">
<u-button v-if="item.taskStatus == 1" size="mini" plain style="margin-right: 32rpx"
@click="openWorkOrder(item)">接单</u-button>
@click="openWorkOrder(item,'tsak')">接单</u-button>
<u-button v-if="item.taskStatus == 2" size="mini" plain style="margin-right: 32rpx"
@click="openWorkOrder(item)">巡检</u-button>
@click="openWorkOrder(item,'tsak')">巡检</u-button>
</block>
<!--巡检任务 维修主管 指派 -->
<block v-if="subsectionCurrent == '0' && dataTypes == 3">
@ -61,7 +61,7 @@
<!--巡检维修 客户 -->
<block v-if="subsectionCurrent == '1' && dataTypes == 1">
<u-button v-if="item.repairStatus == 3" size="mini" plain style="margin-right: 32rpx"
@click="openWorkOrder(item)">审批</u-button>
@click="openWorkOrder(item,'repair')">审批</u-button>
<u-button v-if="item.repairStatus == 5" size="mini" plain style="margin-right: 32rpx"
@click="openEvaluate(item)">评价</u-button>
</block>
@ -73,12 +73,12 @@
<!--巡检维修 维修主管 -->
<block v-if="subsectionCurrent == '1' && dataTypes == 3">
<u-button v-if="item.repairStatus == 2" size="mini" plain style="margin-right: 32rpx"
@click="openWorkOrder(item)">审批</u-button>
@click="openWorkOrder(item,'repair')">审批</u-button>
</block>
<!--巡检维修 维修人员 -->
<block v-if="subsectionCurrent == '1' && dataTypes == 4">
<u-button v-if="item.repairStatus == 1" size="mini" plain style="margin-right: 32rpx"
@click="openWorkOrder(item)">提交</u-button>
@click="openWorkOrder(item,'repair')">提交</u-button>
<u-button v-if="item.repairStatus == 4" size="mini" plain style="margin-right: 32rpx"
@click="openModel(item, 'repairComplete')">维修完成</u-button>
</block>
@ -296,10 +296,11 @@ export default {
});
},
//
openWorkOrder(item) {
openWorkOrder(item,type) {
let param = {
id: item.id,
type: 'view'
type: 'view',
details:type
}
uni.navigateTo({
url: `/pages/inspection/questOrder${this.$u.queryParams(param)}`,

@ -91,10 +91,8 @@
</view>
</template>
<script>
import detailsCollapse from './components/detailsCollapse.vue'
export default {
components: {
detailsCollapse,
},
computed: {
dataTypes() {

@ -247,12 +247,10 @@
</view>
</template>
<script>
import detailsCollapse from './components/detailsCollapse.vue'
import website from '@/utils/website'
import { dateFormat } from '@/utils/util.js'
export default {
components: {
detailsCollapse,
},
computed: {
dataTypes() {
@ -267,6 +265,7 @@ export default {
return {
detailForm: {},
orderId: '',//id
detailsType: '',//
optionsType: '',//
reservationTime: '',//
minDate: null,
@ -320,6 +319,7 @@ export default {
onLoad(options) {
this.optionsType = options.type
this.orderId = options.id
this.detailsType = options.details
this.getDetails()
this.initDate()
this.userInfo = uni.getStorageSync("userinfo");
@ -329,12 +329,22 @@ export default {
let query = {
id: this.orderId
}
this.$u.api.getTaskDetail(query).then(res => {
if (res.code == 200) {
this.detailForm = res.data
this.collapseData = JSON.parse(JSON.stringify(res.data.details))
}
})
if (this.detailsType == 'task') {
this.$u.api.getTaskDetail(query).then(res => {
if (res.code == 200) {
this.detailForm = res.data
this.collapseData = JSON.parse(JSON.stringify(res.data.details))
}
})
} else {
this.$u.api.getRepairDetail(query).then(res => {
if (res.code == 200) {
this.detailForm = res.data
this.collapseData = JSON.parse(JSON.stringify(res.data.details))
}
})
}
},
endOrderCancel() {
uni.navigateBack({

@ -78,8 +78,17 @@ export default {
}],
userLat: null,//
userLon: null,//
userId: null,//id
userInfo: {},//
};
},
onLoad(options) {
console.log(6)
this.userId = options.userid
},
methods: {
//
rad(d) {
@ -115,15 +124,29 @@ export default {
},
//
getLocation() {
let query = {
userId: this.userId
}
this.$u.api.getPosition(query).then(res => {
if (res.code == 200) {
if (res.data == '') {
} else {
this.markers[1].latitude = data.split(',')[0]
this.markers[1].longitude = data.split(',')[1]
}
}
})
// uni.getLocation({
// type: 'wgs84',
// success: (res) => {
// this.latitude = res.latitude//
// this.longitude = res.longitude
this.markers[1].latitude = this.latitude + 20//
this.markers[1].longitude = this.longitude + 20
// this.markers[1].latitude = this.latitude + 20//
// this.markers[1].longitude = this.longitude + 20
// console.log(':', res,this.markers);
this.getDistances(this.markers[1].latitude, this.markers[1].longitude, this.markers[0].latitude, this.markers[0].longitude)
// },
// fail: (err) => {
// this.error = err;
@ -131,12 +154,25 @@ export default {
// }
// });
},
},
onload() {
getUserInfo() {
this.$u.api.getUserInfo().then(res => {
if (res.code == 200) {
this.userInfo = res.data
this.markers[0].latitude = res.data.addressLat
this.markers[0].longitude = res.data.addressLon
this.getDistances(this.markers[1].latitude, this.markers[1].longitude, this.markers[0].latitude, this.markers[0].longitude)
}
}).catch(err => {
})
}
},
mounted() {
this.getUserInfo()
this.getLocation()
},
};
</script>

@ -4,21 +4,21 @@
<view v-for="(item, index) in breakdownInfo" :key="index">
<betone-header-top :titleMin="'故障信息'" />
<u-form labelPosition="left" :rules="rules" :ref="`breakdownForm${index}`" :model="item">
<u-form-item label="" prop="businessName" :border-bottom="false">
<u-form-item prop="businessName" :border-bottom="false">
<view @click="itemIndexFn(index)" style="width: 100%">
<betone-new-input :disabled="formDisabled" label="设备名称:" v-model="item.deviceName"
placeholder="请输入" endIcon="scan" @scanSuccess="scanSuccess" :endScanIndex="index" />
</view>
</u-form-item>
<u-form-item label="" prop="businessName" :border-bottom="false">
<u-form-item prop="businessName" :border-bottom="false">
<betone-new-input :disabled="formDisabled" label="故障位置:" v-model="item.faultLocation"
placeholder="请输入" />
</u-form-item>
<u-form-item label="" prop="businessName" :border-bottom="false">
<u-form-item prop="businessName" :border-bottom="false">
<betone-new-input :disabled="formDisabled" label="故障专业类型:" v-model="item.faultType"
placeholder="请输入" />
</u-form-item>
<u-form-item label="" prop="faultDescribe" :border-bottom="false" label-width="0">
<u-form-item prop="faultDescribe" :border-bottom="false" label-width="0">
<betone-new-input :disabled="formDisabled" label="故障描述:" v-model="item.faultDescribe"
placeholder="请输入" type="textarea" :height="150" :isRequire="true" />
</u-form-item>

Loading…
Cancel
Save