综合查询新增领料出库查询,导出等功能,维修模块优化,领料出库模块新增出库记录查询,导出等功能

This commit is contained in:
BianLzhaoMin 2024-09-26 18:12:08 +08:00
parent d48727429f
commit 8776771768
12 changed files with 736 additions and 33 deletions

View File

@ -312,3 +312,11 @@ export function pushSmartEngineeringApi(data) {
data, data,
}) })
} }
// 推送智慧工程
export function getLeaseOutDetailRecordApi(data) {
return request({
url: '/material/base/tm_task/getLeaseOutDetailRecord',
method: 'get',
params: data,
})
}

View File

@ -0,0 +1,13 @@
import request from '@/utils/request'
/**
* 出库查询页面接口
*/
/* 出库列表数据 */
export const getOutboundListApi = (data) => {
return request.get('/material/inputRecord/getOutputRecordList', {
params: data,
})
}

View File

@ -189,7 +189,7 @@
<el-dialog <el-dialog
:title="title" :title="title"
:visible.sync="openLeaseDevices" :visible.sync="openLeaseDevices"
width="1200px" width="80%"
append-to-body append-to-body
> >
<el-form <el-form
@ -274,6 +274,14 @@
prop="userName" prop="userName"
:show-overflow-tooltip="true" :show-overflow-tooltip="true"
/> />
<el-table-column label="操作" align="center" v-if="isView">
<template slot-scope="{ row }" v-if="row.alNum > 0">
<el-button type="text" @click="onPreviewRecord(row)"
>出库记录</el-button
>
</template>
</el-table-column>
<el-table-column <el-table-column
label="操作" label="操作"
align="center" align="center"
@ -313,6 +321,91 @@
:limit.sync="dialogQuery.pageSize" :limit.sync="dialogQuery.pageSize"
@pagination="getDialogList" @pagination="getDialogList"
/> />
<el-dialog
title="出库记录"
:visible.sync="outRecordVisible"
width="70%"
append-to-body
>
<el-form inline>
<!-- 搜索表单 -->
<el-form-item label="时间">
<el-date-picker
clearable
type="daterange"
v-model="outTime"
style="width: 240px"
range-separator="至"
value-format="yyyy-MM-dd"
end-placeholder="结束日期"
start-placeholder="开始日期"
placeholder="请选择出库日期"
@change="onOutTimeChange"
/>
</el-form-item>
<el-form-item>
<el-button
size="small"
type="primary"
@click="onHandleQuery"
>查询</el-button
>
<el-button
size="small"
type="primary"
@click="onHandleReset"
>重置</el-button
>
<el-button
size="small"
type="primary"
@click="onHandleExport"
>导出</el-button
>
</el-form-item>
</el-form>
<!-- 出库记录列表 -->
<el-table border :data="leaseOutDetailsList">
<el-table-column
align="center"
label="序号"
show-overflow-tooltip
type="index"
/>
<el-table-column
align="center"
label="机具名称"
prop="typeName"
show-overflow-tooltip
/>
<el-table-column
align="center"
label="规格型号"
prop="typeModelName"
show-overflow-tooltip
/>
<el-table-column
align="center"
label="出库时间"
prop="createTime"
show-overflow-tooltip
/>
<el-table-column
align="center"
label="本次出库数量"
prop="outNum"
show-overflow-tooltip
/>
<el-table-column
align="center"
label="出库人"
prop="userName"
show-overflow-tooltip
/>
</el-table>
</el-dialog>
</el-dialog> </el-dialog>
<!-- 编码出库 --> <!-- 编码出库 -->
@ -522,6 +615,7 @@ import {
getDetailsByTypeId, getDetailsByTypeId,
submitOut, submitOut,
submitNumOut, submitNumOut,
getLeaseOutDetailRecordApi,
} from '@/api/claimAndRefund/receive.js' } from '@/api/claimAndRefund/receive.js'
import { getTypeList } from '@/api/store/warehousing' import { getTypeList } from '@/api/store/warehousing'
import { equipmentTypeTree } from '@/api/store/tools' import { equipmentTypeTree } from '@/api/store/tools'
@ -604,6 +698,16 @@ export default {
outCodeList: [], // outCodeList: [], //
outNumList: [], // outNumList: [], //
leaseType: '', // 0 1 leaseType: '', // 0 1
outRecordVisible: false,
leaseOutDetailParams: {
id: '',
typeId: '',
startTime: '',
endTime: '',
},
leaseOutDetailsList: [],
outTime: [],
} }
}, },
created() { created() {
@ -685,6 +789,7 @@ export default {
this.openLeaseDevices = true this.openLeaseDevices = true
this.isView = true this.isView = true
this.dialogQuery.id = row.id this.dialogQuery.id = row.id
this.leaseOutDetailParams.id = row.id
this.resetDialogQuery() this.resetDialogQuery()
// this.getDialogList(); // this.getDialogList();
}, },
@ -841,6 +946,46 @@ export default {
`领料出库_${new Date().getTime()}.xlsx`, `领料出库_${new Date().getTime()}.xlsx`,
) )
}, },
/* 查看出库记录 */
onPreviewRecord(row) {
this.leaseOutDetailParams.typeId = row.typeId
this.onHandleQuery().then(() => {
this.outRecordVisible = true
})
},
async onHandleQuery() {
const res = await getLeaseOutDetailRecordApi(
this.leaseOutDetailParams,
)
this.leaseOutDetailsList = res.data
},
onHandleReset() {
this.outTime = []
this.leaseOutDetailParams.startTime = ''
this.leaseOutDetailParams.endTime = ''
this.onHandleQuery()
},
onHandleExport() {
this.download(
'material/base/tm_task/exportLeaseOutDetailRecord',
{
...this.leaseOutDetailParams,
},
`机具出库列表.xlsx`,
)
},
onOutTimeChange(val) {
if (val.length > 0) {
const [_1, _2] = val
this.leaseOutDetailParams.startTime = _1
this.leaseOutDetailParams.endTime = _2
} else {
this.leaseOutDetailParams.startTime = ''
this.leaseOutDetailParams.endTime = ''
}
},
}, },
} }
</script> </script>

