These are chat archives for reactioncommerce/reaction

14th
Sep 2015
Aesop7
@Aesop7
Sep 14 2015 00:48
I'm guessing I shouldn't just go into .meteor/versions and start changing things...
is pulling the repos via the shell script the best way to upgrade right now? Will it be possible to run a 'meteor update' soon instead?
Aaron Judd
@aaronjudd
Sep 14 2015 01:21
v0.7.0 - is just development branch, so I haven't published it yet - to be honest I don't have a firm policy on this yet -> the correct thing is to say, that until we merge to master I don't publish any packages from the development branch. that said, sometimes I do - and just rely on package dependencies to not screw anyone up.
Aaron Judd
@aaronjudd
Sep 14 2015 01:30
I've just updated the shell script, and to be honest it's what I use. that said, I'll be moving to publish this release pretty quickly (a few days) (this should be one of the safe cases and almost everything got a major version bump)
Aaron Judd
@aaronjudd
Sep 14 2015 01:38
@Aesop7 I think now might be one of those times, where I publish, and rely on the package system - I'm personally blocked - so there goes the rules. :shipit:
Aesop7
@Aesop7
Sep 14 2015 02:30
Thanks @aaronjudd TBH, I'm just used to the meteor update workflow (JS noob here), but i'm chomping at the bit to try the new accounts package, so I think I'll probably give the shell script a shot tomorrow.
Aesop7
@Aesop7
Sep 14 2015 12:14
Well I just woke up and tried a meteor update before work... lo and behold i'm now at v. 0.7! Thank You!!! :clap:
Aaron Judd
@aaronjudd
Sep 14 2015 15:09
:thumbsup:
Bogi
@boboci9
Sep 14 2015 16:18
Hi, I have taken a look into the new version of the RC and I wanted to ask if you have any suggestions how can I extend the CartWorkflow, and OrderWorkflow in the new version? I know that these two object doesn't exitst anymore in the new version so I don't know how could I add or change a step in the workflows now? Do you have any suggestions?
Michael Jenny
@prinzdezibel
Sep 14 2015 16:37
@aaronjudd: When adding items to the cart, the quantity is updated if there's already an variant of the selected item in cart. Now I don't want that. My question is: Is it possible to override the addToCart server method somehow? Or does it even make sense to have this configurable?
But probably the existing behaviour makes sense for 98 % of all use cases.
It is not good if you want to display the cart's content in chronological order.
It's not suitable for me that the last added product MAY NOT appear last in the cart item list.
e.g. the cart drawer
Mike Murray
@mikemurray
Sep 14 2015 16:47
@prinzdezibel it might be best to override the template and make your own query clent side. That way you'd have complete control over the order and display of the items.
Michael Jenny
@prinzdezibel
Sep 14 2015 17:27
@mikemurray: Problem is, that server side addToCart method is merging multiple instances of one product into one record. I'd like to prevent this.
With overriding client side template/helpers I can't restore the relevant information anymore. (Which product was added in which order.)
Michael Jenny
@prinzdezibel
Sep 14 2015 17:52
@mikemurray: thx. I'm ok. There's an internal data structure for server methods which can be overriden in my case. Meteor.default_server.method_handlers['addToCart'] = myAddToCart;
This message was deleted
Did you have any tooling for converting from cs to js?
Mike Murray
@mikemurray
Sep 14 2015 17:57
just the coffee script compiler and a bash script
Aaron Judd
@aaronjudd
Sep 14 2015 17:58
I used atom-compile-coffee with Atom.io, because I wanted to handle each file as I converted
Aaron Judd
@aaronjudd
Sep 14 2015 18:22
@boboci9 the workflow is now purely in the data, so persistentent at all times
and also in the packages.md docs
Spencer Norman
@spencern
Sep 14 2015 18:24
I’ve also used atom-compile-coffee as my primary weapon for CS->ES
Aaron Judd
@aaronjudd
Sep 14 2015 18:25
actually ignore those workflow docs, it’s not very accurate. I’ll update them now. essentially: the default workflow is stored in Packages.layout, so to customize, you can update the packages collection.
this will be the same workflow mechanism for orders, carts, and publishing.
orders, and publishing are under construction, but should be pushing the key pieces this week.
the state of the workflow is stored in the collection itself (cart.workflow, orders.workflow)
Mike Murray
@mikemurray
Sep 14 2015 18:29
This is what I used to do a mass conversion of coffee -> js
# step 1
find . -type d -exec coffee -b -c --no-header . \;

# some time later
find . -name "*.coffee" -type f -delete
Aaron Judd
@aaronjudd
Sep 14 2015 18:32
@prinzdezibel maybe you could do something using ReactionCore.MethodHooks.before(‘addToCart', function(options) {
oh yeah - because 0.7.0 now includes MethodHooks
Aaron Judd
@aaronjudd
Sep 14 2015 20:40
@boboci9 workflow docs updated, hope that helps.
Bogi
@boboci9
Sep 14 2015 20:45
Thanks, I will take a look