Merge branch 'master' of http://121.40.234.130:8899/root/wuHanXinRui
This commit is contained in:
@@ -38,6 +38,14 @@ public class CheckOutBillController {
|
|||||||
return new ResponseEntity<>(checkOutBillService.queryAddDtl(whereJson,page), HttpStatus.OK);
|
return new ResponseEntity<>(checkOutBillService.queryAddDtl(whereJson,page), HttpStatus.OK);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@GetMapping("/queryDtl")
|
||||||
|
@Log("查询出库单")
|
||||||
|
@ApiOperation("查询出库单")
|
||||||
|
//@PreAuthorize("@el.check('checkoutbill:list')")
|
||||||
|
public ResponseEntity<Object> queryDtl(@RequestParam Map whereJson, Pageable page){
|
||||||
|
return new ResponseEntity<>(checkOutBillService.queryDtl(whereJson,page), HttpStatus.OK);
|
||||||
|
}
|
||||||
|
|
||||||
@GetMapping("/getOutBillDtl")
|
@GetMapping("/getOutBillDtl")
|
||||||
@Log("查询出库单")
|
@Log("查询出库单")
|
||||||
@ApiOperation("查询出库单")
|
@ApiOperation("查询出库单")
|
||||||
|
|||||||
@@ -24,6 +24,14 @@ public interface CheckOutBillService {
|
|||||||
* @return Map<String, Object>
|
* @return Map<String, Object>
|
||||||
*/
|
*/
|
||||||
Map<String, Object> queryAddDtl(Map whereJson, Pageable page);
|
Map<String, Object> queryAddDtl(Map whereJson, Pageable page);
|
||||||
|
/**
|
||||||
|
* 查询数据分页
|
||||||
|
*
|
||||||
|
* @param whereJson 条件
|
||||||
|
* @param page 分页参数
|
||||||
|
* @return Map<String, Object>
|
||||||
|
*/
|
||||||
|
Map<String, Object> queryDtl(Map whereJson, Pageable page);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 多选删除
|
* 多选删除
|
||||||
|
|||||||
@@ -81,6 +81,29 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
|||||||
return jo;
|
return jo;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Map<String, Object> queryDtl(Map whereJson, Pageable page) {
|
||||||
|
HashMap<String, String> map = new HashMap<>(whereJson);
|
||||||
|
map.put("flag", "12");
|
||||||
|
|
||||||
|
if (StrUtil.isNotEmpty(map.get("material_code"))) {
|
||||||
|
map.put("material_code", "%" + map.get("material_code") + "%");
|
||||||
|
}
|
||||||
|
if (StrUtil.isNotEmpty(map.get("pcsn"))) {
|
||||||
|
map.put("pcsn", "%" + map.get("pcsn") + "%");
|
||||||
|
}
|
||||||
|
String begin_time = map.get("begin_time");
|
||||||
|
if (StrUtil.isNotEmpty(begin_time)) {
|
||||||
|
map.put("begin_time", begin_time.substring(0,10)+" 00:00:00");
|
||||||
|
}
|
||||||
|
String end_time = map.get("end_time");
|
||||||
|
if (StrUtil.isNotEmpty(end_time)) {
|
||||||
|
map.put("end_time", end_time.substring(0,10)+" 23:59:59");
|
||||||
|
}
|
||||||
|
JSONObject jo = WQL.getWO("QST_IVT_CHECKOUTBILL").addParamMap(map).pageQuery(WqlUtil.getHttpContext(page), "iosdtl2.material_id");
|
||||||
|
return jo;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@Transactional(rollbackFor = Exception.class)
|
@Transactional(rollbackFor = Exception.class)
|
||||||
public void deleteAll(Long[] ids) {
|
public void deleteAll(Long[] ids) {
|
||||||
|
|||||||
@@ -16,6 +16,8 @@
|
|||||||
输入.flag TYPEAS s_string
|
输入.flag TYPEAS s_string
|
||||||
输入.bill_status TYPEAS s_string
|
输入.bill_status TYPEAS s_string
|
||||||
输入.bill_code TYPEAS s_string
|
输入.bill_code TYPEAS s_string
|
||||||
|
输入.source_bill_code TYPEAS s_string
|
||||||
|
输入.username TYPEAS s_string
|
||||||
输入.create_mode TYPEAS s_string
|
输入.create_mode TYPEAS s_string
|
||||||
输入.bill_type TYPEAS s_string
|
输入.bill_type TYPEAS s_string
|
||||||
输入.stor_id TYPEAS s_string
|
输入.stor_id TYPEAS s_string
|
||||||
@@ -598,5 +600,80 @@
|
|||||||
ENDQUERY
|
ENDQUERY
|
||||||
ENDIF
|
ENDIF
|
||||||
|
|
||||||
|
IF 输入.flag = "12"
|
||||||
|
PAGEQUERY
|
||||||
|
SELECT
|
||||||
|
SUM( iosdtl2.real_qty ) AS sum_real_qty,
|
||||||
|
SUM( iosdtl2.plan_qty ) AS sum_plan_qty,
|
||||||
|
iosdtl2.qty_unit_id,
|
||||||
|
iosdtl2.qty_unit_name,
|
||||||
|
iosdtl2.material_name,
|
||||||
|
iosdtl2.material_code,
|
||||||
|
iosdtl2.material_id,
|
||||||
|
iosdtl2.pcsn,
|
||||||
|
iosdtl2.is_active,
|
||||||
|
iosdtl2.ivt_level,
|
||||||
|
iosdtl2.quality_scode
|
||||||
|
FROM
|
||||||
|
(
|
||||||
|
SELECT
|
||||||
|
iosdtl.material_id,
|
||||||
|
iosdtl.pcsn,
|
||||||
|
iosdtl.quality_scode,
|
||||||
|
iosdtl.ivt_level,
|
||||||
|
iosdtl.is_active,
|
||||||
|
iosdtl.plan_qty,
|
||||||
|
iosdtl.real_qty,
|
||||||
|
iosdtl.qty_unit_id,
|
||||||
|
iosdtl.qty_unit_name,
|
||||||
|
mb.material_name,
|
||||||
|
mb.material_code
|
||||||
|
FROM
|
||||||
|
ST_IVT_IOStorInvDtl iosdtl
|
||||||
|
LEFT JOIN md_me_materialbase mb ON mb.material_id = iosdtl.material_id
|
||||||
|
LEFT JOIN ST_IVT_IOStorInv ios ON ios.iostorinv_id = iosdtl.iostorinv_id
|
||||||
|
WHERE
|
||||||
|
1 = 1
|
||||||
|
AND ios.is_delete = '0'
|
||||||
|
OPTION 输入.remark <> ""
|
||||||
|
(mb.material_code like 输入.remark or mb.material_name like 输入.remark)
|
||||||
|
ENDOPTION
|
||||||
|
OPTION 输入.username <> ""
|
||||||
|
(ios.input_optid = 输入.username or ios.input_optname = 输入.username)
|
||||||
|
ENDOPTION
|
||||||
|
OPTION 输入.pcsn <> ""
|
||||||
|
iosdtl.pcsn like 输入.pcsn
|
||||||
|
ENDOPTION
|
||||||
|
OPTION 输入.source_bill_code <> ""
|
||||||
|
iosdtl.source_bill_code = 输入.source_bill_code
|
||||||
|
ENDOPTION
|
||||||
|
OPTION 输入.begin_time <> ""
|
||||||
|
ios.biz_date >= 输入.begin_time
|
||||||
|
ENDOPTION
|
||||||
|
OPTION 输入.end_time <> ""
|
||||||
|
ios.biz_date <= 输入.end_time
|
||||||
|
ENDOPTION
|
||||||
|
OPTION 输入.bill_type <> ""
|
||||||
|
ios.bill_type = 输入.bill_type
|
||||||
|
ENDOPTION
|
||||||
|
OPTION 输入.stor_id <> ""
|
||||||
|
ios.stor_id = 输入.stor_id
|
||||||
|
ENDOPTION
|
||||||
|
) iosdtl2
|
||||||
|
where 1=1
|
||||||
|
GROUP BY
|
||||||
|
iosdtl2.material_id,
|
||||||
|
iosdtl2.pcsn,
|
||||||
|
iosdtl2.is_active,
|
||||||
|
iosdtl2.ivt_level,
|
||||||
|
iosdtl2.quality_scode,
|
||||||
|
iosdtl2.material_name,
|
||||||
|
iosdtl2.material_code,
|
||||||
|
iosdtl2.qty_unit_id,
|
||||||
|
iosdtl2.qty_unit_name
|
||||||
|
ENDSELECT
|
||||||
|
ENDPAGEQUERY
|
||||||
|
ENDIF
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
241
mes/qd/src/views/wms/statistics/outStorQuery/index.vue
Normal file
241
mes/qd/src/views/wms/statistics/outStorQuery/index.vue
Normal file
@@ -0,0 +1,241 @@
|
|||||||
|
<template>
|
||||||
|
<div class="app-container">
|
||||||
|
<!--工具栏-->
|
||||||
|
<div class="head-container">
|
||||||
|
<div v-if="crud.props.searchToggle">
|
||||||
|
<!-- 搜索 -->
|
||||||
|
<el-form
|
||||||
|
:inline="true"
|
||||||
|
class="demo-form-inline"
|
||||||
|
label-position="right"
|
||||||
|
label-width="90px"
|
||||||
|
label-suffix=":"
|
||||||
|
>
|
||||||
|
<el-form-item label="所属仓库">
|
||||||
|
<el-select
|
||||||
|
v-model="query.stor_id"
|
||||||
|
clearable
|
||||||
|
size="mini"
|
||||||
|
placeholder="全部"
|
||||||
|
class="filter-item"
|
||||||
|
@change="crud.toQuery"
|
||||||
|
>
|
||||||
|
<el-option
|
||||||
|
v-for="item in storlist"
|
||||||
|
:key="item.stor_id"
|
||||||
|
:label="item.stor_name"
|
||||||
|
:value="item.stor_id"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="单据类型">
|
||||||
|
<el-select
|
||||||
|
v-model="query.bill_type"
|
||||||
|
clearable
|
||||||
|
filterable
|
||||||
|
size="mini"
|
||||||
|
placeholder="业务类型"
|
||||||
|
class="filter-item"
|
||||||
|
@change="crud.toQuery"
|
||||||
|
>
|
||||||
|
<el-option
|
||||||
|
v-for="item in billtypelist"
|
||||||
|
:key="item.code"
|
||||||
|
:label="item.name"
|
||||||
|
:value="item.code"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="单据日期">
|
||||||
|
<el-date-picker
|
||||||
|
v-model="query.createTime"
|
||||||
|
type="daterange"
|
||||||
|
@input="onInput()"
|
||||||
|
value-format="yyyy-MM-dd HH:mm:ss"
|
||||||
|
start-placeholder="开始日期"
|
||||||
|
end-placeholder="结束日期"
|
||||||
|
:default-time="['00:00:00', '23:59:59']"
|
||||||
|
@change="crud.toQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="工令">
|
||||||
|
<el-input
|
||||||
|
v-model="query.source_bill_code"
|
||||||
|
size="mini"
|
||||||
|
clearable
|
||||||
|
placeholder="工令"
|
||||||
|
@keyup.enter.native="crud.toQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="物料">
|
||||||
|
<el-input
|
||||||
|
v-model="query.material_code"
|
||||||
|
size="mini"
|
||||||
|
clearable
|
||||||
|
placeholder="物料编码或名称模糊查询"
|
||||||
|
@keyup.enter.native="crud.toQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="批次">
|
||||||
|
<el-input
|
||||||
|
v-model="query.pcsn"
|
||||||
|
size="mini"
|
||||||
|
clearable
|
||||||
|
placeholder="批次模糊查询"
|
||||||
|
@keyup.enter.native="crud.toQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="人员">
|
||||||
|
<el-input
|
||||||
|
v-model="query.username"
|
||||||
|
size="mini"
|
||||||
|
clearable
|
||||||
|
placeholder="人员"
|
||||||
|
@keyup.enter.native="crud.toQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<rrOperation />
|
||||||
|
</el-form>
|
||||||
|
</div>
|
||||||
|
<!--如果想在工具栏加入更多按钮,可以使用插槽方式, slot = 'left' or 'right'-->
|
||||||
|
<crudOperation :permission="permission">
|
||||||
|
</crudOperation>
|
||||||
|
<!--表格渲染-->
|
||||||
|
<el-table
|
||||||
|
ref="table"
|
||||||
|
v-loading="crud.loading"
|
||||||
|
size="mini"
|
||||||
|
:data="crud.data"
|
||||||
|
style="width: 100%;"
|
||||||
|
:highlight-current-row="true"
|
||||||
|
@selection-change="crud.selectionChangeHandler"
|
||||||
|
@current-change="handleCurrentChange"
|
||||||
|
@select="handleSelectionChange"
|
||||||
|
@select-all="onSelectAll"
|
||||||
|
>
|
||||||
|
<el-table-column type="index" label="序号" width="50" align="center" />
|
||||||
|
<el-table-column prop="material_code" label="物料编码" width="150" align="center" />
|
||||||
|
<el-table-column prop="material_name" label="物料名称" width="150" align="center" />
|
||||||
|
<el-table-column min-width="90" prop="pcsn" label="批次号" align="center" />
|
||||||
|
<el-table-column prop="sum_plan_qty" label="计划重量(KG)" :formatter="crud.formatNum3" width="150" align="center" />
|
||||||
|
<el-table-column prop="sum_real_qty" label="实际重量(KG)" :formatter="crud.formatNum3" width="150" align="center" />
|
||||||
|
<el-table-column prop="quality_scode" label="品质类型" align="center" width="110px" :formatter="quality_scodeFormat" />
|
||||||
|
<el-table-column prop="ivt_level" label="库存等级" align="center" width="100px" :formatter="ivt_levelFormat" />
|
||||||
|
<el-table-column prop="is_active" label="是否可用" align="center" width="110px" :formatter="is_activeFormat" />
|
||||||
|
<el-table-column min-width="120" prop="qty_unit_name" label="单位" align="center" />
|
||||||
|
</el-table>
|
||||||
|
<!--分页组件-->
|
||||||
|
<pagination />
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import checkoutbill from '@/api/wms/st/core/outbill/checkoutbill'
|
||||||
|
import CRUD, { crud, header, presenter } from '@crud/crud'
|
||||||
|
import rrOperation from '@crud/RR.operation'
|
||||||
|
import crudOperation from '@crud/CRUD.operation'
|
||||||
|
import pagination from '@crud/Pagination'
|
||||||
|
import crudStorattr from '@/api/wms/basedata/st/storattr'
|
||||||
|
import Date from '@/utils/datetime'
|
||||||
|
import crudRawAssist from '@/api/wms/st/core/inbill/rawassist'
|
||||||
|
|
||||||
|
export default {
|
||||||
|
name: 'outStorQuery',
|
||||||
|
components: { crudOperation, rrOperation, pagination },
|
||||||
|
cruds() {
|
||||||
|
return CRUD({ title: '生产配粉领料', idField: 'iostorinv_id', url: 'api/checkoutbill/queryDtl', crudMethod: { ...checkoutbill },
|
||||||
|
optShow: {
|
||||||
|
add: false,
|
||||||
|
edit: false,
|
||||||
|
del: false,
|
||||||
|
reset: true,
|
||||||
|
download: false
|
||||||
|
}})
|
||||||
|
},
|
||||||
|
mixins: [presenter(), header(), crud()],
|
||||||
|
// 数据字典
|
||||||
|
dicts: ['ST_QUALITY_SCODE', 'ST_IVT_LEVEL', 'is_used', 'is_again_put', 'is_usable'],
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
height: document.documentElement.clientHeight - 180 + 'px;',
|
||||||
|
permission: {
|
||||||
|
},
|
||||||
|
divShow: false,
|
||||||
|
openParam: [],
|
||||||
|
mstrow: {},
|
||||||
|
currentRow: null,
|
||||||
|
checkrows: [],
|
||||||
|
storlist: [],
|
||||||
|
billtypelist: []
|
||||||
|
}
|
||||||
|
},
|
||||||
|
mounted: function() {
|
||||||
|
const that = this
|
||||||
|
window.onresize = function temp() {
|
||||||
|
that.height = document.documentElement.clientHeight - 180 + 'px;'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
crudStorattr.getStor({ 'is_materialstore': '1' }).then(res => {
|
||||||
|
this.storlist = res.content
|
||||||
|
})
|
||||||
|
crudRawAssist.getType({ 'io_code': '0103', 'io_flag': '01' }).then(res => {
|
||||||
|
this.billtypelist = res
|
||||||
|
})
|
||||||
|
this.crud.query.createTime = [new Date(), new Date()]
|
||||||
|
this.crud.toQuery()
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
[CRUD.HOOK.beforeRefresh]() {
|
||||||
|
this.handleCurrentChange(null)
|
||||||
|
},
|
||||||
|
onInput() {
|
||||||
|
this.$forceUpdate()
|
||||||
|
},
|
||||||
|
handleSelectionChange(val, row) {
|
||||||
|
if (val.length > 1) {
|
||||||
|
this.$refs.table.clearSelection()
|
||||||
|
this.$refs.table.toggleRowSelection(val.pop())
|
||||||
|
this.buttonChange(row)
|
||||||
|
} else if (val.length === 1) {
|
||||||
|
this.buttonChange(row)
|
||||||
|
} else {
|
||||||
|
this.handleCurrentChange(null)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
onSelectAll() {
|
||||||
|
this.$refs.table.clearSelection()
|
||||||
|
this.handleCurrentChange(null)
|
||||||
|
},
|
||||||
|
buttonChange(current) {
|
||||||
|
if (current !== null) {
|
||||||
|
this.currentRow = current
|
||||||
|
}
|
||||||
|
},
|
||||||
|
quality_scodeFormat(row, column) {
|
||||||
|
return this.dict.label.ST_QUALITY_SCODE[row.quality_scode]
|
||||||
|
},
|
||||||
|
ivt_levelFormat(row, column) {
|
||||||
|
return this.dict.label.ST_IVT_LEVEL[row.ivt_level]
|
||||||
|
},
|
||||||
|
is_activeFormat(row, column) {
|
||||||
|
return this.dict.label.is_usable[row.is_active]
|
||||||
|
},
|
||||||
|
handleCurrentChange(current) {
|
||||||
|
if (current === null) {
|
||||||
|
this.currentRow = {}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
querytable() {
|
||||||
|
this.crud.toQuery()
|
||||||
|
this.handleCurrentChange(null)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
<style rel="stylesheet/scss" lang="scss" scoped>
|
||||||
|
::v-deep .el-dialog__body {
|
||||||
|
padding-top: 10px;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
Reference in New Issue
Block a user