Просмотр исходного кода

Ticket #703 - Move:
1. Memberships & Payment Settings in Account Settings;
2. Orders, Subscriptions & Licenses in Account Dashboard.
3. Necessary related changes.

AntonLV 9 лет назад
Родитель
Сommit
123db8398e
30 измененных файлов с 322 добавлено и 151 удалено
  1. 11 4
      install/sql/system.sql
  2. 3 2
      modules/base/payment/classes/BxBaseModPaymentConfig.php
  3. 32 0
      modules/boonex/acl/classes/BxAclPageView.php
  4. 5 5
      modules/boonex/acl/install/sql/enable.sql
  5. 21 0
      modules/boonex/decorous/data/template/system/scripts/BxTemplMenuAccountDashboard.php
  6. 3 0
      modules/boonex/english/data/langs/system/en.xml
  7. 3 1
      modules/boonex/market/classes/BxMarketModule.php
  8. 12 0
      modules/boonex/market/classes/BxMarketPageLicenses.php
  9. 2 2
      modules/boonex/market/install/langs/en.xml
  10. 4 4
      modules/boonex/market/install/sql/enable.sql
  11. 21 0
      modules/boonex/ocean/data/template/system/scripts/BxTemplMenuAccountDashboard.php
  12. 1 2
      modules/boonex/payment/classes/BxPaymentConfig.php
  13. 0 2
      modules/boonex/payment/classes/BxPaymentDetails.php
  14. 3 3
      modules/boonex/payment/classes/BxPaymentModule.php
  15. 11 2
      modules/boonex/payment/classes/BxPaymentOrders.php
  16. 1 1
      modules/boonex/payment/classes/BxPaymentPageCart.php
  17. 12 0
      modules/boonex/payment/classes/BxPaymentPageDetails.php
  18. 1 1
      modules/boonex/payment/classes/BxPaymentPageHistory.php
  19. 15 40
      modules/boonex/payment/classes/BxPaymentSubscriptions.php
  20. 9 9
      modules/boonex/payment/classes/BxPaymentTemplate.php
  21. 15 15
      modules/boonex/payment/install/langs/en.xml
  22. 15 10
      modules/boonex/payment/install/sql/enable.sql
  23. 23 23
      modules/boonex/payment/install/sql/install.sql
  24. 21 0
      modules/boonex/protean/data/template/system/scripts/BxTemplMenuAccountDashboard.php
  25. 2 2
      modules/boonex/russian/data/langs/bx_market/ru.xml
  26. 15 15
      modules/boonex/russian/data/langs/bx_payment/ru.xml
  27. 3 0
      modules/boonex/russian/data/langs/system/ru.xml
  28. 50 0
      template/scripts/BxBaseMenuAccountDashboard.php
  29. 2 8
      template/scripts/BxBaseMenuAccountNotifications.php
  30. 6 0
      template/scripts/BxBasePageDashboard.php

+ 11 - 4
install/sql/system.sql

