Explorar o código

#93 - Ocean: Page width setting in template.

AntonLV %!s(int64=11) %!d(string=hai) anos
pai
achega
5ae1402011

+ 3 - 0
modules/boonex/ocean/data/template/system/scripts/BxTemplConfig.php

@@ -28,6 +28,9 @@ class BxTemplConfig extends BxBaseConfig
         	'bx-border-color' => '#00a0ce',
         ));
 
+        if(class_exists('BxDolDb') && BxDolDb::getInstance())
+			$this->_aConfig['aLessConfig']['bx-page-width'] = getParam('bx_ocean_page_width') . 'px';
+
         bx_import('BxDolTemplate');
         $sCode = BxDolTemplate::getInstance()->getCode();
         $sStaticImages = BX_DOL_URL_ROOT . 'templates/tmpl_' . $sCode . '/images/';

+ 1 - 0
modules/boonex/ocean/install/langs/en.xml

@@ -4,4 +4,5 @@
 	<string name="_bx_ocean_stg_cpt_type"><![CDATA[Ocean]]></string>
 	<string name="_bx_ocean_stg_cpt_category_system"><![CDATA[General]]></string>
 	<string name="_bx_ocean_stg_cpt_option_switcher_name"><![CDATA[Name In Template Switcher]]></string>
+	<string name="_bx_ocean_stg_cpt_option_page_width"><![CDATA[Page Width]]></string>
 </resources>

+ 2 - 1
modules/boonex/ocean/install/sql/install.sql

@@ -10,7 +10,8 @@ INSERT INTO `sys_options_categories`(`type_id`, `name`, `caption`, `order`) VALU
 SET @iCategoryId = LAST_INSERT_ID();
 
 INSERT INTO `sys_options`(`category_id`, `name`, `caption`, `value`, `type`, `extra`, `check`, `check_error`, `order`) VALUES
-(@iCategoryId, CONCAT(@sName, '_switcher_title'), '_bx_ocean_stg_cpt_option_switcher_name', 'Ocean', 'digit', '', '', '', 1);
+(@iCategoryId, CONCAT(@sName, '_switcher_title'), '_bx_ocean_stg_cpt_option_switcher_name', 'Ocean', 'digit', '', '', '', 1),
+(@iCategoryId, CONCAT(@sName, '_page_width'), '_bx_ocean_stg_cpt_option_page_width', '1000', 'digit', '', '', '', 2);
 
 
 -- STUDIO PAGE & WIDGET