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
f9be7e47
Commit
f9be7e47
authored
Dec 16, 2025
by
wangchunyang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
仓库库位选择调整,表格宽度调整,ID字样消除,盘点功能样式调整
parent
5e1984ae
隐藏空白字符变更
内嵌
并排
正在显示
13 个修改的文件
包含
324 行增加
和
295 行删除
+324
-295
ruoyi-admin-vue/src/views/inventory/inbound/details.vue
+11
-12
ruoyi-admin-vue/src/views/inventory/inbound_items/index.vue
+1
-1
ruoyi-admin-vue/src/views/inventory/items/index.vue
+10
-13
ruoyi-admin-vue/src/views/inventory/locations/index.vue
+85
-86
ruoyi-admin-vue/src/views/inventory/orders/OutboundOrderFormWithItems.vue
+19
-20
ruoyi-admin-vue/src/views/inventory/orders/index.vue
+36
-37
ruoyi-admin-vue/src/views/inventory/report_view/inbound_outbound_statistics.vue
+10
-11
ruoyi-admin-vue/src/views/inventory/report_view/inventory_detail.vue
+14
-15
ruoyi-admin-vue/src/views/inventory/return_op/items.vue
+2
-2
ruoyi-admin-vue/src/views/inventory/stocktake_items/index.vue
+16
-16
ruoyi-admin-vue/src/views/inventory/stocktakes/stocktakeCountTable.vue
+8
-9
ruoyi-admin-vue/src/views/inventory/stocktakes/stocktakeItemsTable.vue
+85
-45
ruoyi-admin-vue/src/views/inventory/warehouses/index.vue
+27
-28
没有找到文件。
ruoyi-admin-vue/src/views/inventory/inbound/details.vue
View file @
f9be7e47
...
@@ -47,10 +47,10 @@
...
@@ -47,10 +47,10 @@
@
keyup
.
enter
.
native=
"handleQuery"
@
keyup
.
enter
.
native=
"handleQuery"
/>
/>
</el-form-item>
</el-form-item>
<el-form-item
label=
"批次
ID
"
prop=
"batchId"
>
<el-form-item
label=
"批次"
prop=
"batchId"
>
<el-input
<el-input
v-model=
"queryParams.batchId"
v-model=
"queryParams.batchId"
placeholder=
"请输入批次
ID
"
placeholder=
"请输入批次"
clearable
clearable
@
keyup
.
enter
.
native=
"handleQuery"
@
keyup
.
enter
.
native=
"handleQuery"
/>
/>
...
@@ -80,7 +80,7 @@
...
@@ -80,7 +80,7 @@
readonly
readonly
@
focus=
"openLocationSelector"
@
focus=
"openLocationSelector"
:suffix-icon=
"''"
:suffix-icon=
"''"
>
>
<
template
v-if=
"queryLocationName"
#
suffix
>
<
template
v-if=
"queryLocationName"
#
suffix
>
<i
<i
...
@@ -149,17 +149,17 @@
...
@@ -149,17 +149,17 @@
:
limit
.
sync
=
"queryParams.pageSize"
:
limit
.
sync
=
"queryParams.pageSize"
@
pagination
=
"getList"
@
pagination
=
"getList"
/>
/>
<!--
仓库选择组件
-->
<!--
仓库选择组件
-->
<
WarehouseSelector
<
WarehouseSelector
v
-
model
=
"warehouseSelectorVisible"
v
-
model
=
"warehouseSelectorVisible"
@
selected
=
"handleWarehouseSelected"
@
selected
=
"handleWarehouseSelected"
/>
/>
<!--
库位选择组件
-->
<!--
库位选择组件
-->
<
LocationSelector
<
LocationSelector
v
-
model
=
"locationSelectorVisible"
v
-
model
=
"locationSelectorVisible"
@
selected
=
"handleLocationSelected"
@
selected
=
"handleLocationSelected"
/>
/>
<
/div
>
<
/div
>
...
@@ -286,8 +286,8 @@ export default {
...
@@ -286,8 +286,8 @@ export default {
this
.
queryParams
.
warehouseId
=
warehouse
.
warehouseId
this
.
queryParams
.
warehouseId
=
warehouse
.
warehouseId
this
.
queryWarehouseName
=
warehouse
.
warehousesName
||
warehouse
.
warehousesCode
this
.
queryWarehouseName
=
warehouse
.
warehousesName
||
warehouse
.
warehousesCode
// 仓库选择后,清空库位信息
// 仓库选择后,清空库位信息
this
.
queryLocationName
=
null
//
this.queryLocationName = null
this
.
queryParams
.
locationId
=
null
//
this.queryParams.locationId = null
this
.
handleQuery
()
this
.
handleQuery
()
}
,
}
,
...
@@ -296,8 +296,8 @@ export default {
...
@@ -296,8 +296,8 @@ export default {
this
.
queryWarehouseName
=
null
this
.
queryWarehouseName
=
null
this
.
queryParams
.
warehouseId
=
null
this
.
queryParams
.
warehouseId
=
null
// 清空仓库时,同时清空库位
// 清空仓库时,同时清空库位
this
.
queryLocationName
=
null
//
this.queryLocationName = null
this
.
queryParams
.
locationId
=
null
//
this.queryParams.locationId = null
this
.
handleQuery
()
this
.
handleQuery
()
}
,
}
,
...
@@ -347,4 +347,4 @@ export default {
...
@@ -347,4 +347,4 @@ export default {
.
table
-
container
{
.
table
-
container
{
margin
-
top
:
16
px
;
margin
-
top
:
16
px
;
}
}
<
/style>
<
/style
>
\ No newline at end of file
ruoyi-admin-vue/src/views/inventory/inbound_items/index.vue
View file @
f9be7e47
...
@@ -752,7 +752,7 @@ export default {
...
@@ -752,7 +752,7 @@ export default {
const
errors
=
[]
const
errors
=
[]
this
.
displayData
.
forEach
((
item
,
index
)
=>
{
this
.
displayData
.
forEach
((
item
,
index
)
=>
{
if
(
!
item
.
materialId
)
{
if
(
!
item
.
materialId
)
{
errors
.
push
(
`第
${
index
+
1
}
行:货物
ID
不能为空`
)
errors
.
push
(
`第
${
index
+
1
}
行:货物不能为空`
)
}
}
if
(
parseFloat
(
item
.
actualQuantity
)
<=
0
)
{
if
(
parseFloat
(
item
.
actualQuantity
)
<=
0
)
{
errors
.
push
(
`第
${
index
+
1
}
实际数量必须大于0`
)
errors
.
push
(
`第
${
index
+
1
}
实际数量必须大于0`
)
...
...
ruoyi-admin-vue/src/views/inventory/items/index.vue
View file @
f9be7e47
...
@@ -56,7 +56,7 @@
...
@@ -56,7 +56,7 @@
<el-form-item
label=
"物料"
prop=
"materialId"
>
<el-form-item
label=
"物料"
prop=
"materialId"
>
<el-input
<el-input
v-model=
"queryParams.materialId"
v-model=
"queryParams.materialId"
placeholder=
"请输入物料
ID
或编码"
placeholder=
"请输入物料或编码"
clearable
clearable
@
keyup
.
enter
.
native=
"handleQuery"
@
keyup
.
enter
.
native=
"handleQuery"
/>
/>
...
@@ -81,11 +81,9 @@
...
@@ -81,11 +81,9 @@
<el-form-item
label=
"库位"
prop=
"locationId"
>
<el-form-item
label=
"库位"
prop=
"locationId"
>
<el-input
<el-input
v-model=
"queryLocationName"
v-model=
"queryLocationName"
placeholder=
"请选择库位"
readonly
readonly
@
focus=
"openLocationSelector"
@
focus=
"openLocationSelector"
:suffix-icon=
"''"
:suffix-icon=
"''"
:disabled=
"!queryParams.warehouseId"
>
>
<
template
v-if=
"queryLocationName"
#
suffix
>
<
template
v-if=
"queryLocationName"
#
suffix
>
<i
<i
...
@@ -411,23 +409,23 @@ export default {
...
@@ -411,23 +409,23 @@ export default {
if
(
!
warehouse
)
return
if
(
!
warehouse
)
return
this
.
queryParams
.
warehouseId
=
warehouse
.
warehouseId
this
.
queryParams
.
warehouseId
=
warehouse
.
warehouseId
this
.
queryWarehouseName
=
warehouse
.
warehousesName
||
warehouse
.
warehousesCode
this
.
queryWarehouseName
=
warehouse
.
warehousesName
||
warehouse
.
warehousesCode
this
.
queryLocationName
=
null
//
this.queryLocationName = null
this
.
queryParams
.
locationId
=
null
//
this.queryParams.locationId = null
this
.
handleQuery
()
this
.
handleQuery
()
},
},
clearQueryWarehouse
()
{
clearQueryWarehouse
()
{
this
.
queryWarehouseName
=
null
this
.
queryWarehouseName
=
null
this
.
queryParams
.
warehouseId
=
null
this
.
queryParams
.
warehouseId
=
null
this
.
queryParams
.
warehousesCode
=
null
this
.
queryParams
.
warehousesCode
=
null
this
.
queryLocationName
=
null
//
this.queryLocationName = null
this
.
queryParams
.
locationId
=
null
//
this.queryParams.locationId = null
this
.
handleQuery
()
this
.
handleQuery
()
},
},
openLocationSelector
()
{
openLocationSelector
()
{
if
(
!
this
.
queryParams
.
warehouseId
)
{
//
if (!this.queryParams.warehouseId) {
this
.
$message
.
warning
(
"请先选择仓库"
)
//
this.$message.warning("请先选择仓库")
return
//
return
}
//
}
this
.
locationSelectorVisible
=
true
this
.
locationSelectorVisible
=
true
},
},
handleLocationSelected
(
location
)
{
handleLocationSelected
(
location
)
{
...
@@ -568,4 +566,4 @@ export default {
...
@@ -568,4 +566,4 @@ export default {
.w20
{
.w20
{
width
:
150px
;
width
:
150px
;
}
}
</
style
>
</
style
>
\ No newline at end of file
ruoyi-admin-vue/src/views/inventory/locations/index.vue
View file @
f9be7e47
...
@@ -48,10 +48,10 @@
...
@@ -48,10 +48,10 @@
</PageTitle>
</PageTitle>
<div
class=
"page-container"
>
<div
class=
"page-container"
>
<page-wrapper-search
<page-wrapper-search
:model=
"queryParams"
:model=
"queryParams"
ref=
"queryForm"
ref=
"queryForm"
size=
"small"
size=
"small"
@
search=
"handleQuery"
@
search=
"handleQuery"
@
reset=
"resetQuery"
@
reset=
"resetQuery"
>
>
...
@@ -160,15 +160,15 @@
...
@@ -160,15 +160,15 @@
/>
/>
</el-form-item>
</el-form-item>
</page-wrapper-search>
</page-wrapper-search>
<div
class=
"table-container"
>
<div
class=
"table-container"
>
<el-table
<el-table
ref=
"locationsTable"
ref=
"locationsTable"
v-loading=
"loading"
v-loading=
"loading"
:data=
"locationsList"
:data=
"locationsList"
height=
"100%"
height=
"100%"
@
selection-change=
"handleSelectionChange"
@
selection-change=
"handleSelectionChange"
@
row-click=
"handleRowClick"
@
row-click=
"handleRowClick"
row-key=
"id"
row-key=
"id"
>
>
<el-table-column
type=
"expand"
>
<el-table-column
type=
"expand"
>
...
@@ -259,7 +259,7 @@
...
@@ -259,7 +259,7 @@
</el-table-column>
</el-table-column>
<el-table-column
label=
"上架顺序"
align=
"center"
prop=
"putawayOrder"
width=
"100"
/>
<el-table-column
label=
"上架顺序"
align=
"center"
prop=
"putawayOrder"
width=
"100"
/>
<el-table-column
label=
"拣货顺序"
align=
"center"
prop=
"pickingOrder"
width=
"100"
/>
<el-table-column
label=
"拣货顺序"
align=
"center"
prop=
"pickingOrder"
width=
"100"
/>
<el-table-column
label=
"库位容量(千克)"
align=
"center"
prop=
"capacity"
width=
"120"
/>
<el-table-column
label=
"库位容量(千克)"
align=
"center"
prop=
"capacity"
width=
"120"
/>
<el-table-column
label=
"体积容量(立方米)"
align=
"center"
prop=
"volumeCapacity"
width=
"120"
/>
<el-table-column
label=
"体积容量(立方米)"
align=
"center"
prop=
"volumeCapacity"
width=
"120"
/>
<el-table-column
label=
"允许存放的危险等级"
align=
"center"
prop=
"allowedHazardLevels"
width=
"140"
/>
<el-table-column
label=
"允许存放的危险等级"
align=
"center"
prop=
"allowedHazardLevels"
width=
"140"
/>
...
@@ -300,7 +300,7 @@
...
@@ -300,7 +300,7 @@
<dict-tag
:options=
"dict.type.is_enabled"
:value=
"scope.row.isEnabled"
/>
<dict-tag
:options=
"dict.type.is_enabled"
:value=
"scope.row.isEnabled"
/>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
<el-table-column
label=
"创建日期"
align=
"center"
prop=
"createTime"
width=
"160"
/>
<el-table-column
label=
"创建日期"
align=
"center"
prop=
"createTime"
width=
"160"
/>
<el-table-column
label=
"操作"
align=
"center"
class-name=
"small-padding fixed-width"
width=
"120"
fixed=
"right"
>
<el-table-column
label=
"操作"
align=
"center"
class-name=
"small-padding fixed-width"
width=
"120"
fixed=
"right"
>
<
template
slot-scope=
"scope"
>
<
template
slot-scope=
"scope"
>
...
@@ -322,7 +322,7 @@
...
@@ -322,7 +322,7 @@
</el-table-column>
</el-table-column>
</el-table>
</el-table>
</div>
</div>
<pagination
<pagination
v-show=
"total>0"
v-show=
"total>0"
:total=
"total"
:total=
"total"
...
@@ -338,20 +338,20 @@
...
@@ -338,20 +338,20 @@
<el-row
:gutter=
"20"
>
<el-row
:gutter=
"20"
>
<el-col
:span=
"12"
>
<el-col
:span=
"12"
>
<el-form-item
label=
"库位编码"
prop=
"locationCode"
>
<el-form-item
label=
"库位编码"
prop=
"locationCode"
>
<el-input
<el-input
v-model=
"form.locationCode"
v-model=
"form.locationCode"
placeholder=
"请输入库位编码"
placeholder=
"请输入库位编码"
:readonly=
"!!form.id"
:readonly=
"!!form.id"
:disabled=
"!!form.id"
:disabled=
"!!form.id"
/>
/>
</el-form-item>
</el-form-item>
</el-col>
</el-col>
<el-col
:span=
"12"
>
<el-col
:span=
"12"
>
<el-form-item
label=
"库位名称"
prop=
"locationName"
>
<el-form-item
label=
"库位名称"
prop=
"locationName"
>
<el-input
<el-input
v-model=
"form.locationName"
v-model=
"form.locationName"
placeholder=
"请输入库位名称"
placeholder=
"请输入库位名称"
:readonly=
"!!form.id"
:readonly=
"!!form.id"
:disabled=
"!!form.id"
:disabled=
"!!form.id"
/>
/>
</el-form-item>
</el-form-item>
...
@@ -483,22 +483,22 @@
...
@@ -483,22 +483,22 @@
<el-row
:gutter=
"20"
>
<el-row
:gutter=
"20"
>
<el-col
:span=
"12"
>
<el-col
:span=
"12"
>
<el-form-item
label=
"库位容量(千克)"
prop=
"capacity"
>
<el-form-item
label=
"库位容量(千克)"
prop=
"capacity"
>
<el-input-number
<el-input-number
v-model=
"form.capacity"
v-model=
"form.capacity"
placeholder=
"请输入库位容量(千克)"
placeholder=
"请输入库位容量(千克)"
:min=
"0"
:min=
"0"
:step=
"0.01"
:step=
"0.01"
style=
"width: 100%;"
style=
"width: 100%;"
/>
/>
</el-form-item>
</el-form-item>
</el-col>
</el-col>
<el-col
:span=
"12"
>
<el-col
:span=
"12"
>
<el-form-item
label=
"体积容量(立方米)"
prop=
"volumeCapacity"
>
<el-form-item
label=
"体积容量(立方米)"
prop=
"volumeCapacity"
>
<el-input-number
<el-input-number
v-model=
"form.volumeCapacity"
v-model=
"form.volumeCapacity"
placeholder=
"请输入体积容量(立方米)"
placeholder=
"请输入体积容量(立方米)"
:min=
"0"
:min=
"0"
:step=
"0.01"
:step=
"0.01"
style=
"width: 100%;"
style=
"width: 100%;"
/>
/>
</el-form-item>
</el-form-item>
...
@@ -513,12 +513,12 @@
...
@@ -513,12 +513,12 @@
<el-col
:span=
"12"
>
<el-col
:span=
"12"
>
<el-form-item
label=
"允许存放物料"
prop=
"allowedCategoryIds"
>
<el-form-item
label=
"允许存放物料"
prop=
"allowedCategoryIds"
>
<div
style=
"display: flex; align-items: center; flex-direction: column; gap: 8px;"
>
<div
style=
"display: flex; align-items: center; flex-direction: column; gap: 8px;"
>
<el-input
<el-input
v-model=
"form.allowedCategoryNames"
v-model=
"form.allowedCategoryNames"
@
click=
"initMaterialSelector"
@
click=
"initMaterialSelector"
placeholder=
"请选择允许存放的物料"
placeholder=
"请选择允许存放的物料"
readonly
readonly
style=
"width: 100%;"
style=
"width: 100%;"
/>
/>
</div>
</div>
</el-form-item>
</el-form-item>
...
@@ -533,7 +533,7 @@
...
@@ -533,7 +533,7 @@
</el-radio-group>
</el-radio-group>
</el-form-item>
</el-form-item>
</el-col>
</el-col>
</el-row>
</el-row>
<el-row
:gutter=
"20"
>
<el-row
:gutter=
"20"
>
<el-col
:span=
"24"
>
<el-col
:span=
"24"
>
...
@@ -555,8 +555,8 @@
...
@@ -555,8 +555,8 @@
:visible
.
sync=
"showMaterialSelect"
:visible
.
sync=
"showMaterialSelect"
width=
"1000px"
width=
"1000px"
append-to-body
append-to-body
:close-on-click-modal=
"false"
:close-on-click-modal=
"false"
:close-on-press-escape=
"false"
:close-on-press-escape=
"false"
>
>
<materialsSeletor
<materialsSeletor
ref=
"materialsSeletor"
ref=
"materialsSeletor"
...
@@ -581,7 +581,7 @@
...
@@ -581,7 +581,7 @@
template-name=
"locations_importTemplate"
template-name=
"locations_importTemplate"
@
success=
"getList"
@
success=
"getList"
/>
/>
<!-- 仓库选择器组件 -->
<!-- 仓库选择器组件 -->
<!-- <WarehouseSelector
<!-- <WarehouseSelector
v-model="warehouseSelectorVisible"
v-model="warehouseSelectorVisible"
...
@@ -600,7 +600,7 @@ import { listMaterials } from "@/api/inventory/materials"
...
@@ -600,7 +600,7 @@ import { listMaterials } from "@/api/inventory/materials"
export
default
{
export
default
{
name
:
"Locations"
,
name
:
"Locations"
,
components
:
{
materialsSeletor
,
WarehouseSelector
,
ImportExcel
},
components
:
{
materialsSeletor
,
ImportExcel
},
dicts
:
[
'sys_normal_disable'
,
'location_type'
,
'location_usage'
,
'yorn'
,
'is_enabled'
],
dicts
:
[
'sys_normal_disable'
,
'location_type'
,
'location_usage'
,
'yorn'
,
'is_enabled'
],
data
()
{
data
()
{
return
{
return
{
...
@@ -748,21 +748,21 @@ export default {
...
@@ -748,21 +748,21 @@ export default {
this
.
queryParams
.
warehouseId
=
null
this
.
queryParams
.
warehouseId
=
null
this
.
handleQuery
()
this
.
handleQuery
()
},
},
// 清空表单仓库
// 清空表单仓库
clearFormWarehouse
()
{
clearFormWarehouse
()
{
console
.
log
(
'【清空表单仓库】执行清空操作'
)
console
.
log
(
'【清空表单仓库】执行清空操作'
)
this
.
form
.
warehouseName
=
''
this
.
form
.
warehouseName
=
''
this
.
form
.
warehouseId
=
null
this
.
form
.
warehouseId
=
null
},
},
// 仓库选择回调
// 仓库选择回调
handleWarehouseSelected
(
warehouse
)
{
handleWarehouseSelected
(
warehouse
)
{
console
.
log
(
'【仓库选择回调】选中的仓库数据:'
,
warehouse
)
console
.
log
(
'【仓库选择回调】选中的仓库数据:'
,
warehouse
)
if
(
!
warehouse
)
return
if
(
!
warehouse
)
return
const
warehouseId
=
warehouse
.
warehousesId
||
warehouse
.
warehouseId
||
warehouse
.
id
const
warehouseId
=
warehouse
.
warehousesId
||
warehouse
.
warehouseId
||
warehouse
.
id
const
warehouseName
=
warehouse
.
warehousesName
||
warehouse
.
name
||
warehouse
.
warehouseName
const
warehouseName
=
warehouse
.
warehousesName
||
warehouse
.
name
||
warehouse
.
warehouseName
if
(
this
.
warehouseSelectTarget
===
'query'
)
{
if
(
this
.
warehouseSelectTarget
===
'query'
)
{
this
.
queryParams
.
warehouseId
=
warehouseId
this
.
queryParams
.
warehouseId
=
warehouseId
this
.
queryWarehouseName
=
warehouseName
this
.
queryWarehouseName
=
warehouseName
...
@@ -770,7 +770,7 @@ export default {
...
@@ -770,7 +770,7 @@ export default {
}
else
{
}
else
{
this
.
form
.
warehouseId
=
warehouseId
this
.
form
.
warehouseId
=
warehouseId
this
.
form
.
warehouseName
=
warehouseName
this
.
form
.
warehouseName
=
warehouseName
if
(
this
.
currentDetailItem
)
{
if
(
this
.
currentDetailItem
)
{
this
.
currentDetailItem
.
warehouseId
=
warehouseId
this
.
currentDetailItem
.
warehouseId
=
warehouseId
this
.
currentDetailItem
.
warehouseName
=
warehouseName
this
.
currentDetailItem
.
warehouseName
=
warehouseName
...
@@ -778,14 +778,14 @@ export default {
...
@@ -778,14 +778,14 @@ export default {
}
}
this
.
warehouseSelectorVisible
=
false
this
.
warehouseSelectorVisible
=
false
},
},
// 打开仓库选择器
// 打开仓库选择器
openWarehouseSelector
(
target
=
'form'
)
{
openWarehouseSelector
(
target
=
'form'
)
{
console
.
log
(
'【打开仓库选择器】目标:'
,
target
)
console
.
log
(
'【打开仓库选择器】目标:'
,
target
)
this
.
warehouseSelectTarget
=
target
this
.
warehouseSelectTarget
=
target
this
.
warehouseSelectorVisible
=
true
this
.
warehouseSelectorVisible
=
true
},
},
// 获取仓库列表
// 获取仓库列表
getWarehouseList
()
{
getWarehouseList
()
{
console
.
log
(
'【获取仓库列表】开始请求仓库数据'
)
console
.
log
(
'【获取仓库列表】开始请求仓库数据'
)
...
@@ -800,19 +800,19 @@ export default {
...
@@ -800,19 +800,19 @@ export default {
this
.
loadingWarehouse
=
false
this
.
loadingWarehouse
=
false
})
})
},
},
// 根据仓库ID获取仓库名称
// 根据仓库ID获取仓库名称
getWarehouseNameById
(
warehouseId
)
{
getWarehouseNameById
(
warehouseId
)
{
console
.
log
(
'【根据仓库ID获取名称】仓库ID:'
,
warehouseId
)
console
.
log
(
'【根据仓库ID获取名称】仓库ID:'
,
warehouseId
)
if
(
!
warehouseId
)
return
'-'
if
(
!
warehouseId
)
return
'-'
const
warehouse
=
this
.
warehouseList
.
find
(
item
=>
const
warehouse
=
this
.
warehouseList
.
find
(
item
=>
item
.
warehousesId
===
warehouseId
||
item
.
warehouseId
===
warehouseId
||
item
.
id
===
warehouseId
item
.
warehousesId
===
warehouseId
||
item
.
warehouseId
===
warehouseId
||
item
.
id
===
warehouseId
)
)
const
warehouseName
=
warehouse
?
(
warehouse
.
warehousesName
||
warehouse
.
name
||
warehouse
.
warehouseName
||
'-'
)
:
'-'
const
warehouseName
=
warehouse
?
(
warehouse
.
warehousesName
||
warehouse
.
name
||
warehouse
.
warehouseName
||
'-'
)
:
'-'
console
.
log
(
'【根据仓库ID获取名称】匹配到的仓库名称:'
,
warehouseName
)
console
.
log
(
'【根据仓库ID获取名称】匹配到的仓库名称:'
,
warehouseName
)
return
warehouseName
return
warehouseName
},
},
// 初始化物料编码-名称映射表
// 初始化物料编码-名称映射表
async
initMaterialCodeToNameMap
()
{
async
initMaterialCodeToNameMap
()
{
console
.
log
(
'【初始化物料映射表】开始加载物料数据'
)
console
.
log
(
'【初始化物料映射表】开始加载物料数据'
)
...
@@ -822,17 +822,17 @@ export default {
...
@@ -822,17 +822,17 @@ export default {
const
pageSize
=
1000
const
pageSize
=
1000
let
hasMore
=
true
let
hasMore
=
true
this
.
materialCodeToNameMap
=
{}
this
.
materialCodeToNameMap
=
{}
while
(
hasMore
)
{
while
(
hasMore
)
{
console
.
log
(
`【初始化物料映射表】请求第
${
pageNum
}
页物料数据,每页
${
pageSize
}
条`
)
console
.
log
(
`【初始化物料映射表】请求第
${
pageNum
}
页物料数据,每页
${
pageSize
}
条`
)
const
response
=
await
listMaterials
({
const
response
=
await
listMaterials
({
pageNum
,
pageNum
,
pageSize
,
pageSize
,
isUsed
:
1
,
isUsed
:
1
,
materialCode
:
null
,
materialCode
:
null
,
materialName
:
null
materialName
:
null
})
})
if
(
response
.
rows
&&
response
.
rows
.
length
)
{
if
(
response
.
rows
&&
response
.
rows
.
length
)
{
console
.
log
(
`【初始化物料映射表】第
${
pageNum
}
页返回
${
response
.
rows
.
length
}
条物料数据`
)
console
.
log
(
`【初始化物料映射表】第
${
pageNum
}
页返回
${
response
.
rows
.
length
}
条物料数据`
)
response
.
rows
.
forEach
(
item
=>
{
response
.
rows
.
forEach
(
item
=>
{
...
@@ -886,7 +886,7 @@ export default {
...
@@ -886,7 +886,7 @@ export default {
this
.
loading
=
false
this
.
loading
=
false
})
})
},
},
// 查询事件
// 查询事件
handleQuery
()
{
handleQuery
()
{
console
.
log
(
'【查询事件】执行查询操作'
)
console
.
log
(
'【查询事件】执行查询操作'
)
...
@@ -940,13 +940,13 @@ export default {
...
@@ -940,13 +940,13 @@ export default {
this
.
$modal
.
msgWarning
(
'请选择要修改的库位!'
)
this
.
$modal
.
msgWarning
(
'请选择要修改的库位!'
)
return
return
}
}
try
{
try
{
console
.
log
(
'【修改库位】请求库位详情,ID:'
,
id
)
console
.
log
(
'【修改库位】请求库位详情,ID:'
,
id
)
const
response
=
await
getLocations
(
id
)
const
response
=
await
getLocations
(
id
)
console
.
log
(
'【修改库位】后端返回库位详情:'
,
response
)
console
.
log
(
'【修改库位】后端返回库位详情:'
,
response
)
const
rowData
=
response
.
data
const
rowData
=
response
.
data
// 映射后端字段到前端
// 映射后端字段到前端
const
formData
=
{
const
formData
=
{
...
rowData
,
...
rowData
,
...
@@ -954,7 +954,7 @@ export default {
...
@@ -954,7 +954,7 @@ export default {
warehousesId
:
undefined
warehousesId
:
undefined
}
}
this
.
form
=
JSON
.
parse
(
JSON
.
stringify
(
formData
))
this
.
form
=
JSON
.
parse
(
JSON
.
stringify
(
formData
))
// 设置仓库名称
// 设置仓库名称
if
(
this
.
form
.
warehouseId
)
{
if
(
this
.
form
.
warehouseId
)
{
this
.
form
.
warehouseName
=
this
.
getWarehouseNameById
(
this
.
form
.
warehouseId
)
this
.
form
.
warehouseName
=
this
.
getWarehouseNameById
(
this
.
form
.
warehouseId
)
...
@@ -965,14 +965,14 @@ export default {
...
@@ -965,14 +965,14 @@ export default {
// 处理物料编码和名称(支持数组或字符串格式)
// 处理物料编码和名称(支持数组或字符串格式)
let
materialCodes
=
[]
let
materialCodes
=
[]
let
materialNames
=
[]
let
materialNames
=
[]
// 优先从allowedCategoryIds数组读取(原materialIds)
// 优先从allowedCategoryIds数组读取(原materialIds)
if
(
Array
.
isArray
(
rowData
.
allowedCategoryIds
)
&&
rowData
.
allowedCategoryIds
.
length
)
{
if
(
Array
.
isArray
(
rowData
.
allowedCategoryIds
)
&&
rowData
.
allowedCategoryIds
.
length
)
{
materialCodes
=
rowData
.
allowedCategoryIds
materialCodes
=
rowData
.
allowedCategoryIds
.
filter
(
code
=>
code
&&
code
.
trim
())
.
filter
(
code
=>
code
&&
code
.
trim
())
.
map
(
code
=>
code
.
trim
().
toUpperCase
())
.
map
(
code
=>
code
.
trim
().
toUpperCase
())
.
filter
((
code
,
index
,
self
)
=>
self
.
indexOf
(
code
)
===
index
)
.
filter
((
code
,
index
,
self
)
=>
self
.
indexOf
(
code
)
===
index
)
}
}
// 兼容字符串格式
// 兼容字符串格式
else
if
(
rowData
.
allowedCategoryIds
)
{
else
if
(
rowData
.
allowedCategoryIds
)
{
materialCodes
=
rowData
.
allowedCategoryIds
.
split
(
','
)
materialCodes
=
rowData
.
allowedCategoryIds
.
split
(
','
)
...
@@ -986,7 +986,7 @@ export default {
...
@@ -986,7 +986,7 @@ export default {
materialNames
=
rowData
.
allowedCategoryNames
materialNames
=
rowData
.
allowedCategoryNames
.
filter
(
name
=>
name
&&
name
.
trim
())
.
filter
(
name
=>
name
&&
name
.
trim
())
.
filter
((
name
,
index
,
self
)
=>
self
.
indexOf
(
name
)
===
index
)
.
filter
((
name
,
index
,
self
)
=>
self
.
indexOf
(
name
)
===
index
)
}
}
else
if
(
rowData
.
allowedCategoryNames
)
{
else
if
(
rowData
.
allowedCategoryNames
)
{
materialNames
=
rowData
.
allowedCategoryNames
.
split
(
','
)
materialNames
=
rowData
.
allowedCategoryNames
.
split
(
','
)
.
filter
(
name
=>
name
&&
name
.
trim
())
.
filter
(
name
=>
name
&&
name
.
trim
())
...
@@ -1017,7 +1017,7 @@ export default {
...
@@ -1017,7 +1017,7 @@ export default {
allowedCategoryIds
:
this
.
form
.
allowedCategoryIds
,
allowedCategoryIds
:
this
.
form
.
allowedCategoryIds
,
allowedCategoryNames
:
this
.
form
.
allowedCategoryNames
allowedCategoryNames
:
this
.
form
.
allowedCategoryNames
})
})
this
.
open
=
true
this
.
open
=
true
this
.
title
=
"修改库位"
this
.
title
=
"修改库位"
}
catch
(
error
)
{
}
catch
(
error
)
{
...
@@ -1045,7 +1045,7 @@ export default {
...
@@ -1045,7 +1045,7 @@ export default {
this
.
form
.
allowedCategoryIds
=
formatField
(
this
.
form
.
allowedCategoryIds
)
this
.
form
.
allowedCategoryIds
=
formatField
(
this
.
form
.
allowedCategoryIds
)
this
.
form
.
allowedCategoryNames
=
formatField
(
this
.
form
.
allowedCategoryNames
)
this
.
form
.
allowedCategoryNames
=
formatField
(
this
.
form
.
allowedCategoryNames
)
// 转换表单数据
// 转换表单数据
const
submitData
=
{
const
submitData
=
{
...
this
.
form
,
...
this
.
form
,
...
@@ -1053,7 +1053,7 @@ export default {
...
@@ -1053,7 +1053,7 @@ export default {
warehouseId
:
undefined
,
warehouseId
:
undefined
,
warehouseName
:
undefined
warehouseName
:
undefined
}
}
console
.
log
(
'【提交表单】最终提交数据:'
,
submitData
)
console
.
log
(
'【提交表单】最终提交数据:'
,
submitData
)
const
request
=
this
.
form
.
id
!=
null
?
updateLocations
(
submitData
)
:
addLocations
(
submitData
)
const
request
=
this
.
form
.
id
!=
null
?
updateLocations
(
submitData
)
:
addLocations
(
submitData
)
request
.
then
(
response
=>
{
request
.
then
(
response
=>
{
...
@@ -1079,7 +1079,7 @@ export default {
...
@@ -1079,7 +1079,7 @@ export default {
this
.
$modal
.
msgWarning
(
'请选择要删除的库位!'
)
this
.
$modal
.
msgWarning
(
'请选择要删除的库位!'
)
return
return
}
}
console
.
log
(
'【删除库位】待删除ID:'
,
ids
)
console
.
log
(
'【删除库位】待删除ID:'
,
ids
)
this
.
$modal
.
confirm
(
this
.
$modal
.
confirm
(
row
?.
id
?
`是否确认删除库位编号为"
${
row
.
locationCode
}
"的数据项?`
:
`是否确认删除选中的
${
ids
.
length
}
条库位数据项?`
row
?.
id
?
`是否确认删除库位编号为"
${
row
.
locationCode
}
"的数据项?`
:
`是否确认删除选中的
${
ids
.
length
}
条库位数据项?`
...
@@ -1106,34 +1106,34 @@ export default {
...
@@ -1106,34 +1106,34 @@ export default {
console
.
log
(
'【导出库位】最终导出参数:'
,
exportParams
)
console
.
log
(
'【导出库位】最终导出参数:'
,
exportParams
)
this
.
download
(
'inventory/locations/export'
,
exportParams
,
`locations_
${
new
Date
().
getTime
()}
.xlsx`
)
this
.
download
(
'inventory/locations/export'
,
exportParams
,
`locations_
${
new
Date
().
getTime
()}
.xlsx`
)
},
},
// 物料选择变化
// 物料选择变化
handleMaterialSelectionChange
(
selectedData
)
{
handleMaterialSelectionChange
(
selectedData
)
{
console
.
log
(
'【物料选择变化】接收到的选择数据:'
,
selectedData
)
console
.
log
(
'【物料选择变化】接收到的选择数据:'
,
selectedData
)
// 修复:从selectedData中取materialIds(而非materialCodes)
// 修复:从selectedData中取materialIds(而非materialCodes)
const
materialCodes
=
(
selectedData
.
materialIds
||
[])
const
materialCodes
=
(
selectedData
.
materialIds
||
[])
.
filter
(
code
=>
code
&&
code
.
trim
())
.
filter
(
code
=>
code
&&
code
.
trim
())
.
map
(
code
=>
code
.
trim
().
toUpperCase
())
.
map
(
code
=>
code
.
trim
().
toUpperCase
())
.
filter
((
code
,
index
,
self
)
=>
self
.
indexOf
(
code
)
===
index
)
.
filter
((
code
,
index
,
self
)
=>
self
.
indexOf
(
code
)
===
index
)
// 物料名称取selectedData.names
// 物料名称取selectedData.names
const
names
=
(
selectedData
.
names
||
[])
const
names
=
(
selectedData
.
names
||
[])
.
filter
(
name
=>
name
&&
name
.
trim
())
.
filter
(
name
=>
name
&&
name
.
trim
())
.
filter
((
name
,
index
,
self
)
=>
self
.
indexOf
(
name
)
===
index
)
.
filter
((
name
,
index
,
self
)
=>
self
.
indexOf
(
name
)
===
index
)
// 分类ID取selectedData.categoryIds(现在存储的是物料编码)
// 分类ID取selectedData.categoryIds(现在存储的是物料编码)
const
categoryIds
=
materialCodes
const
categoryIds
=
materialCodes
this
.
tempSelectedMaterials
=
{
this
.
tempSelectedMaterials
=
{
materialCodes
,
materialCodes
,
names
,
names
,
categoryIds
categoryIds
}
}
console
.
log
(
'【物料选择变化】处理后的临时选择数据:'
,
this
.
tempSelectedMaterials
)
console
.
log
(
'【物料选择变化】处理后的临时选择数据:'
,
this
.
tempSelectedMaterials
)
},
},
// 取消物料选择
// 取消物料选择
handleMaterialSelectionCancel
()
{
handleMaterialSelectionCancel
()
{
console
.
log
(
'【取消物料选择】执行取消操作,恢复原有选择状态'
)
console
.
log
(
'【取消物料选择】执行取消操作,恢复原有选择状态'
)
...
@@ -1146,11 +1146,11 @@ export default {
...
@@ -1146,11 +1146,11 @@ export default {
}
}
console
.
log
(
'【取消物料选择】恢复后的临时选择数据:'
,
this
.
tempSelectedMaterials
)
console
.
log
(
'【取消物料选择】恢复后的临时选择数据:'
,
this
.
tempSelectedMaterials
)
},
},
// 确认物料选择
// 确认物料选择
confirmMaterialSelection
()
{
confirmMaterialSelection
()
{
console
.
log
(
'【确认物料选择】当前临时选择数据:'
,
this
.
tempSelectedMaterials
)
console
.
log
(
'【确认物料选择】当前临时选择数据:'
,
this
.
tempSelectedMaterials
)
// 修复:判断tempSelectedMaterials.materialCodes是否有值
// 修复:判断tempSelectedMaterials.materialCodes是否有值
if
(
!
this
.
tempSelectedMaterials
.
materialCodes
.
length
)
{
if
(
!
this
.
tempSelectedMaterials
.
materialCodes
.
length
)
{
console
.
warn
(
'【确认物料选择】未选择任何物料,提示用户'
)
console
.
warn
(
'【确认物料选择】未选择任何物料,提示用户'
)
...
@@ -1161,22 +1161,22 @@ export default {
...
@@ -1161,22 +1161,22 @@ export default {
// 更新表单数据(确保去重和过滤)
// 更新表单数据(确保去重和过滤)
this
.
form
.
allowedCategoryIds
=
this
.
tempSelectedMaterials
.
materialCodes
.
join
(
','
)
this
.
form
.
allowedCategoryIds
=
this
.
tempSelectedMaterials
.
materialCodes
.
join
(
','
)
this
.
form
.
allowedCategoryNames
=
this
.
tempSelectedMaterials
.
names
.
join
(
','
)
this
.
form
.
allowedCategoryNames
=
this
.
tempSelectedMaterials
.
names
.
join
(
','
)
console
.
log
(
'【确认物料选择】更新后的表单物料数据:'
,
{
console
.
log
(
'【确认物料选择】更新后的表单物料数据:'
,
{
allowedCategoryIds
:
this
.
form
.
allowedCategoryIds
,
allowedCategoryIds
:
this
.
form
.
allowedCategoryIds
,
allowedCategoryNames
:
this
.
form
.
allowedCategoryNames
allowedCategoryNames
:
this
.
form
.
allowedCategoryNames
})
})
this
.
showMaterialSelect
=
false
this
.
showMaterialSelect
=
false
this
.
$modal
.
msgSuccess
(
`成功选择
${
this
.
tempSelectedMaterials
.
names
.
length
}
个物料`
)
this
.
$modal
.
msgSuccess
(
`成功选择
${
this
.
tempSelectedMaterials
.
names
.
length
}
个物料`
)
},
},
// 导入库位
// 导入库位
handleImport
()
{
handleImport
()
{
console
.
log
(
'【导入库位】打开导入组件'
)
console
.
log
(
'【导入库位】打开导入组件'
)
this
.
$refs
.
import
.
show
()
this
.
$refs
.
import
.
show
()
},
},
// 重置表单
// 重置表单
reset
()
{
reset
()
{
console
.
log
(
'【重置表单】执行表单重置'
)
console
.
log
(
'【重置表单】执行表单重置'
)
...
@@ -1223,7 +1223,7 @@ export default {
...
@@ -1223,7 +1223,7 @@ export default {
}
}
console
.
log
(
'【重置表单】重置完成,表单数据:'
,
this
.
form
)
console
.
log
(
'【重置表单】重置完成,表单数据:'
,
this
.
form
)
},
},
// 取消操作
// 取消操作
cancel
()
{
cancel
()
{
console
.
log
(
'【取消操作】关闭弹窗并重置表单'
)
console
.
log
(
'【取消操作】关闭弹窗并重置表单'
)
...
@@ -1277,4 +1277,4 @@ export default {
...
@@ -1277,4 +1277,4 @@ export default {
max-width
:
300px
;
max-width
:
300px
;
white-space
:
normal
;
white-space
:
normal
;
}
}
</
style
>
</
style
>
\ No newline at end of file
ruoyi-admin-vue/src/views/inventory/orders/OutboundOrderFormWithItems.vue
View file @
f9be7e47
...
@@ -11,7 +11,7 @@
...
@@ -11,7 +11,7 @@
<el-form
ref=
"detailForm"
:model=
"form"
label-width=
"100px"
:rules=
"rules"
>
<el-form
ref=
"detailForm"
:model=
"form"
label-width=
"100px"
:rules=
"rules"
>
<el-row
:gutter=
"20"
>
<el-row
:gutter=
"20"
>
<el-col
:span=
"12"
>
<el-col
:span=
"12"
>
<el-form-item
label=
"货物
ID
"
prop=
"materialId"
>
<el-form-item
label=
"货物"
prop=
"materialId"
>
<el-input
<el-input
v-model=
"form.materialName"
v-model=
"form.materialName"
placeholder=
"请选择物料"
placeholder=
"请选择物料"
...
@@ -54,7 +54,7 @@
...
@@ -54,7 +54,7 @@
:multiple=
"false"
:multiple=
"false"
/>
/>
</div>
</div>
</el-dialog>
</el-dialog>
<!-- 库存信息列表 -->
<!-- 库存信息列表 -->
...
@@ -76,7 +76,7 @@
...
@@ -76,7 +76,7 @@
:row-key=
"item => item.inventoryId"
:row-key=
"item => item.inventoryId"
>
>
<el-table-column
prop=
"materialName"
label=
"物料名称"
width=
"180"
/>
<el-table-column
prop=
"materialName"
label=
"物料名称"
width=
"180"
/>
<el-table-column
prop=
"batchId"
label=
"批次
ID
"
width=
"150"
/>
<el-table-column
prop=
"batchId"
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
<el-table-column
...
@@ -189,7 +189,7 @@
...
@@ -189,7 +189,7 @@
</el-form-item>
</el-form-item>
</el-col>
</el-col>
</el-row>
</el-row>
<el-row
:gutter=
"20"
style=
"margin-top: 10px;"
>
<el-row
:gutter=
"20"
style=
"margin-top: 10px;"
>
<el-col
:span=
"16"
>
<el-col
:span=
"16"
>
<el-form-item
label=
"备注"
prop=
"remark"
>
<el-form-item
label=
"备注"
prop=
"remark"
>
...
@@ -221,10 +221,10 @@
...
@@ -221,10 +221,10 @@
:row-key=
"item => item.inventoryId"
:row-key=
"item => item.inventoryId"
>
>
<el-table-column
prop=
"materialName"
label=
"物料名称"
width=
"180"
/>
<el-table-column
prop=
"materialName"
label=
"物料名称"
width=
"180"
/>
<el-table-column
prop=
"batchId"
label=
"批次
ID
"
width=
"150"
/>
<el-table-column
prop=
"batchId"
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=
"plannedQuantity"
label=
"计划数量"
width=
"100"
/>
<el-table-column
prop=
"plannedQuantity"
label=
"计划数量"
width=
"100"
/>
<el-table-column
prop=
"actualQuantity"
label=
"实际数量"
width=
"100"
fixed=
"right"
/>
<el-table-column
prop=
"actualQuantity"
label=
"实际数量"
width=
"100"
fixed=
"right"
/>
<el-table-column
prop=
"unitPrice"
label=
"单价"
width=
"100"
/>
<el-table-column
prop=
"unitPrice"
label=
"单价"
width=
"100"
/>
...
@@ -534,18 +534,18 @@ export default {
...
@@ -534,18 +534,18 @@ export default {
this
.
initDetails
.
forEach
(
detail
=>
{
this
.
initDetails
.
forEach
(
detail
=>
{
let
targetRow
=
null
;
let
targetRow
=
null
;
targetRow
=
this
.
inventoryList
.
find
(
row
=>
row
.
inventoryId
===
detail
.
inventoryId
);
targetRow
=
this
.
inventoryList
.
find
(
row
=>
row
.
inventoryId
===
detail
.
inventoryId
);
if
(
!
targetRow
)
{
if
(
!
targetRow
)
{
targetRow
=
this
.
inventoryList
.
find
(
row
=>
targetRow
=
this
.
inventoryList
.
find
(
row
=>
row
.
batchId
===
detail
.
batchId
&&
row
.
batchId
===
detail
.
batchId
&&
row
.
warehousesId
===
detail
.
warehousesId
&&
row
.
warehousesId
===
detail
.
warehousesId
&&
row
.
locationId
===
detail
.
locationId
row
.
locationId
===
detail
.
locationId
);
);
}
}
if
(
!
targetRow
)
{
if
(
!
targetRow
)
{
targetRow
=
this
.
inventoryList
.
find
(
row
=>
targetRow
=
this
.
inventoryList
.
find
(
row
=>
row
.
batchId
===
detail
.
batchId
&&
row
.
batchId
===
detail
.
batchId
&&
row
.
materialId
===
detail
.
materialId
row
.
materialId
===
detail
.
materialId
);
);
}
}
...
@@ -691,7 +691,7 @@ syncDetails(strict = true) {
...
@@ -691,7 +691,7 @@ syncDetails(strict = true) {
handleSubmit
()
{
handleSubmit
()
{
// 1. 校验物料ID
// 1. 校验物料ID
if
(
!
this
.
form
.
materialId
?.
trim
())
{
if
(
!
this
.
form
.
materialId
?.
trim
())
{
this
.
$message
.
error
(
'请先选择物料
ID
'
);
this
.
$message
.
error
(
'请先选择物料'
);
return
;
return
;
}
}
...
@@ -732,9 +732,9 @@ handleSubmit() {
...
@@ -732,9 +732,9 @@ handleSubmit() {
outboundOrderId
:
this
.
form
.
outboundOrderId
||
detail
.
outboundOrderId
,
outboundOrderId
:
this
.
form
.
outboundOrderId
||
detail
.
outboundOrderId
,
materialId
:
this
.
form
.
materialId
||
detail
.
materialId
materialId
:
this
.
form
.
materialId
||
detail
.
materialId
}));
}));
console
.
log
(
'提交的明细数据:'
,
submitDetails
);
console
.
log
(
'提交的明细数据:'
,
submitDetails
);
this
.
$emit
(
'submit'
,
submitDetails
);
this
.
$emit
(
'submit'
,
submitDetails
);
this
.
$emit
(
'update:open'
,
false
);
this
.
$emit
(
'update:open'
,
false
);
});
});
...
@@ -757,7 +757,7 @@ handleSubmit() {
...
@@ -757,7 +757,7 @@ handleSubmit() {
}
}
this
.
syncDetails
(
this
.
initDetails
.
length
===
0
);
this
.
syncDetails
(
this
.
initDetails
.
length
===
0
);
},
},
handleClose
()
{
handleClose
()
{
this
.
closeLoading
();
this
.
closeLoading
();
this
.
$nextTick
(()
=>
{
this
.
$nextTick
(()
=>
{
...
@@ -780,9 +780,9 @@ handleSubmit() {
...
@@ -780,9 +780,9 @@ handleSubmit() {
console
.
log
(
"【物料选择事件触发】选中数据:"
,
selectedData
);
console
.
log
(
"【物料选择事件触发】选中数据:"
,
selectedData
);
// 兼容数组格式(multiple=false时可能返回对象,需转为数组)
// 兼容数组格式(multiple=false时可能返回对象,需转为数组)
const
selectList
=
Array
.
isArray
(
selectedData
)
?
selectedData
:
selectedData
?
[
selectedData
]
:
[];
const
selectList
=
Array
.
isArray
(
selectedData
)
?
selectedData
:
selectedData
?
[
selectedData
]
:
[];
if
(
selectList
.
length
>
0
)
{
if
(
selectList
.
length
>
0
)
{
this
.
selectedMaterialInfo
=
selectList
[
0
];
this
.
selectedMaterialInfo
=
selectList
[
0
];
// 关键:兼容常见的物料ID字段名(id/materialId/uuid)
// 关键:兼容常见的物料ID字段名(id/materialId/uuid)
this
.
selectedMaterialId
=
this
.
selectedMaterialInfo
.
id
||
this
.
selectedMaterialInfo
.
materialId
||
this
.
selectedMaterialInfo
.
uuid
||
''
;
this
.
selectedMaterialId
=
this
.
selectedMaterialInfo
.
id
||
this
.
selectedMaterialInfo
.
materialId
||
this
.
selectedMaterialInfo
.
uuid
||
''
;
// 兼容常见的物料名称字段名(materialName/name)
// 兼容常见的物料名称字段名(materialName/name)
...
@@ -892,4 +892,4 @@ handleSubmit() {
...
@@ -892,4 +892,4 @@ handleSubmit() {
/
deep
/
.el-button.is-disabled
{
/
deep
/
.el-button.is-disabled
{
cursor
:
not-allowed
;
cursor
:
not-allowed
;
}
}
</
style
>
</
style
>
\ No newline at end of file
ruoyi-admin-vue/src/views/inventory/orders/index.vue
View file @
f9be7e47
...
@@ -51,10 +51,10 @@
...
@@ -51,10 +51,10 @@
<!-- 页面容器 -->
<!-- 页面容器 -->
<div
class=
"page-container"
>
<div
class=
"page-container"
>
<!-- 搜索区域 -->
<!-- 搜索区域 -->
<page-wrapper-search
<page-wrapper-search
:model=
"queryParams"
:model=
"queryParams"
ref=
"queryForm"
ref=
"queryForm"
size=
"small"
size=
"small"
@
search=
"handleQuery"
@
search=
"handleQuery"
@
reset=
"resetQuery"
@
reset=
"resetQuery"
>
>
...
@@ -84,9 +84,9 @@
...
@@ -84,9 +84,9 @@
</el-form-item>
</el-form-item>
<!-- 新增:订单类型查询项 -->
<!-- 新增:订单类型查询项 -->
<el-form-item
label=
"订单类型"
prop=
"orderType"
>
<el-form-item
label=
"订单类型"
prop=
"orderType"
>
<el-select
<el-select
v-model=
"queryParams.orderType"
v-model=
"queryParams.orderType"
placeholder=
"请选择订单类型"
placeholder=
"请选择订单类型"
clearable
clearable
style=
"width: 100%"
style=
"width: 100%"
>
>
...
@@ -98,10 +98,10 @@
...
@@ -98,10 +98,10 @@
/>
/>
</el-select>
</el-select>
</el-form-item>
</el-form-item>
<el-form-item
label=
"批次
ID
"
prop=
"batchCode"
>
<el-form-item
label=
"批次"
prop=
"batchCode"
>
<el-input
<el-input
v-model=
"queryParams.batchCode"
v-model=
"queryParams.batchCode"
placeholder=
"请输入批次
ID
"
placeholder=
"请输入批次"
clearable
clearable
@
keyup
.
enter
.
native=
"handleQuery"
@
keyup
.
enter
.
native=
"handleQuery"
/>
/>
...
@@ -136,9 +136,9 @@
...
@@ -136,9 +136,9 @@
/>
/>
</el-form-item>
</el-form-item>
<el-form-item
label=
"订单状态"
prop=
"orderStatus"
>
<el-form-item
label=
"订单状态"
prop=
"orderStatus"
>
<el-select
<el-select
v-model=
"queryParams.orderStatus"
v-model=
"queryParams.orderStatus"
placeholder=
"请选择订单状态"
placeholder=
"请选择订单状态"
clearable
clearable
style=
"width: 100%"
style=
"width: 100%"
>
>
...
@@ -205,7 +205,7 @@
...
@@ -205,7 +205,7 @@
<span
v-else
>
-
</span>
<span
v-else
>
-
</span>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
<el-table-column
label=
"批次
ID
"
align=
"center"
prop=
"batchCode"
width=
"120"
/>
<el-table-column
label=
"批次"
align=
"center"
prop=
"batchCode"
width=
"120"
/>
<el-table-column
label=
"仓库"
align=
"center"
prop=
"warehouseName"
width=
"120"
>
<el-table-column
label=
"仓库"
align=
"center"
prop=
"warehouseName"
width=
"120"
>
<
template
slot-scope=
"scope"
>
<
template
slot-scope=
"scope"
>
{{
scope
.
row
.
warehouseName
||
'-'
}}
{{
scope
.
row
.
warehouseName
||
'-'
}}
...
@@ -255,7 +255,7 @@
...
@@ -255,7 +255,7 @@
v
-
if
=
"scope.row.orderStatus===1"
v
-
if
=
"scope.row.orderStatus===1"
@
click
=
"handleShip(scope.row)"
@
click
=
"handleShip(scope.row)"
v
-
hasPermi
=
"['inventory:orders:edit']"
v
-
hasPermi
=
"['inventory:orders:edit']"
:
loading
=
"shipLoading[scope.row.id]"
:
loading
=
"shipLoading[scope.row.id]"
>
出货
<
/el-button
>
>
出货
<
/el-button
>
<
el
-
button
<
el
-
button
size
=
"mini"
size
=
"mini"
...
@@ -299,10 +299,10 @@
...
@@ -299,10 +299,10 @@
<
el
-
col
:
span
=
"12"
>
<
el
-
col
:
span
=
"12"
>
<
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.inbound_outbound_type"
v
-
for
=
"item in dict.type.inbound_outbound_type"
:
key
=
"item.value"
:
key
=
"item.value"
:
label
=
"item.label"
:
label
=
"item.label"
:
value
=
"item.value"
:
value
=
"item.value"
>
>
<
span
style
=
"margin-left: 8px;"
>
{{
item
.
label
}}
<
/span
>
<
span
style
=
"margin-left: 8px;"
>
{{
item
.
label
}}
<
/span
>
...
@@ -336,8 +336,8 @@
...
@@ -336,8 +336,8 @@
<
/el-row
>
<
/el-row
>
<
el
-
row
:
gutter
=
"20"
>
<
el
-
row
:
gutter
=
"20"
>
<
el
-
col
:
span
=
"12"
>
<
el
-
col
:
span
=
"12"
>
<
el
-
form
-
item
label
=
"批次
ID
"
prop
=
"batchCode"
>
<
el
-
form
-
item
label
=
"批次"
prop
=
"batchCode"
>
<
el
-
input
v
-
model
=
"form.batchCode"
placeholder
=
"请输入批次
ID
"
:
disabled
=
"isViewDetail || formDisabled.batchCode"
/>
<
el
-
input
v
-
model
=
"form.batchCode"
placeholder
=
"请输入批次"
:
disabled
=
"isViewDetail || formDisabled.batchCode"
/>
<
/el-form-item
>
<
/el-form-item
>
<
/el-col
>
<
/el-col
>
<
el
-
col
:
span
=
"12"
>
<
el
-
col
:
span
=
"12"
>
...
@@ -380,10 +380,10 @@
...
@@ -380,10 +380,10 @@
<
el
-
col
:
span
=
"12"
>
<
el
-
col
:
span
=
"12"
>
<
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.order_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"
>
>
<
span
style
=
"margin-left: 8px;"
>
{{
item
.
label
}}
<
/span
>
<
span
style
=
"margin-left: 8px;"
>
{{
item
.
label
}}
<
/span
>
...
@@ -391,8 +391,8 @@
...
@@ -391,8 +391,8 @@
<
/el-select
>
<
/el-select
>
<
/el-form-item
>
<
/el-form-item
>
<
/el-col
>
<
/el-col
>
<
/el-row
>
<
/el-row
>
<
el
-
row
:
gutter
=
"20"
>
<
el
-
row
:
gutter
=
"20"
>
<
el
-
col
:
span
=
"12"
>
<
el
-
col
:
span
=
"12"
>
...
@@ -457,7 +457,7 @@
...
@@ -457,7 +457,7 @@
<!--
<
el
-
table
-
column
label
=
"仓库编号"
prop
=
"warehouseId"
width
=
"150"
/>
-->
<!--
<
el
-
table
-
column
label
=
"仓库编号"
prop
=
"warehouseId"
width
=
"150"
/>
-->
<
el
-
table
-
column
label
=
"库位编号"
prop
=
"locationName"
width
=
"150"
/>
<
el
-
table
-
column
label
=
"库位编号"
prop
=
"locationName"
width
=
"150"
/>
<
el
-
table
-
column
label
=
"批次编号"
prop
=
"batchCode"
width
=
"150"
/>
<
el
-
table
-
column
label
=
"批次编号"
prop
=
"batchCode"
width
=
"150"
/>
<
el
-
table
-
column
label
=
"计划数量"
prop
=
"plannedQuantity"
width
=
"150"
/>
<
el
-
table
-
column
label
=
"计划数量"
prop
=
"plannedQuantity"
width
=
"150"
/>
<
el
-
table
-
column
label
=
"实际数量"
prop
=
"actualQuantity"
width
=
"150"
fixed
=
"right"
/>
<
el
-
table
-
column
label
=
"实际数量"
prop
=
"actualQuantity"
width
=
"150"
fixed
=
"right"
/>
<
el
-
table
-
column
label
=
"约数"
prop
=
"divisor"
width
=
"150"
><
/el-table-column
>
<
el
-
table
-
column
label
=
"约数"
prop
=
"divisor"
width
=
"150"
><
/el-table-column
>
...
@@ -683,7 +683,7 @@ export default {
...
@@ -683,7 +683,7 @@ export default {
this
.
getList
()
this
.
getList
()
}
)
}
)
this
.
handleShip
=
this
.
debounce
(
this
.
handleShip
,
500
)
this
.
handleShip
=
this
.
debounce
(
this
.
handleShip
,
500
)
}
,
}
,
methods
:
{
methods
:
{
debounce
(
fn
,
delay
=
300
)
{
debounce
(
fn
,
delay
=
300
)
{
...
@@ -718,7 +718,7 @@ export default {
...
@@ -718,7 +718,7 @@ export default {
}
else
{
}
else
{
this
.
form
.
warehouseId
=
warehouse
.
warehouseId
||
warehouse
.
id
this
.
form
.
warehouseId
=
warehouse
.
warehouseId
||
warehouse
.
id
this
.
form
.
warehouseName
=
warehouse
.
warehousesName
||
warehouse
.
name
this
.
form
.
warehouseName
=
warehouse
.
warehousesName
||
warehouse
.
name
// 更新明细中的默认仓库
// 更新明细中的默认仓库
if
(
this
.
currentDetailItem
)
{
if
(
this
.
currentDetailItem
)
{
this
.
currentDetailItem
.
warehouseId
=
warehouse
.
warehouseId
||
warehouse
.
id
this
.
currentDetailItem
.
warehouseId
=
warehouse
.
warehouseId
||
warehouse
.
id
...
@@ -823,7 +823,7 @@ export default {
...
@@ -823,7 +823,7 @@ export default {
try
{
try
{
// 设置当前订单出货loading
// 设置当前订单出货loading
this
.
$set
(
this
.
shipLoading
,
row
.
id
,
true
)
this
.
$set
(
this
.
shipLoading
,
row
.
id
,
true
)
// 原有业务逻辑
// 原有业务逻辑
console
.
log
(
"handleShip"
,
row
)
console
.
log
(
"handleShip"
,
row
)
await
ship
({
await
ship
({
...
@@ -980,7 +980,7 @@ export default {
...
@@ -980,7 +980,7 @@ export default {
const
materialId
=
this
.
currentMaterialId
||
detailList
[
0
]?.
materialId
;
const
materialId
=
this
.
currentMaterialId
||
detailList
[
0
]?.
materialId
;
if
(
!
materialId
)
{
if
(
!
materialId
)
{
this
.
$message
.
warning
(
"物料
ID
不能为空"
);
this
.
$message
.
warning
(
"物料不能为空"
);
return
;
return
;
}
}
...
@@ -1264,7 +1264,7 @@ export default {
...
@@ -1264,7 +1264,7 @@ export default {
updateUserCode
:
null
updateUserCode
:
null
}
}
}
}
this
.
queryOwnerName
=
''
this
.
queryOwnerName
=
''
this
.
queryWarehouseName
=
''
this
.
queryWarehouseName
=
''
this
.
handleQuery
()
this
.
handleQuery
()
...
@@ -1493,15 +1493,15 @@ export default {
...
@@ -1493,15 +1493,15 @@ export default {
// 修改点7:构造提交数据,适配新的字段映射规则
// 修改点7:构造提交数据,适配新的字段映射规则
const
submitData
=
{
const
submitData
=
{
...
this
.
form
,
...
this
.
form
,
outboundOrderId
:
this
.
form
.
id
,
outboundOrderId
:
this
.
form
.
id
,
orderId
:
this
.
form
.
orderId
,
orderId
:
this
.
form
.
orderId
,
orderType
:
this
.
form
.
orderType
,
// 新增:提交订单类型
orderType
:
this
.
form
.
orderType
,
// 新增:提交订单类型
outboundOrderItemsList
:
uniqueDetails
.
map
(
item
=>
{
outboundOrderItemsList
:
uniqueDetails
.
map
(
item
=>
{
const
{
index
,
materialUuids
,
warehouseName
,
locationName
,
...
rest
}
=
item
const
{
index
,
materialUuids
,
warehouseName
,
locationName
,
...
rest
}
=
item
return
{
return
{
...
rest
,
...
rest
,
orderId
:
null
,
orderId
:
null
,
outboundOrderId
:
this
.
form
.
id
||
null
,
outboundOrderId
:
this
.
form
.
id
||
null
,
materialName
:
item
.
materialName
||
''
,
// 【修改16】提交物料名称
materialName
:
item
.
materialName
||
''
,
// 【修改16】提交物料名称
inventoryId
:
rest
.
inventoryId
||
''
,
inventoryId
:
rest
.
inventoryId
||
''
,
materialId
:
rest
.
materialId
||
''
,
materialId
:
rest
.
materialId
||
''
,
...
@@ -1572,4 +1572,4 @@ export default {
...
@@ -1572,4 +1572,4 @@ export default {
}
}
}
}
}
}
<
/script>
<
/script
>
\ No newline at end of file
ruoyi-admin-vue/src/views/inventory/report_view/inbound_outbound_statistics.vue
View file @
f9be7e47
...
@@ -53,7 +53,6 @@
...
@@ -53,7 +53,6 @@
readonly
readonly
@
focus=
"openLocationSelector"
@
focus=
"openLocationSelector"
:suffix-icon=
"''"
:suffix-icon=
"''"
:disabled=
"!queryParams.warehouseId"
>
>
<
template
v-if=
"queryLocationName"
#
suffix
>
<
template
v-if=
"queryLocationName"
#
suffix
>
<i
<i
...
@@ -67,7 +66,7 @@
...
@@ -67,7 +66,7 @@
<el-form-item
label=
"物料"
prop=
"materialId"
>
<el-form-item
label=
"物料"
prop=
"materialId"
>
<el-input
<el-input
v-model=
"queryParams.materialId"
v-model=
"queryParams.materialId"
placeholder=
"请输入物料
ID
或编码"
placeholder=
"请输入物料或编码"
clearable
clearable
@
keyup
.
enter
.
native=
"handleQuery"
@
keyup
.
enter
.
native=
"handleQuery"
/>
/>
...
@@ -234,9 +233,9 @@ export default {
...
@@ -234,9 +233,9 @@ export default {
this
.
queryParams
.
warehouseId
=
warehouse
.
warehouseId
||
warehouse
.
id
this
.
queryParams
.
warehouseId
=
warehouse
.
warehouseId
||
warehouse
.
id
this
.
queryParams
.
warehousesCode
=
warehouse
.
warehousesCode
this
.
queryParams
.
warehousesCode
=
warehouse
.
warehousesCode
this
.
queryWarehouseName
=
warehouse
.
warehousesName
||
warehouse
.
warehousesCode
this
.
queryWarehouseName
=
warehouse
.
warehousesName
||
warehouse
.
warehousesCode
// 仓库选择后,清空库位信息
//
//
仓库选择后,清空库位信息
this
.
queryLocationName
=
null
//
this.queryLocationName = null
this
.
queryParams
.
locationId
=
null
//
this.queryParams.locationId = null
this
.
handleQuery
()
this
.
handleQuery
()
},
},
/** 清空仓库选择 */
/** 清空仓库选择 */
...
@@ -245,16 +244,16 @@ export default {
...
@@ -245,16 +244,16 @@ export default {
this
.
queryParams
.
warehouseId
=
null
this
.
queryParams
.
warehouseId
=
null
this
.
queryParams
.
warehousesCode
=
null
this
.
queryParams
.
warehousesCode
=
null
// 清空仓库时,同时清空库位
// 清空仓库时,同时清空库位
this
.
queryLocationName
=
null
//
this.queryLocationName = null
this
.
queryParams
.
locationId
=
null
//
this.queryParams.locationId = null
this
.
handleQuery
()
this
.
handleQuery
()
},
},
/** 打开库位选择器 */
/** 打开库位选择器 */
openLocationSelector
()
{
openLocationSelector
()
{
if
(
!
this
.
queryParams
.
warehouseId
)
{
//
if (!this.queryParams.warehouseId) {
this
.
$message
.
warning
(
"请先选择仓库"
)
//
this.$message.warning("请先选择仓库")
return
//
return
}
//
}
this
.
locationSelectorVisible
=
true
this
.
locationSelectorVisible
=
true
},
},
/** 库位选择回调 */
/** 库位选择回调 */
...
...
ruoyi-admin-vue/src/views/inventory/report_view/inventory_detail.vue
View file @
f9be7e47
...
@@ -50,7 +50,6 @@
...
@@ -50,7 +50,6 @@
readonly
readonly
@
focus=
"openLocationSelector"
@
focus=
"openLocationSelector"
:suffix-icon=
"''"
:suffix-icon=
"''"
:disabled=
"!queryParams.warehouseId"
>
>
<
template
v-if=
"queryLocationName"
#
suffix
>
<
template
v-if=
"queryLocationName"
#
suffix
>
<i
<i
...
@@ -419,16 +418,16 @@ export default {
...
@@ -419,16 +418,16 @@ export default {
this
.
queryParams
.
warehousesCode
=
warehouse
.
warehousesCode
this
.
queryParams
.
warehousesCode
=
warehouse
.
warehousesCode
this
.
queryWarehouseName
=
warehouse
.
warehousesName
||
warehouse
.
warehousesCode
this
.
queryWarehouseName
=
warehouse
.
warehousesName
||
warehouse
.
warehousesCode
// 仓库选择后,清空库位信息
// 仓库选择后,清空库位信息
this
.
queryLocationName
=
null
//
this.queryLocationName = null
this
.
queryParams
.
locationId
=
null
//
this.queryParams.locationId = null
this
.
handleQuery
()
this
.
handleQuery
()
},
},
/** 打开库位选择器 */
/** 打开库位选择器 */
openLocationSelector
()
{
openLocationSelector
()
{
if
(
!
this
.
queryParams
.
warehouseId
)
{
//
if (!this.queryParams.warehouseId) {
this
.
$message
.
warning
(
"请先选择仓库"
)
//
this.$message.warning("请先选择仓库")
return
//
return
}
//
}
this
.
locationSelectorVisible
=
true
this
.
locationSelectorVisible
=
true
},
},
/** 库位选择回调 */
/** 库位选择回调 */
...
@@ -444,8 +443,8 @@ export default {
...
@@ -444,8 +443,8 @@ export default {
this
.
queryParams
.
warehouseId
=
null
this
.
queryParams
.
warehouseId
=
null
this
.
queryParams
.
warehousesCode
=
null
this
.
queryParams
.
warehousesCode
=
null
// 清空仓库时,同时清空库位
// 清空仓库时,同时清空库位
this
.
queryLocationName
=
null
//
this.queryLocationName = null
this
.
queryParams
.
locationId
=
null
//
this.queryParams.locationId = null
this
.
handleQuery
()
this
.
handleQuery
()
},
},
/** 清空库位选择 */
/** 清空库位选择 */
...
@@ -512,12 +511,12 @@ export default {
...
@@ -512,12 +511,12 @@ export default {
// 根据当前行的物料ID、仓库、库位、货主等信息查询明细
// 根据当前行的物料ID、仓库、库位、货主等信息查询明细
const
params
=
{
const
params
=
{
materialId
:
row
.
materialId
,
materialId
:
row
.
materialId
,
warehousesId
:
row
.
warehousesId
,
warehousesId
:
this
.
queryParams
.
warehousesId
,
locationId
:
row
.
locationId
,
locationId
:
this
.
queryParams
.
locationId
,
ownerId
:
row
.
ownerId
,
ownerId
:
this
.
queryParams
.
ownerId
,
batchId
:
row
.
batchId
,
batchId
:
this
.
queryParams
.
batchId
,
inventoryType
:
row
.
inventoryType
,
inventoryType
:
this
.
queryParams
.
inventoryType
,
inventoryStatus
:
row
.
inventoryStatus
,
inventoryStatus
:
this
.
queryParams
.
inventoryStatus
,
pageNum
:
1
,
pageNum
:
1
,
pageSize
:
10000
// 设置一个很大的值,不分页
pageSize
:
10000
// 设置一个很大的值,不分页
}
}
...
...
ruoyi-admin-vue/src/views/inventory/return_op/items.vue
View file @
f9be7e47
...
@@ -57,7 +57,7 @@
...
@@ -57,7 +57,7 @@
<el-form-item
label=
"物料"
prop=
"materialId"
>
<el-form-item
label=
"物料"
prop=
"materialId"
>
<el-input
<el-input
v-model=
"queryParams.materialId"
v-model=
"queryParams.materialId"
placeholder=
"请输入物料
ID
或编码"
placeholder=
"请输入物料或编码"
clearable
clearable
@
keyup
.
enter
.
native=
"handleQuery"
@
keyup
.
enter
.
native=
"handleQuery"
/>
/>
...
@@ -118,7 +118,7 @@
...
@@ -118,7 +118,7 @@
<div
class=
"table-container"
>
<div
class=
"table-container"
>
<el-table
v-loading=
"loading"
:data=
"returnOrderItemList"
border
height=
"100%"
style=
"width: 100%"
>
<el-table
v-loading=
"loading"
:data=
"returnOrderItemList"
border
height=
"100%"
style=
"width: 100%"
>
<el-table-column
type=
"index"
label=
"序号"
width=
"60"
align=
"center"
fixed=
"left"
/>
<el-table-column
type=
"index"
label=
"序号"
width=
"60"
align=
"center"
fixed=
"left"
/>
<!-- <el-table-column label="物料
ID
" align="center" prop="materialId" width="150" /> -->
<!-- <el-table-column label="物料" align="center" prop="materialId" width="150" /> -->
<el-table-column
label=
"物料名称"
align=
"center"
prop=
"materialName"
min-width=
"150"
show-overflow-tooltip
/>
<el-table-column
label=
"物料名称"
align=
"center"
prop=
"materialName"
min-width=
"150"
show-overflow-tooltip
/>
<el-table-column
label=
"SAP物料号"
align=
"center"
prop=
"sapNo"
width=
"120"
/>
<el-table-column
label=
"SAP物料号"
align=
"center"
prop=
"sapNo"
width=
"120"
/>
<el-table-column
label=
"TS Code"
align=
"center"
prop=
"tsCode"
width=
"120"
/>
<el-table-column
label=
"TS Code"
align=
"center"
prop=
"tsCode"
width=
"120"
/>
...
...
ruoyi-admin-vue/src/views/inventory/stocktake_items/index.vue
View file @
f9be7e47
...
@@ -9,34 +9,34 @@
...
@@ -9,34 +9,34 @@
@
keyup
.
enter
.
native=
"handleQuery"
@
keyup
.
enter
.
native=
"handleQuery"
/>
/>
</el-form-item>
</el-form-item>
<el-form-item
label=
"货物
ID
字典,检索条件"
prop=
"materialId"
>
<el-form-item
label=
"货物 字典,检索条件"
prop=
"materialId"
>
<el-input
<el-input
v-model=
"queryParams.materialId"
v-model=
"queryParams.materialId"
placeholder=
"请输入货物
ID
字典,检索条件"
placeholder=
"请输入货物 字典,检索条件"
clearable
clearable
@
keyup
.
enter
.
native=
"handleQuery"
@
keyup
.
enter
.
native=
"handleQuery"
/>
/>
</el-form-item>
</el-form-item>
<el-form-item
label=
"批次
ID
检索条件"
prop=
"batchCode"
>
<el-form-item
label=
"批次 检索条件"
prop=
"batchCode"
>
<el-input
<el-input
v-model=
"queryParams.batchCode"
v-model=
"queryParams.batchCode"
placeholder=
"请输入批次
ID
检索条件"
placeholder=
"请输入批次 检索条件"
clearable
clearable
@
keyup
.
enter
.
native=
"handleQuery"
@
keyup
.
enter
.
native=
"handleQuery"
/>
/>
</el-form-item>
</el-form-item>
<el-form-item
label=
"仓库
ID
检索条件"
prop=
"warehouseId"
>
<el-form-item
label=
"仓库 检索条件"
prop=
"warehouseId"
>
<el-input
<el-input
v-model=
"queryParams.warehouseId"
v-model=
"queryParams.warehouseId"
placeholder=
"请输入仓库
ID
检索条件"
placeholder=
"请输入仓库 检索条件"
clearable
clearable
@
keyup
.
enter
.
native=
"handleQuery"
@
keyup
.
enter
.
native=
"handleQuery"
/>
/>
</el-form-item>
</el-form-item>
<el-form-item
label=
"库位
ID
检索条件"
prop=
"locationId"
>
<el-form-item
label=
"库位 检索条件"
prop=
"locationId"
>
<el-input
<el-input
v-model=
"queryParams.locationId"
v-model=
"queryParams.locationId"
placeholder=
"请输入库位
ID
检索条件"
placeholder=
"请输入库位 检索条件"
clearable
clearable
@
keyup
.
enter
.
native=
"handleQuery"
@
keyup
.
enter
.
native=
"handleQuery"
/>
/>
...
@@ -299,17 +299,17 @@
...
@@ -299,17 +299,17 @@
<
el
-
form
-
item
label
=
"盘点单号 检索条件"
prop
=
"stocktakeId"
>
<
el
-
form
-
item
label
=
"盘点单号 检索条件"
prop
=
"stocktakeId"
>
<
el
-
input
v
-
model
=
"form.stocktakeId"
placeholder
=
"请输入盘点单号 检索条件"
/>
<
el
-
input
v
-
model
=
"form.stocktakeId"
placeholder
=
"请输入盘点单号 检索条件"
/>
<
/el-form-item
>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"货物
ID
字典,检索条件"
prop
=
"materialId"
>
<
el
-
form
-
item
label
=
"货物 字典,检索条件"
prop
=
"materialId"
>
<
el
-
input
v
-
model
=
"form.materialId"
placeholder
=
"请输入货物
ID
字典,检索条件"
/>
<
el
-
input
v
-
model
=
"form.materialId"
placeholder
=
"请输入货物 字典,检索条件"
/>
<
/el-form-item
>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"批次
ID
检索条件"
prop
=
"batchCode"
>
<
el
-
form
-
item
label
=
"批次 检索条件"
prop
=
"batchCode"
>
<
el
-
input
v
-
model
=
"form.batchCode"
placeholder
=
"请输入批次
ID
检索条件"
/>
<
el
-
input
v
-
model
=
"form.batchCode"
placeholder
=
"请输入批次 检索条件"
/>
<
/el-form-item
>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"仓库
ID
检索条件"
prop
=
"warehouseId"
>
<
el
-
form
-
item
label
=
"仓库 检索条件"
prop
=
"warehouseId"
>
<
el
-
input
v
-
model
=
"form.warehouseId"
placeholder
=
"请输入仓库
ID
检索条件"
/>
<
el
-
input
v
-
model
=
"form.warehouseId"
placeholder
=
"请输入仓库 检索条件"
/>
<
/el-form-item
>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"库位
ID
检索条件"
prop
=
"locationId"
>
<
el
-
form
-
item
label
=
"库位 检索条件"
prop
=
"locationId"
>
<
el
-
input
v
-
model
=
"form.locationId"
placeholder
=
"请输入库位
ID
检索条件"
/>
<
el
-
input
v
-
model
=
"form.locationId"
placeholder
=
"请输入库位 检索条件"
/>
<
/el-form-item
>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"系统数量"
prop
=
"systemQuantity"
>
<
el
-
form
-
item
label
=
"系统数量"
prop
=
"systemQuantity"
>
<
el
-
input
v
-
model
=
"form.systemQuantity"
placeholder
=
"请输入系统数量"
/>
<
el
-
input
v
-
model
=
"form.systemQuantity"
placeholder
=
"请输入系统数量"
/>
...
...
ruoyi-admin-vue/src/views/inventory/stocktakes/stocktakeCountTable.vue
View file @
f9be7e47
...
@@ -51,7 +51,6 @@
...
@@ -51,7 +51,6 @@
readonly
readonly
@
focus=
"openLocationSelector"
@
focus=
"openLocationSelector"
:suffix-icon=
"''"
:suffix-icon=
"''"
:disabled=
"!queryParams.warehousesCode"
>
>
<
template
v-if=
"queryLocationName"
#
suffix
>
<
template
v-if=
"queryLocationName"
#
suffix
>
<i
<i
...
@@ -238,8 +237,8 @@ export default {
...
@@ -238,8 +237,8 @@ export default {
this
.
queryParams
.
warehouseId
=
warehouse
.
warehouseId
this
.
queryParams
.
warehouseId
=
warehouse
.
warehouseId
this
.
queryWarehouseName
=
warehouse
.
warehousesName
||
warehouse
.
warehouseId
this
.
queryWarehouseName
=
warehouse
.
warehousesName
||
warehouse
.
warehouseId
// 仓库选择后,清空库位信息
// 仓库选择后,清空库位信息
this
.
queryLocationName
=
null
//
this.queryLocationName = null
this
.
queryParams
.
locationId
=
null
//
this.queryParams.locationId = null
this
.
handleQuery
()
this
.
handleQuery
()
},
},
...
@@ -272,16 +271,16 @@ export default {
...
@@ -272,16 +271,16 @@ export default {
this
.
queryWarehouseName
=
null
this
.
queryWarehouseName
=
null
this
.
queryParams
.
warehouseId
=
null
this
.
queryParams
.
warehouseId
=
null
// 清空仓库时,同时清空库位
// 清空仓库时,同时清空库位
this
.
queryLocationName
=
null
//
this.queryLocationName = null
this
.
queryParams
.
locationId
=
null
//
this.queryParams.locationId = null
this
.
handleQuery
()
this
.
handleQuery
()
},
},
/** 打开库位选择器 */
/** 打开库位选择器 */
openLocationSelector
()
{
openLocationSelector
()
{
if
(
!
this
.
queryParams
.
warehouseId
)
{
//
if (!this.queryParams.warehouseId) {
this
.
$message
.
warning
(
"请先选择仓库"
)
//
this.$message.warning("请先选择仓库")
return
//
return
}
//
}
this
.
locationSelectorVisible
=
true
this
.
locationSelectorVisible
=
true
},
},
/** 清空库位选择 */
/** 清空库位选择 */
...
...
ruoyi-admin-vue/src/views/inventory/stocktakes/stocktakeItemsTable.vue
View file @
f9be7e47
...
@@ -76,74 +76,96 @@
...
@@ -76,74 +76,96 @@
@
selection-change=
"handleSelectionChange"
@
selection-change=
"handleSelectionChange"
border
border
size=
"small"
>
size=
"small"
>
<el-table-column
label=
"子表
ID"
align=
"center"
width=
"150px"
prop=
"id"
v-if=
"false"
/>
<el-table-column
label=
"子表
"
align=
"center"
min-
width=
"150px"
prop=
"id"
v-if=
"false"
/>
<el-table-column
label=
"物料"
align=
"center"
prop=
"materialId"
width=
"150px"
fixed
>
<el-table-column
label=
"物料"
align=
"center"
prop=
"materialId"
min-
width=
"150px"
fixed
>
<
template
slot-scope=
"scope"
>
<
template
slot-scope=
"scope"
>
<div
class=
"
el-input__inner disabled-input"
style=
"padding: 0 15px; height: 32px; line-height: 32px;
"
>
<div
class=
"
disabled-input
"
>
{{
getDictLabel
(
materialDict
,
scope
.
row
.
materialId
,
'id'
,
'material_name'
)
}}
{{
getDictLabel
(
materialDict
,
scope
.
row
.
materialId
,
'id'
,
'material_name'
)
}}
</div>
</div>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
<el-table-column
label=
"批次编号"
align=
"center"
prop=
"batchCode"
width=
"150px"
>
<el-table-column
label=
"批次编号"
align=
"center"
prop=
"batchCode"
min-
width=
"150px"
>
<
template
slot-scope=
"scope"
>
<
template
slot-scope=
"scope"
>
<el-input
v-model=
"scope.row.batchCode"
placeholder=
"请输入批次编号"
disabled
/>
<div
class=
"disabled-input"
>
{{
scope
.
row
.
batchCode
}}
</div>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
<el-table-column
label=
"仓库"
align=
"center"
prop=
"warehouseName"
width=
"150px"
>
<el-table-column
label=
"仓库"
align=
"center"
prop=
"warehouseName"
min-
width=
"150px"
>
<
template
slot-scope=
"scope"
>
<
template
slot-scope=
"scope"
>
<el-input
v-model=
"scope.row.warehouseName"
placeholder=
"请输入仓库"
disabled
/>
<div
class=
"disabled-input"
>
{{
scope
.
row
.
warehouseName
}}
</div>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
<el-table-column
label=
"库位"
align=
"center"
prop=
"locationName"
width=
"150px"
>
<el-table-column
label=
"库位"
align=
"center"
prop=
"locationName"
min-
width=
"150px"
>
<
template
slot-scope=
"scope"
>
<
template
slot-scope=
"scope"
>
<el-input
v-model=
"scope.row.locationName"
placeholder=
"请输入库位"
disabled
/>
<div
class=
"disabled-input"
>
{{
scope
.
row
.
locationName
}}
</div>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
<el-table-column
label=
"系统数量"
align=
"center"
prop=
"systemQuantity"
width=
"150px"
>
<el-table-column
label=
"系统数量"
align=
"center"
prop=
"systemQuantity"
min-
width=
"150px"
>
<
template
slot-scope=
"scope"
>
<
template
slot-scope=
"scope"
>
<el-input
v-model=
"scope.row.systemQuantity"
placeholder=
"请输入系统数量"
disabled
/>
<div
class=
"disabled-input"
>
{{
scope
.
row
.
systemQuantity
}}
</div>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
<el-table-column
label=
"实际数量"
align=
"center"
prop=
"actualQuantity"
width=
"150px"
>
<el-table-column
label=
"实际数量"
align=
"center"
prop=
"actualQuantity"
min-
width=
"150px"
>
<
template
slot-scope=
"scope"
>
<
template
slot-scope=
"scope"
>
<el-input
v-model=
"scope.row.actualQuantity"
<template
v-if=
"isConfirm"
>
placeholder=
"请输入实际数量"
<div
class=
"disabled-input"
>
type=
"number"
{{
scope
.
row
.
actualQuantity
}}
:disabled=
"isConfirm"
</div>
@
input=
"handleItemChange(scope.row)"
</
template
>
/>
<
template
v-else
>
<el-input
v-model=
"scope.row.actualQuantity"
placeholder=
"请输入实际数量"
type=
"number"
@
input=
"handleItemChange(scope.row)"
/>
</
template
>
</template>
</template>
</el-table-column>
</el-table-column>
<el-table-column
label=
"差异数量"
align=
"center"
prop=
"varianceQuantity"
width=
"150px"
>
<el-table-column
label=
"差异数量"
align=
"center"
prop=
"varianceQuantity"
min-
width=
"150px"
>
<
template
slot-scope=
"scope"
>
<
template
slot-scope=
"scope"
>
<el-input
type=
"number"
v-model=
"scope.row.varianceQuantity"
placeholder=
"请输入差异数量"
disabled
/>
<div
class=
"disabled-input"
>
{{
scope
.
row
.
varianceQuantity
}}
</div>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
<el-table-column
label=
"单价"
align=
"center"
prop=
"unitPrice"
width=
"150px"
>
<el-table-column
label=
"单价"
align=
"center"
prop=
"unitPrice"
min-
width=
"150px"
>
<
template
slot-scope=
"scope"
>
<
template
slot-scope=
"scope"
>
<div
class=
"
el-input__inner disabled-input"
style=
"padding: 0 15px; height: 32px; line-height: 32px;
"
>
<div
class=
"
disabled-input
"
>
{{
formatAmount
(
scope
.
row
.
unitPrice
)
}}
{{
formatAmount
(
scope
.
row
.
unitPrice
)
}}
</div>
</div>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
<el-table-column
label=
"差异金额"
align=
"center"
prop=
"varianceAmount"
width=
"150px"
>
<el-table-column
label=
"差异金额"
align=
"center"
prop=
"varianceAmount"
min-
width=
"150px"
>
<
template
slot-scope=
"scope"
>
<
template
slot-scope=
"scope"
>
<div
class=
"
el-input__inner disabled-input"
style=
"padding: 0 15px; height: 32px; line-height: 32px;
"
>
<div
class=
"
disabled-input
"
>
{{
formatAmount
(
scope
.
row
.
varianceAmount
)
}}
{{
formatAmount
(
scope
.
row
.
varianceAmount
)
}}
</div>
</div>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
<el-table-column
label=
"是否已调整"
align=
"center"
prop=
"adjusted"
v-if=
"isConfirm"
width=
"150px"
>
<el-table-column
label=
"是否已调整"
align=
"center"
prop=
"adjusted"
v-if=
"isConfirm"
min-
width=
"150px"
>
<
template
slot-scope=
"scope"
>
<
template
slot-scope=
"scope"
>
<!--
<el-input
v-model=
"scope.row.adjusted"
placeholder=
"请输入是否已调整0否1是"
disabled
/>
-->
<div
class=
"disabled-input"
>
<div
class=
"el-input__inner disabled-input"
style=
"padding: 0 15px; height: 32px; line-height: 32px;"
>
<dict-tag
:options=
"dict.type.is_adjusted"
:value=
"scope.row.adjusted"
/>
<dict-tag
:options=
"dict.type.is_adjusted"
:value=
"scope.row.adjusted"
/>
</div>
</div>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
<el-table-column
prop=
"adjustedType"
align=
"center"
label=
"调整原因类型"
width=
"150px"
>
<el-table-column
prop=
"adjustedType"
align=
"center"
label=
"调整原因类型"
min-width=
"150px"
>
<
template
slot-scope=
"scope"
>
<
template
v-if=
"isConfirm"
slot-scope=
"scope"
>
<div
class=
"disabled-input"
>
{{
getAdjustReasonName
(
scope
.
row
.
adjustedType
)
}}
</div>
</
template
>
<
template
v-else
slot-scope=
"scope"
>
<!--
<template
slot-scope=
"scope"
>
-->
<el-select
<el-select
v-model=
"scope.row.adjustedType"
v-model=
"scope.row.adjustedType"
placeholder=
"请选择调整原因类型"
placeholder=
"请选择调整原因类型"
...
@@ -162,26 +184,38 @@
...
@@ -162,26 +184,38 @@
</el-select>
</el-select>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
<el-table-column
label=
"调整原因"
align=
"center"
prop=
"adjustmentReason"
width=
"150px"
>
<el-table-column
label=
"调整原因"
align=
"center"
prop=
"adjustmentReason"
min-
width=
"150px"
>
<
template
slot-scope=
"scope"
>
<
template
slot-scope=
"scope"
>
<el-input
<template
v-if=
"isConfirm"
>
v-model=
"scope.row.adjustmentReason"
<div
placeholder=
"请输入调整原因"
class=
"disabled-input"
type=
"text"
>
:disabled=
"isConfirm"
{{
scope
.
row
.
adjustmentReason
}}
:style=
"(Number(scope.row.varianceQuantity)||0)!==0 && !scope.row.adjustmentReason ?
{border:'1px solid #f56c6c',boxShadow:'0 0 0 2px rgba(245,108,108,0.2)'} : {}"
</div>
@input="handleItemChange(scope.row)"
</
template
>
/>
<
template
v-else
>
<el-input
v-model=
"scope.row.adjustmentReason"
placeholder=
"请输入调整原因"
type=
"text"
:style=
"(Number(scope.row.varianceQuantity)||0)!==0 && !scope.row.adjustmentReason ?
{border:'1px solid #f56c6c',boxShadow:'0 0 0 2px rgba(245,108,108,0.2)'} : {}"
@input="handleItemChange(scope.row)"
/>
</
template
>
</template>
</template>
</el-table-column>
</el-table-column>
<el-table-column
label=
"调整人"
align=
"center"
prop=
"adjustedBy"
v-if=
"isConfirm"
width=
"150px"
>
<el-table-column
label=
"调整人"
align=
"center"
prop=
"adjustedBy"
v-if=
"isConfirm"
min-
width=
"150px"
>
<
template
slot-scope=
"scope"
>
<
template
slot-scope=
"scope"
>
<el-input
v-model=
"scope.row.adjustedBy"
placeholder=
"请输入调整人"
disabled
/>
<div
class=
"disabled-input"
>
{{
scope
.
row
.
adjustedBy
}}
</div>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
<el-table-column
label=
"调整时间"
align=
"center"
prop=
"adjustedAt"
v-if=
"isConfirm"
width=
"150px"
>
<el-table-column
label=
"调整时间"
align=
"center"
prop=
"adjustedAt"
v-if=
"isConfirm"
min-
width=
"150px"
>
<
template
slot-scope=
"scope"
>
<
template
slot-scope=
"scope"
>
<el-date-picker
clearable
v-model=
"scope.row.adjustedAt"
type=
"date"
value-format=
"yyyy-MM-dd"
placeholder=
"请选择调整时间"
disabled
/>
<div
class=
"disabled-input"
>
{{
scope
.
row
.
adjustedAt
}}
</div>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
</el-table>
</el-table>
...
@@ -458,6 +492,11 @@ export default {
...
@@ -458,6 +492,11 @@ export default {
})
})
// 同步通知父组件数据变化
// 同步通知父组件数据变化
this
.
$emit
(
"item-change"
,
row
);
this
.
$emit
(
"item-change"
,
row
);
},
/** 获取调整原因名称 */
getAdjustReasonName
(
status
)
{
const
item
=
this
.
dict
.
type
.
adjusted_type
.
find
(
item
=>
item
.
value
===
status
)
return
item
?
item
.
label
:
'未知'
}
}
}
}
}
}
...
@@ -486,11 +525,12 @@ export default {
...
@@ -486,11 +525,12 @@ export default {
--el-table-row-hover-bg-color
:
#f5f7fa
;
--el-table-row-hover-bg-color
:
#f5f7fa
;
}
}
.disabled-input
{
/*
.disabled-input {
background-color: #f5f7fa !important;
background-color: #f5f7fa !important;
border: 1px solid #e5e6eb !important;
border: 1px solid #e5e6eb !important;
color: #909399 !important;
color: #909399 !important;
cursor: not-allowed !important;
cursor: not-allowed !important;
border-radius: 4px !important;
border-radius: 4px !important;
}
padding: 0 15px; height: 32px; line-height: 32px;
} */
</
style
>
</
style
>
ruoyi-admin-vue/src/views/inventory/warehouses/index.vue
View file @
f9be7e47
...
@@ -36,15 +36,15 @@
...
@@ -36,15 +36,15 @@
@
click=
"handleExport"
@
click=
"handleExport"
v-hasPermi=
"['inventory:warehouses:export']"
v-hasPermi=
"['inventory:warehouses:export']"
>
导出
</el-button>
>
导出
</el-button>
</
template
>
</
template
>
</PageTitle>
</PageTitle>
<div
class=
"page-container"
>
<div
class=
"page-container"
>
<page-wrapper-search
<page-wrapper-search
:model=
"queryParams"
:model=
"queryParams"
ref=
"queryForm"
ref=
"queryForm"
size=
"small"
size=
"small"
@
search=
"handleQuery"
@
search=
"handleQuery"
@
reset=
"resetQuery"
@
reset=
"resetQuery"
>
>
...
@@ -104,21 +104,21 @@
...
@@ -104,21 +104,21 @@
<div
class=
"table-container"
>
<div
class=
"table-container"
>
<el-table
v-loading=
"loading"
:data=
"warehousesList"
height=
"100%"
@
selection-change=
"handleSelectionChange"
>
<el-table
v-loading=
"loading"
:data=
"warehousesList"
height=
"100%"
@
selection-change=
"handleSelectionChange"
>
<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=
"warehousesCode"
width=
"120"
fixed
/>
<el-table-column
label=
"仓库编码"
align=
"center"
prop=
"warehousesCode"
min-
width=
"120"
fixed
/>
<el-table-column
label=
"仓库名称"
align=
"center"
prop=
"warehousesName"
width=
"150"
/>
<el-table-column
label=
"仓库名称"
align=
"center"
prop=
"warehousesName"
min-
width=
"150"
/>
<el-table-column
label=
"仓库类型"
align=
"center"
prop=
"warehouseType"
width=
"100"
>
<el-table-column
label=
"仓库类型"
align=
"center"
prop=
"warehouseType"
min-
width=
"100"
>
<
template
slot-scope=
"scope"
>
<
template
slot-scope=
"scope"
>
<dict-tag
:options=
"dict.type.warehouse_type"
:value=
"scope.row.warehouseType"
/>
<dict-tag
:options=
"dict.type.warehouse_type"
:value=
"scope.row.warehouseType"
/>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
<el-table-column
label=
"仓库地点"
align=
"center"
prop=
"address"
width=
"200"
/>
<el-table-column
label=
"仓库地点"
align=
"center"
prop=
"address"
min-
width=
"200"
/>
<el-table-column
label=
"仓库区域"
align=
"center"
prop=
"area"
width=
"120"
/>
<el-table-column
label=
"仓库区域"
align=
"center"
prop=
"area"
min-
width=
"120"
/>
<el-table-column
label=
"仓库容量"
align=
"center"
prop=
"capacity"
width=
"100"
/>
<el-table-column
label=
"仓库容量"
align=
"center"
prop=
"capacity"
min-
width=
"100"
/>
<el-table-column
label=
"仓库管理员"
align=
"center"
prop=
"manager"
width=
"120"
/>
<el-table-column
label=
"仓库管理员"
align=
"center"
prop=
"manager"
min-
width=
"120"
/>
<el-table-column
label=
"联系电话"
align=
"center"
prop=
"contactPhone"
width=
"120"
/>
<el-table-column
label=
"联系电话"
align=
"center"
prop=
"contactPhone"
min-
width=
"120"
/>
<el-table-column
label=
"应用状态"
align=
"center"
prop=
"isEnabled"
width=
"100"
>
<el-table-column
label=
"应用状态"
align=
"center"
prop=
"isEnabled"
min-
width=
"100"
>
<
template
slot-scope=
"scope"
>
<
template
slot-scope=
"scope"
>
<el-tag
<el-tag
:type=
"scope.row.isEnabled === 1 ? 'success' : 'danger'"
:type=
"scope.row.isEnabled === 1 ? 'success' : 'danger'"
size=
"small"
size=
"small"
>
>
...
@@ -126,7 +126,7 @@
...
@@ -126,7 +126,7 @@
</el-tag>
</el-tag>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
<el-table-column
label=
"创建日期"
align=
"center"
prop=
"createTime"
width=
"160"
/>
<el-table-column
label=
"创建日期"
align=
"center"
prop=
"createTime"
min-
width=
"160"
/>
<el-table-column
label=
"操作"
align=
"center"
class-name=
"small-padding fixed-width"
width=
"120"
fixed=
"right"
>
<el-table-column
label=
"操作"
align=
"center"
class-name=
"small-padding fixed-width"
width=
"120"
fixed=
"right"
>
<
template
slot-scope=
"scope"
>
<
template
slot-scope=
"scope"
>
<el-button
<el-button
...
@@ -147,7 +147,7 @@
...
@@ -147,7 +147,7 @@
</el-table-column>
</el-table-column>
</el-table>
</el-table>
</div>
</div>
<pagination
<pagination
v-show=
"total>0"
v-show=
"total>0"
:total=
"total"
:total=
"total"
...
@@ -202,10 +202,10 @@
...
@@ -202,10 +202,10 @@
</el-col>
</el-col>
<el-col
:span=
"12"
>
<el-col
:span=
"12"
>
<el-form-item
label=
"仓库容量"
prop=
"capacity"
>
<el-form-item
label=
"仓库容量"
prop=
"capacity"
>
<el-input-number
<el-input-number
v-model=
"form.capacity"
v-model=
"form.capacity"
placeholder=
"请输入仓库容量"
placeholder=
"请输入仓库容量"
:min=
"0"
:min=
"0"
style=
"width: 100%"
style=
"width: 100%"
/>
/>
</el-form-item>
</el-form-item>
...
@@ -230,7 +230,7 @@
...
@@ -230,7 +230,7 @@
</el-form-item>
</el-form-item>
</el-col>
</el-col>
</el-row>
</el-row>
</el-form>
</el-form>
<div
slot=
"footer"
class=
"dialog-footer"
>
<div
slot=
"footer"
class=
"dialog-footer"
>
<el-button
type=
"primary"
@
click=
"submitForm"
>
确 定
</el-button>
<el-button
type=
"primary"
@
click=
"submitForm"
>
确 定
</el-button>
...
@@ -354,7 +354,7 @@ export default {
...
@@ -354,7 +354,7 @@ export default {
{
required
:
true
,
message
:
'应用状态不能为空'
,
trigger
:
'change'
}
{
required
:
true
,
message
:
'应用状态不能为空'
,
trigger
:
'change'
}
],
],
area
:
[
area
:
[
{
{
validator
:
(
rule
,
value
,
callback
)
=>
{
validator
:
(
rule
,
value
,
callback
)
=>
{
// 空值直接通过(如果需要必填,可加required规则)
// 空值直接通过(如果需要必填,可加required规则)
if
(
!
value
)
return
callback
();
if
(
!
value
)
return
callback
();
...
@@ -364,8 +364,8 @@ export default {
...
@@ -364,8 +364,8 @@ export default {
}
else
{
}
else
{
callback
();
callback
();
}
}
},
},
trigger
:
'blur'
trigger
:
'blur'
}
}
],
],
// 新增:联系电话校验(手机号格式)
// 新增:联系电话校验(手机号格式)
...
@@ -467,7 +467,7 @@ export default {
...
@@ -467,7 +467,7 @@ export default {
this
.
open
=
true
;
// 先打开弹窗,渲染表单DOM
this
.
open
=
true
;
// 先打开弹窗,渲染表单DOM
// 等待DOM渲染完成后再重置
// 等待DOM渲染完成后再重置
this
.
$nextTick
(()
=>
{
this
.
$nextTick
(()
=>
{
this
.
reset
();
this
.
reset
();
});
});
},
},
handleUpdate
(
row
)
{
handleUpdate
(
row
)
{
...
@@ -565,4 +565,4 @@ export default {
...
@@ -565,4 +565,4 @@ export default {
.dialog-footer
{
.dialog-footer
{
text-align
:
center
;
text-align
:
center
;
}
}
</
style
>
</
style
>
\ No newline at end of file
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论