|
|
|
@ -89,14 +89,23 @@ |
|
|
|
class="el-button el-button--primary el-button--medium"> |
|
|
|
{{ "导出" }} |
|
|
|
</download-excel> |
|
|
|
<el-button type="primary" v-if="!authSearch" @click="transferOrderHandle()">转单</el-button> |
|
|
|
</el-form-item> |
|
|
|
</el-form> |
|
|
|
|
|
|
|
<el-table |
|
|
|
:height="height" |
|
|
|
:data="dataList" |
|
|
|
@selection-change="selectionChangeHandle" |
|
|
|
border |
|
|
|
style="width: 100%;"> |
|
|
|
<el-table-column |
|
|
|
type="selection" |
|
|
|
header-align="center" |
|
|
|
align="center" |
|
|
|
:selectable="selectableStatus" |
|
|
|
width="50"> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column |
|
|
|
prop="buDesc" |
|
|
|
header-align="center" |
|
|
|
@ -720,6 +729,7 @@ |
|
|
|
import {userFavoriteList, saveUserFavorite, removeUserFavorite} from '@/api/userFavorite.js' |
|
|
|
import reportImageUpload from "./report_image_upload.vue" |
|
|
|
import UploadFileList from "../common/uploadFileList.vue"; |
|
|
|
import {updateRepairTypes} from "../../../api/eam/eam"; |
|
|
|
export default { |
|
|
|
components: { |
|
|
|
Chooselist, |
|
|
|
@ -2168,7 +2178,7 @@ |
|
|
|
|
|
|
|
// 多选 |
|
|
|
selectionChangeHandle (val) { |
|
|
|
this.dataListSelections = val |
|
|
|
this.dataListSelections = val |
|
|
|
}, |
|
|
|
|
|
|
|
// 选择到达人员 |
|
|
|
@ -2706,14 +2716,14 @@ |
|
|
|
}) |
|
|
|
}, |
|
|
|
|
|
|
|
getCorePartSpareList () { |
|
|
|
async getCorePartSpareList () { |
|
|
|
let tempData = { |
|
|
|
site: this.saveData.site, |
|
|
|
buNo: this.saveData.buNo, |
|
|
|
objectID: this.saveData.objectID, |
|
|
|
orderNo: this.saveData.orderNo, |
|
|
|
} |
|
|
|
getDeviceCorePartList(tempData).then(({data}) => { |
|
|
|
await getDeviceCorePartList(tempData).then(({data}) => { |
|
|
|
if (data && data.code === 0) { |
|
|
|
this.corePartSpareList = data.rows |
|
|
|
} else { |
|
|
|
@ -2722,8 +2732,8 @@ |
|
|
|
}) |
|
|
|
}, |
|
|
|
|
|
|
|
coreComponentModal () { |
|
|
|
this.getCorePartSpareList() |
|
|
|
async coreComponentModal () { |
|
|
|
await this.getCorePartSpareList() |
|
|
|
this.coreComponentData = { |
|
|
|
site: this.saveData.site, |
|
|
|
buNo: this.saveData.buNo, |
|
|
|
@ -2776,7 +2786,35 @@ |
|
|
|
this.coreComponentData.oldSerialNo = '' |
|
|
|
this.coreComponentData.newSerialNo = '' |
|
|
|
} |
|
|
|
} |
|
|
|
}, |
|
|
|
selectableStatus (row) { |
|
|
|
// 只允许未开工的工单转单 |
|
|
|
return row.status === '未开工' |
|
|
|
}, |
|
|
|
// 转单方法 |
|
|
|
transferOrderHandle () { |
|
|
|
console.log(this.dataListSelections) |
|
|
|
if (this.dataListSelections.length === 0) { |
|
|
|
this.$message.warning('请选择要转单的工单!') |
|
|
|
return |
|
|
|
} |
|
|
|
this.dataListSelections[0].repairType = '设备维修组' |
|
|
|
updateRepairTypes(this.dataListSelections).then(({data}) => { |
|
|
|
if (data && data.code === 0) { |
|
|
|
this.$message({ |
|
|
|
message: '转单成功', |
|
|
|
type: 'success', |
|
|
|
duration: 1500, |
|
|
|
onClose: () => {} |
|
|
|
}) |
|
|
|
this.getDataList() |
|
|
|
} else { |
|
|
|
this.$alert(data.msg, '错误', { |
|
|
|
confirmButtonText: '确定' |
|
|
|
}) |
|
|
|
} |
|
|
|
}) |
|
|
|
}, |
|
|
|
} |
|
|
|
} |
|
|
|
</script> |
|
|
|
|