2
Answers
Vote up!
1
Vote down!

How do I create a relationship to the table commerce_options?

I've got a commerce installation using product attributes and product options. Everything appears to be working when I add options to the products. When I add products in the shopping cart, the system asks me all the options as I prepared this.

problem : in Views I'm not able to create a relationship to the table : commerce options (There are no relationships available to add)
I would like to link this table to the commerce line items by the common : line item id

(ps in the table commerce line items there is a field : product attributes that includes all commerce options for this line , however this is one field that I can't cut into the separated fields ?)

Asked by: godfriedv
on May 31, 2012

Comments

Are you using the actual Commerce Options module or using that to refer to the options of your product attribute fields?

- Ryan Szrama on May 31, 2012

Thanks for replying

I'm trying to make a Data export (views3) in a csv file of the pending orders and all of there data.. options ... products...price ... quantiy....

in my product types I've got 2 kinds of options linked to them
- the one I use as - attribute field- is linked to a taxonomy vocabulary ( this data I find in the product table related to the -commerce orders-)
- the ones that are not used as attribute have been created in - option sets- (These I see in the table -commerce option- but I can't link this table to any other table)

- godfriedv on May 31, 2012

2 Answers

Vote up!
2
Vote down!

Alrighty, sorry, I had the module name wrong in my comment above requesting clarification. The module you're using is Commerce Product Option, which as far as I can tell is no longer in active development and has actually been deprecated since we introduced the ability to expose line item fields to the Add to Cart form. That's the module that defines the commerce_option table, but if you look in that module's .views.inc file, you can see that they're doing nothing to integrate the table with Views. Unfortunately, until you or someone adds the necessary table definition, you won't be able to access your option data through Views.

Ryan Szrama
Answer by: Ryan Szrama
Posted: May 31, 2012
Vote up!
1
Vote down!

Hi,

I indroduced the Product Inline Entity and have been playing with it ,I'm able to attache options to a line item type and to let the customer fill it in , however , I don't see how I can make these options depandable of the producttype.

now for each order I have the same options the system is asking for .

how can I let the system ask for different options depending on the different productypes while adding to the cart (this was what product options did) ?

Answer by: godfriedv
Posted: Jun 1, 2012