solidus_backend 2.3.1 → 2.4.0.beta1

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of solidus_backend might be problematic. Click here for more details.

Files changed (270) hide show
  1. checksums.yaml +4 -4
  2. data/app/assets/javascripts/spree/backend/admin.js +0 -12
  3. data/app/assets/javascripts/spree/backend/number_field_updater.coffee +5 -5
  4. data/app/assets/javascripts/spree/backend/shipments.js +16 -14
  5. data/app/assets/javascripts/spree/backend/stock_transfers/count_update_forms.coffee +3 -3
  6. data/app/assets/javascripts/spree/backend/stock_transfers/transfer_item_deleting.coffee +1 -1
  7. data/app/assets/javascripts/spree/backend/taxonomy.js.coffee +1 -1
  8. data/app/assets/javascripts/spree/backend/templates/orders/details_adjustment_row.hbs +2 -2
  9. data/app/assets/javascripts/spree/backend/templates/orders/line_item.hbs +3 -3
  10. data/app/assets/javascripts/spree/backend/templates/stock_items/stock_location_stock_item.hbs +5 -5
  11. data/app/assets/javascripts/spree/backend/templates/stock_transfers/transfer_item.hbs +5 -5
  12. data/app/assets/javascripts/spree/backend/templates/taxons/_tree.hbs +7 -3
  13. data/app/assets/javascripts/spree/backend/templates/variants/line_items_autocomplete_stock.hbs +1 -1
  14. data/app/assets/javascripts/spree/backend/templates/variants/split.hbs +2 -2
  15. data/app/assets/javascripts/spree/backend/views/order/customer_details.js +1 -2
  16. data/app/assets/javascripts/spree/backend.js +1 -1
  17. data/app/assets/stylesheets/spree/backend/_bootstrap_custom.scss +27 -906
  18. data/app/assets/stylesheets/spree/backend/components/_actions.scss +13 -15
  19. data/app/assets/stylesheets/spree/backend/components/_date-picker.scss +1 -1
  20. data/app/assets/stylesheets/spree/backend/components/_editable_table.scss +0 -1
  21. data/app/assets/stylesheets/spree/backend/components/_messages.scss +8 -8
  22. data/app/assets/stylesheets/spree/backend/components/_navigation.scss +1 -1
  23. data/app/assets/stylesheets/spree/backend/components/_number_field_update.scss +1 -1
  24. data/app/assets/stylesheets/spree/backend/components/_number_with_currency.scss +1 -1
  25. data/app/assets/stylesheets/spree/backend/components/_pills.scss +92 -0
  26. data/app/assets/stylesheets/spree/backend/components/_sidebar.scss +7 -32
  27. data/app/assets/stylesheets/spree/backend/components/_states.scss +5 -27
  28. data/app/assets/stylesheets/spree/backend/components/_stock_table.scss +0 -12
  29. data/app/assets/stylesheets/spree/backend/globals/_variables.scss +58 -139
  30. data/app/assets/stylesheets/spree/backend/plugins/_bootstrap_tooltip.scss +11 -15
  31. data/app/assets/stylesheets/spree/backend/plugins/_select2.scss +7 -5
  32. data/app/assets/stylesheets/spree/backend/sections/_orders.scss +6 -6
  33. data/app/assets/stylesheets/spree/backend/sections/_products.scss +5 -1
  34. data/app/assets/stylesheets/spree/backend/sections/_promotions.scss +4 -2
  35. data/app/assets/stylesheets/spree/backend/sections/_stock_management.scss +4 -35
  36. data/app/assets/stylesheets/spree/backend/sections/_style_guide.scss +14 -15
  37. data/app/assets/stylesheets/spree/backend/sections/_taxonomies.scss +9 -16
  38. data/app/assets/stylesheets/spree/backend/shared/_forms.scss +23 -20
  39. data/app/assets/stylesheets/spree/backend/shared/_header.scss +1 -5
  40. data/app/assets/stylesheets/spree/backend/shared/_layout.scss +3 -23
  41. data/app/assets/stylesheets/spree/backend/shared/_tables.scss +40 -92
  42. data/app/assets/stylesheets/spree/backend/shared/_typography.scss +6 -6
  43. data/app/assets/stylesheets/spree/backend/spree_admin.scss +1 -1
  44. data/app/controllers/spree/admin/adjustments_controller.rb +1 -1
  45. data/app/controllers/spree/admin/customer_returns_controller.rb +0 -1
  46. data/app/controllers/spree/admin/promotion_actions_controller.rb +1 -1
  47. data/app/controllers/spree/admin/shipping_methods_controller.rb +1 -1
  48. data/app/controllers/spree/admin/style_guide_controller.rb +3 -2
  49. data/app/controllers/spree/admin/tax_rates_controller.rb +1 -1
  50. data/app/controllers/spree/admin/users_controller.rb +9 -4
  51. data/app/helpers/spree/admin/base_helper.rb +32 -35
  52. data/app/helpers/spree/admin/stock_transfers_helper.rb +0 -4
  53. data/app/models/spree/backend_configuration.rb +1 -1
  54. data/app/views/spree/admin/adjustment_reasons/index.html.erb +6 -4
  55. data/app/views/spree/admin/adjustments/_adjustment.html.erb +5 -5
  56. data/app/views/spree/admin/adjustments/_adjustments_table.html.erb +7 -7
  57. data/app/views/spree/admin/cancellations/index.html.erb +9 -5
  58. data/app/views/spree/admin/customer_returns/_reimbursements_table.html.erb +6 -3
  59. data/app/views/spree/admin/customer_returns/_return_item_decision.html.erb +12 -7
  60. data/app/views/spree/admin/customer_returns/_return_item_selection.html.erb +13 -8
  61. data/app/views/spree/admin/customer_returns/edit.html.erb +1 -1
  62. data/app/views/spree/admin/customer_returns/index.html.erb +5 -5
  63. data/app/views/spree/admin/images/_image_row.html.erb +14 -4
  64. data/app/views/spree/admin/images/index.html.erb +2 -1
  65. data/app/views/spree/admin/option_types/_option_value_fields.html.erb +6 -6
  66. data/app/views/spree/admin/option_types/edit.html.erb +2 -1
  67. data/app/views/spree/admin/option_types/index.html.erb +5 -5
  68. data/app/views/spree/admin/orders/_adjustments.html.erb +3 -3
  69. data/app/views/spree/admin/orders/_carton.html.erb +1 -1
  70. data/app/views/spree/admin/orders/_carton_manifest.html.erb +3 -3
  71. data/app/views/spree/admin/orders/_risk_analysis.html.erb +18 -16
  72. data/app/views/spree/admin/orders/_shipment.html.erb +26 -30
  73. data/app/views/spree/admin/orders/_shipment_manifest.html.erb +6 -6
  74. data/app/views/spree/admin/orders/confirm/_line_items.html.erb +3 -3
  75. data/app/views/spree/admin/orders/confirm/_payments.html.erb +6 -6
  76. data/app/views/spree/admin/orders/confirm/_shipment.html.erb +1 -1
  77. data/app/views/spree/admin/orders/confirm/_shipment_manifest.html.erb +3 -3
  78. data/app/views/spree/admin/orders/index.html.erb +25 -9
  79. data/app/views/spree/admin/payment_methods/_form.html.erb +4 -1
  80. data/app/views/spree/admin/payment_methods/index.html.erb +11 -7
  81. data/app/views/spree/admin/payments/_capture_events.html.erb +1 -1
  82. data/app/views/spree/admin/payments/_list.html.erb +9 -5
  83. data/app/views/spree/admin/payments/show.html.erb +2 -2
  84. data/app/views/spree/admin/prices/_master_variant_table.html.erb +2 -2
  85. data/app/views/spree/admin/prices/_table.html.erb +2 -2
  86. data/app/views/spree/admin/product_properties/_product_property_fields.html.erb +1 -1
  87. data/app/views/spree/admin/product_properties/index.html.erb +4 -2
  88. data/app/views/spree/admin/products/index.html.erb +10 -9
  89. data/app/views/spree/admin/promotions/actions/_create_item_adjustments.html.erb +1 -1
  90. data/app/views/spree/admin/promotions/actions/_promotion_calculators_with_custom_fields.html.erb +1 -1
  91. data/app/views/spree/admin/promotions/calculators/_default_fields.html.erb +3 -6
  92. data/app/views/spree/admin/promotions/calculators/tiered_flat_rate/_fields.html.erb +3 -8
  93. data/app/views/spree/admin/promotions/calculators/tiered_percent/_fields.html.erb +3 -8
  94. data/app/views/spree/admin/promotions/index.html.erb +24 -17
  95. data/app/views/spree/admin/promotions/rules/_user_role.html.erb +2 -2
  96. data/app/views/spree/admin/properties/index.html.erb +3 -3
  97. data/app/views/spree/admin/refund_reasons/index.html.erb +7 -5
  98. data/app/views/spree/admin/refunds/new.html.erb +1 -1
  99. data/app/views/spree/admin/reimbursement_types/index.html.erb +2 -2
  100. data/app/views/spree/admin/reimbursements/edit.html.erb +6 -6
  101. data/app/views/spree/admin/reimbursements/index.html.erb +9 -2
  102. data/app/views/spree/admin/reimbursements/show.html.erb +6 -6
  103. data/app/views/spree/admin/reports/index.html.erb +2 -2
  104. data/app/views/spree/admin/reports/sales_total.html.erb +1 -1
  105. data/app/views/spree/admin/return_authorizations/_form.html.erb +9 -5
  106. data/app/views/spree/admin/return_authorizations/edit.html.erb +9 -2
  107. data/app/views/spree/admin/return_authorizations/index.html.erb +11 -4
  108. data/app/views/spree/admin/search/products.json.jbuilder +10 -0
  109. data/app/views/spree/admin/search/users.json.jbuilder +37 -0
  110. data/app/views/spree/admin/shared/_calculator_fields.html.erb +4 -1
  111. data/app/views/spree/admin/shared/_modal.html.erb +18 -0
  112. data/app/views/spree/admin/shared/_number_field_update_actions.html.erb +2 -2
  113. data/app/views/spree/admin/shared/_number_field_update_cell.html.erb +1 -1
  114. data/app/views/spree/admin/shared/_order_summary.html.erb +21 -5
  115. data/app/views/spree/admin/shared/_refunds.html.erb +6 -6
  116. data/app/views/spree/admin/shared/_settings_sub_menu.html.erb +4 -4
  117. data/app/views/spree/admin/shared/named_types/_index.html.erb +7 -5
  118. data/app/views/spree/admin/shared/preference_fields/_boolean.html.erb +13 -0
  119. data/app/views/spree/admin/shared/preference_fields/_decimal.html.erb +12 -0
  120. data/app/views/spree/admin/shared/preference_fields/_integer.html.erb +12 -0
  121. data/app/views/spree/admin/shared/preference_fields/_password.html.erb +12 -0
  122. data/app/views/spree/admin/shared/preference_fields/_string.html.erb +12 -0
  123. data/app/views/spree/admin/shared/preference_fields/_text.html.erb +12 -0
  124. data/app/views/spree/admin/shipping_categories/index.html.erb +2 -2
  125. data/app/views/spree/admin/shipping_methods/index.html.erb +5 -5
  126. data/app/views/spree/admin/stock_items/_stock_management.html.erb +3 -3
  127. data/app/views/spree/admin/stock_locations/index.html.erb +9 -11
  128. data/app/views/spree/admin/stock_movements/index.html.erb +4 -4
  129. data/app/views/spree/admin/stock_transfers/_transfer_item_actions.html.erb +1 -1
  130. data/app/views/spree/admin/stock_transfers/_transfer_item_table.html.erb +2 -2
  131. data/app/views/spree/admin/stock_transfers/index.html.erb +10 -6
  132. data/app/views/spree/admin/stock_transfers/tracking_info.html.erb +1 -1
  133. data/app/views/spree/admin/store_credits/index.html.erb +53 -50
  134. data/app/views/spree/admin/store_credits/show.html.erb +5 -5
  135. data/app/views/spree/admin/stores/_form.html.erb +9 -0
  136. data/app/views/spree/admin/style_guide/topics/components/_modals.html.erb +50 -0
  137. data/app/views/spree/admin/style_guide/topics/components/_pills.html.erb +101 -0
  138. data/app/views/spree/admin/style_guide/topics/tables/_building_tables.html.erb +4 -4
  139. data/app/views/spree/admin/tax_categories/index.html.erb +5 -5
  140. data/app/views/spree/admin/tax_rates/index.html.erb +9 -9
  141. data/app/views/spree/admin/taxonomies/_list.html.erb +4 -4
  142. data/app/views/spree/admin/taxons/search.json.jbuilder +5 -0
  143. data/app/views/spree/admin/users/index.html.erb +64 -23
  144. data/app/views/spree/admin/users/items.html.erb +9 -13
  145. data/app/views/spree/admin/users/orders.html.erb +28 -12
  146. data/app/views/spree/admin/variants/_table.html.erb +6 -5
  147. data/app/views/spree/admin/variants/index.html.erb +12 -16
  148. data/app/views/spree/admin/variants/new.html.erb +1 -3
  149. data/app/views/spree/admin/zones/edit.html.erb +0 -3
  150. data/app/views/spree/admin/zones/index.html.erb +2 -6
  151. data/app/views/spree/admin/zones/new.html.erb +0 -3
  152. data/app/views/spree/layouts/admin.html.erb +9 -30
  153. data/config/routes.rb +0 -4
  154. data/lib/spree/backend.rb +2 -1
  155. data/solidus_backend.gemspec +3 -1
  156. data/spec/controllers/spree/admin/orders_controller_spec.rb +0 -5
  157. data/spec/controllers/spree/admin/payments_controller_spec.rb +1 -1
  158. data/spec/controllers/spree/admin/search_controller_spec.rb +2 -2
  159. data/spec/features/admin/configuration/payment_methods_spec.rb +1 -1
  160. data/spec/features/admin/configuration/zones_spec.rb +1 -1
  161. data/spec/features/admin/orders/adjustments_spec.rb +1 -1
  162. data/spec/features/admin/orders/cancelling_and_resuming_spec.rb +4 -4
  163. data/spec/features/admin/orders/cancelling_inventory_spec.rb +1 -1
  164. data/spec/features/admin/orders/customer_details_spec.rb +8 -1
  165. data/spec/features/admin/orders/listing_spec.rb +1 -1
  166. data/spec/features/admin/orders/new_order_spec.rb +3 -3
  167. data/spec/features/admin/orders/order_details_spec.rb +17 -16
  168. data/spec/features/admin/orders/payments_spec.rb +4 -4
  169. data/spec/features/admin/orders/risk_analysis_spec.rb +2 -2
  170. data/spec/features/admin/orders/shipments_spec.rb +1 -1
  171. data/spec/features/admin/products/edit/images_spec.rb +1 -1
  172. data/spec/features/admin/store_credits_spec.rb +3 -3
  173. data/spec/features/admin/stores_spec.rb +35 -0
  174. data/spec/features/admin/users_spec.rb +60 -13
  175. data/spec/spec_helper.rb +9 -4
  176. data/vendor/assets/javascripts/solidus_admin/bootstrap.js +657 -361
  177. data/vendor/assets/javascripts/solidus_admin/popover.js +4 -0
  178. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_alert.scss +4 -11
  179. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_badge.scss +4 -33
  180. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_breadcrumb.scss +1 -1
  181. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_button-group.scss +11 -15
  182. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_buttons.scss +13 -42
  183. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_card.scss +27 -80
  184. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_carousel.scss +24 -17
  185. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_close.scss +0 -2
  186. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_custom-forms.scss +27 -36
  187. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_dropdown.scss +15 -48
  188. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_forms.scss +70 -68
  189. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_functions.scss +90 -0
  190. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_grid.scss +3 -2
  191. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_images.scss +1 -1
  192. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_input-group.scss +6 -8
  193. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_jumbotron.scss +0 -4
  194. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_list-group.scss +9 -36
  195. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_media.scss +0 -4
  196. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_mixins.scss +2 -18
  197. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_modal.scss +3 -3
  198. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_nav.scss +15 -16
  199. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_navbar.scss +70 -54
  200. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_pagination.scss +3 -4
  201. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_popover.scss +96 -72
  202. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_print.scss +1 -9
  203. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_progress.scss +4 -4
  204. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_reboot.scss +187 -95
  205. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_tables.scss +34 -19
  206. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_tooltip.scss +52 -35
  207. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_type.scss +8 -28
  208. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_utilities.scss +1 -0
  209. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_variables.scss +286 -410
  210. data/vendor/assets/stylesheets/solidus_admin/bootstrap/bootstrap-grid.scss +2 -8
  211. data/vendor/assets/stylesheets/solidus_admin/bootstrap/bootstrap-reboot.scss +1 -2
  212. data/vendor/assets/stylesheets/solidus_admin/bootstrap/bootstrap.scss +2 -15
  213. data/vendor/assets/stylesheets/solidus_admin/bootstrap/mixins/_alert.scss +4 -5
  214. data/vendor/assets/stylesheets/solidus_admin/bootstrap/mixins/_badge.scss +6 -5
  215. data/vendor/assets/stylesheets/solidus_admin/bootstrap/mixins/_border-radius.scss +3 -3
  216. data/vendor/assets/stylesheets/solidus_admin/bootstrap/mixins/_box-shadow.scss +5 -0
  217. data/vendor/assets/stylesheets/solidus_admin/bootstrap/mixins/_breakpoints.scss +23 -13
  218. data/vendor/assets/stylesheets/solidus_admin/bootstrap/mixins/_buttons.scss +11 -14
  219. data/vendor/assets/stylesheets/solidus_admin/bootstrap/mixins/_clearfix.scss +1 -1
  220. data/vendor/assets/stylesheets/solidus_admin/bootstrap/mixins/_forms.scss +57 -55
  221. data/vendor/assets/stylesheets/solidus_admin/bootstrap/mixins/_gradients.scss +1 -1
  222. data/vendor/assets/stylesheets/solidus_admin/bootstrap/mixins/_grid-framework.scss +9 -18
  223. data/vendor/assets/stylesheets/solidus_admin/bootstrap/mixins/_grid.scss +12 -65
  224. data/vendor/assets/stylesheets/solidus_admin/bootstrap/mixins/_hover.scss +6 -6
  225. data/vendor/assets/stylesheets/solidus_admin/bootstrap/mixins/_list-group.scss +2 -4
  226. data/vendor/assets/stylesheets/solidus_admin/bootstrap/mixins/_nav-divider.scss +3 -3
  227. data/vendor/assets/stylesheets/solidus_admin/bootstrap/mixins/_pagination.scss +1 -0
  228. data/vendor/assets/stylesheets/solidus_admin/bootstrap/mixins/_reset-text.scss +4 -3
  229. data/vendor/assets/stylesheets/solidus_admin/bootstrap/mixins/_resize.scss +1 -1
  230. data/vendor/assets/stylesheets/solidus_admin/bootstrap/mixins/_screen-reader.scss +5 -2
  231. data/vendor/assets/stylesheets/solidus_admin/bootstrap/mixins/_text-truncate.scss +1 -1
  232. data/vendor/assets/stylesheets/solidus_admin/bootstrap/mixins/_transition.scss +9 -0
  233. data/vendor/assets/stylesheets/solidus_admin/bootstrap/mixins/_visibility.scss +2 -2
  234. data/vendor/assets/stylesheets/solidus_admin/bootstrap/utilities/_background.scss +4 -17
  235. data/vendor/assets/stylesheets/solidus_admin/bootstrap/utilities/_borders.scss +20 -5
  236. data/vendor/assets/stylesheets/solidus_admin/bootstrap/utilities/_display.scss +36 -1
  237. data/vendor/assets/stylesheets/solidus_admin/bootstrap/{_responsive-embed.scss → utilities/_embed.scss} +0 -0
  238. data/vendor/assets/stylesheets/solidus_admin/bootstrap/utilities/_flex.scss +0 -4
  239. data/vendor/assets/stylesheets/solidus_admin/bootstrap/utilities/_position.scss +5 -3
  240. data/vendor/assets/stylesheets/solidus_admin/bootstrap/utilities/_spacing.scss +10 -12
  241. data/vendor/assets/stylesheets/solidus_admin/bootstrap/utilities/_text.scss +5 -17
  242. data/vendor/assets/stylesheets/solidus_admin/bootstrap/utilities/_visibility.scss +4 -48
  243. metadata +73 -34
  244. data/app/assets/stylesheets/spree/backend/shared/_skeleton.scss +0 -242
  245. data/app/controllers/spree/admin/countries_controller.rb +0 -9
  246. data/app/controllers/spree/admin/states_controller.rb +0 -29
  247. data/app/helpers/spree/admin/reimbursements_helper.rb +0 -14
  248. data/app/views/spree/admin/countries/_form.html.erb +0 -22
  249. data/app/views/spree/admin/countries/edit.html.erb +0 -19
  250. data/app/views/spree/admin/countries/index.html.erb +0 -49
  251. data/app/views/spree/admin/countries/new.html.erb +0 -18
  252. data/app/views/spree/admin/search/products.rabl +0 -9
  253. data/app/views/spree/admin/search/users.rabl +0 -30
  254. data/app/views/spree/admin/shared/_areas_tabs.html.erb +0 -19
  255. data/app/views/spree/admin/states/_form.html.erb +0 -14
  256. data/app/views/spree/admin/states/_state_list.html.erb +0 -33
  257. data/app/views/spree/admin/states/edit.html.erb +0 -19
  258. data/app/views/spree/admin/states/index.html.erb +0 -39
  259. data/app/views/spree/admin/states/new.html.erb +0 -17
  260. data/app/views/spree/admin/style_guide/topics/typography/_tags.html.erb +0 -25
  261. data/app/views/spree/admin/taxons/search.rabl +0 -5
  262. data/app/views/spree/admin/variants/new.js.erb +0 -1
  263. data/spec/features/admin/configuration/countries_spec.rb +0 -22
  264. data/spec/features/admin/configuration/states_spec.rb +0 -64
  265. data/spec/helpers/admin/reimbursements_helper_spec.rb +0 -34
  266. data/vendor/assets/javascripts/solidus_admin/tether.js +0 -1726
  267. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_custom.scss +0 -4
  268. data/vendor/assets/stylesheets/solidus_admin/bootstrap/_normalize.scss +0 -461
  269. data/vendor/assets/stylesheets/solidus_admin/bootstrap/mixins/_cards.scss +0 -47
  270. data/vendor/assets/stylesheets/solidus_admin/bootstrap/mixins/_transforms.scss +0 -14
