Browse Source

维修工单测试

master
zhang_li 9 months ago
parent
commit
6dd9b900a3
  1. 1
      src/pages/deviceReport/addForm.vue
  2. 15
      src/pages/index.vue
  3. 10
      src/pages/repairOrder/detail.vue
  4. 4
      src/pages/repairOrder/transfer.vue

1
src/pages/deviceReport/addForm.vue

@ -265,7 +265,6 @@
}, },
async onLoad(option) { async onLoad(option) {
if (option.type) this.type = option.type; if (option.type) this.type = option.type;
console.log(33,this.type)
this.appDeviceMoldType = await dictApi.getDict('app_device_mold_type') this.appDeviceMoldType = await dictApi.getDict('app_device_mold_type')
if(this.type == 'DEVICE'){ if(this.type == 'DEVICE'){
this.appDeviceMoldType = this.appDeviceMoldType.filter((item => item.value != "MOLD")) this.appDeviceMoldType = this.appDeviceMoldType.filter((item => item.value != "MOLD"))

15
src/pages/index.vue

@ -44,6 +44,7 @@
<view class="box"> <view class="box">
<view class=""> <view class="">
<view class="title">设备维护</view> <view class="title">设备维护</view>
<u-row gutter="16" style="padding:0px 20rpx ;"> <u-row gutter="16" style="padding:0px 20rpx ;">
<u-col span="3"> <u-col span="3">
<view class="icon-item" @click="open('/pages/deviceReport/index?type=DEVICE')"> <view class="icon-item" @click="open('/pages/deviceReport/index?type=DEVICE')">
@ -51,25 +52,25 @@
<view>设备报修</view> <view>设备报修</view>
</view> </view>
</u-col> </u-col>
<u-col span="3" v-if=" $store.state.user.classType == 'DEVICE' || $store.state.user.classType == 'TECH' || !$store.state.user.classType"> <u-col span="3" v-if=" $store.state.user.dept.classType == 'DEVICE' || $store.state.user.dept.classType == 'TECH' || !$store.state.user.dept.classType">
<view class="icon-item" @click="open('/pages/repairOrder/index?type=DEVICE')"> <view class="icon-item" @click="open('/pages/repairOrder/index?type=DEVICE')">
<image src="../static/images/icon5.svg" mode=""></image> <image src="../static/images/icon5.svg" mode=""></image>
<view>维修工单</view> <view>维修工单</view>
</view> </view>
</u-col> </u-col>
<u-col span="3" v-if=" $store.state.user.classType == 'DEVICE' || $store.state.user.classType == 'TECH' || !$store.state.user.classType"> <u-col span="3" v-if=" $store.state.user.dept.classType == 'DEVICE' || $store.state.user.dept.classType == 'TECH' || !$store.state.user.dept.classType">
<view class="icon-item" @click="open('/pages/overhaulOrder/index?type=DEVICE')"> <view class="icon-item" @click="open('/pages/overhaulOrder/index?type=DEVICE')">
<image src="../static/images/icon3.svg" mode=""></image> <image src="../static/images/icon3.svg" mode=""></image>
<view>检修工单</view> <view>检修工单</view>
</view> </view>
</u-col> </u-col>
<u-col span="3" v-if=" $store.state.user.classType == 'DEVICE' || $store.state.user.classType == 'TECH' || !$store.state.user.classType"> <u-col span="3" v-if=" $store.state.user.dept.classType == 'DEVICE' || $store.state.user.dept.classType == 'TECH' || !$store.state.user.dept.classType">
<view class="icon-item" @click="open('/pages/spotCheckOrder/addForm?type=DEVICE')"> <view class="icon-item" @click="open('/pages/spotCheckOrder/addForm?type=DEVICE')">
<image src="../static/images/icon2.svg" mode=""></image> <image src="../static/images/icon2.svg" mode=""></image>
<view>点检工单</view> <view>点检工单</view>
</view> </view>
</u-col> </u-col>
<u-col span="3" v-if=" $store.state.user.classType == 'DEVICE' || $store.state.user.classType == 'TECH' || !$store.state.user.classType"> <u-col span="3" v-if=" $store.state.user.dept.classType == 'DEVICE' || $store.state.user.dept.classType == 'TECH' || !$store.state.user.dept.classType">
<view class="icon-item" @click="open('/pages/upkeepOrder/index?type=DEVICE')"> <view class="icon-item" @click="open('/pages/upkeepOrder/index?type=DEVICE')">
<image src="../static/images/icon1.svg" mode=""></image> <image src="../static/images/icon1.svg" mode=""></image>
<view>保养工单</view> <view>保养工单</view>
@ -88,19 +89,19 @@
<view>模具报修</view> <view>模具报修</view>
</view> </view>
</u-col> </u-col>
<u-col span="3" v-if="$store.state.user.classType == 'MOLD' "> <u-col span="3" v-if="$store.state.user.dept.classType == 'MOLD' ">
<view class="icon-item" @click="open('/pages/repairOrder/index?type=MOLD')"> <view class="icon-item" @click="open('/pages/repairOrder/index?type=MOLD')">
<image src="../static/images/icon5.svg" mode=""></image> <image src="../static/images/icon5.svg" mode=""></image>
<view>维修工单</view> <view>维修工单</view>
</view> </view>
</u-col> </u-col>
<u-col span="3" v-if="$store.state.user.classType == 'MOLD' "> <u-col span="3" v-if="$store.state.user.dept.classType == 'MOLD' ">
<view class="icon-item" @click="open('/pages/overhaulOrder/index?type=MOLD')"> <view class="icon-item" @click="open('/pages/overhaulOrder/index?type=MOLD')">
<image src="../static/images/icon2.svg" mode=""></image> <image src="../static/images/icon2.svg" mode=""></image>
<view>检修工单</view> <view>检修工单</view>
</view> </view>
</u-col> </u-col>
<u-col span="3" v-if="$store.state.user.classType == 'MOLD' "> <u-col span="3" v-if="$store.state.user.dept.classType == 'MOLD' ">
<view class="icon-item" @click="open('/pages/maintenWorkOrderList/index')"> <view class="icon-item" @click="open('/pages/maintenWorkOrderList/index')">
<image src="../static/images/icon1.svg" mode=""></image> <image src="../static/images/icon1.svg" mode=""></image>
<view>保养工单</view> <view>保养工单</view>

10
src/pages/repairOrder/detail.vue

@ -71,19 +71,19 @@
<view class="dec" v-if="changeItem.value == 1"> <view class="dec" v-if="changeItem.value == 1">
<view class="dec-item"> <view class="dec-item">
<view>设备编号</view> <view>设备编号</view>
<view>{{data1.deviceNumber}}</view> <view>{{data.deviceNumber}}</view>
</view> </view>
<view class="dec-item"> <view class="dec-item">
<view>设备名称</view> <view>设备名称</view>
<view>{{data1.name}}</view> <view>{{data.name}}</view>
</view> </view>
<view class="dec-item"> <view class="dec-item">
<view>所属厂区</view> <view>所属厂区</view>
<view>{{data1.factoryAreaName}}</view> <view>{{data.factoryAreaName}}</view>
</view> </view>
<view class="dec-item"> <view class="dec-item">
<view>设备类型</view> <view>设备类型</view>
<view>{{data1.type == 'DEVICE'?'设备':data1.type == 'TECH'?'工艺':'模具'}}</view> <view>{{data.type == 'DEVICE'?'设备':data1.type == 'TECH'?'工艺':'模具'}}</view>
</view> </view>
</view> </view>
<view class="dec" v-if="changeItem.value == 2"> <view class="dec" v-if="changeItem.value == 2">
@ -360,7 +360,7 @@
}) })
}, },
transfer() { transfer() {
this.$tab.navigateTo(`/pages/repairOrder/transfer?type=${this.type}&id=${this.data.id}`) this.$tab.navigateTo(`/pages/repairOrder/transfer?type=${this.data.type}&id=${this.data.id}`)
}, },
previewImage(current, array) { previewImage(current, array) {
uni.previewImage({ uni.previewImage({

4
src/pages/repairOrder/transfer.vue

@ -175,11 +175,13 @@
this.type = this.form[this.field] this.type = this.form[this.field]
this.form.deviceName = '' this.form.deviceName = ''
this.form.deviceNumber = '' this.form.deviceNumber = ''
this.form.receiverUserId = undefined
this.getDeviceList() this.getDeviceList()
} else if (this.field == 'deviceNumber') { } else if (this.field == 'deviceNumber') {
this.choosesingleColumnItem = this.singleColumnList.filter(item => item.number == e[0].value) this.choosesingleColumnItem = this.singleColumnList.filter(item => item.number == e[0].value)
this.form.factoryAreaName = this.choosesingleColumnItem[0].factoryAreaName this.form.factoryAreaName = this.choosesingleColumnItem[0].factoryAreaName
this.form.factoryAreaNumber = this.choosesingleColumnItem[0].factoryAreaNumber this.form.factoryAreaNumber = this.choosesingleColumnItem[0].factoryAreaNumber
this.form.receiverUserId = undefined
this.getSelecUser() this.getSelecUser()
} }
this.singleColumnShow = false this.singleColumnShow = false
@ -252,7 +254,7 @@
async onLoad(option) { async onLoad(option) {
if (option.type) this.type = option.type; if (option.type) this.type = option.type;
if (option.id) this.form.id = option.id; if (option.id) this.form.id = option.id;
this.deviceMoldType = await dictApi.getDict('device_mold_type') this.deviceMoldType = await dictApi.getDict('app_device_mold_type')
this.deviceMoldType = this.deviceMoldType.filter(item => item.value != this.type) this.deviceMoldType = this.deviceMoldType.filter(item => item.value != this.type)
} }
} }

Loading…
Cancel
Save