From 87d9efba5e04a4c55eee39ba4860b92a091f176c Mon Sep 17 00:00:00 2001 From: Pradeep Nayak Date: Tue, 5 Dec 2023 23:49:21 +0000 Subject: [PATCH] Change URL for edit/create/delete SMS provider to support Searchkit admin ui over-ride --- CRM/Core/xml/Menu/Admin.xml | 11 ++++++++++- CRM/SMS/DAO/Provider.php | 9 +++++---- CRM/SMS/Form/Provider.php | 2 +- xml/schema/SMS/Provider.xml | 7 ++++--- 4 files changed, 20 insertions(+), 9 deletions(-) diff --git a/CRM/Core/xml/Menu/Admin.xml b/CRM/Core/xml/Menu/Admin.xml index 93ecf39477..419f08166f 100644 --- a/CRM/Core/xml/Menu/Admin.xml +++ b/CRM/Core/xml/Menu/Admin.xml @@ -718,7 +718,16 @@ System Settings 500 - + + civicrm/admin/sms/provider/edit + Sms Providers + To configure a sms provider + CRM_SMS_Form_Provider + administer CiviCRM + System Settings + 501 + + civicrm/sms/send New Mass SMS CRM_SMS_Controller_Send diff --git a/CRM/SMS/DAO/Provider.php b/CRM/SMS/DAO/Provider.php index 3be708e169..5225f0590b 100644 --- a/CRM/SMS/DAO/Provider.php +++ b/CRM/SMS/DAO/Provider.php @@ -6,7 +6,7 @@ * * Generated from xml/schema/CRM/SMS/Provider.xml * DO NOT EDIT. Generated by CRM_Core_CodeGen - * (GenCodeChecksum:ea1cbd7f1f11e5665fff00358476e535) + * (GenCodeChecksum:2d570203bb9be927ba5276f3c2043d45) */ /** @@ -43,9 +43,10 @@ class CRM_SMS_DAO_Provider extends CRM_Core_DAO { * @var string[] */ protected static $_paths = [ - 'add' => 'civicrm/admin/sms/provider?reset=1&action=add', - 'delete' => 'civicrm/admin/sms/provider?reset=1&action=delete&id=[id]', - 'update' => 'civicrm/admin/sms/provider?reset=1&action=update&id=[id]', + 'add' => 'civicrm/admin/sms/provider/edit?reset=1&action=add', + 'delete' => 'civicrm/admin/sms/provider/edit?reset=1&action=delete&id=[id]', + 'update' => 'civicrm/admin/sms/provider/edit?reset=1&action=update&id=[id]', + 'browse' => 'civicrm/admin/sms/provider?reset=1', ]; /** diff --git a/CRM/SMS/Form/Provider.php b/CRM/SMS/Form/Provider.php index 602f0e6847..baa9b86791 100644 --- a/CRM/SMS/Form/Provider.php +++ b/CRM/SMS/Form/Provider.php @@ -28,7 +28,7 @@ class CRM_SMS_Form_Provider extends CRM_Core_Form { public function preProcess() { - $this->_id = $this->get('id'); + $this->_id = CRM_Utils_Request::retrieve('id', 'Integer', $this); $this->setPageTitle(ts('SMS Provider')); diff --git a/xml/schema/SMS/Provider.xml b/xml/schema/SMS/Provider.xml index ad9e39f81a..c9df774a45 100644 --- a/xml/schema/SMS/Provider.xml +++ b/xml/schema/SMS/Provider.xml @@ -7,9 +7,10 @@ Table to add different sms providers 4.2 - civicrm/admin/sms/provider?reset=1&action=add - civicrm/admin/sms/provider?reset=1&action=delete&id=[id] - civicrm/admin/sms/provider?reset=1&action=update&id=[id] + civicrm/admin/sms/provider/edit?reset=1&action=add + civicrm/admin/sms/provider/edit?reset=1&action=delete&id=[id] + civicrm/admin/sms/provider/edit?reset=1&action=update&id=[id] + civicrm/admin/sms/provider?reset=1 SMS Provider -- 2.25.1