@@ -3228,6 +3228,7 @@ INSERT INTO `sys_objects_menu` (`object`, `title`, `set_name`, `module`, `templa
 ('sys_add_content', '_sys_menu_title_add_content', 'sys_add_content_links', 'system', 14, 0, 1, 'BxTemplMenuSite', ''),
 ('sys_add_profile', '_sys_menu_title_add_profile', 'sys_add_profile_links', 'system', 14, 0, 1, 'BxTemplMenuProfileAdd', ''),
 ('sys_add_profile_vertical', '_sys_menu_title_add_profile_vertical', 'sys_add_profile_links', 'system', 6, 0, 1, 'BxTemplMenuProfileAdd', ''),
+('sys_account_dashboard', '_sys_menu_title_account_dashboard', 'sys_account_dashboard', 'system', 8, 0, 1, 'BxTemplMenuAccountDashboard', ''),
 ('sys_account_dashboard_manage_tools', '_sys_menu_title_account_dashboard_manage_tools', 'sys_account_dashboard_manage_tools', 'system', 4, 0, 1, '', ''),
 ('sys_account_settings_submenu', '_sys_menu_title_account_settings', 'sys_account_settings', 'system', 8, 0, 1, '', ''),
 ('sys_account_settings_more', '_sys_menu_title_account_settings_more', 'sys_account_settings_more', 'system', 4, 0, 1, '', ''),
@@ -3261,6 +3262,7 @@ INSERT INTO `sys_menu_sets` (`set_name`, `module`, `title`, `deletable`) VALUES
 ('sys_account_notifications', 'system', '_sys_menu_set_title_account_notifications', 0),
 ('sys_add_content_links', 'system', '_sys_menu_set_title_add_content', 0),
 ('sys_add_profile_links', 'system', '_sys_menu_set_title_add_profile', 0),
+('sys_account_dashboard', 'system', '_sys_menu_set_title_account_dashboard', 0),
 ('sys_account_dashboard_manage_tools', 'system', '_sys_menu_set_title_account_dashboard_manage_tools', 0),
 ('sys_account_settings', 'system', '_sys_menu_set_title_account_settings', 0),
 ('sys_account_settings_more', 'system', '_sys_menu_set_title_account_settings_more', 0),
@@ -3330,9 +3332,8 @@ INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `tit
 
 -- notifications menu in account popup
 INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES
-('sys_account_notifications', 'system', 'cart', '_sys_menu_item_title_system_cart', '_sys_menu_item_title_cart', 'cart.php', '', '', 'cart-plus col-red3', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:20:"get_cart_items_count";s:6:"params";a:0:{}s:5:"class";s:21:"TemplPaymentsServices";}', '', 2147483646, 1, 1, 1),
-('sys_account_notifications', 'system', 'subscriptions', '_sys_menu_item_title_system_subscriptions', '_sys_menu_item_title_subscriptions', 'subscriptions.php', '', '', 'money col-blue3', '', '', 2147483646, 1, 1, 2),
-('sys_account_notifications', 'system', 'orders', '_sys_menu_item_title_system_orders', '_sys_menu_item_title_orders', 'orders.php', '', '', 'cart-arrow-down col-green3', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:16:"get_orders_count";s:6:"params";a:1:{i:0;s:3:"new";}s:5:"class";s:21:"TemplPaymentsServices";}', '', 2147483646, 1, 1, 3);
+('sys_account_notifications', 'system', 'notifications-cart', '_sys_menu_item_title_system_cart', '_sys_menu_item_title_cart', 'cart.php', '', '', 'cart-plus col-red3', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:20:"get_cart_items_count";s:6:"params";a:0:{}s:5:"class";s:21:"TemplPaymentsServices";}', '', 2147483646, 1, 1, 1),
+('sys_account_notifications', 'system', 'notifications-orders', '_sys_menu_item_title_system_orders', '_sys_menu_item_title_orders', 'orders.php', '', '', 'cart-arrow-down col-green3', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:16:"get_orders_count";s:6:"params";a:1:{i:0;s:3:"new";}s:5:"class";s:21:"TemplPaymentsServices";}', '', 2147483646, 0, 1, 2);
 
 -- account settings menu
 INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES
@@ -3340,12 +3341,18 @@ INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `tit
 ('sys_account_settings', 'system', 'account-settings-info', '_sys_menu_item_title_system_account_settings_info', '_sys_menu_item_title_account_settings_info', 'page.php?i=account-settings-info', '', '', 'info-circle', '', 2147483646, 1, 1, 2),
 ('sys_account_settings', 'system', 'account-settings-email', '_sys_menu_item_title_system_account_settings_email', '_sys_menu_item_title_account_settings_email', 'page.php?i=account-settings-email', '', '', 'envelope', '', 2147483646, 1, 1, 3),
 ('sys_account_settings', 'system', 'account-settings-password', '_sys_menu_item_title_system_account_settings_pwd', '_sys_menu_item_title_account_settings_pwd', 'page.php?i=account-settings-password', '', '', 'key', '', 2147483646, 1, 1, 4),
-('sys_account_settings', 'system', 'account-settings-more', '_sys_menu_item_title_system_more', '_sys_menu_item_title_more', 'javascript:void(0);', 'bx_menu_popup(''sys_account_settings_more'', this);', '', '', '', 2147483647, 1, 1, 5);
+('sys_account_settings', 'system', 'account-settings-more', '_sys_menu_item_title_system_more', '_sys_menu_item_title_more', 'javascript:void(0);', 'bx_menu_popup(''sys_account_settings_more'', this);', '', '', '', 2147483647, 1, 1, 999);
 
 -- account settings menu more
 INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES
 ('sys_account_settings_more', 'system', 'account-settings-delete', '_sys_menu_item_title_system_account_settings_delete', '_sys_menu_item_title_account_settings_delete', 'page.php?i=account-settings-delete', '', '', 'remove', '', 2147483646, 1, 1, 1);
 
+-- account dashboard
+INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES
+('sys_account_dashboard', 'system', 'dashboard', '_sys_menu_item_title_system_account_dashboard', '_sys_menu_item_title_account_dashboard', 'page.php?i=dashboard', '', '', 'dashboard', '', '', 2147483646, 1, 1, 1),
+('sys_account_dashboard', 'system', 'dashboard-subscriptions', '_sys_menu_item_title_system_subscriptions', '_sys_menu_item_title_subscriptions', 'subscriptions.php', '', '', 'money col-blue3', '', '', 2147483646, 1, 1, 2),
+('sys_account_dashboard', 'system', 'dashboard-orders', '_sys_menu_item_title_system_orders', '_sys_menu_item_title_orders', 'orders.php', '', '', 'cart-arrow-down col-green3', '', '', 2147483646, 1, 1, 3);
+
 -- comment manage menu
 INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
 ('sys_cmts_item_manage', 'system', 'item-edit', '_sys_menu_item_title_system_cmts_item_edit', '_sys_menu_item_title_cmts_item_edit', 'javascript:void(0)', 'javascript:{js_object}.cmtEdit(this, {content_id})', '_self', 'pencil', '', 2147483647, 1, 0, 0),

+ 3 - 2
modules/base/payment/classes/BxBaseModPaymentConfig.php

@@ -49,6 +49,7 @@ class BxBaseModPaymentConfig extends BxBaseModGeneralConfig
 			'display_pendings_process' => $this->_sName . '_form_pendings_process',
 			'display_processed_add' => $this->_sName . '_form_processed_add',
 
+			'menu_dashboard' => 'sys_account_dashboard',
 			'menu_cart_submenu' => $this->_sName . '_menu_cart_submenu',
         	'menu_orders_submenu' => $this->_sName . '_menu_orders_submenu',
     		'menu_sbs_submenu' => $this->_sName . '_menu_sbs_submenu',
@@ -59,9 +60,9 @@ class BxBaseModPaymentConfig extends BxBaseModGeneralConfig
 			'grid_pending' => $this->_sName . '_grid_orders_pending',
 			'grid_carts' => $this->_sName . '_grid_carts',
 			'grid_cart' => $this->_sName . '_grid_cart',
-			'grid_sbs_list' => $this->_sName . '_grid_sbs_list',
+			'grid_sbs_list_my' => $this->_sName . '_grid_sbs_list_my',
+			'grid_sbs_list_all' => $this->_sName . '_grid_sbs_list_all',
 			'grid_sbs_history' => $this->_sName . '_grid_sbs_history',
-		    'grid_sbs_administration' => $this->_sName . '_grid_sbs_administration',
 		));
 
 		$this->_aPerPage = array();

+ 32 - 0
modules/boonex/acl/classes/BxAclPageView.php

@@ -0,0 +1,32 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    PaidLevels Paid Levels
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+class BxAclPageView extends BxTemplPage
+{
+    protected $MODULE;
+
+    public function __construct($aObject, $oTemplate = false)
+    {
+        $this->MODULE = 'bx_acl';
+
+        parent::__construct($aObject, $oTemplate);
+
+        $oMenuSubmenu = BxDolMenu::getObjectInstance('sys_site_submenu');
+        if($oMenuSubmenu) {
+            $sSubmenu = 'sys_account_settings_submenu';
+            $oMenuSubmenu->setObjectSubmenu($sSubmenu, array('title' => _t('_sys_menu_item_title_account_settings'), 'link' => '', 'icon' => ''));
+
+            BxDolMenu::getObjectInstance($sSubmenu)->setSelected($this->MODULE, 'acl-view');
+        }
+    }
+}
+
+/** @} */

+ 5 - 5
modules/boonex/acl/install/sql/enable.sql

@@ -3,16 +3,16 @@ SET @sName = 'bx_acl';
 
 -- PAGE: view levels
 INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
-('bx_acl_view', '_bx_acl_page_title_sys_view', '_bx_acl_page_title_view', @sName, 5, 2147483647, 1, 'acl-view', 'page.php?i=acl-view', '', '', '', 0, 1, 0, '', '');
+('bx_acl_view', '_bx_acl_page_title_sys_view', '_bx_acl_page_title_view', @sName, 5, 2147483647, 1, 'acl-view', 'page.php?i=acl-view', '', '', '', 0, 1, 0, 'BxAclPageView', 'modules/boonex/acl/classes/BxAclPageView.php');
 
 INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
 ('bx_acl_view', 1, @sName, '_bx_acl_page_block_title_system_view', '_bx_acl_page_block_title_view', 11, 2147483647, 'service', 'a:2:{s:6:\"module\";s:6:\"bx_acl\";s:6:\"method\";s:14:\"get_block_view\";}', 0, 1, 0);
 
 
--- MENU: Account links
-SET @iMIOrder = (SELECT IFNULL(MAX(`order`), 0) FROM `sys_menu_items` WHERE `set_name` = 'sys_account_notifications');
-INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES
-('sys_account_notifications', 'bx_acl', 'acl-view', '_bx_acl_menu_item_title_system_acl_view', '_bx_acl_menu_item_title_acl_view', 'page.php?i=acl-view', '', '', 'shield col-red2', '', '', 2147483646, 1, 0, @iMIOrder + 1);
+-- MENU: account settings menu
+SET @iMoAccountSettings = (SELECT IFNULL(MAX(`order`), 0) FROM `sys_menu_items` WHERE `set_name`='sys_account_settings' AND `name` <> 'account-settings-more' LIMIT 1);
+INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `editable`, `order`) VALUES
+('sys_account_settings', 'bx_acl', 'acl-view', '_bx_acl_menu_item_title_system_acl_view', '_bx_acl_menu_item_title_acl_view', 'page.php?i=acl-view', '', '', 'shield col-red2', '', '', 2147483646, 1, 0, 1, @iMoAccountSettings + 1);
 
 
 -- SETTINGS

+ 21 - 0
modules/boonex/decorous/data/template/system/scripts/BxTemplMenuAccountDashboard.php

@@ -0,0 +1,21 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    UnaTemplate UNA Template Classes
+ * @{
+ */
+
+/**
+ * @see BxDolMenu
+ */
+class BxTemplMenuAccountDashboard extends BxBaseMenuAccountDashboard
+{
+    public function __construct ($aObject, $oTemplate = false)
+    {
+        parent::__construct ($aObject, $oTemplate);
+    }
+}
+
+/** @} */

+ 3 - 0
modules/boonex/english/data/langs/system/en.xml

@@ -2059,6 +2059,7 @@ If it is not enabled then please consider implement this optimization, since it
 	<string name="_sys_menu_item_title_system_terms"><![CDATA[Terms]]></string>
 	<string name="_sys_menu_item_title_system_account_menu"><![CDATA[Account]]></string>
 	<string name="_sys_menu_item_title_system_account_profile_context"><![CDATA[Profiles]]></string>
+	<string name="_sys_menu_item_title_system_account_dashboard"><![CDATA[Dashboard]]></string>
 	<string name="_sys_menu_item_title_system_account_dashboard_administration"><![CDATA[Administration]]></string>
 	<string name="_sys_menu_item_title_system_account_settings"><![CDATA[Settings]]></string>
 	<string name="_sys_menu_item_title_system_account_settings_delete"><![CDATA[Delete]]></string>
@@ -2088,6 +2089,7 @@ If it is not enabled then please consider implement this optimization, since it
     <string name="_sys_menu_item_title_system_social_sharing_twitter"><![CDATA[Share in Twitter]]></string>
     <string name="_sys_menu_item_title_system_social_sharing_pinterest"><![CDATA[Share in Pinterest]]></string>
 	<string name="_sys_menu_set_title_account"><![CDATA[Account]]></string>
+	<string name="_sys_menu_set_title_account_dashboard"><![CDATA[Account Dashboard]]></string>
 	<string name="_sys_menu_set_title_account_dashboard_manage_tools"><![CDATA[Account Dashboard Manage Tools]]></string>
 	<string name="_sys_menu_set_title_account_settings"><![CDATA[Account Settings]]></string>
 	<string name="_sys_menu_set_title_account_settings_more"><![CDATA[Account Settings More]]></string>
@@ -2125,6 +2127,7 @@ If it is not enabled then please consider implement this optimization, since it
 	<string name="_sys_menu_template_title_account_popup"><![CDATA[Account popup]]></string>
 	<string name="_sys_menu_template_title_custom"><![CDATA[Custom menu items]]></string>
 	<string name="_sys_menu_title_account"><![CDATA[Account Menu]]></string>
+	<string name="_sys_menu_title_account_dashboard"><![CDATA[Account Dashboard Menu]]></string>
 	<string name="_sys_menu_title_account_dashboard_manage_tools"><![CDATA[Account Dashboard Manage Tools Menu]]></string>
 	<string name="_sys_menu_title_account_notifications"><![CDATA[Notifications Items]]></string>
 	<string name="_sys_menu_title_account_popup"><![CDATA[Account Popup]]></string>

+ 3 - 1
modules/boonex/market/classes/BxMarketModule.php

@@ -159,8 +159,10 @@ class BxMarketModule extends BxBaseModTextModule
 	{
 	    return MsgBox(_t('_bx_market_page_block_content_licenses_note'));
 	}
+
     /**
-     * Get number of unused licenses for some profile
+     * Get number of unused licenses for some profile. It can be used in menus with "alert" counters.
+     * 
      * @param $iProfileId - profile to get unused licenses for, if omitted then currently logged in profile is used
      * @return integer
      */

+ 12 - 0
modules/boonex/market/classes/BxMarketPageLicenses.php

@@ -14,9 +14,21 @@
  */
 class BxMarketPageLicenses extends BxBaseModTextPageAuthor
 {
+    protected $MODULE;
+
     public function __construct($aObject, $oTemplate = false)
     {
+        $this->MODULE = 'bx_market';
+
         parent::__construct($aObject, $oTemplate);
+
+        $oMenuSubmenu = BxDolMenu::getObjectInstance('sys_site_submenu');
+        if($oMenuSubmenu) {
+            $sMenuSubmenu = 'sys_account_dashboard';
+            $oMenuSubmenu->setObjectSubmenu($sMenuSubmenu, array('title' => _t('_sys_menu_item_title_account_dashboard'), 'link' => '', 'icon' => ''));
+
+            BxDolMenu::getObjectInstance($sMenuSubmenu)->setSelected($this->MODULE, 'dashboard-licenses');
+        }
     }
 }
 

+ 2 - 2
modules/boonex/market/install/langs/en.xml

@@ -244,8 +244,8 @@
 	<string name="_bx_market_menu_item_title_admt_products"><![CDATA[Products - {addon} hidden]]></string>
 	<string name="_bx_market_menu_item_title_manage_my"><![CDATA[My Products]]></string>
 	<string name="_bx_market_menu_item_title_manage_all"><![CDATA[All Products]]></string>
-	<string name="_bx_market_menu_item_title_system_notifications_licenses"><![CDATA[Licenses]]></string>
-	<string name="_bx_market_menu_item_title_notifications_licenses"><![CDATA[Licenses]]></string>
+	<string name="_bx_market_menu_item_title_system_licenses"><![CDATA[Licenses]]></string>
+	<string name="_bx_market_menu_item_title_licenses"><![CDATA[Licenses]]></string>
 	<string name="_bx_market_menu_title_snippet"><![CDATA[Snippet Actions]]></string>
     <string name="_bx_market_menu_set_title_snippet"><![CDATA[Snippet Actions]]></string>
     <string name="_bx_market_menu_item_title_system_snippet_more"><![CDATA[More Actions]]></string>

+ 4 - 4
modules/boonex/market/install/sql/enable.sql

@@ -288,10 +288,10 @@ INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `titl
 INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
 ('trigger_profile_view_submenu', 'bx_market', 'products-author', '_bx_market_menu_item_title_system_view_entries_author', '_bx_market_menu_item_title_view_entries_author', 'page.php?i=products-author&profile_id={profile_id}', '', '', 'shopping-cart col-green3', '', 2147483647, 1, 0, 0);
 
--- MENU: Notifications
-SET @iMIOrder = (SELECT IFNULL(MAX(`order`), 0) FROM `sys_menu_items` WHERE `set_name` = 'sys_account_notifications');
-INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES
-('sys_account_notifications', 'bx_market', 'notifications-licenses', '_bx_market_menu_item_title_system_notifications_licenses', '_bx_market_menu_item_title_notifications_licenses', 'page.php?i=products-licenses', '', '', 'certificate col-green2', 'a:2:{s:6:"module";s:9:"bx_market";s:6:"method";s:23:"get_unused_licenses_num";}', '', 2147483646, 1, 0, @iMIOrder + 1);
+-- MENU: account dashboard
+SET @iMoAccountDashboard = (SELECT IFNULL(MAX(`order`), 0) FROM `sys_menu_items` WHERE `set_name`='sys_account_dashboard' LIMIT 1);
+INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `editable`, `order`) VALUES
+('sys_account_dashboard', 'bx_market', 'dashboard-licenses', '_bx_market_menu_item_title_system_licenses', '_bx_market_menu_item_title_licenses', 'page.php?i=products-licenses', '', '', 'certificate col-green2', '', '', 2147483646, 1, 0, 1, @iMoAccountDashboard + 1);
 
 
 -- PRIVACY 

