Code Monkey home page Code Monkey logo

ai-client-html's Introduction

Aimeos logo

Aimeos HTML client

Build Status Coverage Status Scrutinizer Code Quality License

Aimeos HTML components for e-commerce projects

Aimeos demo

ai-client-html's People

Contributors

aimeos avatar alextravin avatar cnoelker avatar creativemadeofficial avatar defive avatar faerietree avatar floriankuehl avatar gilbertsoft avatar guelzow avatar heural avatar iammart avatar jonaseberle avatar kras95 avatar lgeorget avatar maxmessing avatar merzilla avatar metalicss avatar niloofarfs avatar nollm avatar nos3 avatar nvindice avatar pdanzinger avatar peteracs avatar popkornkevin avatar ra2410 avatar scrutinizer-auto-fixer avatar switch-cheehau avatar tenkrad avatar xerc avatar zlem0815 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

ai-client-html's Issues

Address data are lost after validation error

Environment

  1. Version: 18.10.3
  2. Integration: TYPO3
  3. System: Ubuntu 18.04.1

Describe the bug
When I change the billing address and the validation of only one field wasn't successfully all other changes were reverted.
But when I click "new address" and the validation of a field isn't correct all other changes are still there.

To Reproduce
Steps to reproduce the behavior:

  1. Go to address checkout page
  2. Change something and leave a required field empty.
  3. Click next.
  4. All changes are reverted to old values.

Expected behavior
Same behaviour like new address. When a validation wasn't correct all other changes should be still there.

Screenshots
The salutation was forgotten after changing the address.
address

Additional context
When a customer change his billing address and enter something wrong he should do all other changes again after clicking next.

Canceling on PayPal

If someone cancels a payment at PayPal he will be returned to confirm page with two buttons "change payment" and "try again". The third option "continue shopping" would be nice. And perhaps "cancel purchase", but this is not so important I think.

Yesterday we had the case that someone canceled on PayPal and 50 minutes later we have received a second purchase with on additional product in the order payed and confirmed at / by PayPal. First order is on payment pending and has to be canceled by hand.

Deleting delivery address takes you to next page

Environment

  1. Version: 18.10.3
  2. Integration: TYPO3 v9.5
  3. System: Ubuntu 18.04.1

Describe the bug
When I deleting a delivery address in the checkout process it takes me back to the overview page.

To Reproduce
Steps to reproduce the behavior:

  1. Complete the checkout process until you are on the overview page.
  2. Click on 'change' beside delivery address.
  3. Delete a delivery address.
  4. It takes you back to overview page again.

Expected behavior
Stay on address page after deleting a address.

use array-index @ mediaItem->getPreview

$mediaItem->getPreview( 1200 ) << unsing width is not save

  'controller' => [
    'common' => [
      'media' => [
        'product' => [
          'previews' => [
            '1x' => ['maxheight' => (2*  534)],// NORMAL
            '2x' => ['maxheight' => (2* 1068)],// RETINA
            'og' => ['maxheight' => (2*  630), 'maxwidth' => (2* 1200), 'force-size' => true],// SHARE

Customer receive voucher email with zero amount after redeem voucher code

Hi Aimeos.

I'm trying to utilise the function of voucher but i encounter this issue, i'm using version 2021-07.
Steps to reproduce

  1. Customer purchase a voucher from website and receive the email with voucher code.
  2. When customer redeem the voucher, they will receive another new voucher code with amount zero.

I think it's something to do with the codes below

$expr = array(
$orderSearch->compare( '>=', 'order.mtime', $limitDate ),
$orderSearch->compare( '==', 'order.statuspayment', $status ),
$orderSearch->compare( '==', 'order.base.product.type', 'voucher' ),
$orderSearch->compare( '==', $orderFunc, 0 ),
);

Does it make sense to trigger the process only when the product voucher price is more than 0?

 $expr = array( 
 	$orderSearch->compare( '>=', 'order.mtime', $limitDate ), 
 	$orderSearch->compare( '==', 'order.statuspayment', $status ), 
 	$orderSearch->compare( '==', 'order.base.product.type', 'voucher' ), 
        $orderSearch->compare( '>', 'order.base.product.price', 0 ),
 	$orderSearch->compare( '==', $orderFunc, 0 ), 
 ); 

JavaScript issues (TYPO3, e.g. Firefox 54.0.1; even in t3 Demo shop)

On HAMAG and Demo shop site: e.g.
http://typo3.demo.aimeos.org/demo/detail/d/10022/Demo_selection_article/1/

Selecting an option does not update the detail view price in realtime.

No feedback (warnings, logs in console, ...).

(NoScript is turned off thus this can not be the culprit.)

This issue was encountered in version 17_4* too.
Is it only my system? Then there is something wrong with my javascript. Else it could be Aimeos.

Reducing JavaScript to a minimum might be wise because it is again and again prone to generating issues. Most things like hide, show or basic animations can be accomplished using CSS3.

Email notification for watched products

Hi everyone.

When a customer watches a product variant, a notification is send whenever any variant or the main product is changed.

How to reproduce:
1.) You have two product variants, a blue pen and a red pen. The blue pen is out of stock.
2.) A customer wants a notification, when the blue pen is available again, and clicks on the watch button.
3.) The customer then watches the main product, and not the variant.
4.) There is a stock-change for the red pen from 5 to 10.
5.) An email notification is send by the cron, and the watch record is removed.

