spree_backend 2.3.13 → 2.4.0.rc1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (163) hide show
  1. checksums.yaml +4 -4
  2. data/app/assets/javascripts/spree/backend/address_states.js +1 -3
  3. data/app/assets/javascripts/spree/backend/adjustments.js.coffee +1 -2
  4. data/app/assets/javascripts/spree/backend/admin.js.erb +11 -1
  5. data/app/assets/javascripts/spree/backend/checkouts/edit.js +1 -20
  6. data/app/assets/javascripts/spree/backend/line_items.js.coffee +2 -5
  7. data/app/assets/javascripts/spree/backend/line_items_on_order_edit.js.erb +50 -0
  8. data/app/assets/javascripts/spree/backend/option_type_autocomplete.js.erb +2 -4
  9. data/app/assets/javascripts/spree/backend/orders/edit_form.js +2 -3
  10. data/app/assets/javascripts/spree/backend/payments/edit.js.coffee +5 -5
  11. data/app/assets/javascripts/spree/backend/product_picker.js +2 -4
  12. data/app/assets/javascripts/spree/backend/returns/expedited_exchanges_warning.coffee +4 -0
  13. data/app/assets/javascripts/spree/backend/returns/return_item_selection.js +35 -0
  14. data/app/assets/javascripts/spree/backend/shipments.js.erb +39 -52
  15. data/app/assets/javascripts/spree/backend/stock_movement.js.coffee +1 -2
  16. data/app/assets/javascripts/spree/backend/stock_transfer.js.coffee +1 -2
  17. data/app/assets/javascripts/spree/backend/taxon_autocomplete.js.erb +8 -6
  18. data/app/assets/javascripts/spree/backend/taxonomy.js.coffee +5 -24
  19. data/app/assets/javascripts/spree/backend/taxons.js.coffee +2 -4
  20. data/app/assets/javascripts/spree/backend/user_picker.js +2 -3
  21. data/app/assets/javascripts/spree/backend/variant_autocomplete.js.coffee.erb +2 -2
  22. data/app/assets/stylesheets/spree/backend/components/_navigation.scss +0 -5
  23. data/app/assets/stylesheets/spree/backend/plugins/_select2.scss +5 -2
  24. data/app/assets/stylesheets/spree/backend/sections/_adjustments_table.scss +8 -0
  25. data/app/assets/stylesheets/spree/backend/sections/_products.scss +4 -0
  26. data/app/assets/stylesheets/spree/backend/sections/_return_authorizations.scss +24 -0
  27. data/app/assets/stylesheets/spree/backend/sections/_taxons.scss +1 -7
  28. data/app/assets/stylesheets/spree/backend/shared/_tables.scss +8 -0
  29. data/app/assets/stylesheets/spree/backend/spree_admin.scss +2 -0
  30. data/app/assets/stylesheets/spree/backend.css +1 -1
  31. data/app/controllers/spree/admin/adjustments_controller.rb +1 -7
  32. data/app/controllers/spree/admin/base_controller.rb +8 -2
  33. data/app/controllers/spree/admin/customer_returns_controller.rb +67 -0
  34. data/app/controllers/spree/admin/general_settings_controller.rb +1 -1
  35. data/app/controllers/spree/admin/images_controller.rb +1 -1
  36. data/app/controllers/spree/admin/log_entries_controller.rb +2 -2
  37. data/app/controllers/spree/admin/option_types_controller.rb +1 -1
  38. data/app/controllers/spree/admin/orders/customer_details_controller.rb +2 -2
  39. data/app/controllers/spree/admin/orders_controller.rb +21 -10
  40. data/app/controllers/spree/admin/payment_methods_controller.rb +3 -3
  41. data/app/controllers/spree/admin/payments_controller.rb +6 -12
  42. data/app/controllers/spree/admin/product_properties_controller.rb +2 -2
  43. data/app/controllers/spree/admin/products_controller.rb +1 -1
  44. data/app/controllers/spree/admin/promotion_actions_controller.rb +2 -2
  45. data/app/controllers/spree/admin/promotion_categories_controller.rb +6 -0
  46. data/app/controllers/spree/admin/promotion_rules_controller.rb +2 -2
  47. data/app/controllers/spree/admin/promotions_controller.rb +2 -1
  48. data/app/controllers/spree/admin/refund_reasons_controller.rb +6 -0
  49. data/app/controllers/spree/admin/refunds_controller.rb +31 -0
  50. data/app/controllers/spree/admin/reimbursement_types_controller.rb +6 -0
  51. data/app/controllers/spree/admin/reimbursements_controller.rb +44 -0
  52. data/app/controllers/spree/admin/resource_controller.rb +2 -2
  53. data/app/controllers/spree/admin/return_authorization_reasons_controller.rb +6 -0
  54. data/app/controllers/spree/admin/return_authorizations_controller.rb +35 -5
  55. data/app/controllers/spree/admin/return_items_controller.rb +9 -0
  56. data/app/controllers/spree/admin/search_controller.rb +1 -1
  57. data/app/controllers/spree/admin/shipping_methods_controller.rb +3 -3
  58. data/app/controllers/spree/admin/states_controller.rb +1 -1
  59. data/app/controllers/spree/admin/stock_items_controller.rb +1 -1
  60. data/app/controllers/spree/admin/stock_locations_controller.rb +1 -1
  61. data/app/controllers/spree/admin/stock_transfers_controller.rb +2 -2
  62. data/app/controllers/spree/admin/tax_rates_controller.rb +1 -1
  63. data/app/controllers/spree/admin/users_controller.rb +4 -4
  64. data/app/controllers/spree/admin/variants_controller.rb +2 -2
  65. data/app/controllers/spree/admin/zones_controller.rb +1 -1
  66. data/app/helpers/spree/admin/customer_returns_helper.rb +9 -0
  67. data/app/helpers/spree/admin/navigation_helper.rb +1 -1
  68. data/app/helpers/spree/admin/reimbursement_type_helper.rb +9 -0
  69. data/app/helpers/spree/admin/reimbursements_helper.rb +14 -0
  70. data/app/views/spree/admin/adjustments/_adjustments_table.html.erb +7 -3
  71. data/app/views/spree/admin/customer_returns/_reimbursements_table.html.erb +36 -0
  72. data/app/views/spree/admin/customer_returns/_return_item_decision.html.erb +50 -0
  73. data/app/views/spree/admin/customer_returns/_return_item_selection.html.erb +43 -0
  74. data/app/views/spree/admin/customer_returns/edit.html.erb +65 -0
  75. data/app/views/spree/admin/customer_returns/index.html.erb +60 -0
  76. data/app/views/spree/admin/customer_returns/new.html.erb +60 -0
  77. data/app/views/spree/admin/general_settings/edit.html.erb +6 -0
  78. data/app/views/spree/admin/images/_form.html.erb +6 -6
  79. data/app/views/spree/admin/log_entries/_credit_card.html.erb +4 -0
  80. data/app/views/spree/admin/log_entries/index.html.erb +2 -5
  81. data/app/views/spree/admin/option_types/_option_value_fields.html.erb +5 -7
  82. data/app/views/spree/admin/option_types/edit.html.erb +9 -2
  83. data/app/views/spree/admin/orders/_add_line_item.html.erb +18 -0
  84. data/app/views/spree/admin/orders/_form.html.erb +7 -7
  85. data/app/views/spree/admin/orders/_line_items_edit_form.html.erb +40 -0
  86. data/app/views/spree/admin/orders/_shipment.html.erb +1 -1
  87. data/app/views/spree/admin/orders/_shipment_manifest.html.erb +5 -4
  88. data/app/views/spree/admin/orders/cart.html.erb +39 -0
  89. data/app/views/spree/admin/orders/customer_details/_form.html.erb +1 -1
  90. data/app/views/spree/admin/orders/edit.html.erb +2 -2
  91. data/app/views/spree/admin/orders/index.html.erb +8 -14
  92. data/app/views/spree/admin/payment_methods/_form.html.erb +7 -7
  93. data/app/views/spree/admin/payments/_list.html.erb +11 -3
  94. data/app/views/spree/admin/payments/index.html.erb +13 -1
  95. data/app/views/spree/admin/product_properties/_product_property_fields.html.erb +4 -6
  96. data/app/views/spree/admin/products/_form.html.erb +20 -6
  97. data/app/views/spree/admin/products/new.html.erb +3 -3
  98. data/app/views/spree/admin/products/stock.html.erb +1 -1
  99. data/app/views/spree/admin/promotion_categories/_form.html.erb +10 -0
  100. data/app/views/spree/admin/promotion_categories/edit.html.erb +17 -0
  101. data/app/views/spree/admin/promotion_categories/index.html.erb +34 -0
  102. data/app/views/spree/admin/promotion_categories/new.html.erb +16 -0
  103. data/app/views/spree/admin/promotion_rules/create.js.erb +2 -0
  104. data/app/views/spree/admin/promotions/_actions.html.erb +1 -1
  105. data/app/views/spree/admin/promotions/_form.html.erb +5 -0
  106. data/app/views/spree/admin/promotions/actions/_create_line_items.html.erb +7 -7
  107. data/app/views/spree/admin/promotions/index.html.erb +16 -6
  108. data/app/views/spree/admin/promotions/rules/_item_total.html.erb +4 -2
  109. data/app/views/spree/admin/promotions/rules/_one_use_per_user.html.erb +0 -0
  110. data/app/views/spree/admin/promotions/rules/_taxon.html.erb +9 -0
  111. data/app/views/spree/admin/prototypes/_form.html.erb +2 -2
  112. data/app/views/spree/admin/refund_reasons/edit.html.erb +4 -0
  113. data/app/views/spree/admin/refund_reasons/index.html.erb +5 -0
  114. data/app/views/spree/admin/refund_reasons/new.html.erb +4 -0
  115. data/app/views/spree/admin/refunds/edit.html.erb +31 -0
  116. data/app/views/spree/admin/refunds/new.html.erb +43 -0
  117. data/app/views/spree/admin/reimbursement_types/index.html.erb +33 -0
  118. data/app/views/spree/admin/reimbursements/edit.html.erb +108 -0
  119. data/app/views/spree/admin/reimbursements/index.html.erb +34 -0
  120. data/app/views/spree/admin/reimbursements/show.html.erb +94 -0
  121. data/app/views/spree/admin/return_authorization_reasons/edit.html.erb +4 -0
  122. data/app/views/spree/admin/return_authorization_reasons/index.html.erb +5 -0
  123. data/app/views/spree/admin/return_authorization_reasons/new.html.erb +4 -0
  124. data/app/views/spree/admin/return_authorizations/_form.html.erb +62 -50
  125. data/app/views/spree/admin/return_authorizations/edit.html.erb +6 -8
  126. data/app/views/spree/admin/return_authorizations/index.html.erb +3 -4
  127. data/app/views/spree/admin/return_authorizations/new.html.erb +1 -1
  128. data/app/views/spree/admin/shared/_configuration_menu.html.erb +5 -2
  129. data/app/views/spree/admin/shared/_destroy.js.erb +1 -1
  130. data/app/views/spree/admin/shared/_head.html.erb +1 -2
  131. data/app/views/spree/admin/shared/_order_submenu.html.erb +17 -3
  132. data/app/views/spree/admin/shared/_order_summary.html.erb +7 -0
  133. data/app/views/spree/admin/shared/_product_tabs.html.erb +1 -0
  134. data/app/views/spree/admin/shared/_refunds.html.erb +32 -0
  135. data/app/views/spree/admin/shared/_report_order_criteria.html.erb +12 -12
  136. data/app/views/spree/admin/shared/_tabs.html.erb +2 -2
  137. data/app/views/spree/admin/shared/named_types/_edit.html.erb +17 -0
  138. data/app/views/spree/admin/shared/named_types/_form.html.erb +16 -0
  139. data/app/views/spree/admin/shared/named_types/_index.html.erb +52 -0
  140. data/app/views/spree/admin/shared/named_types/_new.html.erb +16 -0
  141. data/app/views/spree/admin/shipping_categories/_form.html.erb +1 -1
  142. data/app/views/spree/admin/shipping_methods/_form.html.erb +8 -0
  143. data/app/views/spree/admin/stock_locations/_form.html.erb +77 -59
  144. data/app/views/spree/admin/stock_transfers/new.html.erb +2 -2
  145. data/app/views/spree/admin/tax_categories/_form.html.erb +9 -2
  146. data/app/views/spree/admin/tax_categories/index.html.erb +4 -1
  147. data/app/views/spree/admin/taxons/index.html.erb +4 -0
  148. data/app/views/spree/admin/trackers/_form.html.erb +4 -4
  149. data/app/views/spree/admin/users/_form.html.erb +1 -1
  150. data/app/views/spree/admin/users/index.html.erb +1 -1
  151. data/app/views/spree/admin/variants/_autocomplete_line_items_stock.js.erb +49 -0
  152. data/app/views/spree/admin/variants/_autocomplete_stock.js.erb +0 -1
  153. data/app/views/spree/admin/variants/_split.js.erb +1 -1
  154. data/app/views/spree/admin/zones/_form.html.erb +1 -1
  155. data/config/initializers/assets.rb +1 -1
  156. data/config/routes.rb +22 -1
  157. metadata +62 -32
  158. data/app/controllers/spree/admin/inventory_units_controller.rb +0 -6
  159. data/app/controllers/spree/admin/line_items_controller.rb +0 -49
  160. data/app/controllers/spree/admin/overview_controller.rb +0 -11
  161. data/app/views/spree/admin/inventory_units/adjust.html.erb +0 -31
  162. data/app/views/spree/test_mailer/test_email.text.erb +0 -4
  163. data/config/locales/en.yml +0 -6
