Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
ops_2024_vue
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
Administrator
ops_2024_vue
Commits
53e45829
Commit
53e45829
authored
Apr 01, 2024
by
heduo
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'lmy' of
http://119.78.67.12/git/root/ops_2024_vue
into hd
parents
d9605614
50ca4ee0
Changes
5
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
1108 additions
and
916 deletions
+1108
-916
src/views/regionalSpotManage/components/addProduct.vue
src/views/regionalSpotManage/components/addProduct.vue
+395
-316
src/views/regionalSpotManage/components/list.vue
src/views/regionalSpotManage/components/list.vue
+620
-525
src/views/regionalSpotManage/components/upLoadTask.vue
src/views/regionalSpotManage/components/upLoadTask.vue
+74
-61
src/views/regionalSpotManage/taskCenter.vue
src/views/regionalSpotManage/taskCenter.vue
+12
-14
types/global.d.ts
types/global.d.ts
+7
-0
No files found.
src/views/regionalSpotManage/components/addProduct.vue
View file @
53e45829
This diff is collapsed.
Click to expand it.
src/views/regionalSpotManage/components/list.vue
View file @
53e45829
This diff is collapsed.
Click to expand it.
src/views/regionalSpotManage/components/upLoadTask.vue
View file @
53e45829
<
script
lang=
"ts"
setup
>
<
script
lang=
"ts"
setup
>
import
{
ref
,
onMounted
}
from
'
vue
'
;
import
{
ref
,
onMounted
}
from
'
vue
'
;
import
{
import
{
message
}
from
'
ant-design-vue
'
;
message
,
const
config
=
import
.
meta
.
env
;
}
from
'
ant-design-vue
'
;
import
{
const
config
=
import
.
meta
.
env
taskCenterQueryListApi
,
import
{
taskCenterRevokeExcelUploadApi
,
taskCenterQueryListApi
,
}
from
'
/@/api/regionalSpotManage
'
;
taskCenterRevokeExcelUploadApi
,
onMounted
(
async
()
=>
{
}
from
'
/@/api/regionalSpotManage
'
;
getList
();
onMounted
(
async
()
=>
{
});
getList
()
let
list
=
ref
<
any
[]
>
([]);
});
let
listLoading
=
ref
(
false
);
let
list
=
ref
<
any
[]
>
([])
const
downLoad
=
(
url
)
=>
{
let
listLoading
=
ref
(
false
)
window
.
open
(
config
.
VITE_GLOB_API_URL
+
'
/system/excelFile/
'
+
url
,
'
_blank
'
);
const
downLoad
=
(
url
)
=>
{
};
window
.
open
(
config
.
VITE_GLOB_API_URL
+
'
/system/excelFile/
'
+
url
,
'
_blank
'
)
const
downloadFail
=
(
record
)
=>
{
}
if
(
record
.
failNum
===
0
)
return
;
const
downloadFail
=
(
record
)
=>
{
let
href
=
if
(
record
.
failNum
===
0
)
return
config
.
VITE_GLOB_API_URL
+
let
href
=
config
.
VITE_GLOB_API_URL
+
'
/excel/excelNew/fail/download?sysid=
'
+
record
.
sysid
+
'
&type=
'
+
record
.
type
.
slice
(
2
,
6
)
'
/excel/excelNew/fail/download?sysid=
'
+
window
.
open
(
href
,
'
blank
'
)
record
.
sysid
+
}
'
&type=
'
+
const
cancel
=
async
(
record
)
=>
{
record
.
type
.
slice
(
2
,
6
);
const
param
=
ref
<
{
[
key
:
string
]:
any
}
>
({
window
.
open
(
href
,
'
blank
'
);
sysid
:
record
.
sysid
};
})
const
cancel
=
async
(
record
)
=>
{
const
res
=
await
taskCenterRevokeExcelUploadApi
(
param
.
value
)
const
param
=
ref
<
{
[
key
:
string
]:
any
}
>
({
if
(
res
.
code
===
20000
)
{
sysid
:
record
.
sysid
,
message
.
success
(
'
操作成功
'
)
});
getList
()
const
res
=
await
taskCenterRevokeExcelUploadApi
(
param
.
value
);
}
else
{
if
(
res
.
code
===
20000
)
{
message
.
error
(
res
.
message
)
message
.
success
(
'
操作成功
'
);
}
getList
();
}
}
else
{
const
getList
=
async
()
=>
{
message
.
error
(
res
.
message
);
listLoading
.
value
=
true
}
const
res
=
await
taskCenterQueryListApi
({
type
:
0
})
};
if
(
res
.
code
===
20000
)
{
const
getList
=
async
()
=>
{
list
.
value
=
res
.
data
listLoading
.
value
=
true
;
}
else
{
const
res
=
await
taskCenterQueryListApi
({
type
:
0
});
list
.
value
=
[]
if
(
res
.
code
===
20000
)
{
}
list
.
value
=
res
.
data
;
listLoading
.
value
=
false
}
else
{
}
list
.
value
=
[];
}
listLoading
.
value
=
false
;
};
</
script
>
</
script
>
<
template
>
<
template
>
<div>
<div>
<a-button
@
click=
"getList"
type=
"primary"
>
刷新数据
</a-button>
<a-button
@
click=
"getList"
type=
"primary"
>
刷新数据
</a-button>
</div>
</div>
<a-table
<a-table
:data-source=
"list"
:data-source=
"list"
:loading=
"listLoading"
:loading=
"listLoading"
bordered
bordered
:rowKey=
"(record) => record.sysid"
:rowKey=
"(record) => record.sysid"
style=
"margin-top: 15px"
style=
"margin-top: 15px"
>
>
<a-table-column
title=
"操作时间"
align=
"center"
:width=
"100"
>
<a-table-column
title=
"操作时间"
align=
"center"
:width=
"100"
>
<template
v-slot=
"
{record
}">
<template
#default
="
{ record
}">
{{
record
.
createTime
}}
{{
record
.
createTime
}}
</
template
>
</
template
>
</a-table-column>
</a-table-column>
<a-table-column
title=
"类型"
align=
"center"
:width=
"100"
>
<a-table-column
title=
"类型"
align=
"center"
:width=
"100"
>
<
template
v-slot=
"{record
}"
>
<
template
#default
="{
record
}"
>
{{
record
.
type
}}
{{
record
.
type
}}
</
template
>
</
template
>
</a-table-column>
</a-table-column>
<a-table-column
title=
"状态"
align=
"center"
:width=
"100"
>
<a-table-column
title=
"状态"
align=
"center"
:width=
"100"
>
<
template
v-slot=
"{record}"
>
<
template
#default
="{
record
}"
>
<p>
{{
record
.
isRevoke
?
'
已撤销
'
:
record
.
status
==
0
?
'
待进行
'
:(
record
.
status
==
1
?
'
进行中
'
:
'
已完成
'
)
}}
</p>
<p>
{{
record
.
isRevoke
?
'
已撤销
'
:
record
.
status
==
0
?
'
待进行
'
:
record
.
status
==
1
?
'
进行中
'
:
'
已完成
'
}}
</p>
</
template
>
</
template
>
</a-table-column>
</a-table-column>
<a-table-column
title=
"操作数据"
align=
"center"
:width=
"100"
>
<a-table-column
title=
"操作数据"
align=
"center"
:width=
"100"
>
<
template
v-slot=
"{record
}"
>
<
template
#default
="{
record
}"
>
{{
record
.
sproductNumpec
}}
{{
record
.
sproductNumpec
}}
</
template
>
</
template
>
</a-table-column>
</a-table-column>
<a-table-column
title=
"成功数据"
align=
"center"
:width=
"100"
>
<a-table-column
title=
"成功数据"
align=
"center"
:width=
"100"
>
<
template
v-slot=
"{record
}"
>
<
template
#default
="{
record
}"
>
{{
record
.
successNum
}}
{{
record
.
successNum
}}
</
template
>
</
template
>
</a-table-column>
</a-table-column>
<a-table-column
title=
"错误数据"
align=
"center"
:width=
"100"
>
<a-table-column
title=
"错误数据"
align=
"center"
:width=
"100"
>
<
template
v-slot=
"{record
}"
>
<
template
#default
="{
record
}"
>
{{
record
.
failNum
}}
{{
record
.
failNum
}}
</
template
>
</
template
>
</a-table-column>
</a-table-column>
<a-table-column
title=
"操作人"
align=
"center"
:width=
"100"
>
<a-table-column
title=
"操作人"
align=
"center"
:width=
"100"
>
<
template
v-slot=
"{record
}"
>
<
template
#default
="{
record
}"
>
{{
record
.
createName
}}
{{
record
.
createName
}}
</
template
>
</
template
>
</a-table-column>
</a-table-column>
<a-table-column
title=
"操作"
align=
"center"
:width=
"200"
>
<a-table-column
title=
"操作"
align=
"center"
:width=
"200"
>
<
template
v-slot=
"{record
}"
>
<
template
#default
="{
record
}"
>
<Button
type=
"link"
@
click=
"downLoad(record.fileUrl)"
>
下载源文件
</Button>
<Button
type=
"link"
@
click=
"downLoad(record.fileUrl)"
>
下载源文件
</Button>
<Button
type=
"link"
v-if=
"record.failNum"
@
click=
"downloadFail(record)"
>
下载错误数据
</Button>
<Button
type=
"link"
v-if=
"record.failNum"
@
click=
"downloadFail(record)"
<Button
type=
"link"
v-if=
"record.status == 0 && !record.isRevoke"
@
click=
"cancel(record)"
>
撤销
</Button>
>
下载错误数据
</Button
>
<Button
type=
"link"
v-if=
"record.status == 0 && !record.isRevoke"
@
click=
"cancel(record)"
>
撤销
</Button
>
</
template
>
</
template
>
</a-table-column>
</a-table-column>
</a-table>
</a-table>
</template>
</template>
<
style
lang=
"less"
scoped
>
<
style
lang=
"less"
scoped
></
style
>
</
style
>
src/views/regionalSpotManage/taskCenter.vue
View file @
53e45829
<
script
lang=
"ts"
setup
>
<
script
lang=
"ts"
setup
>
import
{
ref
}
from
'
vue
'
;
import
{
ref
}
from
'
vue
'
;
import
uploadTask
from
'
./components/upLoadTask.vue
'
import
uploadTask
from
'
./components/upLoadTask.vue
'
;
import
downLoadTask
from
'
./components/downLoadTask.vue
'
import
downLoadTask
from
'
./components/downLoadTask.vue
'
;
import
platformProBatch
from
'
./components/platformProBatch.vue
'
import
platformProBatch
from
'
./components/platformProBatch.vue
'
;
const
activeKey
=
ref
(
'
1
'
)
const
activeKey
=
ref
(
'
1
'
);
const
callback
=
(
val
)
=>
{
const
callback
=
(
val
)
=>
{
activeKey
.
value
=
val
activeKey
.
value
=
val
;
}
};
</
script
>
</
script
>
<
template
>
<
template
>
<a-tabs
@
change=
"callback"
v-model:activeKey=
"activeKey"
>
<a-tabs
@
change=
"callback"
v-model:activeKey=
"activeKey"
>
<a-tab-pane
key=
"1"
tab=
"上传任务数据"
>
<a-tab-pane
key=
"1"
tab=
"上传任务数据"
>
<uploadTask
v-if=
"activeKey === '1'"
></uploadTask
>
<uploadTask
v-if=
"activeKey === '1'"
/
>
</a-tab-pane>
</a-tab-pane>
<a-tab-pane
key=
"2"
tab=
"下载任务数据"
force-render
>
<a-tab-pane
key=
"2"
tab=
"下载任务数据"
force-render
>
<downLoadTask
v-if=
"activeKey === '2'"
></downLoadTask
>
<downLoadTask
v-if=
"activeKey === '2'"
/
>
</a-tab-pane>
</a-tab-pane>
<a-tab-pane
key=
"3"
tab=
"平台商品批量"
>
<a-tab-pane
key=
"3"
tab=
"平台商品批量"
>
<platformProBatch
v-if=
"activeKey === '3'"
></platformProBatch
>
<platformProBatch
v-if=
"activeKey === '3'"
/
>
</a-tab-pane>
</a-tab-pane>
</a-tabs>
</a-tabs>
</
template
>
</
template
>
<
style
lang=
"less"
scoped
>
<
style
lang=
"less"
scoped
></
style
>
</
style
>
types/global.d.ts
View file @
53e45829
...
@@ -52,6 +52,13 @@ declare global {
...
@@ -52,6 +52,13 @@ declare global {
declare
interface
WheelEvent
{
declare
interface
WheelEvent
{
path
?:
EventTarget
[];
path
?:
EventTarget
[];
}
}
interface
ImportMeta
{
env
:
{
VITE_GLOB_API_URL
?:
string
;
};
}
interface
ImportMetaEnv
extends
ViteEnv
{
interface
ImportMetaEnv
extends
ViteEnv
{
__
:
unknown
;
__
:
unknown
;
}
}
...
...
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