Drupal Commerce Issue Queue

Line item determined in product entity type

Fri, 05/09/2014 - 08:43

Shouldn't the line item be determined in the product entity type (or entity) and not the node product display?

It's a bugger having to create another product display node type -- in this case specific -- when you have a generic product display node type that allows you to chose any product entity type.

Maybe there's a simple answer to this question in which case we can file this issue under Support request / Documentation. However, I believe the following issue tries to solve this exact question: #1798006: Add to Cart Line Item type should be determined by product type or product instance

Categories: Issue Queues

Order Views link handlers should check for order_id

Fri, 05/09/2014 - 04:17

Currently the Views field handlers for Commerce Orders that generate links to orders (view/edit/delete) don't validate if there is an order id, they just presume it is there and generate a link.

I use a View of entities that can reference orders, but the View currently always shows a link even if there is no referenced order in the entity (the generated link is ofcourse broken and gives a 404 page).

I will attach a patch that checks if a order_id is known, and only then generates a link.

Len

Categories: Issue Queues

Order Views link handlers should check for order_id

Fri, 05/09/2014 - 04:17

Currently the Views field handlers for Commerce Orders that generate links to orders (view/edit/delete) don't validate if there is an order id, they just presume it is there and generate a link.

I use a View of entities that can reference orders, but the View currently always shows a link even if there is no referenced order in the entity (the generated link is ofcourse broken and gives a 404 page).

I will attach a patch that checks if a order_id is known, and only then generates a link.

Len

Categories: Issue Queues

commerce_currency_format() creates UTF8 codes in CSV export

Thu, 05/08/2014 - 06:34

When I create a CSV export in Views and set the display formatter for Commerce Payment Transaction: Amount to "Currency Formatted Amount" I end up with UTF8 entities such as £ for a UK pound sign (£) when I view in Excel.

Adding utf8_decode() to the return function in commerce_currency_format() as hack will mean the correct symbol is displayed but I don't want to hack the module.

Any ideas on how I can solve?

Categories: Issue Queues

commerce_currency_format() creates UTF8 codes in CSV export

Thu, 05/08/2014 - 06:34

When I create a CSV export in Views and set the display formatter for Commerce Payment Transaction: Amount to "Currency Formatted Amount" I end up with UTF8 entities such as £ for a UK pound sign (£) when I view in Excel.

Adding utf8_decode() to the return function in commerce_currency_format() as hack will mean the correct symbol is displayed but I don't want to hack the module.

Any ideas on how I can solve?

Categories: Issue Queues

Commerce Line Item Views Handler for Remove From Cart functionality only works for product based line items

Wed, 05/07/2014 - 12:43

I created a custom line item (not based off the Product line item type) type for coupons the customer adds to their cart, which works great so far except for the fact that the Remove button in the views handler will not remove the coupon. I believe this is because the code uses a function which would only remove a product, which is reasonable, though I think coupons are a potential big exception to this. There is a "todo" comment in the code saying that in the future the dependency on the cart api for this functionality should be removed. Just mentioning it here in case this todo was forgotten and to ask if this item might be addressed in the near future. See commerce/modules/line_item/includes/views/handlers/commerce_line_item_handler_field_edit_delete.inc, line 63.

Categories: Issue Queues

Commerce Line Item Views Handler for Remove From Cart functionality only works for product based line items

Wed, 05/07/2014 - 12:43

I created a custom line item (not based off the Product line item type) type for coupons the customer adds to their cart, which works great so far except for the fact that the Remove button in the views handler will not remove the coupon. I believe this is because the code uses a function which would only remove a product, which is reasonable, though I think coupons are a potential big exception to this. There is a "todo" comment in the code saying that in the future the dependency on the cart api for this functionality should be removed. Just mentioning it here in case this todo was forgotten and to ask if this item might be addressed in the near future. See commerce/modules/line_item/includes/views/handlers/commerce_line_item_handler_field_edit_delete.inc, line 63.

Categories: Issue Queues

Zoom widget crash after changing product variation

Mon, 05/05/2014 - 03:19

