Several theme loading views problem
Forum rules
Always add your Laravel, Aimeos and PHP version as well as your environment (Linux/Mac/Win)
Spam and unrelated posts will be removed immediately!
Always add your Laravel, Aimeos and PHP version as well as your environment (Linux/Mac/Win)
Spam and unrelated posts will be removed immediately!
Re: Several theme loading views problem
It seems it always takes these middle components from this new-theme-sk. So when I change to new-theme-sk it is fine, but when I come back to new-theme, the middle components is taken from new-theme-sk
Re: Several theme loading views problem
I use aimeos/aimeos-laravel version 2021.07.6
Re: Several theme loading views problem
I analyzed the topic and I can see that Aimeos always takes the last theme it found and if there is an expected file in client/html/templates, it takes it, no matter what theme is selected in the shop. In the case of the sk shop it works fine because new-theme-sk is the last theme and takes files from packages/new-theme-sk/client/html/templates from there. The choice of the theme in the store is doesn't matter in this case.
It only gets the appropriate files from the packages/new-theme/views and packages/new-theme-sk/views directories. In the case of packages/new-theme/client/html/templates and packages/new-theme-sk/client/html/templates no longer get the proper.
Maybe if I add files to /client/html/templates, I should add them to option / value table for site ?
It only gets the appropriate files from the packages/new-theme/views and packages/new-theme-sk/views directories. In the case of packages/new-theme/client/html/templates and packages/new-theme-sk/client/html/templates no longer get the proper.
Maybe if I add files to /client/html/templates, I should add them to option / value table for site ?
Re: Several theme loading views problem
Just now i checked aimeos app aimeos: dev-master+ aimeos:04.2022 installed more than 12 different theme extenstion for different side/code which using different layout even there own config.. and all working as to be, without clear cache or optimize something,may use artisan optimize:clear or delete the data cache in laravel app stroge.
Re: Several theme loading views problem
@cyberdev you try install aimeos/aimeos-laravel version 2021.07.6 and use several themes
Re: Several theme loading views problem
My config/shop.php
Code: Select all
<?php
return [
'apc_enabled' => false, // enable for maximum performance if APCu is availalbe
'apc_prefix' => 'laravel:', // prefix for caching config and translation in APCu
'pcntl_max' => 4, // maximum number of parallel command line processes when starting jobs
'routes' => [
'jsonapi' => ['prefix' => '{site}/jsonapi', 'middleware' => ['web', 'api']],
'account' => ['prefix' => '{site}/profile', 'middleware' => ['web', 'auth']],
'default' => ['prefix' => '{site}/shop', 'middleware' => ['web']]
],
'page' => [
// Docs: https://aimeos.org/docs/Laravel/Adapt_pages
// Hint: catalog/filter is also available as single 'catalog/search', 'catalog/tree', 'catalog/price', 'catalog/supplier' and 'catalog/attribute'
'account-index' => ['account/profile', 'account/review', 'account/subscription', 'account/history', 'account/favorite', 'account/watch', 'basket/mini', 'catalog/session'],
'basket-index' => ['basket/bulk', 'basket/standard', 'basket/related'],
'catalog-count' => ['catalog/count'],
'catalog-detail' => ['basket/mini', 'catalog/stage', 'catalog/detail', 'catalog/session'],
'catalog-home' => ['basket/mini', 'catalog/search', 'catalog/tree', 'catalog/home'],
'catalog-list' => ['basket/mini', 'catalog/filter', 'catalog/lists'],
'catalog-stock' => ['catalog/stock'],
'catalog-suggest' => ['catalog/suggest'],
'catalog-tree' => ['basket/mini', 'catalog/filter', 'catalog/stage', 'catalog/lists'],
'checkout-confirm' => ['checkout/confirm'],
'checkout-index' => ['checkout/standard'],
'checkout-update' => ['checkout/update'],
'supplier-detail' => ['basket/mini', 'supplier/detail', 'catalog/lists'],
],
'client' => [
'html' => [
'checkout' => [
'confirm' => [
'order' => [
'decorators' => [
'global' => ['ConfirmOrderDecorator']
],
],
'decorators' => [
'global' => ['ConfirmDecorator']
],
],
'standard' => [
'onepage' => ['summary', 'delivery', 'payment'],
'address' => [
'billing' => [
'name' => 'Billing',
'salutations' => [
'',
'company'
],
'disable-new' => false,
'mandatory' => [
'order.base.address.firstname',
'order.base.address.lastname',
'order.base.address.address1',
'order.base.address.address2',
'order.base.address.postal',
'order.base.address.city',
//'order.base.address.languageid',
'order.base.address.telephone',
'order.base.address.tel_prefix',
'order.base.address.email',
'order.base.regulations',
],
'optional' => [
'order.base.address.salutation',
'order.base.address.company',
'order.base.address.vatid',
'order.base.address.address3',
'order.base.address.countryid',
]
],
'delivery' => [
'name' => 'Delivery',
'salutations' => [
'',
'company'
],
'mandatory' => [
'order.base.address.firstname',
'order.base.address.lastname',
'order.base.address.address1',
'order.base.address.address2',
'order.base.address.postal',
'order.base.address.city',
//'order.base.address.languageid',
'order.base.address.telephone',
'order.base.address.tel_prefix',
],
'optional' => [
'order.base.address.address3',
'order.base.address.countryid',
]
],
'payment' => [
'optional' => [
'order.base.address.city',
'order.base.address.countryid',
]
],
'validate' => [
'company' => '^\S$|^\S[\s\S]*\S$',
'vatid' => '^PL[0-9]{10}$',
'email' => '^([a-zA-Z0-9_\-\.]+)@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.)|(([a-zA-Z0-9\-]+\.)+))([a-zA-Z]{2,4}|[0-9]{1,3})(\]?)$',
'firstname' => '^([A-zÀ-žа-яА-Я\s-]){1,}$',
'lastname' => '^([A-zÀ-žа-яА-Я\s-]){1,}$',
'address1' => '^\S$|^\S[\s\S]*\S$',
'address2' => '^\S$|^\S[\s\S]*\S$',
// 'address3' => '/^(\s*|\d+)$',
'tel_prefix' => '^\S$|^\S[\s\S]*\S$',
'telephone' => '^[0-9]{9}$',
'postal' => '^[0-9]{2}[-][0-9]{3}$',
'city' => '^([A-zÀ-žа-яА-Я\s-]){1,}$',
],
'countries' => [
'PL',
],
'telprefixes' => [
'+359',
'+420',
'+49',
'+372',
'+385',
'+371',
'+370',
'+36',
'+43',
'+48',
'+40',
'+386',
'+421',
'+30',
'+373',
'+7',
'+381',
'+380',
'+44',
],
],
'delivery' => [
'decorators' => [
'global' => ['DeliveryOptionsDecorator']
],
],
'process' => [
],
],
'subparts' => [
'summary', 'delivery', 'payment', 'address', 'process'
],
],
'basket' => [
'cache' => [
'enable' => false, // Disable basket content caching for development
],
'standard' => [
'decorators' => [
'global' => ['BasketDecorator']
],
],
],
'common' => [
'template' => [
],
'address' => [
'salutations' => [
'',
'company'
],
],
],
],
],
'controller' => [
'jobs' => [
'frontend' => [
]
],
'backend' => [
],
'frontend' => [
'basket' => [
'limit-count' => 1,
'limit-seconds' => 3,
'name ' => 'Standardff'
],
],
],
'i18n' => [
'pl' => [
'client' => [
'Billing address part "%1$s" is missing' => ['Pole "%1$s" jest wymagane'],
'Billing address part "%1$s" is invalid' => ['Niepoprawna wartość w polu "%1$s"'],
'Delivery address part "%1$s" is missing' => ['Pole "%1$s" jest wymagane'],
'Delivery address part "%1$s" is invalid' => ['Niepoprawna wartość w polu "%1$s"'],
'Not a date' => ['Błędna data'],
'Configuration for "date.value" is missing' => ['Pole "data wysyłki" jest wymagane'],
'Configuration for "time.hourminute" is missing' => ['Pole "godzina" jest wymagane'],
'Invalid service attributes' => ['Nieprawidłowe dane'],
'prefix' => ['prefix'],
'client_type' => ['rodzaj klienta'],
'country' => ['kraj'],
'vatid' => ['NIP'],
'postal' => ['kod pocztowy'],
'Delivery service is required' => ['Należy wybrać sposób dostawy'],
'Delivery service is bad' => ['Nieprawidłowa forma dostawy'],
'Date value before "%1$s"' => ['Data powinna być nie starsza niż "%1$s"'],
'The date can be a maximum of %1$s days from today' => ['Data może być maksymalnie do %1$s dni od dziś'],
'Invalid parcel locker' => ['Nieprawidłowy paczkomat'],
],
],
],
'mshop' => [
'locale' => [
//'site' => 'pl', // used instead of "default"
]
],
'command' => [
],
'frontend' => [
],
'backend' => [
],
'madmin' => [
'cache' => [
'manager' => [
'name' => 'None', // Disable caching for development
],
],
'log' => [
'manager' => [
//'loglevel' => 7, // Enable debug logging into madmin_log table
],
],
],
];
Re: Several theme loading views problem
Firstly deb where your template load from on applying different theme extenstion or change the basic.blade.php to Anonymous Blade Components as well all related view templates in your extenstion . the best to hear from aimeos.
Re: Several theme loading views problem
My packages/new-theme/views/base.blade.php
In @yield('aimeos_body') data is loaded from new-theme-sk/client/html/templates instead of new-theme/client/html/templates but base.blade.php itself loads from a good theme.
My packages/new-theme-sk/views/base.blade.php is the same as packages/new-theme/views/base.blade.php
Code: Select all
<!DOCTYPE html>
<html>
<head>
</head>
<body>
<div class="container main-container">
@yield('aimeos_body')
</div>
</body>
</html>
My packages/new-theme-sk/views/base.blade.php is the same as packages/new-theme/views/base.blade.php
Re: Several theme loading views problem
For eaxmple in
is
$aibody['catalog/detail'] contains data from packages\new-theme-sk\client\html\templates\catalog\detail\body-standard.blade.php
Code: Select all
packages\new-theme\views\catalog\detail.blade.php
Code: Select all
@section('aimeos_body')
<div class="container-xl">
<?= $aibody['catalog/detail'] ?? '' ?>
</div>
@stop
Re: Several theme loading views problem
@Aimeos please help what could be wrong ?
Maybe there are some extra settings that I don't set?
My friend has the same error
Maybe there are some extra settings that I don't set?
My friend has the same error