Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
M
mini-wms
概览
Overview
Details
Activity
Cycle Analytics
版本库
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
问题
0
Issues
0
列表
Board
标记
里程碑
合并请求
0
Merge Requests
0
CI / CD
CI / CD
流水线
作业
日程表
图表
维基
Wiki
代码片段
Snippets
成员
Members
Collapse sidebar
Close sidebar
活动
图像
聊天
创建新问题
作业
提交
Issue Boards
Open sidebar
周海峰
mini-wms
Commits
c2162be0
Commit
c2162be0
authored
Dec 12, 2025
by
wangchunyang
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of
https://code.palacesun.com/zhouhaifeng/mini-wms
parents
b1240733
9e20d976
全部展开
显示空白字符变更
内嵌
并排
正在显示
16 个修改的文件
包含
127 行增加
和
293 行删除
+127
-293
ruoyi-admin-vue/src/components/materialsSeletor copy.vue
+0
-0
ruoyi-admin-vue/src/components/materialsSeletor.vue
+0
-1
ruoyi-admin-vue/src/views/inventory/locations/index.vue
+0
-0
ruoyi-admin-vue/src/views/inventory/orders/OutboundOrderFormWithItems.vue
+1
-3
ruoyi-admin-vue/src/views/inventory/orders/index.vue
+22
-14
ruoyi-inventory/src/main/java/com/ruoyi/inventory/controller/OutboundOrdersController.java
+2
-2
ruoyi-inventory/src/main/java/com/ruoyi/inventory/domain/Inventory.java
+6
-0
ruoyi-inventory/src/main/java/com/ruoyi/inventory/domain/vo/InboundOutboundStatisticsVO.java
+0
-1
ruoyi-inventory/src/main/java/com/ruoyi/inventory/domain/vo/OutboundOrdersSummaryVO.java
+6
-257
ruoyi-inventory/src/main/java/com/ruoyi/inventory/domain/vo/StorageLocationsLocationTemplateVO.java
+2
-1
ruoyi-inventory/src/main/java/com/ruoyi/inventory/service/IOutboundOrdersService.java
+1
-1
ruoyi-inventory/src/main/java/com/ruoyi/inventory/service/impl/OutboundOrdersServiceImpl.java
+2
-1
ruoyi-inventory/src/main/java/com/ruoyi/inventory/service/impl/StorageLocationsServiceImpl.java
+1
-0
ruoyi-inventory/src/main/resources/mapper/inventory/InventoryMapper.xml
+50
-10
ruoyi-inventory/src/main/resources/mapper/inventory/OutboundOrderItemsMapper.xml
+13
-2
ruoyi-inventory/src/main/resources/mapper/inventory/StorageLocationsMapper.xml
+21
-0
没有找到文件。
ruoyi-admin-vue/src/components/materialsSeletor copy.vue
deleted
100644 → 0
View file @
b1240733
差异被折叠。
点击展开。
ruoyi-admin-vue/src/components/materialsSeletor.vue
View file @
c2162be0
...
@@ -74,7 +74,6 @@
...
@@ -74,7 +74,6 @@
align=
"center"
align=
"center"
/>
/>
<el-table-column
type=
"index"
label=
"序号"
align=
"center"
/>
<el-table-column
type=
"index"
label=
"序号"
align=
"center"
/>
<el-table-column
label=
"物料ID"
align=
"center"
prop=
"id"
/>
<el-table-column
label=
"SAP物料号"
align=
"center"
prop=
"sapNo"
/>
<el-table-column
label=
"SAP物料号"
align=
"center"
prop=
"sapNo"
/>
<el-table-column
label=
"物料名称"
align=
"center"
prop=
"materialName"
width=
"150"
/>
<el-table-column
label=
"物料名称"
align=
"center"
prop=
"materialName"
width=
"150"
/>
<el-table-column
label=
"TS Code"
align=
"center"
prop=
"tsCode"
/>
<el-table-column
label=
"TS Code"
align=
"center"
prop=
"tsCode"
/>
...
...
ruoyi-admin-vue/src/views/inventory/locations/index.vue
View file @
c2162be0
差异被折叠。
点击展开。
ruoyi-admin-vue/src/views/inventory/orders/OutboundOrderFormWithItems.vue
View file @
c2162be0
...
@@ -83,7 +83,6 @@
...
@@ -83,7 +83,6 @@
<el-table-column
prop=
"outboundOrderId"
label=
"出库单号"
width=
"150"
/>
<el-table-column
prop=
"outboundOrderId"
label=
"出库单号"
width=
"150"
/>
<el-table-column
prop=
"warehousesName"
label=
"仓库名称"
width=
"120"
/>
<el-table-column
prop=
"warehousesName"
label=
"仓库名称"
width=
"120"
/>
<el-table-column
prop=
"locationName"
label=
"库位名称"
width=
"120"
/>
<el-table-column
prop=
"locationName"
label=
"库位名称"
width=
"120"
/>
<el-table-column
prop=
"locationId"
label=
"库位ID"
width=
"140"
/>
<el-table-column
<el-table-column
prop=
"inventoryType"
prop=
"inventoryType"
label=
"库存类型"
label=
"库存类型"
...
@@ -146,7 +145,7 @@
...
@@ -146,7 +145,7 @@
v-for=
"color in dict.type.label_color"
v-for=
"color in dict.type.label_color"
:key=
"color.value"
:key=
"color.value"
:label=
"color.label"
:label=
"color.label"
:value=
"
color.value
"
:value=
"
Number(color.value)
"
/>
/>
</el-select>
</el-select>
</el-form-item>
</el-form-item>
...
@@ -230,7 +229,6 @@
...
@@ -230,7 +229,6 @@
<el-table-column
prop=
"batchId"
label=
"批次ID"
width=
"150"
/>
<el-table-column
prop=
"batchId"
label=
"批次ID"
width=
"150"
/>
<el-table-column
prop=
"warehousesName"
label=
"仓库名称"
width=
"120"
/>
<el-table-column
prop=
"warehousesName"
label=
"仓库名称"
width=
"120"
/>
<el-table-column
prop=
"locationName"
label=
"库位名称"
width=
"120"
/>
<el-table-column
prop=
"locationName"
label=
"库位名称"
width=
"120"
/>
<el-table-column
prop=
"locationId"
label=
"库位ID"
width=
"140"
/>
<el-table-column
prop=
"plannedQuantity"
label=
"计划数量"
width=
"100"
/>
<el-table-column
prop=
"plannedQuantity"
label=
"计划数量"
width=
"100"
/>
<el-table-column
prop=
"actualQuantity"
label=
"实际数量"
width=
"100"
/>
<el-table-column
prop=
"actualQuantity"
label=
"实际数量"
width=
"100"
/>
<el-table-column
prop=
"unitPrice"
label=
"单价"
width=
"100"
/>
<el-table-column
prop=
"unitPrice"
label=
"单价"
width=
"100"
/>
...
...
ruoyi-admin-vue/src/views/inventory/orders/index.vue
View file @
c2162be0
...
@@ -74,10 +74,10 @@
...
@@ -74,10 +74,10 @@
@
keyup
.
enter
.
native=
"handleQuery"
@
keyup
.
enter
.
native=
"handleQuery"
/>
/>
</el-form-item>
</el-form-item>
<el-form-item
label=
"
入
库类型"
prop=
"orderTypeId"
>
<el-form-item
label=
"
出
库类型"
prop=
"orderTypeId"
>
<el-input
<el-input
v-model=
"queryParams.orderTypeId"
v-model=
"queryParams.orderTypeId"
placeholder=
"请输入
入
库类型"
placeholder=
"请输入
出
库类型"
clearable
clearable
@
keyup
.
enter
.
native=
"handleQuery"
@
keyup
.
enter
.
native=
"handleQuery"
/>
/>
...
@@ -192,7 +192,7 @@
...
@@ -192,7 +192,7 @@
<el-table-column
type=
"selection"
width=
"55"
align=
"center"
fixed
/>
<el-table-column
type=
"selection"
width=
"55"
align=
"center"
fixed
/>
<el-table-column
label=
"出库单号"
align=
"center"
prop=
"orderId"
width=
"150"
fixed
/>
<el-table-column
label=
"出库单号"
align=
"center"
prop=
"orderId"
width=
"150"
fixed
/>
<el-table-column
label=
"系统编号"
align=
"center"
prop=
"systemNo"
width=
"150"
/>
<el-table-column
label=
"系统编号"
align=
"center"
prop=
"systemNo"
width=
"150"
/>
<el-table-column
label=
"
入
库类型"
align=
"center"
prop=
"orderTypeId"
width=
"120"
>
<el-table-column
label=
"
出
库类型"
align=
"center"
prop=
"orderTypeId"
width=
"120"
>
<
template
slot-scope=
"scope"
>
<
template
slot-scope=
"scope"
>
<dict-tag
v-if=
"dict.type.outbound_order_type"
:options=
"dict.type.outbound_order_type"
:value=
"scope.row.orderTypeId"
/>
<dict-tag
v-if=
"dict.type.outbound_order_type"
:options=
"dict.type.outbound_order_type"
:value=
"scope.row.orderTypeId"
/>
<span
v-else
>
-
</span>
<span
v-else
>
-
</span>
...
@@ -201,7 +201,7 @@
...
@@ -201,7 +201,7 @@
<!-- 新增:订单类型列 -->
<!-- 新增:订单类型列 -->
<el-table-column
label=
"订单类型"
align=
"center"
prop=
"orderType"
width=
"120"
>
<el-table-column
label=
"订单类型"
align=
"center"
prop=
"orderType"
width=
"120"
>
<
template
slot-scope=
"scope"
>
<
template
slot-scope=
"scope"
>
<dict-tag
v-if=
"dict.type.o
utbound_order_type"
:options=
"dict.type.outbound_
order_type"
:value=
"scope.row.orderType"
/>
<dict-tag
v-if=
"dict.type.o
rder_type"
:options=
"dict.type.
order_type"
:value=
"scope.row.orderType"
/>
<span
v-else
>
-
</span>
<span
v-else
>
-
</span>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
...
@@ -299,7 +299,7 @@
...
@@ -299,7 +299,7 @@
<
el
-
form
-
item
label
=
"入库类型"
prop
=
"orderTypeId"
>
<
el
-
form
-
item
label
=
"入库类型"
prop
=
"orderTypeId"
>
<
el
-
select
v
-
model
=
"form.orderTypeId"
placeholder
=
"请选择入库类型"
:
disabled
=
"isViewDetail || formDisabled.orderTypeId"
style
=
"width: 100%"
>
<
el
-
select
v
-
model
=
"form.orderTypeId"
placeholder
=
"请选择入库类型"
:
disabled
=
"isViewDetail || formDisabled.orderTypeId"
style
=
"width: 100%"
>
<
el
-
option
<
el
-
option
v
-
for
=
"item in dict.type.
in
bound_order_type"
v
-
for
=
"item in dict.type.
out
bound_order_type"
:
key
=
"item.value"
:
key
=
"item.value"
:
label
=
"item.label"
:
label
=
"item.label"
:
value
=
"item.value"
:
value
=
"item.value"
...
@@ -314,7 +314,7 @@
...
@@ -314,7 +314,7 @@
<
el
-
form
-
item
label
=
"订单类型"
prop
=
"orderType"
>
<
el
-
form
-
item
label
=
"订单类型"
prop
=
"orderType"
>
<
el
-
select
v
-
model
=
"form.orderType"
placeholder
=
"请选择订单类型"
:
disabled
=
"isViewDetail || formDisabled.orderType"
style
=
"width: 100%"
>
<
el
-
select
v
-
model
=
"form.orderType"
placeholder
=
"请选择订单类型"
:
disabled
=
"isViewDetail || formDisabled.orderType"
style
=
"width: 100%"
>
<
el
-
option
<
el
-
option
v
-
for
=
"item in dict.type.o
utbound_o
rder_type"
v
-
for
=
"item in dict.type.order_type"
:
key
=
"item.value"
:
key
=
"item.value"
:
label
=
"item.label"
:
label
=
"item.label"
:
value
=
"item.value"
:
value
=
"item.value"
...
@@ -518,9 +518,12 @@
...
@@ -518,9 +518,12 @@
ref
=
"import"
ref
=
"import"
title
=
"导入"
title
=
"导入"
import
-
url
=
"/inventory/orders/import"
import
-
url
=
"/inventory/orders/import"
template
-
url
=
"
inventory/orders/importTemplate"
template
-
url
=
"/
inventory/orders/importTemplate"
template
-
name
=
"owners_importTemplate
"
template
-
name
=
"入库单导入模板
"
@
success
=
"getList"
@
success
=
"getList"
:
show
-
trdc
-
checkbox
=
"true"
@
orderTypeChange
=
"handleOrderTypeChange"
:
orderTypeRequired
=
"true"
/>
/>
<
/div
>
<
/div
>
<
/template
>
<
/template
>
...
@@ -534,10 +537,11 @@ import WarehouseSelector from "@/views/compononents/WarehouseSelector.vue"
...
@@ -534,10 +537,11 @@ import WarehouseSelector from "@/views/compononents/WarehouseSelector.vue"
import
LocationSelector
from
"@/views/compononents/LocationSelector.vue"
import
LocationSelector
from
"@/views/compononents/LocationSelector.vue"
import
OwnerSelector
from
"@/views/compononents/OwnerSelector.vue"
import
OwnerSelector
from
"@/views/compononents/OwnerSelector.vue"
import
PageTitle
from
"@/components/PageTitle"
import
PageTitle
from
"@/components/PageTitle"
import
ImportExcel
from
"@/components/ImportExcel/index"
import
ImportExcel
from
"@/components/ImportExcel/index"
export
default
{
export
default
{
name
:
"Orders"
,
name
:
"Orders"
,
dicts
:
[
'outbound_order_type'
,
'inbound_order_type'
,
'inbound_order_status'
,
'label_color'
],
dicts
:
[
'outbound_order_type'
,
'inbound_order_type'
,
'inbound_order_status'
,
'label_color'
,
'order_type'
],
components
:
{
components
:
{
OutboundOrderFormWithItems
,
OutboundOrderFormWithItems
,
WarehouseSelector
,
WarehouseSelector
,
...
@@ -677,6 +681,9 @@ export default {
...
@@ -677,6 +681,9 @@ export default {
}
,
}
,
methods
:
{
methods
:
{
handleOrderTypeChange
(
selection
)
{
this
.
form
.
orderTypeId
=
selection
}
,
/** 打开导入弹窗 */
/** 打开导入弹窗 */
handleImport
()
{
handleImport
()
{
this
.
$refs
.
import
.
show
()
this
.
$refs
.
import
.
show
()
...
@@ -934,8 +941,7 @@ handleOwnerSelected(owner) {
...
@@ -934,8 +941,7 @@ handleOwnerSelected(owner) {
this
.
detailDialogOpen
=
true
this
.
detailDialogOpen
=
true
}
)
}
)
}
,
}
,
// 修复:接收子组件提交的明细数据
handleDetailSubmit
(
details
)
{
handleDetailSubmit
(
details
)
{
// 确保是数组格式
// 确保是数组格式
const
detailList
=
Array
.
isArray
(
details
)
?
details
:
[
details
];
const
detailList
=
Array
.
isArray
(
details
)
?
details
:
[
details
];
if
(
detailList
.
length
===
0
)
{
if
(
detailList
.
length
===
0
)
{
...
@@ -983,7 +989,8 @@ handleOwnerSelected(owner) {
...
@@ -983,7 +989,8 @@ handleOwnerSelected(owner) {
sortNo
:
0
,
sortNo
:
0
,
remark
:
item
.
remark
||
''
,
remark
:
item
.
remark
||
''
,
warehouseName
:
item
.
warehouseName
||
this
.
form
.
warehouseName
||
''
,
warehouseName
:
item
.
warehouseName
||
this
.
form
.
warehouseName
||
''
,
locationName
:
item
.
locationName
||
''
locationName
:
item
.
locationName
||
''
,
batchCode
:
item
.
batchId
||
''
// 新增:将子组件的batchId赋值给batchCode
}
;
}
;
}
);
}
);
...
@@ -1019,7 +1026,8 @@ handleOwnerSelected(owner) {
...
@@ -1019,7 +1026,8 @@ handleOwnerSelected(owner) {
sortNo
:
0
,
sortNo
:
0
,
remark
:
item
.
remark
||
''
,
remark
:
item
.
remark
||
''
,
warehouseName
:
item
.
warehouseName
||
this
.
form
.
warehouseName
||
''
,
warehouseName
:
item
.
warehouseName
||
this
.
form
.
warehouseName
||
''
,
locationName
:
item
.
locationName
||
''
locationName
:
item
.
locationName
||
''
,
batchCode
:
item
.
batchId
||
''
// 新增:将子组件的batchId赋值给batchCode
}
;
}
;
}
);
}
);
...
@@ -1042,7 +1050,7 @@ handleOwnerSelected(owner) {
...
@@ -1042,7 +1050,7 @@ handleOwnerSelected(owner) {
this
.
detailDialogOpen
=
false
;
this
.
detailDialogOpen
=
false
;
// 强制更新视图
// 强制更新视图
this
.
$forceUpdate
();
this
.
$forceUpdate
();
}
,
}
,
// 计算主表总数量和总金额
// 计算主表总数量和总金额
calcTotalQuantity
()
{
calcTotalQuantity
()
{
let
totalPlanned
=
0
let
totalPlanned
=
0
...
...
ruoyi-inventory/src/main/java/com/ruoyi/inventory/controller/OutboundOrdersController.java
View file @
c2162be0
...
@@ -158,12 +158,12 @@ public class OutboundOrdersController extends BaseController
...
@@ -158,12 +158,12 @@ public class OutboundOrdersController extends BaseController
@PreAuthorize
(
"@ss.hasPermi('inventory:inbound:import')"
)
@PreAuthorize
(
"@ss.hasPermi('inventory:inbound:import')"
)
@Log
(
title
=
"入库信息导入"
,
businessType
=
BusinessType
.
IMPORT
)
@Log
(
title
=
"入库信息导入"
,
businessType
=
BusinessType
.
IMPORT
)
@PostMapping
(
"/import"
)
@PostMapping
(
"/import"
)
public
AjaxResult
importTemplate
(
MultipartFile
file
,
boolean
updateSupport
)
throws
Exception
public
AjaxResult
importTemplate
(
MultipartFile
file
,
boolean
updateSupport
,
Integer
orderType
)
throws
Exception
{
{
ExcelUtil
<
OutboundTemplateVO
>
util
=
new
ExcelUtil
<
OutboundTemplateVO
>(
OutboundTemplateVO
.
class
);
ExcelUtil
<
OutboundTemplateVO
>
util
=
new
ExcelUtil
<
OutboundTemplateVO
>(
OutboundTemplateVO
.
class
);
List
<
OutboundTemplateVO
>
inboundOrders
=
util
.
importExcel
(
file
.
getInputStream
());
List
<
OutboundTemplateVO
>
inboundOrders
=
util
.
importExcel
(
file
.
getInputStream
());
String
operName
=
getUsername
();
String
operName
=
getUsername
();
String
message
=
outboundOrdersService
.
importOutboundOrders
(
inboundOrders
,
updateSupport
,
operName
);
String
message
=
outboundOrdersService
.
importOutboundOrders
(
inboundOrders
,
updateSupport
,
operName
,
orderType
);
return
success
(
message
);
return
success
(
message
);
}
}
}
}
ruoyi-inventory/src/main/java/com/ruoyi/inventory/domain/Inventory.java
View file @
c2162be0
...
@@ -125,7 +125,13 @@ public class Inventory extends BaseEntity
...
@@ -125,7 +125,13 @@ public class Inventory extends BaseEntity
/** 预警类型 */
/** 预警类型 */
private
String
alertType
;
private
String
alertType
;
public
String
getWarehousesId
()
{
return
warehousesId
;
}
public
void
setWarehousesId
(
String
warehousesId
)
{
this
.
warehousesId
=
warehousesId
;
}
/** 最低库存 */
/** 最低库存 */
private
Long
minStockLevel
;
private
Long
minStockLevel
;
...
...
ruoyi-inventory/src/main/java/com/ruoyi/inventory/domain/vo/InboundOutboundStatisticsVO.java
View file @
c2162be0
...
@@ -68,7 +68,6 @@ public class InboundOutboundStatisticsVO extends BaseEntity {
...
@@ -68,7 +68,6 @@ public class InboundOutboundStatisticsVO extends BaseEntity {
/** 库位ID */
/** 库位ID */
private
String
locationId
;
private
String
locationId
;
/** 物料编码/ID查询 */
/** 物料编码/ID查询 */
private
String
materialCode
;
private
String
materialCode
;
...
...
ruoyi-inventory/src/main/java/com/ruoyi/inventory/domain/vo/OutboundOrdersSummaryVO.java
View file @
c2162be0
...
@@ -3,6 +3,7 @@ package com.ruoyi.inventory.domain.vo;
...
@@ -3,6 +3,7 @@ package com.ruoyi.inventory.domain.vo;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.ruoyi.common.annotation.Excel
;
import
com.ruoyi.common.annotation.Excel
;
import
com.ruoyi.common.core.domain.BaseEntity
;
import
com.ruoyi.common.core.domain.BaseEntity
;
import
lombok.Data
;
import
org.apache.commons.lang3.builder.ToStringBuilder
;
import
org.apache.commons.lang3.builder.ToStringBuilder
;
import
org.apache.commons.lang3.builder.ToStringStyle
;
import
org.apache.commons.lang3.builder.ToStringStyle
;
...
@@ -15,6 +16,7 @@ import java.util.Date;
...
@@ -15,6 +16,7 @@ import java.util.Date;
* @author ruoyi
* @author ruoyi
* @date 2025-12-10
* @date 2025-12-10
*/
*/
@Data
public
class
OutboundOrdersSummaryVO
extends
BaseEntity
public
class
OutboundOrdersSummaryVO
extends
BaseEntity
{
{
private
static
final
long
serialVersionUID
=
1L
;
private
static
final
long
serialVersionUID
=
1L
;
...
@@ -56,6 +58,9 @@ public class OutboundOrdersSummaryVO extends BaseEntity
...
@@ -56,6 +58,9 @@ public class OutboundOrdersSummaryVO extends BaseEntity
@Excel
(
name
=
"包装重量"
)
@Excel
(
name
=
"包装重量"
)
private
BigDecimal
packageWeight
;
private
BigDecimal
packageWeight
;
private
String
itemStatus
;
private
String
unitPrice
;
/** 总重量 */
/** 总重量 */
@Excel
(
name
=
"总重量"
)
@Excel
(
name
=
"总重量"
)
private
BigDecimal
totalWeight
;
private
BigDecimal
totalWeight
;
...
@@ -124,265 +129,10 @@ public class OutboundOrdersSummaryVO extends BaseEntity
...
@@ -124,265 +129,10 @@ public class OutboundOrdersSummaryVO extends BaseEntity
@JsonFormat
(
pattern
=
"yyyy-MM-dd"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd"
)
private
Date
endDate
;
private
Date
endDate
;
/** 订单状态(检索条件) */
@Excel
(
name
=
"订单状态 字典,检索条件"
)
private
Long
orderStatus
;
/** 库位ID(检索条件) */
/** 库位ID(检索条件) */
@Excel
(
name
=
"库位ID 检索条件"
)
@Excel
(
name
=
"库位ID 检索条件"
)
private
String
locationId
;
private
String
locationId
;
// ========== Getter & Setter 方法 ==========
private
String
locationName
;
public
String
getMaterialId
()
{
return
materialId
;
}
public
void
setMaterialId
(
String
materialId
)
{
this
.
materialId
=
materialId
;
}
public
String
getMaterialName
()
{
return
materialName
;
}
public
void
setMaterialName
(
String
materialName
)
{
this
.
materialName
=
materialName
;
}
public
String
getSapNo
()
{
return
sapNo
;
}
public
void
setSapNo
(
String
sapNo
)
{
this
.
sapNo
=
sapNo
;
}
public
String
getTsCode
()
{
return
tsCode
;
}
public
void
setTsCode
(
String
tsCode
)
{
this
.
tsCode
=
tsCode
;
}
public
String
getHazardId
()
{
return
hazardId
;
}
public
void
setHazardId
(
String
hazardId
)
{
this
.
hazardId
=
hazardId
;
}
public
String
getSpecification
()
{
return
specification
;
}
public
void
setSpecification
(
String
specification
)
{
this
.
specification
=
specification
;
}
public
String
getMaterialUnit
()
{
return
materialUnit
;
}
public
void
setMaterialUnit
(
String
materialUnit
)
{
this
.
materialUnit
=
materialUnit
;
}
public
BigDecimal
getUnitWeight
()
{
return
unitWeight
;
}
public
void
setUnitWeight
(
BigDecimal
unitWeight
)
{
this
.
unitWeight
=
unitWeight
;
}
public
BigDecimal
getPackageWeight
()
{
return
packageWeight
;
}
public
void
setPackageWeight
(
BigDecimal
packageWeight
)
{
this
.
packageWeight
=
packageWeight
;
}
public
BigDecimal
getTotalWeight
()
{
return
totalWeight
;
}
public
void
setTotalWeight
(
BigDecimal
totalWeight
)
{
this
.
totalWeight
=
totalWeight
;
}
public
BigDecimal
getVolume
()
{
return
volume
;
}
public
void
setVolume
(
BigDecimal
volume
)
{
this
.
volume
=
volume
;
}
public
Long
getShelfLifeDays
()
{
return
shelfLifeDays
;
}
public
void
setShelfLifeDays
(
Long
shelfLifeDays
)
{
this
.
shelfLifeDays
=
shelfLifeDays
;
}
public
String
getStorageTemperature
()
{
return
storageTemperature
;
}
public
void
setStorageTemperature
(
String
storageTemperature
)
{
this
.
storageTemperature
=
storageTemperature
;
}
public
String
getSpecialRequirements
()
{
return
specialRequirements
;
}
public
void
setSpecialRequirements
(
String
specialRequirements
)
{
this
.
specialRequirements
=
specialRequirements
;
}
public
Long
getSortNo
()
{
return
sortNo
;
}
public
void
setSortNo
(
Long
sortNo
)
{
this
.
sortNo
=
sortNo
;
}
public
BigDecimal
getPlannedQuantity
()
{
return
plannedQuantity
;
}
public
void
setPlannedQuantity
(
BigDecimal
plannedQuantity
)
{
this
.
plannedQuantity
=
plannedQuantity
;
}
public
BigDecimal
getActualQuantity
()
{
return
actualQuantity
;
}
public
void
setActualQuantity
(
BigDecimal
actualQuantity
)
{
this
.
actualQuantity
=
actualQuantity
;
}
public
BigDecimal
getTotalAmount
()
{
return
totalAmount
;
}
public
void
setTotalAmount
(
BigDecimal
totalAmount
)
{
this
.
totalAmount
=
totalAmount
;
}
public
String
getWarehouseId
()
{
return
warehouseId
;
}
public
void
setWarehouseId
(
String
warehouseId
)
{
this
.
warehouseId
=
warehouseId
;
}
public
String
getWarehouseName
()
{
return
warehouseName
;
}
public
void
setWarehouseName
(
String
warehouseName
)
{
this
.
warehouseName
=
warehouseName
;
}
public
String
getBatchCode
()
{
return
batchCode
;
}
public
void
setBatchCode
(
String
batchCode
)
{
this
.
batchCode
=
batchCode
;
}
public
String
getOrderId
()
{
return
orderId
;
}
public
void
setOrderId
(
String
orderId
)
{
this
.
orderId
=
orderId
;
}
public
String
getMainOrderId
()
{
return
mainOrderId
;
}
public
void
setMainOrderId
(
String
mainOrderId
)
{
this
.
mainOrderId
=
mainOrderId
;
}
public
Date
getStartDate
()
{
return
startDate
;
}
public
void
setStartDate
(
Date
startDate
)
{
this
.
startDate
=
startDate
;
}
public
Date
getEndDate
()
{
return
endDate
;
}
public
void
setEndDate
(
Date
endDate
)
{
this
.
endDate
=
endDate
;
}
public
Long
getOrderStatus
()
{
return
orderStatus
;
}
public
void
setOrderStatus
(
Long
orderStatus
)
{
this
.
orderStatus
=
orderStatus
;
}
public
String
getLocationId
()
{
return
locationId
;
}
public
void
setLocationId
(
String
locationId
)
{
this
.
locationId
=
locationId
;
}
// ========== ToString 方法 ==========
@Override
public
String
toString
()
{
return
new
ToStringBuilder
(
this
,
ToStringStyle
.
MULTI_LINE_STYLE
)
.
append
(
"materialId"
,
getMaterialId
())
.
append
(
"materialName"
,
getMaterialName
())
.
append
(
"sapNo"
,
getSapNo
())
.
append
(
"tsCode"
,
getTsCode
())
.
append
(
"hazardId"
,
getHazardId
())
.
append
(
"specification"
,
getSpecification
())
.
append
(
"materialUnit"
,
getMaterialUnit
())
.
append
(
"unitWeight"
,
getUnitWeight
())
.
append
(
"packageWeight"
,
getPackageWeight
())
.
append
(
"totalWeight"
,
getTotalWeight
())
.
append
(
"volume"
,
getVolume
())
.
append
(
"shelfLifeDays"
,
getShelfLifeDays
())
.
append
(
"storageTemperature"
,
getStorageTemperature
())
.
append
(
"specialRequirements"
,
getSpecialRequirements
())
.
append
(
"sortNo"
,
getSortNo
())
.
append
(
"plannedQuantity"
,
getPlannedQuantity
())
.
append
(
"actualQuantity"
,
getActualQuantity
())
.
append
(
"totalAmount"
,
getTotalAmount
())
.
append
(
"warehouseId"
,
getWarehouseId
())
.
append
(
"warehouseName"
,
getWarehouseName
())
.
append
(
"batchCode"
,
getBatchCode
())
.
append
(
"orderId"
,
getOrderId
())
.
append
(
"mainOrderId"
,
getMainOrderId
())
.
append
(
"startDate"
,
getStartDate
())
.
append
(
"endDate"
,
getEndDate
())
.
append
(
"orderStatus"
,
getOrderStatus
())
.
append
(
"locationId"
,
getLocationId
())
.
append
(
"remark"
,
getRemark
())
.
append
(
"createTime"
,
getCreateTime
())
.
append
(
"updateTime"
,
getUpdateTime
())
.
toString
();
}
}
}
\ No newline at end of file
ruoyi-inventory/src/main/java/com/ruoyi/inventory/domain/vo/StorageLocationsLocationTemplateVO.java
View file @
c2162be0
...
@@ -46,6 +46,6 @@ public class StorageLocationsLocationTemplateVO {
...
@@ -46,6 +46,6 @@ public class StorageLocationsLocationTemplateVO {
@Excel
(
name
=
"允许混放产品"
,
dictType
=
"yorn"
)
@Excel
(
name
=
"允许混放产品"
,
dictType
=
"yorn"
)
private
String
allowMixedProducts
;
private
String
allowMixedProducts
;
@Excel
(
name
=
"允许混放批次"
)
@Excel
(
name
=
"允许混放批次"
,
dictType
=
"yorn"
)
private
String
allowMixedBatches
;
private
String
allowMixedBatches
;
}
}
\ No newline at end of file
ruoyi-inventory/src/main/java/com/ruoyi/inventory/service/IOutboundOrdersService.java
View file @
c2162be0
...
@@ -78,5 +78,5 @@ public interface IOutboundOrdersService
...
@@ -78,5 +78,5 @@ public interface IOutboundOrdersService
public
String
outboundOrdersCount
();
public
String
outboundOrdersCount
();
@Transactional
(
rollbackFor
=
Exception
.
class
)
@Transactional
(
rollbackFor
=
Exception
.
class
)
String
importOutboundOrders
(
List
<
OutboundTemplateVO
>
inboundOrdersList
,
Boolean
isUpdateSupport
,
String
operName
);
String
importOutboundOrders
(
List
<
OutboundTemplateVO
>
inboundOrdersList
,
Boolean
isUpdateSupport
,
String
operName
,
Integer
orderType
);
}
}
ruoyi-inventory/src/main/java/com/ruoyi/inventory/service/impl/OutboundOrdersServiceImpl.java
View file @
c2162be0
...
@@ -252,7 +252,7 @@ public class OutboundOrdersServiceImpl implements IOutboundOrdersService
...
@@ -252,7 +252,7 @@ public class OutboundOrdersServiceImpl implements IOutboundOrdersService
@Transactional
(
rollbackFor
=
Exception
.
class
)
@Transactional
(
rollbackFor
=
Exception
.
class
)
@Override
@Override
public
String
importOutboundOrders
(
List
<
OutboundTemplateVO
>
inboundOrdersList
,
Boolean
isUpdateSupport
,
String
operName
)
{
public
String
importOutboundOrders
(
List
<
OutboundTemplateVO
>
inboundOrdersList
,
Boolean
isUpdateSupport
,
String
operName
,
Integer
orderType
)
{
// 1. 基础空值校验(完全保留你的代码)
// 1. 基础空值校验(完全保留你的代码)
if
(
CollectionUtils
.
isEmpty
(
inboundOrdersList
))
{
if
(
CollectionUtils
.
isEmpty
(
inboundOrdersList
))
{
throw
new
ServiceException
(
"导入数据不能为空!"
);
throw
new
ServiceException
(
"导入数据不能为空!"
);
...
@@ -348,6 +348,7 @@ public class OutboundOrdersServiceImpl implements IOutboundOrdersService
...
@@ -348,6 +348,7 @@ public class OutboundOrdersServiceImpl implements IOutboundOrdersService
mainDO
.
setOrderStatus
(
3L
);
mainDO
.
setOrderStatus
(
3L
);
mainDO
.
setCreateBy
(
operId
);
mainDO
.
setCreateBy
(
operId
);
mainDO
.
setCreateTime
(
now
);
mainDO
.
setCreateTime
(
now
);
mainDO
.
setOrderType
(
Long
.
valueOf
(
orderType
));
mainDO
.
setCreateUserCode
(
operId
);
mainDO
.
setCreateUserCode
(
operId
);
mainDO
.
setUpdateBy
(
operId
);
mainDO
.
setUpdateBy
(
operId
);
mainDO
.
setUpdateTime
(
now
);
mainDO
.
setUpdateTime
(
now
);
...
...
ruoyi-inventory/src/main/java/com/ruoyi/inventory/service/impl/StorageLocationsServiceImpl.java
View file @
c2162be0
...
@@ -270,6 +270,7 @@ public class StorageLocationsServiceImpl implements IStorageLocationsService
...
@@ -270,6 +270,7 @@ public class StorageLocationsServiceImpl implements IStorageLocationsService
storageLocations
.
setCreateBy
(
operId
);
storageLocations
.
setCreateBy
(
operId
);
storageLocations
.
setCreateTime
(
now
);
storageLocations
.
setCreateTime
(
now
);
storageLocations
.
setCreateUserCode
(
operId
);
storageLocations
.
setCreateUserCode
(
operId
);
storageLocations
.
setWarehousesId
(
"572ba484-199c-45d9-9735-610928ed5c70"
);
// 设置默认值
// 设置默认值
if
(
storageLocations
.
getIsUsed
()
==
null
)
{
if
(
storageLocations
.
getIsUsed
()
==
null
)
{
...
...
ruoyi-inventory/src/main/resources/mapper/inventory/InventoryMapper.xml
View file @
c2162be0
<?xml version="1.0" encoding="UTF-8" ?>
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper
<!DOCTYPE mapper
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.ruoyi.inventory.mapper.InventoryMapper"
>
<mapper
namespace=
"com.ruoyi.inventory.mapper.InventoryMapper"
>
<resultMap
type=
"Inventory"
id=
"InventoryResult"
>
<resultMap
type=
"Inventory"
id=
"InventoryResult"
>
...
@@ -44,7 +44,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
...
@@ -44,7 +44,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result
property=
"unitWeight"
column=
"unit_weight"
/>
<result
property=
"unitWeight"
column=
"unit_weight"
/>
<result
property=
"packageWeight"
column=
"package_weight"
/>
<result
property=
"packageWeight"
column=
"package_weight"
/>
<result
property=
"totalWeight"
column=
"total_weight"
/>
<result
property=
"totalWeight"
column=
"total_weight"
/>
<result
property=
"volume"
column=
"volume"
/>
<result
property=
"shelfLifeDays"
column=
"shelf_life_days"
/>
<result
property=
"shelfLifeDays"
column=
"shelf_life_days"
/>
<result
property=
"storageTemperature"
column=
"storage_temperature"
/>
<result
property=
"storageTemperature"
column=
"storage_temperature"
/>
<result
property=
"specialRequirements"
column=
"special_requirements"
/>
<result
property=
"specialRequirements"
column=
"special_requirements"
/>
...
@@ -89,6 +88,52 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
...
@@ -89,6 +88,52 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result
property=
"unitPrice"
column=
"unit_price"
/>
<result
property=
"unitPrice"
column=
"unit_price"
/>
</resultMap>
</resultMap>
<resultMap
type=
"com.ruoyi.inventory.domain.vo.InventoryVo"
id=
"InventoryVoResult"
>
<result
property=
"id"
column=
"id"
/>
<result
property=
"inventoryType"
column=
"inventory_type"
/>
<result
property=
"orderId"
column=
"order_id"
/>
<result
property=
"materialId"
column=
"material_id"
/>
<result
property=
"batchId"
column=
"batch_id"
/>
<result
property=
"warehousesCode"
column=
"warehouses_code"
/>
<result
property=
"locationId"
column=
"location_id"
/>
<result
property=
"ownerId"
column=
"owner_id"
/>
<result
property=
"quantity"
column=
"quantity"
/>
<result
property=
"lockedQuantity"
column=
"locked_quantity"
/>
<result
property=
"unitWeight"
column=
"unit_weight"
/>
<result
property=
"totalWeight"
column=
"total_weight"
/>
<result
property=
"totalVolume"
column=
"total_volume"
/>
<result
property=
"productionDate"
column=
"production_date"
/>
<result
property=
"expirationDate"
column=
"expiration_date"
/>
<result
property=
"inventoryStatus"
column=
"inventory_status"
/>
<result
property=
"lastInboundTime"
column=
"last_inbound_time"
/>
<result
property=
"lastOutboundTime"
column=
"last_outbound_time"
/>
<result
property=
"isUsed"
column=
"is_used"
/>
<result
property=
"sortNo"
column=
"sort_no"
/>
<result
property=
"createTime"
column=
"create_time"
/>
<result
property=
"createUserCode"
column=
"create_user_code"
/>
<result
property=
"updateTime"
column=
"update_time"
/>
<result
property=
"updateUserCode"
column=
"update_user_code"
/>
<result
property=
"warehousesId"
column=
"warehouses_id"
/>
<result
property=
"materialName"
column=
"material_name"
/>
<result
property=
"minStockLevel"
column=
"min_stock_level"
jdbcType=
"BIGINT"
/>
<result
property=
"maxStockLevel"
column=
"max_stock_level"
jdbcType=
"BIGINT"
/>
<result
property=
"sapNo"
column=
"sap_no"
/>
<result
property=
"tsCode"
column=
"ts_code"
/>
<result
property=
"hazardId"
column=
"hazard_id"
/>
<result
property=
"specification"
column=
"specification"
/>
<result
property=
"materialUnit"
column=
"material_unit"
/>
<result
property=
"unitWeight"
column=
"unit_weight"
/>
<result
property=
"packageWeight"
column=
"package_weight"
/>
<result
property=
"totalWeight"
column=
"total_weight"
/>
<result
property=
"shelfLifeDays"
column=
"shelf_life_days"
/>
<result
property=
"storageTemperature"
column=
"storage_temperature"
/>
<result
property=
"specialRequirements"
column=
"special_requirements"
/>
<result
property=
"alterType"
column=
"alterType"
/>
<result
property=
"warehousesName"
column=
"warehouses_name"
/>
<result
property=
"locationName"
column=
"location_name"
/>
<result
property=
"ownerName"
column=
"owner_name"
/>
</resultMap>
<resultMap
type=
"com.ruoyi.inventory.domain.vo.InventorySummaryVO"
id=
"InventorySummaryResult"
>
<resultMap
type=
"com.ruoyi.inventory.domain.vo.InventorySummaryVO"
id=
"InventorySummaryResult"
>
<result
property=
"materialId"
column=
"material_id"
/>
<result
property=
"materialId"
column=
"material_id"
/>
<result
property=
"materialName"
column=
"material_name"
/>
<result
property=
"materialName"
column=
"material_name"
/>
...
@@ -102,7 +147,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
...
@@ -102,7 +147,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result
property=
"unitWeight"
column=
"unit_weight"
/>
<result
property=
"unitWeight"
column=
"unit_weight"
/>
<result
property=
"packageWeight"
column=
"package_weight"
/>
<result
property=
"packageWeight"
column=
"package_weight"
/>
<result
property=
"totalWeight"
column=
"total_weight"
/>
<result
property=
"totalWeight"
column=
"total_weight"
/>
<result
property=
"volume"
column=
"volume"
/>
<result
property=
"shelfLifeDays"
column=
"shelf_life_days"
/>
<result
property=
"shelfLifeDays"
column=
"shelf_life_days"
/>
<result
property=
"storageTemperature"
column=
"storage_temperature"
/>
<result
property=
"storageTemperature"
column=
"storage_temperature"
/>
<result
property=
"specialRequirements"
column=
"special_requirements"
/>
<result
property=
"specialRequirements"
column=
"special_requirements"
/>
...
@@ -157,7 +201,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
...
@@ -157,7 +201,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
m.unit_weight,
m.unit_weight,
m.package_weight,
m.package_weight,
m.total_weight,
m.total_weight,
m.volume,
m.shelf_life_days,
m.shelf_life_days,
m.storage_temperature,
m.storage_temperature,
m.special_requirements,
m.special_requirements,
...
@@ -193,7 +236,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
...
@@ -193,7 +236,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
m.unit_weight,
m.unit_weight,
m.package_weight,
m.package_weight,
m.total_weight,
m.total_weight,
m.volume,
m.shelf_life_days,
m.shelf_life_days,
m.storage_temperature,
m.storage_temperature,
m.special_requirements ) tab
m.special_requirements ) tab
...
@@ -218,7 +260,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
...
@@ -218,7 +260,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if
test=
"inventoryStatus != null "
>
and i.inventory_status = #{inventoryStatus}
</if>
<if
test=
"inventoryStatus != null "
>
and i.inventory_status = #{inventoryStatus}
</if>
<if
test=
"isUsed != null "
>
and i.is_used = #{isUsed}
</if>
<if
test=
"isUsed != null "
>
and i.is_used = #{isUsed}
</if>
</where>
</where>
i.material_id, m.material_name, m.sap_no,
group by
i.material_id, m.material_name, m.sap_no,
m.ts_code,
m.ts_code,
m.hazard_id,
m.hazard_id,
m.specification,
m.specification,
...
@@ -226,7 +268,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
...
@@ -226,7 +268,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
m.unit_weight,
m.unit_weight,
m.package_weight,
m.package_weight,
m.total_weight,
m.total_weight,
m.volume,
m.shelf_life_days,
m.shelf_life_days,
m.storage_temperature,
m.storage_temperature,
m.special_requirements) tab
m.special_requirements) tab
...
@@ -268,7 +309,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
...
@@ -268,7 +309,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
m.unit_weight,
m.unit_weight,
m.package_weight,
m.package_weight,
m.total_weight,
m.total_weight,
m.volume,
m.shelf_life_days,
m.shelf_life_days,
m.storage_temperature,
m.storage_temperature,
m.special_requirements,
m.special_requirements,
...
@@ -535,7 +575,7 @@ and inventory_status = '1'
...
@@ -535,7 +575,7 @@ and inventory_status = '1'
#{id}
#{id}
</foreach>
</foreach>
</delete>
</delete>
<!-- 库存物料超出预警值统计-->
<!-- 库存物料超出预警值统计-->
<resultMap
id=
"InventoryExceedWarnResultMap"
type=
"com.ruoyi.inventory.domain.vo.InventoryExceedWarnVO"
>
<resultMap
id=
"InventoryExceedWarnResultMap"
type=
"com.ruoyi.inventory.domain.vo.InventoryExceedWarnVO"
>
<result
column=
"material_name"
property=
"materialName"
jdbcType=
"VARCHAR"
/>
<result
column=
"material_name"
property=
"materialName"
jdbcType=
"VARCHAR"
/>
<result
column=
"category_name"
property=
"categoryName"
jdbcType=
"VARCHAR"
/>
<result
column=
"category_name"
property=
"categoryName"
jdbcType=
"VARCHAR"
/>
...
...
ruoyi-inventory/src/main/resources/mapper/inventory/OutboundOrderItemsMapper.xml
View file @
c2162be0
...
@@ -42,6 +42,12 @@
...
@@ -42,6 +42,12 @@
<result
property=
"materialName"
column=
"material_name"
/>
<result
property=
"materialName"
column=
"material_name"
/>
<result
property=
"sapNo"
column=
"sap_no"
/>
<result
property=
"sapNo"
column=
"sap_no"
/>
<result
property=
"tsCode"
column=
"ts_code"
/>
<result
property=
"tsCode"
column=
"ts_code"
/>
<result
property=
"locationId"
column=
"location_id"
/>
<result
property=
"locationName"
column=
"location_name"
/>
<result
property=
"itemStatus"
column=
"item_status"
/>
<result
property=
"unitPrice"
column=
"unit_price"
/>
<result
property=
"hazardId"
column=
"hazard_id"
/>
<result
property=
"hazardId"
column=
"hazard_id"
/>
<result
property=
"specification"
column=
"specification"
/>
<result
property=
"specification"
column=
"specification"
/>
<result
property=
"materialUnit"
column=
"material_unit"
/>
<result
property=
"materialUnit"
column=
"material_unit"
/>
...
@@ -244,6 +250,8 @@
...
@@ -244,6 +250,8 @@
m.total_weight,
m.total_weight,
m.volume,
m.volume,
m.shelf_life_days,
m.shelf_life_days,
oi.location_id,
sl.location_name as location_name,
m.storage_temperature,
m.storage_temperature,
m.special_requirements,
m.special_requirements,
m.sort_no,
m.sort_no,
...
@@ -254,7 +262,10 @@
...
@@ -254,7 +262,10 @@
w.warehouses_name as warehouse_name,
w.warehouses_name as warehouse_name,
oi.batch_code,
oi.batch_code,
oi.order_id,
oi.order_id,
o.order_id as main_order_id
oi.remark,
oi.unit_price,
o.order_id as main_order_id,
oi.item_status
from outbound_order_items oi
from outbound_order_items oi
left join outbound_orders o on oi.outbound_order_id = o.id
left join outbound_orders o on oi.outbound_order_id = o.id
left join materials m on oi.material_id = m.id
left join materials m on oi.material_id = m.id
...
@@ -269,7 +280,7 @@
...
@@ -269,7 +280,7 @@
<if
test=
"endDate != null and endDate != ''"
>
and date_format(COALESCE(oi.shipped_at, o.inbound_date),'%Y-%m-%d')
<
= #{endDate}
</if>
<if
test=
"endDate != null and endDate != ''"
>
and date_format(COALESCE(oi.shipped_at, o.inbound_date),'%Y-%m-%d')
<
= #{endDate}
</if>
<if
test=
"warehouseId != null and warehouseId != ''"
>
and oi.warehouse_id = #{warehouseId}
</if>
<if
test=
"warehouseId != null and warehouseId != ''"
>
and oi.warehouse_id = #{warehouseId}
</if>
<if
test=
"locationId != null and locationId != ''"
>
and oi.location_id = #{locationId}
</if>
<if
test=
"locationId != null and locationId != ''"
>
and oi.location_id = #{locationId}
</if>
<if
test=
"
orderStatus != null "
>
and o.order_status = #{order
Status}
</if>
<if
test=
"
itemStatus != null "
>
and oi.item_status = #{item
Status}
</if>
</where>
</where>
group by oi.material_id, m.material_name, m.sap_no,
group by oi.material_id, m.material_name, m.sap_no,
m.ts_code,
m.ts_code,
...
...
ruoyi-inventory/src/main/resources/mapper/inventory/StorageLocationsMapper.xml
View file @
c2162be0
...
@@ -108,6 +108,8 @@
...
@@ -108,6 +108,8 @@
<if
test=
"pickingArea != null and pickingArea != ''"
>
and sl.picking_area = #{pickingArea}
</if>
<if
test=
"pickingArea != null and pickingArea != ''"
>
and sl.picking_area = #{pickingArea}
</if>
<if
test=
"allowMixedProducts != null "
>
and sl.allow_mixed_products = #{allowMixedProducts}
</if>
<if
test=
"allowMixedProducts != null "
>
and sl.allow_mixed_products = #{allowMixedProducts}
</if>
<if
test=
"allowMixedBatches != null "
>
and sl.allow_mixed_batches = #{allowMixedBatches}
</if>
<if
test=
"allowMixedBatches != null "
>
and sl.allow_mixed_batches = #{allowMixedBatches}
</if>
<!-- 按sort_no降序排序 -->
order by sl.sort_no desc
</select>
</select>
<!-- 关联仓库表的列表查询(简化) -->
<!-- 关联仓库表的列表查询(简化) -->
...
@@ -129,6 +131,8 @@
...
@@ -129,6 +131,8 @@
<if
test=
"pickingArea != null and pickingArea != ''"
>
and sl.picking_area = #{pickingArea}
</if>
<if
test=
"pickingArea != null and pickingArea != ''"
>
and sl.picking_area = #{pickingArea}
</if>
<if
test=
"allowMixedProducts != null "
>
and sl.allow_mixed_products = #{allowMixedProducts}
</if>
<if
test=
"allowMixedProducts != null "
>
and sl.allow_mixed_products = #{allowMixedProducts}
</if>
<if
test=
"allowMixedBatches != null "
>
and sl.allow_mixed_batches = #{allowMixedBatches}
</if>
<if
test=
"allowMixedBatches != null "
>
and sl.allow_mixed_batches = #{allowMixedBatches}
</if>
<!-- 按sort_no降序排序 -->
order by sl.sort_no desc
</select>
</select>
<!-- 根据ID查询(调整:保留where,单独条件) -->
<!-- 根据ID查询(调整:保留where,单独条件) -->
...
@@ -180,12 +184,16 @@
...
@@ -180,12 +184,16 @@
<select
id=
"selectStorageLocationsByWarehousesCode"
parameterType=
"String"
resultMap=
"StorageLocationsResult"
>
<select
id=
"selectStorageLocationsByWarehousesCode"
parameterType=
"String"
resultMap=
"StorageLocationsResult"
>
<include
refid=
"selectStorageLocationsVo"
/>
<include
refid=
"selectStorageLocationsVo"
/>
and sl.warehouses_code = #{warehousesCode}
and sl.warehouses_code = #{warehousesCode}
<!-- 按sort_no降序排序 -->
order by sl.sort_no desc
</select>
</select>
<!-- 关联仓库表的仓库编码查询(简化) -->
<!-- 关联仓库表的仓库编码查询(简化) -->
<select
id=
"selectStorageLocationsByWarehousesCodeWithWarehouses"
parameterType=
"String"
resultMap=
"StorageLocationsWithWarehousesResult"
>
<select
id=
"selectStorageLocationsByWarehousesCodeWithWarehouses"
parameterType=
"String"
resultMap=
"StorageLocationsWithWarehousesResult"
>
<include
refid=
"selectStorageLocationsWithWarehousesVo"
/>
<include
refid=
"selectStorageLocationsWithWarehousesVo"
/>
and sl.warehouses_code = #{warehousesCode}
and sl.warehouses_code = #{warehousesCode}
<!-- 按sort_no降序排序 -->
order by sl.sort_no desc
</select>
</select>
<!-- 根据仓库编码列表查询(简化) -->
<!-- 根据仓库编码列表查询(简化) -->
...
@@ -195,6 +203,8 @@
...
@@ -195,6 +203,8 @@
<foreach
item=
"id"
collection=
"list"
open=
"("
separator=
","
close=
")"
>
<foreach
item=
"id"
collection=
"list"
open=
"("
separator=
","
close=
")"
>
#{id}
#{id}
</foreach>
</foreach>
<!-- 按sort_no降序排序 -->
order by sl.sort_no desc
</select>
</select>
<!-- 关联仓库表的编码列表查询(简化) -->
<!-- 关联仓库表的编码列表查询(简化) -->
...
@@ -204,12 +214,16 @@
...
@@ -204,12 +214,16 @@
<foreach
item=
"id"
collection=
"list"
open=
"("
separator=
","
close=
")"
>
<foreach
item=
"id"
collection=
"list"
open=
"("
separator=
","
close=
")"
>
#{id}
#{id}
</foreach>
</foreach>
<!-- 按sort_no降序排序 -->
order by sl.sort_no desc
</select>
</select>
<!-- 获取库位表 的 location_code 编码 location_name 做成字典-->
<!-- 获取库位表 的 location_code 编码 location_name 做成字典-->
<select
id=
"getMapList"
parameterType=
"StorageLocations"
resultType=
"java.util.Map"
>
<select
id=
"getMapList"
parameterType=
"StorageLocations"
resultType=
"java.util.Map"
>
select id, IFNULL(location_name, '') as location_name from storage_locations where is_used = 1
select id, IFNULL(location_name, '') as location_name from storage_locations where is_used = 1
<if
test=
"warehousesCode != null and warehousesCode != ''"
>
and warehouses_id = #{warehousesCode}
</if>
<if
test=
"warehousesCode != null and warehousesCode != ''"
>
and warehouses_id = #{warehousesCode}
</if>
<!-- 按sort_no降序排序 -->
order by sort_no desc
</select>
</select>
<!-- 关联仓库的字典查询 -->
<!-- 关联仓库的字典查询 -->
...
@@ -219,6 +233,8 @@
...
@@ -219,6 +233,8 @@
left join warehouses w on sl.warehouses_code = w.warehouses_code
left join warehouses w on sl.warehouses_code = w.warehouses_code
where sl.is_used = 1
where sl.is_used = 1
<if
test=
"warehousesCode != null and warehousesCode != ''"
>
and sl.warehouses_code = #{warehousesCode}
</if>
<if
test=
"warehousesCode != null and warehousesCode != ''"
>
and sl.warehouses_code = #{warehousesCode}
</if>
<!-- 按sort_no降序排序 -->
order by sl.sort_no desc
</select>
</select>
<!-- 原有新增/更新/删除方法(仅添加新字段) -->
<!-- 原有新增/更新/删除方法(仅添加新字段) -->
...
@@ -393,6 +409,8 @@
...
@@ -393,6 +409,8 @@
<if
test=
"pickingArea != null and pickingArea != ''"
>
and sl.picking_area = #{pickingArea}
</if>
<if
test=
"pickingArea != null and pickingArea != ''"
>
and sl.picking_area = #{pickingArea}
</if>
<if
test=
"allowMixedProducts != null "
>
and sl.allow_mixed_products = #{allowMixedProducts}
</if>
<if
test=
"allowMixedProducts != null "
>
and sl.allow_mixed_products = #{allowMixedProducts}
</if>
<if
test=
"allowMixedBatches != null "
>
and sl.allow_mixed_batches = #{allowMixedBatches}
</if>
<if
test=
"allowMixedBatches != null "
>
and sl.allow_mixed_batches = #{allowMixedBatches}
</if>
<!-- 按sort_no降序排序 -->
order by sl.sort_no desc
</select>
</select>
<!-- 关联仓库的getStorageLocationsList -->
<!-- 关联仓库的getStorageLocationsList -->
...
@@ -414,6 +432,8 @@
...
@@ -414,6 +432,8 @@
<if
test=
"pickingArea != null and pickingArea != ''"
>
and sl.picking_area = #{pickingArea}
</if>
<if
test=
"pickingArea != null and pickingArea != ''"
>
and sl.picking_area = #{pickingArea}
</if>
<if
test=
"allowMixedProducts != null "
>
and sl.allow_mixed_products = #{allowMixedProducts}
</if>
<if
test=
"allowMixedProducts != null "
>
and sl.allow_mixed_products = #{allowMixedProducts}
</if>
<if
test=
"allowMixedBatches != null "
>
and sl.allow_mixed_batches = #{allowMixedBatches}
</if>
<if
test=
"allowMixedBatches != null "
>
and sl.allow_mixed_batches = #{allowMixedBatches}
</if>
<!-- 按sort_no降序排序 -->
order by sl.sort_no desc
</select>
</select>
</mapper>
</mapper>
\ No newline at end of file
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论