Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit9a55c69

Browse files
committed
when not editable, not show 'delete' button
1 parentd95c0c5 commit9a55c69

File tree

1 file changed

+19
-15
lines changed

1 file changed

+19
-15
lines changed

‎uliweb_apijson/apijson/templates/vue/inc_apijson_table.html

Lines changed: 19 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,19 @@
3838
"action":{
3939
title:'Action',
4040
width:140,
41-
render:(h,params)=>{
42-
returnh('div',[
41+
render:function(h,params){
42+
vardelete_button=h('Button',{
43+
props:{
44+
type:'error',
45+
size:'small'
46+
},
47+
on:{
48+
click:function(){
49+
thisp.remove(params)
50+
}
51+
}
52+
},'Delete')
53+
varbuttons=[
4354
h('Button',{
4455
props:{
4556
type:'primary',
@@ -53,19 +64,12 @@
5364
thisp.show(params)
5465
}
5566
}
56-
},this.viewedit_label),
57-
h('Button',{
58-
props:{
59-
type:'error',
60-
size:'small'
61-
},
62-
on:{
63-
click:function(){
64-
thisp.remove(params)
65-
}
66-
}
67-
},'Delete')
68-
]);
67+
},thisp.viewedit_label)
68+
]
69+
if(thisp.config_editable){
70+
buttons.push(delete_button)
71+
}
72+
returnh('div',buttons);
6973
}
7074
}
7175
},

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp