Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gxpt_web
Overview
Overview
Details
Activity
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
pseer
gxpt_web
Commits
7bd16f7c
Commit
7bd16f7c
authored
Nov 01, 2023
by
吕明尚
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
更改套餐列表,房间列表
parent
4dac456e
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
32 additions
and
11 deletions
+32
-11
index.vue
src/views/system/pack/index.vue
+8
-7
index.vue
src/views/system/room/index.vue
+24
-4
No files found.
src/views/system/pack/index.vue
View file @
7bd16f7c
...
...
@@ -298,19 +298,20 @@ export default {
},
/** 删除按钮操作 */
handleDelete
(
row
)
{
let
name
;
const
ids
=
row
.
id
||
this
.
ids
;
this
.
getRoomPackList
(
ids
);
var
roomId
=
roomPackList
[
0
].
roomId
;
getRoom
(
roomId
).
then
(
response
=>
{
name
=
response
.
data
.
name
;
this
.
$modal
.
confirm
(
"当前套餐下有"
+
name
+
"房间,请确认删除"
).
then
((
result
)
=>
{
getRoomPack
(
row
.
id
).
then
(
response
=>
{
let
roomnNameStr
=
`是否确认删除
${
row
.
name
}
的数据?`
if
(
response
.
data
.
length
>
0
){
let
str
=
response
.
data
.
map
(
item
=>
item
.
roomName
).
join
(
"、"
)
roomnNameStr
=
`是否确认删除
${
row
.
name
}
数据及其关联的房间
${
str
}
下的绑定套餐?`
}
this
.
$modal
.
confirm
(
roomnNameStr
).
then
((
result
)
=>
{
return
delPack
(
ids
);
}).
then
(()
=>
{
this
.
getList
();
this
.
$modal
.
msgSuccess
(
"删除成功"
);
}).
catch
(()
=>
{});
});
},
/** 导出按钮操作 */
handleExport
()
{
...
...
src/views/system/room/index.vue
View file @
7bd16f7c
...
...
@@ -129,7 +129,7 @@
<el-table-column
label=
"套餐"
align=
"center"
prop=
"packIds"
>
<
template
slot-scope=
"scope"
>
<div
v-if=
"scope.row.packIds"
style=
"display: flex;flex-wrap: wrap;width: 100%;"
>
<dict-tag
style=
"margin: 0 3px;"
v-for=
"(item ,k) in
packList"
:key=
"k"
:options=
"packIds"
:value=
"item.name+'-'+'时段'+item.packaStartPeriod+'-'+item.packaEndPeriod
"
/>
<dict-tag
style=
"margin: 0 3px;"
v-for=
"(item ,k) in
scope.row.packIds"
:key=
"k"
:options=
"packList"
:value=
"item
"
/>
</div>
</
template
>
</el-table-column>
...
...
@@ -300,7 +300,10 @@ export default {
created
()
{
this
.
onGetAllStoreList
()
this
.
onPackList
()
this
.
getList
();
},
mounted
()
{
console
.
log
(
this
.
dict
)
},
methods
:
{
onChange
(
e
){
...
...
@@ -318,7 +321,23 @@ export default {
},
onPackList
(){
query
().
then
(
res
=>
{
this
.
packList
=
res
.
data
this
.
packList
=
res
.
data
.
map
(
obj
=>
{
return
{
...
obj
,
raw
:{
dictSort
:
1
,
dictValue
:
"1"
,
listClass
:
"primary"
,
cssClass
:
''
},
value
:
obj
.
id
.
toString
(),
label
:
obj
.
name
,
}
})
console
.
log
(
this
.
packList
,
9090999
)
this
.
getList
();
})
},
...
...
@@ -329,7 +348,8 @@ export default {
this
.
roomList
=
response
.
rows
.
map
(
item
=>
{
return
{
...
item
,
facilities
:
item
.
facilities
?
item
.
facilities
.
split
(
","
):
[]
facilities
:
item
.
facilities
?
item
.
facilities
.
split
(
","
):
[],
packIds
:
item
.
packIds
?
item
.
packIds
.
split
(
","
):
[]
}
});
this
.
total
=
response
.
total
;
...
...
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