+ 21 - 0
modules/boonex/ocean/data/template/system/scripts/BxTemplMenuAccountDashboard.php

@@ -0,0 +1,21 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    UnaTemplate UNA Template Classes
+ * @{
+ */
+
+/**
+ * @see BxDolMenu
+ */
+class BxTemplMenuAccountDashboard extends BxBaseMenuAccountDashboard
+{
+    public function __construct ($aObject, $oTemplate = false)
+    {
+        parent::__construct ($aObject, $oTemplate);
+    }
+}
+
+/** @} */

+ 1 - 2
modules/boonex/payment/classes/BxPaymentConfig.php

@@ -23,8 +23,7 @@ class BxPaymentConfig extends BxBaseModPaymentConfig
         	'URL_CART' => 'page.php?i=payment-cart',
         	'URL_CART_CHECKOUT' => $sBaseUrl . 'initialize_checkout/' . BX_PAYMENT_TYPE_SINGLE . '/',
         	'URL_SUBSCRIBE' => $sBaseUrl . 'subscribe/',
-        	'URL_SUBSCRIPTIONS' => 'page.php?i=payment-sbs-list',
-        	'URL_SUBSCRIPTIONS_ADM' => 'page.php?i=payment-sbs-administration',
+        	'URL_SUBSCRIPTIONS' => 'page.php?i=payment-sbs-list-my',
         	'URL_HISTORY' => 'page.php?i=payment-history',
         	'URL_ORDERS' => 'page.php?i=payment-orders',
         	'URL_DETAILS' => 'page.php?i=payment-details',

+ 0 - 2
modules/boonex/payment/classes/BxPaymentDetails.php

@@ -45,8 +45,6 @@ class BxPaymentDetails extends BxBaseModPaymentDetails
 		if(empty($sContent))
 			$sContent = MsgBox(_t($this->_sLangsPrefix . 'msg_no_results'));
 
-        $this->_oModule->setSiteSubmenu('menu_orders_submenu', 'details');
-
         return array(
         	'content' => $sContent
         );

+ 3 - 3
modules/boonex/payment/classes/BxPaymentModule.php

@@ -691,7 +691,7 @@ class BxPaymentModule extends BxBaseModPaymentModule
 		//--- 'System' -> 'Cancel Subscription' for Alerts Engine ---//
 	}
 
-    public function setSiteSubmenu($sSubmenu, $sSelected)
+    public function setSiteSubmenu($sSubmenu, $sSelModule, $sSelName)
     {
         $oSiteSubmenu = BxDolMenu::getObjectInstance('sys_site_submenu');
         if(!$oSiteSubmenu)
@@ -702,8 +702,8 @@ class BxPaymentModule extends BxBaseModPaymentModule
         if(!$oModuleSubmenu) 
             return;
 
-        $oSiteSubmenu->setObjectSubmenu($sModuleSubmenu, array('title' => _t('_bx_payment'), 'link' => '','icon' => ''));
-        $oModuleSubmenu->setSelected($this->_aModule['name'], $sSelected);
+        $oSiteSubmenu->setObjectSubmenu($sModuleSubmenu);
+        $oModuleSubmenu->setSelected($sSelModule, $sSelName);
     }
 }
 

+ 11 - 2
modules/boonex/payment/classes/BxPaymentOrders.php

@@ -27,6 +27,8 @@ class BxPaymentOrders extends BxBaseModPaymentOrders
      */
 	public function serviceGetBlockOrders($sType = '', $iUserId = BX_PAYMENT_EMPTY_ID)
     {
+        $CNF = &$this->_oModule->_oConfig->CNF;
+
     	if(empty($sType))
     		$sType = bx_get('type') !== false ? bx_process_input(bx_get('type')) : BX_PAYMENT_ORDERS_TYPE_PROCESSED;
 
@@ -37,10 +39,17 @@ class BxPaymentOrders extends BxBaseModPaymentOrders
         if($sType == BX_PAYMENT_ORDERS_TYPE_PROCESSED)
             $this->_oModule->_oDb->updateOrdersProcessed(array('new' => 0), array('seller_id' => $iUserId, 'new' => 1));
 
-        $this->_oModule->setSiteSubmenu('menu_orders_submenu', 'orders-' . $sType);
+        $this->_oModule->setSiteSubmenu('menu_dashboard', 'system', 'dashboard-orders');
+
+        $sBlockSubmenu = $this->_oModule->_oConfig->getObject('menu_orders_submenu');
+        $oBlockSubmenu = BxDolMenu::getObjectInstance($sBlockSubmenu);
+        if($oBlockSubmenu)
+            $oBlockSubmenu->setSelected($this->MODULE, 'orders-' . $sType);
+
         return array(
         	'title' => _t($this->_sLangsPrefix . 'page_block_title_orders_' . $sType),
-        	'content' => $this->_oModule->_oTemplate->displayBlockOrders($sType, $iUserId)
+        	'content' => $this->_oModule->_oTemplate->displayBlockOrders($sType, $iUserId),
+            'menu' => $oBlockSubmenu
         );
     }
 

+ 1 - 1
modules/boonex/payment/classes/BxPaymentPageCart.php

@@ -17,7 +17,7 @@ class BxPaymentPageCart extends BxBaseModPaymentPage
 
         parent::__construct($aObject, $oTemplate);
         
-        $this->_oModule->setSiteSubmenu('menu_cart_submenu', 'cart');
+        $this->_oModule->setSiteSubmenu('menu_cart_submenu', $this->MODULE, 'cart');
     }
 }
 

+ 12 - 0
modules/boonex/payment/classes/BxPaymentPageDetails.php

@@ -11,9 +11,21 @@
 
 class BxPaymentPageDetails extends BxTemplPage
 {
+    protected $MODULE;
+
     public function __construct($aObject, $oTemplate = false)
     {
+        $this->MODULE = 'bx_payment';
+
         parent::__construct($aObject, $oTemplate);
+
+        $oMenuSubmenu = BxDolMenu::getObjectInstance('sys_site_submenu');
+        if($oMenuSubmenu) {
+            $sSubmenu = 'sys_account_settings_submenu';
+            $oMenuSubmenu->setObjectSubmenu($sSubmenu, array('title' => _t('_sys_menu_item_title_account_settings'), 'link' => '', 'icon' => ''));
+
+            BxDolMenu::getObjectInstance($sSubmenu)->setSelected($this->MODULE, 'payment-details');
+        }
     }
 }
 

+ 1 - 1
modules/boonex/payment/classes/BxPaymentPageHistory.php

@@ -17,7 +17,7 @@ class BxPaymentPageHistory extends BxBaseModPaymentPage
 
         parent::__construct($aObject, $oTemplate);
 
-        $this->_oModule->setSiteSubmenu('menu_cart_submenu', 'cart-history');
+        $this->_oModule->setSiteSubmenu('menu_cart_submenu', $this->MODULE, 'cart-history');
     }
 }
 

+ 15 - 40
modules/boonex/payment/classes/BxPaymentSubscriptions.php

@@ -21,25 +21,19 @@ class BxPaymentSubscriptions extends BxBaseModPaymentSubscriptions
     /*
      * Service methods
      */
-    public function serviceGetBlockList()
+    public function serviceGetBlockListMy()
     {
-        $this->_oModule->setSiteSubmenu('menu_sbs_submenu', 'sbs-list');
-
-        return $this->_getBlockSubscriptions('list');
+        return $this->_getBlock('list_my');
     }
 
-    public function serviceGetBlockHistory()
+    public function serviceGetBlockListAll()
     {
-        $this->_oModule->setSiteSubmenu('menu_sbs_submenu', 'sbs-history');
-
-        return $this->_getBlock('history');
+        return $this->_getBlock('list_all');
     }
 
