mirror of
https://github.com/silverstripe/silverstripe-comments
synced 2024-10-22 11:05:49 +02:00
Prevented duplicate IDs on action buttons
This commit is contained in:
parent
4d538f565c
commit
671766364b
@ -44,7 +44,7 @@ class CommentsGridFieldAction implements GridField_ColumnProvider, GridField_Act
|
|||||||
if(!$record->IsSpam || !$record->Moderated) {
|
if(!$record->IsSpam || !$record->Moderated) {
|
||||||
$field .= GridField_FormAction::create(
|
$field .= GridField_FormAction::create(
|
||||||
$gridField,
|
$gridField,
|
||||||
'CustomAction' . $record->ID,
|
'CustomAction' . $record->ID . 'Spam',
|
||||||
'Spam',
|
'Spam',
|
||||||
'spam',
|
'spam',
|
||||||
array('RecordID' => $record->ID)
|
array('RecordID' => $record->ID)
|
||||||
@ -54,7 +54,7 @@ class CommentsGridFieldAction implements GridField_ColumnProvider, GridField_Act
|
|||||||
if($record->IsSpam || !$record->Moderated) {
|
if($record->IsSpam || !$record->Moderated) {
|
||||||
$field .= GridField_FormAction::create(
|
$field .= GridField_FormAction::create(
|
||||||
$gridField,
|
$gridField,
|
||||||
'CustomAction' . $record->ID,
|
'CustomAction' . $record->ID . 'Approve',
|
||||||
'Approve',
|
'Approve',
|
||||||
'approve',
|
'approve',
|
||||||
array('RecordID' => $record->ID)
|
array('RecordID' => $record->ID)
|
||||||
@ -97,4 +97,4 @@ class CommentsGridFieldAction implements GridField_ColumnProvider, GridField_Act
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user