Posted by pavel.karoukin on May 13, 2012 at 11:01pm
5 followers
| Project: | Drupal Commerce |
| Version: | 7.x-1.x-dev |
| Component: | Product reference |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | postponed (maintainer needs more info) |
Issue Summary
I have a node View, which pulls product through Relationship with referenced product. This works well.
Where it fails - my product (CD) have product reference fields (Tracks) and these would not pull through Relationship. After looking into actual SQL query run on DB, I think there is minor bug with declaration, although I am not too good with Views, so please review attached patch and let me know what do you think.
View I am using also attached.
| Attachment | Size | Status | Test result | Operations |
|---|---|---|---|---|
| product_reference_views.patch | 1.27 KB | Idle | FAILED: [[SimpleTest]]: [MySQL] Unable to apply patch product_reference_views.patch. Unable to apply patch. See the log in the details link for more information. | View details | Re-test |
| albums_tracks_view.txt | 10.18 KB | Ignored: Check issue status. | None | None |
Comments
#1
The last submitted patch, product_reference_views.patch, failed testing.
#2
another try with patch to pass auto test.
#3
product_reference_views.patch queued for re-testing.
#4
Can you post an export of the View used to generate the error and the product type configuration we should have to test this out?
#5
@scrypt : you can use Features and Commerce features to export all the configurations Ryan (rszrama) asked for.
#6
The current implementation does seem incorrect - but the problem would on present itself when using a product_reference field on a product bundle. I agree with #2, but at the same time it really is a (minor) API change. However, I tried to create situations where this patch could break stuff and I didn't came across anything.
#7
I think I get the second hunk, but I'm not so sure about the first. For the field schema, the entity_id is the ID of the entity the product reference field is attached to. So it seems like you're be trying to join from the left product_id to the right nid (or whatever ID of the entity the field is on). Are we sure it isn't correct to have it joining to the [field_name]_product_id in the first hunk?