@@ -0,0 +1,101 @@
1
+ <p>
2
+ Pills are useful for showing statuses as an admin can get a better idea of the
3
+ state of the object by the color alone. These are most effective in a table,
4
+ as displayed below, but can also be used in other areas of the system where
5
+ appropriate.
6
+ </p>
7
+
8
+ <%- snippet = capture do %>
9
+ <span class="pill pill-complete">Complete</span>
10
+ <span class="pill pill-active">Active</span>
11
+ <span class="pill pill-inactive">Inactive</span>
12
+ <span class="pill pill-pending">Pending</span>
13
+ <span class="pill pill-warning">Warning</span>
14
+ <span class="pill pill-error">Error</span>
15
+ <%- end %>
16
+
17
+ <div class="style-guide-result half">
18
+ <%= snippet %>
19
+ </div>
20
+
21
+ <div class="style-guide-code half">
22
+ <pre><code class="language-html"><%= escape_once snippet %></code></pre>
23
+ </div>
24
+
25
+ <div class="style-guide-result">
26
+ <h3>Orders</h3>
27
+
28
+ <table>
29
+ <thead>
30
+ <th>Date</th>
31
+ <th>Number</th>
32
+ <th>Payments</th>
33
+ <th>Shipments</th>
34
+ <th>Customer</th>
35
+ <th>Total</th>
36
+ </thead>
37
+ <tbody>
38
+ <tr>
39
+ <td>July 18, 2017</td>
40
+ <td>R1234</td>
41
+ <td><span class="pill pill-complete">Paid</span></td>
42
+ <td><span class="pill pill-complete">Shipped</span></td>
43
+ <td><a href="#">lauren@example.com</a></td>
44
+ <td>$75.00</td>
45
+ </tr>
46
+ <tr>
47
+ <td>July 17, 2017</td>
48
+ <td>R1234</td>
49
+ <td><span class="pill pill-pending">Balance Due</span></td>
50
+ <td><span class="pill pill-pending">Pending</span></td>
51
+ <td><a href="#">jessicajones@example.com</a></td>
52
+ <td>$105.00</td>
53
+ </tr>
54
+ <tr>
55
+ <td>July 15, 2017</td>
56
+ <td>R1234</td>
57
+ <td><span class="pill pill-warning">Credit Owed</span></td>
58
+ <td><span class="pill pill-pending">Ready</span></td>
59
+ <td><a href="#">john@example.com</a></td>
60
+ <td>$34.00</td>
61
+ </tr>
62
+ </tbody>
63
+ </table>
64
+ </div>
65
+
66
+ <div class="style-guide-result">
67
+ <h3>Promotions</h3>
68
+
69
+ <table>
70
+ <thead>
71
+ <th>Code</th>
72
+ <th>Status</th>
73
+ <th>Used</th>
74
+ <th>Start</th>
75
+ <th>End</th>
76
+ </thead>
77
+ <tbody>
78
+ <tr>
79
+ <td>FALL2017</td>
80
+ <td><span class="pill pill-inactive">Inactive</span></td>
81
+ <td>0</td>
82
+ <td>September 1, 2017</td>
83
+ <td>–</td>
84
+ </tr>
85
+ <tr>
86
+ <td>SAVE_20</td>
87
+ <td><span class="pill pill-active">Active</span></td>
88
+ <td>651</td>
89
+ <td>June 20, 2016</td>
90
+ <td>–</td>
91
+ </tr>
92
+ <tr>
93
+ <td>NEWSLETTER</td>
94
+ <td><span class="pill pill-inactive">Expired</span></td>
95
+ <td>358</td>
96
+ <td>January 1, 2016</td>
97
+ <td>March 30, 2016</td>
98
+ </tr>
99
+ </tbody>
100
+ </table>
101
+ </div>
@@ -28,13 +28,13 @@
28
28
  Quod si ita se habeat, non possit beatam praestare vitam sapientia.