-    public function serviceGetBlockAdministration()
+    public function serviceGetBlockHistory()
     {
-        $this->_oModule->setSiteSubmenu('menu_sbs_submenu', 'sbs-list');
-
-        return $this->_getBlockSubscriptions('administration');
+        return $this->_getBlock('history');
     }
 
 	public function serviceSubscribe($iSellerId, $sSellerProvider, $iModuleId, $iItemId, $iItemCount)
@@ -113,36 +107,17 @@ class BxPaymentSubscriptions extends BxBaseModPaymentSubscriptions
         if(empty($iUserId))
             return MsgBox(_t($CNF['T']['ERR_REQUIRED_LOGIN']));
 
-        return array(
-        	'content' => $this->_oModule->_oTemplate->$sMethod($iUserId)
-        );
-    }
+        $this->_oModule->setSiteSubmenu('menu_dashboard', 'system', 'dashboard-subscriptions');
 
-    protected function _getBlockSubscriptions($sType)
-    {
-        $CNF = &$this->_oModule->_oConfig->CNF;
-
-        $aResult = $this->_getBlock($sType);
-        if(!is_array($aResult))
-            return $aResult;
-
-        $sMenu = '';
-		if(BxDolAcl::getInstance()->isMemberLevelInSet(192)) {
-			$oPermalink = BxDolPermalinks::getInstance();
-
-            $oMenu = new BxTemplMenu(array(
-            	'template' => 'menu_vertical.html', 
-            	'menu_items' => array(
-    			    array('id' => 'sbs-list', 'name' => 'sbs-list', 'class' => '', 'link' => $oPermalink->permalink($CNF['URL_SUBSCRIPTIONS']), 'target' => '_self', 'title' => _t('_bx_payment_menu_item_title_sbs_list_my'), 'active' => 1),
-    			    array('id' => 'sbs-administration', 'name' => 'sbs-administration', 'class' => '', 'link' => $oPermalink->permalink($CNF['URL_SUBSCRIPTIONS_ADM']), 'target' => '_self', 'title' => _t('_bx_payment_menu_item_title_sbs_list_administration'), 'active' => 1)
-    			)
-            ), $this->_oModule->_oTemplate);
-            $oMenu->setSelected($this->_oModule->getName(), 'sbs-' . $sType);
+        $sBlockSubmenu = $this->_oModule->_oConfig->getObject('menu_sbs_submenu');
+        $oBlockSubmenu = BxDolMenu::getObjectInstance($sBlockSubmenu);
+        if($oBlockSubmenu) 
+            $oBlockSubmenu->setSelected($this->MODULE, 'sbs-' . str_replace('_', '-', $sType));     
 
-            $aResult['menu'] = $oMenu->getCode();
-		}
-
-		return $aResult;
+        return array(
+        	'content' => $this->_oModule->_oTemplate->$sMethod($iUserId),
+        	'menu' => $this->_oModule->_oConfig->getObject('menu_sbs_submenu')
+        );
     }
 }
 

+ 9 - 9
modules/boonex/payment/classes/BxPaymentTemplate.php

@@ -184,9 +184,9 @@ class BxPaymentTemplate extends BxBaseModPaymentTemplate
         return $this->_displayBlockHistory('grid_history', $iClientId, $iSellerId);
     }
 
-    public function displayBlockSbsList($iClientId)
+    public function displayBlockSbsListMy($iClientId)
     {
-        $oGrid = BxDolGrid::getObjectInstance($this->_oConfig->getObject('grid_sbs_list'), $this->getModule()->_oTemplate);
+        $oGrid = BxDolGrid::getObjectInstance($this->_oConfig->getObject('grid_sbs_list_my'), $this->getModule()->_oTemplate);
         if(!$oGrid || empty($iClientId))
             return MsgBox(_t($this->_sLangsPrefix . 'msg_no_results'));
 
@@ -196,14 +196,9 @@ class BxPaymentTemplate extends BxBaseModPaymentTemplate
         return $this->displayJsCode(BX_PAYMENT_ORDERS_TYPE_SUBSCRIPTION) . $oGrid->getCode();
     }
 
-    public function displayBlockSbsHistory($iClientId)
-    {
-        return $this->_displayBlockHistory('grid_sbs_history', $iClientId);
-    }
-
-    public function displayBlockSbsAdministration()
+    public function displayBlockSbsListAll()
     {
-        $oGrid = BxDolGrid::getObjectInstance($this->_oConfig->getObject('grid_sbs_administration'), $this->getModule()->_oTemplate);
+        $oGrid = BxDolGrid::getObjectInstance($this->_oConfig->getObject('grid_sbs_list_all'), $this->getModule()->_oTemplate);
         if(!$oGrid)
             return MsgBox(_t($this->_sLangsPrefix . 'msg_no_results'));
 
@@ -211,6 +206,11 @@ class BxPaymentTemplate extends BxBaseModPaymentTemplate
         return $this->displayJsCode(BX_PAYMENT_ORDERS_TYPE_SUBSCRIPTION) . $oGrid->getCode();
     }
 
