* Code for projectadmin btn.

This commit is contained in:
sunguangming
2023-08-03 13:11:23 +08:00
parent 43e1e16a59
commit 9ae302ade5
2 changed files with 11 additions and 4 deletions
+2
View File
@@ -65,6 +65,8 @@ function addItem(e)
function deleteItem(e)
{
if($("table tr").length == 5) return false;
let currentClass = $(e.target).closest('tr').attr('class');
$(e.target).closest('table').find('tr.' + currentClass).remove();
}
+9 -4
View File
@@ -101,7 +101,7 @@ if($projectAdmins)
set::rowspan($rowspan),
btnGroup
(
$i > 1 ? set::items
set::items
(
array
(
@@ -109,8 +109,6 @@ if($projectAdmins)
array('icon' => 'trash', 'class' => 'btn ghost btn-delete')
)
)
:
set::items(array(array('icon' => 'plus', 'class' => 'btn ghost btn-add'))),
)
)
);
@@ -281,7 +279,14 @@ else
set::rowspan($rowspan),
btnGroup
(
set::items(array(array('icon' => 'plus', 'class' => 'btn ghost btn-add')))
set::items
(
array
(
array('icon' => 'plus', 'class' => 'btn ghost btn-add'),
array('icon' => 'trash', 'class' => 'btn ghost btn-delete')
)
)
)
)
);