@@ -1,77 +1,95 @@
1
1
  <div data-hook="admin_stock_locations_form_fields" class="row">
2
- <div class="alpha nine columns" data-hook="stock_location_names">
3
- <div data-hook="stock_location_name">
2
+ <div class="row">
3
+ <div class="alpha twelve columns">
4
4
  <%= f.field_container :name do %>
5
5
  <%= f.label :name, Spree.t(:name) %> <span class="required">*</span><br />
6
- <%= f.text_field :name, class: 'fullwidth', required: true %>
7
- <% end %>
8
- </div>
9
- <div data-hook="stock_location_admin_name">
6
+ <%= f.text_field :name, :class => 'fullwidth' %>
7
+ <% end %><br>
10
8
  <%= f.field_container :admin_name do %>
11
9
  <%= f.label :admin_name, Spree.t(:internal_name) %>
12
- <%= f.text_field :admin_name, class: 'fullwidth', label: false %>
10
+ <%= f.text_field :admin_name, :class => 'fullwidth', :label => false %>
11
+ <% end %>
12
+ </div>
13
+ <div class="omega four columns">
14
+ <%= f.field_container :active do %>
15
+ <label for="active"><%= Spree.t(:status) %></label>
16
+ <ul>
17
+ <li>
18
+ <%= f.label :active, Spree.t(:active) %>
19
+ <%= f.check_box :active %>
20
+ </li>
21
+ <li>
22
+ <%= f.label :default, Spree.t(:default) %>
23
+ <%= f.check_box :default %>
24
+ </li>
25
+ <li>
26
+ <%= f.label :backorderable_default, Spree.t(:backorderable_default) %>
27
+ <%= f.check_box :backorderable_default %>
28
+ </li>
29
+ <li>
30
+ <%= f.label :propagate_all_variants, Spree.t(:propagate_all_variants) %>
31
+ <%= f.check_box :propagate_all_variants %>
32
+ </li>
33
+ </ul>
13
34
  <% end %>
