diff --git a/src/config.js b/src/config.js
index acd21c9..c9200a4 100644
--- a/src/config.js
+++ b/src/config.js
@@ -1,6 +1,6 @@
// 应用全局配置
module.exports = {
- baseUrl: process.env.NODE_ENV === 'development' ? 'http://192.168.0.172:12080' : 'http://dev.ccwin-in.com:25202',
+ baseUrl: process.env.NODE_ENV === 'development' ? 'http://192.168.0.106:12080' : 'http://dev.ccwin-in.com:25202',
baseApi:process.env.NODE_ENV === 'development' ? '/admin-api' : '/api/admin-api',
// 应用信息
appInfo: {
diff --git a/src/pages.json b/src/pages.json
index 66f3a32..7c4ad62 100644
--- a/src/pages.json
+++ b/src/pages.json
@@ -122,6 +122,13 @@
"navigationBarBackgroundColor": "#409eff",
"navigationBarTextStyle": "white"
}
+ },{
+ "path": "pages/overhaulOrder/reqairOrderList",
+ "style": {
+ "navigationBarTitleText": "选择维修工单",
+ "navigationBarBackgroundColor": "#409eff",
+ "navigationBarTextStyle": "white"
+ }
},{
"path": "pages/upkeepOrder/index",
"style": {
diff --git a/src/pages/deviceReport/addForm.vue b/src/pages/deviceReport/addForm.vue
index 8ffff44..acafdee 100644
--- a/src/pages/deviceReport/addForm.vue
+++ b/src/pages/deviceReport/addForm.vue
@@ -5,7 +5,7 @@
-
+
+
+
+
+ {{selectFormat(form.type,appDeviceMoldType)}}
{{`请选择类型`}}
@@ -28,7 +28,7 @@
-
+
+
+
+
+ 扫描
+
+
+
+
+
+
+
+
-
+
+
+
+
@@ -85,17 +101,21 @@
deviceName: '',
factoryAreaName: '',
factoryAreaNumber: '',
- receiverType: ''
+ type: ''
},
singleColumnShow: false,
singleColumnDefaultValue: [],
singleColumnList: [],
- imgList: []
+ imgList: [],
}
},
methods: {
// 扫描设备条码
chickRightButton(field) {
+ if(!this.form.type){
+ this.$modal.showToast('请先选择类型')
+ return;
+ }
uni.scanCode({
success: function(res) {
this.form.deviceNumber = res.result
@@ -104,8 +124,12 @@
});
},
blur() {
- if (this.form.deviceNumber) {
- this.getDetailsByNumber()
+ if(this.form.deviceNumber){
+ this.getDetailsByNumber()
+ }else{
+ this.form.deviceName =''
+ this.form.factoryAreaName = ''
+ this.form.factoryAreaNumber = ''
}
},
// 获取厂区列表
@@ -125,29 +149,55 @@
// 根据设备/模具号查询信息
getDetailsByNumber() {
if (this.type == 'DEVICE'||this.type == 'TECH') {
- deviceApi.getDeviceByFactoryAreaNumber(this.form.factoryAreaNumber).then((res) => {
- if (res.data && res.data.length > 0) {
- res.data.map(item => {
- item.value = item.number
- item.label = item.name
- })
- this.deviceList = res.data
- } else {
- this.deviceList = []
+ deviceApi.getDeviceDetailsByNumber({
+ number:this.form.deviceNumber,
+ type:this.type
+ }).then((res) => {
+ // if (res.data && res.data.length > 0) {
+ // res.data.map(item => {
+ // item.value = item.number
+ // item.label = item.name
+ // })
+ // this.deviceList = res.data
+ // } else {
+ // this.deviceList = []
+ // }
+ if(!res.data){
+ this.$modal.showToast('找不到该设备')
+ this.form.deviceName =''
+ this.form.factoryAreaName = ''
+ this.form.factoryAreaNumber = ''
+ return;
}
- }).catch(()=>{})
+ this.form.deviceName = res.data.name
+ this.form.factoryAreaName = res.data.factoryAreaName
+ this.form.factoryAreaNumber = res.data.factoryAreaNumber
+ }).catch(()=>{
+ this.$modal.showToast('找不到该设备')
+ this.form.deviceName =''
+ this.form.factoryAreaName = ''
+ this.form.factoryAreaNumber = ''
+ })
} else if (this.type == 'MOLD') {
- moldApi.getMoldByFactoryAreaNumber(this.form.factoryAreaNumber).then((res) => {
- if (res.data && res.data.length > 0) {
- res.data.map(item => {
- item.value = item.number
- item.label = item.name
- })
- this.deviceList = res.data
- } else {
- this.deviceList = []
+ moldApi.getMoldDetailsByNumber({
+ number:this.form.deviceNumber
+ }).then((res) => {
+ if(!res.data){
+ this.$modal.showToast('找不到该设备')
+ this.form.deviceName =''
+ this.form.factoryAreaName = ''
+ this.form.factoryAreaNumber = ''
+ return;
}
- }).catch(()=>{})
+ this.form.deviceName = res.data.name
+ this.form.factoryAreaName = res.data.factoryAreaName
+ this.form.factoryAreaNumber = res.data.factoryAreaNumber
+ }).catch(()=>{
+ this.$modal.showToast('找不到该设备')
+ this.form.deviceName =''
+ this.form.factoryAreaName = ''
+ this.form.factoryAreaNumber = ''
+ })
}
},
// 触发提交表单
@@ -165,7 +215,7 @@
this.$modal.showToast(`请选择${this.type=='DEVICE'||this.type=='TECH'?'设备' : '模具'}`)
return;
}
- if (!this.form.receiverType) {
+ if (!this.form.type) {
this.$modal.showToast(`请选择类型'}`)
return;
}
@@ -173,7 +223,6 @@
describes: this.form.describes,
deviceNumber: this.form.deviceNumber,
factoryAreaNumber: this.form.factoryAreaNumber,
- receiverType: this.form.receiverType,
type: this.type,
filePathList: this.imgList,
}
@@ -227,8 +276,9 @@
this.form.deviceName = ''
this.getDetailsByNumber()
}
- if (this.field == 'receiverType') {
+ if (this.field == 'type') {
this.type = this.form[this.field]
+ this.getDetailsByNumber()
}
this.singleColumnShow = false
this.$emit('singleColumn', this.field, this.form[this.field])
@@ -275,8 +325,8 @@
title:'模具报修'
})
this.appDeviceMoldType = this.appDeviceMoldType.filter((item => item.value == "MOLD"))
- this.form.receiverType = this.appDeviceMoldType[0].value
}
+ this.form.type = this.appDeviceMoldType[0].value
this.getFactoryAreaList()
}
}
diff --git a/src/pages/mine/index.vue b/src/pages/mine/index.vue
index 52c8637..cff4c65 100644
--- a/src/pages/mine/index.vue
+++ b/src/pages/mine/index.vue
@@ -1,5 +1,5 @@
-
+
@@ -78,6 +78,7 @@
隐私政策
+
+
+ {{type =='DEVICE'||type == 'TECH'?'设备' : '模具'}}
+
+
+
+
+ 扫描
+
+
+
+
@@ -245,6 +257,76 @@
}
},
+ // 扫描设备条码
+ chickRightButton(field) {
+ if(!this.form.type){
+ this.$modal.showToast('请先选择类型')
+ return;
+ }
+ uni.scanCode({
+ success: function(res) {
+ this.form.deviceNumber = res.result
+ this.getDetailsByNumber()
+ }
+ });
+ },
+ blur() {
+ if(this.form.deviceNumber){
+ this.getDetailsByNumber()
+ }else{
+ this.form.deviceName =''
+ this.form.factoryAreaName = ''
+ this.form.factoryAreaNumber = ''
+ }
+ },
+ // 根据设备/模具号查询信息
+ getDetailsByNumber() {
+ if (this.type == 'DEVICE'||this.type == 'TECH') {
+ deviceApi.getDeviceDetailsByNumber({
+ number:this.form.deviceNumber,
+ type:this.type
+ }).then((res) => {
+ if(!res.data){
+ this.$modal.showToast('找不到该设备')
+ this.form.deviceName =''
+ this.form.factoryAreaName = ''
+ this.form.factoryAreaNumber = ''
+ return;
+ }
+ this.form.deviceName = res.data.name
+ this.form.factoryAreaName = res.data.factoryAreaName
+ this.form.factoryAreaNumber = res.data.factoryAreaNumber
+ }).catch(()=>{
+ this.$modal.showToast('找不到该设备')
+ this.form.deviceName =''
+ this.form.factoryAreaName = ''
+ this.form.factoryAreaNumber = ''
+ })
+ } else if (this.type == 'MOLD') {
+ moldApi.getMoldDetailsByNumber({
+ number:this.form.deviceNumber
+ }).then((res) => {
+ if(!res.data){
+ this.$modal.showToast('找不到该设备')
+ this.form.deviceName =''
+ this.form.factoryAreaName = ''
+ this.form.factoryAreaNumber = ''
+ return;
+ }
+ this.form.deviceName = res.data.name
+ this.form.factoryAreaName = res.data.factoryAreaName
+ this.form.factoryAreaNumber = res.data.factoryAreaNumber
+ }).catch(()=>{
+ this.$modal.showToast('找不到该设备')
+ this.form.deviceName =''
+ this.form.factoryAreaName = ''
+ this.form.factoryAreaNumber = ''
+ })
+ }
+ },
+ openOrder(){
+ this.$tab.navigateTo(`/pages/overhaulOrder/reqairOrderList?type=`+this.type)
+ }
},
async onLoad(option) {
if (option.type) this.type = option.type;
@@ -262,8 +344,29 @@
this.isDisabled = this.form.maintenanceNumber ||this.form.id ? true:false
};
await this.getRepairOrderList()
- this.getDeviceList()
+ // this.getDeviceList()
this.faultType = await dictApi.getDict('fault_type')
+ uni.$on('chooseOrder',data=>{
+ console.log(data)
+ if(data){
+ this.form.maintenanceNumber = data.number
+ this.form.deviceName = data.name
+ this.form.deviceNumber = data.deviceNumber
+ this.form.deviceName = data.name
+ this.form.factoryAreaName = data.factoryAreaName
+ this.form.factoryAreaNumber = data.factoryAreaNumber
+ this.isDisabled = true
+ }else{
+ this.form.maintenanceNumber = ''
+ this.form.deviceName = ''
+ this.form.deviceNumber = ''
+ this.form.deviceName = ''
+ this.form.factoryAreaName = ''
+ this.form.factoryAreaNumber =''
+ this.isDisabled = false
+ }
+
+ })
}
}
diff --git a/src/pages/overhaulOrder/addServiceRecord.vue b/src/pages/overhaulOrder/addServiceRecord.vue
index ee6ea2f..d1791fd 100644
--- a/src/pages/overhaulOrder/addServiceRecord.vue
+++ b/src/pages/overhaulOrder/addServiceRecord.vue
@@ -1,5 +1,5 @@
-
+
@@ -108,7 +108,7 @@
-
+
diff --git a/src/pages/overhaulOrder/reqairOrderList.vue b/src/pages/overhaulOrder/reqairOrderList.vue
new file mode 100644
index 0000000..adfd6d1
--- /dev/null
+++ b/src/pages/overhaulOrder/reqairOrderList.vue
@@ -0,0 +1,256 @@
+
+
+
+
+
+
+
+
+
+ {{item.describes}}
+
+
+
+
+
+
+
+
+
+ 工单单号:{{item.number}}
+
+
+ 类型:{{item.type=='DEVICE'?'设备':item.type=='TECH'?'工艺':'模具'}}
+
+
+ {{`${type=='DEVICE'?'设备' : '模具'}`}}编号:{{item.deviceNumber}}
+
+
+ {{`${type=='DEVICE'?'设备' : '模具'}`}}名称:{{item.name}}
+
+
+ 所属厂区:{{item.factoryAreaName}}
+
+
+ 班次:{{item.classesName}}
+
+
+ 故障类型:{{item.faultTypeName}}
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/src/pages/repairOrder/addForm.vue b/src/pages/repairOrder/addForm.vue
index 9471c99..6590385 100644
--- a/src/pages/repairOrder/addForm.vue
+++ b/src/pages/repairOrder/addForm.vue
@@ -16,7 +16,7 @@
-
+
+
+
+
+ 扫描
+
+
+
+
-
-
+
+
+
+
+
@@ -99,6 +111,73 @@
}
},
methods: {
+ // 扫描设备条码
+ chickRightButton(field) {
+ if(!this.form.type){
+ this.$modal.showToast('请先选择类型')
+ return;
+ }
+ uni.scanCode({
+ success: function(res) {
+ this.form.deviceNumber = res.result
+ this.getDetailsByNumber()
+ }
+ });
+ },
+ blur() {
+ if(this.form.deviceNumber){
+ this.getDetailsByNumber()
+ }else{
+ this.form.deviceName =''
+ this.form.factoryAreaName = ''
+ this.form.factoryAreaNumber = ''
+ }
+ },
+ // 根据设备/模具号查询信息
+ getDetailsByNumber() {
+ if (this.type == 'DEVICE'||this.type == 'TECH') {
+ deviceApi.getDeviceDetailsByNumber({
+ number:this.form.deviceNumber,
+ type:this.type
+ }).then((res) => {
+ if(!res.data){
+ this.$modal.showToast('找不到该设备')
+ this.form.deviceName =''
+ this.form.factoryAreaName = ''
+ this.form.factoryAreaNumber = ''
+ return;
+ }
+ this.form.deviceName = res.data.name
+ this.form.factoryAreaName = res.data.factoryAreaName
+ this.form.factoryAreaNumber = res.data.factoryAreaNumber
+ }).catch(()=>{
+ this.$modal.showToast('找不到该设备')
+ this.form.deviceName =''
+ this.form.factoryAreaName = ''
+ this.form.factoryAreaNumber = ''
+ })
+ } else if (this.type == 'MOLD') {
+ moldApi.getMoldDetailsByNumber({
+ number:this.form.deviceNumber
+ }).then((res) => {
+ if(!res.data){
+ this.$modal.showToast('找不到该设备')
+ this.form.deviceName =''
+ this.form.factoryAreaName = ''
+ this.form.factoryAreaNumber = ''
+ return;
+ }
+ this.form.deviceName = res.data.name
+ this.form.factoryAreaName = res.data.factoryAreaName
+ this.form.factoryAreaNumber = res.data.factoryAreaNumber
+ }).catch(()=>{
+ this.$modal.showToast('找不到该设备')
+ this.form.deviceName =''
+ this.form.factoryAreaName = ''
+ this.form.factoryAreaNumber = ''
+ })
+ }
+ },
// 触发提交表单
submit() {
// 校验
@@ -263,6 +342,7 @@
this.appDeviceMoldType = this.appDeviceMoldType.filter((item=>item.value!="MOLD"))
}
+ this.form.type = this.appDeviceMoldType[0].value
this.faultType = await dictApi.getDict('fault_type')
}
}
@@ -272,9 +352,17 @@
.add-form-container {
min-height: calc(100vh - 140rpx);
background: white;
- padding: 0px 30rpx 140rpx;
+ padding: 0px 0rpx 140rpx;
}
-
+
+ .u-form-item {
+ padding: 20rpx 30rpx;
+ }
+
+ .disabled {
+ background: #f5f5f5;
+ }
+
.list {
padding-bottom: 20rpx;
diff --git a/src/pages/repairOrder/detail.vue b/src/pages/repairOrder/detail.vue
index c2c771f..cf9b4f2 100644
--- a/src/pages/repairOrder/detail.vue
+++ b/src/pages/repairOrder/detail.vue
@@ -17,15 +17,39 @@
报修描述:
{{data.describes}}
-
+
+
+
+
+
+ {{selectFormat(data.classes,maintenanceShift)}}
+
+
+ {{`请选择班次`}}
+
+
+
+
+
+
+
+ {{selectFormat(data.faultType,faultType)}}
+
+
+ {{`请选择故障类型`}}
+
+
+
+
+
+
班次:
{{data.classesName}}
-
+
故障类型:
{{data.faultTypeName}}
-
创建时间:
{{$time.formatDate(data.createTime)}}
@@ -161,7 +185,9 @@
接单
+
+ 修改工单
完成
@@ -186,6 +212,8 @@
+
@@ -213,6 +241,7 @@
},
data: '', //工单信息
loading: false,
+ loading1:false,
type: "",
deviceInfo: '', //设备信息
serviceList: [], //维修内同列表
@@ -220,7 +249,14 @@
isShowSuccess: false,
orderCompleteResult: [], //订单完成类型
result: 'TEMPORARILY',
- data1: ''
+ data1: '',
+
+ singleColumnShow: false,
+ singleColumnDefaultValue: [],
+ singleColumnList: [],
+ field: '',
+ maintenanceShift: [], //班次字典项
+ faultType: [], //故障类型字典项
}
},
methods: {
@@ -293,7 +329,7 @@
}
}
-
+
const data = {
number: this.data.number,
status: this.data.status,
@@ -301,12 +337,29 @@
result: type == 2 ? this.result : '',
requestNumber: this.data.requestNumber,
}
+ // 修改工单接口参数
+ const data1 = {
+ id: this.data && this.data.id ? this.data.id : '',
+ describes: this.data.describes,
+ type: this.data.type,
+ deviceNumber: this.data.deviceNumber,
+ factoryAreaNumber: this.data.factoryAreaNumber,
+ classes: this.data.classes,
+ faultType: this.data.faultType
+ }
let tips = this.data.status == 'PENDING' ? '是否接单?' : this.data.status == 'PECEIVED' ? '是否完成?' : this.data
.status == 'COMPLETED' ? '是否验证完结?' : ''
- this.$modal.confirm(tips).then(() => {
+ this.$modal.confirm(tips).then(async () => {
this.$modal.loading('加载中')
this.loading = true
- repairOrderApi.orderClick(data).then((res) => {
+ // 如果直接点击完成先走修改工单接口
+ if (this.data.status == 'PECEIVED') {
+ await repairOrderApi.repairOrderUpdate(data1).then((res) => {}).catch(() => {
+ this.$modal.closeLoading()
+ this.loading = false
+ })
+ }
+ await repairOrderApi.orderClick(data).then((res) => {
if (res.data) {
this.$modal.showToast('操作成功')
setTimeout(() => {
@@ -372,6 +425,67 @@
}
}
});
+ },
+ selectFormat(val, array) {
+ let str = array.filter(item => item.value == val)[0].label
+ return str
+ },
+ // 单列模式
+ openSingleColumn(field, val, list) {
+ this.singleColumnList = list
+ this.field = field
+ if (val) {
+ this.singleColumnDefaultValue = [list.findIndex(item => item.value == val)]
+ } else {
+ this.singleColumnDefaultValue = []
+ }
+ this.singleColumnShow = true
+ },
+ // 单列模式点击确定之后
+ chooseSingleColumn(e) {
+ console.log(e[0])
+ this.data[this.field] = e[0].value
+ if(this.field == 'classes'){
+ this.data.classesName = e[0].label
+ }
+ if(this.field == 'faultType'){
+ this.data.faultTypeName = e[0].label
+ }
+ this.singleColumnShow = false
+ this.$emit('singleColumn', this.field, this.data[this.field])
+ this.$forceUpdate()
+ },
+ // 修改工单
+ editForm(){
+ const data = {
+ id: this.data && this.data.id ? this.data.id : '',
+ describes: this.data.describes,
+ type: this.data.type,
+ deviceNumber: this.data.deviceNumber,
+ factoryAreaNumber: this.data.factoryAreaNumber,
+ classes: this.data.classes,
+ faultType: this.data.faultType
+ }
+ this.$modal.confirm('是否修改维修工单').then(() => {
+ this.$modal.loading('加载中')
+ this.loading1 = true
+ repairOrderApi.repairOrderUpdate(data).then((res) => {
+ this.$modal.closeLoading()
+ if (res.data) {
+ this.$modal.showToast('修改成功')
+ // setTimeout(() => {
+ // this.$tab.navigateBack()
+ this.loading1 = false
+ // }, 1500)
+ } else {
+ this.$modal.showToast('修改失败')
+ this.loading1 = false
+ }
+ }).catch(() => {
+ this.$modal.closeLoading()
+ this.loading = false
+ })
+ })
}
},
async onLoad(option) {
@@ -385,7 +499,7 @@
},
- onShow() {
+ async onShow() {
if (this.data.requestNumber) {
this.getDeviceRepairDetailsByNumber()
this.list = [{
@@ -408,6 +522,8 @@
}]
}
this.getRepairOrderDetaiList()
+ this.maintenanceShift = await dictApi.getDict('maintenance_shift')
+ this.faultType = await dictApi.getDict('fault_type')
}
}
@@ -628,4 +744,23 @@
border-radius: 10rpx;
}
}
+ .select {
+ display: flex;
+ align-items: center;
+ height: 72rpx;
+ width: 100%;
+
+ .input {
+ flex: 1;
+ font-size: 28rpx;
+ color: #000000;
+ }
+
+ .placeholder {
+ flex: 1;
+ font-size: 28rpx;
+ color: rgb(192, 196, 204);
+
+ }
+ }
\ No newline at end of file
diff --git a/src/pages/repairOrder/index.vue b/src/pages/repairOrder/index.vue
index 727b970..ed54711 100644
--- a/src/pages/repairOrder/index.vue
+++ b/src/pages/repairOrder/index.vue
@@ -48,10 +48,10 @@
{{`${$time.formatDate(item.createTime)}`}}
-
+
diff --git a/src/pages/repairOrder/transfer.vue b/src/pages/repairOrder/transfer.vue
index 2aa989e..0b620cc 100644
--- a/src/pages/repairOrder/transfer.vue
+++ b/src/pages/repairOrder/transfer.vue
@@ -13,17 +13,15 @@
-
-
-
- {{selectFormat(form.deviceNumber,deviceList)}}
-
-
- {{`请选择${type=='DEVICE'||type=='TECH'?'设备' : '模具'}名称`}}
-
-
+
+
+
+ 扫描
+
+
+
@@ -104,7 +102,7 @@
return;
}
if (!this.form.deviceNumber) {
- this.$modal.showToast(`请选择${this.type=='DEVICE'||this.type=='TECH'?'设备' : '模具'}名称`)
+ this.$modal.showToast(`请选择${this.type=='DEVICE'||this.type=='TECH'?'设备' : '模具'}编码`)
return;
}
if (!this.form.receiverUserId) {
@@ -116,6 +114,7 @@
receiverType: this.form.receiverType,
deviceNumber: this.form.deviceNumber,
receiverUserId: this.form.receiverUserId,
+ factoryAreaNumber: this.form.factoryAreaNumber,
}
this.$modal.confirm('是否转办维修工单').then(() => {
this.$modal.loading('加载中')
@@ -151,6 +150,80 @@
this.form = {}
}
},
+ // 扫描设备条码
+ chickRightButton(field) {
+ if(!this.form.type){
+ this.$modal.showToast('请先选择类型')
+ return;
+ }
+ uni.scanCode({
+ success: function(res) {
+ this.form.deviceNumber = res.result
+ this.getDetailsByNumber()
+ }
+ });
+ },
+ blur() {
+ if(this.form.deviceNumber){
+ this.getDetailsByNumber()
+ }else{
+ this.form.deviceName =''
+ this.form.factoryAreaName = ''
+ this.form.factoryAreaNumber = ''
+ }
+ },
+ // 根据设备/模具号查询信息
+ getDetailsByNumber() {
+ if (this.type == 'DEVICE'||this.type == 'TECH') {
+ deviceApi.getDeviceDetailsByNumber({
+ number:this.form.deviceNumber,
+ type:this.type
+ }).then(async (res) => {
+ if(!res.data){
+ this.$modal.showToast('找不到该设备')
+ this.form.deviceName =''
+ this.form.factoryAreaName = ''
+ this.form.factoryAreaNumber = ''
+ this.selecUserList = []
+ return;
+ }
+ this.form.deviceName = res.data.name
+ this.form.factoryAreaName = res.data.factoryAreaName
+ this.form.factoryAreaNumber = res.data.factoryAreaNumber
+ await this.getSelecUser()
+ }).catch(()=>{
+ this.$modal.showToast('找不到该设备')
+ this.form.deviceName =''
+ this.form.factoryAreaName = ''
+ this.form.factoryAreaNumber = ''
+ this.selecUserList = []
+ })
+ } else if (this.type == 'MOLD') {
+ moldApi.getMoldDetailsByNumber({
+ number:this.form.deviceNumber
+ }).then(async (res) => {
+ if(!res.data){
+ this.$modal.showToast('找不到该设备')
+ this.form.deviceName =''
+ this.form.factoryAreaName = ''
+ this.form.factoryAreaNumber = ''
+ this.selecUserList = []
+ return;
+ }
+ this.form.deviceName = res.data.name
+ this.form.factoryAreaName = res.data.factoryAreaName
+ this.form.factoryAreaNumber = res.data.factoryAreaNumber
+ await this.getSelecUser()
+ }).catch(()=>{
+ this.$modal.showToast('找不到该设备')
+ this.form.deviceName =''
+ this.form.factoryAreaName = ''
+ this.form.factoryAreaNumber = ''
+ console.log(this.form)
+ this.selecUserList = []
+ })
+ }
+ },
//
selectFormat(val, array) {
let str = array.filter(item => item.value == val)[0].label
@@ -254,7 +327,8 @@
if (option.type) this.type = option.type;
if (option.id) this.form.id = option.id;
this.deviceMoldType = await dictApi.getDict('app_device_mold_type')
- this.deviceMoldType = this.deviceMoldType.filter(item => item.value != this.type)
+ this.form.receiverType = this.deviceMoldType[0].value
+ // this.deviceMoldType = this.deviceMoldType.filter(item => item.value != this.type)
}
}
@@ -263,8 +337,17 @@
.add-form-container {
min-height: calc(100vh - 140rpx);
background: white;
- padding: 0px 30rpx 140rpx;
+ padding: 0px 0rpx 140rpx;
+ }
+
+ .u-form-item {
+ padding: 20rpx 30rpx;
+ }
+
+ .disabled {
+ background: #f5f5f5;
}
+
.list {
padding-bottom: 20rpx;
diff --git a/src/pages/upkeepOrder/addServiceRecord.vue b/src/pages/upkeepOrder/addServiceRecord.vue
index df88ef5..697d251 100644
--- a/src/pages/upkeepOrder/addServiceRecord.vue
+++ b/src/pages/upkeepOrder/addServiceRecord.vue
@@ -298,8 +298,13 @@
// 重置
reset() {
if (this.form.id) {
- this.form.classes = '';
- this.form.faultType = ''
+ this.form.actualMinutes = '';
+ this.form.chargePeoples = '';
+ this.form.status = 1;
+ this.form.completionTime = '';
+ this.form.engineer = '';
+ this.form.uncompleted = '';
+ this.form.itemNumbers = [];
} else {
this.form = {}