spree_active_sale 1.0.6 → 1.3.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (55) hide show
  1. data/README.md +198 -56
  2. data/app/controllers/spree/admin/active_sale_events_controller.rb +52 -0
  3. data/app/controllers/spree/admin/active_sales_controller.rb +25 -0
  4. data/app/controllers/spree/admin/sale_images_controller.rb +33 -0
  5. data/app/controllers/spree/checkout_controller_decorator.rb +6 -0
  6. data/app/controllers/spree/home_controller_decorator.rb +10 -0
  7. data/app/controllers/spree/orders_controller_decorator.rb +6 -0
  8. data/app/controllers/{products_controller_decorator.rb → spree/products_controller_decorator.rb} +5 -1
  9. data/app/controllers/spree/store_controller_decorator.rb +11 -0
  10. data/app/controllers/{taxons_controller_decorator.rb → spree/taxons_controller_decorator.rb} +1 -1
  11. data/app/helpers/spree/active_sale_events_helper.rb +46 -0
  12. data/app/helpers/spree/active_sales_helper.rb +4 -0
  13. data/app/models/spree/active_sale.rb +12 -6
  14. data/app/models/spree/active_sale_configuration.rb +13 -0
  15. data/app/models/spree/active_sale_event.rb +58 -0
  16. data/app/models/spree/line_item_decorator.rb +6 -0
  17. data/app/models/spree/order_decorator.rb +6 -0
  18. data/app/models/spree/product_decorator.rb +14 -3
  19. data/app/models/spree/sale_event.rb +86 -0
  20. data/app/models/spree/sale_image.rb +51 -0
  21. data/app/models/spree/taxon_decorator.rb +11 -2
  22. data/app/models/spree/variant_decorator.rb +2 -2
  23. data/app/overrides/admin_active_sales_tab.rb +6 -0
  24. data/app/views/spree/admin/active_sale_events/_form.html.erb +136 -0
  25. data/app/views/spree/admin/active_sale_events/edit.html.erb +17 -0
  26. data/app/views/spree/admin/active_sale_events/index.html.erb +12 -0
  27. data/app/views/spree/admin/active_sale_events/new.html.erb +15 -0
  28. data/app/views/spree/admin/active_sales/_form.html.erb +35 -0
  29. data/app/views/spree/admin/active_sales/edit.html.erb +17 -0
  30. data/app/views/spree/admin/active_sales/index.html.erb +57 -0
  31. data/app/views/spree/admin/active_sales/new.html.erb +15 -0
  32. data/app/views/spree/admin/sale_images/_form.html.erb +18 -0
  33. data/app/views/spree/admin/sale_images/edit.html.erb +24 -0
  34. data/app/views/spree/admin/sale_images/new.html.erb +19 -0
  35. data/app/views/spree/admin/shared/_list_events.html.erb +32 -0
  36. data/app/views/spree/admin/shared/_sale_images.html.erb +41 -0
  37. data/app/views/spree/admin/shared/_translations.html.erb +57 -0
  38. data/app/views/spree/home/index.html.erb +4 -0
  39. data/app/views/spree/shared/_sale_events.html.erb +28 -0
  40. data/config/locales/active_sales_en.yml +74 -0
  41. data/config/locales/active_sales_es.yml +74 -0
  42. data/config/routes.rb +12 -0
  43. data/db/migrate/20130404062459_create_sale_events.rb +70 -0
  44. data/db/migrate/20130411091742_add_discount_to_sale_events.rb +5 -0
  45. data/lib/generators/spree_active_sale/assets/assets_generator.rb +37 -0
  46. data/lib/generators/spree_active_sale/templates/README.md +3 -0
  47. data/lib/spree_active_sale/engine.rb +7 -0
  48. data/lib/tasks/spree_active_sale.rake +14 -6
  49. metadata +46 -11
  50. data/app/assets/javascripts/admin/spree_active_sale.js +0 -1
  51. data/app/assets/javascripts/store/spree_active_sale.js +0 -1
  52. data/app/assets/stylesheets/admin/spree_active_sale.css +0 -3
  53. data/app/assets/stylesheets/store/spree_active_sale.css +0 -3
  54. data/app/models/spree/active_sale/event.rb +0 -57
  55. data/config/locales/en.yml +0 -12