14
35
  </div>
15
36
  </div>
16
37
 
17
- <div class="omega three columns" data-hook="stock_location_status">
18
- <%= f.field_container :active do %>
19
- <label for="active"><%= Spree.t(:status) %></label>
20
- <ul>
21
- <li class="fullwidth" data-hook="stock_location_active">
22
- <%= f.check_box :active %>
23
- <%= f.label :active, Spree.t(:active) %>
24
- </li>
25
- <li class="fullwidth" data-hook="stock_location_backorderable_default">
26
- <%= f.check_box :backorderable_default %>
27
- <%= f.label :backorderable_default, Spree.t(:backorderable_default) %>
28
- </li>
29
- <li class="fullwidth" data-hook="stock_location_propagate_all_variants">
30
- <%= f.check_box :propagate_all_variants %>
31
- <%= f.label :propagate_all_variants, Spree.t(:propagate_all_variants) %>
32
- </li>
33
- </ul>
34
- <% end %>
35
- </div>
36
-
37
- <div class="alpha six columns field" data-hook="stock_location_address1">
38
- <%= f.label :address1, Spree.t(:street_address) %>
39
- <%= f.text_field :address1, class: 'fullwidth' %>
40
- </div>
41
-
42
- <div class="omega six columns field" data-hook="stock_location_city">
43
- <%= f.label :city, Spree.t(:city) %>
44
- <%= f.text_field :city, class: 'fullwidth' %>
45
- </div>
38
+ <div class="row">
39
+ <div class="alpha four columns">
40
+ <div class="field ">
41
+ <%= f.label :address1, Spree.t(:street_address) %>
42
+ <%= f.text_field :address1, :class => 'fullwidth' %>
43
+ </div>
44
+ </div>
46
45
 
