diff --git a/Gemfile.lock b/Gemfile.lock
index 6f16202c1..9ac087970 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -53,10 +53,10 @@ PATH
rqrcode (~> 2.0)
searchkick (~> 5.1)
simple_calendar (~> 2.4)
- spree (>= 4.5.0)
- spree_api_v1 (>= 4.5.0)
- spree_auth_devise (>= 4.5.0)
- spree_backend (>= 4.5.0)
+ spree (~> 4.5.0)
+ spree_api_v1 (~> 4.5.0)
+ spree_auth_devise (~> 4.5.0)
+ spree_backend (~> 4.5.0)
spree_extension
spree_multi_vendor (>= 2.4.1)
telegram-bot
@@ -719,7 +719,7 @@ GEM
responders
spree (>= 4.4.0.rc1)
spree_extension
- spree_auth_devise (4.6.0)
+ spree_auth_devise (4.5.0)
devise (~> 4.7)
devise-encryptable (= 0.2.0)
spree_core (>= 4.5.0)
diff --git a/app/jobs/spree_cm_commissioner/subscription_order_executor_job.rb b/app/jobs/spree_cm_commissioner/subscription_order_executor_job.rb
index 25ed800cd..7d733c6b8 100644
--- a/app/jobs/spree_cm_commissioner/subscription_order_executor_job.rb
+++ b/app/jobs/spree_cm_commissioner/subscription_order_executor_job.rb
@@ -2,6 +2,8 @@ module SpreeCmCommissioner
class SubscriptionOrderExecutorJob < ApplicationJob
def perform
SubscriptionsOrderCronExecutor.call
+ logger.info 'SubscriptionOrderExecutorJob done'
+ logger.debug { 'My args: tykeaboyloy' }
end
end
end
diff --git a/app/views/spree/billing/businesses/index.html.erb b/app/views/spree/billing/businesses/index.html.erb
index 66441c746..6bee44dd0 100644
--- a/app/views/spree/billing/businesses/index.html.erb
+++ b/app/views/spree/billing/businesses/index.html.erb
@@ -1,9 +1,9 @@
<% content_for :page_title do %>
- <%= @businesses_taxonomy&.name %>
+ <%= I18n.t('spree.billing.businesses') %>
<% end %>
<% content_for :page_actions do %>
- <%= button_link_to Spree.t('billing.businesses.add_new_business'), spree.new_billing_business_path(), icon: 'add.svg', class: 'no-wrap btn btn-success align-self-center' %>
+ <%= button_link_to I18n.t('spree.billing.add_new_business'), spree.new_billing_business_path(), icon: 'add.svg', class: 'no-wrap btn btn-success align-self-center' %>
<% end %>
diff --git a/app/views/spree/billing/customers/_form.html.erb b/app/views/spree/billing/customers/_form.html.erb
index 5b14a316b..ac4b1b529 100644
--- a/app/views/spree/billing/customers/_form.html.erb
+++ b/app/views/spree/billing/customers/_form.html.erb
@@ -6,17 +6,17 @@
<%= f.error_message_on :email %>
<% end %>
<%= f.field_container :first_name do %>
- <%= f.label :first_name, Spree.t(:business_name) %>
+ <%= f.label :first_name, Spree.t('billing.business_name') %>
<%= f.text_field :first_name, class: 'form-control' %>
<%= f.error_message_on :first_name %>
<% end %>
<%= f.field_container :last_name do %>
- <%= f.label :last_name, Spree.t(:owner_name) %>
+ <%= f.label :last_name, Spree.t('billing.owner_name') %>
<%= f.text_field :last_name, class: 'form-control' %>
<%= f.error_message_on :last_name %>
<% end %>
<%= f.field_container :place_id do %>
- <%= f.label :place_id, Spree.t(:place) %>
+ <%= f.label :place_id, Spree.t('billing.places') %>
<%= f.collection_select(:place_id, SpreeCmCommissioner::Place.all, :id, :name, { include_blank: true }, { class: 'select2-clear' }) %>
<%= f.error_message_on :location %>
<% end %>
@@ -27,7 +27,7 @@
<% end %>
<%= f.hidden_field :vendor_id, value: current_vendor.id %>
<%= f.field_container :taxons do %>
- <%= f.label :taxon_ids, Spree.t('businesses') %>
+ <%= f.label :taxon_ids, Spree.t('billing.businesses') %>
<%= f.collection_select(:taxon_ids, @businesses, :id, :name, { include_blank: Spree.t('match_choices.none') }, { class: 'select2', multiple: true })%>
<%= f.error_message_on :taxon_ids %>
<% end %>
diff --git a/app/views/spree/billing/customers/index.html.erb b/app/views/spree/billing/customers/index.html.erb
index 9822e95b6..ce45a1f78 100644
--- a/app/views/spree/billing/customers/index.html.erb
+++ b/app/views/spree/billing/customers/index.html.erb
@@ -59,7 +59,7 @@
<%= sort_link @search, :id, Spree.t(:id), {}, {title:"id_title"} %>
- <%= sort_link @search, :full_name, Spree.t(:business_name), {}, {title: 'fullname_title'} %>
+ <%= sort_link @search, :full_name, I18n.t("spree.billing.business_name"), {}, {title: 'fullname_title'} %>
|
<%= sort_link @search, :full_name, Spree.t(:full_name), {}, {title: 'fullname_title'} %>
diff --git a/app/views/spree/billing/option_types/index.html.erb b/app/views/spree/billing/option_types/index.html.erb
index d73a7ade5..b140634ba 100644
--- a/app/views/spree/billing/option_types/index.html.erb
+++ b/app/views/spree/billing/option_types/index.html.erb
@@ -1,5 +1,5 @@
<% content_for :page_title do %>
- <%= plural_resource_name(Spree::OptionType) %>
+ <%= Spree.t('option_type') %>
<% end %>
<% content_for :page_actions do %>
diff --git a/app/views/spree/billing/payments/_list.html.erb b/app/views/spree/billing/payments/_list.html.erb
index 068476ad9..81c8caf0f 100644
--- a/app/views/spree/billing/payments/_list.html.erb
+++ b/app/views/spree/billing/payments/_list.html.erb
@@ -2,7 +2,7 @@
- <%= Spree::Payment.human_attribute_name(:number) %> |
+ <%= I18n.t(:number, scope: 'activerecord.attributes.spree/payment') %> |
<%= "#{Spree.t('date')}/#{Spree.t('time')}" %> |
<%= Spree.t(:amount) %> |
<%= Spree.t(:payment_method) %> |
diff --git a/app/views/spree/billing/places/index.html.erb b/app/views/spree/billing/places/index.html.erb
index 49b4094a4..f00db2734 100644
--- a/app/views/spree/billing/places/index.html.erb
+++ b/app/views/spree/billing/places/index.html.erb
@@ -3,7 +3,7 @@
<% end %>
<% content_for :page_actions do %>
- <%= button_link_to Spree.t(:new_place), new_billing_place_path, { class: "btn-success", icon: 'add.svg', id: 'admin_new_place' } %>
+ <%= button_link_to I18n.t('spree.billing.new_place'), new_billing_place_path, { class: "btn-success", icon: 'add.svg', id: 'admin_new_place' } %>
<% end if can?(:create, SpreeCmCommissioner::Place) %>
<% content_for :table_filter do %>
@@ -37,8 +37,8 @@
<%= sort_link @search,:name, Spree.t(:name), { default_order: "desc" }, {title: 'admin_places_listing_name_title'} %> |
<%= sort_link @search,:code, Spree.t(:code), { default_order: "desc" }, {title: 'admin_places_listing_code_title'} %> |
- <%= sort_link @search,:updated_at, Spree.t(:updated_at), { default_order: "desc" }, {title: 'admin_places_listing_updated_at_title'} %> |
- <%= sort_link @search,:created_at, Spree.t(:created_at), { default_order: "desc" }, {title: 'admin_places_listing_created_at_title'} %> |
+ <%= sort_link @search,:updated_at, I18n.t(:updated_at, scope: 'activerecord.attributes.spree/order'), { default_order: "desc" }, {title: 'admin_places_listing_updated_at_title'} %> |
+ <%= sort_link @search,:created_at, I18n.t(:created_at, scope: 'activerecord.attributes.spree/order'), { default_order: "desc" }, {title: 'admin_places_listing_created_at_title'} %> |
|
diff --git a/app/views/spree/billing/places/new.html.erb b/app/views/spree/billing/places/new.html.erb
index 6ffa18cf5..85b852809 100644
--- a/app/views/spree/billing/places/new.html.erb
+++ b/app/views/spree/billing/places/new.html.erb
@@ -1,6 +1,6 @@
<% content_for :page_title do %>
<%= page_header_back_button spree.billing_places_path %>
- <%= Spree.t(:new_place) %>
+ <%= Spree.t('billing.new_place') %>
<% end %>
<%= render partial: 'spree/admin/shared/error_messages', locals: { target: @object } %>
diff --git a/app/views/spree/billing/shared/sub_menu/_setting.html.erb b/app/views/spree/billing/shared/sub_menu/_setting.html.erb
index a7b5d6209..a9964eb67 100644
--- a/app/views/spree/billing/shared/sub_menu/_setting.html.erb
+++ b/app/views/spree/billing/shared/sub_menu/_setting.html.erb
@@ -5,5 +5,5 @@
<% if spree_current_user.has_spree_role?('admin') || spree_current_user.permissions.exists?(entry: 'spree/billing/roles') %>
<%= configurations_sidebar_menu_item(I18n.t('spree.billing.roles'), billing_roles_url) %>
<% end %>
- <%= tab :vendor, selected: request.path.include?('/vendors'), url: edit_billing_vendor_url(@current_vendor.id), label: Spree.t('billing.vendor') %>
+ <%= tab :vendor, selected: request.path.include?('/vendors'), url: edit_billing_vendor_url(@current_vendor.id), label: I18n.t('spree.vendor') %>
diff --git a/config/locales/en.yml b/config/locales/en.yml
index 918b5a186..472e3aeaf 100644
--- a/config/locales/en.yml
+++ b/config/locales/en.yml
@@ -241,8 +241,13 @@ en:
match_any: "Some line items must from selected age group"
match_all: "All line items must from selected age group"
billing:
+ owner_name: "Owner Name"
+ new_place: "New Place"
+ payment_date: "Payment Date"
new_order: "New Order"
businesses: "Businesses"
+ add_new_business: "Add New Business"
+ business_name: "Business Name"
places: "Places"
code: "code"
name: "name"
@@ -336,6 +341,8 @@ en:
show_invoices: "Show Invoices"
spree/report:
cashier: "Cashier"
+ spree/payment:
+ number: "Number"
errors:
models:
spree_cm_commissioner/service_calendar:
diff --git a/config/locales/km.yml b/config/locales/km.yml
index 82556a13e..45216cad1 100644
--- a/config/locales/km.yml
+++ b/config/locales/km.yml
@@ -228,12 +228,19 @@ km:
match_any: "Some line items must from selected age group"
match_all: "All line items must from selected age group"
billing:
- code: "code"
- name: "name"
- logo: "logo"
- payment_qrcode: "Payment QRCode"
- image: "image"
- order_line_items: "Order Line Items"
+ owner_name: "MISSING"
+ new_place: "MISSING"
+ new_order: "MISSING"
+ businesses: "MISSING"
+ add_new_business: "MISSING"
+ business_name: "MISSING"
+ places: "MISSING"
+ code: "MISSING"
+ name: "MISSING"
+ logo: "MISSING"
+ payment_qrcode: "MISSING"
+ image: "MISSING"
+ order_line_items: "MISSING"
new_role: "បង្កើតតួនាទីថ្មី"
role_id: "កូដតួនាទី"
settings: "ការកំណត់"
@@ -248,7 +255,11 @@ km:
balance_due_orders: "វិក្កយបត្រមិនទាន់បង់"
overdue_orders: "វិក្កយបត្រហួសថ្ងៃបង់"
orders: "វិក្កយបត្រ"
- customers: "អតិថិជន"
+ customers:
+ re_create_order:
+ success: "Invoice Created"
+ fails: "Invoice for this month is already exist "
+ customers: "អតិថិជន"
roles: "តួនាទី"
subscriptions: "ការប្រើប្រាស់"
active_subscription: "កំពុងប្រើប្រាស់"
@@ -257,7 +268,8 @@ km:
users: "គណនីបុគ្គលិក"
day: "ថ្ងៃ"
products: "ទំនិញ"
- vendor: "vendor"
+ account_name: "MISSING"
+ account_number: "MISSING"
payment_state:
paid: "បង់រួច"
balance_due: "មិនទាន់បង់"
@@ -281,10 +293,16 @@ km:
activerecord:
attributes:
spree/order:
+ product_type: "MISSING"
+ customer_name: "MISSING"
+ issued_date: "MISSING"
+ payment_date: "MISSING"
+ printing_date: "MISSING"
customer_id: "លេខកូដអតិថិជន"
to_date: "រហូតដល់ថ្ងៃ"
from_date: "ពីថ្ងៃ"
created_at: "បង្កើតនៅថ្ងៃ"
+ updated_at: "MISSING"
start_date: "ថ្ងៃចាប់ផ្តើម"
start_date_range: "ចន្លោះថ្ងៃចាប់ផ្តើម"
phone_number: "លេខទូរសព្ទ"
@@ -295,8 +313,13 @@ km:
type: "ប្រភេទ"
select_date: "ជ្រើសរើសថ្ងៃ"
taxon: "ប្រភេទ"
+ quantity: "MISSING"
+ amount: "MISSING"
+ show_invoices: "MISSING"
spree/report:
cashier: "អ្នកគិតលុយ"
+ spree/payment:
+ number: "MISSING"
errors:
models:
spree_cm_commissioner/service_calendar:
diff --git a/spec/models/spree_cm_commissioner/customer_spec.rb b/spec/models/spree_cm_commissioner/customer_spec.rb
index 50340faea..76fe258b1 100644
--- a/spec/models/spree_cm_commissioner/customer_spec.rb
+++ b/spec/models/spree_cm_commissioner/customer_spec.rb
@@ -73,4 +73,4 @@
expect(variants_list2).to include(*customer2.variants)
end
end
-end
\ No newline at end of file
+end
diff --git a/spree_cm_commissioner.gemspec b/spree_cm_commissioner.gemspec
index b1cf1645d..88d433385 100644
--- a/spree_cm_commissioner.gemspec
+++ b/spree_cm_commissioner.gemspec
@@ -20,7 +20,7 @@ Gem::Specification.new do |s|
s.require_path = 'lib'
s.requirements << 'none'
- spree_opts = '>= 4.5.0'
+ spree_opts = '~> 4.5.0'
s.add_dependency 'spree', spree_opts
s.add_dependency 'spree_api_v1', spree_opts # latest spree_multi_vendor 2.4.0 still depends on the Spree v1 API
s.add_dependency 'spree_auth_devise', spree_opts
@@ -52,4 +52,4 @@ Gem::Specification.new do |s|
s.add_development_dependency 'pg'
s.add_development_dependency 'spree_dev_tools'
s.metadata['rubygems_mfa_required'] = 'true'
-end
\ No newline at end of file
+end
|