29
29
  Etenim nec iustitia nec amicitia esse omnino poterunt, nisi ipsae per se expetuntur.
30
30
  </td>
31
- <td class="align-center">$22.99</td>
32
- <td class="align-center no-wrap">1 x on hand</td>
33
- <td class="align-center">$22.99</td>
31
+ <td>$22.99</td>
32
+ <td class="no-wrap">1 x on hand</td>
33
+ <td>$22.99</td>
34
34
  </tr>
35
35
  <tr>
36
36
  <td colspan="5">UPS Ground (USD)</td>
37
- <td class="align-center">
37
+ <td>
38
38
  <span>$5.00</span>
39
39
  </td>
40
40
  </tr>
@@ -38,11 +38,11 @@
38
38
  @edit_url = edit_admin_tax_category_path(tax_category)
39
39
  @delete_url = admin_tax_category_path(tax_category)
40
40
  %>
41
- <tr id="<%= spree_dom_id tax_category %>" data-hook="tax_row" class="<%= cycle('odd', 'even')%>">
42
- <td class="align-center"><%= tax_category.name %></td>
43
- <td class="align-center"><%= tax_category.tax_code %></td>
44
- <td class="align-center"><%= tax_category.description %></td>
45
- <td class="align-center"><%= tax_category.is_default? ? Spree.t(:say_yes) : Spree.t(:say_no) %></td>
41
+ <tr id="<%= spree_dom_id tax_category %>" data-hook="tax_row">
42
+ <td><%= tax_category.name %></td>
43
+ <td><%= tax_category.tax_code %></td>
44
+ <td><%= tax_category.description %></td>
45
+ <td><%= tax_category.is_default? ? Spree.t(:say_yes) : Spree.t(:say_no) %></td>
46
46
  <td class="actions">