The customer wanted to get an update on the blue pen, but gets an email when the stock of the red pen is updated. It also removes the watch record.

Tobi

Product link in basket list

The link in the common/summary/detail-standard seems to be wrong.
In all other Templates it changed to the "name" of the product instead of the ID.
In my case i could solve it by changing it to take the product code as the value for the d_name parameter. But since in the catalog list for example the value is taken with $product->getName('url') i would gues theres more logic to it.

Review rating does not correctly math

version 2020.10.x-dev

There is 2 review:

  1. rating 5
  2. rating 3

dump(number_format( $this->detailProductItem->getRating(), 1 ));
returned 8.0

In template 8.0/5

Is it conceived or is it a bug?

basket-add A non-recoverable error occured

After update 'Missing required parameter for [Route: aimeos_shop_detail] [URI: shop/d_name/d_pos?/d_prodid?] [Missing parameter: d_name]' . Error arise along with fs-theme update from contextSite to contextSiteTheme, when use contextSite its work but when change to contextSiteTheme then file missing (js,css).

Count in category filter

Environment

  1. Version: 18.10.3
  2. Integration: TYPO3
  3. System: Ubuntu 18.04.1

Describe the bug
In version 18.10.3 the count for sub categories doesn't work if you're on top categories.

To Reproduce
Steps to reproduce the behavior:

  1. Create sub categories below start.
  2. Assign products to that sub categories.
  3. Click on category start.

Expected behavior
I want to see the count for all the categories always.

Screenshots
Left in version 18.10.2 and right in version 18.10.3.
categories

Additional context
When I use the setting "client/html/catalog/lists/levels = 3" the counts doesn't include the products below. With this setting I expect that the start node counts all available products but the count display only products that explicit assined to start. Is that what it's meant to be?

Search only searches in default category

When a default category is set (e.g. via client/html/catalog/lists/catid-default), the search function only lists search results from this default category. This might be counterintuitive, especially because the suggest function lists products from all categories.

Is this desired behaviour?

See

