Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
apaas-ui
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
gzga-jzapi
apaas-ui
Commits
8a26a769
Commit
8a26a769
authored
May 06, 2020
by
徐一鸣
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
服务管理编辑提示
parent
f5cd5d52
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
137 additions
and
9 deletions
+137
-9
src/components/dialog-action.vue
src/components/dialog-action.vue
+98
-0
src/components/table-um.vue
src/components/table-um.vue
+1
-1
src/pages/fwgl.vue
src/pages/fwgl.vue
+1
-1
src/pages/fwglList.vue
src/pages/fwglList.vue
+37
-7
No files found.
src/components/dialog-action.vue
0 → 100644
View file @
8a26a769
<
template
>
<transition
name=
"mask-bg-fade"
>
<el-dialog
:visible.sync=
"show"
width=
"400px"
top=
"25vh"
class=
"user-dialog"
>
<span
slot=
"title"
>
<b
class=
"iconLeft"
></b>
<span
style=
" display: inline-block;vertical-align: middle;"
>
{{
confirmOptions
.
title
||
"
提示
"
}}
</span>
</span>
<span>
{{
confirmOptions
.
message
||
""
}}
</span>
<span
slot=
"footer"
class=
"dialog-footer"
>
<el-button
class=
"form_c"
type=
"defalut"
size=
"mini"
@
click=
"hideModel"
>
{{
confirmOptions
.
btnCancelText
||
"
取消
"
}}
</el-button
>
<el-button
class=
"form_t"
type=
"primary"
size=
"mini"
@
click=
"confirmSubmit"
>
{{
confirmOptions
.
btnSubmitText
||
"
确定
"
}}
</el-button
>
</span>
</el-dialog>
</transition>
</
template
>
<
script
>
export
default
{
name
:
"
dialogAction
"
,
props
:
{
confirmOptions
:
{
type
:
Object
,
default
:
()
=>
({}),
},
},
data
()
{
return
{
show
:
false
,
};
},
methods
:
{
showModel
()
{
this
.
show
=
true
;
},
hideModel
()
{
this
.
show
=
false
;
},
confirmSubmit
()
{
typeof
this
.
confirmOptions
.
confirmSubmit
===
"
function
"
&&
this
.
confirmOptions
.
confirmSubmit
();
},
},
};
</
script
>
<
style
>
.el-dialog__header
{
border-bottom
:
1px
solid
#edf0ff
;
padding
:
20px
20px
16px
!important
;
font-family
:
"MicrosoftYaHei"
;
font-size
:
16px
;
color
:
#1d1e20
;
font-weight
:
800
;
}
.el-dialog__header
.iconLeft
{
width
:
4px
;
height
:
16px
;
background-color
:
#0367f6
;
border-radius
:
2px
;
display
:
inline-block
;
vertical-align
:
middle
;
margin-right
:
3px
;
}
.el-icon-close
:before
{
font-weight
:
800
!important
;
}
.el-dialog__body
{
padding
:
49px
20px
!important
;
}
</
style
>
<
style
scoped
>
.group-dialog.el-dialog__wrapper
{
width
:
100%
!important
;
left
:
0
!important
;
overflow
:
hidden
;
}
.user-dialog
{
overflow
:
hidden
;
}
</
style
>
src/components/table-um.vue
View file @
8a26a769
...
@@ -116,7 +116,7 @@
...
@@ -116,7 +116,7 @@
<b
v-for=
"(btn, key) in item.btnList"
:key=
"key"
>
<b
v-for=
"(btn, key) in item.btnList"
:key=
"key"
>
<em
<em
:class=
"btn.type"
:class=
"btn.type"
style=
"color: #0f2683
"
:style=
"
{color: btn.label=='删除' ? '#830f53' : '#0f2683'}
"
@click="handleClick(btn.type, scope.row)"
@click="handleClick(btn.type, scope.row)"
>
{{
btn
.
label
}}
</em>
>
{{
btn
.
label
}}
</em>
<em
v-if=
"btn.line"
style=
"padding:0 20px;color:#edf0ff"
>
{{
btn
.
line
}}
</em>
<em
v-if=
"btn.line"
style=
"padding:0 20px;color:#edf0ff"
>
{{
btn
.
line
}}
</em>
...
...
src/pages/fwgl.vue
View file @
8a26a769
...
@@ -75,7 +75,7 @@ export default {
...
@@ -75,7 +75,7 @@ export default {
name
:
"
云资源管理
"
,
name
:
"
云资源管理
"
,
path
:
"
/fwgl/list/9/云资源管理
"
,
path
:
"
/fwgl/list/9/云资源管理
"
,
},
},
]
.
filter
((
nav
)
=>
nav
.
level
===
this
.
userLevel
)
;
];
this
.
$router
.
push
(
this
.
navList
[
0
].
path
);
this
.
$router
.
push
(
this
.
navList
[
0
].
path
);
},
},
...
...
src/pages/fwglList.vue
View file @
8a26a769
...
@@ -13,9 +13,8 @@
...
@@ -13,9 +13,8 @@
url=
"tableData"
url=
"tableData"
:searchShow=
"true"
:searchShow=
"true"
:autoAdd=
"false"
:autoAdd=
"false"
:isDialog=
"true"
:confirmOptions=
"confirmOptions"
detailsUrl=
"/fwgl/servicedetail/"
detailsUrl=
"/fwgl/servicedetail/"
@
primary-del=
"deleteItem"
@
primary-edit=
"editItem"
@
primary-edit=
"editItem"
@
sold-out=
"soldOutItem"
@
sold-out=
"soldOutItem"
:emptyText=
"emptyText"
:emptyText=
"emptyText"
...
@@ -24,21 +23,28 @@
...
@@ -24,21 +23,28 @@
:filterList=
"filterList"
:filterList=
"filterList"
></ces-table>
></ces-table>
</div>
</div>
<dialog-action
ref=
"myConfirm"
:confirm-options=
"confirmOptions"
></dialog-action>
</div>
</div>
</
template
>
</
template
>
<
script
>
<
script
>
import
cesTable
from
"
@/components/table-um
"
;
import
cesTable
from
"
@/components/table-um
"
;
import
dialogAction
from
"
@/components/dialog-action
"
;
export
default
{
export
default
{
data
:
()
=>
({
data
:
()
=>
({
headers
:
[],
headers
:
[],
url
:
""
,
url
:
""
,
detailsUrl
:
"
ss/
"
,
detailsUrl
:
"
ss/
"
,
confirmOptions
:
{
confirmOptions
:
{
title
:
"
提示
"
,
//提示
title
:
""
,
message
:
"
确认删除该条数据?
"
,
//""
message
:
""
,
btnCancelText
:
"
取消
"
,
//取消
btnCancelText
:
""
,
btnSubmitText
:
"
确定
"
,
//确定
btnSubmitText
:
""
,
item
:
null
,
},
},
emptyText
:
"
暂时没数据
"
,
emptyText
:
"
暂时没数据
"
,
filterList
:
[
filterList
:
[
...
@@ -79,13 +85,37 @@ export default {
...
@@ -79,13 +85,37 @@ export default {
}),
}),
components
:
{
components
:
{
cesTable
,
cesTable
,
dialogAction
,
},
},
methods
:
{
methods
:
{
deleteItem
(
item
)
{
this
.
confirmOptions
.
title
=
""
;
this
.
confirmOptions
.
message
=
"
是否删除该条服务?
"
;
this
.
confirmOptions
.
btnCancelText
=
""
;
this
.
confirmOptions
.
btnSubmitText
=
""
;
this
.
confirmOptions
.
confirmSubmit
=
()
=>
{
console
.
log
(
"
deleteItem -
"
+
item
.
name
);
this
.
$refs
.
myConfirm
.
hideModel
();
};
this
.
$refs
.
myConfirm
.
showModel
();
},
editItem
(
item
)
{
editItem
(
item
)
{
this
.
$router
.
push
(
"
/fwgl/serviceedit/
"
+
item
.
id
);
this
.
$router
.
push
(
"
/fwgl/serviceedit/
"
+
item
.
id
);
},
},
soldOutItem
(
item
)
{
soldOutItem
(
item
)
{
console
.
log
(
item
);
this
.
confirmOptions
.
title
=
"
是否删除该条服务?
"
;
this
.
confirmOptions
.
message
=
"
下架此服务会导致用户被迫暂停对服务的调用,下架前需向超级管理员发送通知,超级管理员通过后此服务将会从服务超市中下架。
"
;
this
.
confirmOptions
.
btnCancelText
=
""
;
this
.
confirmOptions
.
btnSubmitText
=
"
发送通知
"
;
this
.
confirmOptions
.
confirmSubmit
=
()
=>
{
console
.
log
(
"
soldOutItem -
"
+
item
.
name
);
this
.
$refs
.
myConfirm
.
hideModel
();
};
this
.
$refs
.
myConfirm
.
showModel
();
},
confirmSubmit
(
item
)
{
console
.
log
(
item
.
name
);
},
},
},
},
mounted
()
{
mounted
()
{
...
...
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