Skip to content
Browse files

MINOR: changing order of save and delete buttons so that they are con…

…sistent
  • Loading branch information...
1 parent 4590436 commit 13c7c01b954117468f9cd91a1b1dc99350221989 @candidasa candidasa committed
Showing with 6 additions and 6 deletions.
  1. +6 −6 admin/code/LeftAndMain.php
View
12 admin/code/LeftAndMain.php
@@ -876,18 +876,18 @@ public function getEditForm($id = null, $fields = null) {
$actions = $record->getCMSActions();
// add default actions if none are defined
if(!$actions || !$actions->Count()) {
- if($record->hasMethod('canDelete') && $record->canDelete()) {
- $actions->push(
- FormAction::create('delete',_t('ModelAdmin.DELETE','Delete'))
- ->addExtraClass('ss-ui-action-destructive')
- );
- }
if($record->hasMethod('canEdit') && $record->canEdit()) {
$actions->push(
FormAction::create('save',_t('CMSMain.SAVE','Save'))
->addExtraClass('ss-ui-action-constructive')->setAttribute('data-icon', 'accept')
);
}
+ if($record->hasMethod('canDelete') && $record->canDelete()) {
+ $actions->push(
+ FormAction::create('delete',_t('ModelAdmin.DELETE','Delete'))
+ ->addExtraClass('ss-ui-action-destructive')
+ );
+ }
}
}

0 comments on commit 13c7c01

Please sign in to comment.
Something went wrong with that request. Please try again.