From 6a64f827ced9236d62365d801582f841a60d014b Mon Sep 17 00:00:00 2001 From: Etienne Roudeix Date: Mon, 6 Jan 2014 12:14:56 +0100 Subject: [PATCH] fix conflicts --- .../Thelia/Core/Template/Loop/Template.php | 15 ++++++------ .../Smarty/Assets/SmartyAssetsManager.php | 23 +++++++------------ .../Thelia/Core/Template/TemplateHelper.php | 13 ----------- core/lib/Thelia/Core/Thelia.php | 14 ++++------- local/config/schema.xml | 5 ++-- 5 files changed, 24 insertions(+), 46 deletions(-) diff --git a/core/lib/Thelia/Core/Template/Loop/Template.php b/core/lib/Thelia/Core/Template/Loop/Template.php index f3b4a05f9..9b6ae8a28 100644 --- a/core/lib/Thelia/Core/Template/Loop/Template.php +++ b/core/lib/Thelia/Core/Template/Loop/Template.php @@ -23,12 +23,19 @@ namespace Thelia\Core\Template\Loop; +use Propel\Runtime\ActiveQuery\Criteria; +use Thelia\Core\Security\AccessManager; +use Thelia\Core\Template\Element\BaseI18nLoop; use Thelia\Core\Template\Element\LoopResult; use Thelia\Core\Template\Element\LoopResultRow; +use Thelia\Core\Template\Element\PropelSearchLoopInterface; use Thelia\Core\Template\Loop\Argument\ArgumentCollection; use Thelia\Core\Template\Loop\Argument\Argument; +use Thelia\Model\ModuleQuery; + +use Thelia\Module\BaseModule; use Thelia\Type; use Thelia\Core\Template\TemplateHelper; use Thelia\Core\Template\TemplateDefinition; @@ -45,7 +52,7 @@ use Thelia\Core\Template\Element\ArraySearchLoopInterface; */ class Template extends BaseLoop implements ArraySearchLoopInterface { - /** + /** * @return ArgumentCollection */ protected function getArgDefinitions() @@ -65,14 +72,8 @@ class Template extends BaseLoop implements ArraySearchLoopInterface ); } -<<<<<<< HEAD public function buildArray() { $type = $this->getArg('template-type')->getValue(); -======= - public function buildArray() - { - $type = $this->getArg(template_type); ->>>>>>> cleanmaster if ($type == 'front-office') $templateType = TemplateDefinition::FRONT_OFFICE; diff --git a/core/lib/Thelia/Core/Template/Smarty/Assets/SmartyAssetsManager.php b/core/lib/Thelia/Core/Template/Smarty/Assets/SmartyAssetsManager.php index 5deb6e9d0..cb867b8c1 100755 --- a/core/lib/Thelia/Core/Template/Smarty/Assets/SmartyAssetsManager.php +++ b/core/lib/Thelia/Core/Template/Smarty/Assets/SmartyAssetsManager.php @@ -23,11 +23,8 @@ namespace Thelia\Core\Template\Smarty\Assets; -<<<<<<< HEAD use Thelia\Core\Template\Assets\AsseticHelper; use Thelia\Core\Template\TemplateDefinition; -======= ->>>>>>> cleanmaster use Thelia\Tools\URL; use Thelia\Core\Template\Assets\AssetManagerInterface; @@ -45,9 +42,9 @@ class SmartyAssetsManager /** * Creates a new SmartyAssetsManager instance * - * @param AssetManagerInterface $assetsManager an asset manager instance - * @param string $web_root the disk path to the web root (with final /) - * @param string $path_relative_to_web_root the path (relative to web root) where the assets will be generated + * @param AssetManagerInterface $assetsManager an asset manager instance + * @param string $web_root the disk path to the web root (with final /) + * @param string $path_relative_to_web_root the path (relative to web root) where the assets will be generated */ public function __construct(AssetManagerInterface $assetsManager, $web_root, $path_relative_to_web_root) { @@ -59,7 +56,6 @@ class SmartyAssetsManager public function prepareAssets($assets_directory, \Smarty_Internal_Template $template) { -<<<<<<< HEAD self::$assetsDirectory = $assets_directory; $smartyParser = $template->smarty; @@ -74,19 +70,16 @@ class SmartyAssetsManager foreach($templateDirectories[$templateDefinition->getName()] as $key => $directory) { $tpl_path = $directory . DS . self::$assetsDirectory; -======= - $tpl_dir = dirname($template->source->filepath); ->>>>>>> cleanmaster $asset_dir_absolute_path = realpath($tpl_path); if (false !== $asset_dir_absolute_path) { $this->assetsManager->prepareAssets( - $asset_dir_absolute_path, - $this->web_root . $this->path_relative_to_web_root, - $templateDefinition->getPath(), - $key + $asset_dir_absolute_path, + $this->web_root . $this->path_relative_to_web_root, + $templateDefinition->getPath(), + $key ); } } @@ -127,7 +120,7 @@ class SmartyAssetsManager $assetType, $filters, $debug - ); + ); return $url; } diff --git a/core/lib/Thelia/Core/Template/TemplateHelper.php b/core/lib/Thelia/Core/Template/TemplateHelper.php index b7c8fcddd..000a5bfd5 100644 --- a/core/lib/Thelia/Core/Template/TemplateHelper.php +++ b/core/lib/Thelia/Core/Template/TemplateHelper.php @@ -90,7 +90,6 @@ class TemplateHelper ); } -<<<<<<< HEAD /** * Returns an array which contains all standard template definitions */ @@ -114,18 +113,6 @@ class TemplateHelper $list = $exclude = array(); $tplIterator = TemplateDefinition::getStandardTemplatesSubdirsIterator(); -======= - public function getList($templateType) - { - $list = $exclude = array(); - - if ($templateType == TemplateDefinition::BACK_OFFICE) { - $baseDir = THELIA_TEMPLATE_DIR.TemplateDefinition::BACK_OFFICE_SUBDIR; - } elseif ($templateType == TemplateDefinition::PDF) { - $baseDir = THELIA_TEMPLATE_DIR.TemplateDefinition::PDF_SUBDIR; - } else { - $baseDir = THELIA_TEMPLATE_DIR.TemplateDefinition::FRONT_OFFICE_SUBDIR; ->>>>>>> cleanmaster foreach($tplIterator as $type => $subdir) { diff --git a/core/lib/Thelia/Core/Thelia.php b/core/lib/Thelia/Core/Thelia.php index 6b3ba4266..abb5fbfc6 100755 --- a/core/lib/Thelia/Core/Thelia.php +++ b/core/lib/Thelia/Core/Thelia.php @@ -1,7 +1,7 @@ . */ +/* along with this program. If not, see . */ /* */ /*************************************************************************************/ @@ -49,6 +49,7 @@ use Thelia\Config\DefinePropel; use Thelia\Core\Template\TemplateDefinition; use Thelia\Core\TheliaContainerBuilder; use Thelia\Core\DependencyInjection\Loader\XmlFileLoader; +use Thelia\Model\ConfigQuery; use Symfony\Component\Config\FileLocator; use Propel\Runtime\Propel; @@ -175,7 +176,7 @@ class Thelia extends Kernel ->depth(0) ->in(THELIA_ROOT . "/core/lib/Thelia/Config/Resources"); - foreach ($finder as $file) { + foreach($finder as $file) { $loader->load($file->getBaseName()); } @@ -197,11 +198,6 @@ class Thelia extends Kernel $definition ); -<<<<<<< HEAD -======= - $code = ucfirst($module->getCode()); - ->>>>>>> cleanmaster $loader = new XmlFileLoader($container, new FileLocator($module->getAbsoluteConfigPath())); $loader->load("config.xml"); @@ -374,4 +370,4 @@ class Thelia extends Kernel //Nothing is load here but it's possible to load container configuration here. //exemple in sf2 : $loader->load(__DIR__.'/config/config_'.$this->getEnvironment().'.yml'); } -} +} \ No newline at end of file diff --git a/local/config/schema.xml b/local/config/schema.xml index c77b3204f..2c76e4b93 100755 --- a/local/config/schema.xml +++ b/local/config/schema.xml @@ -1,4 +1,4 @@ - + @@ -58,6 +58,7 @@ +
@@ -853,7 +854,7 @@ - +