From 80d62badd3be4323b287c2858287cca3727a507c Mon Sep 17 00:00:00 2001 From: Eileen McNaughton Date: Tue, 12 Sep 2023 13:45:35 +1200 Subject: [PATCH] Fix weight notices on ActivityType (option values) pages --- CRM/Admin/Page/Options.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/CRM/Admin/Page/Options.php b/CRM/Admin/Page/Options.php index 93f30fc18f..19954130e2 100644 --- a/CRM/Admin/Page/Options.php +++ b/CRM/Admin/Page/Options.php @@ -157,26 +157,30 @@ class CRM_Admin_Page_Options extends CRM_Core_Page_Basic { 'url' => 'civicrm/admin/options/' . self::$_gName, 'qs' => 'action=update&id=%%id%%&reset=1', 'title' => ts('Edit %1', [1 => self::$_gName]), + 'weight' => CRM_Core_Action::getWeight(CRM_Core_Action::UPDATE), ], CRM_Core_Action::DISABLE => [ 'name' => ts('Disable'), 'ref' => 'crm-enable-disable', 'title' => ts('Disable %1', [1 => self::$_gName]), + 'weight' => CRM_Core_Action::getWeight(CRM_Core_Action::DISABLE), ], CRM_Core_Action::ENABLE => [ 'name' => ts('Enable'), 'ref' => 'crm-enable-disable', 'title' => ts('Enable %1', [1 => self::$_gName]), + 'weight' => CRM_Core_Action::getWeight(CRM_Core_Action::ENABLE), ], CRM_Core_Action::DELETE => [ 'name' => ts('Delete'), 'url' => 'civicrm/admin/options/' . self::$_gName, 'qs' => 'action=delete&id=%%id%%', 'title' => ts('Delete %1 Type', [1 => self::$_gName]), + 'weight' => CRM_Core_Action::getWeight(CRM_Core_Action::DELETE), ], ]; - if (self::$_gName == 'custom_search') { + if (self::$_gName === 'custom_search') { $runLink = [ CRM_Core_Action::FOLLOWUP => [ 'name' => ts('Run'), @@ -184,6 +188,7 @@ class CRM_Admin_Page_Options extends CRM_Core_Page_Basic { 'qs' => 'reset=1&csid=%%value%%', 'title' => ts('Run %1', [1 => self::$_gName]), 'class' => 'no-popup', + 'weight' => 10, ], ]; self::$_links = $runLink + self::$_links; -- 2.25.1