+    public function displayBlockSbsHistory($iClientId)
+    {
+        return $this->_displayBlockHistory('grid_sbs_history', $iClientId);
+    }
+
     public function displayBlockSbsDetails($iClientId)
     {
         return 'Details would be here';

+ 15 - 15
modules/boonex/payment/install/langs/en.xml

@@ -19,17 +19,17 @@
     <string name="_bx_payment_page_block_title_cart_thank_you"><![CDATA[Thank you!]]></string>
     <string name="_bx_payment_page_block_content_cart_thank_you"><![CDATA[Thank you! Payment was successfully performed. The data will be processed shortly. Please wait.]]></string>
 
-    <string name="_bx_payment_page_title_sys_sbs_list"><![CDATA[Subscriptions List]]></string>
-    <string name="_bx_payment_page_title_sbs_list"><![CDATA[Subscriptions]]></string>
-    <string name="_bx_payment_page_block_title_sbs_list"><![CDATA[Subscriptions]]></string>
+    <string name="_bx_payment_page_title_sys_sbs_list_my"><![CDATA[My Subscriptions]]></string>
+    <string name="_bx_payment_page_title_sbs_list_my"><![CDATA[My Subscriptions]]></string>
+    <string name="_bx_payment_page_block_title_sbs_list_my"><![CDATA[My Subscriptions]]></string>
 
-    <string name="_bx_payment_page_title_sys_sbs_history"><![CDATA[Subscriptions History]]></string>
-    <string name="_bx_payment_page_title_sbs_history"><![CDATA[Payment History]]></string>
-    <string name="_bx_payment_page_block_title_sbs_history"><![CDATA[Payment History]]></string>
+    <string name="_bx_payment_page_title_sys_sbs_list_all"><![CDATA[All Subscriptions]]></string>
+    <string name="_bx_payment_page_title_sbs_list_all"><![CDATA[All Subscriptions]]></string>
+    <string name="_bx_payment_page_block_title_sbs_list_all"><![CDATA[All Subscriptions]]></string>
 
-    <string name="_bx_payment_page_title_sys_sbs_administration"><![CDATA[Subscriptions Administration]]></string>
-    <string name="_bx_payment_page_title_sbs_administration"><![CDATA[Subscriptions]]></string>
-    <string name="_bx_payment_page_block_title_sbs_administration"><![CDATA[Subscriptions]]></string>
+    <string name="_bx_payment_page_title_sys_sbs_history"><![CDATA[My Payments]]></string>
+    <string name="_bx_payment_page_title_sbs_history"><![CDATA[My Payments]]></string>
+    <string name="_bx_payment_page_block_title_sbs_history"><![CDATA[My Payments]]></string>
 
 	<string name="_bx_payment_page_title_sys_history"><![CDATA[Shopping History]]></string>
 	<string name="_bx_payment_page_title_history"><![CDATA[Shopping History]]></string>
@@ -61,7 +61,7 @@
     <string name="_bx_payment_menu_item_title_system_orders_pending"><![CDATA[Pending Orders]]></string>
     <string name="_bx_payment_menu_item_title_orders_pending"><![CDATA[Pending]]></string>
     <string name="_bx_payment_menu_item_title_system_details"><![CDATA[Payments Details]]></string>
-    <string name="_bx_payment_menu_item_title_details"><![CDATA[Settings]]></string>
+    <string name="_bx_payment_menu_item_title_details"><![CDATA[Payments]]></string>
 
 	<string name="_bx_payment_menu_title_cart_submenu"><![CDATA[Cart Submenu]]></string>
     <string name="_bx_payment_menu_set_title_cart_submenu"><![CDATA[Cart Submenu]]></string>
@@ -72,12 +72,12 @@
 
     <string name="_bx_payment_menu_title_sbs_submenu"><![CDATA[Subscriptions Submenu]]></string>
     <string name="_bx_payment_menu_set_title_sbs_submenu"><![CDATA[Subscriptions Submenu]]></string>
-    <string name="_bx_payment_menu_item_title_system_sbs_list"><![CDATA[Subscriptions List]]></string>
-    <string name="_bx_payment_menu_item_title_sbs_list"><![CDATA[Subscriptions]]></string>
+    <string name="_bx_payment_menu_item_title_system_sbs_list_my"><![CDATA[My Subscriptions List]]></string>
     <string name="_bx_payment_menu_item_title_sbs_list_my"><![CDATA[My Subscriptions]]></string>
-    <string name="_bx_payment_menu_item_title_sbs_list_administration"><![CDATA[All Subscriptions]]></string>
-    <string name="_bx_payment_menu_item_title_system_sbs_history"><![CDATA[Subscriptions History]]></string>
-    <string name="_bx_payment_menu_item_title_sbs_history"><![CDATA[Payments]]></string>
+    <string name="_bx_payment_menu_item_title_system_sbs_list_all"><![CDATA[All Subscriptions List]]></string>
+    <string name="_bx_payment_menu_item_title_sbs_list_all"><![CDATA[All Subscriptions]]></string>
+    <string name="_bx_payment_menu_item_title_system_sbs_history"><![CDATA[My Payments History]]></string>
+    <string name="_bx_payment_menu_item_title_sbs_history"><![CDATA[My Payments]]></string>
 
     <string name="_bx_payment_menu_title_sbs_actions"><![CDATA[Subscription Actions]]></string>
     <string name="_bx_payment_menu_set_title_sbs_actions"><![CDATA[Subscription Actions]]></string>

+ 15 - 10
modules/boonex/payment/install/sql/enable.sql

@@ -25,9 +25,9 @@ INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `lay
 ('bx_payment_cart_thank_you', '_bx_payment_page_title_sys_cart_thank_you', '_bx_payment_page_title_cart_thank_you', @sName, 5, 2147483647, 1, 'payment-cart-thank-you', 'page.php?i=payment-cart-thank-you', '', '', '', 0, 1, 0, 'BxPaymentPageCart', 'modules/boonex/payment/classes/BxPaymentPageCart.php'),
 ('bx_payment_history', '_bx_payment_page_title_sys_history', '_bx_payment_page_title_history', @sName, 5, 2147483647, 1, 'payment-history', 'page.php?i=payment-history', '', '', '', 0, 1, 0, 'BxPaymentPageHistory', 'modules/boonex/payment/classes/BxPaymentPageHistory.php'),
 
-('bx_payment_sbs_list', '_bx_payment_page_title_sys_sbs_list', '_bx_payment_page_title_sbs_list', @sName, 5, 2147483647, 1, 'payment-sbs-list', 'page.php?i=payment-sbs-list', '', '', '', 0, 1, 0, 'BxPaymentPageSubscriptions', 'modules/boonex/payment/classes/BxPaymentPageSubscriptions.php'),
+('bx_payment_sbs_list_my', '_bx_payment_page_title_sys_sbs_list_my', '_bx_payment_page_title_sbs_list_my', @sName, 5, 2147483647, 1, 'payment-sbs-list-my', 'page.php?i=payment-sbs-list-my', '', '', '', 0, 1, 0, 'BxPaymentPageSubscriptions', 'modules/boonex/payment/classes/BxPaymentPageSubscriptions.php'),
+('bx_payment_sbs_list_all', '_bx_payment_page_title_sys_sbs_list_all', '_bx_payment_page_title_sbs_list_all', @sName, 5, 192, 1, 'payment-sbs-list-all', 'page.php?i=payment-sbs-list-all', '', '', '', 0, 1, 0, 'BxPaymentPageSubscriptions', 'modules/boonex/payment/classes/BxPaymentPageSubscriptions.php'),
 ('bx_payment_sbs_history', '_bx_payment_page_title_sys_sbs_history', '_bx_payment_page_title_sbs_history', @sName, 5, 2147483647, 1, 'payment-sbs-history', 'page.php?i=payment-sbs-history', '', '', '', 0, 1, 0, 'BxPaymentPageSubscriptions', 'modules/boonex/payment/classes/BxPaymentPageSubscriptions.php'),
-('bx_payment_sbs_administration', '_bx_payment_page_title_sys_sbs_administration', '_bx_payment_page_title_sbs_administration', @sName, 5, 192, 1, 'payment-sbs-administration', 'page.php?i=payment-sbs-administration', '', '', '', 0, 1, 0, 'BxPaymentPageSubscriptions', 'modules/boonex/payment/classes/BxPaymentPageSubscriptions.php'),
 
 ('bx_payment_orders', '_bx_payment_page_title_sys_orders', '_bx_payment_page_title_orders', @sName, 5, 2147483647, 1, 'payment-orders', 'page.php?i=payment-orders', '', '', '', 0, 1, 0, 'BxPaymentPageOrders', 'modules/boonex/payment/classes/BxPaymentPageOrders.php'),
 ('bx_payment_details', '_bx_payment_page_title_sys_details', '_bx_payment_page_title_details', @sName, 5, 2147483647, 1, 'payment-details', 'page.php?i=payment-details', '', '', '', 0, 1, 0, 'BxPaymentPageDetails', 'modules/boonex/payment/classes/BxPaymentPageDetails.php');
@@ -40,9 +40,9 @@ INSERT INTO `sys_pages_blocks` (`object`, `cell_id`, `module`, `title`, `designb
 ('bx_payment_cart_thank_you', 1, @sName, '_bx_payment_page_block_title_cart_thank_you', 11, 2147483647, 'lang', '_bx_payment_page_block_content_cart_thank_you', 0, 0, 1),
 ('bx_payment_history', 1, @sName, '_bx_payment_page_block_title_history', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:10:"bx_payment";s:6:"method";s:22:"get_block_cart_history";s:6:"params";a:0:{}s:5:"class";s:4:"Cart";}', 0, 0, 1),
 
-('bx_payment_sbs_list', 1, @sName, '_bx_payment_page_block_title_sbs_list', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:10:"bx_payment";s:6:"method";s:14:"get_block_list";s:6:"params";a:0:{}s:5:"class";s:13:"Subscriptions";}', 0, 0, 1),
+('bx_payment_sbs_list_my', 1, @sName, '_bx_payment_page_block_title_sbs_list_my', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:10:"bx_payment";s:6:"method";s:17:"get_block_list_my";s:6:"params";a:0:{}s:5:"class";s:13:"Subscriptions";}', 0, 0, 1),
+('bx_payment_sbs_list_all', 1, @sName, '_bx_payment_page_block_title_sbs_list_all', 11, 192, 'service', 'a:4:{s:6:"module";s:10:"bx_payment";s:6:"method";s:18:"get_block_list_all";s:6:"params";a:0:{}s:5:"class";s:13:"Subscriptions";}', 0, 0, 1),
 ('bx_payment_sbs_history', 1, @sName, '_bx_payment_page_block_title_sbs_history', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:10:"bx_payment";s:6:"method";s:17:"get_block_history";s:6:"params";a:0:{}s:5:"class";s:13:"Subscriptions";}', 0, 0, 1),
-('bx_payment_sbs_administration', 1, @sName, '_bx_payment_page_block_title_sbs_administration', 11, 192, 'service', 'a:4:{s:6:"module";s:10:"bx_payment";s:6:"method";s:24:"get_block_administration";s:6:"params";a:0:{}s:5:"class";s:13:"Subscriptions";}', 0, 0, 1),
 
 ('bx_payment_orders', 1, @sName, '_bx_payment_page_block_title_orders', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:10:"bx_payment";s:6:"method";s:16:"get_block_orders";s:6:"params";a:0:{}s:5:"class";s:6:"Orders";}', 0, 0, 1),
 ('bx_payment_details', 1, @sName, '_bx_payment_page_block_title_details', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:10:"bx_payment";s:6:"method";s:17:"get_block_details";s:6:"params";a:0:{}s:5:"class";s:7:"Details";}', 0, 0, 1);
@@ -61,14 +61,15 @@ INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `titl
 
 -- MENU: subscriptions submenu
 INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
-('bx_payment_menu_sbs_submenu', '_bx_payment_menu_title_sbs_submenu', 'bx_payment_menu_sbs_submenu', 'bx_payment', 8, 0, 1, '', '');
+('bx_payment_menu_sbs_submenu', '_bx_payment_menu_title_sbs_submenu', 'bx_payment_menu_sbs_submenu', 'bx_payment', 6, 0, 1, '', '');
 
 INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
 ('bx_payment_menu_sbs_submenu', 'bx_payment', '_bx_payment_menu_set_title_sbs_submenu', 0);
 
 INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `editable`, `order`) VALUES 
-('bx_payment_menu_sbs_submenu', 'bx_payment', 'sbs-list', '_bx_payment_menu_item_title_system_sbs_list', '_bx_payment_menu_item_title_sbs_list', 'page.php?i=payment-sbs-list', '', '_self', '', '', '', 2147483647, 1, 0, 1, 1),
-('bx_payment_menu_sbs_submenu', 'bx_payment', 'sbs-history', '_bx_payment_menu_item_title_system_sbs_history', '_bx_payment_menu_item_title_sbs_history', 'page.php?i=payment-sbs-history', '', '_self', '', '', '', 2147483647, 1, 0, 1, 2);
+('bx_payment_menu_sbs_submenu', 'bx_payment', 'sbs-list-all', '_bx_payment_menu_item_title_system_sbs_list_all', '_bx_payment_menu_item_title_sbs_list_all', 'page.php?i=payment-sbs-list-all', '', '_self', '', '', '', 192, 1, 0, 1, 1),
+('bx_payment_menu_sbs_submenu', 'bx_payment', 'sbs-list-my', '_bx_payment_menu_item_title_system_sbs_list_my', '_bx_payment_menu_item_title_sbs_list_my', 'page.php?i=payment-sbs-list-my', '', '_self', '', '', '', 2147483646, 1, 0, 1, 2),
+('bx_payment_menu_sbs_submenu', 'bx_payment', 'sbs-history', '_bx_payment_menu_item_title_system_sbs_history', '_bx_payment_menu_item_title_sbs_history', 'page.php?i=payment-sbs-history', '', '_self', '', '', '', 2147483646, 1, 0, 1, 3);
 
 -- MENU: subscription actions
 INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
@@ -82,15 +83,19 @@ INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `titl
 
 -- MENU: orders submenu
 INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
-('bx_payment_menu_orders_submenu', '_bx_payment_menu_title_orders_submenu', 'bx_payment_menu_orders_submenu', 'bx_payment', 8, 0, 1, '', '');
+('bx_payment_menu_orders_submenu', '_bx_payment_menu_title_orders_submenu', 'bx_payment_menu_orders_submenu', 'bx_payment', 6, 0, 1, '', '');
 
 INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
 ('bx_payment_menu_orders_submenu', 'bx_payment', '_bx_payment_menu_set_title_orders_submenu', 0);
 
 INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `editable`, `order`) VALUES 
 ('bx_payment_menu_orders_submenu', 'bx_payment', 'orders-processed', '_bx_payment_menu_item_title_system_orders_processed', '_bx_payment_menu_item_title_orders_processed', 'page.php?i=payment-orders&type=processed', '', '_self', '', '', '', 2147483647, 1, 0, 1, 1),
