Commit Graph

284 Commits

Author SHA1 Message Date
Rohan Mitchell
e6041aaf2f Enterprise user can view, create and edit payment methods 2013-10-18 09:09:53 +11:00
Rohan Mitchell
93cb845ee2 DB and model changes to make ShippingMethod distributor habtm 2013-10-17 11:15:43 +11:00
Rohan Mitchell
8654f23a19 Move spree model decorator specs into their own dir to mirror model dir layout 2013-10-17 09:53:54 +11:00
Rohan Mitchell
30bc45370b When order cycle expires mid-order, clear the order cycle and display a message 2013-09-30 16:56:11 +10:00
Rohan Mitchell
f5b56617a0 As an enterprise user, when I create an enterprise, I should have management permission for it 2013-09-30 11:10:20 +10:00
Rohan Mitchell
01036ec730 Add LineItem#supplied_by scope, fixes orders and fulfillment report supplier filtering 2013-09-27 14:11:12 +10:00
Rohan Mitchell
dac49d1044 Order cycle-aware pickup time 2013-09-27 11:17:24 +10:00
Rohan Mitchell
68fe20c37a Add scope: Exchange.with_product 2013-09-23 17:39:16 +10:00
Rohan Mitchell
19349c805f Destroy supplied products when a supplier is destroyed 2013-09-23 14:58:26 +10:00
Rohan Mitchell
450a1e49c2 Do not 500 when add to cart fails 2013-09-23 14:15:53 +10:00
Rohan Mitchell
08941ae22b Data integrity 2013-09-19 11:22:55 +10:00
David Cook
5ec3c1831d Only show order cycles that the user has access to in reports drop-down 2013-09-18 09:26:50 +10:00
Rohan Mitchell
2f73161421 Move patch to address class - much simpler 2013-09-18 07:14:21 +10:00
Rohan Mitchell
a929312979 Add scope: OrderCycle.with_distributor 2013-09-17 09:54:21 +10:00
Rohan Mitchell
0e8443e118 Rename 'Change Pick-up Date' to 'Change Collection Date'. Fix this to clear the cart. Do not clear distributor when setting Order.order_cycle to nil. 2013-09-10 11:28:49 +10:00
Rohan Mitchell
644beeb093 Revert "Fix test fail"
This reverts commit 1de0f85c73.
2013-09-09 10:55:40 +10:00
Rohan Mitchell
1de0f85c73 Fix test fail 2013-09-09 10:41:28 +10:00
Rohan Mitchell
d32a8b56d0 When order cycle is selected, only show variants that are in it 2013-09-09 10:40:15 +10:00
alexs333
80bb55496b Temporarily disabling some tests. 2013-09-05 14:18:40 +10:00
alexs333
999bc2697a Implemented simlified shop flow. 2013-09-04 20:33:18 +10:00
David Cook
25b25b7681 New scope Order.not_state to filter out cancelled orders from reports 2013-08-30 17:07:17 +10:00
David Cook
bf3c5c6dd6 Merge branch 'master' into reports-completed-only
Conflicts:
	app/controllers/spree/admin/reports_controller_decorator.rb
2013-08-30 16:42:00 +10:00
Rohan Mitchell
cace60b187 Shipping methods are only shown at checkout if their distributor matches the order 2013-08-30 12:27:13 +10:00
Rohan Mitchell
911d8b8bbc Shipping method has a distributor, admin can create and edit 2013-08-30 11:43:45 +10:00
Rohan Mitchell
9824e1b9c5 Make spec more precise and robust - query was finding outgoing instead of incoming exchange 2013-08-27 10:41:02 +10:00
Rohan Mitchell
6a5d819fa6 Enterprise manager can create an order 2013-08-27 10:05:55 +10:00
Rohan Mitchell
8a092697ee Enterprise manager can clone an order cycle 2013-08-22 17:11:53 +10:00
Rohan Mitchell
f1fa90d7c3 Clone order cycles 2013-08-22 16:53:11 +10:00
Rohan Mitchell
f870e70560 Enterprise manager can edit and bulk edit enterprises they have access to 2013-08-22 11:40:33 +10:00
Rohan Mitchell
aab7176f2c Enterprise manager can bulk edit products 2013-08-22 11:21:49 +10:00
Rohan Mitchell
31a078a53c Enterprise manager can access enterprise fees for enterprises they manage - fixes fees on order cycles interface 2013-08-20 16:26:46 +10:00
Rohan Mitchell
562365311e Lock enterprise fee adjustments on creation to avoid them being recalculated against order by update hooks 2013-08-19 14:38:51 +10:00
Rohan Mitchell
ba4d3d5d7d Removing a product from cart removes its fees 2013-08-19 12:19:03 +10:00
Rohan Mitchell
7a75898b2b Find exchanges going to/from any number of enterprises 2013-08-19 10:41:14 +10:00
Rohan Mitchell
e15e9a1476 Charge order cycle fees 2013-08-19 10:41:14 +10:00
Rohan Mitchell
dfd1a89975 Test whether exchanges are incoming 2013-08-19 10:41:14 +10:00
Rohan Mitchell
9563aad9fa Find exchanges with a particular variant 2013-08-19 10:41:14 +10:00
Rohan Mitchell
1d23446c40 ProductDistribution validates_presence_of enterprise fee, check no longer required 2013-08-19 10:41:14 +10:00
Rohan Mitchell
591f6a8a57 Move ProductDistribution#clear_all_enterprise_fee_adjustments_for to EnterpriseFee class 2013-08-19 10:41:14 +10:00
Andrew Spinks
38522e2b74 Fix order cycle permissions for enterprise user. 2013-08-18 19:41:04 +10:00
Andrew Spinks
82726d032c Add enterprise roles for order cycles. 2013-08-16 11:34:07 +10:00
Rohan Mitchell
552cecb2e0 Find incoming and outgoing exchanges 2013-08-16 10:22:29 +10:00
alexs
b8bc30d4ab Fixed the test setup and added the text for the bug found in 'Enterprise.find_near'. 2013-08-15 17:34:51 +10:00
Andrew Spinks
9c6c4724be Ensure line items only get created in correct orders when adding a product to a cart. 2013-08-14 10:49:55 +10:00
Andrew Spinks
d5791657f3 Support multiple orders when adding a product to a cart. 2013-08-14 10:49:55 +10:00
Andrew Spinks
dd3aaccf9f When adding a variant to a cart, split into multiple orders depending on the distributors that it contains. 2013-08-14 10:49:55 +10:00
alexs
e90ccef337 Merge branch 'master' of github.com:eaterprises/openfoodweb 2013-08-13 11:40:54 +10:00
Rohan Mitchell
5f4313b588 Remove itemwise shipping calculator 2013-08-13 10:14:39 +10:00
Rohan Mitchell
7677f79f17 Remove the now-unused Product#shipping_method_for_distributor 2013-08-13 09:11:26 +10:00
Rohan Mitchell
94e49d4190 Remove line item specs for removed functionality 2013-08-13 09:11:26 +10:00