Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
肖康
/
cloudSystem
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
f11ba9d1
authored
Jan 06, 2025
by
LJM
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
重新点开导入弹窗,之前上传的数据需要清空
parent
9bf35607
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
23 additions
and
5 deletions
src/views/consignmentManagement/consignmentImport.vue
src/views/consignmentManagement/consignmentImport.vue
View file @
f11ba9d1
...
...
@@ -58,8 +58,10 @@
</el-table>
<el-pagination
layout=
"total, sizes, prev, pager, next, jumper"
:page-sizes=
"[10, 20, 50, 100, 200]"
:total=
"total"
@
size-change=
"handleSizeChange"
@
current-change=
"handleCurrentChange"
:current-page=
"page"
></el-pagination>
</div>
</div>
<Menu></Menu>
<!--导入数据确认-->
<el-dialog
title=
"导入数据确认"
:close-on-click-modal=
"false"
:visible
.
sync=
"dialogVisible
"
width=
"700px"
>
<el-dialog
title=
"导入数据确认"
:close-on-click-modal=
"false"
:visible
.
sync=
"dialogVisible"
@
closed=
"handleDialogClosed
"
width=
"700px"
>
<div
class=
"dialog-text"
>
<p
class=
"tt"
style=
"font-size: 13px;margin-bottom: 0;"
>
上架最高天数:现货:{{ cp_time_day == -1 ? '无限制' : cp_time_day + '天' }};期货:{{ futures_cp_time_day == -1 ? '无限制' : futures_cp_time_day + '天' }}
...
...
@@ -92,7 +94,7 @@
</div>
<div
slot=
"footer"
class=
"dialog-footer row"
style=
"text-align: right;justify-content: flex-end;"
>
<el-button
@
click=
"dialogVisible = false"
style=
"margin-right: 10px;"
>
取 消
</el-button>
<el-upload
:data=
"fileData"
:action=
"uploadUrl"
:before-upload=
"handleBeforeUpload"
:on-success=
"handleChange"
:on-progress=
"handleProgress"
>
<el-upload
ref=
"upload"
:data=
"fileData"
:action=
"uploadUrl"
:before-upload=
"handleBeforeUpload"
:on-success=
"handleChange"
:on-progress=
"handleProgress"
>
<el-button
type=
"primary"
:loading=
"uploading"
>
确 定
</el-button>
<el-progress
v-if=
"uploading"
:percentage=
"progress"
/>
</el-upload>
...
...
@@ -100,8 +102,6 @@
</div>
</el-dialog>
</div>
<Menu></Menu>
</div>
</template>
<
script
>
import
Vue
from
'vue'
;
...
...
@@ -162,9 +162,19 @@ export default {
* 导入
*/
importChange
()
{
this
.
dialogVisible
=
true
;
// 先重置所有状态
this
.
progress
=
0
;
this
.
uploading
=
false
;
// 清空上传列表
if
(
this
.
$refs
.
upload
)
{
this
.
$refs
.
upload
.
clearFiles
();
}
// 使用 nextTick 确保DOM更新后再显示对话框
this
.
$nextTick
(()
=>
{
this
.
dialogVisible
=
true
;
});
},
/**
* 上传文件之前的钩子
...
...
@@ -244,6 +254,14 @@ export default {
*/
handleSelectionChange
(
val
)
{
this
.
multipleSelection
=
val
;
},
handleDialogClosed
()
{
// 对话框关闭时清空
this
.
progress
=
0
;
this
.
uploading
=
false
;
if
(
this
.
$refs
.
upload
)
{
this
.
$refs
.
upload
.
clearFiles
();
}
}
},
components
:
{
...
...
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