I'm going to test a lot of widget images tool for zooming images on my commerce kickstart release but with EVERY tool I use, on changing product variation (for example the color of the item) the images are reloaded but without the applied effect.

I'm using the Magic Magnify Plus plugin (http://www.magictoolbox.com/magicmagnifyplus/) applyed to an image style of drupal and it works until the product variation type is changed, even if drupal loads a default style image...

This is not the only one affected by this problem, even with other modules I have the same results.

Is there a solution to this?

Categories: Issue Queues

Drupal Commerce Checkout Issue

Sun, 05/04/2014 - 21:53

Hello-

I am having an issue with a Drupal Commerce configuration and was hoping to get a push in the right direction on resolving this.

I am using

DC 7.1.8
Drupal 7.26
entityapi 7.1.5

commerce_addressbook
commerce_coupon
commerce_discount
commerce_invoice_receipt
commerce_moa
commerce_price_decimals_formatter

The issue occurs when the coupon module is activated. Coupon can be successfully added to an order as expected, but then moving to review, or going back to cart and then forward to checkout from /cart, produces a WSOD with the following entry:

EntityMetadataWrapperException: Unable to get the data property type as the parent data structure is not set. in EntityStructureWrapper->getPropertyValue() (line 438 of /mnt/ssl-vhosts/domain.com/htdocs/sites/all/modules/entity/includes/entity.wrapper.inc).

If I disable coupon code fieldset on the checkout config, everything returns to normal. I am using the latest dev on both commerce_coupon and commerce_discount.

Can anyone think of where the culprit is in this? I have run commerce_repair and the error persists.

It may be important to know that this store was originally ubercart and ubercart_migrate was used to roll the existing orders into commerce, but seemed to be successful until we added coupons.

Categories: Issue Queues

Commerce module incorrectly checks for i18n_string instead of i18n_field

Fri, 05/02/2014 - 04:06

commerce_i18n_object() checks if i18n_string exists to attempt a translation but the definition of how to translate a field_instance object is defined in i18n_field, not i18n_string.

