فهرست منبع

Merge branch 'master' of https://github.com/unaio/una

AntonLV 6 سال پیش
والد
کامیت
9543c8e870

+ 5 - 1
inc/classes/BxDolAccount.php

@@ -44,7 +44,7 @@ class BxDolAccount extends BxDolFactory implements iBxDolSingleton
     /**
      * Get singleton instance of the class
      */
-    public static function getInstance($mixedAccountId = false)
+    public static function getInstance($mixedAccountId = false,  $bClearCache = false)
     {
         if (!$mixedAccountId)
             $mixedAccountId = getLoggedId();
@@ -54,6 +54,10 @@ class BxDolAccount extends BxDolFactory implements iBxDolSingleton
             return false;
 
         $sClass = __CLASS__ . '_' . $iAccountId;
+        
+        if ($bClearCache && isset($GLOBALS['bxDolClasses'][$sClass]))
+            unset($GLOBALS['bxDolClasses'][$sClass]);
+        
         if(!isset($GLOBALS['bxDolClasses'][$sClass]))
             $GLOBALS['bxDolClasses'][$sClass] = new BxDolAccount($iAccountId);
 

+ 3 - 1
install/sql/system.sql

@@ -226,7 +226,9 @@ INSERT INTO `sys_email_templates` (`Module`, `NameSystem`, `Name`, `Subject`, `B
 ('system', '_sys_et_txt_name_upgrade_modules_failed', 't_UpgradeModulesFailed', '_sys_et_txt_subject_upgrade_modules_failed', '_sys_et_txt_body_upgrade_modules_failed'),
 ('system', '_sys_et_txt_name_upgrade_success', 't_UpgradeSuccess', '_sys_et_txt_subject_upgrade_success', '_sys_et_txt_body_upgrade_success'),
 ('system', '_sys_et_txt_name_upgrade_modules_success', 't_UpgradeModulesSuccess', '_sys_et_txt_subject_upgrade_modules_success', '_sys_et_txt_body_upgrade_modules_success'),
-('system', '_sys_et_txt_name_bg_operation_failed', 't_BgOperationFailed', '_sys_et_txt_subject_bg_operation_failed', '_sys_et_txt_body_bg_operation_failed');
+('system', '_sys_et_txt_name_bg_operation_failed', 't_BgOperationFailed', '_sys_et_txt_subject_bg_operation_failed', '_sys_et_txt_body_bg_operation_failed'),
+('system', '_sys_et_txt_name_account_change_status_activate', 't_ChangeStatusAccountActivate', '_sys_et_txt_subject_account_change_status_activate', '_sys_et_txt_body_account_change_status_activate'),
+('system', '_sys_et_txt_name_account_change_status_suspended', 't_ChangeStatusAccountSuspend', '_sys_et_txt_subject_account_change_status_suspended', '_sys_et_txt_body_account_change_status_suspended');
 
 -- --------------------------------------------------------
 

+ 5 - 0
modules/base/connect/classes/BxBaseModConnectModule.php

@@ -16,6 +16,11 @@ class BxBaseModConnectModule extends BxBaseModGeneralModule
         parent::__construct($aModule);
     }
 
+    public function serviceGetSafeServices()
+    {
+        return array();
+    }
+
     public function serviceGetProfilesModules ()
     {
         $aModules = array();

+ 1 - 1
modules/base/general/classes/BxBaseModGeneralModule.php

@@ -458,7 +458,7 @@ class BxBaseModGeneralModule extends BxDolModule
      * @code bx_srv('bx_posts', 'browse_featured', [...]); @endcode
      * 
      * Display featured entries
-     * @param $sUnitView browseing unity view, 
+     * @param $sUnitView browsing unity view, 
      *                   such as: full, extended, gallery, showcase
      * @param $bEmptyMessage display or not "empty" message when there is no content
      * @param $bAjaxPaginate use AJAX paginate or not

+ 5 - 0
modules/base/notifications/classes/BxBaseModNotificationsModule.php

@@ -44,6 +44,11 @@ class BxBaseModNotificationsModule extends BxBaseModGeneralModule
         $this->_iOwnerId = 0;
     }
 
+    public function serviceGetSafeServices()
+    {
+        return array();
+    }
+
     /**
      * @page service Service Calls
      * @section bx_base_notifications Base Notifications

+ 5 - 0
modules/base/payment/classes/BxBaseModPaymentModule.php

@@ -22,6 +22,11 @@ class BxBaseModPaymentModule extends BxBaseModGeneralModule
         $this->_sLangsPrefix = $this->_oConfig->getPrefix('langs');
     }
 
+    public function serviceGetSafeServices()
+    {
+        return array();
+    }
+
     /**
      * @page service Service Calls
      * @section bx_base_payment Base Payment

+ 6 - 2
modules/base/profile/classes/BxBaseModProfileMenuSnippetMeta.php

@@ -49,6 +49,11 @@ class BxBaseModProfileMenuSnippetMeta extends BxBaseModGeneralMenuSnippetMeta
         if(!empty($this->_iContentId))
             $this->_oContentProfile = BxDolProfile::getInstanceByContentAndType($iContentId, $this->_sModule);
     }
+    
+    protected function getMenuItemConnectionJsCode($sConnection, $sAction, $iContentProfile, $aItem)
+    {
+        return 'bx_conn_action(this, \'' . $sConnection . '\', \'' . $sAction . '\', \'' . $iContentProfile . '\', false, function(oData, eLink) {$(eLink).parents(\'.bx-menu-item:first\').remove();})';
+    }
 
     public function setContentPublic($bContentPublic)
     {
@@ -118,7 +123,6 @@ class BxBaseModProfileMenuSnippetMeta extends BxBaseModGeneralMenuSnippetMeta
         if(!isLogged() || $this->_oModule->{$this->_aConnectionToFunctionCheck[$sConnection][$sAction]}($this->_aContentInfo) !== CHECK_ACTION_RESULT_ALLOWED)
             return false;
 
-        $iProfile = bx_get_logged_profile_id();
         $iContentProfile = $this->_oContentProfile->id();
 
         $oConnection = BxDolConnection::getObjectInstance($sConnection);
@@ -130,7 +134,7 @@ class BxBaseModProfileMenuSnippetMeta extends BxBaseModGeneralMenuSnippetMeta
             return false;
 
         return $this->getUnitMetaItemButtonSmall($sTitle, array(
-            'onclick' => 'bx_conn_action(this, \'' . $sConnection . '\', \'' . $sAction . '\', \'' . $iContentProfile . '\', false, function(oData, eLink) {$(eLink).parents(\'.bx-menu-item:first\').remove();})'
+            'onclick' => $this->getMenuItemConnectionJsCode($sConnection, $sAction, $iContentProfile, $aItem)
         ));
     }
 

+ 176 - 2
modules/base/profile/classes/BxBaseModProfileModule.php

@@ -60,6 +60,23 @@ class BxBaseModProfileModule extends BxBaseModGeneralModule implements iBxDolCon
     }
 
     // ====== SERVICE METHODS
+
+    public function serviceGetSafeServices()
+    {
+        $a = parent::serviceGetSafeServices();
+        return array_merge($a, array (
+            'ProfileUnitSafe' => '',
+            'ProfileUrl' => '',
+            'EntityCreate' => '',
+            'BrowseRecommended' => '',
+            'BrowseRecentProfiles' => '',
+            'BrowseActiveProfiles' => '',
+            'BrowseTopProfiles' => '',
+            'BrowseOnlineProfiles' => '',
+            'BrowseByAcl' => '',
+        ));
+    }
+
     public function serviceGetOptionsRedirectAfterAdd()
     {
         $CNF = &$this->_oConfig->CNF;
@@ -241,6 +258,28 @@ class BxBaseModProfileModule extends BxBaseModGeneralModule implements iBxDolCon
         return $aRet;
     }
 
+    /**
+     * @page service Service Calls
+     * @section bx_base_profile Base Profile
+     * @subsection bx_base_profile-general General
+     * @subsubsection bx_base_profile-profile_unit_safe profile_unit_safe
+     * 
+     * @code bx_srv('bx_persons', 'profile_unit_safe', [...]); @endcode
+     * 
+     * Get profile unit
+     * @param $iContentId content ID
+     * 
+     * @see BxBaseModProfileModule::serviceProfileUnitSafe
+     */
+    /** 
+     * @ref bx_base_profile-profile_unit_safe "profile_unit_safe"
+     */
+    public function serviceProfileUnitSafe ($iContentId, $aParams = array())
+    {
+        unset($aParams['check_private_content']);
+        return $this->serviceProfileUnit ($iContentId, $aParams);
+    }
+
     public function serviceProfileUnit ($iContentId, $aParams = array())
     {
         $mixedContent = $this->_getContent($iContentId);
@@ -344,6 +383,22 @@ class BxBaseModProfileModule extends BxBaseModGeneralModule implements iBxDolCon
     	return $bAbsolute ? BX_DOL_URL_ROOT . BxDolPermalinks::getInstance()->permalink($CNF['URL_CREATE']) : $CNF['URL_CREATE'];
     }
 
+    /**
+     * @page service Service Calls
+     * @section bx_base_profile Base Profile
+     * @subsection bx_base_profile-general General
+     * @subsubsection bx_base_profile-profile_url profile_url
+     * 
+     * @code bx_srv('bx_persons', 'profile_url', [...]); @endcode
+     * 
+     * Get profile URL
+     * @param $iContentId content ID
+     * 
+     * @see BxBaseModProfileModule::serviceProfileUrl
+     */
+    /** 
+     * @ref bx_base_profile-profile_url "profile_url"
+     */
     public function serviceProfileUrl ($iContentId)
     {
         if (!$iContentId)
@@ -444,6 +499,22 @@ class BxBaseModProfileModule extends BxBaseModGeneralModule implements iBxDolCon
         return parent::serviceFormsHelper ();
     }
 
+    /**
+     * @page service Service Calls
+     * @section bx_base_profile Base Profile
+     * @subsection bx_base_profile-forms Forms
+     * @subsubsection bx_base_profile-entity_create entity_create
+     * 
+     * @code bx_srv('bx_persons', 'entity_create', [...]); @endcode
+     * 
+     * Get profile creation form
+     * @param $sDisplay optional form display name
+     * 
+     * @see BxBaseModProfileModule::serviceEntityCreate
+     */
+    /** 
+     * @ref bx_base_profile-entity_create "entity_create"
+     */
     public function serviceEntityCreate ($sDisplay = false)
     {
 	    BxDolInformer::getInstance($this->_oTemplate)->setEnabled(false);
@@ -456,6 +527,24 @@ class BxBaseModProfileModule extends BxBaseModGeneralModule implements iBxDolCon
         return true;
     }
 
+    /**
+     * @page service Service Calls
+     * @section bx_base_profile Base Profile
+     * @subsection bx_base_profile-browse Browse
+     * @subsubsection bx_base_profile-browse_recommended browse_recommended
+     * 
+     * @code bx_srv('bx_persons', 'browse_recommended', [...]); @endcode
+     * 
+     * Browse recommended profiles
+     * @param $sUnitView optional, unit view, for example - showcase
+     * @param $bEmptyMessage optional, display or not "empty" message when there is no content
+     * @param $bAjaxPaginate optional, use AJAX paginate or not
+     * 
+     * @see BxBaseModProfileModule::serviceBrowseRecommended
+     */
+    /** 
+     * @ref bx_base_profile-browse_recommended "browse_recommended"
+     */
     public function serviceBrowseRecommended ($sUnitView = false, $bEmptyMessage = false, $bAjaxPaginate = true)
     {
         if (!isLogged())
@@ -463,21 +552,89 @@ class BxBaseModProfileModule extends BxBaseModGeneralModule implements iBxDolCon
         return $this->_serviceBrowse ('recommended', $sUnitView ? array('unit_view' => $sUnitView) : false, BX_DB_PADDING_DEF, $bEmptyMessage, $bAjaxPaginate);
     }
 
+    /**
+     * @page service Service Calls
+     * @section bx_base_profile Base Profile
+     * @subsection bx_base_profile-browse Browse
+     * @subsubsection bx_base_profile-browse_recent_profiles browse_recent_profiles
+     * 
+     * @code bx_srv('bx_persons', 'browse_recent_profiles', [...]); @endcode
+     * 
+     * Browse recently joined profiles
+     * @param $bEmptyMessage optional, display or not "empty" message when there is no content
+     * @param $bAjaxPaginate optional, use AJAX paginate or not
+     * 
+     * @see BxBaseModProfileModule::serviceBrowseRecentProfiles
+     */
+    /** 
+     * @ref bx_base_profile-browse_recent_profiles "browse_recent_profiles"
+     */
     public function serviceBrowseRecentProfiles ($bDisplayEmptyMsg = false, $bAjaxPaginate = true)
     {
         return $this->_serviceBrowse ('recent', false, BX_DB_PADDING_DEF, $bDisplayEmptyMsg, $bAjaxPaginate);
     }
 
+    /**
+     * @page service Service Calls
+     * @section bx_base_profile Base Profile
+     * @subsection bx_base_profile-browse Browse
+     * @subsubsection bx_base_profile-browse_active_profiles browse_active_profiles
+     * 
+     * @code bx_srv('bx_persons', 'browse_active_profiles', [...]); @endcode
+     * 
+     * Browse recently active profiles
+     * @param $bEmptyMessage optional, display or not "empty" message when there is no content
+     * @param $bAjaxPaginate optional, use AJAX paginate or not
+     * 
+     * @see BxBaseModProfileModule::serviceBrowseActiveProfiles
+     */
+    /** 
+     * @ref bx_base_profile-browse_active_profiles "browse_active_profiles"
+     */
     public function serviceBrowseActiveProfiles ($sUnitView = false, $bEmptyMessage = false, $bAjaxPaginate = false)
     {
         return $this->_serviceBrowse ('active', $sUnitView ? array('unit_view' => $sUnitView) : false, BX_DB_PADDING_DEF, $bEmptyMessage, $bAjaxPaginate);
     }
 
+    /**
+     * @page service Service Calls
+     * @section bx_base_profile Base Profile
+     * @subsection bx_base_profile-browse Browse
+     * @subsubsection bx_base_profile-browse_top_profiles browse_top_profiles
+     * 
+     * @code bx_srv('bx_persons', 'browse_top_profiles', [...]); @endcode
+     * 
+     * Browse top profiles
+     * @param $bEmptyMessage optional, display or not "empty" message when there is no content
+     * @param $bAjaxPaginate optional, use AJAX paginate or not
+     * 
+     * @see BxBaseModProfileModule::serviceBrowseTopProfiles
+     */
+    /** 
+     * @ref bx_base_profile-browse_top_profiles "browse_top_profiles"
+     */
     public function serviceBrowseTopProfiles ($bDisplayEmptyMsg = false, $bAjaxPaginate = false)
     {
         return $this->_serviceBrowse ('top', false, BX_DB_PADDING_DEF, $bDisplayEmptyMsg, $bAjaxPaginate);
     }
 
+    /**
+     * @page service Service Calls
+     * @section bx_base_profile Base Profile
+     * @subsection bx_base_profile-browse Browse
+     * @subsubsection bx_base_profile-browse_online_profiles browse_online_profiles
+     * 
+     * @code bx_srv('bx_persons', 'browse_online_profiles', [...]); @endcode
+     * 
+     * Browse online profiles
+     * @param $bEmptyMessage optional, display or not "empty" message when there is no content
+     * @param $bAjaxPaginate optional, use AJAX paginate or not
+     * 
+     * @see BxBaseModProfileModule::serviceBrowseOnlineProfiles
+     */
+    /** 
+     * @ref bx_base_profile-browse_online_profiles "browse_online_profiles"
+     */
     public function serviceBrowseOnlineProfiles ($bDisplayEmptyMsg = false, $bAjaxPaginate = false)
     {
         return $this->_serviceBrowse ('online', false, BX_DB_PADDING_DEF, $bDisplayEmptyMsg, $bAjaxPaginate);
@@ -613,6 +770,23 @@ class BxBaseModProfileModule extends BxBaseModGeneralModule implements iBxDolCon
         );
     }
 
+    /**
+     * @page service Service Calls
+     * @section bx_base_profile Base Profile
+     * @subsection bx_base_profile-browse Browse
+     * @subsubsection bx_base_profile-browse_by_acl browse_by_acl
+     * 
+     * @code bx_srv('bx_persons', 'browse_by_acl', [...]); @endcode
+     * 
+     * Browse profiles by membership(ACL) level
+     * @param $mixedLevelId membership level, or array of membership levels
+     * @param $iDesignBox optional, design box identifier
+     * 
+     * @see BxBaseModProfileModule::serviceBrowseByAcl
+     */
+    /** 
+     * @ref bx_base_profile-browse_by_acl "browse_by_acl"
+     */
 	public function serviceBrowseByAcl ($mixedLevelId, $iDesignBox = BX_DB_PADDING_DEF)
     {
         return $this->_serviceBrowse (
@@ -1631,13 +1805,13 @@ class BxBaseModProfileModule extends BxBaseModGeneralModule implements iBxDolCon
         return parent::_getContent($iContentId, $sFuncGetContent);
     }
 
-    /** Returns list of members by mode with limited number of records for React Jot
+    /** 
+     * Returns list of members by mode with limited number of records for React Jot
      * @param string $sMode
      * @param int $iStart
      * @param int $iPerPage
      * @return mixed
      */
-
     public function serviceGetMembers($sMode = 'active', $iStart = 0, $iPerPage = 10){
         bx_import('SearchResult', $this->_aModule);
         $sClass = $this->_aModule['class_prefix'] . 'SearchResult';

+ 5 - 0
modules/base/template/classes/BxBaseModTemplateModule.php

@@ -20,6 +20,11 @@ class BxBaseModTemplateModule extends BxBaseModGeneralModule
         $this->_oConfig->init($this->_oDb);
     }
 
+    public function serviceGetSafeServices()
+    {
+        return array();
+    }
+
     public function serviceGetOptionsDefaultMix()
     {
         $aResult = array(

+ 201 - 13
modules/base/text/classes/BxBaseModTextModule.php

@@ -97,6 +97,39 @@ class BxBaseModTextModule extends BxBaseModGeneralModule implements iBxDolConten
     }
 
     // ====== SERVICE METHODS
+
+    public function serviceGetSafeServices()
+    {
+        $a = parent::serviceGetSafeServices();
+        return array_merge($a, array (
+            'GetBlockPollAnswers' => '',
+            'GetBlockPollResults' => '',
+            'GetMenuAddonManageToolsProfileStats' => '',
+            'BrowsePublic' => '',
+            'BrowsePopular' => '',
+            'BrowseTop' => '',
+            'BrowseUpdated' => '',
+            'BrowseAuthor' => '',
+            'CategoriesMultiList' => ''
+        ));
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_base_text Base Text
+     * @subsection bx_base_text-polls Polls Blocks
+     * @subsubsection bx_base_text-get_block_poll_answers get_block_poll_answers
+     * 
+     * @code bx_srv('bx_posts', 'get_block_poll_answers', [...]); @endcode
+     * 
+     * Get block with poll answers
+     * @param $iPollId poll ID
+     * 
+     * @see BxBaseModTextModule::serviceGetBlockPollAnswers
+     */
+    /** 
+     * @ref bx_base_text-get_block_poll_answers "get_block_poll_answers"
+     */
     public function serviceGetBlockPollAnswers($iPollId, $bForceDisplay = false)
     {
         if(!$iPollId)
@@ -108,6 +141,22 @@ class BxBaseModTextModule extends BxBaseModGeneralModule implements iBxDolConten
         return $this->_serviceTemplateFunc('entryPollAnswers', $iPollId, 'getPollInfoById');
     }
 
+    /**
+     * @page service Service Calls
+     * @section bx_base_text Base Text
+     * @subsection bx_base_text-polls Polls Blocks
+     * @subsubsection bx_base_text-get_block_poll_results get_block_poll_results
+     * 
+     * @code bx_srv('bx_posts', 'get_block_poll_results', [...]); @endcode
+     * 
+     * Get block with poll results
+     * @param $iPollId poll ID
+     * 
+     * @see BxBaseModTextModule::serviceGetBlockPollResults
+     */
+    /** 
+     * @ref bx_base_text-get_block_poll_results "get_block_poll_results"
+     */
     public function serviceGetBlockPollResults($iPollId)
     {
         return $this->_serviceTemplateFunc('entryPollResults', $iPollId, 'getPollInfoById');
@@ -147,6 +196,21 @@ class BxBaseModTextModule extends BxBaseModGeneralModule implements iBxDolConten
         return array('counter1_value' => $iNum1, 'counter2_value' => $iNum2, 'counter3_value' => $iNumTotal );
 	}
 
+    /**
+     * @page service Service Calls
+     * @section bx_base_text Base Text
+     * @subsection bx_base_text-other Other
+     * @subsubsection bx_base_text-get_menu_addon_manage_tools_profile_stats get_menu_addon_manage_tools_profile_stats
+     * 
+     * @code bx_srv('bx_posts', 'get_menu_addon_manage_tools_profile_stats', []); @endcode
+     * 
+     * Get number of posts for currently logged in user
+     * 
+     * @see BxBaseModTextModule::serviceGetMenuAddonManageToolsProfileStats
+     */
+    /** 
+     * @ref bx_base_text-get_menu_addon_manage_tools_profile_stats "get_menu_addon_manage_tools_profile_stats"
+     */
 	public function serviceGetMenuAddonManageToolsProfileStats()
 	{
 		bx_import('SearchResult', $this->_aModule);
@@ -161,8 +225,22 @@ class BxBaseModTextModule extends BxBaseModGeneralModule implements iBxDolConten
 	}
 
     /**
-     * Display public entries
-     * @return HTML string
+     * @page service Service Calls
+     * @section bx_base_text Base Text
+     * @subsection bx_base_text-browse Browse
+     * @subsubsection bx_base_text-browse_public browse_public
+     * 
+     * @code bx_srv('bx_posts', 'browse_public', [...]); @endcode
+     * 
+     * Display public posts
+     * @param $sUnitView unit view, such as: full, extended, gallery, showcase
+     * @param $bEmptyMessage display or not "empty" message when there is no content
+     * @param $bAjaxPaginate use AJAX paginate or not
+     * 
+     * @see BxBaseModTextModule::serviceBrowsePublic
+     */
+    /** 
+     * @ref bx_base_text-browse_public "browse_public"
      */
     public function serviceBrowsePublic ($sUnitView = false, $bEmptyMessage = true, $bAjaxPaginate = true)
     {   
@@ -170,8 +248,22 @@ class BxBaseModTextModule extends BxBaseModGeneralModule implements iBxDolConten
     }
 
     /**
-     * Display popular entries
-     * @return HTML string
+     * @page service Service Calls
+     * @section bx_base_text Base Text
+     * @subsection bx_base_text-browse Browse
+     * @subsubsection bx_base_text-browse_popular browse_popular
+     * 
+     * @code bx_srv('bx_posts', 'browse_popular', [...]); @endcode
+     * 
+     * Display popular posts
+     * @param $sUnitView unit view, such as: full, extended, gallery, showcase
+     * @param $bEmptyMessage display or not "empty" message when there is no content
+     * @param $bAjaxPaginate use AJAX paginate or not
+     * 
+     * @see BxBaseModTextModule::serviceBrowsePopular
+     */
+    /** 
+     * @ref bx_base_text-browse_popular "browse_popular"
      */
     public function serviceBrowsePopular ($sUnitView = false, $bEmptyMessage = true, $bAjaxPaginate = true)
     {
@@ -179,8 +271,22 @@ class BxBaseModTextModule extends BxBaseModGeneralModule implements iBxDolConten
     }
 
     /**
-     * Display popular entries
-     * @return HTML string
+     * @page service Service Calls
+     * @section bx_base_text Base Text
+     * @subsection bx_base_text-browse Browse
+     * @subsubsection bx_base_text-browse_top browse_top
+     * 
+     * @code bx_srv('bx_posts', 'browse_top', [...]); @endcode
+     * 
+     * Display top posts
+     * @param $sUnitView unit view, such as: full, extended, gallery, showcase
+     * @param $bEmptyMessage display or not "empty" message when there is no content
+     * @param $bAjaxPaginate use AJAX paginate or not
+     * 
+     * @see BxBaseModTextModule::serviceBrowseTop
+     */
+    /** 
+     * @ref bx_base_text-browse_top "browse_top"
      */
     public function serviceBrowseTop ($sUnitView = false, $bEmptyMessage = true, $bAjaxPaginate = true)
     {
@@ -188,8 +294,22 @@ class BxBaseModTextModule extends BxBaseModGeneralModule implements iBxDolConten
     }
 
     /**
-     * Display recently updated entries
-     * @return HTML string
+     * @page service Service Calls
+     * @section bx_base_text Base Text
+     * @subsection bx_base_text-browse Browse
+     * @subsubsection bx_base_text-browse_updated browse_updated
+     * 
+     * @code bx_srv('bx_posts', 'browse_updated', [...]); @endcode
+     * 
+     * Display recently updated posts
+     * @param $sUnitView unit view, such as: full, extended, gallery, showcase
+     * @param $bEmptyMessage display or not "empty" message when there is no content
+     * @param $bAjaxPaginate use AJAX paginate or not
+     * 
+     * @see BxBaseModTextModule::serviceBrowseUpdated
+     */
+    /** 
+     * @ref bx_base_text-browse_updated "browse_updated"
      */
     public function serviceBrowseUpdated ($sUnitView = false, $bEmptyMessage = true, $bAjaxPaginate = true)
     {
@@ -197,8 +317,21 @@ class BxBaseModTextModule extends BxBaseModGeneralModule implements iBxDolConten
     }
 
     /**
-     * Display entries of the author
-     * @return HTML string
+     * @page service Service Calls
+     * @section bx_base_text Base Text
+     * @subsection bx_base_text-browse Browse
+     * @subsubsection bx_base_text-browse_author browse_author
+     * 
+     * @code bx_srv('bx_posts', 'browse_author', [...]); @endcode
+     * 
+     * Display posts of specified author
+     * @param $iProfileId profile ID
+     * @param $aParams additional params, see BxBaseModGeneralModule::serviceBrowse
+     * 
+     * @see BxBaseModTextModule::serviceBrowseAuthor
+     */
+    /** 
+     * @ref bx_base_text-browse_author "browse_author"
      */
     public function serviceBrowseAuthor ($iProfileId = 0, $aParams = array())
     {
@@ -206,7 +339,20 @@ class BxBaseModTextModule extends BxBaseModGeneralModule implements iBxDolConten
     }
     
     /**
-     * Entry author block
+     * @page service Service Calls
+     * @section bx_base_text Base Text
+     * @subsection bx_base_text-page_blocks Page Blocks
+     * @subsubsection bx_base_text-entity_author entity_author
+     * 
+     * @code bx_srv('bx_posts', 'entity_author', [...]); @endcode
+     * 
+     * Display author block for the specified post
+     * @param $iContentId content ID
+     * 
+     * @see BxBaseModTextModule::serviceEntityAuthor
+     */
+    /** 
+     * @ref bx_base_text-entity_author "entity_author"
      */
     public function serviceEntityAuthor ($iContentId = 0)
     {
@@ -214,13 +360,42 @@ class BxBaseModTextModule extends BxBaseModGeneralModule implements iBxDolConten
     }
     
     /**
-     * Entry polls block
+     * @page service Service Calls
+     * @section bx_base_text Base Text
+     * @subsection bx_base_text-page_blocks Page Blocks
+     * @subsubsection bx_base_text-entity_polls entity_polls
+     * 
+     * @code bx_srv('bx_posts', 'entity_polls', [...]); @endcode
+     * 
+     * Display polls for the specified post
+     * @param $iContentId content ID
+     * 
+     * @see BxBaseModTextModule::serviceEntityPolls
+     */
+    /** 
+     * @ref bx_base_text-entity_polls "entity_polls"
      */
     public function serviceEntityPolls ($iContentId = 0)
     {
         return $this->_serviceTemplateFunc ('entryPolls', $iContentId);
     }
 
+    /**
+     * @page service Service Calls
+     * @section bx_base_text Base Text
+     * @subsection bx_base_text-page_blocks Page Blocks
+     * @subsubsection bx_base_text-entity_breadcrumb entity_breadcrumb
+     * 
+     * @code bx_srv('bx_forum', 'entity_breadcrumb', [...]); @endcode
+     * 
+     * Display breadcrumb for the specified post
+     * @param $iContentId content ID
+     * 
+     * @see BxBaseModTextModule::serviceEntityBreadcrumb
+     */
+    /** 
+     * @ref bx_base_text-entity_breadcrumb "entity_breadcrumb"
+     */
     public function serviceEntityBreadcrumb ($iContentId = 0)
     {
         return $this->_serviceTemplateFunc ('entryBreadcrumb', $iContentId);
@@ -245,7 +420,20 @@ class BxBaseModTextModule extends BxBaseModGeneralModule implements iBxDolConten
     }
     
     /**
-     * Entry multicategiries block
+     * @page service Service Calls
+     * @section bx_base_text Base Text
+     * @subsection bx_base_text-page_blocks Page Blocks
+     * @subsubsection bx_base_text-categories_multi_list categories_multi_list
+     * 
+     * @code bx_srv('bx_posts', 'categories_multi_list', [...]); @endcode
+     * 
+     * Display multi-categorories block with number of posts in each category
+     * @param $bDisplayEmptyCats display empty categories
+     * 
+     * @see BxBaseModTextModule::serviceCategoriesMultiList
+     */
+    /** 
+     * @ref bx_base_text-categories_multi_list "categories_multi_list"
      */
     public function serviceCategoriesMultiList($bDisplayEmptyCats = true)
     {

+ 7 - 4
modules/boonex/accounts/classes/BxAccntGridAdministration.php

@@ -333,13 +333,16 @@ class BxAccntGridAdministration extends BxBaseModProfileGridAdministration
 
         $iAction = BX_PROFILE_ACTION_MANUAL;
         $sMethod = $isChecked ? 'activate' : 'suspend';
-        if(!$oProfile->$sMethod($iAction))
+        if(!$oProfile->$sMethod($iAction, 0 ,false))
             return false;
 
+        sendMailTemplate('t_ChangeStatusAccount' . ucfirst($sMethod), $oProfile->getAccountObject()->id(), $oProfile->id(), array(), BX_EMAIL_SYSTEM);
+        
         $aProfiles = $oProfile->getAccountObject()->getProfiles();
-        foreach($aProfiles as $aProfile)
-            BxDolProfile::getInstance($aProfile['id'])->$sMethod($iAction);
-
+        foreach($aProfiles as $aProfile){
+            BxDolProfile::getInstance($aProfile['id'])->$sMethod($iAction, 0 ,false);
+        }
+        
     	return true;
     }
 

+ 5 - 0
modules/boonex/accounts/classes/BxAccntModule.php

@@ -21,6 +21,11 @@ class BxAccntModule extends BxBaseModGeneralModule
         $this->_oConfig->init($this->_oDb);
     }
 
+    public function serviceGetSafeServices()
+    {
+        return array ();
+    }
+
     /**
      * @page service Service Calls
      * @section bx_accounts Accounts

+ 5 - 0
modules/boonex/dolphin_migration/classes/BxDolMModule.php

@@ -137,6 +137,11 @@ class BxDolMModule extends BxBaseModGeneralModule
         return $this->_oMDb->connect();
     }
 
+    public function serviceGetSafeServices()
+    {
+        return array ();
+    }
+
     public function serviceGetPrivacyGroups(){
         $aPrivacyList = $this -> _oDb -> getPrivacyList();
         $aValues = array();

+ 8 - 0
modules/boonex/elasticsearch/classes/BxElsModule.php

@@ -130,6 +130,14 @@ class BxElsModule extends BxBaseModGeneralModule
         echo '</pre>';
     }
 
+    public function serviceGetSafeServices()
+    {
+        return array (
+            'SearchSimple' => '',
+            'SearchExtended' => '',
+        );
+    }
+
     /**
      * @page service Service Calls
      * @section bx_elasticsearch ElasticSearch

+ 17 - 1
modules/boonex/english/data/langs/system/en.xml

@@ -1712,7 +1712,7 @@
 	<string name="_sys_actions"><![CDATA[Actions]]></string>
 	<string name="_sys_active"><![CDATA[Active]]></string>
   <string name="_sys_account_settings_email_successfully_submitted"><![CDATA[Email settings were successfully saved]]></string>
-  <string name="_sys_account_settings_pwd_successfully_submitted"><![CDATA[Password  were successfully changed]]></string>
+  <string name="_sys_account_settings_pwd_successfully_submitted"><![CDATA[Password was successfully changed]]></string>
   <string name="_sys_account_settings_info_successfully_submitted"><![CDATA[Account settings were successfully saved]]></string>
 	<string name="_sys_acc_confirmation_type_none"><![CDATA[No confirmation]]></string>
 	<string name="_sys_acc_confirmation_type_email"><![CDATA[email is confirmed]]></string>
@@ -1985,6 +1985,18 @@ If it is not enabled then please consider implement this optimization, since it
 <p>Your profile is currently suspended.</p>
 <p> </p>
 {email_footer}]]></string>
+  <string name="_sys_et_txt_body_account_change_status_activate">
+    <![CDATA[{email_header}
+<p>Your account and all your related profiles are currently activated.</p>
+<p></p>
+{email_footer}]]>
+  </string>
+  <string name="_sys_et_txt_body_account_change_status_suspended">
+    <![CDATA[{email_header}
+<p>Your account and all your related profiles are currently suspended.</p>
+<p> </p>
+{email_footer}]]>
+  </string>
 	<string name="_sys_et_txt_body_account"><![CDATA[{email_header}
 <p>{account_output}</p>
 {email_footer}]]></string>
@@ -2036,6 +2048,8 @@ If it is not enabled then please consider implement this optimization, since it
 	<string name="_sys_et_txt_name_profile_change_status_active"><![CDATA[Profile status changed to active]]></string>
 	<string name="_sys_et_txt_name_profile_change_status_pending"><![CDATA[Profile status changed to pending]]></string>
 	<string name="_sys_et_txt_name_profile_change_status_suspended"><![CDATA[Profile status changed to suspended]]></string>
+  <string name="_sys_et_txt_name_account_change_status_active"><![CDATA[Account status changed to active]]></string>
+  <string name="_sys_et_txt_name_account_change_status_suspended"><![CDATA[Account status changed to suspended]]></string>
 	<string name="_sys_et_txt_name_system_account"><![CDATA[New Accounts]]></string>
 	<string name="_sys_et_txt_name_system_pruning"><![CDATA[Pruning result]]></string>
 	<string name="_sys_et_txt_name_upgrade_failed"><![CDATA[Upgrade failed]]></string>
@@ -2055,6 +2069,8 @@ If it is not enabled then please consider implement this optimization, since it
 	<string name="_sys_et_txt_subject_profile_change_status_active"><![CDATA[Profile activated]]></string>
 	<string name="_sys_et_txt_subject_profile_change_status_pending"><![CDATA[Profile pending review]]></string>
 	<string name="_sys_et_txt_subject_profile_change_status_suspended"><![CDATA[Profile suspended]]></string>
+  <string name="_sys_et_txt_subject_account_change_status_activate"><![CDATA[Account activated]]></string>
+  <string name="_sys_et_txt_subject_account_change_status_suspended"><![CDATA[Account suspended]]></string>
 	<string name="_sys_et_txt_subject_account"><![CDATA[{site_name} {account_count} accounts created yesterday]]></string>
 	<string name="_sys_et_txt_subject_pruning"><![CDATA[{site_name} pruning result]]></string>
 	<string name="_sys_et_txt_subject_upgrade_failed"><![CDATA[{site_name} upgrade failed]]></string>

+ 11 - 7
modules/boonex/massmailer/classes/BxMassMailerModule.php

@@ -222,7 +222,12 @@ class BxMassMailerModule extends BxBaseModGeneralModule
     /**
     * SERVICE METHODS
     */
-          
+
+    public function serviceGetSafeServices()
+    {
+        return array ();
+    }
+
     /**
     * @page service Service Calls
     * @section bx_massmailer Mass mailer
@@ -233,7 +238,7 @@ class BxMassMailerModule extends BxBaseModGeneralModule
     * 
     * Get page block with the campagn's subscribers list
     *
-    * @param $aParams an array with search params.
+    * @param $iContentId content ID.
     * @return HTML string with block content to display on the site. All necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
     * 
     * @see BxMassMailerModule::serviceCampagnSubscribers
@@ -265,7 +270,7 @@ class BxMassMailerModule extends BxBaseModGeneralModule
      * 
      * Get page block with the campagn info
      *
-     * @param $aParams an array with search params.
+     * @param $iContentId content ID.
      * @return HTML string with block content to display on the site. All necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
      * 
      * @see BxMassMailerModule::serviceCampagnInfo
@@ -294,7 +299,7 @@ class BxMassMailerModule extends BxBaseModGeneralModule
      * 
      * Get page block with the campagn links list
      *
-     * @param $aParams an array with search params.
+     * @param $iContentId content ID
      * @return HTML string with block content to display on the site. All necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
      * 
      * @see BxMassMailerModule::serviceCampagnLinks
@@ -349,7 +354,7 @@ class BxMassMailerModule extends BxBaseModGeneralModule
      * 
      * Get page block with page's breadcrumbs
      *
-     * @param $aParams an array with search params.
+     * @param $iContentId content ID
      * @return HTML string with block content to display on the site. All necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
      * 
      * @see BxMassMailerModule::serviceEntityBreadcrumb
@@ -386,7 +391,6 @@ class BxMassMailerModule extends BxBaseModGeneralModule
      * 
      * Get page block with attributes list
      *
-     * @param $aParams an array with search params.
      * @return HTML string with block content to display on the site. All necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
      * 
      * @see BxMassMailerModule::serviceAttributes
@@ -629,4 +633,4 @@ class BxMassMailerModule extends BxBaseModGeneralModule
     }
 }
 
-/** @} */
+/** @} */

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

@@ -1975,6 +1975,18 @@
 <p>Ваш профиль заблокирован.</p>
 <p> </p>
 {email_footer}]]></string>
+  <string name="_sys_et_txt_body_account_change_status_activate">
+    <![CDATA[{email_header}
+<p>Ваш аккаунт и все связанные с ним профили активированы.</p>
+<p></p>
+{email_footer}]]>
+  </string>
+  <string name="_sys_et_txt_body_account_change_status_suspended">
+    <![CDATA[{email_header}
+<p>Ваш аккаунт и все связанные с ним профили заблокированы.</p>
+<p> </p>
+{email_footer}]]>
+  </string>
 	<string name="_sys_et_txt_body_account"><![CDATA[{email_header}
 <p>{account_output}</p>
 {email_footer}]]></string>
@@ -2026,6 +2038,8 @@
 	<string name="_sys_et_txt_name_profile_change_status_active"><![CDATA[Статус профиля изменён на Активный]]></string>
 	<string name="_sys_et_txt_name_profile_change_status_pending"><![CDATA[Статус профиля изменён на Ожидающий]]></string>
 	<string name="_sys_et_txt_name_profile_change_status_suspended"><![CDATA[Статус профиля изменён на Заблокированный]]></string>
+  <string name="_sys_et_txt_name_account_change_status_active"><![CDATA[Статус аккаунта изменён на Активный]]></string>
+  <string name="_sys_et_txt_name_account_change_status_suspended"><![CDATA[Статус аккаунта изменён на Заблокированный]]></string>
 	<string name="_sys_et_txt_name_system_account"><![CDATA[Новые аккаунты]]></string>
 	<string name="_sys_et_txt_name_system_pruning"><![CDATA[Результат очистки]]></string>
 	<string name="_sys_et_txt_name_upgrade_failed"><![CDATA[Обновление не удалось]]></string>
@@ -2045,6 +2059,8 @@
 	<string name="_sys_et_txt_subject_profile_change_status_active"><![CDATA[Профиль активирован]]></string>
 	<string name="_sys_et_txt_subject_profile_change_status_pending"><![CDATA[Профиль в ожидании одобрения]]></string>
 	<string name="_sys_et_txt_subject_profile_change_status_suspended"><![CDATA[Профиль заблокирован]]></string>
+  <string name="_sys_et_txt_subject_account_change_status_activate"><![CDATA[Аккаунт активирован]]></string>
+  <string name="_sys_et_txt_subject_account_change_status_suspended"><![CDATA[Аккаунт заблокирован]]></string>
 	<string name="_sys_et_txt_subject_account"><![CDATA[{site_name} - {account_count} аккаунтов, созданных вчера]]></string>
 	<string name="_sys_et_txt_subject_pruning"><![CDATA[{site_name} - результат очистки]]></string>
 	<string name="_sys_et_txt_subject_upgrade_failed"><![CDATA[{site_name} - обновление не удалось]]></string>

+ 9 - 4
modules/boonex/se_migration/classes/BxSEMigModule.php

@@ -123,11 +123,16 @@ class BxSEMigModule extends BxBaseModGeneralModule
 		$this -> _oSEDb = new BxSEDb($aConfig);		
 		return $this -> _oSEDb	-> connect(); 
 	}
-	
+
+    public function serviceGetSafeServices()
+    {
+        return array ();
+    }
+
 	/** 
-	* Returns Password Ecnrypted by Seocial Engine Rules
-	* @param object	
-	*/	
+	 * Returns Password Ecnrypted by Seocial Engine Rules
+	 * @param object	
+	 */	
 	public function serviceSocialEngineResponse($oAlert){
 		// if imported member tries to login set new hash for password
 		if ($oAlert -> sAction == 'encrypt_password_after' && isset($oAlert -> aExtras['info']['se_id']) && (int)$oAlert -> aExtras['info']['se_id']){

+ 4 - 2
studio/template/scripts/BxBaseStudioDashboard.php

@@ -159,8 +159,10 @@ class BxBaseStudioDashboard extends BxDolStudioDashboard
 	    	$iSizeTotal = 0;
 	        $aChartData = array();
 	        foreach($aItems as $sColor => $aItem) {
-	        	$iSizeTotal += $aItem['value'];
-	            $aChartData[] = array(bx_js_string(strip_tags(_t($aItem['label'])), BX_ESCAPE_STR_APOS), array('v' => $aItem['value'], 'f' => bx_js_string(_t_format_size($aItem['value']))));
+                if ($aItem['value'] > 0){
+	        	    $iSizeTotal += $aItem['value'];
+	                $aChartData[] = array(bx_js_string(strip_tags(_t($aItem['label'])), BX_ESCAPE_STR_APOS), array('v' => $aItem['value'], 'f' => bx_js_string(_t_format_size($aItem['value']))));
+                }
 	        }
     	}
 

+ 3 - 1
template/scripts/BxBaseAccountForms.php

@@ -254,8 +254,10 @@ class BxBaseAccountForms extends BxDolProfileForms
         }
 
         // check if email was changed
-        if (!empty($aTrackTextFieldsChanges['changed_fields']) && in_array('email', $aTrackTextFieldsChanges['changed_fields']))
+        if (!empty($aTrackTextFieldsChanges['changed_fields']) && in_array('email', $aTrackTextFieldsChanges['changed_fields'])){
+            $oAccount = BxDolAccount::getInstance($iAccountId, true); // refresh account to clear cache 
             $oAccount->updateEmailConfirmed(false);  // mark email as unconfirmed
+        }
 
         // check if password was changed
         if ($oForm->getCleanValue('password')) {