View File

@ -37,7 +37,7 @@
noResultsText="没有搜索结果" noResultsText="没有搜索结果"
placeholder="请选择配件" placeholder="请选择配件"
:disable-branch-nodes="true" :disable-branch-nodes="true"
@input="handleSelectTree" @input="handleSelectTree($event, index)"
/> />
</el-form-item> </el-form-item>
<el-form-item <el-form-item
@ -60,7 +60,7 @@
/> />
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item <!-- <el-form-item
:prop="'premiumList.' + index + '.partType'" :prop="'premiumList.' + index + '.partType'"
label="是否收费:" label="是否收费:"
required required
@ -77,7 +77,7 @@
<el-radio :label="1"></el-radio> <el-radio :label="1"></el-radio>
<el-radio :label="0"></el-radio> <el-radio :label="0"></el-radio>
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item> -->
<el-form-item <el-form-item
:prop="'premiumList.' + index + '.partNum'" :prop="'premiumList.' + index + '.partNum'"
@ -226,10 +226,10 @@
noResultsText="没有搜索结果" noResultsText="没有搜索结果"
placeholder="选择上级" placeholder="选择上级"
:disable-branch-nodes="true" :disable-branch-nodes="true"
@input="handleSelectTree" @input="handleSelectTree($event, index)"
/> />
</el-form-item> </el-form-item>
<el-form-item <!-- <el-form-item
:prop="'premiumListTwo.' + index + '.partType'" :prop="'premiumListTwo.' + index + '.partType'"
label="是否收费:" label="是否收费:"
required required
@ -246,7 +246,7 @@
<el-radio :label="1"></el-radio> <el-radio :label="1"></el-radio>
<el-radio :label="0"></el-radio> <el-radio :label="0"></el-radio>
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item> -->
<el-form-item <el-form-item
:prop="'premiumListTwo.' + index + '.partNum'" :prop="'premiumListTwo.' + index + '.partNum'"
label="配件数量:" label="配件数量:"
@ -637,10 +637,12 @@ export default {
} }
}) })
}, },
handleSelectTree(value) { handleSelectTree(value, index) {
if (value) { if (value) {
this.isRequired = true this.isRequired = true
} else { } else {
this.$refs['dynamicValidateForm'].clearValidate()
this.$refs['dynamicValidateFormTwo'].clearValidate()
this.isRequired = false this.isRequired = false
} }
}, },