47
47
  <% if can?(:update, tax_category) %>
48
48
  <%= link_to_edit tax_category, no_text: true %>
@@ -41,21 +41,21 @@
41
41
  </thead>
42
42
  <tbody>
43
43
  <% @tax_rates.each do |tax_rate|%>
44
- <tr id="<%= spree_dom_id tax_rate %>" data-hook="rate_row" class="<%= cycle('odd', 'even')%>">
45
- <td class="align-center"><%=tax_rate.zone.try(:name) || Spree.t(:not_available) %></td>
46
- <td class="align-center"><%=tax_rate.name %></td>
47
- <td class="align-center">
44
+ <tr id="<%= spree_dom_id tax_rate %>" data-hook="rate_row">
45
+ <td><%=tax_rate.zone.try(:name) || Spree.t(:not_available) %></td>
46
+ <td><%=tax_rate.name %></td>
47
+ <td>
48
48
  <% if tax_rate.tax_categories.any? %>
49
49
  <%= tax_rate.tax_categories.map(&:name).join(", ") %>
50
50
  <% else %>
51
51
  <%= Spree.t(:not_available) %>
52
52
  <% end %>
53
53
  </td>
54
- <td class="align-center"><%=tax_rate.amount %></td>
55
- <td class="align-center"><%=tax_rate.included_in_price? ? Spree.t(:say_yes) : Spree.t(:say_no) %></td>
56
- <td class="align-center"><%=tax_rate.show_rate_in_label? ? Spree.t(:say_yes) : Spree.t(:say_no) %></td>
57
- <td class="align-center"><%=tax_rate.expires_at.to_date.to_s(:short_date) if tax_rate.expires_at %></td>
58
- <td class="align-center"><%=tax_rate.calculator.to_s %></td>
54
+ <td><%=tax_rate.amount %></td>
55
+ <td><%=tax_rate.included_in_price? ? Spree.t(:say_yes) : Spree.t(:say_no) %></td>
56
+ <td><%=tax_rate.show_rate_in_label? ? Spree.t(:say_yes) : Spree.t(:say_no) %></td>
57
+ <td><%=tax_rate.expires_at.to_date.to_s(:short_date) if tax_rate.expires_at %></td>
58
+ <td><%=tax_rate.calculator.to_s %></td>
59
59
  <td class="actions">
