CMS MADE SIMPLE FORGE

Cart Made Simple

 

[#3459] Compatibility with other modules

avatar
Created By: Pierre-Luc Germain (plger)
Date Submitted: 2009-05-21 12:58

Assigned To:
Resolution: None
State: Open
Summary:
Compatibility with other modules
Detailed Description:
Allowing other modules to add items to the CartMadeSimple cart would be very
interesting. And it seems to me that the job wouldn't be too hard either. From
what I've seen, SMS is used only in the orders api (elsewhere just to get the
weight unit), so all that would be to change are the ShowCart, GenerateOrder and
GetOrderLines functions. You could save the module name (which is already passed
in the add to cart link) in the carts table, and in, say, ShowCart, instead of
having hard-coded queries with SMS, the cart could ask the appropriate module to
return the product informations. Other modules would only need to include this
function and create links to CartMadeSimple, and the integration is done.

History

Comments
avatar
Date: 2009-05-21 14:14
Posted By: Duketown  (duketown)

Thanks for these thoughts. I understand that this would benefit those that want
another product handling module.
This is not a light change (baring in mind that testing is to be done with a
number of modules available).
What if the product module owner has no intentions to change coding for this?
Time, time, time. If I could only buy that (firsthand or secondhand I don't
mind).
Patience will be strechted here.

Duketown
      
avatar
Date: 2009-05-22 05:20
Posted By: Pierre-Luc Germain (plger)

Thanks for answering...
Of course this would mean that the other modules would have to conform their
code to be integrated, but for them it would mean little change (just adding a
small function or two). You don't have to test so much: if they wish to use the
Cart, they conform their modules.
To be perfectly honest, I had started integrating functions in my CTLModuleMaker
to make the created modules compatible with CartMadeSimple, I did it already
with a modified version of CartMadeSimple, but it seemed inelegant to me to ask
the users to change the Cart's code...
If you are interested, I'd be more than happy to help and suggest the code
changes for this.
      
Updates

Updated: 2009-05-21 14:14
resolution_id: => 5