报废管理
This commit is contained in:
parent
e832c75241
commit
83483e286e
|
|
@ -372,6 +372,14 @@ export function getTaskDetail(data) {
|
|||
})
|
||||
}
|
||||
|
||||
export function getCtDetailList(data) {
|
||||
return request({
|
||||
url: '/material/backApply/getCtDetailList',
|
||||
method: 'get',
|
||||
params: data,
|
||||
})
|
||||
}
|
||||
|
||||
// 退料接收编辑 保存
|
||||
export function submitUpdateBackApply(data) {
|
||||
return request({
|
||||
|
|
|
|||
|
|
@ -103,6 +103,15 @@ export function submitBackApplyApi(data) {
|
|||
})
|
||||
}
|
||||
|
||||
|
||||
export function submitCtBackApplyApi(data) {
|
||||
return request({
|
||||
url: '/material/backApply/submitCtBackInfo',
|
||||
method: 'post',
|
||||
data: data
|
||||
})
|
||||
}
|
||||
|
||||
// 退料审核新增
|
||||
export function submitBackApplyApiByCq(data) {
|
||||
return request({
|
||||
|
|
@ -148,6 +157,14 @@ export function getBackReceiveList(query) {
|
|||
params: query
|
||||
})
|
||||
}
|
||||
|
||||
export function getCtBackList(query) {
|
||||
return request({
|
||||
url: '/material/backApply/getBackCtList',
|
||||
method: 'get',
|
||||
params: query
|
||||
})
|
||||
}
|
||||
// 退料接收详情列表
|
||||
export function receiveView(data) {
|
||||
return request({
|
||||
|
|
|
|||
|
|
@ -26,6 +26,15 @@ export function addDetailsAuditApi(data) {
|
|||
})
|
||||
}
|
||||
|
||||
export function addDetailsAuditApiNew(data) {
|
||||
return request({
|
||||
url: '/material/scrap/auditNew',
|
||||
method: 'post',
|
||||
// contentType: 'application/json',
|
||||
data: data
|
||||
})
|
||||
}
|
||||
|
||||
export function getScrapRecord(query) {
|
||||
return request({
|
||||
url: '/material/scrap/getScrapRecord',
|
||||
|
|
|
|||
|
|
@ -158,7 +158,7 @@
|
|||
style="width: 240px"
|
||||
value-format="yyyy-MM-dd HH:mm:ss"
|
||||
type="datetime"
|
||||
placeholder="预计领料时间1"
|
||||
placeholder="预计领料时间"
|
||||
></el-date-picker>
|
||||
</el-form-item>
|
||||
<el-form-item label="备注" prop="roleName" label-width="90px">
|
||||
|
|
|
|||
|
|
@ -42,39 +42,7 @@
|
|||
<el-form-item label="协议号" prop="agreementCode">
|
||||
<el-input v-model="queryParams.agreementCode" disabled style="width: 240px"></el-input>
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label="类型名称" prop="status">
|
||||
<el-cascader
|
||||
:key="propsKey"
|
||||
v-model="deviceType"
|
||||
:show-all-levels="false"
|
||||
:options="deviceTypeTree"
|
||||
:props="deviceTypeTreeProps"
|
||||
filterable
|
||||
collapse-tags
|
||||
style="width: 240px"
|
||||
placeholder="类型名称"
|
||||
ref="deviceTypeCascader"
|
||||
popper-class="popper-select"
|
||||
@change="deviceTypeChange"
|
||||
></el-cascader>
|
||||
</el-form-item> -->
|
||||
<!-- <el-form-item label="规格型号" prop="typeId">
|
||||
<el-select
|
||||
v-model="queryParams.typeId"
|
||||
filterable
|
||||
clearable
|
||||
style="width: 240px"
|
||||
placeholder="请选择规格型号"
|
||||
@change="changeType"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in typeListDev"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item> -->
|
||||
|
||||
<el-form-item label="规格型号" prop="equipmentId">
|
||||
<el-cascader
|
||||
:key="propsKey"
|
||||
|
|
@ -91,12 +59,19 @@
|
|||
@change="deviceTypeChange"
|
||||
></el-cascader>
|
||||
</el-form-item>
|
||||
<el-form-item label="退料单号" prop="backCode">
|
||||
<el-input
|
||||
v-model="queryParams.backCode"
|
||||
placeholder="请输入退料单号"
|
||||
clearable
|
||||
style="width: 240px"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="退料人" prop="backPerson">
|
||||
<el-input
|
||||
v-model="queryParams.backPerson"
|
||||
placeholder="请输入退料人"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
style="width: 240px"
|
||||
/>
|
||||
</el-form-item>
|
||||
|
|
@ -119,27 +94,13 @@
|
|||
:maxlength="11"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="备注" prop="roleName">
|
||||
<el-input
|
||||
v-model="queryParams.remark"
|
||||
placeholder="请输入备注"
|
||||
clearable
|
||||
rows="1"
|
||||
type="textarea"
|
||||
style="width: 240px"
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-row>
|
||||
<el-row> </el-row>
|
||||
</el-form>
|
||||
|
||||
<el-row :gutter="10" class="mb8" v-if="!isView">
|
||||
<el-col :span="1.5">
|
||||
<el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd(0)">保存</el-button>
|
||||
</el-col>
|
||||
<el-col :span="1.5">
|
||||
<el-button type="success" plain size="mini" @click="handleAdd(1)">完成退料</el-button>
|
||||
<el-button type="success" plain size="mini" @click="handleAdd(1)">明细提交</el-button>
|
||||
</el-col>
|
||||
<el-col :span="1.5">
|
||||
</el-col>
|
||||
|
|
@ -155,19 +116,20 @@
|
|||
<el-table-column align="center" label="设备所属" prop="deviceAscription" />
|
||||
<el-table-column label="领用数量" prop="num" align="center" />
|
||||
<el-table-column align="center" label="已退数量" prop="leaseNum" />
|
||||
<el-table-column align="center" label="未退数量" >
|
||||
<el-table-column align="center" label="差缺量" prop="needNum" />
|
||||
<el-table-column align="center" label="本次退料数量" >
|
||||
<template slot-scope="scope">
|
||||
<el-input
|
||||
v-if="!isView"
|
||||
v-model.number="scope.row.needNum"
|
||||
placeholder="请输入未退数量"
|
||||
v-model.number="scope.row.nowNum"
|
||||
placeholder="请输入本次退料数量"
|
||||
type="number"
|
||||
min="1"
|
||||
min="0"
|
||||
clearable
|
||||
style="width: 100%"
|
||||
|
||||
@input="checkNowNum(scope.row)"
|
||||
/>
|
||||
<span v-else>{{ scope.row.needNum }}</span>
|
||||
<span v-else>{{ scope.row.nowNum }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="备注" align="center" prop="remark">
|
||||
|
|
@ -189,16 +151,7 @@
|
|||
<el-table-column label="成套设备名称" prop="wholeTypeName" min-width="150" align="center" :show-overflow-tooltip="true"/>
|
||||
|
||||
|
||||
<el-table-column align="center" label="领用量" width="260" prop="num">
|
||||
<template slot-scope="scope">
|
||||
<el-input-number
|
||||
:min="1"
|
||||
:max="1000"
|
||||
@change="onChangeInput($event, scope.$index)"
|
||||
v-model="scope.row.num"
|
||||
/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="领用量" width="260" prop="num"/>
|
||||
<el-table-column align="center" label="操作" width="180" v-if="!isEdit">
|
||||
<template slot-scope="scope">
|
||||
<el-button size="mini" type="danger" @click="onHandelDelete(scope.$index)">删除</el-button>
|
||||
|
|
@ -206,191 +159,6 @@
|
|||
</el-table-column>
|
||||
</el-table>
|
||||
|
||||
|
||||
|
||||
<!-- <el-table v-loading="loading" :data="leaseApplyDetails" @selection-change="handleSelectionChange" border>
|
||||
<el-table-column type="selection" min-width="55" align="center" :selectable="selectable" />
|
||||
<el-table-column label="序号" type="index" min-width="120" />
|
||||
<el-table-column
|
||||
label="机具名称"
|
||||
prop="typeName"
|
||||
min-width="150"
|
||||
align="center"
|
||||
:show-overflow-tooltip="true"
|
||||
/>
|
||||
<el-table-column
|
||||
label="规格型号"
|
||||
prop="typeCode"
|
||||
min-width="150"
|
||||
align="center"
|
||||
:show-overflow-tooltip="true"
|
||||
/>
|
||||
<el-table-column label="计量单位" prop="unitNames" min-width="100" align="center" />
|
||||
|
||||
<el-table-column label="当前在用量" align="center" prop="useNum" min-width="130"> </el-table-column>
|
||||
<el-table-column label="预退数量" align="center" prop="outNum" min-width="180"> </el-table-column> -->
|
||||
<!-- <el-table-column label="退料方式" align="center" prop="manageType" min-width="130">
|
||||
<template slot-scope="{ row }">
|
||||
<span>{{ row.manageType == '0' ? '编码退料' : '数量退料' }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="退料数量" align="center" prop="num1" min-width="130">
|
||||
<template slot-scope="{ row }">
|
||||
<span v-if="row.manageType == 1">{{
|
||||
Number(row.maintenanceNum || 0) + Number(row.passNum || 0)
|
||||
}}</span>
|
||||
<el-button v-else type="text" :disabled="isView" @click="handleSelect(row, 1)">{{
|
||||
row.numList && row.numList.length > 0 ? row.numList.length : '设备选择'
|
||||
}}</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="退料合格数量" align="center" prop="passNum" min-width="180">
|
||||
<template slot-scope="{ row }">
|
||||
<el-input-number
|
||||
v-if="row.manageType == 1"
|
||||
v-model="row.passNum"
|
||||
placeholder="合格数量"
|
||||
:min="0"
|
||||
:precision="0"
|
||||
clearable
|
||||
size="small"
|
||||
:disabled="isView"
|
||||
@change="checkNum(row)"
|
||||
/>
|
||||
<el-button v-else type="text" :disabled="isView" @click="handleSelect(row, 2)">{{
|
||||
row.passMaCodeDtoList && row.passMaCodeDtoList.length > 0
|
||||
? row.passMaCodeDtoList.length
|
||||
: '设备选择'
|
||||
}}</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="维修数量" align="center" prop="maintenanceNum" min-width="180">
|
||||
<template slot-scope="{ row }">
|
||||
<el-input-number
|
||||
v-if="row.manageType == 1"
|
||||
v-model="row.maintenanceNum"
|
||||
placeholder="维修数量"
|
||||
:min="0"
|
||||
:precision="0"
|
||||
clearable
|
||||
size="small"
|
||||
:disabled="isView"
|
||||
@change="checkNum(row)"
|
||||
/>
|
||||
<span v-else>{{ calculateDifference(row) }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="备注" align="center" prop="remark" min-width="150">
|
||||
<template slot-scope="scope">
|
||||
<el-input
|
||||
v-model="scope.row.remark"
|
||||
placeholder="请输入备注"
|
||||
clearable
|
||||
style="width: 100%"
|
||||
:disabled="isView"
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="附件" align="center" prop="fileList" min-width="200">
|
||||
<template slot-scope="scope">
|
||||
<el-upload
|
||||
class="upload-demo"
|
||||
:action="uploadUrl"
|
||||
:data="{ fileType: 'sx' }"
|
||||
:headers="headers"
|
||||
accept="image/*,application/pdf"
|
||||
:limit="5"
|
||||
:file-list="scope.row.fileList"
|
||||
:before-upload="beforeUpload"
|
||||
:before-remove="beforeRemove"
|
||||
:on-remove="(file, fileList) => handleRemove(file, fileList, scope.row)"
|
||||
:on-exceed="handleExceed"
|
||||
:on-preview="handlePreview"
|
||||
:on-success="(res, file, fileList) => handleSuccess(res, file, fileList, scope.row)"
|
||||
>
|
||||
<el-button :disabled="isView" size="mini" type="text">点击上传</el-button>
|
||||
</el-upload>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" align="center" width="160px">
|
||||
<template slot-scope="scope" v-if="scope.row.roleId !== 1">
|
||||
<el-button
|
||||
size="mini"
|
||||
type="text"
|
||||
icon="el-icon-delete"
|
||||
@click="handleDelete({ ...scope.row, index: scope.$index })"
|
||||
>删除</el-button
|
||||
>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table> -->
|
||||
|
||||
<!-- 弹框 -->
|
||||
<el-dialog title="设备出库" :visible.sync="openDialog" width="1200px" append-to-body>
|
||||
<el-row :gutter="10" class="mb8">
|
||||
<el-col :span="24" v-if="machineList[0] && machineList[0].totalNum">
|
||||
<div>待出库数量: {{ machineList[0] && machineList[0].totalNum }}</div>
|
||||
</el-col>
|
||||
<el-col :span="24">
|
||||
<div style="display: flex; align-items: center; margin: 15px">
|
||||
<span>设备编码: </span>
|
||||
<el-input
|
||||
v-model="maCode"
|
||||
placeholder="请输入"
|
||||
size="mini"
|
||||
style="margin: 0 10px; width: 220px"
|
||||
></el-input>
|
||||
<el-button type="primary" icon="el-icon-search" size="mini" @click="getMachineList"
|
||||
>查询</el-button
|
||||
>
|
||||
<el-button icon="el-icon-refresh" size="mini" @click="resetMaCode">重置</el-button>
|
||||
</div>
|
||||
</el-col>
|
||||
<el-col :span="1.5">
|
||||
<el-button type="primary" size="mini" @click="dialogConfirm">确定</el-button>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-table
|
||||
:data="machineList"
|
||||
width="100%"
|
||||
ref="codeTableList"
|
||||
height="450px"
|
||||
row-key="maId"
|
||||
reserve-selection
|
||||
@selection-change="codeSelectionChange"
|
||||
>
|
||||
<el-table-column type="selection" width="55" align="center" />
|
||||
<el-table-column label="序号" type="index" width="55" align="center" />
|
||||
<el-table-column
|
||||
label="类型名称"
|
||||
prop="typeName"
|
||||
align="center"
|
||||
:show-overflow-tooltip="true"
|
||||
></el-table-column>
|
||||
<el-table-column
|
||||
label="规格型号"
|
||||
prop="materialName"
|
||||
align="center"
|
||||
:show-overflow-tooltip="true"
|
||||
></el-table-column>
|
||||
<el-table-column
|
||||
label="设备编码"
|
||||
prop="maCode"
|
||||
align="center"
|
||||
:show-overflow-tooltip="true"
|
||||
></el-table-column>
|
||||
<el-table-column label="设备状态" prop="maStatus" align="center" :show-overflow-tooltip="true">
|
||||
<template slot-scope="scope">
|
||||
<span>在用</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<!-- <div style="width: 100%; height: 50px; display: flex; justify-content: flex-end; align-items: center">
|
||||
<el-button type="primary" size="mini" @click="saveDevCode">保存</el-button>
|
||||
<el-button type="normal" size="mini" @click="open = false">取消</el-button>
|
||||
</div> -->
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
|
|
@ -400,22 +168,14 @@ import { treeselect as menuTreeselect, roleMenuTreeselect } from '@/api/system/m
|
|||
import {
|
||||
getProData,
|
||||
getUnitData,
|
||||
getDeviceTypeTree,
|
||||
getAgreementInfoById,
|
||||
submitLeaseApply,
|
||||
getUseTypeTreee,
|
||||
getUseNumByTypeId,
|
||||
getTaskDetail,
|
||||
submitUpdateBackApply,
|
||||
getPreAuditNum,
|
||||
getUseTypeTreeCt,
|
||||
getSltCtList
|
||||
} from '@/api/claimAndRefund/receive'
|
||||
import { submitBackApplyApi, getMachineById } from '@/api/claimAndRefund/return'
|
||||
import {
|
||||
submitBackApplyApiByCq,
|
||||
materialReturnNoteByApply,
|
||||
submitRefuseBackApply,
|
||||
submitCtBackApplyApi,
|
||||
} from '@/api/claimAndRefund/return.js'
|
||||
import { mapState } from 'vuex'
|
||||
import { getInfo, h } from '@/api/login'
|
||||
|
|
@ -523,6 +283,7 @@ export default {
|
|||
taskStatus: 30,
|
||||
backTime: '', //申请时间
|
||||
backPerson: '', //退料人
|
||||
backCode: '', //退料编码
|
||||
remark: '', //备注
|
||||
//退料人信息
|
||||
leaseApplyInfo: {
|
||||
|
|
@ -672,27 +433,26 @@ export default {
|
|||
if (this.taskId && this.isEdit) {
|
||||
Promise.all([
|
||||
this.GetTaskDetail(this.taskId),
|
||||
// this.GetDeviceTypeTree(),
|
||||
])
|
||||
// .then(() => {
|
||||
// let selectList = []
|
||||
// this.leaseApplyDetails.forEach((e) => {
|
||||
// selectList.push(
|
||||
// this.getParentsById(this.deviceTypeTree, e.typeId),
|
||||
// )
|
||||
// })
|
||||
// console.log( 'selectList', selectList)
|
||||
// this.$nextTick(() => {
|
||||
// this.deviceType = selectList
|
||||
// this.propsKey++
|
||||
// })
|
||||
// })
|
||||
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
...mapState(['user']),
|
||||
},
|
||||
methods: {
|
||||
// 校验本次退料数量
|
||||
checkNowNum(row) {
|
||||
if (row.nowNum > row.needNum) {
|
||||
row.nowNum = row.needNum;
|
||||
this.$message.warning('本次退料数量不能大于差缺量');
|
||||
}else if(row.nowNum<0){
|
||||
row.nowNum = 0;
|
||||
this.$message.warning('本次退料数量不能小于0');
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
// 获取 来往单位 列表数据
|
||||
async GetUnitData() {
|
||||
const params = {
|
||||
|
|
@ -845,23 +605,6 @@ export default {
|
|||
this.leaseApplyDetails = res.data
|
||||
this.GetDeviceTypeTreeFn(data.agreementId)
|
||||
},
|
||||
//生成回显数据
|
||||
handelEchoData(item) {
|
||||
// console.log('item======', item)
|
||||
const template = JSON.parse(JSON.stringify(this.leaseApplyDetailsItem))
|
||||
template.createBy = item.createBy
|
||||
template.parentId = item.data.parentId
|
||||
template.typeId = item.data.typeId
|
||||
template.companyId = item.companyId
|
||||
// template.typeId = item.typeId
|
||||
template.unitNames = item.unitNames
|
||||
template.typeCn = item.typeName
|
||||
template.guigeCn = item.typeModelName
|
||||
template.remark = item.remark
|
||||
template.preNum = item.preNum
|
||||
template.status = item.status
|
||||
return template
|
||||
},
|
||||
|
||||
/** 查询角色列表 */
|
||||
async getList() {},
|
||||
|
|
@ -880,15 +623,6 @@ export default {
|
|||
checkedKeys.unshift.apply(checkedKeys, halfCheckedKeys)
|
||||
return checkedKeys
|
||||
},
|
||||
// 所有部门节点数据
|
||||
getDeptAllCheckedKeys() {
|
||||
// 目前被选中的部门节点
|
||||
let checkedKeys = this.$refs.dept.getCheckedKeys()
|
||||
// 半选中的部门节点
|
||||
let halfCheckedKeys = this.$refs.dept.getHalfCheckedKeys()
|
||||
checkedKeys.unshift.apply(checkedKeys, halfCheckedKeys)
|
||||
return checkedKeys
|
||||
},
|
||||
/** 根据角色ID查询菜单树结构 */
|
||||
getRoleMenuTreeselect(roleId) {
|
||||
return roleMenuTreeselect(roleId).then((response) => {
|
||||
|
|
@ -963,19 +697,6 @@ export default {
|
|||
console.log('🚀 ~ handleSelectionChange ~ selection:', selection)
|
||||
this.queryParams.leaseApplyDetails = selection
|
||||
},
|
||||
// 更多操作触发
|
||||
handleCommand(command, row) {
|
||||
switch (command) {
|
||||
case 'handleDataScope':
|
||||
this.handleDataScope(row)
|
||||
break
|
||||
case 'handleAuthUser':
|
||||
this.handleAuthUser(row)
|
||||
break
|
||||
default:
|
||||
break
|
||||
}
|
||||
},
|
||||
|
||||
/** 保存按钮操作 */
|
||||
handleAdd(type) {
|
||||
|
|
@ -983,73 +704,38 @@ export default {
|
|||
if (!valid) {
|
||||
return false
|
||||
} else {
|
||||
let backApplyInfo = []
|
||||
if (this.queryParams.leaseApplyDetails.length == 0) {
|
||||
this.$message.error('请勾选要添加数据')
|
||||
return
|
||||
}
|
||||
// const isRemark = this.queryParams.leaseApplyDetails.some(
|
||||
// (item) => item.remark == '' || item.remark == undefined
|
||||
// );
|
||||
|
||||
this.queryParams.leaseApplyDetails.forEach((item) => {
|
||||
console.log("jjjjjjjjjj",item)
|
||||
|
||||
if (item.manageType == 1) {
|
||||
item.num1 = Number(item.maintenanceNum || 0) + Number(item.passNum || 0);
|
||||
|
||||
} else {
|
||||
item.num1 = item.numList && item.numList.length > 0 ? item.numList.length : 0;
|
||||
}
|
||||
item.backNum = item.num1
|
||||
if (item.manageType == 0) {
|
||||
item.backNum = item.numList.length
|
||||
if (item.passMaCodeDtoList) {
|
||||
item.repairMaCodeDtoList = item.numList.filter(
|
||||
(item2) =>
|
||||
!item.passMaCodeDtoList.some((standardItem) => standardItem.maId == item2.maId),
|
||||
)
|
||||
}
|
||||
item.passNum = (item.passMaCodeDtoList && item.passMaCodeDtoList.length) || 0
|
||||
item.maintenanceNum = (item.repairMaCodeDtoList && item.repairMaCodeDtoList.length) || 0
|
||||
this.leaseApplyDetails.forEach((item) => {
|
||||
item.ascriptionType = 1
|
||||
if(item.maWholeLeaseDetailVoList.length>0){
|
||||
item.maWholeLeaseDetailVoList.forEach((e) => {
|
||||
if(e.nowNum===''){
|
||||
this.$message.error('本次退料数量不能为空!')
|
||||
return
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
})
|
||||
console.log("kkkkkkkkkkkkkkk",this.queryParams.leaseApplyDetails)
|
||||
const isNum = this.queryParams.leaseApplyDetails.some(
|
||||
(item) => {
|
||||
if(item.manageType == 1) {return Number(item.maintenanceNum || 0) + Number(item.passNum || 0)==0}
|
||||
else {return (!item.numList) || (Number(item.numList.length || 0)==0) }
|
||||
}
|
||||
// (item) => item.backNum == '' || item.backNum == undefined || item.backNum == 0,
|
||||
)
|
||||
if (isNum) {
|
||||
this.$message.error('退料数量不能为空!')
|
||||
return
|
||||
}
|
||||
|
||||
|
||||
this.queryParams.createBy = this.user.name
|
||||
this.queryParams.companyId = this.companyId
|
||||
this.queryParams.backApplyInfo = {
|
||||
id: this.rowId,
|
||||
backPerson: this.queryParams.backPerson,
|
||||
phone: this.queryParams.phone,
|
||||
remark: this.queryParams.remark,
|
||||
backTime: this.queryParams.backTime,
|
||||
companyId: this.companyId,
|
||||
taskId: this.taskId,
|
||||
backCode: this.queryParams.backCode,
|
||||
agreementId: this.queryParams.agreementId,
|
||||
createBy: this.queryParams.createBy,
|
||||
}
|
||||
if (this.taskId != '') {
|
||||
let params = {
|
||||
isFinishBack: type,
|
||||
companyId: this.companyId,
|
||||
createBy: this.createBy,
|
||||
id: this.rowId,
|
||||
agreementId: this.queryParams.agreementId,
|
||||
backApplyInfo: this.queryParams.backApplyInfo,
|
||||
backApplyDetails: this.queryParams.leaseApplyDetails,
|
||||
ctBackApplyInfo: this.leaseApplyDetails,
|
||||
}
|
||||
console.log('🚀 ~ this.$refs.queryForm.validate ~ params:', params)
|
||||
const res = await submitUpdateBackApply(params)
|
||||
console.log('🚀mmmmmmmmmmmmmmmmmmmmmmmmmmmmmm', params)
|
||||
const res = await submitCtBackApplyApi(params)
|
||||
if (res.code == 200) {
|
||||
this.$message({ type: 'success', message: res.msg })
|
||||
setTimeout(() => {
|
||||
|
|
@ -1059,57 +745,11 @@ export default {
|
|||
// })
|
||||
}, 1000)
|
||||
}
|
||||
} else {
|
||||
let params = {
|
||||
isFinishBack: type,
|
||||
companyId: this.companyId,
|
||||
createBy: this.createBy,
|
||||
agreementId: this.queryParams.agreementId,
|
||||
backApplyInfo: this.queryParams.backApplyInfo,
|
||||
backApplyDetails: this.queryParams.leaseApplyDetails,
|
||||
}
|
||||
console.log('🚀 ~ this.$refs.queryForm.validate ~ params:', params)
|
||||
const res = await submitBackApplyApi(params)
|
||||
if (res.code == 200) {
|
||||
this.$message({ type: 'success', message: res.msg })
|
||||
setTimeout(() => {
|
||||
this.$emit('goBackPage')
|
||||
// this.$tab.closeOpenPage({
|
||||
// path: '/claimAndRefund/return/returnApplyByCq',
|
||||
// })
|
||||
}, 1000)
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
})
|
||||
},
|
||||
/** 修改按钮操作 */
|
||||
handleBack(row) {
|
||||
this.$tab.closeOpenPage({
|
||||
path: '/claimAndRefund/return/returnApplyByCq',
|
||||
})
|
||||
},
|
||||
|
||||
/** 分配数据权限操作 */
|
||||
handleDataScope(row) {
|
||||
this.reset()
|
||||
const deptTreeSelect = this.getDeptTree(row.roleId)
|
||||
getRole(row.roleId).then((response) => {
|
||||
this.form = response.data
|
||||
this.openDataScope = true
|
||||
this.$nextTick(() => {
|
||||
deptTreeSelect.then((res) => {
|
||||
this.$refs.dept.setCheckedKeys(res.checkedKeys)
|
||||
})
|
||||
})
|
||||
this.title = '分配数据权限'
|
||||
})
|
||||
},
|
||||
/** 分配用户操作 */
|
||||
handleAuthUser: function (row) {
|
||||
const roleId = row.roleId
|
||||
this.$router.push('/system/role-auth/user/' + roleId)
|
||||
},
|
||||
/** 提交按钮 */
|
||||
submitForm: function () {
|
||||
this.$refs['form'].validate((valid) => {
|
||||
|
|
@ -1135,14 +775,6 @@ export default {
|
|||
|
||||
/** 删除按钮操作 */
|
||||
handleDelete(row) {
|
||||
// this.deviceType.forEach((e, index) => {
|
||||
// if (e[3] == row.typeId) {
|
||||
// this.$nextTick(() => {
|
||||
// this.deviceType.splice(index, 1)
|
||||
// this.propsKey++
|
||||
// })
|
||||
// }
|
||||
// })
|
||||
this.leaseApplyDetails.splice(row.index, 1)
|
||||
},
|
||||
/** 导出按钮操作 */
|
||||
|
|
@ -1188,47 +820,10 @@ export default {
|
|||
// useNum: deviceTypeList[0].data.num,
|
||||
typeName: deviceTypeList[0].parent.data.typeName,
|
||||
}
|
||||
// if (val.length > 0) {
|
||||
// const items = val.map((e) => {
|
||||
// return e[3]
|
||||
// })
|
||||
// console.log("tttttttttttttt",items)
|
||||
// for (let i in items) {
|
||||
// for (let z in deviceTypeList) {
|
||||
// if (deviceTypeList[z].data.typeId == items[i]) {
|
||||
|
||||
// let { id,} = deviceTypeList[z].data
|
||||
|
||||
// const isRepeat = this.leaseApplyDetails.some((e) => e.typeId === id)
|
||||
// if (!isRepeat) {
|
||||
// this.getMaTypeDataByIdFun(deviceTypeList[z].data)
|
||||
// }
|
||||
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// console.log('🚀 ~ deviceTypeChange ~ this.selectParams:', this.selectParams)
|
||||
|
||||
this.getMaTypeDataByIdFun(val[val.length-1])
|
||||
})
|
||||
// console.log(val, '*******************')
|
||||
|
||||
// const deviceTypeList =
|
||||
// this.$refs.deviceTypeCascader.getCheckedNodes()
|
||||
// let tempList = []
|
||||
|
||||
// if (val.length > 0) {
|
||||
// const items = val.map((e) => {
|
||||
// return e[3]
|
||||
// })
|
||||
// for (let i in items) {
|
||||
// for (let z in deviceTypeList) {
|
||||
// if (deviceTypeList[z].data.typeId == items[i]) {
|
||||
// this.getMaTypeDataByIdFun(val[val.length-1])
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
},
|
||||
// 获取规格型号
|
||||
async getMaTypeDataByIdFun(val) {
|
||||
|
|
@ -1261,185 +856,7 @@ export default {
|
|||
this.leaseApplyDetails.splice(index, 1);
|
||||
},
|
||||
|
||||
//// 将数据处理成 表格中需要的数据
|
||||
handelTableItemData(node) {
|
||||
const template = JSON.parse(JSON.stringify(this.leaseApplyDetailsItem))
|
||||
template.createBy = this.createBy
|
||||
template.typeId = node.data.typeId
|
||||
template.companyId = node.data.companyId
|
||||
// template.typeId = node.data.id
|
||||
template.unitNames = node.data.unitNames
|
||||
template.preNum = node.data.num
|
||||
template.typeName = node.pathLabels[2]
|
||||
template.typeCode = node.pathLabels[3]
|
||||
template.num = node.data.num
|
||||
template.useNum = node.data.useNum
|
||||
return template
|
||||
},
|
||||
resetMaCode() {
|
||||
this.maCode = ''
|
||||
this.getMachineList()
|
||||
},
|
||||
// 获取编码再用列表
|
||||
getMachineList() {
|
||||
const params = {
|
||||
unitId: this.queryParams.unitId,
|
||||
projectId: this.queryParams.proId,
|
||||
typeId: this.typeId,
|
||||
maCode: this.maCode,
|
||||
}
|
||||
getMachineById(params).then((res) => {
|
||||
this.machineList = res.data
|
||||
// 如果this.machineList 中 有 和row.numList 的值是对象 不再是 id 一样的值就设置选中
|
||||
this.machineList.forEach((item) => {
|
||||
if (this.diaRow.numList.some((item2) => item2.maId == item.maId)) {
|
||||
this.$nextTick(() => {
|
||||
this.$refs.codeTableList.toggleRowSelection(item, true)
|
||||
})
|
||||
}
|
||||
})
|
||||
})
|
||||
},
|
||||
// 打开弹框
|
||||
handleSelect(row, type) {
|
||||
console.log('🚀 ~ handleSelect ~ row:', row)
|
||||
if (!row.numList) row.numList = []
|
||||
if (!row.numIds) row.numIds = []
|
||||
if (!row.standardIds) row.standardIds = []
|
||||
if (!row.fileList) row.fileList = []
|
||||
this.dialogType = type
|
||||
this.selectedList = []
|
||||
this.currentRow = row
|
||||
if (type == 1) {
|
||||
this.typeId = row.typeId
|
||||
this.diaRow = row
|
||||
this.getMachineList()
|
||||
} else {
|
||||
if (row.numList.length == 0) {
|
||||
// 提示
|
||||
this.$message({
|
||||
message: '请先选择编码退料数量',
|
||||
type: 'warning',
|
||||
duration: 1000,
|
||||
})
|
||||
return
|
||||
}
|
||||
this.machineList = [...row.numList]
|
||||
this.machineList.forEach((item) => {
|
||||
if (row.passMaCodeDtoList && row.passMaCodeDtoList.some((item2) => item2.maId == item.maId)) {
|
||||
this.$nextTick(() => {
|
||||
this.$refs.codeTableList.toggleRowSelection(item, true)
|
||||
})
|
||||
}
|
||||
})
|
||||
}
|
||||
// this.calculateDifference(row)
|
||||
this.openDialog = true
|
||||
console.log('🚀 ~ handleSelect ~ row:', row)
|
||||
},
|
||||
// 弹框多选
|
||||
codeSelectionChange(selection) {
|
||||
console.log('🚀 ~ codeSelectionChange ~ selection:', selection)
|
||||
this.selectedList = selection
|
||||
},
|
||||
// 弹框确定
|
||||
dialogConfirm() {
|
||||
if (this.dialogType == 1) {
|
||||
this.currentRow.numList = this.selectedList
|
||||
this.currentRow.numIds = this.selectedList.map((item) => {
|
||||
return item.maId
|
||||
})
|
||||
this.currentRow.standardIds = []
|
||||
this.currentRow.passMaCodeDtoList = []
|
||||
} else {
|
||||
this.currentRow.passMaCodeDtoList = this.selectedList
|
||||
this.currentRow.standardIds = this.selectedList.map((item) => {
|
||||
return item.maId
|
||||
})
|
||||
}
|
||||
if (this.currentRow.numIds.length > this.currentRow.useNum) {
|
||||
this.$message({
|
||||
message: '不能超过使用数量',
|
||||
type: 'warning',
|
||||
})
|
||||
this.currentRow.numIds = []
|
||||
this.currentRow.numList = []
|
||||
return
|
||||
}
|
||||
this.openDialog = false
|
||||
},
|
||||
handleRemove(file, fileList, row) {
|
||||
console.log(file, fileList)
|
||||
console.log('🚀 ~ handleRemove ~ row:', row)
|
||||
row.fileList = fileList.map((item) => {
|
||||
let fileName = ''
|
||||
let fileUrl = ''
|
||||
if (item.response) {
|
||||
fileName = item.response.data.fileName
|
||||
fileUrl = item.response.data.fileUrl
|
||||
} else {
|
||||
fileName = item.fileName
|
||||
fileUrl = item.fileUrl
|
||||
}
|
||||
return {
|
||||
typeId: row.typeId,
|
||||
fileName: fileName,
|
||||
fileUrl: fileUrl,
|
||||
}
|
||||
})
|
||||
console.log('🚀 ~ handleRemove ~ row.fileList:', row.fileList)
|
||||
},
|
||||
handlePreview(file) {
|
||||
console.log('🚀 ~ handlePreview ~ file:', file)
|
||||
if (file.response) {
|
||||
window.open(process.env.VUE_APP_BASE_API + '/system'+ file.response.data.fileUrl)
|
||||
} else {
|
||||
window.open(process.env.VUE_APP_BASE_API + '/system'+ file.fileUrl)
|
||||
}
|
||||
},
|
||||
handleExceed(files, fileList) {
|
||||
this.$message.warning(
|
||||
`当前限制选择 5 个文件,本次选择了 ${files.length} 个文件,共选择了 ${
|
||||
files.length + fileList.length
|
||||
} 个文件`,
|
||||
)
|
||||
},
|
||||
beforeUpload(file) {
|
||||
const isLtMB = file.size / 1024 / 1024 < 20
|
||||
if (!isLtMB) {
|
||||
this.$message.error('上传文件大小不能超过 20MB!')
|
||||
}
|
||||
return isLtMB
|
||||
},
|
||||
beforeRemove(file, fileList) {
|
||||
return this.$confirm(`确定移除 ${file.name} ?`)
|
||||
},
|
||||
handleSuccess(res, file, fileList, row) {
|
||||
console.log('🚀 ~ handleSuccess ~ res:', res)
|
||||
console.log('🚀 ~ handleSuccess ~ file:', file)
|
||||
console.log('🚀 ~ handleSuccess ~ fileList:', fileList)
|
||||
console.log('🚀 ~ handleSuccess ~ row:', row)
|
||||
|
||||
if (res.code == 200) {
|
||||
if (!row.fileList) {
|
||||
row.fileList = []
|
||||
}
|
||||
row.fileList.push({
|
||||
typeId: row.typeId,
|
||||
fileName: res.data.fileName,
|
||||
name: res.data.fileName,
|
||||
fileUrl: res.data.fileUrl,
|
||||
url: res.data.fileUrl,
|
||||
})
|
||||
}
|
||||
console.log('🚀 ~ row.fileList=fileList.map ~ row.fileList:', row.fileList)
|
||||
},
|
||||
getLength(arr) {
|
||||
return Array.isArray(arr) ? arr.length : 0
|
||||
},
|
||||
calculateDifference(row) {
|
||||
return this.getLength(row.numList) - this.getLength(row.passMaCodeDtoList)
|
||||
},
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
|
|
@ -9,8 +9,8 @@
|
|||
v-show="showSearch"
|
||||
label-width="100px"
|
||||
>
|
||||
<el-form-item label="退料单号" prop="keyWord">
|
||||
<el-input v-model="queryParams.keyWord" placeholder="请输入退料单号" clearable style="width: 240px" />
|
||||
<el-form-item label="退料单号" prop="backCode">
|
||||
<el-input v-model="queryParams.backCode" placeholder="请输入退料单号" clearable style="width: 240px" />
|
||||
</el-form-item>
|
||||
<el-form-item label="退料单位" prop="unitId">
|
||||
<el-select
|
||||
|
|
@ -63,7 +63,7 @@
|
|||
/>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="退料申请时间" prop="dateRange">
|
||||
<el-form-item label="退料时间" prop="dateRange">
|
||||
<el-date-picker
|
||||
v-model="dateRange"
|
||||
type="daterange"
|
||||
|
|
@ -83,7 +83,7 @@
|
|||
|
||||
<el-row :gutter="10" class="mb8">
|
||||
<el-col :span="1.5">
|
||||
<el-button type="primary" plain size="mini" @click="handleAdd">退料接收</el-button>
|
||||
<el-button type="primary" plain size="mini" @click="handleAdd">成套退料</el-button>
|
||||
</el-col>
|
||||
<el-col :span="1.5">
|
||||
<el-button
|
||||
|
|
@ -107,16 +107,16 @@
|
|||
type="index"
|
||||
:index="indexContinuation(queryParams.pageNum, queryParams.pageSize)"
|
||||
/>
|
||||
<el-table-column label="退料单号" align="center" prop="code" show-overflow-tooltip width="150px"/>
|
||||
<el-table-column label="退料单号" align="center" prop="backCode" show-overflow-tooltip width="150px"/>
|
||||
<el-table-column label="退料单位" align="center" prop="unitName" show-overflow-tooltip width="150px"/>
|
||||
<el-table-column label="退料工程" align="center" prop="lotName" show-overflow-tooltip width="150px"/>
|
||||
<el-table-column label="退料类型名称" align="center" prop="typeName" show-overflow-tooltip width="170px"/>
|
||||
<el-table-column label="退料工程" align="center" prop="lotName" show-overflow-tooltip width="200px"/>
|
||||
<el-table-column label="退料类型名称" align="center" prop="typeName" show-overflow-tooltip />
|
||||
<el-table-column label="退料人员" align="center" prop="backPerson" show-overflow-tooltip width="100px"/>
|
||||
<el-table-column label="联系电话" align="center" prop="phone" show-overflow-tooltip width="120px"/>
|
||||
<el-table-column label="申请时间" align="center" prop="backTime" show-overflow-tooltip width="100px"/>
|
||||
<el-table-column label="退料时间" align="center" prop="backTime" show-overflow-tooltip width="100px"/>
|
||||
<el-table-column label="协议号" align="center" prop="agreementCode" show-overflow-tooltip width="150px"/>
|
||||
|
||||
<el-table-column label="操作" align="center" width="230" fixed="right">
|
||||
<el-table-column label="操作" align="center" width="120" fixed="right">
|
||||
<template slot-scope="scope">
|
||||
<el-button
|
||||
size="medium"
|
||||
|
|
@ -126,16 +126,6 @@
|
|||
@click="handleSee(scope.row, 'see')"
|
||||
>查看</el-button
|
||||
>
|
||||
<el-button
|
||||
size="medium"
|
||||
type="text"
|
||||
@click="handleEdit(scope.row, 'see')"
|
||||
icon="el-icon-edit"
|
||||
v-hasPermi="['return:receive:handler']"
|
||||
v-if="scope.row.taskStatus != '40'"
|
||||
>
|
||||
编辑
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
|
@ -153,11 +143,8 @@
|
|||
|
||||
<script>
|
||||
import {
|
||||
getBackAuditList,
|
||||
getViewByExamine,
|
||||
ApiBackApplyAudit,
|
||||
ApiBackApplyRefuse,
|
||||
getBackReceiveList,
|
||||
|
||||
getCtBackList,
|
||||
} from '@/api/claimAndRefund/return.js'
|
||||
import { getInfo } from '@/api/login'
|
||||
import { getUnitData, getProData, getAgreementInfoById } from '@/api/claimAndRefund/receive.js'
|
||||
|
|
@ -199,7 +186,7 @@ export default {
|
|||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
keyWord: '', //关键字
|
||||
backCode: '', //关键字
|
||||
unitId: '', //单位id
|
||||
lotId: '', //工程id
|
||||
taskStatus: '', //状态
|
||||
|
|
@ -314,12 +301,10 @@ export default {
|
|||
this.queryParams.endTime = this.dateRange[1]
|
||||
try {
|
||||
let params = {
|
||||
flag: 1,
|
||||
companyId: this.companyId,
|
||||
...this.queryParams,
|
||||
}
|
||||
console.log('paramsparamsparams', params)
|
||||
const res = await getBackReceiveList(params)
|
||||
const res = await getCtBackList(params)
|
||||
this.typeList = res.data.rows
|
||||
this.total = res.data.total
|
||||
this.loading = false
|
||||
|
|
@ -346,10 +331,6 @@ export default {
|
|||
this.$emit('returnApply')
|
||||
},
|
||||
|
||||
handleEdit(row) {
|
||||
this.$emit('returnEdit', row.id, row.taskId)
|
||||
},
|
||||
|
||||
//查看按钮
|
||||
handleSee(row) {
|
||||
// this.$tab.closeOpenPage({
|
||||
|
|
@ -360,7 +341,7 @@ export default {
|
|||
// },
|
||||
// })
|
||||
|
||||
this.$emit('receiveView', row.id, row.taskId)
|
||||
this.$emit('receiveView', row.id)
|
||||
},
|
||||
//退料按钮
|
||||
handleReturn(row) {
|
||||
|
|
|
|||
|
|
@ -14,7 +14,6 @@
|
|||
:rejectAgreementId="rejectAgreementId"
|
||||
:isEdit="isEdit"
|
||||
@returnApply="returnApply"
|
||||
@returnEdit="returnEdit"
|
||||
@receiveView="receiveView"
|
||||
@receiveReturn="receiveReturn"
|
||||
@goBackPage="goBack"
|
||||
|
|
@ -51,29 +50,18 @@ export default {
|
|||
returnApply() {
|
||||
this.rejectId = ''
|
||||
this.rejectTaskId = ''
|
||||
this.pageContent = '新建退料任务'
|
||||
this.pageContent = '新建成套退料明细'
|
||||
this.isShowComponent = 'AddReturn'
|
||||
this.isEdit = false
|
||||
this.isView = false
|
||||
},
|
||||
// 退料编辑
|
||||
returnEdit(id,taskId) {
|
||||
this.rejectId = id
|
||||
this.rejectTaskId = taskId
|
||||
this.pageContent = '编辑退料任务'
|
||||
this.isShowComponent = 'AddReturn'
|
||||
this.isEdit = true
|
||||
this.isView = false
|
||||
},
|
||||
// 查看
|
||||
receiveView(id, taskId) {
|
||||
this.pageContent = '退料详情'
|
||||
receiveView(id) {
|
||||
this.pageContent = '成套退料明细详情'
|
||||
this.rejectId = id
|
||||
this.rejectTaskId = taskId
|
||||
this.isView = true
|
||||
this.isEdit = true
|
||||
// this.isShowComponent = 'HandlePage'
|
||||
this.isShowComponent = 'AddReturn'
|
||||
this.isShowComponent = 'HandlePage'
|
||||
},
|
||||
// 退料操作
|
||||
receiveReturn(id, taskId,agreementId) {
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
|
|
@ -33,6 +33,7 @@
|
|||
filterable
|
||||
style="width: 240px"
|
||||
>
|
||||
<el-option label="待提交" value="3"></el-option>
|
||||
<el-option label="进行中" value="0"></el-option>
|
||||
<el-option label="已通过" value="1"></el-option>
|
||||
<el-option label="已驳回" value="2"></el-option>
|
||||
|
|
@ -71,11 +72,11 @@
|
|||
icon="el-icon-check"
|
||||
size="mini"
|
||||
:disabled="multiple"
|
||||
>通过</el-button
|
||||
>提交</el-button
|
||||
>
|
||||
</el-col>
|
||||
|
||||
<el-col :span="1.5">
|
||||
<!-- <el-col :span="1.5">
|
||||
<el-button
|
||||
type="danger"
|
||||
@click="batchReject"
|
||||
|
|
@ -84,7 +85,7 @@
|
|||
:disabled="multiple"
|
||||
>驳回</el-button
|
||||
>
|
||||
</el-col>
|
||||
</el-col> -->
|
||||
<right-toolbar
|
||||
:showSearch.sync="showSearch"
|
||||
@queryTable="getList"
|
||||
|
|
@ -104,6 +105,7 @@
|
|||
<el-table-column label="提交时间" align="center" prop="createTime" :show-overflow-tooltip="true"/>
|
||||
<el-table-column label="状态" align="center" prop="taskStatus" :show-overflow-tooltip="true" width="150">
|
||||
<template slot-scope="scope">
|
||||
<span v-if="scope.row.taskStatus == 3">待提交</span>
|
||||
<span v-if="scope.row.taskStatus == 0">进行中</span>
|
||||
<span v-if="scope.row.taskStatus == 1">已通过</span>
|
||||
<span v-if="scope.row.taskStatus == 2">已驳回</span>
|
||||
|
|
@ -221,7 +223,7 @@ export default {
|
|||
|
||||
//是否可用勾选框
|
||||
selectable(row) {
|
||||
if (row.taskStatus == 0) {
|
||||
if (row.taskStatus == 3) {
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
|
|
@ -313,7 +315,7 @@ export default {
|
|||
});
|
||||
return;
|
||||
}
|
||||
inventoryPass({idList:this.ids,status:1}).then((response) => {
|
||||
inventoryPass({idList:this.ids,status:0}).then((response) => {
|
||||
this.$modal.msgSuccess("通过成功");
|
||||
this.ids = [];
|
||||
this.getList();
|
||||
|
|
@ -321,22 +323,22 @@ export default {
|
|||
});
|
||||
},
|
||||
|
||||
//驳回
|
||||
batchReject(){
|
||||
if (this.ids == 0) {
|
||||
this.$alert("未勾选数据", "提示", {
|
||||
type: "warning",
|
||||
confirmButtonText: "确定",
|
||||
});
|
||||
return;
|
||||
}
|
||||
inventoryPass({idList:this.ids,status:2}).then((response) => {
|
||||
this.$modal.msgSuccess("驳回成功");
|
||||
this.ids = [];
|
||||
this.getList();
|
||||
this.$refs.multipleTable.clearSelection();
|
||||
});
|
||||
}
|
||||
// //驳回
|
||||
// batchReject(){
|
||||
// if (this.ids == 0) {
|
||||
// this.$alert("未勾选数据", "提示", {
|
||||
// type: "warning",
|
||||
// confirmButtonText: "确定",
|
||||
// });
|
||||
// return;
|
||||
// }
|
||||
// inventoryPass({idList:this.ids,status:2}).then((response) => {
|
||||
// this.$modal.msgSuccess("驳回成功");
|
||||
// this.ids = [];
|
||||
// this.getList();
|
||||
// this.$refs.multipleTable.clearSelection();
|
||||
// });
|
||||
// }
|
||||
},
|
||||
|
||||
};
|
||||
|
|
|
|||
|
|
@ -802,6 +802,7 @@ export default {
|
|||
partStrList: JSON.stringify(this.dynamicValidateForm.premiumList),
|
||||
manageType: 0,
|
||||
repairNum: this.dynamicValidateForm.premiumList[0]?.repairNum ?? 1,
|
||||
maId: this.rowObj.maId,
|
||||
}
|
||||
this.fullscreenLoading = true
|
||||
submitRepairApplyApiNew(params)
|
||||
|
|
|
|||
|
|
@ -307,6 +307,7 @@ export default {
|
|||
repairRemark: this.dynamicValidateForm.repairRemark,
|
||||
fileList: fileList,
|
||||
manageType: 0,
|
||||
maId: this.rowObj.maId,
|
||||
}
|
||||
this.fullscreenLoading = true
|
||||
submitRepairApplyApiNew(params)
|
||||
|
|
|
|||
|
|
@ -632,6 +632,7 @@ export default {
|
|||
manageType: 0,
|
||||
partStrList: JSON.stringify(this.dynamicValidateForm.premiumList),
|
||||
repairNum: this.dynamicValidateForm.premiumList[0]?.repairNum ?? 1,
|
||||
maId: this.rowObj.maId,
|
||||
}
|
||||
this.fullscreenLoading = true
|
||||
submitRepairApplyApiNew(params)
|
||||
|
|
|
|||
|
|
@ -724,7 +724,7 @@
|
|||
|
||||
<el-dialog
|
||||
:visible.sync="fileDialogVisible"
|
||||
title="文件列表"
|
||||
title="附件列表"
|
||||
width="60%"
|
||||
append-to-body
|
||||
>
|
||||
|
|
|
|||
|
|
@ -354,7 +354,7 @@
|
|||
|
||||
<el-dialog
|
||||
:visible.sync="fileDialogVisible"
|
||||
title="文件列表"
|
||||
title="附件列表"
|
||||
width="60%"
|
||||
append-to-body
|
||||
>
|
||||
|
|
@ -376,7 +376,7 @@
|
|||
</el-dialog>
|
||||
|
||||
<!-- 图片查看弹窗 -->
|
||||
<el-dialog :visible.sync="dialogVisible" width="500px" height="500px" >
|
||||
<el-dialog :visible.sync="dialogVisible" width="600px" height="600px" >
|
||||
<img width="100%" height="500px" :src="dialogImageUrl" />
|
||||
</el-dialog>
|
||||
|
||||
|
|
|
|||
|
|
@ -8,40 +8,6 @@
|
|||
v-show="showSearch"
|
||||
label-width="80px"
|
||||
>
|
||||
<el-form-item label="往来单位">
|
||||
<el-select
|
||||
v-model="queryParams.unitId"
|
||||
clearable
|
||||
@change="GetProData"
|
||||
style="width: 240px"
|
||||
placeholder="请选择"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in unitList"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
>
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="工程名称">
|
||||
<el-select
|
||||
v-model="queryParams.proId"
|
||||
clearable
|
||||
@change="GetUnitData"
|
||||
style="width: 240px"
|
||||
placeholder="请选择"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in proList"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
>
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="关键字" prop="keyWord">
|
||||
<el-input
|
||||
v-model="queryParams.keyWord"
|
||||
|
|
@ -108,54 +74,26 @@
|
|||
indexContinuation(queryParams.pageNum, queryParams.pageSize)
|
||||
"
|
||||
/>
|
||||
<el-table-column label="机具名称" align="center" prop="typeName" show-overflow-tooltip width="150px"/>
|
||||
<el-table-column label="规格型号" align="center" prop="type" show-overflow-tooltip width="150px"/>
|
||||
<el-table-column label="机具编号" align="center" prop="maCode" show-overflow-tooltip width="120px"/>
|
||||
<el-table-column label="维修总数" align="center" prop="repairNum" show-overflow-tooltip />
|
||||
<el-table-column label="维修合格数量" align="center" prop="repairedNum" show-overflow-tooltip />
|
||||
<el-table-column
|
||||
label="维修单号"
|
||||
label="维修类型"
|
||||
align="center"
|
||||
prop="code"
|
||||
prop="repairType"
|
||||
:show-overflow-tooltip="true"
|
||||
/>
|
||||
<el-table-column
|
||||
label="机具名称"
|
||||
align="center"
|
||||
prop="typeName"
|
||||
:show-overflow-tooltip="true"
|
||||
/>
|
||||
<el-table-column
|
||||
label="规格型号"
|
||||
align="center"
|
||||
prop="typeModelName"
|
||||
:show-overflow-tooltip="true"
|
||||
/>
|
||||
<el-table-column
|
||||
label="配件名称"
|
||||
align="center"
|
||||
prop="partName"
|
||||
:show-overflow-tooltip="true"
|
||||
/>
|
||||
<el-table-column
|
||||
label="使用数量"
|
||||
align="center"
|
||||
prop="partNum"
|
||||
:show-overflow-tooltip="true"
|
||||
/>
|
||||
<el-table-column
|
||||
label="单价"
|
||||
align="center"
|
||||
prop="partPrice"
|
||||
:show-overflow-tooltip="true"
|
||||
/>
|
||||
<el-table-column
|
||||
label="退料单位"
|
||||
align="center"
|
||||
prop="unitName"
|
||||
:show-overflow-tooltip="true"
|
||||
/>
|
||||
<el-table-column
|
||||
label="退料工程"
|
||||
align="center"
|
||||
prop="proName"
|
||||
:show-overflow-tooltip="true"
|
||||
/>
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span v-if="scope.row.repairType == 1">内部维修</span>
|
||||
<span v-if="scope.row.repairType == 2">返厂维修</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="维修人" align="center" prop="repairer" show-overflow-tooltip />
|
||||
<el-table-column label="维修时间" align="center" prop="createTime" show-overflow-tooltip width="100px"/>
|
||||
|
||||
|
||||
</el-table>
|
||||
|
||||
<pagination
|
||||
|
|
@ -207,8 +145,7 @@ export default {
|
|||
status: undefined,
|
||||
|
||||
time: null, //申请时间
|
||||
unitId: null, //来往单位id
|
||||
proId: null, //工程id
|
||||
|
||||
|
||||
types: 1, // 1申请列表 2审核列表
|
||||
},
|
||||
|
|
@ -227,8 +164,6 @@ export default {
|
|||
this.loading = true
|
||||
|
||||
const params = {
|
||||
unitId: this.queryParams.unitId,
|
||||
proId: this.queryParams.proId,
|
||||
keyWord: this.queryParams.keyWord,
|
||||
agreementCode: this.queryParams.agreementCode,
|
||||
typeName: this.queryParams.typeName,
|
||||
|
|
|
|||
|
|
@ -20,50 +20,6 @@
|
|||
>
|
||||
</el-date-picker>
|
||||
</el-form-item>
|
||||
<el-form-item label="往来单位">
|
||||
<el-select
|
||||
v-model="queryParams.unitId"
|
||||
clearable
|
||||
@change="GetProData"
|
||||
style="width: 240px"
|
||||
placeholder="请选择"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in unitList"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
>
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="工程名称">
|
||||
<el-select
|
||||
v-model="queryParams.proId"
|
||||
clearable
|
||||
@change="GetUnitData"
|
||||
style="width: 240px"
|
||||
placeholder="请选择"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in proList"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
>
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label="协议号" prop="agreementCode">-->
|
||||
<!-- <el-input-->
|
||||
<!-- v-model="queryParams.agreementCode"-->
|
||||
<!-- placeholder="请输入协议号"-->
|
||||
<!-- clearable-->
|
||||
<!-- :maxlength="20"-->
|
||||
<!-- style="width: 240px"-->
|
||||
<!-- @keyup.enter.native="handleQuery"-->
|
||||
<!-- />-->
|
||||
<!-- </el-form-item>-->
|
||||
<el-form-item label="机具名称" prop="typeName">
|
||||
<el-input
|
||||
v-model="queryParams.typeName"
|
||||
|
|
@ -150,30 +106,12 @@
|
|||
indexContinuation(queryParams.pageNum, queryParams.pageSize)
|
||||
"
|
||||
/>
|
||||
<el-table-column
|
||||
label="往来单位"
|
||||
align="center"
|
||||
prop="unitName"
|
||||
:show-overflow-tooltip="true"
|
||||
/>
|
||||
<el-table-column
|
||||
label="工程名称"
|
||||
align="center"
|
||||
prop="proName"
|
||||
:show-overflow-tooltip="true"
|
||||
/>
|
||||
<el-table-column
|
||||
label="报废单号"
|
||||
align="center"
|
||||
prop="code"
|
||||
:show-overflow-tooltip="true"
|
||||
/>
|
||||
<el-table-column
|
||||
label="来源单号"
|
||||
align="center"
|
||||
prop="sourceCode"
|
||||
:show-overflow-tooltip="true"
|
||||
/>
|
||||
<el-table-column
|
||||
label="机具名称"
|
||||
align="center"
|
||||
|
|
@ -203,6 +141,7 @@
|
|||
align="center"
|
||||
prop="scrapTime"
|
||||
:show-overflow-tooltip="true"
|
||||
width="180"
|
||||
/>
|
||||
<el-table-column
|
||||
label="报废数量"
|
||||
|
|
@ -213,7 +152,7 @@
|
|||
<el-table-column
|
||||
label="报废原因"
|
||||
align="center"
|
||||
prop="remark"
|
||||
prop="scrapReason"
|
||||
:show-overflow-tooltip="true"
|
||||
/>
|
||||
<el-table-column
|
||||
|
|
@ -273,8 +212,6 @@ export default {
|
|||
status: undefined,
|
||||
|
||||
time: null, //申请时间
|
||||
unitId: null, //来往单位id
|
||||
proId: null, //工程id
|
||||
|
||||
types: 1, // 1申请列表 2审核列表
|
||||
},
|
||||
|
|
@ -284,8 +221,6 @@ export default {
|
|||
},
|
||||
created() {
|
||||
this.getList()
|
||||
this.getUnitList()
|
||||
this.getProList()
|
||||
},
|
||||
methods: {
|
||||
// 获取 申请列表
|
||||
|
|
@ -311,24 +246,7 @@ export default {
|
|||
this.total = res.data.total
|
||||
},
|
||||
|
||||
// 获取 来往单位 列表数据
|
||||
async getUnitList() {
|
||||
const params = {
|
||||
id: this.queryParams.proId,
|
||||
}
|
||||
const res = await getUnitData(params)
|
||||
this.unitList = res.data
|
||||
console.log('GetUnitData ======================', res)
|
||||
},
|
||||
// 获取 工程名称 列表数据
|
||||
async getProList() {
|
||||
const params = {
|
||||
id: this.queryParams.unitId,
|
||||
}
|
||||
const res = await getProData(params)
|
||||
this.proList = res.data
|
||||
console.log('GetProData ======================', res)
|
||||
},
|
||||
|
||||
|
||||
// 表单重置
|
||||
reset() {
|
||||
|
|
@ -349,8 +267,6 @@ export default {
|
|||
/** 重置按钮操作 */
|
||||
resetQuery() {
|
||||
this.queryParams.time = []
|
||||
this.queryParams.unitId = ''
|
||||
this.queryParams.proId = ''
|
||||
this.resetForm('queryForm')
|
||||
this.handleQuery()
|
||||
},
|
||||
|
|
|
|||
|
|
@ -191,7 +191,11 @@
|
|||
/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="下次检验日期" align="center" prop="nextCheckTime" />
|
||||
<el-table-column label="下次检验日期" align="center" prop="nextCheckTime" >
|
||||
<template slot-scope="scope">
|
||||
<span style="color: red;">{{ scope.row.nextCheckTime }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
label="固定资产编号"
|
||||
align="center"
|
||||
|
|
|
|||
Loading…
Reference in New Issue