60
60
  <% if can?(:update, tax_rate) %>
61
61
  <%= link_to_edit tax_rate, no_text: true %>
@@ -6,20 +6,20 @@
6
6
  </colgroup>
7
7
  <thead>
8
8
  <tr data-hook="taxonomies_header">
9
- <th class="no-border"></th>
9
+ <th></th>
10
10
  <th><%= Spree::Taxonomy.human_attribute_name(:name) %></th>
11
11
  <th class="actions"></th>
12
12
  </tr>
13
13
  </thead>
14
14
  <tbody>
15
15
  <% @taxonomies.each do |taxonomy| %>
16
- <tr id="<%= spree_dom_id taxonomy %>" data-hook="taxonomies_row" class="<%= cycle('odd', 'even')%>">
17
- <td class="no-border">
16
+ <tr id="<%= spree_dom_id taxonomy %>" data-hook="taxonomies_row">
17
+ <td>
18
18
  <% if can?(:update_positions, Spree::Taxonomy) %>
19
19
  <span class="handle"></span>
20
20
  <% end %>
21
21
  </td>
22
- <td class="align-center"><%= taxonomy.name %></td>
22
+ <td><%= taxonomy.name %></td>
23
23
  <td class="actions">
24
24
  <% if can?(:update, taxonomy) %>
25
25
  <%= link_to_edit taxonomy, no_text: true %>
@@ -0,0 +1,5 @@
1
+ json.taxons(@taxons) do |taxon|
2
+ json.id taxon.id
3
+ json.name taxon.name
4
+ json.pretty_name taxon.pretty_name
5
+ end
@@ -1,6 +1,5 @@
1
1
  <% admin_breadcrumb(plural_resource_name(Spree::LegacyUser)) %>
2
2
 
3
-
4
3
  <% content_for :page_actions do %>
5
4
  <% if can?(:admin, Spree.user_class) && can?(:create, Spree.user_class) %>
6
5
  <li>
@@ -9,21 +8,81 @@
9
8
  <% end %>
10
9
  <% end %>
11
10
 
11
+ <% content_for :table_filter_title do %>
12
+ <%= Spree.t(:search) %>
13
+ <% end %>
14
+
15
+ <% content_for :table_filter do %>
16
+ <div data-hook="admin_users_index_search">
17
+ <%= search_form_for [:admin, @search], url: admin_users_url do |f| %>
18
+ <div class="row">
19
+ <div class="col-xs-12 col-md-5">
20
+ <div class="form-group">
21
+ <%= f.label :email_cont, Spree.t(:email) %>
22
+ <%= f.text_field :email_cont, class: "form-control" %>
23
+ </div>
24
+ </div>
25
+ <div class="col-xs-12 col-md-3">
26
+ <div class="form-group">
27
+ <%= f.label :spree_roles_id_in, Spree.user_class.human_attribute_name(:spree_roles) %>
28
+ <%= f.collection_select :spree_roles_id_in, @roles, :id, :name, {},
29
+ multiple: true, class: 'select2 fullwidth' %>
30
+ </div>
31
+ </div>
32
+ <div class="col-xs-12 col-md-4">
33
+ <div class="date-range-filter form-group">
34
+ <%= label_tag :q_created_at_gt, Spree.t(:member_since) %>
35
+ <div class="date-range-fields input-group">
36
+ <%= f.text_field :created_at_gt, class: 'datepicker form-control datepicker-from',
37
+ value: params[:q].try!("[]", :created_at_gt), placeholder: Spree.t(:start) %>
38
+
39
+ <span class="range-divider input-group-addon">
40
+ <i class="fa fa-arrow-right"></i>
41
+ </span>
42
+
43
+ <%= f.text_field :created_at_lt, class: 'datepicker form-control datepicker-to',
44
+ value: params[:q].try!("[]", :created_at_lt), placeholder: Spree.t(:stop) %>
45
+ </div>
46
+ </div>
47
+ </div>
48
+ </div>
49
+
50
+ <div class="actions filter-actions" data-hook="admin_users_index_search_buttons">
51
+ <%= button Spree.t(:search) %>
52
+ </div>
53
+ <% end %>
54
+ </div>
55
+ <% end %>
56
+
57
+ <%= paginate @users, theme: "solidus_admin" %>
58
+
12
59
  <table class="index" id="listing_users" data-hook>