-('bx_payment_menu_orders_submenu', 'bx_payment', 'orders-pending', '_bx_payment_menu_item_title_system_orders_pending', '_bx_payment_menu_item_title_orders_pending', 'page.php?i=payment-orders&type=pending', '', '_self', '', '', '', 2147483647, 1, 0, 1, 2),
-('bx_payment_menu_orders_submenu', 'bx_payment', 'details', '_bx_payment_menu_item_title_system_details', '_bx_payment_menu_item_title_details', 'page.php?i=payment-details', '', '_self', '', '', '', 2147483647, 1, 0, 1, 3);
+('bx_payment_menu_orders_submenu', 'bx_payment', 'orders-pending', '_bx_payment_menu_item_title_system_orders_pending', '_bx_payment_menu_item_title_orders_pending', 'page.php?i=payment-orders&type=pending', '', '_self', '', '', '', 2147483647, 1, 0, 1, 2);
+
+-- MENU: account settings menu
+SET @iMoAccountSettings = (SELECT IFNULL(MAX(`order`), 0) FROM `sys_menu_items` WHERE `set_name`='sys_account_settings' AND `name` <> 'account-settings-more' LIMIT 1);
+INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `editable`, `order`) VALUES
+('sys_account_settings', 'bx_payment', 'payment-details', '_bx_payment_menu_item_title_system_details', '_bx_payment_menu_item_title_details', 'page.php?i=payment-details', '', '_self', '', '', '', 2147483646, 1, 0, 1, @iMoAccountSettings + 1);
 
 
 -- ALERTS

+ 23 - 23
modules/boonex/payment/install/sql/install.sql

