Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
F
factory_front
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
qinjianhui
factory_front
Commits
4bf76094
Commit
4bf76094
authored
May 27, 2025
by
zhuzhequan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
工厂端仓库
parent
ba93e883
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
44 additions
and
2 deletions
+44
-2
src/api/warehouse.ts
+17
-0
src/views/warehouse/warning.vue
+27
-2
No files found.
src/api/warehouse.ts
View file @
4bf76094
...
...
@@ -32,6 +32,17 @@ export interface factoryWarehouseInfo {
warehouseId
?:
string
locationName
?:
string
remark
?:
string
idList
?:
string
|
number
[]
}
export
interface
ExportFactoryWarehouseInfo
{
pageSize
?:
number
currentPage
?:
number
total
?:
number
warehouseId
?:
string
locationName
?:
string
remark
?:
string
idList
?:
string
|
number
[]
}
export
interface
WarehouseInventory
{
...
...
@@ -136,6 +147,12 @@ export function getFactoryLocation(data: factoryWarehouseInfo) {
data
,
)
}
export
function
exportWarehouseInfo
(
data
:
ExportFactoryWarehouseInfo
)
{
return
axios
.
post
<
never
,
BasePaginationData
<
positionInfo
>>
(
'factoryWarehouseInventory/inventory'
,
data
,
)
}
export
function
getFactoryWarehouseInfo
(
data
:
factoryWarehouseInfo
)
{
return
axios
.
post
<
never
,
BasePaginationData
<
warehouseInfo
>>
(
...
...
src/views/warehouse/warning.vue
View file @
4bf76094
...
...
@@ -6,7 +6,7 @@ import {
getWarehouseInventoryInfo
,
factoryLogWarehouseLog
,
LogListData
,
WarehouseWarning
,
factoryWarehouseInventoryPrint
,
WarehouseWarning
,
factoryWarehouseInventoryPrint
,
exportWarehouseInfo
,
}
from
'@/api/warehouse.ts'
import
{
ref
}
from
'vue'
import
SplitDiv
from
'@/components/splitDiv/splitDiv.vue'
...
...
@@ -37,6 +37,7 @@ const pagination = ref<factoryWarehouseInfo>({
total
:
0
,
})
const
showPrintDialog
=
ref
(
false
)
const
exportLoading
=
ref
(
false
)
const
clickItem
=
(
row
:
WarehouseWarning
)
=>
{
if
(
!
row
)
return
getDetail
(
row
.
id
)
...
...
@@ -76,6 +77,28 @@ async function handlePrintProductTag() {
window
.
open
(
filePath
+
res
.
message
,
'_blank'
)
}
async
function
exportData
()
{
if
(
!
selections
.
value
.
length
)
{
return
ElMessage
.
warning
(
'请选择数据'
)
}
exportLoading
.
value
=
true
const
ids
:
number
[]
=
[]
selections
.
value
.
forEach
(
el
=>
{
if
(
el
.
id
)
ids
.
push
(
Number
(
el
.
id
))
})
try
{
const
res
=
await
exportWarehouseInfo
({
...
searchForm
.
value
,
idList
:
ids
,
})
window
.
open
(
filePath
+
res
.
message
,
'_blank'
)
exportLoading
.
value
=
false
}
catch
(
e
)
{
exportLoading
.
value
=
false
}
}
async
function
printProductTag
()
{
if
(
!
selections
.
value
.
length
)
{
return
ElMessage
.
warning
(
'请选择数据'
)
...
...
@@ -191,7 +214,9 @@ getWarehouse()
<el-form-item
style=
"margin-top: 5px"
>
<el-button
type=
"primary"
@
click=
"printProductTag"
>
打印商品SKU标签
</el-button>
</el-form-item>
<el-form-item
style=
"margin-top: 5px"
>
<el-button
:loading=
"exportLoading"
type=
"success"
@
click=
"exportData"
>
导出
</el-button>
</el-form-item>
</el-form>
</el-card>
</template>
...
...
Write
Preview
Markdown
is supported
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