RomanL 8 лет назад
Родитель
Сommit
8cbc18e467

+ 5 - 1
modules/boonex/persons/classes/BxPersonsSearchResult.php

@@ -16,7 +16,11 @@ class BxPersonsSearchResult extends BxBaseModProfileSearchResult
         parent::__construct($sMode, $aParams);
 
         $this->sUnitTemplate = 'unit_with_cover.html';
-
+        if ('showcase' == $aParams['unit_view']){
+			$this->bShowcaseView = true;
+            $this->sUnitTemplate = 'unit_with_cover_showcase.html';
+		}
+        
         $this->aCurrent =  array(
             'name' => 'bx_persons',
             'module_name' => 'bx_persons',

+ 2 - 0
modules/boonex/persons/install/langs/en.xml

@@ -259,4 +259,6 @@
     <string name="_bx_persons_email_friend_request_body"><![CDATA[{email_header}
 <p><a href="{SenderUrl}">{SenderDisplayName}</a> wants to be friends with you. <a href="{FriendsLink}">Respond</a>.</p>
 {email_footer}]]></string>
+
+    <string name="_bx_persons_page_block_title_featured_entries_view_showcase"><![CDATA[Featured People (Showcase View)]]></string>
 </resources>

+ 9 - 2
modules/boonex/persons/install/sql/enable.sql

@@ -17,10 +17,11 @@ INSERT INTO `sys_options` (`name`, `value`, `category_id`, `caption`, `type`, `e
 ('bx_persons_redirect_aadd_custom_url', '', @iCategId, '_bx_persons_option_redirect_aadd_custom_url', 'digit', '', '', '', 4),
 ('bx_persons_num_connections_quick', '6', @iCategId, '_bx_persons_option_num_connections_quick', 'digit', '', '', '', 10),
 ('bx_persons_per_page_browse', '24', @iCategId, '_bx_persons_option_per_page_browse', 'digit', '', '', '', 11),
-('bx_persons_num_rss', '10', @iCategId, '_bx_persons_option_num_rss', 'digit', '', '', '', 12),
+('bx_persons_num_rss', '10', @iCategId, '_bx_persons_option_num_rss', 'digit', '', '', '', 13),
 ('bx_persons_searchable_fields', 'fullname,description', @iCategId, '_bx_persons_option_searchable_fields', 'list', 'a:2:{s:6:"module";s:10:"bx_persons";s:6:"method";s:21:"get_searchable_fields";}', '', '', 20),
 ('bx_persons_public_subscriptions', '', @iCategId, '_bx_persons_option_public_subscriptions', 'checkbox', '', '', '', 30),
-('bx_persons_public_subscribed_me', '', @iCategId, '_bx_persons_option_public_subscribed_me', 'checkbox', '', '', '', 31);
+('bx_persons_public_subscribed_me', '', @iCategId, '_bx_persons_option_public_subscribed_me', 'checkbox', '', '', '', 31),
+('bx_persons_per_page_browse_showcase', '32', @iCategId, '_sys_option_per_page_browse_showcase', 'digit', '', '', '', 12);
 
 -- PAGES
 
@@ -175,6 +176,12 @@ SET @iBlockOrder = (SELECT `order` FROM `sys_pages_blocks` WHERE `object` = 'sys
 INSERT INTO `sys_pages_blocks` (`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES
 ('sys_home', 1, 'bx_persons', '_bx_persons_page_block_title_latest_profiles', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:10:"bx_persons";s:6:"method";s:22:"browse_recent_profiles";}', 1, 0, 0, IFNULL(@iBlockOrder, 0) + 1);
 
+-- PAGE: service blocks
+
+SET @iBlockOrder = (SELECT `order` FROM `sys_pages_blocks` WHERE `object` = '' AND `cell_id` = 0 ORDER BY `order` DESC LIMIT 1);
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('', 0, 'bx_persons', '_bx_persons_page_block_title_featured_entries_view_showcase', 11, 2147483647, 'service', 'a:3:{s:6:\"module\";s:10:\"bx_persons\";s:6:\"method\";s:15:\"browse_featured\";s:6:\"params\";a:3:{s:9:\"unit_view\";s:8:\"showcase\";s:13:\"empty_message\";b:1;s:13:\"ajax_paginate\";b:0;}}', 0, 1, IFNULL(@iBlockOrder, 0) + 1);
+
 -- MENU
 
 -- MENU: add to site menu

+ 1 - 0
modules/boonex/persons/template/unit_with_cover_showcase.html

@@ -0,0 +1 @@
+<bx_include_base:../modules/base/profile/template/unit_with_cover_showcase.html />

+ 3 - 3
modules/boonex/posts/install/langs/en.xml

@@ -218,7 +218,7 @@
     <string name="_bx_posts_txt_sample_comment_single"><![CDATA[comment to post]]></string>
     <string name="_bx_posts_txt_sample_vote_single"><![CDATA[vote to post]]></string>
 	
-	<string name="_bx_posts_page_block_title_recent_entries_view_showcase"><![CDATA[Latest Posts (Showcase View)]]></string>
-	<string name="_bx_posts_page_block_title_popular_entries_view_showcase"><![CDATA[Popular Posts (Showcase View)]]></string>
-	<string name="_bx_posts_page_block_title_featured_entries_view_showcase"><![CDATA[Featured Posts (Showcase View)]]></string>
+    <string name="_bx_posts_page_block_title_recent_entries_view_showcase"><![CDATA[Latest Posts (Showcase View)]]></string>
+    <string name="_bx_posts_page_block_title_popular_entries_view_showcase"><![CDATA[Popular Posts (Showcase View)]]></string>
+    <string name="_bx_posts_page_block_title_featured_entries_view_showcase"><![CDATA[Featured Posts (Showcase View)]]></string>
 </resources>