View File

@ -41,7 +41,7 @@
style="width: 350px" style="width: 350px"
></el-input> ></el-input>
</el-form-item> </el-form-item>
<el-form-item <!-- <el-form-item
:prop="'premiumList.' + index + '.partType'" :prop="'premiumList.' + index + '.partType'"
label="是否收费:" label="是否收费:"
required required
@ -58,7 +58,7 @@
<el-radio :label="1"></el-radio> <el-radio :label="1"></el-radio>
<el-radio :label="0"></el-radio> <el-radio :label="0"></el-radio>
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item> -->
<el-form-item <el-form-item
v-if="index == 0" v-if="index == 0"
:prop="'premiumList.' + index + '.supplierId'" :prop="'premiumList.' + index + '.supplierId'"
@ -200,7 +200,7 @@
style="width: 350px" style="width: 350px"
></el-input> ></el-input>
</el-form-item> </el-form-item>
<el-form-item <!-- <el-form-item
label="是否收费:" label="是否收费:"
required required
:rules="{ :rules="{
@ -216,7 +216,7 @@
<el-radio :label="1"></el-radio> <el-radio :label="1"></el-radio>
<el-radio :label="0"></el-radio> <el-radio :label="0"></el-radio>
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item> -->
<el-form-item <el-form-item
v-if="index == 0" v-if="index == 0"
:prop="'premiumListTwo.' + index + '.supplierId'" :prop="'premiumListTwo.' + index + '.supplierId'"

View File

@ -345,14 +345,14 @@
</el-row> </el-row>
</el-form> </el-form>
<div style="margin-bottom: 10px" v-if="type == 'update'"> <div style="margin-bottom: 10px" v-if="type == 'update'">
<el-button <!-- <el-button
:disabled="selectionList.length == 0" :disabled="selectionList.length == 0"
size="mini" size="mini"
type="primary" type="primary"
@click="complete(2)" @click="complete(2)"
> >
维修合格 维修合格
</el-button> </el-button> -->
<el-button <el-button
:disabled="selectionList.length == 0 || !checkResult" :disabled="selectionList.length == 0 || !checkResult"
size="mini" size="mini"

View File

@ -0,0 +1,163 @@
<template>
<div>
<el-form
inline
size="small"
label-width="80px"
ref="queryParamsFormRef"
:model="queryParamsForm"
>
<el-form-item label="关键字" prop="keyWord">
<el-input
clearable
style="width: 240px"
placeholder="请输入关键字"
v-model="queryParamsForm.keyWord"
/>
</el-form-item>
<el-form-item label="领料单号" prop="code">
<el-input
clearable
style="width: 240px"
placeholder="请输入领料单号"
v-model="queryParamsForm.code"
/>
</el-form-item>
<el-form-item label="领料单位" prop="unitId">
<el-select
clearable
style="width: 240px"
v-model="queryParamsForm.unitId"
placeholder="请选择领料单位"
>
<el-option
v-for="item in unitList"
:key="item.id"
:label="item.name"
:value="item.id"
/>
</el-select>
</el-form-item>
<el-form-item label="工程名称" prop="lotId">
<el-select
clearable
style="width: 240px"
v-model="queryParamsForm.lotId"
placeholder="请选择工程名称"
>
<el-option
v-for="item in projectList"
:key="item.id"
:label="item.name"
:value="item.id"
/>
</el-select>
</el-form-item>
<el-form-item label="出库日期">
<el-date-picker
clearable
type="daterange"
v-model="outTime"
style="width: 240px"
range-separator="至"
value-format="yyyy-MM-dd"
end-placeholder="结束日期"
start-placeholder="开始日期"
placeholder="请选择出库日期"
@change="onOutTimeChange"
/>
</el-form-item>
<el-form-item>
<el-button size="mini" plain @click="handleQuery"
>查询</el-button
>
<el-button size="mini" type="warning" @click="handleReset"
>重置</el-button
>
<el-button size="mini" type="primary" @click="handleExport"
>导出</el-button
>
<el-button
size="mini"
type="success"
@click="handleOutboundOrder"
>出库单</el-button
>
</el-form-item>
</el-form>
<OutboundOrder
v-if="outboundVisible"
:unitList="unitList"
:projectList="projectList"
:outboundVisible="outboundVisible"
@handleClose="handleClose"
/>
</div>
</template>
<script>
import OutboundOrder from './outbound-order'
import { getProData, getUnitData } from '@/api/stquery/deviceScrapQuery'
export default {
components: {
OutboundOrder,
},
data() {
return {
outTime: [],
unitList: [],
projectList: [],
outboundVisible: false,
queryParamsForm: {
code: '',
lotId: '',
unitId: '',
keyWord: '',
startTime: '',
endTime: '',
},
}
},
created() {
this.getUnitList()
this.getProList()
},
methods: {
async getUnitList() {
const { data: res } = await getUnitData()
this.unitList = res
},
async getProList() {
const { data: res } = await getProData()
this.projectList = res
},
onOutTimeChange(val) {
if (val.length > 0) {
const [_1, _2] = val
this.queryParamsForm.startTime = _1
this.queryParamsForm.endTime = _2
}
},
handleQuery() {
this.$emit('handleQuery', this.queryParamsForm)
},
handleReset() {
this.outTime = []
this.queryParamsForm.endTime = ''
this.queryParamsForm.startTime = ''
this.$refs.queryParamsFormRef.resetFields()
this.$emit('handleQuery', this.queryParamsForm, 'reset')
},
handleExport() {
this.$emit('handleExport', this.queryParamsForm)
},
handleOutboundOrder() {
this.outboundVisible = true
},
handleClose() {
this.outboundVisible = false
},
},
}
</script>

View File

@ -0,0 +1,247 @@
<template>
<div>
<el-dialog
center
width="80%"
append-to-body
title="机具出库单"
:before-close="handleClose"
:visible.sync="outboundVisible"
>
<el-form inline label-width="100px">
<el-row>
<el-col :span="12">
<el-form-item label="领用单位">
<el-select
clearable
style="width: 240px"
v-model="queryParamsForm.unitId"
placeholder="请选择领料单位"
@change="onUnitChange"
>
<el-option
v-for="item in unitList"
:key="item.id"
:label="item.name"
:value="item.id"
/>
</el-select>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="出库日期">
<el-date-picker
clearable
type="daterange"
v-model="outTime"
style="width: 240px"
range-separator="至"
value-format="yyyy-MM-dd"
end-placeholder="结束日期"
start-placeholder="开始日期"
placeholder="请选择出库日期"
@change="onOutTimeChange"
/>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="工程名称">
<el-select
clearable
style="width: 240px"
v-model="queryParamsForm.lotId"
placeholder="请选择工程名称"
@change="onProjectChange"
>
<el-option
v-for="item in projectList"
:key="item.id"
:label="item.name"
:value="item.id"
/>
</el-select>
</el-form-item>
</el-col>
</el-row>
</el-form>
<VueEasyPrint ref="vueEasyPrintRef">
<el-table :data="tableList">
<el-table-column label="序号" align="center" type="index" />
<el-table-column
prop="typeName"
label="机具名称"
align="center"
/>
<el-table-column
prop="typeModelName"
label="规格型号"
align="center"
/>
<el-table-column
prop="unitId"
label="计量单位"
align="center"
/>
<el-table-column
prop="outNum"
label="出库数量"
align="center"
/>
<el-table-column
prop="maStauts"
label="设备状态"
align="center"
/>
<el-table-column
prop="maCode"
label="设备编号"
align="center"
/>
<el-table-column label="备注" align="center" />
</el-table>
<h1> 以上工机具均确认完好无误能够正常使用 </h1>
<h1> 如有损坏丢失 原价赔偿 </h1>
<el-row>
<el-col :span="12"> 机具分公司发货人 </el-col>
<el-col :span="12"> 领用单位经办人 </el-col>
</el-row>
<el-row>
<el-col :span="12" style="color: transparent">,</el-col>
<el-col :span="12"> 承运车 </el-col>
</el-row>
</VueEasyPrint>
<div slot="footer" class="dialog-footer">
<el-button size="mini" @click="onPrint"> </el-button>
<el-button size="mini" @click="handleExport"> </el-button>
<el-button size="mini" @click="handleClose" type="primary"
> </el-button
>
</div>
</el-dialog>
</div>
</template>
<script>
import { getOutboundListApi } from '@/api/stquery/outboundPreview.js'
import VueEasyPrint from 'vue-easy-print'
export default {
props: {
outboundVisible: {
type: Boolean,
default: () => false,
},
unitList: {
type: Array,
default: () => [],
},
projectList: {
type: Array,
default: () => [],
},
},
components: {
VueEasyPrint,
},
data() {
return {
outTime: [],
tableList: [],
queryParamsForm: {
lotId: '',
unitId: '',
startTime: '',
endTime: '',
pageNum: 1,
pageSize: 9999,
},
}
},
methods: {
async getTableList() {
const { data: res } = await getOutboundListApi(this.queryParamsForm)
this.tableList = res.rows
},
handleClose() {
this.$emit('handleClose')
},
onUnitChange(val) {
if (val) {
this.getTableList()
}
},
onProjectChange(val) {
if (val) {
this.getTableList()
}
},
onOutTimeChange(val) {
if (val.length > 0) {
const [_1, _2] = val
this.queryParamsForm.startTime = _1
this.queryParamsForm.endTime = _2
} else {
this.queryParamsForm.startTime = ''
this.queryParamsForm.endTime = ''
}
if (this.queryParamsForm.unitId || this.queryParamsForm.lotId) {
this.getTableList()
}
},
onPrint() {
this.$refs.vueEasyPrintRef.print()
},
handleExport() {
this.download(
'material/inputRecord/exOutputport',
{
...this.queryParamsForm,
},
`机具出库列表.xlsx`,
)
},
},
watch: {
queryParamsForm: {
handler(newValue) {
const { lotId, unitId, startTime, endTime } = newValue
if (!lotId && !unitId && !startTime && !endTime) {
this.tableList = []
}
},
deep: true,
},
},
}
</script>
<style scoped>
::v-deep .el-dialog__title {
font-size: 20px;
letter-spacing: 6px;
}
h1 {
margin: 15px 0;
padding: 0;
font-size: 18px;
font-weight: bold;
text-align: center;
}
.el-row {
margin-top: 15px;
font-size: 16px;
letter-spacing: 4px;
}
</style>

View File

@ -0,0 +1,127 @@
<template>
<div>
<!-- 表单搜索 -->
<OutboundForm @handleQuery="handleQuery" @handleExport="handleExport" />
<!-- 列表 -->
<el-table :data="tableList" border>
<el-table-column align="center" label="序号" type="index" />
<el-table-column
align="center"
prop="code"
label="领料单号"
show-overflow-tooltip
/>
<el-table-column
align="center"
prop="unitName"
label="领用单位"
show-overflow-tooltip
/>
<el-table-column
align="center"
prop="lotName"
label="工程名称"
show-overflow-tooltip
/>
<el-table-column
align="center"
prop="typeName"
label="机具名称"
show-overflow-tooltip
/>
<el-table-column
align="center"
prop="typeModelName"
label="规格型号"
show-overflow-tooltip
/>
<el-table-column
align="center"
prop="unitId"
label="计量单位"
show-overflow-tooltip
/>
<el-table-column
align="center"
prop="maCode"
label="设备编号"
show-overflow-tooltip
/>
<el-table-column
align="center"
prop="createTime"
label="出库时间"
show-overflow-tooltip
/>
<el-table-column
align="center"
prop="outNum"
label="本次出库数量"
show-overflow-tooltip
/>
</el-table>
<pagination
v-show="total > 0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getTableList"
/>
</div>
</template>
<script>
import OutboundForm from './outbound-form'
import { getOutboundListApi } from '@/api/stquery/outboundPreview.js'
export default {
components: {
OutboundForm,
},
data() {
return {
queryParams: {
pageNum: 1,
pageSize: 10,
},
total: 0,
tableList: [],
}
},
created() {
this.getTableList()
},
methods: {
async getTableList() {
const { data: res } = await getOutboundListApi(this.queryParams)
this.tableList = res.rows
this.total = res.total
},
handleQuery(val, reset) {
Object.assign(this.queryParams, val)
/* reset === 'reset'时为表单查询条件重置,则初始化分页参数 */
if (reset === 'reset') {
this.queryParams.pageNum = 1
this.queryParams.pageSize = 10
}
this.getTableList()
},
/* 导出 */
handleExport(val) {
Object.assign(this.queryParams, val)
this.download(
'material/inputRecord/exOutputport',
{
...this.queryParams,
},
`机具出库列表.xlsx`,
)
},
},
}
</script>

View File

@ -0,0 +1,15 @@
<template>
<!-- 领料出库页面查询 -->
<div class="app-container">
<OutboundTable />
</div>
</template>
<script>
import OutboundTable from './components/outbound-table'
export default {
components: {
OutboundTable,
},
}
</script>

View File

@ -809,23 +809,6 @@ export default {
}, },
} }
</script> </script>
//
<style lang="scss" scoped>
// ::v-deep.el-table .fixed-width .el-button--mini {
// width: 60px !important;
// margin-bottom: 10px;
// }
// ::v-deep input::-webkit-inner-spin-button {
// -webkit-appearance: none !important;
// }
// ::v-deep input[type='number'] {
// -moz-appearance: textfield !important;
// }
//
</style>
<style lang="scss"> <style lang="scss">
.popper-select { .popper-select {
.el-cascader-panel .el-scrollbar .el-checkbox { .el-cascader-panel .el-scrollbar .el-checkbox {

View File

@ -37,12 +37,12 @@ module.exports = {
[process.env.VUE_APP_BASE_API]: { [process.env.VUE_APP_BASE_API]: {
// target: `http://112.29.103.165:21626`, //线上环境-重庆 // target: `http://112.29.103.165:21626`, //线上环境-重庆
// target: `http://112.29.103.165:21624`,//线上环境-宁夏 打包前放开数据大屏的路由 // target: `http://112.29.103.165:21624`,//线上环境-宁夏 打包前放开数据大屏的路由
// target: `http://192.168.0.14:21624`, //测试环境 // target: `http://192.168.0.56:39080`, //测试环境
// target: `http://1.12.248.179:23028`,//线上环境-南网 // target: `http://1.12.248.179:23028`,//线上环境-南网
// target: `https://test-cc.zhgkxt.com`,//线上环境-南网 // target: `https://test-cc.zhgkxt.com`,//线上环境-南网
// target: `https://z.csgmall.com.cn`, // target: `https://z.csgmall.com.cn`,
target: `http://192.168.2.127:39080`, //超 target: `http://192.168.2.158:39080`, //超
// target: `http://10.40.92.81:8080`, //韩/ // target: `http://10.40.92.81:8080`, //韩/
// target: `http://192.168.2.75:39080`, //旭/ // target: `http://192.168.2.75:39080`, //旭/
// target: `http://192.168.2.17:39080`, //帅 // target: `http://192.168.2.17:39080`, //帅