13
60
  <colgroup>
14
- <col style="width: 85%">
15
- <col style="width: 15%">
61
+ <col style="width: 40%">
62
+ <col style="width: 20%">
63
+ <col style="width: 10%">
64
+ <col style="width: 10%">
65
+ <col style="width: 10%">
66
+ <col style="width: 10%">
16
67
  </colgroup>
17
68
  <thead>
18
69
  <tr data-hook="admin_users_index_headers">
19
- <th><%= sort_link @search,:email, Spree::LegacyUser.model_name.human, {}, {title: 'users_email_title'} %></th>
70
+ <th><%= sort_link @search, :email, Spree.user_class.human_attribute_name(:email), {}, {title: 'users_email_title'} %></th>
71
+ <th><%= Spree.user_class.human_attribute_name(:spree_roles) %></th>
72
+ <th class="align-center"><%= Spree.t(:num_orders) %></th>
73
+ <th class="align-center"><%= Spree.user_class.human_attribute_name(:lifetime_value) %></th>
74
+ <th class="align-center"><%= sort_link @search, :created_at, Spree.t(:member_since) %></th>
20
75
  <th data-hook="admin_users_index_header_actions" class="actions"></th>
21
76
  </tr>
22
77
  </thead>
23
78
  <tbody>
24
79
  <% @users.each do |user|%>
25
- <tr id="<%= spree_dom_id user %>" data-hook="admin_users_index_rows" class="<%= cycle('odd', 'even')%>">
80
+ <tr id="<%= spree_dom_id user %>" data-hook="admin_users_index_rows">
26
81
  <td class='user_email'><%=link_to user.email, edit_admin_user_url(user) %></td>
82
+ <td><%= user.spree_roles.map(&:name).to_sentence %></td>
83
+ <td class="align-center"><%= link_to user.orders.count, spree.orders_admin_user_path(user) %></td>
84
+ <td class="align-center"><%= link_to user.display_lifetime_value, spree.items_admin_user_path(user) %></td>
85
+ <td class="align-center"><%= l user.created_at.to_date %></td>
27
86
  <td data-hook="admin_users_index_row_actions" class="actions">
28
87
  <% if can?(:edit, user) %>
29
88
  <%= link_to_edit user, no_text: true %>
@@ -38,21 +97,3 @@
38
97
  </table>
39
98
 
40
99
  <%= paginate @users, theme: "solidus_admin" %>
41
-
42
- <% content_for :sidebar_title do %>
43
- <%= Spree.t(:search) %>
44
- <% end %>
45
-
46
- <% content_for :sidebar do %>
47
- <div class="box align-center" data-hook="admin_users_index_search">
48
- <%= search_form_for [:admin, @search], url: admin_users_url do |f| %>
49
- <div class="field">
50
- <%= f.label :email_cont, Spree.t(:email) %> <br>
51
- <%= f.text_field :email_cont, class: 'fullwidth' %>
52
- </div>
53
- <div data-hook="admin_users_index_search_buttons">
54
- <%= button Spree.t(:search) %>
55
- </div>
56
- <% end %>
57
- </div>
58
- <% end %>
@@ -39,7 +39,7 @@
39
39
  <% @orders.each do |order| %>
40
40
  <% order.line_items.each do |item| %>
41
41
  <tr class="stock-item" data-item-quantity="<%= item.quantity %>">
42
- <td class="align-center order-completed-at"><%= l(order.completed_at.to_date) if order.completed_at %></td>
42
+ <td class="order-completed-at"><%= l(order.completed_at.to_date) if order.completed_at %></td>
43
43
  <td class="item-image">
44
44
  <%= render 'spree/admin/shared/image', image: item.variant.display_image, size: :mini %>
45
45
  </td>
@@ -49,19 +49,15 @@
49
49
  <strong><%= Spree.t(:sku) %>:</strong> <%= item.variant.sku %>
50
50
  <% end %>
51
51
  </td>
52
- <td class="align-center item-price"><%= item.single_money.to_html %></td>
53
- <td class="align-center item-quantity"><%= item.quantity %></td>
54
- <td class="align-center item-total"><%= item.money.to_html %></td>
55
- <td class="align-center order-state">
56
- <div class="state <%= order.state.downcase %>"><%= Spree.t("order_state.#{order.state.downcase}") %></div>
57
- <% if order.payment_state %>
58
- <div class="state <%= order.payment_state %>"><%= link_to Spree.t("payment_states.#{order.payment_state}"), admin_order_payments_path(order) %></div>
59
- <% end %>
60
- <% if Spree::Order.checkout_step_names.include?(:delivery) && order.shipment_state %>
61
- <div class="state <%= order.shipment_state %>"><%= Spree.t("shipment_states.#{order.shipment_state}") %></div>
62
- <% end %>
52
+ <td class="item-price"><%= item.single_money.to_html %></td>
53
+ <td class="item-quantity"><%= item.quantity %></td>
54
+ <td class="item-total"><%= item.money.to_html %></td>
55
+ <td class="order-state">
56
+ <span class="pill pill-<%= order.state %>">
57
+ <%= Spree.t(order.state, scope: :order_state) %>
58
+ </span>
63
59
  </td>
64
- <td class="align-center order-number">
60
+ <td class="order-number">
65
61
  <% if can?([:admin, :edit], order) %>
66
62
  <%= link_to order.number, edit_admin_order_url(order) %>
67
63
  <% else %>
@@ -25,31 +25,47 @@
25
25
  <tr data-hook="admin_orders_index_headers">
26
26
  <th><%= sort_link @search, :completed_at, Spree::Order.human_attribute_name(:completed_at), {}, {title: 'orders_completed_at_title'} %></th>
27
27
  <th><%= sort_link @search, :number, Spree::Order.human_attribute_name(:number), {}, {title: 'orders_number_title'} %></th>