$ grep commerce_i18n_object * -r
commerce.module:function commerce_i18n_object($type, $object, $options = array()) {
modules/price/commerce_price.module:  $translated_instance = commerce_i18n_object('field_instance', $instance);
modules/price/commerce_price.module:  $translated_instance = commerce_i18n_object('field_instance', $instance);
modules/order/commerce_order.rules.inc:        $translated_instance = commerce_i18n_object('field_instance', $instance);
modules/cart/commerce_cart.module:  $translated_instance = commerce_i18n_object('field_instance', $instance);
modules/product_reference/commerce_product_reference.module:  $translated_instance = commerce_i18n_object('field_instance', $instance);
modules/line_item/commerce_line_item.module:  $translated_instance = commerce_i18n_object('field_instance', $instance);
modules/customer/commerce_customer.module:    $translated_instance = commerce_i18n_object('field_instance', $instance);
modules/customer/commerce_customer.module:  $translated_instance = commerce_i18n_object('field_instance', $instance);

If your installation only has i18n_string enabled but not i18n_field this gives issues because the key of the object type isn't known.

Categories: Issue Queues

Commerce module incorrectly checks for i18n_string instead of i18n_field

Fri, 05/02/2014 - 04:06

commerce_i18n_object() checks if i18n_string exists to attempt a translation but the definition of how to translate a field_instance object is defined in i18n_field, not i18n_string.

$ grep commerce_i18n_object * -r
commerce.module:function commerce_i18n_object($type, $object, $options = array()) {
modules/price/commerce_price.module:  $translated_instance = commerce_i18n_object('field_instance', $instance);
modules/price/commerce_price.module:  $translated_instance = commerce_i18n_object('field_instance', $instance);
modules/order/commerce_order.rules.inc:        $translated_instance = commerce_i18n_object('field_instance', $instance);
modules/cart/commerce_cart.module:  $translated_instance = commerce_i18n_object('field_instance', $instance);
modules/product_reference/commerce_product_reference.module:  $translated_instance = commerce_i18n_object('field_instance', $instance);
modules/line_item/commerce_line_item.module:  $translated_instance = commerce_i18n_object('field_instance', $instance);
modules/customer/commerce_customer.module:    $translated_instance = commerce_i18n_object('field_instance', $instance);
modules/customer/commerce_customer.module:  $translated_instance = commerce_i18n_object('field_instance', $instance);

If your installation only has i18n_string enabled but not i18n_field this gives issues because the key of the object type isn't known.

Categories: Issue Queues

Add Georgian Lari to Currencies

Fri, 05/02/2014 - 01:33
Problem/Motivation

It is included in ISO 4217. The currency code is GEL, Numeric code is 981. This is wikipedia link about ISO 4217 http://en.wikipedia.org/wiki/ISO_4217

Proposed resolution

Add it to the currency file.

    'GEL' => array(
      'code' => 'GEL',
      'symbol' => 'ლ',
      'name' => t('Georgian Lari'),
      'numeric_code' => '981',
      'symbol_placement' => 'before',
      'code_placement' => 'hidden',
      'minor_unit' => t('Tetri'),
      'major_unit' => t('Lari'),
    ),
Categories: Issue Queues

Add Georgian Lari to Currencies

Fri, 05/02/2014 - 01:33
Problem/Motivation

It is included in ISO 4217. The currency code is GEL, Numeric code is 981. This is wikipedia link about ISO 4217 http://en.wikipedia.org/wiki/ISO_4217

Proposed resolution

Add it to the currency file.

    'GEL' => array(
      'code' => 'GEL',
      'symbol' => 'ლ',
      'name' => t('Georgian Lari'),
      'numeric_code' => '981',
      'symbol_placement' => 'before',
      'code_placement' => 'hidden',
      'minor_unit' => t('Tetri'),
      'major_unit' => t('Lari'),
    ),
Categories: Issue Queues

Add line item in /admin/commerce/orders/NNN/edit no longer has arguments

Wed, 04/30/2014 - 06:57

Upgraded to Commerce Kickstart 7.x.2.13 (commerce = "7.x-1.9" ) and lost the following functionality:

It used to be when you went to /admin/commerce/orders/NNN/edit and selected a line item from the AJAX button "Add line item" if that line item type (XXXX) had custom input field (e.g. /admin/commerce/config/line-items/XXXX/fields/ZZZZ ) you'd get a text box where you could type in that information for field ZZZZ. Now that functionality has been lost so if you use that "Add line item" button you can add the line item to the order, but not any of it's custom field information.

Kind of a major loss in functionality as it means people can no longer modify existing orders and enter that custom information.

I'm pretty sure this was working at version Commerce Kickstart 7.x.2.9 ( commerce = "7.x-1.8"), but I'm not sure which upgrade
killed the functionality as it was only brought to my attention recently.

I'm not sure if this is related to https://drupal.org/node/1211278

Categories: Issue Queues

undefined function commerce_i18n_object()

Wed, 04/30/2014 - 06:47

When trying to use commerce_order_load or commerce_order_load_by_number in a custom module I get the fatal error:

Fatal error: Call to undefined function commerce_i18n_object() in /.../sites/all/modules/commerce/modules/customer/commerce_customer.module on line 412

I grepped through the Commerce module directory and found several references to commerce_i18n_object but don't see where it's defined. Am I missing a dependency or something?

Thanks!

Categories: Issue Queues

Hard-coded values ?

Wed, 04/30/2014 - 04:44

I'am getting this issues in order edit page:

Notice: Trying to get property of non-object in commerce_entity_access() (line 1040 of /var/www/mypath/sites/all/modules/contrib/commerce/commerce.module).
Notice: Trying to get property of non-object in commerce_entity_access() (line 1040 of /var/www/mypath/sites/all/modules/contrib/commerce/commerce.module).

After a wile a found that:

+ Apply pricing rules (menu item)
&&
+ Simulate checkout completion (menu item)

is calling "commerce_order_access" with argument 2 an number (3) and not the entity object "$order".

Categories: Issue Queues