if( $catid == '' && $catfilter === true )
{
/** client/html/catalog/lists/catid-default
* The default category ID used if none is given as parameter
*
* If users view a product list page without a category ID in the
* parameter list, the first found products are displayed with a
* random order. You can circumvent this by configuring a default
* category ID that should be used in this case (the ID of the root
* category is best for this). In most cases you can set this value
* via the administration interface of the shop application.
*
* @param string Category ID
* @since 2014.03
* @category User
* @category Developer
* @see client/html/catalog/lists/sort
* @see client/html/catalog/lists/size
* @see client/html/catalog/lists/domains
* @see client/html/catalog/lists/levels
* @see client/html/catalog/detail/prodid-default
*/
$catid = $config->get( 'client/html/catalog/lists/catid-default', '' );
for the cause of this issue.

Translations, localization and customers issue

I miss the part that says how customers worldwide read the default sentences in the webshop, and more specifically the checkout, and even more specifically the country select during checkout.

I assume the choosen language in the website is leading?

If that's so, there might be a problem. I translated and improved the Dutch country names. Those names are very different from the English and the original names. Customers might be unable to read it.

It's not enought to adapt ai-client-html/client/i18/country/nl.po as an intermediate solution.

So, is there a more sophisticated approach to customize this whole set?

For instance, TYPO3 has static_info_tables and translated versions of it (base is https://typo3.org/extensions/repository/view/static_info_tables) which makes it possible to customize localization in detail. This goes into further detail even for country zones.

Feature Request: Delivery emails should differentiate items (For instance refused items)

Is your feature request related to a problem?
We have implemented a shop using Aimeos. In the normal flow customer buys multiple products. Sometimes some of the products in the order are not available. When we change the status of the individual items to refused and then change the delivery status of the order the generated Email doesn't take that into account. The generated Email to customer should differentiate between successful and unsuccessful items

Describe the solution you'd like
Changing the status of individual items should be respected in the generated email for the order and the items should be differentiated

Describe alternatives you've considered
Currently we have to send separate Emails to customers to let them know that these items were not available

Additional context
None

Urgent: Mini basket link broken

Platform: Typo3 v8.7.26 with RealURL
Aimeos: v2018.10.x-dev
Localization: DE

We have experienced a strange problem on saturday. Our German shop uses localized domains like www.shop.de/warenkorb/ for the basket. On saturday, the mini basket link directed to www.shop.de/basket/ instead, which killed the checkout process for a couple of customers, because they encountered a 404 when trying to access the basket/checkout process.

When clearing the Typo3 frontend cache yesterday, all pages were re-rendered and the problem was gone.

We have no clue why this bug occured, but it has the potential to prevent all orders for a whole weekend, if nobody notices. So we need to resolve the root cause fast.

[FEATURE] E-Mail salutation - Possibility to be gender specific

Currently in the translation for e-mail salutation the format is only "Dear %1$s %2$s %3$s".
However, it would be good to have a format that can be per gender - it should be optional that way, if it isn't set it should default to the current one.
The reason is that e.g. in German in the polite wording there is a difference between genders and so it requires a gender specific salutation.

Empty value for parameter "f_catid" prevents default category

Hi

Typo3: 8.7.24
Aimeos: 2019.04.4
Ai-Client-HTML: 2019.04.4

When the parameter f_catid exists but is empty, the default category is not used.
In previous versions the actual value of f_catid is compared to "". Now the default category is only used as the default value for the "param" view helper. The helper only checks for existance.
I think the change in behaviour was done here.
1b5b8e6#diff-6f16179781a98657097155c425017a20

In our setup under some circumstances the parameter can be set to an empty value. In this case we would like the default category. Should I fix the above behaviour in our setup or was the change unintended?

Greetings Sebastian Diez

Coupon error codes

When a coupon is not available, en error like 'coupon.1234.coupon.gone' is displayed (where 1234 is the coupon code). Is this desired behaviour? IMO, it would be better to either remove the coupon code from the error message entirely or to parse it via sprintf() into the translated error message.

The method translatePluginErrorCodes() already removes product codes from the error string:

$key = $scope . ( $scope !== 'product' ? '.' . $object : '' ) . '.' . $errcode;

Can I expand this behaviour on coupon codes? I would create a PR for this if you agree.

Infinite Scrolling

Are you interested in a PR for 2018.x with infinite scrolling at product catalog list?

Wrong name in email

We found an other bug today: a customer has made an order and in the first email is my name instead the customers see screenshot. The second email after paying with paypal was correct.

Product URL slug update problem

We've updated a couple of product labels via CSV product import. The product URL slug did not get changed. Is this on purpose? Is there a way to batch update all URLs?

When adding the product to the basket, this becomes a problem: the $product object of type Order\Item\Base\Product\Standard object does not return the "url" name but just the default label, compare

$params = ['d_name' => $product->getName( 'url' ), 'd_prodid' => $product->getProductId(), 'd_pos' => ''];

What is the best solution here?

For the meantime I just removed the array_diff_key() on the parameters to preserve the product id in the URL.

Product availability

On some products the green availability square isn't shown. The stock of every product is set to null, I can't see any differences between products showing the square or not. Any idea?

Gmail issue with CSS

My e-mails were not rendering CSS in Gmail.

After a long hassle, I found out that Gmail doesn't allow the <style> tag inside the , only inside the

However these files:
ext/ai-client-html/client/html/templates/email/account/html-body-default.php
ext/ai-client-html/client/html/templates/email/delivery/html-body-default.php
ext/ai-client-html/client/html/templates/email/payment/html-body-default.php
ext/ai-client-html/client/html/templates/email/watch/html-body-default.php

have <style> tag inside the
After I moved the <style> tag to the Gmail rendering was correct!
Please check.

coupon code cannot be deleted if all products are removed

Hey,

I'm testing the shop module right now.
I've added some products to the cart and applied a coupon code
The amount was correct.
Then I deleted all the products , but the coupon code stayed active (the total amount was negative -125)

even when I click on the shopping cart icon ( top right of site) , I see the garbage icon next to the coupon code , the code cannot be deleted

Thanx for your time
johan

Product links in emails

I am getting

Error while trying to send payment e-mail for order ID "54" and status "5": Parameter "ai__d_name" for route "enhancer_000000001018d7470000000021161855" must match "[^/]++" ("
<span>Bellow</span>
 V6-269" given)

Shouldn't it be 'd_name' => $product->getUrl() instead of getName() here since it is used for URL generation?

?> <?php foreach( $this->summaryBasket->getProducts() as $product ) : $totalQty += $product->getQuantity() ?> <tr class="body product"><td class="status"> <?php if( ( $status = $product->getStatus() ) >= 0 ) : $key = 'stat:' . $status ?> <?= $enc->html( $this->translate( 'mshop/code', $key ) ); ?> <?php endif; ?> </td><td class="label"> <?php $params = array_merge( $this->param(), ['d_name' => $product->getName(), 'd_prodid' => $product->getProductId(), 'd_pos' => ''] ); ?> <a class="product-name" href="<?= $enc->attr( $this->url( ( $product->getTarget() ?: $detailTarget ), $detailController, $detailAction, $params, [], $detailConfig ) ); ?>"> <?= $enc->html( $product->getName(), $enc::TRUST ); ?> </a><p class="code"><span class="name"><?= $enc->html( $this->translate( 'client', 'Article no.' ), $enc::TRUST ); ?>: </span><span class="value"><?= $product->getProductCode(); ?></span></p> <?php if( ( $desc = $product->getDescription() ) !== '' ) : ?> <p class="product-description"><?= $enc->html( $desc ); ?></p> <?php endif ?> <?php foreach( $this->config( 'client/html/common/summary/detail/product/attribute/types', ['variant', 'config', 'custom'] ) as $attrType ) : ?> <?php if( !( $attributes = $product->getAttributeItems( $attrType ) )->isEmpty() ) : ?> <ul class="attr-list attr-type-<?= $enc->attr( $attrType ); ?>"> <?php foreach( $attributes as $attribute ) : ?> <li class="attr-item attr-code-<?= $enc->attr( $attribute->getCode() ); ?>"><span class="name"><?= $enc->html( $this->translate( 'client/code', $attribute->getCode() ) ); ?>:</span> <span class="value"> <?php if( $attribute->getQuantity() > 1 ) : ?> <?= $enc->html( $attribute->getQuantity() ); ?>× <?php endif; ?> <?= $enc->html( $attrType !== 'custom' && $attribute->getName() ? $attribute->getName() : $attribute->getValue() ); ?> </span></li> <?php endforeach; ?> </ul> <?php endif ?> <?php endforeach; ?> <?php if( $this->extOrderItem->getPaymentStatus() >= $this->config( 'client/html/common/summary/detail/download/payment-status', \Aimeos\MShop\Order\Item\Base::PAY_RECEIVED )

More options for Emails

Would be nice to have more options in the emails, means adding a additional text for a payment type. Think could easy be achieved by a new text type for services (e.g. email short) and so texts can added at the BE. We need this e.g. for payments in advance to get the bank account number to the mails.

cache entry based on config and config through TYPO3-plugin

I'm not sure if it is only a Problem in TYPO3, but in TYPO3 at least there exists a normal workflow to produce the bug.

As far as I understand cache entries of html, for example of the filter, is dependent on the current config but at certain points only parts of the whole config are considered.
The following code gets html for the body of the filter dependent on the config below the path 'client/html/catalog/filter'.

$confkey = 'client/html/catalog/filter';
if( ( $html = $this->getCached( 'body', $uid, $prefixes, $confkey ) ) === null )

In Typo3-Plugins you can configure certain config settings inside the individual plugin instance.
In the Catalog-Filter plugin for example you can configure "client.html.catalog.lists.url.target" and this setting is actually used inside of the html body of the filter, but its values are not considered in the cache key. Configure three instances of the Catalog-Filter plugin each with another value for "client.html.catalog.lists.url.target" and all will use the same cache entry, therefore all filter urls but those from the one which generated the entry are not as expected.

Printed language in emails

The language of the customer in emails is not translated, instead the iso code is printed:

Rechnungsadresse
Frau Melanie Müller
Teslastrasse 25
3151 Musterlingen
Schweiz
de_CH

Locale / currency in navbar

Hello everyone!

I'm using aimeos to build an ecommerce and currently I'm adapting the templates to the client's needs.

I have a question about the locale/select and currency/select.

I see that only the locale is declared:

imagen

But in the page actually shows both: locale and currency.

I've digged through the code but I don't see where is this happening.

The problem is that i would like to split them into individual elements.

Thank you very much!

List type (grid / list)

By clicking on list type link I get a cHash error. Is that a general issue or perhaps dependent from realurl 2.1.5? Hadn't the time for a downgrade now.

Possible bug: Salutation in emails

Hi Aimeos team,

in

$view->emailIntro = $view->translate( 'client/html/email', 'Dear Sir or Madam' );
the translation domain client/html/email is used, which seems to be invalid. I have my own implementation of this class, so I can not confirm if the problem exists in the original setup, but at least in my setup this translation results in an error (and unsent emails).

Same for some other Email classes like Delivery, ...

EDIT: Sorry, forgot to mention: Version 2018.x

wrong showing characteristics of selection product in new version

Environment

  1. Version 2021.07

Describe the bug
as 2021.x update released I found showing characteristics of selection product is wrong and that is characteristics table include and show all types of product, for example in your online demo product DEMO SELECTION ARTICLE have 2 different color and sizes and in the characteristics table all of them is visible, while in 2020.x versions in this table just show selected type characteristics and when user change selection this table updated to selected product's characteristics.

To Reproduce
Steps to reproduce the behavior:

  1. Go to https://laravel.demo.aimeos.org/default/en/EUR/Demo-selection-article/1#image-0
  2. Select Color, Length and Width
  3. Scroll down to CHARACTERISTICS
  4. See error

Page jumping when clicking on slider images on product detail

When you click on an image in the slider on a product detail page the page jumps because the browser reacts to the anchor link being changed, is there a way to change this behaviour?

I tried looking around for which functions I could overwrite to alter this but I couldn't find it. And if I remove the anchors from the hrefs the slider stops working.

Wrong namspace is used for the subpart-filter classes

Hi everyone.

With the configuration:
client/html/catalog/filter/search/standard/subparts
you can add additional search classes to the search.

The AI-Client provides some of them.
When you use this configuration, the following classes are uses
\Aimeos\Client\Html\Catalog\Filter\Search\...\Standard
(The dots are filled with the value from the configuration.)

Sadly, the provided classes are not part of this namespace, resulting in an error message, that the classes are not found.

Possible solution:
Here, the wrong namespace is used.
Changing it from

return $this->createSubClient( 'catalog/filter/search/' . $type, $name );

to

return $this->createSubClient( 'catalog/filter/' . $type, $name );

allows the AI-Client to find the classes.

Alternative solution:
Move the provided classes to the right namespace.

Tobi

Edit: Fixed a typo in the namespace above.

Optional delivery e-mail results in error during delivery changes

If the delivery e-mail is optional, e.g. if a customer wants to send the product to his or her work place, they don't need another e-mail address.

However, in this case the delivery address does exist but there is no e-mail associated with it which results in the notification being unable to be sent.

Therefore, in this case the e-mail of the billing address should be used to send the e-mail notification.
Maybe the easiest solution would be to store the billing e-mail address with the delivery address, if no individual e-mail address is submitted.

better to show "Add To Basket" when product attributes selected by customer.

Hi, i'm using version 2021.04

Current behaviour:

  • Setup a product A with type selection with multiple variants product A-1 and product A-2.
  • Configure product A without price, with categories
  • Configure product A-1 and product A-2 properly with prices, without categories.

Result:
Before select attribute, "Add To Basket" button not appear
image

After select attribute, "Add To Basket" button not appear as well
image

Apparently product A is required to set price in order to work.

I personally feel if product A is type:selection, then should not set any price, but after you select the attributes, it will display the price accordingly, and able to add to basket.

I hope it make sense.

E-mails with CSS

When sending e-mails I noticed that many of the e-mail clients do not display them very good.
Some of them can't send to a customer in this styling.
I have 3 examples here:

Thunderbird

thunderbird

Outlook/GMail

other_clients_normal_view

Outlook (browser view)

outlook_browser_view

In Thunderbird the representation succeeds as it should be.
With Outlook or GMail any CSS styles are missing. Only the HTML tags are interpreted by the client.
If you set the browser view in Outlook you get the overview more or less well displayed but the images are much too large.

I did some research and read very often that inline-styles should be used for e-mails.
Then I have looked at some mails from other shops and could confirm that they do it exactly like that.
In Aimeos the content of a CSS file (email.css) is written between the <style> tags in the of the mail.

Maybe in the future you should see if you also use this way for the email templates in Aimeos.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.