Comments

luke_b’s picture

StatusFileSize
new17.99 KB

Here's the promised patch. Diff is forked from commit: e0d05410df026bb2448f ("Instead of using a delete link directly in the Payment View, use a new Operations ..."). Should be straight forward to merge, because I see only payment and transaction stuff has been touched/modified since then.

luke_b’s picture

Any inputs on that one?

damien tournoud’s picture

We already discussed that a fair bit at each sprint, but apparently failed to move the thoughts into code.

I would strongly prefer if we could:

  • rely solely on hook_product_type_info() for the commerce_product module
  • move the whole db-based product type implementation to product_ui (the UI would only allow db-based types to be modified)

The suggested implementation (#1), modeled around node types implementation in core, feels needlessly complicated.

rszrama’s picture

Status: Needs review » Needs work

Damien, your suggestions make sense - I don't think I ever revisited the product definition b/c our discussion was centered around order statuses at the time... but we did rewrite the checkout page implementation and can easily make rewriting this an alpha3 milestone. It shouldn't be that much work.

damien tournoud’s picture

One other thing comes to mind: we should consider moving product types to exportables, as CTools on Drupal 7 is getting ready for prime-time. After all product types is configuration (ie. there should only be a handful of them).

luke_b’s picture

Exportables and Ctools were our first choice too, however, we decided to write an own implementation for product types in features because the schedule for Ctools and D7 was unclear to us. Will switch to this approach when Ctools is ready. Thanks!

rszrama’s picture

Note to self: when Product UI is updated to use hook_commerce_product_info(), the basic product display created in commerce_product.install should be moved to commerce_product_ui.install. This allows it to be easily deleted instead of defining it via the hook as we do for default order states / statuses.

rszrama’s picture

Status: Needs work » Fixed

Spent the afternoon getting all this code switched around. It seems to test just fine. I'm thinking we should probably have a contributed module called Commerce Features or something that handles Features integration, no? Or should we just use Ctools and make that core since Views 3 requires it now anyways? In either case, let's open another issue for it as necessary.

Commit: https://github.com/rszrama/drupalcommerce/commit/7f72e874f88e018a80a2f30...

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.