47
- <div class="alpha six columns field" data-hook="stock_location_address2">
48
- <%= f.label :address2, Spree.t(:street_address_2) %>
49
- <%= f.text_field :address2, class: 'fullwidth' %>
50
- </div>
46
+ <div class="four columns">
47
+ <div class="field ">
48
+ <%= f.label :address2, Spree.t(:street_address_2) %>
49
+ <%= f.text_field :address2, :class => 'fullwidth' %>
50
+ </div>
51
+ </div>
52
+ <div class="four columns">
53
+ <div class="field ">
54
+ <%= f.label :city, Spree.t(:city) %>
55
+ <%= f.text_field :city, :class => 'fullwidth' %>
56
+ </div>
57
+ </div>
51
58
 
52
- <div class="three columns field" data-hook="stock_location_zipcode">
53
- <%= f.label :zipcode, Spree.t(:zip) %>
54
- <%= f.text_field :zipcode, class: 'fullwidth' %>
59
+ <div class="omega four columns">
60
+ <div class="field ">
61
+ <%= f.label :zipcode, Spree.t(:zip) %>
62
+ <%= f.text_field :zipcode, :class => 'fullwidth' %>
63
+ </div>
64
+ </div>
55
65
  </div>
56
66
 
57
- <div class="omega three columns field" data-hook="stock_location_phone">
58
- <%= f.label :phone, Spree.t(:phone) %>
59
- <%= f.phone_field :phone, class: 'fullwidth' %>
60
- </div>
67
+ <div class="row">
68
+ <div class="alpha eight columns">
69
+ <div class="field ">
70
+ <%= f.label :country_id, Spree.t(:country) %>
71
+ <span id="country"><%= f.collection_select :country_id, available_countries, :id, :name, {}, {:class => 'select2 fullwidth'} %></span>
72
+ </div>
73
+ </div>
61
74
 
