Questions around the TYPO3 integration and plugins as well as Flow and NeosCMS
Forum rules: Always add your TYPO3/Flow, Aimeos and PHP version as well as your environment (Linux/Mac/Win)
#4808 by kimholberg
24 Oct 2017, 16:40
On my front page (shop/list) i want to move the bottom text of the product, up on top of the product image.

So, i have created an extension via Aimeos extension builder named: ai-myname and placed this in the Extension folder of Neos.

Then i copied the templates from client/html/templates and placed them in the same position in my extension.

Then i tried to move the html code from various templates to be before the image section:

Code: Select all            <div class="text-list">
               <h2 itemprop="name"><?= $enc->html( $productItem->getName(), $enc::TRUST ); ?></h2>
               <?php foreach( $productItem->getRefItems( 'text', 'short', 'default' ) as $textItem ) : ?>
                  <div class="text-item" itemprop="description">
                     <?= $enc->html( $textItem->getContent(), $enc::TRUST ); ?><br/>
               </div>
               <?php endforeach; ?>
            </div>


This does not seem to make any changes to the output. In your documentation you write:

"Extensions that depend on the core and contain PHP template files in the client/html/templates/ directory named the same as existing ones are used first."

So i asumed that any change in my extension would change the output, but can you please explain which template i should work in, for the front page of the shop.

Thanks...
#4822 by kimholberg
25 Oct 2017, 18:24
Yes i cleared the caches and also configured to develope with no cache via Settings.yaml file nothing changes.

See image upload of both file tree where i have changed 'items-body-list.php' - but nothing shows any change in either of them.
ai-twelveinch.png
my extension
ai-twelveinch.png (40.81 KiB) Viewed 431 times


ai-client-html.png
aimeos extension
ai-client-html.png (52.85 KiB) Viewed 431 times


Can you confirm that this is the file i should change if i want to re-arrange things on the first page of the shop (/shop/list page)
#4823 by aimeos
26 Oct 2017, 08:34
No, "items-body-list.php" is the alternative list view (texts and price right of the image). The standard list view in generated by the "items-body-default.php" template file.
#4830 by kimholberg
26 Oct 2017, 21:26
Thanks for your reply. As far as i could see, i needed to change the products-default in the common templates folder, then a change is happening (did this in ai-client-html). Then i tried to do this in my own extension (called ai-twelveinch) but nothing happends. Why not?
#4835 by aimeos
27 Oct 2017, 23:23
Can you check if the manifest.php file of your own extension contains "ai-client-html" in the "depends" section?
#4838 by kimholberg
28 Oct 2017, 13:20
In my own extension (ai-twelveinch) manifest i have following:

Code: Select allreturn array(
   'name' => 'ai-twelveinch',
   'depends' => array(
      'aimeos-core',
      'ai-admin-extadm',
      'ai-admin-jqadm',
      'ai-admin-jsonadm',
      'ai-client-html',
      'ai-client-jsonapi',
      'ai-controller-jobs',
   ),
   'include' => array(
      'lib/custom/src',
      'client/html/src',
      'client/jsonapi/src',
      'controller/common/src',
      'controller/frontend/src',
      'controller/extjs/src',
      'controller/jobs/src',
      'admin/jsonadm/src',
      'admin/jqadm/src',
   ),
   'i18n' => array(
      'admin' => 'admin/i18n',
      'admin/jsonadm' => 'admin/jsonadm/i18n',
      'controller/common' => 'controller/common/i18n',
      'controller/frontend' => 'controller/frontend/i18n',
      'controller/extjs' => 'controller/extjs/i18n',
      'controller/jobs' => 'controller/jobs/i18n',
      'mshop' => 'lib/custom/i18n',
      'client' => 'client/i18n',
   ),
   'config' => array(
      'lib/custom/config',
   ),
   'custom' => array(
      'admin/jsonadm/templates' => array(
         'admin/jsonadm/templates',
      ),
      'admin/jqadm/templates' => array(
         'admin/jqadm/templates',
      ),
      'admin/extjs' => array(
         'admin/extjs/manifest.jsb2',
      ),
      'client/html/templates' => array(
         'client/html/templates',
      ),
      'client/jsonapi/templates' => array(
         'client/jsonapi/templates',
      ),
      'controller/extjs' => array(
         'controller/extjs/src',
      ),
      'controller/jobs' => array(
         'controller/jobs/src',
      ),
      'controller/jobs/templates' => array(
         'controller/jobs/templates',
         'client/html/templates',
      ),
   ),
   'setup' => array(
      'lib/custom/setup',
   ),
);
#4842 by aimeos
28 Oct 2017, 21:08
Did you placed the modified "product-default.php" partial into the "client/html/templates/common/partials/" directory of your extension?
#4861 by aimeos
30 Oct 2017, 14:55
Where is your own extension located in your Flow application?