master
zhangdi 11 months ago
parent fd1245b130
commit c8aa593660
  1. 2
      src/views/businessManagement/inspection/repair.vue
  2. 111
      src/views/businessManagement/ordinary.vue

@ -962,7 +962,7 @@ export default {
handleConfirm() {
if (this.errorForm.approveResult1 == 0) {//
if(this.errorForm.approveRemark ==''){
this.$message.success('请输入原因!')
this.$message.error('请输入原因!')
return false
}
let query = {

@ -12,7 +12,8 @@
</template>
<template slot-scope="{row}" slot="overStatusSearch">
<el-select placeholder="请选择完成状态" v-model="searchForm.overStatus">
<el-option v-for="item in overStatusList" :key="item.value" :label="item.name" :value="item.value"></el-option>
<el-option v-for="item in overStatusList" :key="item.value" :label="item.name"
:value="item.value"></el-option>
</el-select>
</template>
<template slot="fillingTimeSearch">
@ -40,7 +41,7 @@
<el-button v-show="permission.ordinaryView" @click="handleView(row)">查看</el-button>
<el-button v-show="permission.ordinaryOrder && (row.status == 101 || row.status == 400 || row.status == 205)"
@click="takeOrders(row)">{{row.status == 400 ? '派单' : '接单'}}</el-button>
@click="takeOrders(row)">{{ row.status == 400 ? '派单' : '接单' }}</el-button>
<el-button v-show="permission.ordinaryClose && row.status == 101" @click="handleClone(row)">关闭</el-button>
<el-button v-show="permission.ordinaryConfirm && row.status == 201" @click="reciveOrder(row)">确认</el-button>
@ -314,7 +315,7 @@
</div>
</template>
</el-table-column>
<el-table-column prop="productId" align="center" label="物料名称" >
<el-table-column prop="productId" align="center" label="物料名称">
<template slot-scope="scope">
<el-select @change="((val) => { changeProduct(val, scope.$index) })"
@blur="((val) => { changeProduct(val, scope.$index) })" v-loadmore="loadmoreProduct"
@ -375,7 +376,7 @@
</el-table>
</el-form-item>
<el-form-item label="维修材料"
v-if="(repairForm.isNeedMaterial == 1 && (repairForm.status == 402 || repairForm.status == 301 || repairForm.status == 403 || repairForm.status == 103 || repairForm.status == 202 || repairForm.status == 104 || repairForm.status == 203 || repairForm.status == 204 || repairForm.status == 102)) && dialogType != 'repair'">
v-if="(repairForm.isNeedMaterial == 1 && (repairForm.status == 402 || repairForm.status == 301 || repairForm.status == 403 || repairForm.status == 103 || repairForm.status == 202 || repairForm.status == 104 || repairForm.status == 203 || repairForm.status == 204 || repairForm.status == 102)) && dialogType != 'repair'">
<!-- v-if="(repairForm.isNeedMaterial == 1 && (repairForm.status >= 3)) && dialogType != 'repair'"> -->
<el-table :data="tableData" border style="width: 98%">
<el-table-column prop="materialName" align="center" label="物料名称"></el-table-column>
@ -594,7 +595,8 @@
</el-form-item>
</div>
<!-- 维修人员 上传维修完成图片列表 403 104 202 203 204 400-->
<div v-show="repairForm.status == 403 || repairForm.status == 103|| repairForm.status == 104 || repairForm.status == 202|| repairForm.status == 203|| repairForm.status == 204|| repairForm.status == 400">
<div
v-show="repairForm.status == 403 || repairForm.status == 103 || repairForm.status == 104 || repairForm.status == 202 || repairForm.status == 203 || repairForm.status == 204 || repairForm.status == 400">
<el-form-item label="维修完成图片" prop="signaturePerson" v-if="repairForm.status == 103">
<el-upload action="/api/blade-resource/oss/endpoint/put-file" list-type="picture-card" :headers="headers"
accept=".jpeg,.jpg,.png,.pdf" :file-list="completeImgList" :on-success="handleSuccess"
@ -604,7 +606,7 @@
</el-form-item>
<el-form-item label="维修完成图片" prop="signaturePerson" v-else>
<img v-for="item in completeImgList" :key="item" :src="item.url" alt=""
style="width: 148px; height: 148px;margin-right:10px;">
style="width: 148px; height: 148px;margin-right:10px;">
</el-form-item>
</div>
</el-form>
@ -786,7 +788,7 @@ export default {
prop: "overStatus",
search: true,
overHidden: true,
hide:true
hide: true
},
{
label: "设备名称",
@ -846,10 +848,10 @@ export default {
sortable: true,
},
{
label:'维修人员',
prop:"repairPersonName",
hide:false,
search:true
label: '维修人员',
prop: "repairPersonName",
hide: false,
search: true
},
{
label: "审批时间",
@ -911,7 +913,7 @@ export default {
headers: {
},
overStatusList:[],
overStatusList: [],
completeImgList: [],//
}
},
@ -954,58 +956,58 @@ export default {
this.role_id = this.userInfo.role_id
this.dataTypes = this.userInfo.dataType
// dataTypes 1: 2: 3: 4
if(this.dataTypes == 2){
// dataTypes 1: 2: 3: 4
if (this.dataTypes == 2) {
this.overStatusList = [
{
value:'101,400,205',
name:'待派单'
value: '101,400,205',
name: '待派单'
},
{
value:'201,401,402,301',
name:'待维修'
value: '201,401,402,301',
name: '待维修'
},
{
value:'403,202,405,105,406',
name:'维修完成'
value: '403,202,405,105,406',
name: '维修完成'
},
{
value:'203,204',
name:'已完成'
value: '203,204',
name: '已完成'
}
]
}else if(this.dataTypes == 3){
} else if (this.dataTypes == 3) {
this.overStatusList = [
{
value:'201',
name:'待确认'
value: '201',
name: '待确认'
},
{
value:'103,404,401',
name:'维修中'
value: '103,404,401',
name: '维修中'
},
{
value:'403,202,405,105,406',
name:'维修完成'
value: '403,202,405,105,406',
name: '维修完成'
},
{
value:'203,204',
name:'已完成'
value: '203,204',
name: '已完成'
}
]
}else if(this.dataTypes == 4){
} else if (this.dataTypes == 4) {
this.overStatusList = [
{
value:'201',
name:'待确认'
value: '201',
name: '待确认'
},
{
value:'401,105',
name:'待提交'
value: '401,105',
name: '待提交'
},
{
value:'403,104,202,203,204,400',
name:'已完成'
value: '403,104,202,203,204,400',
name: '已完成'
}
]
}
@ -1026,7 +1028,7 @@ export default {
finishTime: { required: true, message: '请选择计划完成时间', trigger: 'blur' },
repairPerson: { required: true, message: '请选择维修人员', trigger: 'blur' },
}
if(this.role_id == '1839552581620793346'){
if (this.role_id == '1839552581620793346') {
this.option.column.find(item => item.prop == 'repairPersonName').hide = true
this.option.column.find(item => item.prop == 'repairPersonName').search = false
}
@ -1186,7 +1188,7 @@ export default {
this.discountPrice = res.data.data.discountPrice == -1 ? '' : res.data.data.discountPrice
// completeImgList
this.completeImgList = res.data.data.completeImgList!=''?JSON.parse(res.data.data.completeImgList):[]
this.completeImgList = res.data.data.completeImgList != '' ? JSON.parse(res.data.data.completeImgList) : []
})
},
//
@ -1744,6 +1746,16 @@ export default {
query.discount = 0
}
let query1 = {
details: data,
applyUserId: this.userInfo.user_id, //Id
applyUser: this.userInfo.user_name, //
applyTime: moment().format('YYYY-MM-DD HH:mm:ss'), //(yyyy-MM-dd HH:mm:ss)
status: 0,
workId: this.addForm.id,
remark:'维修单申领'
}
editData(query).then(res => {
if (res.data.code == 200) {
servicemanSubmit({
@ -1752,9 +1764,14 @@ export default {
deviceName: this.repairForm.deviceName,
repairType: this.repairForm.repairType
}).then(res => {
this.$message.success("提交成功")
this.repairVisible = false
this.onLoad()
applyGoods(query1).then(res => {
if (res.data.code == 200) {
this.$message.success("提交成功")
this.repairVisible = false
this.onLoad()
}
})
})
}
})
@ -1997,7 +2014,7 @@ export default {
status: 0,
workId: this.addForm.id,
}
applyGoods(query1).then(res => {
// applyGoods(query1).then(res => {
if (res.data.code == 200) {
servicemanReceive({ id: this.addForm.id }).then(res => {
if (res.data.code == 200) {
@ -2007,7 +2024,7 @@ export default {
}
})
}
})
// })
}
} else {
//
@ -2071,8 +2088,8 @@ export default {
faultType: this.searchForm.faultType ? this.searchForm.faultType : '', //
reportUnitName: this.searchForm.reportUnitName ? this.searchForm.reportUnitName : '',
dataType: this.role_id == '1123598816738675201' ? '' : this.dataTypes,
statusSearch:this.searchForm.overStatus ? this.searchForm.overStatus : '',
repairPersonName:this.searchForm.repairPersonName ? this.searchForm.repairPersonName : ''
statusSearch: this.searchForm.overStatus ? this.searchForm.overStatus : '',
repairPersonName: this.searchForm.repairPersonName ? this.searchForm.repairPersonName : ''
}
getList(query).then(res => {
let data_ = res.data.data.records

Loading…
Cancel
Save