62
- <div class="alpha six columns field" data-hook="stock_location_country">
63
- <%= f.label :country_id, Spree.t(:country) %>
64
- <span id="country"><%= f.collection_select :country_id, available_countries, :id, :name, {}, { class: 'select2 fullwidth' } %></span>
65
- </div>
75
+ <div class="four columns">
76
+ <div class="field ">
77
+ <% if f.object.country %>
78
+ <%= f.label :state_id, Spree.t(:state) %>
79
+ <span id="state" class="region">
80
+ <%= f.text_field :state_name, :style => "display: #{f.object.country.states.empty? ? 'block' : 'none' };", :disabled => !f.object.country.states.empty?, :class => 'fullwidth state_name' %>
81
+ <%= f.collection_select :state_id, f.object.country.states.sort, :id, :name, {:include_blank => true}, {:class => 'select2 fullwidth', :style => "display: #{f.object.country.states.empty? ? 'none' : 'block' };", :disabled => f.object.country.states.empty?} %>
82
+ </span>
83
+ <% end %>
84
+ </div>
85
+ </div>
66
86
 
67
- <div class="omega six columns field" data-hook="stock_location_state">
68
- <% if f.object.country %>
69
- <%= f.label :state_id, Spree.t(:state) %>
70
- <span id="state" class="region">
71
- <%= f.text_field :state_name, style: "display: #{f.object.country.states.empty? ? 'block' : 'none' };", disabled: !f.object.country.states.empty?, class: 'fullwidth state_name' %>
72
- <%= f.collection_select :state_id, f.object.country.states.sort, :id, :name, { include_blank: true }, {class: 'select2 fullwidth', style: "display: #{f.object.country.states.empty? ? 'none' : 'block' };", disabled: f.object.country.states.empty?} %>
73
- </span>
74
- <% end %>
87
+ <div class="omega four columns">
88
+ <div class="field ">
89
+ <%= f.label :phone, Spree.t(:phone) %>
90
+ <%= f.phone_field :phone, :class => 'fullwidth' %>
91
+ </div>
92
+ </div>
75
93
  </div>
