|
|
@ -144,19 +144,46 @@ |
|
|
<el-form-item :label="'实际执行人员'"> |
|
|
<el-form-item :label="'实际执行人员'"> |
|
|
<el-input v-model="saveData.actualOperatorName" disabled style="width: 120px"></el-input> |
|
|
<el-input v-model="saveData.actualOperatorName" disabled style="width: 120px"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
|
|
|
<el-form-item> |
|
|
|
|
|
<span v-if="saveData.status === '已完工'" slot="label"><a>协同人员</a></span> |
|
|
|
|
|
<span v-if="saveData.status === '待审核'" slot="label" @click="getOperatorList()"><a>协同人员</a></span> |
|
|
|
|
|
<el-input v-model="saveData.operator" readonly style="width: 120px"></el-input> |
|
|
|
|
|
</el-form-item> |
|
|
<el-form-item :label="'维保结论'"> |
|
|
<el-form-item :label="'维保结论'"> |
|
|
<el-input v-model="saveData.checkResult" disabled style="width: 120px"></el-input> |
|
|
|
|
|
|
|
|
<el-select v-if="saveData.status === '待审核'" v-model="saveData.checkResult" style="width: 120px"> |
|
|
|
|
|
<el-option label="合格" value="合格"></el-option> |
|
|
|
|
|
<el-option label="异常" value="异常"></el-option> |
|
|
|
|
|
</el-select> |
|
|
|
|
|
<el-select v-if="saveData.status === '已完工'" v-model="saveData.checkResult" disabled style="width: 120px"> |
|
|
|
|
|
<el-option label="合格" value="合格"></el-option> |
|
|
|
|
|
<el-option label="异常" value="异常"></el-option> |
|
|
|
|
|
</el-select> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item v-if="this.saveData.checkResult === '异常'" :label="'异常原因'"> |
|
|
<el-form-item v-if="this.saveData.checkResult === '异常'" :label="'异常原因'"> |
|
|
<el-input v-model="saveData.disposalMeasures" disabled style="width: 120px"></el-input> |
|
|
|
|
|
|
|
|
<el-select v-if="saveData.status === '已完工'" disabled v-model="saveData.disposalMeasures" style="width: 120px"> |
|
|
|
|
|
<el-option label="缺少备件" value="缺少备件"></el-option> |
|
|
|
|
|
<el-option label="等待售后" value="等待售后"></el-option> |
|
|
|
|
|
<el-option label="远程协助" value="远程协助"></el-option> |
|
|
|
|
|
<el-option label="换班换人" value="换班换人"></el-option> |
|
|
|
|
|
</el-select> |
|
|
|
|
|
<el-select v-if="saveData.status === '待审核'" v-model="saveData.disposalMeasures" style="width: 120px"> |
|
|
|
|
|
<el-option label="缺少备件" value="缺少备件"></el-option> |
|
|
|
|
|
<el-option label="等待售后" value="等待售后"></el-option> |
|
|
|
|
|
<el-option label="远程协助" value="远程协助"></el-option> |
|
|
|
|
|
<el-option label="换班换人" value="换班换人"></el-option> |
|
|
|
|
|
</el-select> |
|
|
|
|
|
<!-- <el-input v-if="saveData.status === '已完工'" v-model="saveData.disposalMeasures" disabled style="width: 120px"></el-input>--> |
|
|
|
|
|
<!-- <el-input v-if="saveData.status === '待审核'" v-model="saveData.disposalMeasures" style="width: 120px"></el-input>--> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
</el-form> |
|
|
</el-form> |
|
|
<el-form :inline="true" label-position="top" > |
|
|
<el-form :inline="true" label-position="top" > |
|
|
<el-form-item :label="'工作时间'"> |
|
|
<el-form-item :label="'工作时间'"> |
|
|
<el-input v-model="saveData.workTime" type="number" disabled style="width: 120px"></el-input> |
|
|
|
|
|
|
|
|
<el-input v-if="saveData.status === '已完工'" v-model="saveData.workTime" type="number" :min="0" disabled style="width: 120px"></el-input> |
|
|
|
|
|
<el-input v-if="saveData.status === '待审核'" v-model="saveData.workTime" type="number" :min="0" style="width: 120px"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item :label="'执行结果备注'"> |
|
|
<el-form-item :label="'执行结果备注'"> |
|
|
<el-input v-model="saveData.remark" disabled style="width: 523px"></el-input> |
|
|
|
|
|
|
|
|
<el-input v-if="saveData.status === '已完工'" v-model="saveData.remark" disabled style="width: 523px"></el-input> |
|
|
|
|
|
<el-input v-if="saveData.status === '待审核'" v-model="saveData.remark" style="width: 523px"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item :label="' '"> |
|
|
<el-form-item :label="' '"> |
|
|
<el-button v-if="saveData.status === '已完工'" type="primary" @click="checkModal()">取消审核</el-button> |
|
|
<el-button v-if="saveData.status === '已完工'" type="primary" @click="checkModal()">取消审核</el-button> |
|
|
@ -187,11 +214,11 @@ |
|
|
:header-align="item.headerAlign" |
|
|
:header-align="item.headerAlign" |
|
|
:show-overflow-tooltip="item.showOverflowTooltip" |
|
|
:show-overflow-tooltip="item.showOverflowTooltip" |
|
|
:align="item.align" |
|
|
:align="item.align" |
|
|
:fixed="item.fixed==''?false:item.fixed" |
|
|
|
|
|
|
|
|
:fixed="item.fixed === '' ? false : item.fixed" |
|
|
:min-width="item.columnWidth" |
|
|
:min-width="item.columnWidth" |
|
|
:label="item.columnLabel"> |
|
|
:label="item.columnLabel"> |
|
|
<template slot-scope="scope"> |
|
|
<template slot-scope="scope"> |
|
|
<span v-if="!item.columnHidden"> {{ scope.row[item.columnProp] }}</span> |
|
|
|
|
|
|
|
|
<span v-if="!item.columnHidden">{{scope.row[item.columnProp]}}</span> |
|
|
<span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" style="width: 100px; height: 80px"/></span> |
|
|
<span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" style="width: 100px; height: 80px"/></span> |
|
|
</template> |
|
|
</template> |
|
|
</el-table-column> |
|
|
</el-table-column> |
|
|
@ -212,7 +239,11 @@ |
|
|
min-width="80" |
|
|
min-width="80" |
|
|
label="检验结论"> |
|
|
label="检验结论"> |
|
|
<template slot-scope="scope"> |
|
|
<template slot-scope="scope"> |
|
|
<el-select v-model="scope.row.itemResult" disabled style="height: 11px;padding: 0px"> |
|
|
|
|
|
|
|
|
<el-select v-if="saveData.status === '已完工'" v-model="scope.row.itemResult" disabled style="height: 11px;padding: 0px"> |
|
|
|
|
|
<el-option label="合格" value="合格"></el-option> |
|
|
|
|
|
<el-option label="不合格" value="不合格"></el-option> |
|
|
|
|
|
</el-select> |
|
|
|
|
|
<el-select v-if="saveData.status === '待审核'" v-model="scope.row.itemResult" style="height: 11px;padding: 0px"> |
|
|
<el-option label="合格" value="合格"></el-option> |
|
|
<el-option label="合格" value="合格"></el-option> |
|
|
<el-option label="不合格" value="不合格"></el-option> |
|
|
<el-option label="不合格" value="不合格"></el-option> |
|
|
</el-select> |
|
|
</el-select> |
|
|
@ -221,6 +252,7 @@ |
|
|
</el-table> |
|
|
</el-table> |
|
|
</div> |
|
|
</div> |
|
|
<el-footer style="height:40px;margin-top: 20px;text-align:center"> |
|
|
<el-footer style="height:40px;margin-top: 20px;text-align:center"> |
|
|
|
|
|
<el-button v-if="saveData.status === '待审核'" type="primary" @click="updateWorkOrder()">确定</el-button> |
|
|
<el-button type="primary" @click="detailModelFlag = false">关闭</el-button> |
|
|
<el-button type="primary" @click="detailModelFlag = false">关闭</el-button> |
|
|
</el-footer> |
|
|
</el-footer> |
|
|
</el-dialog> |
|
|
</el-dialog> |
|
|
@ -265,6 +297,60 @@ |
|
|
</el-footer> |
|
|
</el-footer> |
|
|
</el-dialog> |
|
|
</el-dialog> |
|
|
|
|
|
|
|
|
|
|
|
<!-- 人员 --> |
|
|
|
|
|
<el-dialog title="人员清单" :close-on-click-modal="false" v-drag :visible.sync="operatorModelFlag" width="520px"> |
|
|
|
|
|
<div class="rq"> |
|
|
|
|
|
<el-form :inline="true" label-position="top" :model="operatorData"> |
|
|
|
|
|
<el-form-item :label="'人员编码'"> |
|
|
|
|
|
<el-input v-model="operatorData.adminID" style="width: 120px"></el-input> |
|
|
|
|
|
</el-form-item> |
|
|
|
|
|
<el-form-item :label="'人员名称'"> |
|
|
|
|
|
<el-input v-model="operatorData.adminName" style="width: 120px"></el-input> |
|
|
|
|
|
</el-form-item> |
|
|
|
|
|
<el-form-item :label="' '"> |
|
|
|
|
|
<el-button type="primary" @click="getOperatorList()">查询</el-button> |
|
|
|
|
|
</el-form-item> |
|
|
|
|
|
</el-form> |
|
|
|
|
|
<el-table |
|
|
|
|
|
:height="300" |
|
|
|
|
|
:data="operatorList" |
|
|
|
|
|
ref="operatorTable" |
|
|
|
|
|
@row-click="operatorClickRow" |
|
|
|
|
|
@selection-change="selectionOperator" |
|
|
|
|
|
:row-key="getRowKeys" |
|
|
|
|
|
border |
|
|
|
|
|
v-loading="dataListLoading" |
|
|
|
|
|
style="width: 100%;"> |
|
|
|
|
|
<el-table-column |
|
|
|
|
|
type="selection" |
|
|
|
|
|
header-align="center" |
|
|
|
|
|
align="center" |
|
|
|
|
|
:reserve-selection="true" |
|
|
|
|
|
width="50"> |
|
|
|
|
|
</el-table-column> |
|
|
|
|
|
<el-table-column |
|
|
|
|
|
v-for="(item,index) in operatorDetailList" :key="index" |
|
|
|
|
|
:sortable="item.columnSortable" |
|
|
|
|
|
:prop="item.columnProp" |
|
|
|
|
|
:header-align="item.headerAlign" |
|
|
|
|
|
:show-overflow-tooltip="item.showOverflowTooltip" |
|
|
|
|
|
:align="item.align" |
|
|
|
|
|
:fixed="item.fixed==''?false:item.fixed" |
|
|
|
|
|
:min-width="item.columnWidth" |
|
|
|
|
|
:label="item.columnLabel"> |
|
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
|
<span v-if="!item.columnHidden">{{scope.row[item.columnProp]}}</span> |
|
|
|
|
|
<span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" style="width: 100px; height: 80px"/></span> |
|
|
|
|
|
</template> |
|
|
|
|
|
</el-table-column> |
|
|
|
|
|
</el-table> |
|
|
|
|
|
</div> |
|
|
|
|
|
<el-footer style="height:40px;margin-top: 20px;text-align:center"> |
|
|
|
|
|
<el-button type="primary" @click="confirmOperator()">确认</el-button> |
|
|
|
|
|
<el-button type="primary" @click="operatorModelFlag = false">关闭</el-button> |
|
|
|
|
|
</el-footer> |
|
|
|
|
|
</el-dialog> |
|
|
|
|
|
|
|
|
<Chooselist ref="baseList" @getBaseData="getBaseData"></Chooselist> |
|
|
<Chooselist ref="baseList" @getBaseData="getBaseData"></Chooselist> |
|
|
|
|
|
|
|
|
</div> |
|
|
</div> |
|
|
@ -276,9 +362,10 @@ |
|
|
cancelOrder, |
|
|
cancelOrder, |
|
|
changeOrderOperator, |
|
|
changeOrderOperator, |
|
|
eamWorkOrderReportSearch, |
|
|
eamWorkOrderReportSearch, |
|
|
selectNameByMes, |
|
|
|
|
|
|
|
|
getOperatorList, |
|
|
checkWorkOrder, |
|
|
checkWorkOrder, |
|
|
searchFileUrl |
|
|
|
|
|
|
|
|
searchFileUrl, |
|
|
|
|
|
updateWorkOrder |
|
|
} from "@/api/eam/eam.js" |
|
|
} from "@/api/eam/eam.js" |
|
|
import Chooselist from '@/views/modules/common/Chooselist_eam' |
|
|
import Chooselist from '@/views/modules/common/Chooselist_eam' |
|
|
import {userFavoriteList, saveUserFavorite, removeUserFavorite} from '@/api/userFavorite.js' |
|
|
import {userFavoriteList, saveUserFavorite, removeUserFavorite} from '@/api/userFavorite.js' |
|
|
@ -638,7 +725,12 @@ |
|
|
objectID: '', |
|
|
objectID: '', |
|
|
checker: '', |
|
|
checker: '', |
|
|
checkerName: '', |
|
|
checkerName: '', |
|
|
status: '' |
|
|
|
|
|
|
|
|
status: '', |
|
|
|
|
|
operator: '', |
|
|
|
|
|
adminID: '', |
|
|
|
|
|
itemList: [], |
|
|
|
|
|
mesUser: '', |
|
|
|
|
|
functionType: 'B' |
|
|
}, |
|
|
}, |
|
|
columnDetailList: [ |
|
|
columnDetailList: [ |
|
|
{ |
|
|
{ |
|
|
@ -796,7 +888,41 @@ |
|
|
status: '' |
|
|
status: '' |
|
|
}, |
|
|
}, |
|
|
descImages: [], |
|
|
descImages: [], |
|
|
imageModalFlag: false |
|
|
|
|
|
|
|
|
imageModalFlag: false, |
|
|
|
|
|
operatorModelFlag: false, |
|
|
|
|
|
operatorData: { |
|
|
|
|
|
site: this.$store.state.user.site, |
|
|
|
|
|
adminID: '', |
|
|
|
|
|
adminName: '' |
|
|
|
|
|
}, |
|
|
|
|
|
operatorList:[], |
|
|
|
|
|
operatorListSelections: [], |
|
|
|
|
|
operatorDetailList: [ |
|
|
|
|
|
{ |
|
|
|
|
|
columnProp: 'adminID', |
|
|
|
|
|
headerAlign: "center", |
|
|
|
|
|
align: "center", |
|
|
|
|
|
columnLabel: '人员编码', |
|
|
|
|
|
columnHidden: false, |
|
|
|
|
|
columnImage: false, |
|
|
|
|
|
columnSortable: false, |
|
|
|
|
|
sortLv: 0, |
|
|
|
|
|
status: true, |
|
|
|
|
|
fixed: '', |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
columnProp: 'adminName', |
|
|
|
|
|
headerAlign: "center", |
|
|
|
|
|
align: "center", |
|
|
|
|
|
columnLabel: '人员名称', |
|
|
|
|
|
columnHidden: false, |
|
|
|
|
|
columnImage: false, |
|
|
|
|
|
columnSortable: false, |
|
|
|
|
|
sortLv: 0, |
|
|
|
|
|
status: true, |
|
|
|
|
|
fixed: '', |
|
|
|
|
|
}, |
|
|
|
|
|
], |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
mounted () { |
|
|
mounted () { |
|
|
@ -1066,9 +1192,14 @@ |
|
|
objectID: row.objectID, |
|
|
objectID: row.objectID, |
|
|
checker: row.checker, |
|
|
checker: row.checker, |
|
|
checkerName: row.checkerName, |
|
|
checkerName: row.checkerName, |
|
|
status: row.status |
|
|
|
|
|
}, |
|
|
|
|
|
this.detailModelFlag = true; |
|
|
|
|
|
|
|
|
status: row.status, |
|
|
|
|
|
operator: row.operator, |
|
|
|
|
|
adminID: row.adminID, |
|
|
|
|
|
itemList: [], |
|
|
|
|
|
mesUser: this.$store.state.user.name, |
|
|
|
|
|
functionType: 'B' |
|
|
|
|
|
} |
|
|
|
|
|
this.detailModelFlag = true; |
|
|
}, |
|
|
}, |
|
|
// 审核按钮 |
|
|
// 审核按钮 |
|
|
checkModal(){ |
|
|
checkModal(){ |
|
|
@ -1177,6 +1308,102 @@ |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
// 获取人员列表 |
|
|
|
|
|
getOperatorList(){ |
|
|
|
|
|
// 先清空缓存选中 |
|
|
|
|
|
this.$nextTick(() => this.$refs.operatorTable.clearSelection()) |
|
|
|
|
|
// 拿到选中的人员编号 |
|
|
|
|
|
let tempDataList = this.saveData.adminID.split(';') |
|
|
|
|
|
// 查询所有部门 |
|
|
|
|
|
getOperatorList(this.operatorData).then(({data}) => { |
|
|
|
|
|
if (data && data.code === 0) { |
|
|
|
|
|
this.operatorList = data.rows |
|
|
|
|
|
this.operatorList.forEach(val => { |
|
|
|
|
|
// 回显选中的部门 |
|
|
|
|
|
if (tempDataList.includes(val.adminID)) { |
|
|
|
|
|
this.$nextTick(() => this.$refs.operatorTable.toggleRowSelection(val, true)) |
|
|
|
|
|
} |
|
|
|
|
|
}) |
|
|
|
|
|
this.operatorModelFlag = true; |
|
|
|
|
|
}else { |
|
|
|
|
|
this.$alert(data.msg, '错误', { |
|
|
|
|
|
confirmButtonText: '确定' |
|
|
|
|
|
}) |
|
|
|
|
|
} |
|
|
|
|
|
}) |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
// 部门 |
|
|
|
|
|
operatorClickRow(row){ |
|
|
|
|
|
this.$refs.operatorTable.toggleRowSelection(row); |
|
|
|
|
|
}, |
|
|
|
|
|
// 多选 |
|
|
|
|
|
selectionOperator (val) { |
|
|
|
|
|
this.operatorListSelections = val |
|
|
|
|
|
}, |
|
|
|
|
|
getRowKeys(row) { |
|
|
|
|
|
//唯一值,一般都为id |
|
|
|
|
|
return row.adminID; |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
// 确认多选部门 |
|
|
|
|
|
confirmOperator(){ |
|
|
|
|
|
this.saveData.adminID = '' |
|
|
|
|
|
this.saveData.operator = '' |
|
|
|
|
|
for (let i = 0; i < this.operatorListSelections.length; i++) { |
|
|
|
|
|
this.saveData.adminID = this.saveData.adminID + ";" + this.operatorListSelections[i].adminID |
|
|
|
|
|
this.saveData.operator = this.saveData.operator + ";" + this.operatorListSelections[i].adminName |
|
|
|
|
|
} |
|
|
|
|
|
this.saveData.adminID = this.saveData.adminID.substring(1) |
|
|
|
|
|
this.saveData.operator = this.saveData.operator.substring(1) |
|
|
|
|
|
this.operatorModelFlag = false |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
updateWorkOrder (){ |
|
|
|
|
|
let tempFlag = 'N' |
|
|
|
|
|
if (this.saveData.checkResult === '' || this.saveData.checkResult == null) { |
|
|
|
|
|
this.$message.warning('请选择维保结论!') |
|
|
|
|
|
return |
|
|
|
|
|
} |
|
|
|
|
|
if(this.saveData.workTime === 0){ |
|
|
|
|
|
this.$message.warning('工作时长不能为0!') |
|
|
|
|
|
return |
|
|
|
|
|
} |
|
|
|
|
|
if(this.saveData.workTime < 0){ |
|
|
|
|
|
this.$message.warning('工作时长不能小于0!') |
|
|
|
|
|
return |
|
|
|
|
|
} |
|
|
|
|
|
if (this.saveData.checkResult === '不合格') { |
|
|
|
|
|
this.detailList.forEach(val => { |
|
|
|
|
|
if (val.itemResult === '不合格') { |
|
|
|
|
|
tempFlag = 'Y' |
|
|
|
|
|
} |
|
|
|
|
|
}) |
|
|
|
|
|
if (tempFlag != 'Y') { |
|
|
|
|
|
this.$message.warning('请选择不合格项目!') |
|
|
|
|
|
return |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
this.saveData.itemList = JSON.parse(JSON.stringify(this.detailList)) |
|
|
|
|
|
updateWorkOrder(this.saveData).then(({data}) => { |
|
|
|
|
|
if (data && data.code === 0) { |
|
|
|
|
|
this.getDataList() |
|
|
|
|
|
this.detailModelFlag = false |
|
|
|
|
|
this.$message({ |
|
|
|
|
|
message: '操作成功', |
|
|
|
|
|
type: 'success', |
|
|
|
|
|
duration: 1500, |
|
|
|
|
|
onClose: () => { |
|
|
|
|
|
} |
|
|
|
|
|
}) |
|
|
|
|
|
} else { |
|
|
|
|
|
this.$alert(data.msg, '错误', { |
|
|
|
|
|
confirmButtonText: '确定' |
|
|
|
|
|
}) |
|
|
|
|
|
} |
|
|
|
|
|
}) |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
</script> |
|
|
</script> |