Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
SuperMan
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
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
罗超
SuperMan
Commits
b47c16e1
Commit
b47c16e1
authored
Feb 10, 2023
by
罗超
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
地区管理优化
parent
cc89c85b
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
43 additions
and
15 deletions
+43
-15
WebSiteArea.vue
src/components/WebSet/WebSiteArea.vue
+41
-11
uploadImg.vue
src/pubComponents/uploadImg.vue
+2
-4
No files found.
src/components/WebSet/WebSiteArea.vue
View file @
b47c16e1
...
...
@@ -76,6 +76,17 @@
</el-table-column>
<el-table-column
prop=
"ParentName"
label=
"上级名称"
header-align=
"center"
align=
"center"
>
</el-table-column>
<el-table-column
prop=
"ParentName"
label=
"目的地"
header-align=
"center"
align=
"center"
>
<template
slot-scope=
"scope"
>
<span>
{{
getAreaShow
(
scope
)
}}
</span>
</
template
>
</el-table-column>
<el-table-column
prop=
"ParentName"
label=
"封面图"
header-align=
"center"
align=
"center"
>
<
template
slot-scope=
"scope"
>
<i
class=
"el-icon-time"
></i>
<span
style=
"margin-left: 10px"
>
{{
scope
.
row
.
date
}}
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"操作"
header-align=
"center"
align=
"center"
>
<
template
slot-scope=
"scope"
>
<el-tooltip
class=
"item"
effect=
"dark"
:content=
"$t('system.table_edit')"
placement=
"top-start"
>
...
...
@@ -250,9 +261,11 @@ import uploadImg from '../../pubComponents/uploadImg'
this
.
financeinfo_post_GetList
()
},
methods
:
{
getAreaShow
(
scope
)
{
return
scope
.
row
.
DestinationList
?
scope
.
row
.
DestinationList
.
map
(
item
=>
item
.
Name
).
join
(
','
)
:
''
},
areaLevelChange
()
{
const
level
=
this
.
addMsg
.
Level
;
this
.
level
=
level
if
(
level
===
1
)
{
this
.
showAddArea
=
false
this
.
addMsg
.
DestinationList
=
[]
...
...
@@ -323,10 +336,19 @@ import uploadImg from '../../pubComponents/uploadImg'
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
var
tempData
=
res
.
data
.
data
;
this
.
addMsg
.
Id
=
tempData
.
Id
;
this
.
addMsg
.
Level
=
tempData
.
Level
;
this
.
addMsg
.
ParentId
=
tempData
.
ParentId
;
this
.
addMsg
.
AreaName
=
tempData
.
AreaName
;
this
.
addMsg
=
tempData
;
// this.addMsg.Id = tempData.Id;
// this.addMsg.Level = tempData.Level;
// this.addMsg.ParentId = tempData.ParentId;
// this.addMsg.AreaName = tempData.AreaName;
if
(
!
this
.
addMsg
.
BestTravelTimeList
||
!
this
.
addMsg
.
BestTravelTimeList
.
length
)
{
this
.
addMsg
.
BestTravelTimeList
=
[{
Month
:
''
,
Description
:
''
}]
}
this
.
areaLevelChange
()
this
.
$refs
.
uploadImg
.
ImageList
=
tempData
.
ImageList
||
[]
}
else
{
this
.
Error
(
res
.
data
.
message
);
}
...
...
@@ -356,10 +378,18 @@ import uploadImg from '../../pubComponents/uploadImg'
},
//清空数据
clearMsg
()
{
this
.
addMsg
.
Id
=
0
;
this
.
addMsg
.
Level
=
0
;
this
.
addMsg
.
ParentId
=
0
;
this
.
addMsg
.
AreaName
=
""
;
this
.
addMsg
=
{
Id
:
0
,
//编号
Level
:
0
,
//等级
ParentId
:
0
,
//父节点编号
AreaName
:
''
,
//名称
BestTravelTimeList
:
[{
Month
:
''
,
Description
:
''
}],
DestinationList
:
[],
}
this
.
$refs
.
uploadImg
.
ImageList
=
[]
},
//新增、修改广告
submitForm
(
formName
)
{
...
...
@@ -371,7 +401,7 @@ import uploadImg from '../../pubComponents/uploadImg'
this
.
$message
.
error
(
'请上传图片!'
);
return
}
if
(
this
.
l
evel
!==
1
&&
!
this
.
addMsg
.
DestinationList
.
length
)
{
if
(
this
.
addMsg
.
L
evel
!==
1
&&
!
this
.
addMsg
.
DestinationList
.
length
)
{
this
.
$message
.
error
(
'请添加目的地!'
);
return
}
...
...
@@ -412,7 +442,7 @@ import uploadImg from '../../pubComponents/uploadImg'
this
.
areaVisible
=
true
}
else
{
this
.
addMsg
.
DestinationList
.
splice
(
index
,
1
)
if
(
this
.
l
evel
===
2
&&
this
.
addMsg
.
DestinationList
.
length
<
1
)
{
if
(
this
.
addMsg
.
L
evel
===
2
&&
this
.
addMsg
.
DestinationList
.
length
<
1
)
{
this
.
showAddArea
=
true
}
}
...
...
src/pubComponents/uploadImg.vue
View file @
b47c16e1
...
...
@@ -17,9 +17,7 @@
</div>
</div>
</div>
</div>
<div
class=
"add-img"
>
<div
class=
"reimg-add"
>
<div><div
class=
"reimg-add"
>
<i
class=
"iconfont icon-img_haha bigAdd"
></i>
<div
class=
"ad-one"
>
<div
class=
"re-upload"
>
...
...
@@ -31,7 +29,7 @@
<!-- 选择系统图片 -->
<!--
<div
class=
"re-find"
@
click=
"addImgOpen"
><i
class=
"iconfont icon-img_cz"
></i></div>
-->
</div>
</div>
</div>
</div>
</div>
</div>
<!--
<el-upload
class=
"upload-demo"
:http-request=
"UploadImage"
:multiple=
"false"
...
...
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