Commit Graph

21845 Commits

Author SHA1 Message Date
Rohan Mitchell
69019859da Refactor views 2013-06-20 15:14:23 +10:00
Rohan Mitchell
b8d0e3f49a OrderPopulator decorator checks cart contents against order cycle as well as distributor 2013-06-20 15:13:59 +10:00
David Cook
98be44b301 Disable asset debug logging 2013-06-20 11:50:34 +10:00
David Cook
4e2549d347 Add host setting, required for authenticating local DBs 2013-06-20 11:49:36 +10:00
David Cook
65af89c962 ignore new rvm files 2013-06-20 11:48:22 +10:00
Rohan Mitchell
12fb43e268 DistributionChangeValidator returns an empty array when distributor and order cycle are both nil 2013-06-17 16:01:10 +10:00
Rohan Mitchell
1d977de328 Order validation performed over both product distribution and order cycle distribution 2013-06-17 15:06:41 +10:00
Rohan Mitchell
705af41684 DistributionChangeValidator finds variants distributed by product distribution when order cycle is nil 2013-06-17 15:06:20 +10:00
Rohan Mitchell
be29974dd8 DistributionChangeValidator checks if an order can change to a specified new distributION 2013-06-17 15:00:19 +10:00
Rohan Mitchell
27b5dc071a Order cycle reports on the variants distributed by a particular distributor 2013-06-17 14:58:13 +10:00
Rohan Mitchell
17103a8b0c Remove DistributionChangeValidator#can_change_distributor? method 2013-06-17 14:00:39 +10:00
Rohan Mitchell
da02cb5a93 Reorder specs 2013-06-17 12:05:46 +10:00
Rohan Mitchell
a355a09a7c Disable distributor change in checkout until it takes order cycles into account 2013-06-17 11:45:23 +10:00
Rohan Mitchell
b5479380b6 Refactor alternative distributors at checkout form, fixing indentation and removed double negatives 2013-06-17 11:41:35 +10:00
Rohan Mitchell
6d22f56c86 Distribution selection form is not shown when there are products in the cart.
This form doesn't filter options based on which can supply the products in the cart,
so don't show it in those circumstances.
2013-06-17 11:29:36 +10:00
Rohan Mitchell
95de78f24e Tidy-ups 2013-06-17 10:03:00 +10:00
Rohan Mitchell
bfe8184b6a Reload order before setting variant attributes, fixes group buy 2013-06-17 10:02:49 +10:00
David Cook
1a9fd4a9a8 Merge branch 'supplied-active-products-on-hand' of github.com:eaterprises/openfoodweb into supplied-active-products-on-hand 2013-06-14 17:40:12 +10:00
David Cook
7933dea611 WIP: add more tests 2013-06-14 17:38:51 +10:00
David Cook
7ce7107c6c Add meaningfull ids and classnames 2013-06-14 17:37:44 +10:00
David Cook
1abc0dac68 rename vars again 2013-06-14 17:36:38 +10:00
Rohan Mitchell
065ea6a1a1 Remove controller specs that are now covered by OrderPopulator 2013-06-14 14:57:31 +10:00
Rohan Mitchell
4e5f0b9963 Set potential distributor and order cycle before attempting add to cart, revert on failure 2013-06-14 14:57:08 +10:00
Rohan Mitchell
772d01abf7 Merge branch 'favicon' 2013-06-14 12:22:51 +10:00
Rohan Mitchell
063d760047 Merge branch 'master' into supplied-active-products-on-hand 2013-06-14 11:07:24 +10:00
Rohan Mitchell
26c3b80e87 Reverse unintentional changes to database.yml and db/schema.rb 2013-06-14 11:05:56 +10:00
David Cook
1a06b53b21 More verbose sign in error message 2013-06-13 16:29:45 +10:00
David Cook
203232de27 Disable as this has now been incorporated into move_save_checkout_button 2013-06-13 12:30:35 +10:00
David Cook
aa468140ac Move save/process button to side on checkout pages 2013-06-13 12:29:34 +10:00
Rohan Mitchell
5e120b35aa Ensure orders controller decorator is loaded, fixes home controller test failures 2013-06-13 07:57:03 +10:00
David Cook
30253ffd07 align actions column left for better usability 2013-06-12 15:51:07 +10:00
David Cook
017275f40e fix error when order has no payments (ie not yet complete) 2013-06-12 15:40:36 +10:00
David Cook
7381163023 test for cancelled orders in order and distributor report 2013-06-12 15:19:45 +10:00
David Cook
ea3922a023 filter out cancelled orders from the reports 2013-06-12 15:19:14 +10:00
David Cook
415de37a6a WIP for order spec 2013-06-12 13:33:15 +10:00
David Cook
cf4582c08e Create respond_override to return user back to the referring page. (But it breaks payments#create respond_with..) 2013-06-12 11:24:49 +10:00
David Cook
2b15f92ab8 fix capture button to link to latest payment 2013-06-12 09:58:44 +10:00
David Cook
269c6ac14f Use CSS substring selector for selecting Capture link by order number 2013-06-11 17:16:37 +10:00
David Cook
ada95183a2 Start respond_override 2013-06-11 17:09:41 +10:00
David Cook
fb25946acd Start to write a test spec.. (not complete) 2013-06-11 17:00:07 +10:00
David Cook
df769a2f4c ensure latest 'payment' object is used for the capture button 2013-06-11 16:57:14 +10:00
David Cook
4967093b72 Add capture button and resize columns 2013-06-11 15:07:41 +10:00
Rohan Mitchell
71ee764d65 Fix travis fails - set deployment before requiring gems, race condition in distributor info spec 2013-06-07 17:08:55 +10:00
Rohan Mitchell
cbeffaced1 Configure Travis, remove spork, add simplecov, add turbo sprokets.
Add travis config
(cherry picked from commit e3fdb12289)

Only build on Ruby 1.9.3
(cherry picked from commit 719ef386bf)

Exclude pry from CI build
(cherry picked from commit d60935c800)

Conflicts:

	Gemfile

Attempt 2
(cherry picked from commit 2b19253895)

Conflicts:

	Gemfile.lock

Configure travis for postgres
(cherry picked from commit 3a441cd7d9)

Fix migrations that fail because of coupling to changed/removed models
(cherry picked from commit b030793f15)

Set up xvfb for Travis
(cherry picked from commit cdc3ab09a1)

Add a failing test to test travis
(cherry picked from commit 72aa8fe5e5)

Revert "Add a failing test to test travis"

This reverts commit 72aa8fe5e5.
(cherry picked from commit bd5533e2b1)

Add simplecov
(cherry picked from commit 5089d3bb22)

Conflicts:

	Gemfile.lock

Add turbo sprockets for faster asset precompile
(cherry picked from commit 3e6c56a638)

Remove spork
(cherry picked from commit ed7bded642)

Conflicts:

	spec/spec_helper.rb

Remove more spork-specific things, remove unused cuc config from zeus
(cherry picked from commit fa11ff8982)

Ensure order decorator is required, fix test fragility
(cherry picked from commit 1e94f88c5e)
2013-06-07 16:23:24 +10:00
Rohan Mitchell
1e94f88c5e Ensure order decorator is required, fix test fragility 2013-06-07 15:40:03 +10:00
Rohan Mitchell
1e0491e90f Add spec for OrderPopulator#check_variant_available_under_distributor 2013-06-05 16:00:17 +10:00
Rohan Mitchell
e90077bb09 Add spec for OrderPopulator#order_cycle_required_for 2013-06-05 15:54:45 +10:00
Rohan Mitchell
4bcae29553 Add specs for OrderPopulator#check_distribution_provided_for and distribution_provided_for 2013-06-05 15:50:20 +10:00
Rohan Mitchell
f4df69765d Add spec for OrderPopulator#distributor_can_supply_products_in_cart 2013-06-05 15:09:11 +10:00
Rohan Mitchell
3724a67d16 Add spec for OrderPopulator#set_cart_distributor_and_order_cycle 2013-06-05 15:04:42 +10:00