76
94
  </div>
77
95
 
@@ -69,8 +69,8 @@
69
69
  </div>
70
70
  <div class="two columns">
71
71
  <div class="field" id="stock_movement_quantity_field">
72
- <%= label_tag 'quantity', Spree.t(:quantity) %>
73
- <%= number_field_tag 'transfer_variant_quantity', 1, class: 'fullwidth', min: 0 %>
72
+ <%= label_tag :transfer_variant_quantity, Spree.t(:quantity) %>
73
+ <%= number_field_tag :transfer_variant_quantity, 1, class: 'fullwidth', min: 0 %>
74
74
  </div>
75
75
  </div>
76
76
  <div class="two columns omega">
@@ -3,7 +3,14 @@
3
3
  <%= f.field_container :name do %>
4
4
  <%= f.label :name, Spree.t(:name) %>
5
5
  <%= f.text_field :name, :class => 'fullwidth' %>
6
- <% end %>
6
+ <% end %>
7
+ </div>
8
+
9
+ <div class="two columns">
10
+ <%= f.field_container :tax_code do %>
11
+ <%= f.label :tax_code, Spree.t(:tax_code) %>
12
+ <%= f.text_field :tax_code, :class => 'fullwidth' %>
13
+ <% end %>
7
14
  </div>
8
15
 
9
16
  <div class="five columns">
@@ -21,4 +28,4 @@
21
28
  </label>
22
29
  <% end %>
23
30
  </div>
24
- </div>
31
+ </div>
@@ -15,7 +15,8 @@
15
15
  <% if @tax_categories.any? %>
16
16
  <table class="index" id='listing_tax_categories' data-hook>
17
17
  <colgroup>
18
- <col style="width: 30%" />
18
+ <col style="width: 20%" />
19
+ <col style="width: 10%" />
19
20
  <col style="width: 40%" />
20
21
  <col style="width: 15%" />
21
22
  <col style="width: 15%" />
@@ -23,6 +24,7 @@
23
24
  <thead>
24
25
  <tr data-hook="tax_header">
25
26
  <th><%= Spree.t(:name) %></th>
27
+ <th><%= Spree.t(:tax_code) %></th>
26
28
  <th><%= Spree.t(:description) %></th>
27
29
  <th><%= Spree.t(:default) %></th>
28
30
  <th class="actions"></th>
@@ -35,6 +37,7 @@
35
37
  %>
36
38
  <tr id="<%= spree_dom_id tax_category %>" data-hook="tax_row" class="<%= cycle('odd', 'even')%>">
37
39
  <td class="align-center"><%= tax_category.name %></td>
40
+ <td class="align-center"><%= tax_category.tax_code %></td>
38
41
  <td class="align-center"><%= tax_category.description %></td>
39
42
  <td class="align-center"><%= tax_category.is_default? ? Spree.t(:say_yes) : Spree.t(:say_no) %></td>
40
43
  <td class="actions">
@@ -1,3 +1,7 @@
1
+ <% content_for :page_title do %>
2
+ <%= Spree.t(:taxons) %>
3
+ <% end %>
4
+
1
5
  <% content_for :table_filter_title do %>
2
6
  <%= Spree.t(:choose_a_taxon_to_sort_products_for) %>
3
7
  <% end %>
@@ -1,13 +1,13 @@
1
1
  <div data-hook="admin_tracker_form_fields" class="row">
2
2
  <div class="alpha four columns">
3
3
  <div data-hook="analytics_id" class="field">