@@ -0,0 +1,17 @@
1
+ <% content_for :page_title do %>
2
+ <%= @active_sale.name %> &#62; <%= @active_sale_event.name %> &#62; <%= t('spree.active_sale.event.title.edit') %>
3
+ <% end %>
4
+
5
+ <% content_for :page_actions do %>
6
+ <li>
7
+ <%= button_link_to t('spree.active_sale.event.link.back'), [:admin, @active_sale, :active_sale_events], :icon => 'icon-arrow-left', :id => 'admin_active_sale_events_link' %>
8
+ <%= button_link_to t('spree.active_sale.event.link.new'), new_object_url, :icon => 'icon-plus', :id => 'new_admin_active_sale_event_link' %>
9
+ <%= button_link_to t('spree.active_sale.link.edit'), [:edit, :admin, @active_sale], :icon => 'icon-edit', :id => 'admin_active_sale_events_link' %>
10
+ </li>
11
+ <% end %>
12
+
13
+ <div data-hook="admin_active_sale_event_edit_form">
14
+ <div id="active-sale-event-form-wrapper">
15
+ <%= render :partial => 'form' %>
16
+ </div>
17
+ </div>
@@ -0,0 +1,12 @@
1
+ <% content_for :page_title do %>
2
+ <%= @active_sale.name %> > <%= t('spree.active_sale.event.title.list') %>
3
+ <% end %>
4
+
5
+ <% content_for :page_actions do %>
6
+ <li>
7
+ <%= button_link_to t('spree.active_sale.link.edit'), [:admin, @active_sale], :icon => 'icon-arrow-left', :id => 'admin_active_sale_events_link' %>
8
+ <%= button_link_to t('spree.active_sale.event.link.new'), new_object_url, :icon => 'icon-plus', :id => 'admin_new_active_sale_event_link' %>
9
+ </li>
10
+ <% end %>
11
+
12
+ <%= render :partial => "spree/admin/shared/list_events", :locals => { :active_sale_events => @active_sale_events } %>
@@ -0,0 +1,15 @@
1
+ <% content_for :page_title do %>
2
+ <%= @active_sale.name %> &#62; <%= t('spree.active_sale.event.title.new') %>
3
+ <% end %>
4
+
5
+ <% content_for :page_actions do %>
6
+ <li>
7
+ <%= button_link_to t('spree.active_sale.event.link.back'), [:admin, @active_sale, @active_sale_event], :icon => 'icon-arrow-left', :id => 'admin_new_active_sale_event_link' %>
8
+ </li>
9
+ <% end %>
10
+
11
+ <div data-hook="admin_active_sale_event_edit_form">
12
+ <div id="active-sale-event-form-wrapper">
13
+ <%= render :partial => 'form' %>
14
+ </div>
15
+ </div>
@@ -0,0 +1,35 @@
1
+ <% if @active_sale.try(:errors).present? %>
2
+ <%= render :partial => 'spree/shared/error_messages', :locals => { :target => @active_sale } %>
3
+ <% end %>
4
+
5
+ <%= form_for [:admin, @active_sale] do |f| %>
6
+
7
+ <fieldset data-hook="new_active_sale">
8
+
9
+ <%= f.field_container :name do %>
10
+ <%= f.label :name, t(:name) %> <span class="required">*</span><br />
11
+ <%= f.text_field :name, :class => 'fullwidth title' %>
12
+ <%= f.error_message_on :name %>
13
+ <% end %>
14
+
15
+ <p class="form-buttons" data-hook="admin_active_sale_form_buttons">
16
+ <% if @active_sale.new_record? %>
17
+ <%= render :partial => 'spree/admin/shared/new_resource_links' %>
18
+ <% else %>
19
+ <%= render :partial => 'spree/admin/shared/edit_resource_links' %>
20
+ <% end %>
21
+ </p>
22
+
23
+ </fieldset>
24
+ <% end %>
25
+
26
+ <% unless @active_sale.new_record? %>
27
+ <% if @active_sale.active_sale_events.blank? %>
28
+ <% @active_sale_event = @active_sale.active_sale_events.build %>
29
+ <h4><%= t('spree.active_sale.event.create_if_no_record') %></h4>
30
+ <%= render :partial => "spree/admin/active_sale_events/form", :locals => { :events => @active_sale_event } %>
31
+ <% else %>
32
+ <% @active_sale_events = @active_sale.active_sale_events %>
33
+ <%= render :partial => "spree/admin/shared/list_events", :locals => { :events => @active_sale_events } %>
34
+ <% end %>
35
+ <% end %>
@@ -0,0 +1,17 @@
1
+ <% content_for :page_title do %>
2
+ <%= t('spree.active_sale.title.edit') %>
3
+ <% end %>
4
+
5
+ <% content_for :page_actions do %>
6
+ <li>
7
+ <% @event = Spree::ActiveSaleEvent.new %>
8
+ <%= button_link_to t('spree.active_sale.link.back'), collection_url, :icon => 'icon-arrow-left', :id => 'admin_new_active_sale_link' %>
9
+ <%= button_link_to t('spree.active_sale.event.link.new'), [:new, :admin, @active_sale, :active_sale_event], :icon => 'icon-plus', :id => 'admin_new_active_sale_link' %>
10
+ </li>
11
+ <% end %>
12
+
13
+ <div data-hook="admin_active_sale_edit_form">
14
+ <div id="active-sale-form-wrapper">
15
+ <%= render :partial => 'form' %>
16
+ </div>
17
+ </div>
@@ -0,0 +1,57 @@
1
+ <% content_for :page_title do %>
2
+ <%= t('spree.active_sale.title.list') %>
3
+ <% end %>
4
+
5
+ <% content_for :page_actions do %>
6
+ <li>
7
+ <%= button_link_to t('spree.active_sale.link.new'), new_object_url, :icon => 'icon-plus', :id => 'admin_new_active_sale_link' %>
8
+ </li>
9
+ <% end %>
10
+
11
+ <div id="new_active_sale" data-hook></div>
12
+
13
+ <table class="index" id="listing_active_sales" data-hook>
14
+ <colgroup>
15
+ <col style="width: 85%">
16
+ <col style="width: 15%">
17
+ </colgroup>
18
+ <thead>
19
+ <tr data-hook="admin_active_sales_index_headers">
20
+ <th><%= sort_link @search, :name, t('spree.active_sale.active_record.name'), {}, { :title => 'active_sales_name_title' } %></th>
21
+ <th data-hook="admin_active_sales_index_header_actions" class="actions"></th>
22
+ </tr>
23
+ </thead>
24
+ <tbody>
25
+ <% @active_sales.each do |active_sale| %>
26
+ <tr id="<%= spree_dom_id active_sale %>" data-hook="admin_active_sales_index_rows" class="<%= cycle('odd', 'even')%>">
27
+ <td class='active_sale_name'><%= link_to active_sale.name, object_url(active_sale) %></td>
28
+ <td class="actions" data-hook="admin_active_sales_index_row_actions">
29
+ <p class="actions" data-hook="actions">
30
+ <%= link_to_edit active_sale, :no_text => true %>
31
+ <%= link_to_delete active_sale, :no_text => true %>
32
+ </p>
33
+ </td>
34
+ </tr>
35
+ <% end %>
36
+ </tbody>
37
+ </table>
38
+
39
+ <%= paginate @active_sales %>
40
+
41
+ <% content_for :sidebar_title do %>
42
+ <%= t(:search) %>
43
+ <% end %>
44
+
45
+ <% content_for :sidebar do %>
46
+ <div class="box align-center" data-hook="admin_active_sales_index_search">
47
+ <%= search_form_for [:admin, @search] do |f| %>
48
+ <div class="field">
49
+ <%= f.label t(:name) %> <br>
50
+ <%= f.text_field :name_cont, :class => 'fullwidth' %>
51
+ </div>
52
+ <div data-hook="admin_active_sales_index_search_buttons">
53
+ <%= button t(:search), 'icon-search' %>
54
+ </div>
55
+ <% end %>
56
+ </div>
57
+ <% end %>
@@ -0,0 +1,15 @@
1
+ <% content_for :page_title do %>
2
+ <%= t('spree.active_sale.title.new') %>
3
+ <% end %>
4
+
5
+ <% content_for :page_actions do %>
6
+ <li>
7
+ <%= button_link_to t('spree.active_sale.link.back'), collection_url, :icon => 'icon-arrow-left', :id => 'back_to_active_sales_link' %>
8
+ </li>
9
+ <% end %>
10
+
11
+ <div data-hook="admin_active_sale_new_form">
12
+ <div id="active-sale-form-wrapper">
13
+ <%= render :partial => 'form' %>
14
+ </div>
15
+ </div>
@@ -0,0 +1,18 @@
1
+ <div data-hook="admin_image_form_fields">
2
+ <div class="four columns alpha">
3
+ <div data-hook="file" class="field">
4
+ <%= f.label t(:filename) %><br>
5
+ <%= f.file_field :attachment %>
6
+ </div>
7
+ </div>
8
+ <div data-hook="alt_text" class="field omega five columns">
9
+ <%= f.label t(:alt_text) %><br>
10
+ <%= f.text_area :alt, :rows => 4, :class => 'fullwidth' %>
11
+ </div>
12
+ </div>
13
+
14
+ <div class="clear"></div>
15
+
16
+ <br/>
17
+
18
+ <%= render 'spree/admin/shared/sale_images' %>
@@ -0,0 +1,24 @@
1
+ <%= render :partial => 'spree/shared/error_messages', :locals => { :target => @sale_image } %>
2
+
3
+ <ul class="inline-menu">
4
+ <li><%= button_link_to t('spree.active_sale.event.link.back'), edit_admin_active_sale_active_sale_event_url(@active_sale, @active_sale_event), :icon => 'icon-arrow-left' %></li>
5
+ </ul>
6
+
7
+ <%= form_for [:admin, @active_sale, @active_sale_event, @sale_image], :html => { :multipart => true } do |f| %>
8
+ <fieldset data-hook="edit_image">
9
+ <legend align="center"><%= @sale_image.attachment_file_name%></legend>
10
+ <div data-hook="thumbnail" class="field alpha three columns align-center">
11
+ <%= f.label t(:thumbnail) %><br>
12
+ <%= link_to image_tag(@sale_image.attachment.url(:small)), @sale_image.attachment.url(:product) %>
13
+ </div>
14
+ <div class="nine columns omega">
15
+ <%= render :partial => 'form', :locals => { :f => f } %>
16
+ </div>
17
+ <div class="clear"></div>
18
+ <div class="form-buttons filter-actions actions" data-hook="buttons">
19
+ <%= button t(:update), 'icon-refresh' %>
20
+ <span class="or"><%= t(:or) %></span>
21
+ <%= link_to_with_icon 'icon-remove', t(:cancel), admin_active_sale_active_sale_event_url(@active_sale, @active_sale_event), :id => 'cancel_link', :class => 'button' %>
22
+ </div>
23
+ </fieldset>
24
+ <% end %>
@@ -0,0 +1,19 @@
1
+ <ul class="inline-menu">
2
+ <li><%= button_link_to t('spree.active_sale.event.link.back'), edit_admin_active_sale_active_sale_event_url(@active_sale, @active_sale_event), :icon => 'icon-arrow-left' %></li>
3
+ </ul>
4
+
5
+
6
+ <%= form_for [:admin, @active_sale, @active_sale_event, @sale_image], :html => { :multipart => true } do |f| %>
7
+ <fieldset data-hook="new_image">
8
+ <legend align="center"><%= t(:new_image) %></legend>
9
+
10
+ <%= render :partial => 'form', :locals => { :f => f } %>
11
+
12
+ <div class="form-buttons filter-actions actions" data-hook="buttons">
13
+ <%= button t(:save), 'icon-refresh' %>
14
+ <span class="or"><%= t(:or) %></span>
15
+ <%= link_to_with_icon 'icon-remove', t(:cancel), admin_active_sale_active_sale_event_url(@active_sale_event.active_sale, @active_sale_event), :id => 'cancel_link', :class => 'button' %>
16
+ </div>
17
+ </fieldset>
18
+ <% end %>
19
+
@@ -0,0 +1,32 @@
1
+
2
+ <div id="new_active_sale_event" data-hook></div>
3
+
4
+ <table class="index" id="listing_active_sale_events" data-hook>
5
+ <thead>
6
+ <tr data-hook="admin_active_sale_events_index_headers">
7
+ <th><%= t('spree.active_sale.event.active_record.name') %></th>
8
+ <th><%= t('spree.active_sale.event.active_record.start_date') %></th>
9
+ <th><%= t('spree.active_sale.event.active_record.end_date') %></th>
10
+ <th><%= t('spree.active_sale.event.active_record.is_live') %></th>
11
+ <th data-hook="admin_active_sale_events_index_header_actions" class="actions"></th>
12
+ </tr>
13
+ </thead>
14
+ <tbody>
15
+ <% @active_sale_events.each do |event| %>
16
+ <tr id="<%= spree_dom_id event %>" data-hook="admin_active_sales_index_rows" class="<%= cycle('odd', 'even')%>">
17
+ <td class='active_sale_name'><%= link_to event.name, [:admin, @active_sale, event] %></td>
18
+ <td class='active_sale_start_date'><%= event.start_date %></td>
19
+ <td class='active_sale_end_date'><%= event.end_date %></td>
20
+ <td class='active_sale_is_live'><%= event.live? ? t('spree.active_sale.event.boolean.yes') : t('spree.active_sale.event.boolean.no') %></td>
21
+
22
+ <td class="actions" data-hook="admin_active_sale_events_index_row_actions">
23
+ <p class="actions" data-hook="actions">
24
+ <%= link_to_edit_url [:edit, :admin, @active_sale, event], :no_text => true %>
25
+ &nbsp;
26
+ <%= link_to_delete event, { :url => [:admin, @active_sale, event], :no_text => true } %>
27
+ </p>
28
+ </td>
29
+ </tr>
30
+ <% end %>
31
+ </tbody>
32
+ </table>
@@ -0,0 +1,41 @@
1
+ <div id="images" data-hook></div>
2
+
3
+ <% unless @active_sale_event.sale_images.any? %>
4
+ <div class="no-objects-found">
5
+ <%= t('spree.active_sale.event.no_image') %>
6
+ </div>
7
+ <% else %>
8
+ <table class="index sortable" data-hook="images_table" data-sortable-link="<%= update_positions_admin_active_sale_active_sale_event_sale_images_url(@active_sale, @active_sale_event) %>">
9
+ <colgroup>
10
+ <col style="width: 5%">
11
+ <col style="width: 10%">
12
+ <col style="width: 45%">
13
+ <col style="width: 15%">
14
+ </colgroup>
15
+ <thead>
16
+ <tr data-hook="images_header">
17
+ <th colspan="2"><%= t(:thumbnail) %></th>
18
+ <th><%= t(:alt_text) %></th>
19
+ <th class="actions"></th>
20
+ </tr>
21
+ </thead>
22
+
23
+ <tbody>
24
+ <% (@active_sale_event.sale_images).each do |image| %>
25
+ <tr id="<%= spree_dom_id image %>" data-hook="images_row" class="<%= cycle('odd', 'even')%>">
26
+ <td class="no-border">
27
+ <span class="handle"></span>
28
+ </td>
29
+ <td>
30
+ <%= link_to image_tag(image.attachment.url(:mini)), image.attachment.url(:original) %>
31
+ </td>
32
+ <td><%= image.alt %></td>
33
+ <td class="actions">
34
+ <%= link_to_edit_url [:edit, :admin, @active_sale, @active_sale_event, image], :no_text => true %>
35
+ <%= link_to_delete image, { :url => [:admin, @active_sale, @active_sale_event, image], :no_text => true } %>
36
+ </td>
37
+ </tr>
38
+ <% end %>
39
+ </tbody>
40
+ </table>
41
+ <% end %>
@@ -0,0 +1,57 @@
1
+ <script>
2
+ Spree.translations = <%==
3
+ { :date_picker => I18n.t(:js_format,
4
+ :scope => 'spree.date_picker',
5
+ :default => 'yy/mm/dd'),
6
+ :abbr_day_names => I18n.t(:abbr_day_names, :scope => :date),
7
+ :add => I18n.t(:add),
8
+ :are_you_sure_delete => I18n.t(:are_you_sure_delete),
9
+ :bill_address => I18n.t(:bill_address),
10
+ :choose_a_customer => I18n.t(:choose_a_customer),
11
+ :confirm_delete => I18n.t(:confirm_delete),
12
+ :cut => I18n.t(:cut),
13
+ :destroy => I18n.t(:destroy),
14
+ :edit => I18n.t(:edit),
15
+ :loading => I18n.t(:loading),
16
+ :month_names => I18n.t(:month_names, :scope => :date).delete_if(&:blank?),
17
+ :more => I18n.t(:more),
18
+ :name => I18n.t(:name),
19
+ :next => I18n.t(:next),
20
+ :no_results => I18n.t(:no_results),
21
+ :on_hand => I18n.t(:on_hand),
22
+ :paste => I18n.t(:paste),
23
+ :previous => I18n.t(:previous),
24
+ :remove => I18n.t(:remove),
25
+ :rename => I18n.t(:rename),
26
+ :searching => I18n.t(:searching),
27
+ :sku => I18n.t(:sku),
28
+ :type_to_search => I18n.t(:type_to_search),
29
+ :taxon_placeholder => I18n.t(:taxon_placeholder),
30
+ :value => I18n.t(:value)
31
+ }.to_json
32
+ %>
33
+ </script>
34
+
35
+ <script>
36
+ Spree.datetime_translations = <%==
37
+ { :date_format => I18n.t('spree.active_sale.event.datetimepicker.js_date_format',
38
+ :default => 'yy/mm/dd'),
39
+ :time_format => I18n.t('spree.active_sale.event.datetimepicker.js_format',
40
+ :default => 'hh:mm:ss tt z'),
41
+ :time_only_title => I18n.t('spree.active_sale.event.datetimepicker.time_only_title',
42
+ :default => 'Time Only'),
43
+ :time_text => I18n.t('spree.active_sale.event.datetimepicker.time_text',
44
+ :default => 'Time'),
45
+ :hour_text => I18n.t('spree.active_sale.event.datetimepicker.hour_text',
46
+ :default => 'Hour'),
47
+ :minute_text => I18n.t('spree.active_sale.event.datetimepicker.minute_text',
48
+ :default => 'Minute'),
49
+ :second_text => I18n.t('spree.active_sale.event.datetimepicker.second_text',
50
+ :default => 'Second'),
51
+ :current_text => I18n.t('spree.active_sale.event.datetimepicker.current_text',
52
+ :default => 'Current'),
53
+ :close_text => I18n.t('spree.active_sale.event.datetimepicker.close_text',
54
+ :default => 'Close')
55
+ }.to_json
56
+ %>
57
+ </script>
@@ -0,0 +1,4 @@
1
+ <div data-hook="homepage_sales">
2
+ <%= render :partial => 'spree/shared/sale_events', :locals => { :sale_events => @sale_events } %>
3
+ </div>
4
+
@@ -0,0 +1,28 @@
1
+ <%
2
+ paginate_sales = sale_events.paginate(:active_sale_events_per_page) if Spree::ActiveSaleConfig[:paginate_sale_events_for_user?]
3
+ paginate_sales ||= sale_events
4
+ %>
5
+
6
+ <% if sale_events.empty? %>
7
+ <%= t('spree.active_sale.events_not_found') %>
8
+ <% else %>
9
+ <ul id="sale_events" class="inline product-listing" data-hook>
10
+ <% sale_events.each do |sale_event| %>
11
+ <% if sale_image_available?(sale_event) %>
12
+ <li id="active_sale_<%= sale_event.id %>" class="columns three <%= cycle("alpha", "secondary", "", "omega secondary", :name => "classes") %>" data-hook="active_sales_list_item" itemscope itemtype="http://schema.org/Offer">
13
+ <div class="sale_event-image">
14
+ <%= link_to small_event_image(sale_event, :itemprop => "image"), sale_event.permalink, :itemprop => 'url' %>
15
+ </div>
16
+ <%= link_to truncate(sale_event.name, :length => 50), sale_event.permalink, :class => 'info', :itemprop => "name", :title => sale_event.name %>
17
+ <br>
18
+ <%= sale_event_timer(sale_event) %>
19
+ </li>
20
+ <% end %>
21
+ <% end %>
22
+ <% reset_cycle("classes") %>
23
+ </ul>
24
+ <% end %>
25
+
26
+ <% if paginate_sales.respond_to?(:num_pages) %>
27
+ <%= paginate paginate_sales %>
28
+ <% end %>
@@ -0,0 +1,74 @@
1
+ # Active Sale localization file for English. Add more files in this directory for other locales.
2
+ # See https://github.com/svenfuchs/rails-i18n/tree/master/rails%2Flocale for starting points.
3
+
4
+ en:
5
+ spree:
6
+ active_sale:
7
+ active_record:
8
+ name: "Sale name"
9
+ event:
10
+ active_record:
11
+ description: "Event Description"
12
+ is_active: "Active?"
13
+ is_hidden: "Hidden?"
14
+ is_permanent: "Permanent?"
15
+ is_live: "Live?"
16
+ discount: "Discount percentage"
17
+ name: "Event name"
18
+ start_date: "Start date"
19
+ end_date: "End date"
20
+ eventable_name: "Add the name to add type in event"
21
+ eventable_type: "Add a type for event"
22
+ permalink: "Type the name or permalink"
23
+ boolean:
24
+ yes: "Yes"
25
+ no: "No"
26
+ can_not_be_nil: "Argument can not be nil or instance of any other class than Spree::ActiveSaleEvent"
27
+ create_if_no_record: "You don't have any event in this active sale, let's create an event?"
28
+ datetimepicker:
29
+ format: ! '%Y/%m/%d %H:%M:%S %z'
30
+ js_format: 'HH:mm:ss z'
31
+ js_date_format: 'yy/mm/dd'
32
+ time_only_title: 'Time only'
33
+ time_text: 'Time'
34
+ hour_text: 'Hour'
35
+ minute_text: 'Minute'
36
+ second_text: 'Second'
37
+ current_text: 'Current'
38
+ close_text: 'Close'
39
+ ending_message: "SALE CLOSES IN"
40
+ eventable_hint: "Will this be a sale for an individual product or many based on a taxon?"
41
+ eventable_name_hint: "Enter the name of product or taxon this sale will include."
42
+ discount_hint: "Integer number with the mean or max discount percentage (i.e. '30' to express a 30%)."
43
+ flash:
44
+ error: "The page you are looking for is no longer available."
45
+ link:
46
+ new: "New event"
47
+ edit: "Edit event"
48
+ back: "Back to events"
49
+ no_image: "No image found. If image is not available for this sale then affiliated product's/ taxon's image will be used by default to show on store."
50
+ notice_messages:
51
+ created: "Event was successfully created."
52
+ updated: "Event was successfully updated."
53
+ deleted: "Event has been deleted."
54
+ title:
55
+ new: "New event"
56
+ edit: "Edit event"
57
+ list: "Listing events"
58
+ validation:
59
+ errors:
60
+ invalid_dates: "can not be greater than or equal to the end date."
61
+ live_event: "already running and live."
62
+ events_not_found: "There are no sales available at this moment. Try later?"
63
+ link:
64
+ new: "New active sale"
65
+ edit: "Edit active sale"
66
+ back: "Back to active sales list"
67
+ notice_messages:
68
+ created: "Active sale was successfully created."
69
+ updated: "Active sale was successfully updated."
70
+ deleted: "Active sale has been deleted."
71
+ title:
72
+ new: "New active sale"
73
+ edit: "Edit active sale"
74
+ list: "Listing active sales"