28
- <th><%= sort_link @search, :state, Spree::Order.human_attribute_name(:state), {}, {title: 'orders_state_title'} %></th>
28
+ <th><%= sort_link @search, :state %></th>
29
+ <th><%= sort_link @search, :payment_state %></th>
30
+ <% if Spree::Order.checkout_step_names.include?(:delivery) %>
31
+ <th><%= sort_link @search, :shipment_state %></th>
32
+ <% end %>
29
33
  <th><%= sort_link @search, :total, Spree::Order.human_attribute_name(:total), {}, {title: 'orders_total_title'} %></th>
30
34
  </tr>
31
35
  </thead>
32
36
  <tbody>
33
37
  <% @orders.each do |order| %>
34
- <tr data-hook="admin_orders_index_rows" class="state-<%= order.state.downcase %> <%= cycle('odd', 'even') %>">
35
- <td class="align-center order-completed-at"><%= l(order.completed_at.to_date) if order.completed_at %></td>
36
- <td class="align-center order-number">
38
+ <tr data-hook="admin_orders_index_rows">
39
+ <td class="order-completed-at"><%= l(order.completed_at.to_date) if order.completed_at %></td>
40
+ <td class="order-number">
37
41
  <% if can?([:admin, :edit], order) %>
38
42
  <%= link_to order.number, edit_admin_order_path(order) %>
39
43
  <% else %>
40
44
  <%= order.number %>
41
45
  <% end %>
42
46
  </td>
43
- <td class="align-center order-state">
44
- <div class="state <%= order.state.downcase %>"><%= Spree.t("order_state.#{order.state.downcase}") %></div>
45
- <% if order.payment_state %>
46
- <div class="state <%= order.payment_state %>"><%= link_to Spree.t("payment_states.#{order.payment_state}"), admin_order_payments_path(order) %></div>
47
- <% end %>
48
- <% if Spree::Order.checkout_step_names.include?(:delivery) && order.shipment_state %>
49
- <div class="state <%= order.shipment_state %>"><%= Spree.t("shipment_states.#{order.shipment_state}") %></div>
47
+ <td>
48
+ <span class="pill pill-<%= order.state %>">
49
+ <%= Spree.t(order.state, scope: :order_state) %>
50
+ </span>
51
+ </td>
52
+ <td>
53
+ <% if order.payment_state %>
54
+ <span class="pill pill-<%= order.payment_state %>">
55
+ <%= Spree.t(order.payment_state, scope: :payment_states) %>
56
+ </span>
50
57
  <% end %>
51
58
  </td>
52
- <td class="align-center order-total"><%= order.display_total.to_html %></td>
59
+ <% if Spree::Order.checkout_step_names.include?(:delivery) %>
60
+ <td>
61
+ <% if order.shipment_state %>
62
+ <span class="pill pill-<%= order.shipment_state %>">
63
+ <%= Spree.t(order.shipment_state, scope: :shipment_states) %>
64
+ </span>
65
+ <% end %>
66
+ </td>
67
+ <% end %>
68
+ <td class="order-total"><%= order.display_total.to_html %></td>
53
69
  </tr>
54
70
  <% end %>
55
71
  </tbody>
@@ -11,7 +11,8 @@
11
11
  </colgroup>
12
12
  <thead data-hook="variants_header">
13
13
  <tr>
14
- <th colspan="2"><%= Spree.t(:options) %></th>
14
+ <th></th>
15
+ <th><%= Spree.t(:options) %></th>
15
16
  <th><%= Spree::Variant.human_attribute_name(:price) %></th>
16
17
  <th><%= Spree::Variant.human_attribute_name(:sku) %></th>
17
18
  <th class="actions"></th>
@@ -19,15 +20,15 @@
19
20
  </thead>
20
21
  <tbody>
21
22
  <% variants.each do |variant| %>
22
- <tr id="<%= spree_dom_id variant %>" data-hook="variants_row" class="<%= "deleted" if variant.deleted? %> <%= cycle('odd', 'even')%>">
23
- <td class="no-border">
23
+ <tr id="<%= spree_dom_id variant %>" data-hook="variants_row" class="<%= "deleted" if variant.deleted? %>">
24
+ <td>
24
25
  <% if can? :update_positions, Spree::Variant %>
25
26
  <span class="handle"></span>
26
27
  <% end %>
27
28
  </td>
28
29
  <td><%= variant.options_text %></td>
29
- <td class="align-center"><%= variant.display_price.to_html %></td>
30
- <td class="align-center"><%= variant.sku %></td>
30
+ <td><%= variant.display_price.to_html %></td>
31
+ <td><%= variant.sku %></td>
31
32
  <td class="actions">
32
33
  <% if can?(:update, variant) %>
33
34
  <%= link_to_edit(variant, no_text: true) unless variant.deleted? %>
@@ -2,6 +2,17 @@
2
2
 
3
3
  <% admin_breadcrumb(plural_resource_name(Spree::Variant)) %>
4
4
 
5
+ <% content_for :page_actions do %>
6
+ <% if can?(:create, Spree::Variant) && !@product.empty_option_values? %>
7
+ <li id="new_var_link" data-hook>
8
+ <%= link_to(
9
+ Spree.t(:new_variant),
10
+ new_admin_product_variant_url(@product),
11
+ class: 'button'
12
+ ) %>
13
+ </li>
14
+ <% end %>
15
+ <% end %>
5
16
 
6
17
  <% if @variants.any? || @product.variants.only_deleted.any?%>
7
18
  <%= render "table_filter", product: @product %>
@@ -25,23 +36,8 @@
25
36
  <div class="col-9 no-objects-found">
26
37
  <%= Spree.t(:no_resource, resource: plural_resource_name(Spree::Variant)) %>
27
38
  <% if can? :create, Spree::Variant %>
28
- <%= link_to Spree.t(:create_one), new_object_url, remote: true %>
39
+ <%= link_to Spree.t(:create_one), new_object_url %>
29
40
  <% end %>
30
41
  </div>
31
42
  <% end %>
32
43
  <% end %>
33
-
34
- <% if !@product.empty_option_values? %>
35
- <% content_for :page_actions do %>
36
- <ul class="inline-menu" data-hook="toolbar">
37
- <% if can?(:create, Spree::Variant) %>
38
- <li id="new_var_link" data-hook>
39
- <%= link_to Spree.t(:new_variant),
40
- new_admin_product_variant_url(@product),
41
- remote: :true,
42
- class: 'button' %>
43
- </li>
44
- <% end %>
45
- </ul>
46
- <% end %>
47
- <% end %>
@@ -4,10 +4,8 @@
4
4
  <% admin_breadcrumb(link_to plural_resource_name(Spree::Variant), admin_product_variants_path(@product)) %>
5
5
  <% admin_breadcrumb(Spree.t(:new_variant)) %>
6
6
 
7
-
8
7
  <%= form_for [:admin, @product, @variant] do |f| %>
