Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
jinli gu
JSH ERP
Commits
1e81a691
Commit
1e81a691
authored
Oct 31, 2021
by
季圣华
Browse files
优化库存预警报表的查询逻辑
parent
c9ac3d21
Changes
15
Hide whitespace changes
Inline
Side-by-side
jshERP-web/src/mixins/JeecgListMixin.js
View file @
1e81a691
...
...
@@ -388,7 +388,7 @@ export const JeecgListMixin = {
//需要合计的列
let
parseCols
=
'
initialStock,currentStock,currentStockPrice,initialAmount,thisMonthAmount,currentAmount,inSum,inSumPrice,
'
+
'
outSum,outSumPrice,outInSumPrice,operNumber,allPrice,numSum,priceSum,prevSum,thisSum,thisAllPrice,billMoney,changeAmount,
'
+
'
allPrice,
safetystock,
currentNumber,l
injieNumber
'
'
allPrice,currentNumber,l
owSafeStock,highSafeStock,lowCritical,highCritical
'
columns
.
forEach
(
column
=>
{
let
{
key
,
dataIndex
}
=
column
if
(
!
[
key
,
dataIndex
].
includes
(
numKey
))
{
...
...
@@ -408,7 +408,7 @@ export const JeecgListMixin = {
})
dataSource
.
push
(
totalRow
)
//总数要增加合计的行数,每页都有一行合计,所以总数要加上
let
size
=
parseInt
(
this
.
ipagination
.
total
/
this
.
ipagination
.
pageSize
)
+
1
let
size
=
Math
.
ceil
(
this
.
ipagination
.
total
/
this
.
ipagination
.
pageSize
)
this
.
ipagination
.
total
=
this
.
ipagination
.
total
+
size
}
},
...
...
jshERP-web/src/views/material/modules/MaterialModal.vue
View file @
1e81a691
...
...
@@ -366,10 +366,10 @@
title
:
'
期初库存数量
'
,
key
:
'
initStock
'
,
width
:
'
15%
'
,
type
:
FormTypes
.
input
,
defaultValue
:
''
,
placeholder
:
'
请输入${title}
'
},
{
title
:
'
最低库存数量
'
,
key
:
'
lowSafeStock
'
,
width
:
'
15%
'
,
type
:
FormTypes
.
input
,
defaultValue
:
''
,
placeholder
:
'
请输入${title}
'
title
:
'
最低
安全
库存数量
'
,
key
:
'
lowSafeStock
'
,
width
:
'
15%
'
,
type
:
FormTypes
.
input
,
defaultValue
:
''
,
placeholder
:
'
请输入${title}
'
},
{
title
:
'
最高库存数量
'
,
key
:
'
highSafeStock
'
,
width
:
'
15%
'
,
type
:
FormTypes
.
input
,
defaultValue
:
''
,
placeholder
:
'
请输入${title}
'
title
:
'
最高
安全
库存数量
'
,
key
:
'
highSafeStock
'
,
width
:
'
15%
'
,
type
:
FormTypes
.
input
,
defaultValue
:
''
,
placeholder
:
'
请输入${title}
'
}
]
},
...
...
jshERP-web/src/views/report/AccountReport.vue
View file @
1e81a691
...
...
@@ -64,7 +64,7 @@
:page-size=
"ipagination.pageSize"
:page-size-options=
"ipagination.pageSizeOptions"
:total=
"ipagination.total"
:show-total=
"(total, range) => `共 $
{total-
parseInt
(total/ipagination.pageSize)
-1
} 条`">
:show-total=
"(total, range) => `共 $
{total-
Math.ceil
(total/ipagination.pageSize)} 条`">
<template
slot=
"buildOptionText"
slot-scope=
"props"
>
<span>
{{
props
.
value
-
1
}}
条/页
</span>
</
template
>
...
...
jshERP-web/src/views/report/AllocationDetail.vue
View file @
1e81a691
...
...
@@ -91,7 +91,7 @@
:page-size=
"ipagination.pageSize"
:page-size-options=
"ipagination.pageSizeOptions"
:total=
"ipagination.total"
:show-total=
"(total, range) => `共 $
{total-
parseInt
(total/ipagination.pageSize)
-1
} 条`">
:show-total=
"(total, range) => `共 $
{total-
Math.ceil
(total/ipagination.pageSize)} 条`">
<template
slot=
"buildOptionText"
slot-scope=
"props"
>
<span>
{{
props
.
value
-
1
}}
条/页
</span>
</
template
>
...
...
jshERP-web/src/views/report/BuyInReport.vue
View file @
1e81a691
...
...
@@ -52,7 +52,7 @@
:page-size=
"ipagination.pageSize"
:page-size-options=
"ipagination.pageSizeOptions"
:total=
"ipagination.total"
:show-total=
"(total, range) => `共 $
{total-
parseInt
(total/ipagination.pageSize)
-1
} 条`">
:show-total=
"(total, range) => `共 $
{total-
Math.ceil
(total/ipagination.pageSize)} 条`">
<template
slot=
"buildOptionText"
slot-scope=
"props"
>
<span>
{{
props
.
value
-
1
}}
条/页
</span>
</
template
>
...
...
jshERP-web/src/views/report/CustomerAccount.vue
View file @
1e81a691
...
...
@@ -71,7 +71,7 @@
:page-size=
"ipagination.pageSize"
:page-size-options=
"ipagination.pageSizeOptions"
:total=
"ipagination.total"
:show-total=
"(total, range) => `共 $
{total-
parseInt
(total/ipagination.pageSize)
-1
} 条`">
:show-total=
"(total, range) => `共 $
{total-
Math.ceil
(total/ipagination.pageSize)} 条`">
<template
slot=
"buildOptionText"
slot-scope=
"props"
>
<span>
{{
props
.
value
-
1
}}
条/页
</span>
</
template
>
...
...
jshERP-web/src/views/report/InDetail.vue
View file @
1e81a691
...
...
@@ -84,7 +84,7 @@
:page-size=
"ipagination.pageSize"
:page-size-options=
"ipagination.pageSizeOptions"
:total=
"ipagination.total"
:show-total=
"(total, range) => `共 $
{total-
parseInt
(total/ipagination.pageSize)
-1
} 条`">
:show-total=
"(total, range) => `共 $
{total-
Math.ceil
(total/ipagination.pageSize)} 条`">
<template
slot=
"buildOptionText"
slot-scope=
"props"
>
<span>
{{
props
.
value
-
1
}}
条/页
</span>
</
template
>
...
...
jshERP-web/src/views/report/InMaterialCount.vue
View file @
1e81a691
...
...
@@ -81,7 +81,7 @@
:page-size=
"ipagination.pageSize"
:page-size-options=
"ipagination.pageSizeOptions"
:total=
"ipagination.total"
:show-total=
"(total, range) => `共 $
{total-
parseInt
(total/ipagination.pageSize)
-1
} 条`">
:show-total=
"(total, range) => `共 $
{total-
Math.ceil
(total/ipagination.pageSize)} 条`">
<template
slot=
"buildOptionText"
slot-scope=
"props"
>
<span>
{{
props
.
value
-
1
}}
条/页
</span>
</
template
>
...
...
jshERP-web/src/views/report/InOutStockReport.vue
View file @
1e81a691
...
...
@@ -70,7 +70,7 @@
:page-size=
"ipagination.pageSize"
:page-size-options=
"ipagination.pageSizeOptions"
:total=
"ipagination.total"
:show-total=
"(total, range) => `共 $
{total-
parseInt
(total/ipagination.pageSize)
-1
} 条`">
:show-total=
"(total, range) => `共 $
{total-
Math.ceil
(total/ipagination.pageSize)} 条`">
<template
slot=
"buildOptionText"
slot-scope=
"props"
>
<span>
{{
props
.
value
-
1
}}
条/页
</span>
</
template
>
...
...
jshERP-web/src/views/report/MaterialStock.vue
View file @
1e81a691
...
...
@@ -87,7 +87,7 @@
:page-size=
"ipagination.pageSize"
:page-size-options=
"ipagination.pageSizeOptions"
:total=
"ipagination.total"
:show-total=
"(total, range) => `共 $
{total-
parseInt
(total/ipagination.pageSize)
-1
} 条`">
:show-total=
"(total, range) => `共 $
{total-
Math.ceil
(total/ipagination.pageSize)} 条`">
<template
slot=
"buildOptionText"
slot-scope=
"props"
>
<span>
{{
props
.
value
-
1
}}
条/页
</span>
</
template
>
...
...
jshERP-web/src/views/report/OutDetail.vue
View file @
1e81a691
...
...
@@ -84,7 +84,7 @@
:page-size=
"ipagination.pageSize"
:page-size-options=
"ipagination.pageSizeOptions"
:total=
"ipagination.total"
:show-total=
"(total, range) => `共 $
{total-
parseInt
(total/ipagination.pageSize)
-1
} 条`">
:show-total=
"(total, range) => `共 $
{total-
Math.ceil
(total/ipagination.pageSize)} 条`">
<template
slot=
"buildOptionText"
slot-scope=
"props"
>
<span>
{{
props
.
value
-
1
}}
条/页
</span>
</
template
>
...
...
jshERP-web/src/views/report/OutMaterialCount.vue
View file @
1e81a691
...
...
@@ -81,7 +81,7 @@
:page-size=
"ipagination.pageSize"
:page-size-options=
"ipagination.pageSizeOptions"
:total=
"ipagination.total"
:show-total=
"(total, range) => `共 $
{total-
parseInt
(total/ipagination.pageSize)
-1
} 条`">
:show-total=
"(total, range) => `共 $
{total-
Math.ceil
(total/ipagination.pageSize)} 条`">
<template
slot=
"buildOptionText"
slot-scope=
"props"
>
<span>
{{
props
.
value
-
1
}}
条/页
</span>
</
template
>
...
...
jshERP-web/src/views/report/SaleOutReport.vue
View file @
1e81a691
...
...
@@ -52,7 +52,7 @@
:page-size=
"ipagination.pageSize"
:page-size-options=
"ipagination.pageSizeOptions"
:total=
"ipagination.total"
:show-total=
"(total, range) => `共 $
{total-
parseInt
(total/ipagination.pageSize)
-1
} 条`">
:show-total=
"(total, range) => `共 $
{total-
Math.ceil
(total/ipagination.pageSize)} 条`">
<template
slot=
"buildOptionText"
slot-scope=
"props"
>
<span>
{{
props
.
value
-
1
}}
条/页
</span>
</
template
>
...
...
jshERP-web/src/views/report/StockWarningReport.vue
View file @
1e81a691
...
...
@@ -59,7 +59,7 @@
:page-size=
"ipagination.pageSize"
:page-size-options=
"ipagination.pageSizeOptions"
:total=
"ipagination.total"
:show-total=
"(total, range) => `共 $
{total-
parseInt
(total/ipagination.pageSize)
-1
} 条`">
:show-total=
"(total, range) => `共 $
{total-
Math.ceil
(total/ipagination.pageSize)} 条`">
<template
slot=
"buildOptionText"
slot-scope=
"props"
>
<span>
{{
props
.
value
-
1
}}
条/页
</span>
</
template
>
...
...
@@ -113,15 +113,18 @@
return
(
t
!==
'
合计
'
)
?
(
parseInt
(
index
)
+
1
)
:
t
}
},
{
title
:
'
条码
'
,
dataIndex
:
'
barCode
'
,
width
:
120
},
{
title
:
'
名称
'
,
dataIndex
:
'
mname
'
,
width
:
120
},
{
title
:
'
仓库
'
,
dataIndex
:
'
depotName
'
,
width
:
100
},
{
title
:
'
条码
'
,
dataIndex
:
'
barCode
'
,
width
:
100
},
{
title
:
'
名称
'
,
dataIndex
:
'
mname
'
,
width
:
100
},
{
title
:
'
规格
'
,
dataIndex
:
'
mstandard
'
,
width
:
80
},
{
title
:
'
型号
'
,
dataIndex
:
'
mmodel
'
,
width
:
80
},
{
title
:
'
扩展信息
'
,
dataIndex
:
'
materialOther
'
,
width
:
150
},
{
title
:
'
单位
'
,
dataIndex
:
'
materialUnit
'
,
width
:
80
},
{
title
:
'
安全存量
'
,
dataIndex
:
'
safetystock
'
,
sorter
:
(
a
,
b
)
=>
a
.
safetystock
-
b
.
safetystock
,
width
:
80
},
{
title
:
'
当前库存
'
,
dataIndex
:
'
currentNumber
'
,
sorter
:
(
a
,
b
)
=>
a
.
currentNumber
-
b
.
currentNumber
,
width
:
80
},
{
title
:
'
建议入库量
'
,
dataIndex
:
'
linjieNumber
'
,
sorter
:
(
a
,
b
)
=>
a
.
linjieNumber
-
b
.
linjieNumber
,
width
:
80
}
{
title
:
'
扩展信息
'
,
dataIndex
:
'
materialOther
'
,
width
:
100
},
{
title
:
'
单位
'
,
dataIndex
:
'
materialUnit
'
,
width
:
60
},
{
title
:
'
库存
'
,
dataIndex
:
'
currentNumber
'
,
sorter
:
(
a
,
b
)
=>
a
.
currentNumber
-
b
.
currentNumber
,
width
:
80
},
{
title
:
'
最低安全库存
'
,
dataIndex
:
'
lowSafeStock
'
,
sorter
:
(
a
,
b
)
=>
a
.
lowSafeStock
-
b
.
lowSafeStock
,
width
:
100
},
{
title
:
'
最高安全库存
'
,
dataIndex
:
'
highSafeStock
'
,
sorter
:
(
a
,
b
)
=>
a
.
highSafeStock
-
b
.
highSafeStock
,
width
:
100
},
{
title
:
'
建议入库量
'
,
dataIndex
:
'
lowCritical
'
,
sorter
:
(
a
,
b
)
=>
a
.
lowCritical
-
b
.
lowCritical
,
width
:
80
},
{
title
:
'
建议出库量
'
,
dataIndex
:
'
highCritical
'
,
sorter
:
(
a
,
b
)
=>
a
.
highCritical
-
b
.
highCritical
,
width
:
80
}
],
url
:
{
list
:
"
/depotItem/findStockWarningCount
"
...
...
@@ -149,10 +152,11 @@
})
},
exportExcel
()
{
let
aoa
=
[[
'
条码
'
,
'
名称
'
,
'
规格
'
,
'
型号
'
,
'
扩展信息
'
,
'
单位
'
,
'
安全存量
'
,
'
当前库存
'
,
'
建议入
库量
'
]]
let
aoa
=
[[
'
仓库
'
,
'
条码
'
,
'
名称
'
,
'
规格
'
,
'
型号
'
,
'
扩展信息
'
,
'
单位
'
,
'
库存
'
,
'
最低安全库存
'
,
'
最高安全库存
'
,
'
建议入库量
'
,
'
建议出
库量
'
]]
for
(
let
i
=
0
;
i
<
this
.
dataSource
.
length
;
i
++
)
{
let
ds
=
this
.
dataSource
[
i
]
let
item
=
[
ds
.
barCode
,
ds
.
mname
,
ds
.
mstandard
,
ds
.
mmodel
,
ds
.
materialOther
,
ds
.
materialUnit
,
ds
.
safetystock
,
ds
.
currentNumber
,
ds
.
linjieNumber
]
let
item
=
[
ds
.
depotName
,
ds
.
barCode
,
ds
.
mname
,
ds
.
mstandard
,
ds
.
mmodel
,
ds
.
materialOther
,
ds
.
materialUnit
,
ds
.
currentNumber
,
ds
.
lowSafeStock
,
ds
.
highSafeStock
,
ds
.
lowCritical
,
ds
.
highCritical
]
aoa
.
push
(
item
)
}
openDownloadDialog
(
sheet2blob
(
aoa
),
'
库存预警
'
)
...
...
jshERP-web/src/views/report/VendorAccount.vue
View file @
1e81a691
...
...
@@ -71,7 +71,7 @@
:page-size=
"ipagination.pageSize"
:page-size-options=
"ipagination.pageSizeOptions"
:total=
"ipagination.total"
:show-total=
"(total, range) => `共 $
{total-
parseInt
(total/ipagination.pageSize)
-1
} 条`">
:show-total=
"(total, range) => `共 $
{total-
Math.ceil
(total/ipagination.pageSize)} 条`">
<template
slot=
"buildOptionText"
slot-scope=
"props"
>
<span>
{{
props
.
value
-
1
}}
条/页
</span>
</
template
>
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment