From b7d8471187c727939bf68a1dce4a7496d9f909cb Mon Sep 17 00:00:00 2001 From: ankush_m <ankush_m@techjoomla.com> Date: Wed, 10 Aug 2022 12:42:40 +0530 Subject: [PATCH 01/12] Bug #187003 fix: Unable to send notification due to fatel error --- src/com_tjnotifications/admin/models/notifications.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/com_tjnotifications/admin/models/notifications.php b/src/com_tjnotifications/admin/models/notifications.php index 57854a6a..43730460 100644 --- a/src/com_tjnotifications/admin/models/notifications.php +++ b/src/com_tjnotifications/admin/models/notifications.php @@ -273,7 +273,7 @@ public function getItems() * * @since 1.6 */ - public function getTemplate($client, $key, $language, $backend = 'email') + public function getTemplate($client, $key, $language = '*', $backend = 'email') { $object = clone $this; From 7d2daa8127663b8d977d83f3968599f4560eabe7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E2=80=9CSachin?= <sachin_s@techjoomla.com> Date: Wed, 16 Nov 2022 11:47:14 +0530 Subject: [PATCH 02/12] Bug #190354 Fixed: BE> Notification Templates> Limit filters not working --- src/com_tjnotifications/admin/models/notifications.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/com_tjnotifications/admin/models/notifications.php b/src/com_tjnotifications/admin/models/notifications.php index 43730460..892288f7 100644 --- a/src/com_tjnotifications/admin/models/notifications.php +++ b/src/com_tjnotifications/admin/models/notifications.php @@ -86,6 +86,12 @@ protected function populateState($ordering = 'id', $direction = 'asc') // Get pagination request variables $limit = $app->getUserStateFromRequest('global.list.limit', 'limit', $app->get('list_limit'), 'int'); + $list = $app->input->get('list'); + if (isset($list['limit']) && $list['limit']) + { + $limit = $list['limit']; + } + $limitstart = $app->input->get('limitstart', 0, 'int'); // In case limit has been changed, adjust it From 0e6f9c4b4101c436b16ad57415bc53cf332bd88e Mon Sep 17 00:00:00 2001 From: ankush_m <ankush_m@techjoomla.com> Date: Wed, 16 Nov 2022 15:48:06 +0530 Subject: [PATCH 03/12] Bug #190387 fix: page limit is not working on notifications list view --- src/com_tjnotifications/admin/models/notifications.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/com_tjnotifications/admin/models/notifications.php b/src/com_tjnotifications/admin/models/notifications.php index 43730460..bafd70a1 100644 --- a/src/com_tjnotifications/admin/models/notifications.php +++ b/src/com_tjnotifications/admin/models/notifications.php @@ -85,7 +85,7 @@ protected function populateState($ordering = 'id', $direction = 'asc') parent::populateState($ordering, $direction); // Get pagination request variables - $limit = $app->getUserStateFromRequest('global.list.limit', 'limit', $app->get('list_limit'), 'int'); + $limit = $app->getUserStateFromRequest($this->context . '.list.limit', 'limit', $app->get('list_limit'), 'int'); $limitstart = $app->input->get('limitstart', 0, 'int'); // In case limit has been changed, adjust it From 7963b1378c824e3a3ce221977bae3984ad37edaf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E2=80=9CSachin?= <sachin_s@techjoomla.com> Date: Thu, 17 Nov 2022 11:49:12 +0530 Subject: [PATCH 04/12] Bug #190354 Resolved: Remove unwanted code and update the limit code --- src/com_tjnotifications/admin/models/notifications.php | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/src/com_tjnotifications/admin/models/notifications.php b/src/com_tjnotifications/admin/models/notifications.php index 892288f7..bafd70a1 100644 --- a/src/com_tjnotifications/admin/models/notifications.php +++ b/src/com_tjnotifications/admin/models/notifications.php @@ -85,13 +85,7 @@ protected function populateState($ordering = 'id', $direction = 'asc') parent::populateState($ordering, $direction); // Get pagination request variables - $limit = $app->getUserStateFromRequest('global.list.limit', 'limit', $app->get('list_limit'), 'int'); - $list = $app->input->get('list'); - if (isset($list['limit']) && $list['limit']) - { - $limit = $list['limit']; - } - + $limit = $app->getUserStateFromRequest($this->context . '.list.limit', 'limit', $app->get('list_limit'), 'int'); $limitstart = $app->input->get('limitstart', 0, 'int'); // In case limit has been changed, adjust it From 324bbe6ec4ec12fd5c08ea2f6f0a092aa536db1b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E2=80=9CSachin?= <sachin_s@techjoomla.com> Date: Tue, 22 Nov 2022 18:09:48 +0530 Subject: [PATCH 05/12] Bug #190428 Fixed: BE> Notification Templates> After apply filter redirect to another notification page (refer video) j4 --- .../admin/views/notifications/tmpl/default_bs2.php | 11 ++++++++++- .../admin/views/notifications/tmpl/default_bs5.php | 11 ++++++++++- .../admin/views/notifications/view.html.php | 1 + 3 files changed, 21 insertions(+), 2 deletions(-) diff --git a/src/com_tjnotifications/admin/views/notifications/tmpl/default_bs2.php b/src/com_tjnotifications/admin/views/notifications/tmpl/default_bs2.php index b49ae826..3e61d44c 100644 --- a/src/com_tjnotifications/admin/views/notifications/tmpl/default_bs2.php +++ b/src/com_tjnotifications/admin/views/notifications/tmpl/default_bs2.php @@ -43,9 +43,18 @@ }"; $doc->addStyleDeclaration($style); + +if ($this->displayExtension) +{ + $link = 'index.php?option=com_tjnotifications&view=notifications&extension=' . $this->displayExtension; +} +else +{ + $link = 'index.php?option=com_tjnotifications&view=notifications'; +} ?> -<form action="index.php?option=com_tjnotifications&view=notifications" method="post" id="adminForm" name="adminForm"> +<form action="<?php echo $link; ?>" method="post" id="adminForm" name="adminForm"> <?php if (!empty($this->sidebar)) { diff --git a/src/com_tjnotifications/admin/views/notifications/tmpl/default_bs5.php b/src/com_tjnotifications/admin/views/notifications/tmpl/default_bs5.php index 8b686968..f18ab145 100644 --- a/src/com_tjnotifications/admin/views/notifications/tmpl/default_bs5.php +++ b/src/com_tjnotifications/admin/views/notifications/tmpl/default_bs5.php @@ -44,9 +44,18 @@ }"; $doc->addStyleDeclaration($style); + +if ($this->displayExtension) +{ + $link = 'index.php?option=com_tjnotifications&view=notifications&extension=' . $this->displayExtension; +} +else +{ + $link = 'index.php?option=com_tjnotifications&view=notifications'; +} ?> -<form action="index.php?option=com_tjnotifications&view=notifications" method="post" id="adminForm" name="adminForm"> +<form action="<?php echo $link; ?>" method="post" id="adminForm" name="adminForm"> <div id="j-sidebar-container" class="j-sidebar-container"> <div class="js-stools-container-bar"> <?php echo LayoutHelper::render('joomla.searchtools.default', array('view' => $this)); ?> diff --git a/src/com_tjnotifications/admin/views/notifications/view.html.php b/src/com_tjnotifications/admin/views/notifications/view.html.php index e668c2df..6cb8e1af 100644 --- a/src/com_tjnotifications/admin/views/notifications/view.html.php +++ b/src/com_tjnotifications/admin/views/notifications/view.html.php @@ -91,6 +91,7 @@ public function display($tpl = null) BaseDatabaseModel::addIncludePath(JPATH_SITE . '/components/com_tjnotifications/models'); $model = AdminModel::getInstance('Preferences', 'TJNotificationsModel'); $this->count = $model->count(); + $this->displayExtension = $extension; if ($extension) { From a77e8d12b35edc4c08f66486b32a37c5771b6b59 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E2=80=9CSachin?= <sachin_s@techjoomla.com> Date: Thu, 1 Dec 2022 09:52:02 +0530 Subject: [PATCH 06/12] Bug #190927 Fixed: BE >Notification Templates> Search field not working as accepted j3 --- src/com_tjnotifications/admin/models/notifications.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/com_tjnotifications/admin/models/notifications.php b/src/com_tjnotifications/admin/models/notifications.php index bafd70a1..f5237c1c 100644 --- a/src/com_tjnotifications/admin/models/notifications.php +++ b/src/com_tjnotifications/admin/models/notifications.php @@ -126,7 +126,7 @@ protected function getListQuery() if (!empty($search)) { $like = $db->quote('%' . $search . '%'); - $query->where($db->quoteName('client') . ' LIKE ' . $like . ' OR ' . $db->quoteName('key') . ' LIKE ' . $like); + $query->where($db->quoteName('client') . ' LIKE ' . $like . ' OR ' . $db->quoteName('key') . ' LIKE ' . $like . ' OR ' . $db->quoteName('title') . ' LIKE ' . $like); } if ($extension) From 91a687cc480b203e59785f1d0a78110d7d9e3639 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E2=80=9CSachin?= <sachin_s@techjoomla.com> Date: Tue, 6 Dec 2022 11:15:23 +0530 Subject: [PATCH 07/12] Bug#191132 Fixed: BE> Notification Templates> choose client of search tools not working j3 --- .../admin/models/fields/clients.php | 51 ++++++++++++------- 1 file changed, 34 insertions(+), 17 deletions(-) diff --git a/src/com_tjnotifications/admin/models/fields/clients.php b/src/com_tjnotifications/admin/models/fields/clients.php index 41bc2fec..b0e76677 100644 --- a/src/com_tjnotifications/admin/models/fields/clients.php +++ b/src/com_tjnotifications/admin/models/fields/clients.php @@ -38,31 +38,48 @@ protected function getOptions() $options[] = HTMLHelper::_('select.option', '', Text::_('COM_TJNOTIFICATIONS_FIELD_CLIENT_OPTION')); - // Create a new query object. - $query = $db->getQuery(true); + $extension = Factory::getApplication()->input->get('extension', '', 'word'); + if(!$extension) + { + // Create a new query object. + $query = $db->getQuery(true); - $query->select('DISTINCT (`client`)'); - $query->from('#__tj_notification_templates'); - $db->setQuery($query); + $query->select('DISTINCT (`client`)'); + $query->from('#__tj_notification_templates'); + $db->setQuery($query); - $listobjects = $db->loadObjectList(); + $listobjects = $db->loadObjectList(); - if (!empty($listobjects)) - { - foreach ($listobjects as $obj) + if (!empty($listobjects)) { - $client = explode('_', $obj->client); - - if (!empty($client[1])) + foreach ($listobjects as $obj) { - $options[] = HTMLHelper::_('select.option', $obj->client, ucfirst($client[1])); - } - else - { - $options[] = HTMLHelper::_('select.option', $obj->client, ucfirst($client[0])); + $client = explode('_', $obj->client); + + if (!empty($client[1])) + { + $options[] = HTMLHelper::_('select.option', $obj->client, ucfirst($client[1])); + } + else + { + $options[] = HTMLHelper::_('select.option', $obj->client, ucfirst($client[0])); + } } } } + else + { + $client = explode('_', $extension); + + if (!empty($client[1])) + { + $options[] = HTMLHelper::_('select.option', $extension, ucfirst($client[1])); + } + else + { + $options[] = HTMLHelper::_('select.option', $extension, ucfirst($client[0])); + } + } return $options; } From b2c261c52cc3b688a3280139d99d063fbbd5b147 Mon Sep 17 00:00:00 2001 From: ankush_m <ankush_m@techjoomla.com> Date: Wed, 4 Jan 2023 11:43:49 +0530 Subject: [PATCH 08/12] Version bump up --- src/com_tjnotifications/tjnotifications.xml | 6 +++--- src/plugins/actionlog/tjnotification/tjnotification.xml | 6 +++--- src/plugins/api/tjnotifications/tjnotifications.xml | 6 +++--- src/plugins/privacy/tjnotification/tjnotification.xml | 6 +++--- .../tjnotificationsmobilenumber.xml | 6 +++--- 5 files changed, 15 insertions(+), 15 deletions(-) diff --git a/src/com_tjnotifications/tjnotifications.xml b/src/com_tjnotifications/tjnotifications.xml index 7a952f51..3f2afd71 100644 --- a/src/com_tjnotifications/tjnotifications.xml +++ b/src/com_tjnotifications/tjnotifications.xml @@ -4,10 +4,10 @@ <author>Techjoomla</author> <authorEmail>extensions@techjoomla.com</authorEmail> <authorUrl>https://techjoomla.com</authorUrl> - <copyright>Copyright (C) 2016 - 2022 Techjoomla. All rights reserved.</copyright> + <copyright>Copyright (C) 2016 - 2023 Techjoomla. All rights reserved.</copyright> <license>http://www.gnu.org/licenses/gpl-2.0.html GNU/GPL</license> - <creationDate>4th Aug 2022</creationDate> - <version>3.0.2</version> + <creationDate>4th Jan 2023</creationDate> + <version>3.0.3</version> <install> <sql> <file driver="mysql" charset="utf8">sql/install.mysql.utf8.sql</file> diff --git a/src/plugins/actionlog/tjnotification/tjnotification.xml b/src/plugins/actionlog/tjnotification/tjnotification.xml index ab051cd4..6580d584 100644 --- a/src/plugins/actionlog/tjnotification/tjnotification.xml +++ b/src/plugins/actionlog/tjnotification/tjnotification.xml @@ -2,12 +2,12 @@ <extension version="3.9" type="plugin" group="actionlog" method="upgrade"> <name>plg_actionlog_tjnotification</name> <author>Techjoomla</author> - <creationDate>4th Aug 2022</creationDate> - <copyright>Copyright (C) 2016 - 2022 Techjoomla. All rights reserved.</copyright> + <creationDate>4th Jan 2023</creationDate> + <copyright>Copyright (C) 2016 - 2023 Techjoomla. All rights reserved.</copyright> <license>http://www.gnu.org/licenses/gpl-2.0.html GNU/GPL</license> <authorEmail>extensions@techjoomla.com</authorEmail> <authorUrl>https://techjoomla.com</authorUrl> - <version>3.0.2</version> + <version>3.0.3</version> <description>PLG_ACTIONLOG_TJNOTIFICATION_XML_DESCRIPTION</description> <files> <filename plugin="tjnotification">tjnotification.php</filename> diff --git a/src/plugins/api/tjnotifications/tjnotifications.xml b/src/plugins/api/tjnotifications/tjnotifications.xml index 9bcfd936..362ea6b9 100644 --- a/src/plugins/api/tjnotifications/tjnotifications.xml +++ b/src/plugins/api/tjnotifications/tjnotifications.xml @@ -5,10 +5,10 @@ <author>Techjoomla</author> <authorEmail>extensions@techjoomla.com</authorEmail> <authorUrl>https://techjoomla.com</authorUrl> - <creationDate>4th Aug 2022</creationDate> - <copyright>Copyright (C) 2016 - 2022 Techjoomla. All rights reserved.</copyright> + <creationDate>4th Jan 2023</creationDate> + <copyright>Copyright (C) 2016 - 2023 Techjoomla. All rights reserved.</copyright> <license>http://www.gnu.org/licenses/gpl-2.0.html GNU/GPL</license> - <version>3.0.2</version> + <version>3.0.3</version> <files> <filename plugin="tjnotifications">tjnotifications.php</filename> diff --git a/src/plugins/privacy/tjnotification/tjnotification.xml b/src/plugins/privacy/tjnotification/tjnotification.xml index 20efc12d..cf011928 100644 --- a/src/plugins/privacy/tjnotification/tjnotification.xml +++ b/src/plugins/privacy/tjnotification/tjnotification.xml @@ -1,12 +1,12 @@ <?xml version="1.0" encoding="utf-8"?> <extension version="3.9" type="plugin" group="privacy" method="upgrade"> <name>plg_privacy_tjnotification</name> - <version>3.0.2</version> - <creationDate>4th Aug 2022</creationDate> + <version>3.0.3</version> + <creationDate>4th Jan 2023</creationDate> <author>Techjoomla</author> <authorEmail>extensions@techjoomla.com</authorEmail> <authorUrl>https://techjoomla.com</authorUrl> - <copyright>Copyright (C) 2016 - 2022 Techjoomla. All rights reserved.</copyright> + <copyright>Copyright (C) 2016 - 2023 Techjoomla. All rights reserved.</copyright> <license>http://www.gnu.org/licenses/gpl-2.0.html GNU/GPL</license> <description>PLG_PRIVACY_TJNOTIFICATION_XML_DESCRIPTION</description> <files> diff --git a/src/plugins/user/tjnotificationsmobilenumber/tjnotificationsmobilenumber.xml b/src/plugins/user/tjnotificationsmobilenumber/tjnotificationsmobilenumber.xml index 67ecc704..12620894 100644 --- a/src/plugins/user/tjnotificationsmobilenumber/tjnotificationsmobilenumber.xml +++ b/src/plugins/user/tjnotificationsmobilenumber/tjnotificationsmobilenumber.xml @@ -5,10 +5,10 @@ <author>Techjoomla</author> <authorEmail>extensions@techjoomla.com</authorEmail> <authorUrl>https://techjoomla.com</authorUrl> - <creationDate>4th Aug 2022</creationDate> - <copyright>Copyright (C) 2016 - 2022 Techjoomla. All rights reserved.</copyright> + <creationDate>4th Jan 2023</creationDate> + <copyright>Copyright (C) 2016 - 2023 Techjoomla. All rights reserved.</copyright> <license>http://www.gnu.org/licenses/gpl-2.0.html GNU/GPL</license> - <version>3.0.2</version> + <version>3.0.3</version> <files> <filename plugin="tjnotificationsmobilenumber">tjnotificationsmobilenumber.php</filename> From 02af13ee10e4d1b0dfff01e734703479b1e39151 Mon Sep 17 00:00:00 2001 From: ankush_m <ankush_m@techjoomla.com> Date: Wed, 4 Jan 2023 15:35:56 +0530 Subject: [PATCH 09/12] Updated change log --- changelog.md | 24 +++++++++++++++++++++++- 1 file changed, 23 insertions(+), 1 deletion(-) diff --git a/changelog.md b/changelog.md index d4227252..9e7b0bad 100644 --- a/changelog.md +++ b/changelog.md @@ -6,7 +6,29 @@ - Feature Addition (+) - Improvement (^) -### TJNotifications v2.0.2 +### TJNotifications v3.0.3 + +##### - Bug fixes: +- #187003 Unable to send notification due to fatal error +- #190387 page limit is not working on the notifications list view +- #190428 BE > Notification Templates > Limit filter is not working +- #191132 BE > Notification Templates > Search Tools > Client filter is not working +- #190428 BE > Notification Templates > If we apply any filter then the extension parameter gets removed from the URL + +### TJNotifications v3.0.2 + +##### - Bug fixes: +- #184788 BE > Subscriptions > Unable to save the Subscription form for joomla 3.10 + +### TJNotifications v3.0.1 + +##### ^ Improvements: +- #173952 Chore: Table changes - adding default values for tables of TJnotification (Joomla 4 compatibility) + +### TJNotifications v3.0.0 + +##### + Features Added: +- #175851 Joomla 4 compatible ##### ^ Improvements: - #173952 Chore: Table changes - adding default values for all the tables of TJnotification(Joomla 4 compatibility) From 55fa5b38b42e35dfb7ac675ae961ff761937611c Mon Sep 17 00:00:00 2001 From: ankush_m <ankush_m@techjoomla.com> Date: Wed, 4 Jan 2023 15:38:14 +0530 Subject: [PATCH 10/12] Updated change log --- changelog.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/changelog.md b/changelog.md index 9e7b0bad..725aa64b 100644 --- a/changelog.md +++ b/changelog.md @@ -30,6 +30,8 @@ ##### + Features Added: - #175851 Joomla 4 compatible +### TJNotifications v2.0.2 + ##### ^ Improvements: - #173952 Chore: Table changes - adding default values for all the tables of TJnotification(Joomla 4 compatibility) From ad409f266ae8bc8b18216ada43621f839fa768e0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E2=80=9CSachin?= <sachin_s@techjoomla.com> Date: Wed, 4 Jan 2023 15:46:32 +0530 Subject: [PATCH 11/12] Bug #192532 Fixed: BE> Notification Subscriptions> Filters not working as expected j4 --- src/com_tjnotifications/admin/views/subscriptions/view.html.php | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/com_tjnotifications/admin/views/subscriptions/view.html.php b/src/com_tjnotifications/admin/views/subscriptions/view.html.php index b32f06ba..4994f590 100644 --- a/src/com_tjnotifications/admin/views/subscriptions/view.html.php +++ b/src/com_tjnotifications/admin/views/subscriptions/view.html.php @@ -26,8 +26,6 @@ */ class TjnotificationsViewSubscriptions extends HtmlView { - protected $activeFilters; - protected $extension; public $filterForm; From 5325e60af60d61c481710071768208f476f68bfa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E2=80=9CSachin?= <sachin_s@techjoomla.com> Date: Wed, 4 Jan 2023 16:04:28 +0530 Subject: [PATCH 12/12] Bug #192532 Fixed: Changed in variable protected to public --- src/com_tjnotifications/admin/views/subscriptions/view.html.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/com_tjnotifications/admin/views/subscriptions/view.html.php b/src/com_tjnotifications/admin/views/subscriptions/view.html.php index 4994f590..b847a903 100644 --- a/src/com_tjnotifications/admin/views/subscriptions/view.html.php +++ b/src/com_tjnotifications/admin/views/subscriptions/view.html.php @@ -26,6 +26,8 @@ */ class TjnotificationsViewSubscriptions extends HtmlView { + public $activeFilters = []; + protected $extension; public $filterForm;