4
- <%= label_tag nil, Spree.t(:google_analytics_id) %>
4
+ <%= label_tag :tracker_analytics_id, Spree.t(:google_analytics_id) %>
5
5
  <%= text_field :tracker, :analytics_id, :class => 'fullwidth' %>
6
6
  </div>
7
7
  </div>
8
8
  <div class="four columns">
9
9
  <div data-hook="environment" class="field">
10
- <%= label_tag nil, Spree.t(:environment) %>
10
+ <%= label_tag :tracker_environment, Spree.t(:environment) %>
11
11
  <%= collection_select(:tracker, :environment, rails_environments, :to_s, :titleize, {}, {:id => 'tracker-env', :class => 'select2 fullwidth'}) %>
12
12
  </div>
13
13
  </div>
@@ -17,11 +17,11 @@
17
17
  <ul>
18
18
  <li>
19
19
  <%= radio_button(:tracker, :active, true) %>
20
- <%= Spree.t(:say_yes) %>
20
+ <%= label_tag :tracker_active_true, Spree.t(:say_yes) %>
21
21
  </li>
22
22
  <li>
23
23
  <%= radio_button(:tracker, :active, false) %>
24
- <%= Spree.t(:say_no) %>
24
+ <%= label_tag :tracker_active_false, Spree.t(:say_no) %>
25
25
  </li>
26
26
  </ul>
27
27
  </div>
@@ -12,7 +12,7 @@
12
12
  <% @roles.each do |role| %>
13
13
  <li>
14
14
  <%= check_box_tag 'user[spree_role_ids][]', role.id, @user.spree_roles.include?(role), :id => "user_spree_role_#{role.name}" %>
15
- <%= label_tag role.name %>
15
+ <%= label_tag "user_spree_role_#{role.name}", role.name %>
16
16
  </li>
17
17
  <% end %>
18
18
  </ul>
@@ -42,7 +42,7 @@
42
42
  <div class="box align-center" data-hook="admin_users_index_search">
43
43
  <%= search_form_for [:admin, @search], url: admin_users_url do |f| %>
44
44
  <div class="field">
45
- <%= f.label Spree.t(:email) %> <br>
45
+ <%= f.label :email_cont, Spree.t(:email) %> <br>
46
46
  <%= f.text_field :email_cont, :class => 'fullwidth' %>
47
47
  </div>
48
48
  <div data-hook="admin_users_index_search_buttons">