9
- <fieldset data-hook="admin_variant_new_form">
10
- <legend><%= t('.new_variant') %></legend>
8
+ <fieldset class="no-border-top" data-hook="admin_variant_new_form">
11
9
  <%= render partial: 'form', locals: { f: f } %>
12
10
  <%= render partial: 'spree/admin/shared/new_resource_links' %>
13
11
  </fieldset>
@@ -1,7 +1,4 @@
1
- <%= render 'spree/admin/shared/areas_tabs' %>
2
-
3
1
  <% admin_breadcrumb(Spree.t(:settings)) %>
4
- <% admin_breadcrumb(Spree.t('admin.tab.areas')) %>
5
2
  <% admin_breadcrumb(link_to plural_resource_name(Spree::Zone), spree.admin_zones_path) %>
6
3
  <% admin_breadcrumb(@zone.name) %>
7
4
 
@@ -1,10 +1,6 @@
1
- <%= render 'spree/admin/shared/areas_tabs' %>
2
-
3
1
  <% admin_breadcrumb(Spree.t(:settings)) %>
4
- <% admin_breadcrumb(Spree.t('admin.tab.areas')) %>
5
2
  <% admin_breadcrumb(plural_resource_name(Spree::Zone)) %>
6
3
 
7
-
8
4
  <% content_for :page_actions do %>
9
5
  <% if can?(:create, Spree::Zone) %>
10
6
  <li>
@@ -34,8 +30,8 @@
34
30
  </thead>
35
31
  <tbody>
36
32
  <% @zones.each do |zone| %>
37
- <tr id="<%= spree_dom_id zone %>" data-hook="zones_row" class="<%= cycle('odd', 'even')%>">
38
- <td class="align-center"><%= zone.name %></td>
33
+ <tr id="<%= spree_dom_id zone %>" data-hook="zones_row">
34
+ <td><%= zone.name %></td>
39
35
  <td><%= zone.description %></td>
40
36
  <td class="actions">
41
37
  <% if can?(:update, zone) %>
@@ -1,7 +1,4 @@
1
- <%= render 'spree/admin/shared/areas_tabs' %>
2
-
3
1
  <% admin_breadcrumb(Spree.t(:settings)) %>
4
- <% admin_breadcrumb(Spree.t('admin.tab.areas')) %>
5
2
  <% admin_breadcrumb(link_to plural_resource_name(Spree::Zone), spree.admin_zones_path) %>
6
3
  <% admin_breadcrumb(Spree.t(:new_zone)) %>
7
4
 
@@ -4,43 +4,22 @@
4
4
  <%= render 'spree/admin/shared/head' %>
5
5
  </head>
6
6
 
7
- <body class="admin <%= "new-layout" if @admin_layout %>">
7
+ <body class="admin">
8
8
  <%= render "spree/admin/shared/navigation" %>
9
9
  <%= render "spree/admin/shared/header" %>
10
10
  <%= render "spree/admin/shared/flash" %>
11
11
  <%= render "spree/admin/shared/spinner" %>
12
12
 
13
- <div class="content-wrapper <%= @admin_layout.presence %> <%= "has-sidebar" if content_for?(:sidebar) %>" id="wrapper" data-hook>
14
- <% if @admin_layout %>
15
- <div class="content">
16
- <div class="content-main">
17
- <%= yield :tabs %>
18
- <%= render "spree/admin/shared/table_filter" %>
19
- <%= yield %>
20
- </div>
21
-
22
- <%= render "spree/admin/shared/sidebar" %>
13
+ <div class="content-wrapper <%= @admin_layout.presence %> <%= "has-sidebar" if content_for?(:sidebar) %> <%= "has-tabs" if content_for?(:tabs) %>" id="wrapper" data-hook>
14
+ <div class="content row">
15
+ <div class="content-main col-<%= content_for?(:sidebar) ? '9' : '12' %>">
16
+ <%= yield :tabs %>
17
+ <%= render "spree/admin/shared/table_filter" %>
18
+ <%= yield %>
23
19
  </div>
24
- <% else %>
25
- <% # Legacy layout %>
26
- <div class="container">
27
- <div class="<%= 'with-sidebar ' if content_for?(:sidebar) %>" id="content" data-hook>
28
- <div class="row">
29
- <% if content_for?(:tabs) %>
30
- <div class="col-12">
31
- <%= yield :tabs %>
32
- </div>
33
- <% end %>
34
- <div class="js-content-below-tabs <%= if content_for?(:sidebar) then 'col-9' else 'col-12' end %>">
35
- <%= render partial: 'spree/admin/shared/table_filter' %>
36
- <%= yield %>
37
- </div>
38
20
 
39
- <%= render 'spree/admin/shared/sidebar' %>
40
- </div>
41
- </div>
42
- </div>
43
- <% end %>
21
+ <%= render "spree/admin/shared/sidebar" %>
22
+ </div>
44
23
  </div>
45
24
 
46
25
  <div data-hook="admin_footer_scripts"></div>
data/config/routes.rb CHANGED
@@ -22,10 +22,6 @@ Spree::Core::Engine.routes.draw do
22
22
 
23
23
  resources :zones
24
24
 
25
- resources :countries do
26
- resources :states
27
- end
28
- resources :states
29
25
  resources :tax_categories
30
26
 
31
27
  resources :products do
data/lib/spree/backend.rb CHANGED
@@ -6,11 +6,12 @@ require 'sass-rails'
6
6
  require 'bourbon'
7
7
  require 'handlebars_assets'
8
8
  require 'font-awesome-rails'
9
+ require 'autoprefixer-rails'
10
+ require 'jbuilder'
9
11
 
10
12
  require 'spree_core'
11
13
  require 'spree_api'
12
14
 
13
- require 'spree/responder'
14
15
  require 'spree/backend/action_callbacks'
15
16
  require 'spree/backend/callbacks'
16
17
  require 'spree/backend/engine'
@@ -8,7 +8,6 @@ Gem::Specification.new do |s|
8
8
  s.summary = 'Admin interface for the Solidus e-commerce framework.'
9
9
  s.description = s.summary
10
10
 
11
- s.required_ruby_version = '>= 2.1.0'
12
11
  s.author = 'Solidus Team'
13
12
  s.email = 'contact@solidus.io'
14
13
  s.homepage = 'http://solidus.io'
@@ -30,6 +29,9 @@ Gem::Specification.new do |s|
30
29
  s.add_dependency 'jquery-rails'
31
30
  s.add_dependency 'jquery-ui-rails', '~> 5.0.0'
32
31
  s.add_dependency 'font-awesome-rails', '~> 4.0'
32
+ s.add_dependency 'kaminari', '>= 0.17', '< 2.0'
33
+ s.add_dependency 'jbuilder', '~> 2.6'
33
34
 
34
35
  s.add_dependency 'handlebars_assets', '~> 0.23'
36
+ s.add_dependency 'autoprefixer-rails', '~> 7.1'
35
37
  end