fix Определение шаблона
This commit is contained in:
parent
95fc1b28c8
commit
282fff8276
1 changed files with 10 additions and 6 deletions
|
|
@ -247,17 +247,21 @@ class Controller_Component
|
|||
$template = $component->getTemplateName($registry);
|
||||
|
||||
$component->viewPath = array(
|
||||
COMPONENTS . '/' . $name . '/',
|
||||
// Сначало ищем локально
|
||||
BASE_PATH . '/templates/' . $template . '/_components/' . $name . '/',
|
||||
BASE_PATH . '/components/' . $name . '/',
|
||||
CMS_PATH . '/../templates/' . $template . '/_components/' . $name . '/',
|
||||
BASE_PATH . '/templates/' . $template . '/_components/' . $name . '/'
|
||||
// Потом в общем хранилище
|
||||
CMS_PATH . '/../templates/' . $template . '/_components/' . $name . '/',
|
||||
COMPONENTS . '/' . $name . '/',
|
||||
);
|
||||
if (defined('COMPONENTS_WEB')) {
|
||||
$component->webPath = array(
|
||||
COMPONENTS_WEB . '/' . $name,
|
||||
// Сначало локально
|
||||
SITE_WWW_PATH . '/templates/' . $template . '/_components/' . $name,
|
||||
SITE_WWW_PATH . '/components/' . $name,
|
||||
TEMPLATE_WEB . '/' . $template . '/_components/' . $name,
|
||||
SITE_WWW_PATH . '/templates/' . $template . '/_components/' . $name
|
||||
// Потом в общем хранилище
|
||||
TEMPLATE_WEB . '/' . $template . '/_components/' . $name,
|
||||
COMPONENTS_WEB . '/' . $name,
|
||||
);
|
||||
$component->COMPONENTS_WEB = COMPONENTS_WEB;
|
||||
} else {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue