Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
W
web
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
中汽测评-信息安全测评系统
web
Commits
e3bd6f35
Commit
e3bd6f35
authored
May 15, 2024
by
mengzixuan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat(车企文件库管理): 下载模板和导入接口对接
parent
6c2d7407
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
50 additions
and
1 deletion
+50
-1
index.vue
src/views/processing/fileLibrary/index.vue
+50
-1
No files found.
src/views/processing/fileLibrary/index.vue
View file @
e3bd6f35
...
@@ -49,6 +49,27 @@
...
@@ -49,6 +49,27 @@
@
click=
"resetQuery"
@
click=
"resetQuery"
>
重置
</el-button
>
重置
</el-button
>
>
<el-button
type=
"primary"
icon=
"el-icon-download"
size=
"mini"
@
click=
"downTemplate"
>
下载模板
</el-button
>
<el-upload
style=
"float: right; margin-left: 10px"
:action=
"url"
:headers=
"headers"
:file-list=
"fileList"
:show-file-list=
"false"
:on-success=
"handleUploadSuccess"
:before-upload=
"handleBeforeUpload"
:data=
"data"
>
<el-button
size=
"mini"
icon=
"el-icon-upload2"
type=
"primary"
>
导入
</el-button
>
</el-upload>
</el-form-item>
</el-form-item>
</
template
>
</
template
>
<!-- <el-form-item>
<!-- <el-form-item>
...
@@ -211,6 +232,7 @@
...
@@ -211,6 +232,7 @@
import
page
from
'@/mixins/page'
import
page
from
'@/mixins/page'
import
dialog
from
'./components/dialog.vue'
import
dialog
from
'./components/dialog.vue'
import
routerMixins
from
'@/mixins/router'
import
routerMixins
from
'@/mixins/router'
import
{
getToken
}
from
'@/utils/auth'
export
default
{
export
default
{
components
:
{
components
:
{
'yan-dialog'
:
dialog
'yan-dialog'
:
dialog
...
@@ -238,7 +260,16 @@ export default {
...
@@ -238,7 +260,16 @@ export default {
// 表格loading状态
// 表格loading状态
tableLoading
:
false
,
tableLoading
:
false
,
// 表格数据
// 表格数据
tableData
:
[]
tableData
:
[],
url
:
process
.
env
.
VUE_APP_BASE_API
+
'/review/enterprise/archive/importExcel'
,
data
:
{
taskId
:
this
.
$route
.
query
.
id
}
,
fileList
:
[],
headers
:
{
Authorization
:
'Bearer '
+
getToken
()
}
}
}
}
,
}
,
watch
:
{
watch
:
{
...
@@ -253,6 +284,24 @@ export default {
...
@@ -253,6 +284,24 @@ export default {
this
.
queryParams
.
taskId
=
this
.
$route
.
query
.
id
this
.
queryParams
.
taskId
=
this
.
$route
.
query
.
id
}
,
}
,
methods
:
{
methods
:
{
handleBeforeUpload
(
file
,
fileList
)
{
}
,
handleUploadSuccess
(
file
,
fileList
)
{
if
(
file
.
code
===
200
)
{
this
.
$message
.
success
(
file
.
msg
)
this
.
loadData
()
}
else
if
(
file
.
code
===
500
)
{
this
.
$message
.
error
(
file
.
msg
)
}
}
,
/** 下载模板操作 */
downTemplate
()
{
this
.
download
(
'review/enterprise/archive/importDownload'
,
{
}
,
// `user_template_$
{
new
Date
().
getTime
()
}
.
xlsx
`
`
车企文件库模板
.
xlsx
`
)
}
,
sort_change(column, prop, order) {
sort_change(column, prop, order) {
this.queryParams.pageNum = 1 // 排序后返回第一页
this.queryParams.pageNum = 1 // 排序后返回第一页
if (column.order) {
if (column.order) {
...
...
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