@@ -0,0 +1,49 @@
1
+ <script type='text/template' id='variant_line_items_autocomplete_stock_template'>
2
+ <fieldset>
3
+ <legend align="center"><%= Spree.t(:select_stock) %></legend>
4
+ <table class="stock-levels" data-hook="stock-levels">
5
+ <colgroup>
6
+ <col style="width: 30%;" />
7
+ <col style="width: 40%;" />
8
+ <col style="width: 30%;" />
9
+ </colgroup>
10
+ <thead>
11
+ <th><%= Spree.t(:name) %></th>
12
+ <th><%= Spree.t(:count_on_hand) %></th>
13
+ <th><%= Spree.t(:quantity) %></th>
14
+ <th class="actions"></th>
15
+ </thead>
16
+ <tbody>
17
+ <tr>
18
+ <td>{{variant.name}}</td>
19
+ {{#unless variant.track_inventory}}
20
+ <td>
21
+ It doesnt track inventory
22
+ </td>
23
+ <td>
24
+ <input class="quantity" id="variant_quantity" data-variant-id="{{variant.id}}" type="number" min="1" value="1">
25
+ </td>
26
+ <td class="actions">
27
+ <button class="add_variant no-text fa fa-plus icon_link with-tip" data-variant-id="{{this.variant_id}}" title="<%= Spree.t(:add) %>" data-action="add"></button>
28
+ </td>
29
+ {{else}}
30
+ {{#if variant.total_on_hand}}
31
+ <td>
32
+ {{variant.total_on_hand}}
33
+ </td>
34
+ <td>
35
+ <input class="quantity" id="variant_quantity" data-variant-id="{{variant.id}}" type="number" min="1" value="1">
36
+ </td>
37
+ <td class="actions">
38
+ <button class="add_variant no-text fa fa-plus icon_link with-tip" data-variant-id="{{variant.id}}" title="<%= Spree.t(:add) %>" data-action="add"></button>
39
+ </td>
40
+ {{else}}
41
+ <td><%= Spree.t(:out_of_stock) %></td>
42
+ <td>0</td>
43
+ {{/if}}
44
+ {{/unless}}
45
+ </tr>
46
+ </tbody>
47
+ </table>
48
+ </fieldset>
49
+ </script>
@@ -18,7 +18,6 @@
18
18
  {{#each variant.stock_items}}
19
19
  <tr>
20
20
  <td>{{this.stock_location_name}}</td>
21
-
22
21
  {{#unless ../variant.track_inventory}}
23
22
  <td>
24
23
  It doesn't track inventory
@@ -13,7 +13,7 @@
13
13
  </optgroup>
14
14
  <optgroup label="<%=Spree.t('new_shipment_at_location')%>">
15
15
  {{#each variant.stock_items}}
16
- <option data-new-shipment='true' value='{{this.stock_location_id}}'>{{this.stock_location_name}}</option>
16
+ <option data-new-shipment='true' value='{{this.stock_location_id}}'>{{this.stock_location_name}}&nbsp({{this.count_on_hand}} on hand)</option>
17
17
  {{/each}}
18
18
  </optgroup>
19
19
  </select>
@@ -14,7 +14,7 @@
14
14
 
15
15
  <div data-hook="default" class="field">
16
16
  <%= zone_form.check_box :default_tax %>
17
- <%= label_tag Spree.t(:default_tax_zone) %>
17
+ <%= label_tag :zone_default_tax, Spree.t(:default_tax_zone) %>
18
18
  </div>
19
19
 
20
20
  <div data-hook="type" class="field">
@@ -1 +1 @@
1
- Rails.application.config.assets.precompile += %w( jquery-ui/* logo/spree_50.png )
1
+ Rails.application.config.assets.precompile += %w( jquery-ui/* )
data/config/routes.rb CHANGED
@@ -7,6 +7,8 @@ Spree::Core::Engine.add_routes do
7
7
  resources :promotion_actions
8
8
  end
9
9
 
10
+ resources :promotion_categories, :except => [:show]
11
+
10
12
  resources :zones
11
13
 
12
14
  resources :countries do
@@ -69,6 +71,7 @@ Spree::Core::Engine.add_routes do
69
71
 
70
72
  resources :orders, :except => [:show] do
71
73
  member do
74
+ get :cart
72
75
  post :resend
73
76
  get :open_adjustments
74
77
  get :close_adjustments
@@ -78,6 +81,11 @@ Spree::Core::Engine.add_routes do
78
81
  end
79
82
 
80
83
  resource :customer, :controller => "orders/customer_details"
84
+ resources :customer_returns, only: [:index, :new, :edit, :create, :update] do
85
+ member do
86
+ put :refund
87
+ end
88
+ end
81
89
 
82
90
  resources :adjustments
83
91
  resources :line_items
@@ -92,6 +100,13 @@ Spree::Core::Engine.add_routes do
92
100
  end
93
101
 
94
102
  resources :log_entries
103
+ resources :refunds, only: [:new, :create, :edit, :update]
104
+ end
105
+
106
+ resources :reimbursements, only: [:create, :show, :edit, :update] do
107
+ member do
108
+ post :perform
109
+ end
95
110
  end
96
111
  end
97
112
 
@@ -101,9 +116,11 @@ Spree::Core::Engine.add_routes do
101
116
  end
102
117
  end
103
118
 
119
+ resources :return_items, only: [:update]
120
+
104
121
  resources :taxonomies do
105
122
  collection do
106
- post :update_positions
123
+ post :update_positions
107
124
  end
108
125
  member do
109
126
  get :get_children
@@ -124,6 +141,10 @@ Spree::Core::Engine.add_routes do
124
141
  end
125
142
  end
126
143
 
144
+ resources :reimbursement_types, :only => [:index]
145
+ resources :refund_reasons, :except => [:show, :destroy]
146
+ resources :return_authorization_reasons, :except => [:show, :destroy]
147
+
127
148
  resources :shipping_methods
128
149
  resources :shipping_categories
129
150
  resources :stock_transfers, :only => [:index, :show, :new, :create]