Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
T
template_vue
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
杨硕
template_vue
Commits
590490b1
Commit
590490b1
authored
Apr 11, 2024
by
Hagsn3
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改代码
parent
85f9f910
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
524 additions
and
1 deletion
+524
-1
incomeWmsBox.js
src/api/incomeWmsBox.js
+11
-0
outcomeWmsJbapplyTemp.js
src/api/outcomeWmsJbapplyTemp.js
+62
-0
permission.js
src/store/modules/permission.js
+1
-1
outcomeWmsJbapplyTemp.vue
src/views/template/outcomeWmsJbapplyTemp.vue
+450
-0
No files found.
src/api/incomeWmsBox.js
View file @
590490b1
...
@@ -66,3 +66,14 @@ export function exportIncomeWmsBox(query) {
...
@@ -66,3 +66,14 @@ export function exportIncomeWmsBox(query) {
responseType
:
'blob'
responseType
:
'blob'
})
})
}
}
export
function
checkIsZero
(
data
)
{
return
request
({
url
:
'incomewmsbox/checkIsZero'
,
method
:
'post'
,
data
,
headers
:
{
'Content-Type'
:
'application/json;charset=UTF-8'
// 接口修改传参类型
}
})
}
src/api/outcomeWmsJbapplyTemp.js
0 → 100644
View file @
590490b1
import
request
from
'@/utils/request'
import
Qs
from
'qs'
/**
* 1. 列表查询
* 2. 查询详细信息
* 3. 新增
* 4. 修改
* 5. 逻辑删除
* 6. 导出
*
*/
export
function
listOutcomeWmsJbapplyTemp
(
query
)
{
return
request
({
url
:
'/outcomewmsjbapplytemp/list'
,
method
:
'get'
,
params
:
query
})
}
export
function
getOutcomeWmsJbapplyTemp
(
businessId
)
{
return
request
({
url
:
'/outcomewmsjbapplytemp/detail/'
+
businessId
,
method
:
'get'
})
}
export
function
addOutcomeWmsJbapplyTemp
(
data
)
{
data
=
Qs
.
stringify
(
data
)
return
request
({
url
:
'/outcomewmsjbapplytemp/add'
,
method
:
'post'
,
data
:
data
})
}
export
function
updateOutcomeWmsJbapplyTemp
(
data
)
{
const
businessId
=
data
.
businessId
data
=
Qs
.
stringify
(
data
)
return
request
({
url
:
'/outcomewmsjbapplytemp/update/'
+
businessId
,
method
:
'put'
,
data
})
}
export
function
delOutcomeWmsJbapplyTemp
(
businessId
)
{
return
request
({
url
:
'/outcomewmsjbapplytemp/deleteLogical/'
+
businessId
,
method
:
'delete'
})
}
export
function
exportOutcomeWmsJbapplyTemp
(
query
)
{
return
request
({
url
:
'/outcomewmsjbapplytemp/export'
,
method
:
'get'
,
params
:
query
,
responseType
:
'blob'
})
}
src/store/modules/permission.js
View file @
590490b1
...
@@ -3,7 +3,7 @@ import { getRouters } from '@/api/menu'
...
@@ -3,7 +3,7 @@ import { getRouters } from '@/api/menu'
import
{
getInfo
}
from
'@/api/login'
import
{
getInfo
}
from
'@/api/login'
import
Layout
from
'@/layout/index'
import
Layout
from
'@/layout/index'
// pathList: 是要隐藏菜单的集合 system元素:一级菜单的路径(path)
// pathList: 是要隐藏菜单的集合 system元素:一级菜单的路径(path)
const
pathList
=
[
'/setup/index'
,
'/setup/outku'
,
'/setup/enterbound'
,
'/setup/test'
,
'/setup/enterboundTwo'
,
'/setup/ApplicationTable
'
]
const
pathList
=
[
'/setup/index'
,
'/setup/outku'
,
'/setup/enterbound'
,
'/setup/test'
,
'/setup/enterboundTwo'
,
'/setup/ApplicationTable'
,
'/setup/inspectionRequestProcessing'
,
'/setup/checkTheApplicationForExit
'
]
const
permission
=
{
const
permission
=
{
state
:
{
state
:
{
routes
:
[],
routes
:
[],
...
...
src/views/template/outcomeWmsJbapplyTemp.vue
0 → 100644
View file @
590490b1
<
template
>
<div
class=
"app-container"
>
<el-form
ref=
"queryForm"
style=
"padding: 0 0 0 10px"
:model=
"queryParams"
:inline=
"true"
>
<el-form-item
label=
"wh_id"
prop=
"whId"
>
<el-select
v-model=
"queryParams.whId"
placeholder=
"请选择仓库"
clearable
size=
"small"
style=
"width: 150px"
>
<el-option
v-for=
"dict in warehouseList"
:key=
"dict.dictValue"
:label=
"dict.dictLabel"
:value=
"dict.dictValue"
/>
</el-select>
</el-form-item>
<el-form-item
label=
"ptype"
prop=
"ptype"
>
<el-select
v-model=
"queryParams.ptype"
placeholder=
"请选择ptype值"
clearable
:maxlength=
"1"
size=
"small"
style=
"width: 150px"
>
<el-option
v-for=
"dict in ptypeOptions"
:key=
"dict.dictValue"
:label=
"dict.dictLabel"
:value=
"dict.dictValue"
/>
</el-select>
</el-form-item>
<el-form-item
label=
"pn"
prop=
"pn"
>
<el-input
v-model=
"queryParams.pn"
placeholder=
"请输入pn"
clearable
:maxlength=
"100"
size=
"small"
style=
"width: 150px"
/>
</el-form-item>
<el-form-item
label=
"出库状态"
prop=
"dealStatus"
>
<el-select
v-model=
"queryParams.dealStatus"
placeholder=
"请选择出库状态"
clearable
size=
"small"
:maxlength=
"1"
>
<el-option
v-for=
"dict in dealStatusOption"
:key=
"dict.dictValue"
:label=
"dict.dictLabel"
:value=
"dict.dictValue"
/>
</el-select>
</el-form-item>
<el-form-item>
<el-button
:class=
"commonField.queryClass"
:type=
"commonField.typePrimary"
:icon=
"commonField.queryIcon"
:size=
"commonField.smallSize"
@
click=
"handleQuery"
>
查询
</el-button>
<el-button
:class=
"commonField.resetClass"
:icon=
"commonField.resetIcon"
:size=
"commonField.smallSize"
@
click=
"resetQuery"
>
重置
</el-button>
</el-form-item>
</el-form>
<div
class=
"placeholder"
/>
<div
style=
"padding:5px 10px"
>
<div
class=
"mb12 font-small-bold"
>
检查申请列表
</div>
<el-table
v-loading=
"loading"
border
:data=
"outcomeWmsJbapplyTempList"
>
<el-table-column
type=
"index"
label=
"序号"
width=
"55"
align=
"center"
/>
<el-table-column
label=
"wh_id"
prop=
"whId"
:show-overflow-tooltip=
"true"
>
<template
slot-scope=
"scope"
>
<!-- 假设字典数据存储在 dataDict 中 -->
<span
v-if=
"scope.row.whId &&getDataDictLabel(scope.row.whId) "
>
{{
getDataDictLabel
(
scope
.
row
.
whId
)
}}
</span>
<span
v-else
>
-
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"ptype"
prop=
"ptype"
:show-overflow-tooltip=
"true"
>
<
template
slot-scope=
"scope"
>
<span
v-if=
"scope.row.ptype === '1'"
>
jb
</span>
<span
v-else-if=
"scope.row.ptype === '2'"
>
label
</span>
<span
v-else-if=
"scope.row.ptype === '3'"
>
wd
</span>
<span
v-else-if=
"scope.row.ptype === '4'"
>
sl
</span>
<span
v-else-if=
"scope.row.ptype === '5'"
>
zd
</span>
<span
v-else
>
-
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"pn"
prop=
"pn"
:show-overflow-tooltip=
"true"
>
<
template
slot-scope=
"scope"
>
{{
scope
.
row
.
pn
||
'-'
}}
</
template
>
</el-table-column>
<el-table-column
label=
"qty"
prop=
"qty"
:show-overflow-tooltip=
"true"
>
<
template
slot-scope=
"scope"
>
{{
scope
.
row
.
qty
||
'-'
}}
</
template
>
</el-table-column>
<el-table-column
label=
"出库状态"
prop=
"dealStatus"
:show-overflow-tooltip=
"true"
>
<
template
slot-scope=
"scope"
>
<span
v-if=
"scope.row.dealStatus === '1'"
>
已出库
</span>
<span
v-else-if=
"scope.row.dealStatus === '0'"
>
未出库
</span>
<span
v-else
>
-
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"操作"
class-name=
"small-padding fixed-width"
width=
"100px"
>
<
template
slot-scope=
"scope"
>
<el-button
:class=
"commonField.delClass"
:type=
"commonField.typeParent"
:size=
"commonField.size"
@
click=
"handleDelete(scope.row)"
>
删除
</el-button>
</
template
>
</el-table-column>
</el-table>
</div>
<pagination
v-show=
"total>0"
:total=
"total"
:page
.
sync=
"queryParams.page"
:limit
.
sync=
"queryParams.rows"
@
pagination=
"getList"
/>
<!-- 添加或修改检查申请配置对话框 -->
<el-dialog
:title=
"title"
:visible
.
sync=
"open"
width=
"500px"
append-to-body
>
<el-form
ref=
"form"
:model=
"form"
:rules=
"rules"
size=
"small"
label-width=
"90px"
>
<el-form-item
label=
"wh_id"
prop=
"whId"
>
<el-select
v-model=
"form.whId"
placeholder=
"请选择仓库"
clearable
size=
"small"
style=
"width: 100%"
>
<el-option
v-for=
"dict in warehouseList"
:key=
"dict.dictValue"
:label=
"dict.dictLabel"
:value=
"dict.dictValue"
/>
</el-select>
</el-form-item>
<el-form-item
label=
"ptype"
prop=
"ptype"
>
<el-select
v-model=
"form.ptype"
placeholder=
"请选择ptype值"
clearable
:maxlength=
"1"
size=
"small"
style=
"width: 100%"
>
<el-option
v-for=
"dict in addTypeOption"
:key=
"dict.dictValue"
:label=
"dict.dictLabel"
:value=
"dict.dictValue"
/>
</el-select>
</el-form-item>
<el-form-item
label=
"pn"
prop=
"pn"
>
<el-input
v-model
.
trim=
"form.pn"
show-word-limit
:maxlength=
"100"
placeholder=
"请输入pn"
/>
</el-form-item>
<el-form-item
label=
"qty"
prop=
"qty"
>
<el-input
v-model
.
trim=
"form.qty"
placeholder=
"请输入qty的值"
/>
</el-form-item>
</el-form>
<div
slot=
"footer"
class=
"dialog-footer"
>
<el-button
class=
"cancelBtn"
@
click=
"cancel"
>
取 消
</el-button>
<el-button
class=
"submitBtn"
type=
"primary"
@
click=
"submitForm"
>
确 定
</el-button>
</div>
</el-dialog>
</div>
</template>
<
script
>
import
{
listOutcomeWmsJbapplyTemp
,
getOutcomeWmsJbapplyTemp
,
delOutcomeWmsJbapplyTemp
,
addOutcomeWmsJbapplyTemp
,
updateOutcomeWmsJbapplyTemp
,
exportOutcomeWmsJbapplyTemp
}
from
'@/api/outcomeWmsJbapplyTemp'
import
commonField
from
'@/utils/commonField'
import
{
getDicts
}
from
'@/api/system/dict/data'
export
default
{
name
:
'OutcomeWmsJbapplyTemp'
,
data
()
{
return
{
// 遮罩层
loading
:
true
,
// 总条数
total
:
0
,
// ????表格数据
outcomeWmsJbapplyTempList
:
[],
// 仓库列表
warehouseList
:
[],
// 弹出层标题
title
:
''
,
// 是否显示弹出层
open
:
false
,
// 状态菜单
statusOptions
:
[
{
dictLabel
:
'启用'
,
dictValue
:
'1'
},
{
dictLabel
:
'停用'
,
dictValue
:
'0'
}
],
// 出库状态
dealStatusOption
:
[
{
dictLabel
:
'已出库'
,
dictValue
:
'1'
},
{
dictLabel
:
'未出库'
,
dictValue
:
'0'
}
],
// ptype菜单
ptypeOptions
:
[
{
dictLabel
:
'jb'
,
dictValue
:
'1'
}
],
addTypeOption
:
[
{
dictLabel
:
'label'
,
dictValue
:
'2'
}
],
// 查询参数
queryParams
:
{
page
:
1
,
rows
:
10
,
pn
:
undefined
,
qty
:
undefined
,
whId
:
undefined
,
ptype
:
undefined
,
dealStatus
:
undefined
,
createByName
:
undefined
,
rank
:
undefined
,
lot
:
undefined
,
flag
:
''
},
// 表单参数
form
:
{},
// 表单校验
rules
:
{
}
}
},
computed
:
{
commonField
()
{
return
commonField
}
},
created
()
{
this
.
getList
()
// 列表查询
this
.
getwareHouse
()
// 查询数据字典
},
methods
:
{
/* 获取数据字典中的值*/
getDataDictLabel
(
whId
)
{
const
dictItem
=
this
.
warehouseList
.
find
(
item
=>
item
.
dictValue
===
whId
)
return
dictItem
?
dictItem
.
dictLabel
:
null
},
/** 查询数据字典*/
getwareHouse
()
{
getDicts
(
'WAREHOUSE'
).
then
(
res
=>
{
console
.
log
(
'仓库数据字典'
,
res
)
this
.
warehouseList
=
res
.
data
const
whId
=
res
.
data
[
0
].
dictValue
this
.
form
.
whId
=
whId
})
},
/** 查询检查申请列表 */
getList
()
{
this
.
loading
=
true
listOutcomeWmsJbapplyTemp
(
this
.
queryParams
).
then
(
response
=>
{
this
.
outcomeWmsJbapplyTempList
=
response
.
rows
this
.
total
=
response
.
total
this
.
loading
=
false
}
)
},
// 取消按钮
cancel
()
{
this
.
open
=
false
this
.
reset
()
},
// 表单重置
reset
()
{
this
.
form
=
{
businessId
:
undefined
,
remarks
:
undefined
,
pn
:
undefined
,
qty
:
undefined
,
whId
:
undefined
,
ptype
:
undefined
,
dealStatus
:
undefined
,
createByName
:
undefined
,
rank
:
undefined
,
lot
:
undefined
,
flag
:
'1'
}
this
.
resetForm
(
'form'
)
},
/** 查询按钮操作 */
handleQuery
()
{
this
.
queryParams
.
page
=
1
this
.
getList
()
},
/** 重置按钮操作 */
resetQuery
()
{
this
.
queryParams
=
{
page
:
1
,
rows
:
10
,
pn
:
undefined
,
qty
:
undefined
,
whId
:
undefined
,
ptype
:
undefined
,
dealStatus
:
undefined
,
createByName
:
undefined
,
rank
:
undefined
,
lot
:
undefined
,
flag
:
''
}
this
.
handleQuery
()
},
/** 新增按钮操作 */
handleAdd
()
{
this
.
reset
()
this
.
open
=
true
this
.
title
=
'添加检查申请'
},
/** 修改按钮操作 */
handleUpdate
(
row
)
{
this
.
reset
()
const
id
=
row
.
businessId
getOutcomeWmsJbapplyTemp
(
id
).
then
(
response
=>
{
this
.
form
=
response
.
data
this
.
open
=
true
this
.
title
=
'修改检查申请'
})
},
// 改变状态
handleStatusChange
(
row
)
{
const
text
=
row
.
flag
===
'1'
?
'启用'
:
'停用'
this
.
$confirm
(
'确认操作?'
,
'提示'
,
{
confirmButtonText
:
'确定'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
}).
then
(
function
()
{
return
updateOutcomeWmsJbapplyTemp
(
row
)
}).
then
(()
=>
{
this
.
$message
({
message
:
text
+
'成功'
,
type
:
'success'
})
}).
catch
(
function
()
{
row
.
flag
=
row
.
flag
===
'0'
?
'1'
:
'0'
})
},
/** 提交按钮 */
submitForm
:
function
()
{
this
.
$refs
[
'form'
].
validate
(
valid
=>
{
if
(
valid
)
{
if
(
this
.
form
.
businessId
!==
undefined
)
{
updateOutcomeWmsJbapplyTemp
(
this
.
form
).
then
(
response
=>
{
this
.
msgSuccess
(
'修改成功'
)
this
.
open
=
false
this
.
getList
()
})
}
else
{
addOutcomeWmsJbapplyTemp
(
this
.
form
).
then
(
response
=>
{
this
.
msgSuccess
(
'新增成功'
)
this
.
open
=
false
this
.
getList
()
})
}
}
})
},
/** 删除按钮操作 */
handleDelete
(
row
)
{
const
id
=
row
.
businessId
this
.
$confirm
(
'是否确认操作?'
,
'提示'
,
{
confirmButtonText
:
'确定'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
}).
then
(
function
()
{
return
delOutcomeWmsJbapplyTemp
(
id
)
}).
then
(()
=>
{
this
.
getList
()
this
.
$message
({
message
:
'删除成功'
,
type
:
'success'
})
}).
catch
(
function
()
{
})
},
/** 导出按钮操作 */
handleExport
()
{
const
queryParams
=
this
.
queryParams
this
.
$confirm
(
'是否确认操作?'
,
'警告'
,
{
confirmButtonText
:
'确定'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
}).
then
(
function
()
{
return
exportOutcomeWmsJbapplyTemp
(
queryParams
).
then
(
response
=>
{
const
blob
=
new
Blob
([
response
])
const
downloadElement
=
document
.
createElement
(
'a'
)
const
href
=
window
.
URL
.
createObjectURL
(
blob
)
// 创建下载的链接
downloadElement
.
href
=
href
downloadElement
.
download
=
'????信息'
+
'.xls'
// 下载后文件名
document
.
body
.
appendChild
(
downloadElement
)
downloadElement
.
click
()
// 点击下载
document
.
body
.
removeChild
(
downloadElement
)
// 下载完成移除元素
window
.
URL
.
revokeObjectURL
(
href
)
// 释放掉blob对象
})
})
}
}
}
</
script
>
<
style
lang=
"scss"
scoped
>
.app-container
{
font-size
:
18px
;
padding
:
0
;
.placeholder
{
height
:
1
.3vh
;
background-color
:
#F4F4F4
;
margin-bottom
:
10px
}
}
</
style
>
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