@@ -203,9 +203,9 @@ INSERT INTO `sys_objects_grid` (`object`, `source_type`, `source`, `table`, `fie
 ('bx_payment_grid_carts', 'Array', '', '', 'vendor_id', '', '', '', 20, NULL, 'start', '', '', '', 'like', '', '', 2147483647, 'BxPaymentGridCarts', 'modules/boonex/payment/classes/BxPaymentGridCarts.php'),
 ('bx_payment_grid_cart', 'Array', '', '', 'descriptor', '', '', '', 20, NULL, 'start', '', 'title,description', '', 'like', '', '', 2147483647, 'BxPaymentGridCart', 'modules/boonex/payment/classes/BxPaymentGridCart.php'),
 
-('bx_payment_grid_sbs_list', 'Sql', 'SELECT `ttp`.`id` AS `id`, `ttp`.`seller_id` AS `seller_id`, `ts`.`customer_id` AS `customer_id`, `ts`.`subscription_id` AS `subscription_id`, `ttp`.`provider` AS `provider`, `ts`.`date` AS `date` FROM `bx_payment_subscriptions` AS `ts` LEFT JOIN `bx_payment_transactions_pending` AS `ttp` ON `ts`.`pending_id`=`ttp`.`id` WHERE 1 AND `ttp`.`type`=''recurring'' ', 'bx_payment_subscriptions', 'id', 'date', '', '', 100, NULL, 'start', '', 'ts`.`customer_id,ts`.`subscription_id,ts`.`date', '', 'auto', '', '', 2147483647, 'BxPaymentGridSbsList', 'modules/boonex/payment/classes/BxPaymentGridSbsList.php'),
+('bx_payment_grid_sbs_list_my', 'Sql', 'SELECT `ttp`.`id` AS `id`, `ttp`.`seller_id` AS `seller_id`, `ts`.`customer_id` AS `customer_id`, `ts`.`subscription_id` AS `subscription_id`, `ttp`.`provider` AS `provider`, `ts`.`date` AS `date` FROM `bx_payment_subscriptions` AS `ts` LEFT JOIN `bx_payment_transactions_pending` AS `ttp` ON `ts`.`pending_id`=`ttp`.`id` WHERE 1 AND `ttp`.`type`=''recurring'' ', 'bx_payment_subscriptions', 'id', 'date', '', '', 100, NULL, 'start', '', 'ts`.`customer_id,ts`.`subscription_id,ts`.`date', '', 'auto', '', '', 2147483647, 'BxPaymentGridSbsList', 'modules/boonex/payment/classes/BxPaymentGridSbsList.php'),
+('bx_payment_grid_sbs_list_all', 'Sql', 'SELECT `ttp`.`id` AS `id`, `ttp`.`client_id` AS `client_id`, `ttp`.`seller_id` AS `seller_id`, `ts`.`customer_id` AS `customer_id`, `ts`.`subscription_id` AS `subscription_id`, `ttp`.`provider` AS `provider`, `ts`.`paid` AS `paid`, `ts`.`date` AS `date` FROM `bx_payment_subscriptions` AS `ts` LEFT JOIN `bx_payment_transactions_pending` AS `ttp` ON `ts`.`pending_id`=`ttp`.`id` WHERE 1 AND `ttp`.`type`=''recurring'' ', 'bx_payment_subscriptions', 'id', 'date', '', '', 100, NULL, 'start', '', 'ts`.`customer_id,ts`.`subscription_id,ts`.`date', '', 'auto', '', '', 192, 'BxPaymentGridSbsAdministration', 'modules/boonex/payment/classes/BxPaymentGridSbsAdministration.php'),
 ('bx_payment_grid_sbs_history', 'Sql', 'SELECT `tt`.`id` AS `id`, `tt`.`seller_id` AS `seller_id`, `ttp`.`order` AS `transaction`, `tt`.`license` AS `license`, `tt`.`amount` AS `amount`, `tt`.`date` AS `date` FROM `bx_payment_transactions` AS `tt` LEFT JOIN `bx_payment_transactions_pending` AS `ttp` ON `tt`.`pending_id`=`ttp`.`id` WHERE 1 AND `ttp`.`type`=''recurring'' ', 'bx_payment_transactions', 'id', 'date', '', '', 100, NULL, 'start', '', 'ttp`.`order,tt`.`license,tt`.`amount,tt`.`date', '', 'auto', '', '', 2147483647, 'BxPaymentGridSbsHistory', 'modules/boonex/payment/classes/BxPaymentGridSbsHistory.php'),
-('bx_payment_grid_sbs_administration', 'Sql', 'SELECT `ttp`.`id` AS `id`, `ttp`.`client_id` AS `client_id`, `ttp`.`seller_id` AS `seller_id`, `ts`.`customer_id` AS `customer_id`, `ts`.`subscription_id` AS `subscription_id`, `ttp`.`provider` AS `provider`, `ts`.`paid` AS `paid`, `ts`.`date` AS `date` FROM `bx_payment_subscriptions` AS `ts` LEFT JOIN `bx_payment_transactions_pending` AS `ttp` ON `ts`.`pending_id`=`ttp`.`id` WHERE 1 AND `ttp`.`type`=''recurring'' ', 'bx_payment_subscriptions', 'id', 'date', '', '', 100, NULL, 'start', '', 'ts`.`customer_id,ts`.`subscription_id,ts`.`date', '', 'auto', '', '', 192, 'BxPaymentGridSbsAdministration', 'modules/boonex/payment/classes/BxPaymentGridSbsAdministration.php'),
 
 ('bx_payment_grid_orders_history', 'Sql', 'SELECT `tt`.`id` AS `id`, `tt`.`seller_id` AS `seller_id`, `ttp`.`order` AS `transaction`, `tt`.`license` AS `license`, `tt`.`amount` AS `amount`, `tt`.`date` AS `date` FROM `bx_payment_transactions` AS `tt` LEFT JOIN `bx_payment_transactions_pending` AS `ttp` ON `tt`.`pending_id`=`ttp`.`id` WHERE 1 AND `ttp`.`type`=''single'' ', 'bx_payment_transactions', 'id', 'date', '', '', 100, NULL, 'start', '', 'ttp`.`order,tt`.`license,tt`.`amount,tt`.`date', '', 'auto', '', '', 2147483647, 'BxPaymentGridHistory', 'modules/boonex/payment/classes/BxPaymentGridHistory.php'),
 ('bx_payment_grid_orders_processed', 'Sql', 'SELECT `tt`.`id` AS `id`, `tt`.`client_id` AS `client_id`, `tt`.`seller_id` AS `seller_id`, `tt`.`module_id` AS `module_id`, `tt`.`item_id` AS `item_id`, `tt`.`item_count` AS `item_count`, `ttp`.`order` AS `transaction`, `ttp`.`error_msg` AS `error_msg`, `ttp`.`provider` AS `provider`, `tt`.`license` AS `license`, `tt`.`amount` AS `amount`, `tt`.`date` AS `date` FROM `bx_payment_transactions` AS `tt` LEFT JOIN `bx_payment_transactions_pending` AS `ttp` ON `tt`.`pending_id`=`ttp`.`id` WHERE 1 ', 'bx_payment_transactions', 'id', 'date', '', '', 100, NULL, 'start', '', 'ttp`.`order,tt`.`license,tt`.`amount,tt`.`date', '', 'auto', '', '', 2147483647, 'BxPaymentGridProcessed', 'modules/boonex/payment/classes/BxPaymentGridProcessed.php'),
@@ -225,13 +225,22 @@ INSERT INTO `sys_grid_fields` (`object`, `name`, `title`, `width`, `translatable
 ('bx_payment_grid_cart', 'price_single', '_bx_payment_grid_column_title_crt_price', '10%', 0, '16', '', 5),
 ('bx_payment_grid_cart', 'actions', '', '18%', 0, '', '', 6),
 
-('bx_payment_grid_sbs_list', 'checkbox', '', '2%', 0, '', '', 1),
-('bx_payment_grid_sbs_list', 'seller_id', '_bx_payment_grid_column_title_sbs_seller_id', '20%', 0, '24', '', 2),
-('bx_payment_grid_sbs_list', 'customer_id', '_bx_payment_grid_column_title_sbs_customer_id', '20%', 0, '24', '', 3),
-('bx_payment_grid_sbs_list', 'subscription_id', '_bx_payment_grid_column_title_sbs_subscription_id', '20%', 0, '24', '', 4),
-('bx_payment_grid_sbs_list', 'provider', '_bx_payment_grid_column_title_sbs_provider', '10%', 0, '16', '', 5),
-('bx_payment_grid_sbs_list', 'date', '_bx_payment_grid_column_title_sbs_date', '14%', 0, '10', '', 6),
-('bx_payment_grid_sbs_list', 'actions', '', '14%', 0, '', '', 7),
+('bx_payment_grid_sbs_list_my', 'checkbox', '', '2%', 0, '', '', 1),
+('bx_payment_grid_sbs_list_my', 'seller_id', '_bx_payment_grid_column_title_sbs_seller_id', '20%', 0, '24', '', 2),
+('bx_payment_grid_sbs_list_my', 'customer_id', '_bx_payment_grid_column_title_sbs_customer_id', '20%', 0, '24', '', 3),
+('bx_payment_grid_sbs_list_my', 'subscription_id', '_bx_payment_grid_column_title_sbs_subscription_id', '20%', 0, '24', '', 4),
+('bx_payment_grid_sbs_list_my', 'provider', '_bx_payment_grid_column_title_sbs_provider', '10%', 0, '16', '', 5),
+('bx_payment_grid_sbs_list_my', 'date', '_bx_payment_grid_column_title_sbs_date', '14%', 0, '10', '', 6),
+('bx_payment_grid_sbs_list_my', 'actions', '', '14%', 0, '', '', 7),
+
+('bx_payment_grid_sbs_list_all', 'seller_id', '_bx_payment_grid_column_title_sbs_seller_id', '15%', 0, '24', '', 1),
+('bx_payment_grid_sbs_list_all', 'client_id', '_bx_payment_grid_column_title_sbs_client_id', '15%', 0, '24', '', 2),
+('bx_payment_grid_sbs_list_all', 'customer_id', '_bx_payment_grid_column_title_sbs_customer_id', '15%', 0, '18', '', 3),
+('bx_payment_grid_sbs_list_all', 'subscription_id', '_bx_payment_grid_column_title_sbs_subscription_id', '15%', 0, '18', '', 4),
+('bx_payment_grid_sbs_list_all', 'provider', '_bx_payment_grid_column_title_sbs_provider', '10%', 0, '16', '', 5),
+('bx_payment_grid_sbs_list_all', 'paid', '_bx_payment_grid_column_title_sbs_paid', '4%', 0, '4', '', 6),
+('bx_payment_grid_sbs_list_all', 'date', '_bx_payment_grid_column_title_sbs_date', '10%', 0, '10', '', 7),
+('bx_payment_grid_sbs_list_all', 'actions', '', '16%', 0, '', '', 8),
 
 ('bx_payment_grid_sbs_history', 'seller_id', '_bx_payment_grid_column_title_sbs_seller_id', '24%', 0, '20', '', 1),
 ('bx_payment_grid_sbs_history', 'transaction', '_bx_payment_grid_column_title_sbs_transaction', '22%', 0, '18', '', 2),
@@ -240,15 +249,6 @@ INSERT INTO `sys_grid_fields` (`object`, `name`, `title`, `width`, `translatable
 ('bx_payment_grid_sbs_history', 'date', '_bx_payment_grid_column_title_sbs_date', '10%', 0, '10', '', 5),
 ('bx_payment_grid_sbs_history', 'actions', '', '12%', 0, '', '', 6),
 
-('bx_payment_grid_sbs_administration', 'seller_id', '_bx_payment_grid_column_title_sbs_seller_id', '15%', 0, '24', '', 1),
-('bx_payment_grid_sbs_administration', 'client_id', '_bx_payment_grid_column_title_sbs_client_id', '15%', 0, '24', '', 2),
-('bx_payment_grid_sbs_administration', 'customer_id', '_bx_payment_grid_column_title_sbs_customer_id', '15%', 0, '18', '', 3),
-('bx_payment_grid_sbs_administration', 'subscription_id', '_bx_payment_grid_column_title_sbs_subscription_id', '15%', 0, '18', '', 4),
-('bx_payment_grid_sbs_administration', 'provider', '_bx_payment_grid_column_title_sbs_provider', '10%', 0, '16', '', 5),
-('bx_payment_grid_sbs_administration', 'paid', '_bx_payment_grid_column_title_sbs_paid', '4%', 0, '4', '', 6),
-('bx_payment_grid_sbs_administration', 'date', '_bx_payment_grid_column_title_sbs_date', '10%', 0, '10', '', 7),
-('bx_payment_grid_sbs_administration', 'actions', '', '16%', 0, '', '', 8),
-
 ('bx_payment_grid_orders_history', 'seller_id', '_bx_payment_grid_column_title_ods_seller_id', '24%', 0, '20', '', 1),
 ('bx_payment_grid_orders_history', 'transaction', '_bx_payment_grid_column_title_ods_transaction', '22%', 0, '18', '', 2),
 ('bx_payment_grid_orders_history', 'license', '_bx_payment_grid_column_title_ods_license', '22%', 0, '18', '', 3),
@@ -279,13 +279,13 @@ INSERT INTO `sys_grid_actions` (`object`, `type`, `name`, `title`, `icon`, `icon
 ('bx_payment_grid_cart', 'bulk', 'checkout', '_bx_payment_grid_action_title_crt_checkout', '', 0, 0, 1),
 ('bx_payment_grid_cart', 'single', 'delete', '_bx_payment_grid_action_title_crt_delete', 'remove', 1, 1, 1),
 
-('bx_payment_grid_sbs_list', 'single', 'view_order', '_bx_payment_grid_action_title_sbs_view_order', 'ellipsis-h', 1, 0, 1),
-('bx_payment_grid_sbs_list', 'single', 'actions', '_bx_payment_grid_action_title_sbs_actions', 'cog', 1, 0, 2),
+('bx_payment_grid_sbs_list_my', 'single', 'view_order', '_bx_payment_grid_action_title_sbs_view_order', 'ellipsis-h', 1, 0, 1),
+('bx_payment_grid_sbs_list_my', 'single', 'actions', '_bx_payment_grid_action_title_sbs_actions', 'cog', 1, 0, 2),
 
-('bx_payment_grid_sbs_history', 'single', 'view_order', '_bx_payment_grid_action_title_sbs_view_order', 'ellipsis-h', 1, 0, 1),
+('bx_payment_grid_sbs_list_all', 'single', 'view_order', '_bx_payment_grid_action_title_sbs_view_order', 'ellipsis-h', 1, 0, 1),
+('bx_payment_grid_sbs_list_all', 'single', 'cancel', '_bx_payment_grid_action_title_sbs_cancel', 'times', 1, 1, 2),
 
-('bx_payment_grid_sbs_administration', 'single', 'view_order', '_bx_payment_grid_action_title_sbs_view_order', 'ellipsis-h', 1, 0, 1),
-('bx_payment_grid_sbs_administration', 'single', 'cancel', '_bx_payment_grid_action_title_sbs_cancel', 'times', 1, 1, 2),
+('bx_payment_grid_sbs_history', 'single', 'view_order', '_bx_payment_grid_action_title_sbs_view_order', 'ellipsis-h', 1, 0, 1),
 
 ('bx_payment_grid_orders_history', 'single', 'view_order', '_bx_payment_grid_action_title_ods_view_order', 'ellipsis-h', 1, 0, 1),
 

+ 21 - 0
modules/boonex/protean/data/template/system/scripts/BxTemplMenuAccountDashboard.php

@@ -0,0 +1,21 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    UnaTemplate UNA Template Classes
+ * @{
+ */
+
+/**
+ * @see BxDolMenu
+ */
+class BxTemplMenuAccountDashboard extends BxBaseMenuAccountDashboard
+{
+    public function __construct ($aObject, $oTemplate = false)
+    {
+        parent::__construct ($aObject, $oTemplate);
+    }
+}
+
+/** @} */

+ 2 - 2
modules/boonex/russian/data/langs/bx_market/ru.xml

@@ -242,8 +242,8 @@
 	<string name="_bx_market_menu_item_title_admt_products"><![CDATA[Продукты - {addon} спрятано]]></string>
 	<string name="_bx_market_menu_item_title_manage_my"><![CDATA[Мои Продукты]]></string>
 	<string name="_bx_market_menu_item_title_manage_all"><![CDATA[Все Продукты]]></string>
-	<string name="_bx_market_menu_item_title_system_notifications_licenses"><![CDATA[Лицензии]]></string>
-	<string name="_bx_market_menu_item_title_notifications_licenses"><![CDATA[Лицензии]]></string>
+	<string name="_bx_market_menu_item_title_system_licenses"><![CDATA[Лицензии]]></string>
+	<string name="_bx_market_menu_item_title_licenses"><![CDATA[Лицензии]]></string>
     <string name="_bx_market_menu_title_snippet"><![CDATA[Действия с отрывоком]]></string>
     <string name="_bx_market_menu_set_title_snippet"><![CDATA[Действия с отрывоком]]></string>
     <string name="_bx_market_menu_item_title_system_snippet_more"><![CDATA[Ещё действия]]></string>

+ 15 - 15
modules/boonex/russian/data/langs/bx_payment/ru.xml

@@ -19,17 +19,17 @@
     <string name="_bx_payment_page_block_title_cart_thank_you"><![CDATA[Спасибо!]]></string>
     <string name="_bx_payment_page_block_content_cart_thank_you"><![CDATA[Спасибо! Оплата успешно завершена. Данные будут обработаны в ближайшее время. Пожалуйста, подождите.]]></string>
 
-    <string name="_bx_payment_page_title_sys_sbs_list"><![CDATA[Лист подписок]]></string>
-    <string name="_bx_payment_page_title_sbs_list"><![CDATA[Подписки]]></string>
-    <string name="_bx_payment_page_block_title_sbs_list"><![CDATA[Подписки]]></string>
+    <string name="_bx_payment_page_title_sys_sbs_list_my"><![CDATA[Мои подписки]]></string>
+    <string name="_bx_payment_page_title_sbs_list_my"><![CDATA[Мои подписки]]></string>
+    <string name="_bx_payment_page_block_title_sbs_list_my"><![CDATA[Мои подписки]]></string>
 
-    <string name="_bx_payment_page_title_sys_sbs_history"><![CDATA[История подписок]]></string>
-    <string name="_bx_payment_page_title_sbs_history"><![CDATA[История выплат]]></string>
-    <string name="_bx_payment_page_block_title_sbs_history"><![CDATA[История выплат]]></string>
+    <string name="_bx_payment_page_title_sys_sbs_list_all"><![CDATA[Все подписки]]></string>
+    <string name="_bx_payment_page_title_sbs_list_all"><![CDATA[Все подписки]]></string>
+    <string name="_bx_payment_page_block_title_sbs_list_all"><![CDATA[Все подписки]]></string>
 
-    <string name="_bx_payment_page_title_sys_sbs_administration"><![CDATA[Управление подписками]]></string>
-    <string name="_bx_payment_page_title_sbs_administration"><![CDATA[Подписки]]></string>
-    <string name="_bx_payment_page_block_title_sbs_administration"><![CDATA[Подписки]]></string>
+    <string name="_bx_payment_page_title_sys_sbs_history"><![CDATA[Мои выплаты]]></string>
+    <string name="_bx_payment_page_title_sbs_history"><![CDATA[Мои выплаты]]></string>
+    <string name="_bx_payment_page_block_title_sbs_history"><![CDATA[Мои выплаты]]></string>
 
 	<string name="_bx_payment_page_title_sys_history"><![CDATA[История покупок]]></string>
 	<string name="_bx_payment_page_title_history"><![CDATA[История покупок]]></string>
@@ -61,7 +61,7 @@
     <string name="_bx_payment_menu_item_title_system_orders_pending"><![CDATA[Обрабатываемые заказы]]></string>
     <string name="_bx_payment_menu_item_title_orders_pending"><![CDATA[Обрабатываемые]]></string>
     <string name="_bx_payment_menu_item_title_system_details"><![CDATA[Детали платежных систем]]></string>
-    <string name="_bx_payment_menu_item_title_details"><![CDATA[Настройки]]></string>
+    <string name="_bx_payment_menu_item_title_details"><![CDATA[Платежные системы]]></string>
 
 	<string name="_bx_payment_menu_title_cart_submenu"><![CDATA[Подменю корзины]]></string>
     <string name="_bx_payment_menu_set_title_cart_submenu"><![CDATA[Подменю корзины]]></string>
@@ -72,12 +72,12 @@
 
     <string name="_bx_payment_menu_title_sbs_submenu"><![CDATA[Подменю подписок]]></string>
     <string name="_bx_payment_menu_set_title_sbs_submenu"><![CDATA[Подменю подписок]]></string>
-    <string name="_bx_payment_menu_item_title_system_sbs_list"><![CDATA[Лист подписок]]></string>
-    <string name="_bx_payment_menu_item_title_sbs_list"><![CDATA[Подписки]]></string>
+    <string name="_bx_payment_menu_item_title_system_sbs_list_my"><![CDATA[Лист моих подписок]]></string>
     <string name="_bx_payment_menu_item_title_sbs_list_my"><![CDATA[Мои подписки]]></string>
-    <string name="_bx_payment_menu_item_title_sbs_list_administration"><![CDATA[Все подписки]]></string>
-    <string name="_bx_payment_menu_item_title_system_sbs_history"><![CDATA[История подписок]]></string>
-    <string name="_bx_payment_menu_item_title_sbs_history"><![CDATA[История выплат]]></string>
+    <string name="_bx_payment_menu_item_title_system_sbs_list_all"><![CDATA[Лист всех подписок]]></string>
+    <string name="_bx_payment_menu_item_title_sbs_list_all"><![CDATA[Все подписки]]></string>
+    <string name="_bx_payment_menu_item_title_system_sbs_history"><![CDATA[История моих выплат]]></string>
+    <string name="_bx_payment_menu_item_title_sbs_history"><![CDATA[Мои выплаты]]></string>
 
     <string name="_bx_payment_menu_title_sbs_actions"><![CDATA[Действия с подпиской]]></string>
     <string name="_bx_payment_menu_set_title_sbs_actions"><![CDATA[Действия с подпиской]]></string>

+ 3 - 0
modules/boonex/russian/data/langs/system/ru.xml

@@ -2057,6 +2057,7 @@
 	<string name="_sys_menu_item_title_system_terms"><![CDATA[Правила]]></string>
 	<string name="_sys_menu_item_title_system_account_menu"><![CDATA[Аккаунт]]></string>
 	<string name="_sys_menu_item_title_system_account_profile_context"><![CDATA[Профили]]></string>
+	<string name="_sys_menu_item_title_system_account_dashboard"><![CDATA[Панель]]></string>
 	<string name="_sys_menu_item_title_system_account_dashboard_administration"><![CDATA[Администрация]]></string>
 	<string name="_sys_menu_item_title_system_account_settings"><![CDATA[Настройки]]></string>
 	<string name="_sys_menu_item_title_system_account_settings_delete"><![CDATA[Удалить]]></string>
@@ -2086,6 +2087,7 @@
     <string name="_sys_menu_item_title_system_social_sharing_twitter"><![CDATA[Поделиться в Twitter]]></string>
     <string name="_sys_menu_item_title_system_social_sharing_pinterest"><![CDATA[Поделиться в Pinterest]]></string>
 	<string name="_sys_menu_set_title_account"><![CDATA[Аккаунт]]></string>
+	<string name="_sys_menu_set_title_account_dashboard"><![CDATA[Аккаунт панель]]></string>
 	<string name="_sys_menu_set_title_account_dashboard_manage_tools"><![CDATA[Инструменты управления Панелью Аккаунта]]></string>
 	<string name="_sys_menu_set_title_account_settings"><![CDATA[Настройки Аккаунта]]></string>
 	<string name="_sys_menu_set_title_account_settings_more"><![CDATA[Дополнительные Настройки Аккаунта]]></string>
@@ -2123,6 +2125,7 @@
 	<string name="_sys_menu_template_title_account_popup"><![CDATA[Аккаунт - Всплывающие]]></string>
 	<string name="_sys_menu_template_title_custom"><![CDATA[Индивидуальные элементы меню]]></string>
 	<string name="_sys_menu_title_account"><![CDATA[Аккаунт - Меню]]></string>
+	<string name="_sys_menu_title_account_dashboard"><![CDATA[Аккаунт Панель - Меню]]></string>
 	<string name="_sys_menu_title_account_dashboard_manage_tools"><![CDATA[Аккаунт Панель - Управление Меню Инструментов]]></string>
     <string name="_sys_menu_title_account_notifications"><![CDATA[Меню с уведомлениями]]></string>
     <string name="_sys_menu_title_account_popup"><![CDATA[Аккаунт - Всплывающее Меню]]></string>

+ 50 - 0
template/scripts/BxBaseMenuAccountDashboard.php

@@ -0,0 +1,50 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    UnaBaseView UNA Base Representation Classes
+ * @{
+ */
+
+/**
+ * Menu representation.
+ * @see BxDolMenu
+ */
+class BxBaseMenuAccountDashboard extends BxTemplMenu
+{
+    public function __construct ($aObject, $oTemplate)
+    {
+        parent::__construct ($aObject, $oTemplate);
+    }
+
+    /**
+     * Check if menu items is visible with extended checking for friends notifications
+     * @param $a menu item array
+     * @return boolean
+     */
+    protected function _isVisible ($a)
+    {
+        // default visible settings
+        if (!BxDolAcl::getInstance()->isMemberLevelInSet($a['visible_for_levels']))
+            return false;
+
+        switch ($a['name']) {
+            case 'dashboard-subscriptions':
+        		$oPayments = BxDolPayments::getInstance();
+        		if(!$oPayments->isActive())
+        			return false;
+        		break;
+
+        	case 'dashboard-orders':
+        		$oPayments = BxDolPayments::getInstance();
+        		if(!$oPayments->isActive())
+        			return false;
+        		break;
+        }
+
+        return true;
+    }
+}
+
+/** @} */

+ 2 - 8
template/scripts/BxBaseMenuAccountNotifications.php

@@ -30,19 +30,13 @@ class BxBaseMenuAccountNotifications extends BxTemplMenu
             return false;
 
         switch ($a['name']) {
-        	case 'cart':
+        	case 'notifications-cart':
         		$oPayments = BxDolPayments::getInstance();
         		if(!$oPayments->isActive())
         			return false;
         		break;
 
-            case 'subscriptions':
-        		$oPayments = BxDolPayments::getInstance();
-        		if(!$oPayments->isActive())
-        			return false;
-        		break;
-
-        	case 'orders':
+        	case 'notifications-orders':
         		$oPayments = BxDolPayments::getInstance();
         		if(!$oPayments->isActive())
         			return false;

+ 6 - 0
template/scripts/BxBasePageDashboard.php

@@ -15,6 +15,12 @@ class BxBasePageDashboard extends BxTemplPage
     public function __construct($aObject, $oTemplate)
     {
         parent::__construct($aObject, $oTemplate);
+
+        $oMenuSubmenu = BxDolMenu::getObjectInstance('sys_site_submenu');
+        if($oMenuSubmenu) {
+            $sMenuSubmenu = 'sys_account_dashboard';
+            $oMenuSubmenu->setObjectSubmenu($sMenuSubmenu, array('title' => _t('_sys_menu_item_title_account_dashboard'), 'link' => '', 'icon' => ''));
+        }
     }
 }