spree_emails 6.0.0.beta4 → 6.0.0.rc2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +30 -74
- data/Rakefile +23 -0
- data/app/mailers/spree/company_mailer.rb +4 -7
- data/app/mailers/spree/customer_mailer.rb +6 -8
- data/app/mailers/spree/digital_asset_mailer.rb +18 -11
- data/app/mailers/spree/fulfillment_mailer.rb +11 -7
- data/app/mailers/spree/newsletter_mailer.rb +1 -2
- data/app/mailers/spree/order_group_mailer.rb +16 -20
- data/app/mailers/spree/order_mailer.rb +15 -20
- data/app/mailers/spree/return_mailer.rb +10 -5
- data/app/mailers/spree/seller_mailer.rb +8 -13
- data/app/models/spree/emails/amount_line.rb +32 -0
- data/app/serializers/spree/emails/address_serializer.rb +6 -0
- data/app/serializers/spree/emails/amount_line_serializer.rb +13 -0
- data/app/serializers/spree/emails/applied_promotion_serializer.rb +7 -0
- data/app/serializers/spree/emails/customer_group_serializer.rb +6 -0
- data/app/serializers/spree/emails/customer_serializer.rb +19 -0
- data/app/serializers/spree/emails/delivery_method_serializer.rb +6 -0
- data/app/serializers/spree/emails/delivery_rate_serializer.rb +12 -0
- data/app/serializers/spree/emails/delivery_serializer.rb +6 -0
- data/app/serializers/spree/emails/fee_serializer.rb +7 -0
- data/app/serializers/spree/emails/freight_summary_serializer.rb +6 -0
- data/app/serializers/spree/emails/fulfillment_group_serializer.rb +25 -0
- data/app/serializers/spree/emails/fulfillment_serializer.rb +21 -0
- data/app/serializers/spree/emails/gift_card_serializer.rb +7 -0
- data/app/serializers/spree/emails/line_item_serializer.rb +24 -0
- data/app/serializers/spree/emails/market_serializer.rb +6 -0
- data/app/serializers/spree/emails/newsletter_subscriber_serializer.rb +6 -0
- data/app/serializers/spree/emails/option_value_serializer.rb +6 -0
- data/app/serializers/spree/emails/order_group_serializer.rb +50 -0
- data/app/serializers/spree/emails/order_serializer.rb +27 -0
- data/app/serializers/spree/emails/parcel_item_serializer.rb +36 -0
- data/app/serializers/spree/emails/payment_method_serializer.rb +6 -0
- data/app/serializers/spree/emails/payment_serializer.rb +11 -0
- data/app/serializers/spree/emails/purchase_summary_attributes.rb +41 -0
- data/app/serializers/spree/emails/purchased_item_attributes.rb +28 -0
- data/app/serializers/spree/emails/return_serializer.rb +19 -0
- data/app/serializers/spree/emails/stock_location_serializer.rb +6 -0
- data/app/services/spree/emails/samples/base.rb +79 -0
- data/app/services/spree/emails/samples/company_invitation.rb +19 -0
- data/app/services/spree/emails/samples/data_export.rb +11 -0
- data/app/services/spree/emails/samples/downloads.rb +28 -0
- data/app/services/spree/emails/samples/fulfillment.rb +33 -0
- data/app/services/spree/emails/samples/newsletter_confirmation.rb +11 -0
- data/app/services/spree/emails/samples/order.rb +22 -0
- data/app/services/spree/emails/samples/order_group.rb +22 -0
- data/app/services/spree/emails/samples/password_reset.rb +15 -0
- data/app/services/spree/emails/samples/payment_link.rb +17 -0
- data/app/services/spree/emails/samples/return.rb +29 -0
- data/app/subscribers/spree/order_email_subscriber.rb +2 -2
- data/app/subscribers/spree/order_group_email_subscriber.rb +1 -1
- data/app/subscribers/spree/return_email_subscriber.rb +2 -0
- data/app/views/spree/company_mailer/invitation_email.liquid +13 -0
- data/app/views/spree/customer_mailer/data_export_email.liquid +18 -0
- data/app/views/spree/customer_mailer/password_reset_email.liquid +14 -0
- data/app/views/spree/digital_asset_mailer/files_ready_email.liquid +23 -0
- data/app/views/spree/fulfillment_mailer/fulfilled_email.liquid +21 -0
- data/app/views/spree/newsletter_mailer/email_confirmation.liquid +13 -0
- data/app/views/spree/order_group_mailer/confirm_email.liquid +35 -0
- data/app/views/spree/order_group_mailer/store_owner_notification_email.liquid +11 -0
- data/app/views/spree/order_mailer/cancel_email.liquid +12 -0
- data/app/views/spree/order_mailer/confirm_email.liquid +12 -0
- data/app/views/spree/order_mailer/payment_link_email.liquid +12 -0
- data/app/views/spree/order_mailer/store_owner_notification_email.liquid +11 -0
- data/app/views/spree/return_mailer/refunded_email.liquid +19 -0
- data/app/views/spree/seller_mailer/approved_email.liquid +13 -0
- data/app/views/spree/seller_mailer/rejected_email.liquid +11 -0
- data/app/views/spree/seller_mailer/suspended_email.liquid +11 -0
- data/app/views/spree/shared/_fulfillment_group.liquid +25 -0
- data/app/views/spree/shared/_line_item.liquid +29 -0
- data/app/views/spree/shared/_order_summary.liquid +17 -0
- data/app/views/spree/shared/_purchase_totals.liquid +35 -0
- data/config/initializers/typelizer.rb +61 -0
- data/config/locales/ar.yml +40 -0
- data/config/locales/be.yml +37 -0
- data/config/locales/bg.yml +31 -0
- data/config/locales/ca.yml +35 -0
- data/config/locales/cs.yml +38 -0
- data/config/locales/da.yml +37 -0
- data/config/locales/de-CH.yml +11 -0
- data/config/locales/de.yml +38 -0
- data/config/locales/el.yml +37 -0
- data/config/locales/en.yml +0 -25
- data/config/locales/es-CL.yml +21 -0
- data/config/locales/es-EC.yml +22 -0
- data/config/locales/es-MX.yml +26 -0
- data/config/locales/es.yml +40 -0
- data/config/locales/et.yml +31 -0
- data/config/locales/fa.yml +37 -0
- data/config/locales/fi.yml +37 -0
- data/config/locales/fr.yml +38 -0
- data/config/locales/hu.yml +37 -0
- data/config/locales/id.yml +37 -0
- data/config/locales/it.yml +38 -0
- data/config/locales/ja.yml +36 -0
- data/config/locales/km.yml +37 -0
- data/config/locales/ko.yml +36 -0
- data/config/locales/ku.yml +37 -0
- data/config/locales/lt.yml +37 -0
- data/config/locales/lv.yml +39 -0
- data/config/locales/nb.yml +37 -0
- data/config/locales/ne.yml +37 -0
- data/config/locales/nl.yml +38 -0
- data/config/locales/pl.yml +39 -0
- data/config/locales/pt-BR.yml +34 -0
- data/config/locales/pt.yml +34 -0
- data/config/locales/ro.yml +37 -0
- data/config/locales/ru.yml +38 -0
- data/config/locales/sk.yml +31 -0
- data/config/locales/sl-SI.yml +31 -0
- data/config/locales/sv.yml +37 -0
- data/config/locales/th.yml +37 -0
- data/config/locales/tr.yml +38 -0
- data/config/locales/uk.yml +42 -0
- data/config/locales/vi.yml +35 -0
- data/config/locales/zh-CN.yml +38 -0
- data/config/locales/zh-TW.yml +40 -0
- data/lib/spree/emails/engine.rb +27 -3
- data/lib/spree/emails/previews/company_preview.rb +10 -0
- data/lib/spree/emails/previews/customer_preview.rb +4 -0
- data/lib/spree/emails/previews/digital_asset_preview.rb +20 -0
- metadata +110 -55
- data/app/helpers/spree/base_helper.rb +0 -45
- data/app/helpers/spree/digital_asset_helper.rb +0 -16
- data/app/helpers/spree/fulfillment_helper.rb +0 -12
- data/app/helpers/spree/mail_helper.rb +0 -10
- data/app/views/spree/company_mailer/invitation_email.html.erb +0 -8
- data/app/views/spree/company_mailer/invitation_email.text.erb +0 -11
- data/app/views/spree/customer_mailer/data_export_email.html.erb +0 -12
- data/app/views/spree/customer_mailer/data_export_email.text.erb +0 -9
- data/app/views/spree/customer_mailer/password_reset_email.html.erb +0 -10
- data/app/views/spree/customer_mailer/password_reset_email.text.erb +0 -13
- data/app/views/spree/digital_asset_mailer/files_ready_email.html.erb +0 -20
- data/app/views/spree/digital_asset_mailer/files_ready_email.text.erb +0 -10
- data/app/views/spree/fulfillment_mailer/fulfilled_email.html.erb +0 -22
- data/app/views/spree/fulfillment_mailer/fulfilled_email.text.erb +0 -18
- data/app/views/spree/newsletter_mailer/email_confirmation.html.erb +0 -12
- data/app/views/spree/newsletter_mailer/email_confirmation.text.erb +0 -9
- data/app/views/spree/order_group_mailer/confirm_email.html.erb +0 -38
- data/app/views/spree/order_group_mailer/confirm_email.text.erb +0 -26
- data/app/views/spree/order_group_mailer/store_owner_notification_email.html.erb +0 -14
- data/app/views/spree/order_group_mailer/store_owner_notification_email.text.erb +0 -11
- data/app/views/spree/order_mailer/cancel_email.html.erb +0 -12
- data/app/views/spree/order_mailer/cancel_email.text.erb +0 -13
- data/app/views/spree/order_mailer/confirm_email.html.erb +0 -12
- data/app/views/spree/order_mailer/confirm_email.text.erb +0 -13
- data/app/views/spree/order_mailer/payment_link_email.html.erb +0 -11
- data/app/views/spree/order_mailer/store_owner_notification_email.html.erb +0 -11
- data/app/views/spree/order_mailer/store_owner_notification_email.text.erb +0 -13
- data/app/views/spree/return_mailer/refunded_email.html.erb +0 -22
- data/app/views/spree/return_mailer/refunded_email.text.erb +0 -20
- data/app/views/spree/seller_mailer/approved_email.html.erb +0 -8
- data/app/views/spree/seller_mailer/approved_email.text.erb +0 -8
- data/app/views/spree/seller_mailer/rejected_email.html.erb +0 -6
- data/app/views/spree/seller_mailer/rejected_email.text.erb +0 -7
- data/app/views/spree/seller_mailer/suspended_email.html.erb +0 -6
- data/app/views/spree/seller_mailer/suspended_email.text.erb +0 -7
- data/app/views/spree/shared/_fulfillment_group_section.html.erb +0 -37
- data/app/views/spree/shared/_fulfillment_group_section.text.erb +0 -12
- data/app/views/spree/shared/_item_thumbnail_link.html.erb +0 -18
- data/app/views/spree/shared/_order_summary_section.html.erb +0 -20
- data/app/views/spree/shared/_po_number.text.erb +0 -6
- data/app/views/spree/shared/_purchase_totals.html.erb +0 -62
- data/app/views/spree/shared/_purchase_totals.text.erb +0 -24
- data/app/views/spree/shared/_purchased_items_table.html.erb +0 -41
- data/app/views/spree/shared/_purchased_items_table.text.erb +0 -28
- data/app/views/spree/shared/purchased_items_table/_line_item.html.erb +0 -24
- data/app/views/spree/shared/purchased_items_table/_subtotal.html.erb +0 -3
- data/app/views/spree/shared/purchased_items_table/_summary_row.html.erb +0 -14
- data/app/views/spree/shared/purchased_items_table/_total.html.erb +0 -4
- data/config/i18n-tasks.yml +0 -22
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
---
|
|
2
|
+
th:
|
|
3
|
+
spree:
|
|
4
|
+
customer_mailer:
|
|
5
|
+
password_reset_email:
|
|
6
|
+
action: ตั้งรหัสผ่านใหม่
|
|
7
|
+
expiry_notice: ลิงก์ตั้งรหัสผ่านใหม่นี้จะหมดอายุในไม่ช้า หากคุณไม่ได้ร้องขอ ไม่จำเป็นต้องดำเนินการใด ๆ
|
|
8
|
+
greeting: สวัสดีคุณ %{name},
|
|
9
|
+
ignore_notice: หากคุณไม่ได้ร้องขอการตั้งรหัสผ่านใหม่ คุณสามารถละเว้นอีเมลนี้ได้อย่างปลอดภัย รหัสผ่านของคุณจะไม่ถูกเปลี่ยนแปลง
|
|
10
|
+
instructions: เราได้รับคำขอตั้งรหัสผ่านใหม่ของคุณ คลิกที่ปุ่มด้านล่างเพื่อเลือกรหัสผ่านใหม่
|
|
11
|
+
newsletter_mailer:
|
|
12
|
+
email_confirmation:
|
|
13
|
+
dear_customer: สวัสดี,
|
|
14
|
+
ignore_disclaimer: หากคุณไม่ได้ร้องขอ กรุณาละเว้นอีเมลนี้
|
|
15
|
+
instructions: กรุณาคลิกที่ปุ่มด้านล่างเพื่อยืนยันที่อยู่อีเมลของคุณ
|
|
16
|
+
message_copy_link: 'หากปุ่มไม่ทำงาน กรุณาคัดลอกและวางลิงก์ต่อไปนี้ลงในเบราว์เซอร์ของคุณ:'
|
|
17
|
+
subject: ยืนยันที่อยู่อีเมลของคุณ
|
|
18
|
+
verify_email_address_link: ยืนยันที่อยู่อีเมล
|
|
19
|
+
order_mailer:
|
|
20
|
+
cancel_email:
|
|
21
|
+
instructions: สินค้าของคุณได้ถูกยกเลิกแล้ว กรุณาเก็บหลักฐานอีเมลฉบับนี้เอาไว้ เพื่อใช้ในการอ้างอิงในอนาคต
|
|
22
|
+
subject: การยกเลิกการสั่งซื้อ
|
|
23
|
+
confirm_email:
|
|
24
|
+
instructions: กรุณาตรวจสอบและเก็บรายละเอียดการสั่งซื้อนี้เอาไว้
|
|
25
|
+
subject: ยืนยันการสั่งซื้อ
|
|
26
|
+
payment_link_email:
|
|
27
|
+
message: กรุณาคลิกที่ปุ่มด้านล่างเพื่อชำระเงินสำหรับคำสั่งซื้อของคุณ
|
|
28
|
+
message_copy_link: 'หากปุ่มไม่ทำงาน กรุณาคัดลอกและวางลิงก์ต่อไปนี้ลงในเบราว์เซอร์ของคุณ:'
|
|
29
|
+
pay_for_order: ชำระเงินสำหรับคำสั่งซื้อ
|
|
30
|
+
subject: 'ลิงก์ชำระเงินสำหรับคำสั่งซื้อ #%{number}'
|
|
31
|
+
store_owner_notification_email:
|
|
32
|
+
heading: ได้รับคำสั่งซื้อใหม่
|
|
33
|
+
instructions: คุณได้รับคำสั่งซื้อใหม่
|
|
34
|
+
order_summary: สรุปคำสั่งซื้อ %{number}
|
|
35
|
+
subject: "%{store_name} ได้รับคำสั่งซื้อใหม่"
|
|
36
|
+
subtotal: 'ยอดรวมย่อย:'
|
|
37
|
+
total: 'ยอดรวมคำสั่งซื้อ:'
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
---
|
|
2
|
+
tr:
|
|
3
|
+
spree:
|
|
4
|
+
customer_mailer:
|
|
5
|
+
password_reset_email:
|
|
6
|
+
action: Parolayı Sıfırla
|
|
7
|
+
expiry_notice: Bu parola sıfırlama bağlantısının süresi kısa süre içinde dolacaktır. Bu isteği siz yapmadıysanız herhangi bir işlem yapmanıza gerek yoktur.
|
|
8
|
+
greeting: Merhaba %{name},
|
|
9
|
+
ignore_notice: Parola sıfırlama talebinde bulunmadıysanız bu e-postayı güvenle yok sayabilirsiniz. Parolanız değiştirilmeyecektir.
|
|
10
|
+
instructions: Parolanızı sıfırlamak için bir talep aldık. Yeni bir parola seçmek için aşağıdaki düğmeye tıklayın.
|
|
11
|
+
subject: Parola Sıfırlama Talimatları
|
|
12
|
+
newsletter_mailer:
|
|
13
|
+
email_confirmation:
|
|
14
|
+
dear_customer: Merhaba,
|
|
15
|
+
ignore_disclaimer: Bunu siz talep etmediyseniz lütfen bu e-postayı yok sayın.
|
|
16
|
+
instructions: E-posta adresinizi doğrulamak için lütfen aşağıdaki düğmeye tıklayın.
|
|
17
|
+
message_copy_link: 'Düğme çalışmıyorsa lütfen aşağıdaki bağlantıyı kopyalayıp tarayıcınıza yapıştırın:'
|
|
18
|
+
subject: E-posta adresinizi doğrulayın
|
|
19
|
+
verify_email_address_link: E-posta adresini doğrula
|
|
20
|
+
order_mailer:
|
|
21
|
+
cancel_email:
|
|
22
|
+
instructions: Siparişiniz iptal edilmiştir. Kayıtlarınız için lütfen iptal etme işleminin bilgilerini saklayınız.
|
|
23
|
+
subject: Sipariş İptal Etme
|
|
24
|
+
confirm_email:
|
|
25
|
+
instructions: Lütfen aşağıdaki sipariş bilgilerini gözden geçiriniz ve kayıtlarınız için saklayınız.
|
|
26
|
+
subject: Sipariş Onayı
|
|
27
|
+
payment_link_email:
|
|
28
|
+
message: Siparişinizin ödemesini yapmak için lütfen aşağıdaki düğmeye tıklayın.
|
|
29
|
+
message_copy_link: 'Düğme çalışmıyorsa lütfen aşağıdaki bağlantıyı kopyalayıp tarayıcınıza yapıştırın:'
|
|
30
|
+
pay_for_order: Siparişin ödemesini yap
|
|
31
|
+
subject: "#%{number} numaralı sipariş için ödeme bağlantısı"
|
|
32
|
+
store_owner_notification_email:
|
|
33
|
+
heading: Yeni Sipariş Alındı
|
|
34
|
+
instructions: Yeni bir sipariş aldınız.
|
|
35
|
+
order_summary: "%{number} Numaralı Sipariş Özeti"
|
|
36
|
+
subject: "%{store_name} yeni bir sipariş aldı"
|
|
37
|
+
subtotal: 'Ara Toplam:'
|
|
38
|
+
total: 'Sipariş Toplamı:'
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
---
|
|
2
|
+
uk:
|
|
3
|
+
spree:
|
|
4
|
+
customer_mailer:
|
|
5
|
+
password_reset_email:
|
|
6
|
+
action: Скинути пароль
|
|
7
|
+
expiry_notice: Це посилання для скидання пароля незабаром закінчиться. Якщо ви не надсилали такий запит, жодних дій не потрібно.
|
|
8
|
+
greeting: Вітаємо, %{name}!
|
|
9
|
+
ignore_notice: Якщо ви не надсилали запит на скидання пароля, можете спокійно проігнорувати цей лист. Ваш пароль не буде змінено.
|
|
10
|
+
instructions: Ми отримали запит на скидання вашого пароля. Натисніть кнопку нижче, щоб обрати новий пароль.
|
|
11
|
+
subject: Інструкції зі скидання пароля
|
|
12
|
+
newsletter_mailer:
|
|
13
|
+
email_confirmation:
|
|
14
|
+
dear_customer: Вітаємо,
|
|
15
|
+
ignore_disclaimer: Якщо ви не надсилали такий запит, проігноруйте цей лист.
|
|
16
|
+
instructions: Натисніть кнопку нижче, щоб підтвердити свою адресу електронної пошти.
|
|
17
|
+
message_copy_link: 'Якщо кнопка не працює, скопіюйте та вставте наступне посилання у свій браузер:'
|
|
18
|
+
subject: Підтвердьте свою адресу електронної пошти
|
|
19
|
+
verify_email_address_link: Підтвердити адресу електронної пошти
|
|
20
|
+
order_mailer:
|
|
21
|
+
cancel_email:
|
|
22
|
+
dear_customer: Шановний(а) %{name},
|
|
23
|
+
instructions: Ваше замовлення СКАСОВАНО. Будь ласка, збережіть цю інформацію про скасування для своїх записів.
|
|
24
|
+
order_summary_canceled: Підсумок замовлення %{number} [СКАСОВАНО]
|
|
25
|
+
subject: Скасування замовлення
|
|
26
|
+
confirm_email:
|
|
27
|
+
dear_customer: Шановний(а) %{name},
|
|
28
|
+
instructions: Будь ласка, перегляньте та збережіть наступну інформацію про замовлення для своїх записів.
|
|
29
|
+
order_summary: Підсумок замовлення %{number}
|
|
30
|
+
subject: Підтвердження замовлення
|
|
31
|
+
payment_link_email:
|
|
32
|
+
message: Натисніть кнопку нижче, щоб оплатити своє замовлення.
|
|
33
|
+
message_copy_link: 'Якщо кнопка не працює, скопіюйте та вставте наступне посилання у свій браузер:'
|
|
34
|
+
pay_for_order: Оплатити замовлення
|
|
35
|
+
subject: Посилання для оплати замовлення №%{number}
|
|
36
|
+
store_owner_notification_email:
|
|
37
|
+
heading: Нове замовлення отримано
|
|
38
|
+
instructions: Ви отримали нове замовлення.
|
|
39
|
+
order_summary: Підсумок замовлення %{number}
|
|
40
|
+
subject: "%{store_name} отримав нове замовлення"
|
|
41
|
+
subtotal: 'Підсумок:'
|
|
42
|
+
total: 'Загальна сума замовлення:'
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
---
|
|
2
|
+
vi:
|
|
3
|
+
spree:
|
|
4
|
+
customer_mailer:
|
|
5
|
+
password_reset_email:
|
|
6
|
+
action: Đặt lại mật khẩu
|
|
7
|
+
expiry_notice: Liên kết đặt lại mật khẩu này sẽ sớm hết hạn. Nếu bạn không yêu cầu điều này, bạn không cần làm gì.
|
|
8
|
+
greeting: Chào %{name},
|
|
9
|
+
ignore_notice: Nếu bạn không yêu cầu đặt lại mật khẩu, bạn có thể yên tâm bỏ qua email này. Mật khẩu của bạn sẽ không bị thay đổi.
|
|
10
|
+
instructions: Chúng tôi đã nhận được yêu cầu đặt lại mật khẩu của bạn. Nhấp vào nút bên dưới để chọn mật khẩu mới.
|
|
11
|
+
newsletter_mailer:
|
|
12
|
+
email_confirmation:
|
|
13
|
+
dear_customer: Xin chào,
|
|
14
|
+
ignore_disclaimer: Nếu bạn không yêu cầu điều này, vui lòng bỏ qua email này.
|
|
15
|
+
instructions: Vui lòng nhấp vào nút bên dưới để xác minh địa chỉ email của bạn.
|
|
16
|
+
message_copy_link: 'Nếu nút không hoạt động, vui lòng sao chép và dán liên kết sau vào trình duyệt của bạn:'
|
|
17
|
+
subject: Xác minh địa chỉ email của bạn
|
|
18
|
+
verify_email_address_link: Xác minh địa chỉ email
|
|
19
|
+
order_mailer:
|
|
20
|
+
cancel_email:
|
|
21
|
+
instructions: Đơn đặt hàng của quý khách bị hủy. Vui lòng kiểm tra lại đơn hàng của bạn.
|
|
22
|
+
confirm_email:
|
|
23
|
+
instructions: Vui lòng kiểm tra đơn đặt hàng của bạn.
|
|
24
|
+
payment_link_email:
|
|
25
|
+
message: Vui lòng nhấp vào nút bên dưới để thanh toán cho đơn hàng của bạn.
|
|
26
|
+
message_copy_link: 'Nếu nút không hoạt động, vui lòng sao chép và dán liên kết sau vào trình duyệt của bạn:'
|
|
27
|
+
pay_for_order: Thanh toán đơn hàng
|
|
28
|
+
subject: 'Liên kết thanh toán cho đơn hàng #%{number}'
|
|
29
|
+
store_owner_notification_email:
|
|
30
|
+
heading: Đã nhận đơn hàng mới
|
|
31
|
+
instructions: Bạn đã nhận được một đơn hàng mới.
|
|
32
|
+
order_summary: Tóm tắt đơn hàng %{number}
|
|
33
|
+
subject: "%{store_name} đã nhận được một đơn hàng mới"
|
|
34
|
+
subtotal: 'Tạm tính:'
|
|
35
|
+
total: 'Tổng đơn hàng:'
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
---
|
|
2
|
+
zh-CN:
|
|
3
|
+
spree:
|
|
4
|
+
customer_mailer:
|
|
5
|
+
password_reset_email:
|
|
6
|
+
action: 重置密码
|
|
7
|
+
expiry_notice: 此密码重置链接将很快过期。如果这不是您本人的操作,则无需理会。
|
|
8
|
+
greeting: 您好,%{name}:
|
|
9
|
+
ignore_notice: 如果您没有请求重置密码,可以放心忽略此邮件。您的密码不会被更改。
|
|
10
|
+
instructions: 我们收到了重置您密码的请求。请点击下方按钮设置新密码。
|
|
11
|
+
subject: 密码重置说明
|
|
12
|
+
newsletter_mailer:
|
|
13
|
+
email_confirmation:
|
|
14
|
+
dear_customer: 您好,
|
|
15
|
+
ignore_disclaimer: 如果这不是您本人的请求,请忽略此邮件。
|
|
16
|
+
instructions: 请点击下方按钮验证您的电子邮箱地址。
|
|
17
|
+
message_copy_link: 如果按钮无法使用,请复制以下链接并粘贴到您的浏览器中:
|
|
18
|
+
subject: 验证您的电子邮箱地址
|
|
19
|
+
verify_email_address_link: 验证电子邮箱地址
|
|
20
|
+
order_mailer:
|
|
21
|
+
cancel_email:
|
|
22
|
+
instructions: 您的订单已被取消。请保留此取消信息记录。
|
|
23
|
+
subject: 取消订单
|
|
24
|
+
confirm_email:
|
|
25
|
+
instructions: 请仔细阅读并保留以下订单信息记录。
|
|
26
|
+
subject: 订单确认
|
|
27
|
+
payment_link_email:
|
|
28
|
+
message: 请点击下方按钮支付您的订单。
|
|
29
|
+
message_copy_link: 如果按钮无法使用,请复制以下链接并粘贴到您的浏览器中:
|
|
30
|
+
pay_for_order: 支付订单
|
|
31
|
+
subject: '订单 #%{number} 的支付链接'
|
|
32
|
+
store_owner_notification_email:
|
|
33
|
+
heading: 收到新订单
|
|
34
|
+
instructions: 您收到了一个新订单。
|
|
35
|
+
order_summary: 订单 %{number} 摘要
|
|
36
|
+
subject: "%{store_name} 收到一个新订单"
|
|
37
|
+
subtotal: 小计:
|
|
38
|
+
total: 订单总额:
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
---
|
|
2
|
+
zh-TW:
|
|
3
|
+
spree:
|
|
4
|
+
customer_mailer:
|
|
5
|
+
password_reset_email:
|
|
6
|
+
action: 重設密碼
|
|
7
|
+
expiry_notice: 此重設密碼連結將很快失效。若您並未提出此要求,則無需採取任何行動。
|
|
8
|
+
greeting: 您好 %{name},
|
|
9
|
+
ignore_notice: 若您並未要求重設密碼,可放心忽略此電子郵件。您的密碼不會被變更。
|
|
10
|
+
instructions: 我們收到了重設您密碼的要求。請點選下方按鈕設定新密碼。
|
|
11
|
+
subject: 密碼重設說明
|
|
12
|
+
newsletter_mailer:
|
|
13
|
+
email_confirmation:
|
|
14
|
+
dear_customer: 您好,
|
|
15
|
+
ignore_disclaimer: 若您並未提出此要求,請忽略此電子郵件。
|
|
16
|
+
instructions: 請點選下方按鈕以驗證您的電子郵件地址。
|
|
17
|
+
message_copy_link: 若按鈕無法運作,請複製並貼上以下連結至您的瀏覽器:
|
|
18
|
+
subject: 驗證您的電子郵件地址
|
|
19
|
+
verify_email_address_link: 驗證電子郵件地址
|
|
20
|
+
order_mailer:
|
|
21
|
+
cancel_email:
|
|
22
|
+
instructions: 你的訂單已取消。請你保留好此信件做為紀錄。
|
|
23
|
+
order_summary_canceled: 訂單編號 %{number} 總結 [CANCELED]
|
|
24
|
+
subject: 訂單取消
|
|
25
|
+
confirm_email:
|
|
26
|
+
instructions: 請你保留好此信件做為紀錄。
|
|
27
|
+
order_summary: 訂單編號 %{number} 總結
|
|
28
|
+
subject: 訂單確認信件
|
|
29
|
+
payment_link_email:
|
|
30
|
+
message: 請點選下方按鈕為您的訂單付款。
|
|
31
|
+
message_copy_link: 若按鈕無法運作,請複製並貼上以下連結至您的瀏覽器:
|
|
32
|
+
pay_for_order: 為訂單付款
|
|
33
|
+
subject: '訂單 #%{number} 的付款連結'
|
|
34
|
+
store_owner_notification_email:
|
|
35
|
+
heading: 新訂單
|
|
36
|
+
instructions: 一筆新訂單
|
|
37
|
+
order_summary: 訂單 %{number} 總結
|
|
38
|
+
subject: "%{store_name}收到了一筆新訂單"
|
|
39
|
+
subtotal: '小記:'
|
|
40
|
+
total: '總計:'
|
data/lib/spree/emails/engine.rb
CHANGED
|
@@ -6,9 +6,6 @@ module Spree
|
|
|
6
6
|
isolate_namespace Spree
|
|
7
7
|
engine_name 'spree_emails'
|
|
8
8
|
|
|
9
|
-
# Add app/subscribers to autoload paths
|
|
10
|
-
config.paths.add 'app/subscribers', eager_load: true
|
|
11
|
-
|
|
12
9
|
# Register bundled ActionMailer previews so they show up at /rails/mailers
|
|
13
10
|
# without the host app having to copy any files.
|
|
14
11
|
initializer 'spree_emails.mailer_previews' do |app|
|
|
@@ -17,6 +14,30 @@ module Spree
|
|
|
17
14
|
end
|
|
18
15
|
end
|
|
19
16
|
|
|
17
|
+
# The customer emails merchants may edit in the dashboard, with the layout
|
|
18
|
+
# and shared partials they are built from. Staff, store-owner and seller
|
|
19
|
+
# emails are deliberately not registered.
|
|
20
|
+
initializer 'spree_emails.editable_templates' do
|
|
21
|
+
{
|
|
22
|
+
'spree/order_mailer/confirm_email' => 'Spree::Emails::Samples::Order',
|
|
23
|
+
'spree/order_mailer/cancel_email' => 'Spree::Emails::Samples::Order',
|
|
24
|
+
'spree/order_mailer/payment_link_email' => 'Spree::Emails::Samples::PaymentLink',
|
|
25
|
+
'spree/order_group_mailer/confirm_email' => 'Spree::Emails::Samples::OrderGroup',
|
|
26
|
+
'spree/fulfillment_mailer/fulfilled_email' => 'Spree::Emails::Samples::Fulfillment',
|
|
27
|
+
'spree/return_mailer/refunded_email' => 'Spree::Emails::Samples::Return',
|
|
28
|
+
'spree/digital_asset_mailer/files_ready_email' => 'Spree::Emails::Samples::Downloads',
|
|
29
|
+
'spree/customer_mailer/password_reset_email' => 'Spree::Emails::Samples::PasswordReset',
|
|
30
|
+
'spree/customer_mailer/data_export_email' => 'Spree::Emails::Samples::DataExport',
|
|
31
|
+
'spree/newsletter_mailer/email_confirmation' => 'Spree::Emails::Samples::NewsletterConfirmation',
|
|
32
|
+
'spree/company_mailer/invitation_email' => 'Spree::Emails::Samples::CompanyInvitation'
|
|
33
|
+
}.each { |key, sample| Spree.editable_email_templates.register(key, kind: :email, sample: sample) }
|
|
34
|
+
|
|
35
|
+
Spree.editable_email_templates.register('layouts/spree/base_mailer', kind: :layout)
|
|
36
|
+
%w[line_item order_summary purchase_totals fulfillment_group summary_row].each do |partial|
|
|
37
|
+
Spree.editable_email_templates.register("spree/shared/#{partial}", kind: :partial)
|
|
38
|
+
end
|
|
39
|
+
end
|
|
40
|
+
|
|
20
41
|
# Add email event subscribers
|
|
21
42
|
config.after_initialize do
|
|
22
43
|
Spree.subscribers.concat [
|
|
@@ -26,6 +47,9 @@ module Spree
|
|
|
26
47
|
Spree::ReturnEmailSubscriber,
|
|
27
48
|
Spree::NewsletterSubscriberEmailSubscriber,
|
|
28
49
|
Spree::CustomerEmailSubscriber,
|
|
50
|
+
Spree::DataRequestEmailSubscriber,
|
|
51
|
+
Spree::CompanyEmailSubscriber,
|
|
52
|
+
Spree::DigitalAssetEmailSubscriber,
|
|
29
53
|
Spree::SellerEmailSubscriber
|
|
30
54
|
]
|
|
31
55
|
end
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
require 'spree/core/previews/preview_data'
|
|
2
|
+
|
|
3
|
+
# Preview Spree company emails at /rails/mailers/spree/company
|
|
4
|
+
class Spree::CompanyPreview < ActionMailer::Preview
|
|
5
|
+
include Spree::PreviewData::LocaleParam
|
|
6
|
+
|
|
7
|
+
def invitation_email
|
|
8
|
+
Spree::CompanyMailer.invitation_email(Spree::CompanyInvitation.pending.last)
|
|
9
|
+
end
|
|
10
|
+
end
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
require 'spree/core/previews/preview_data'
|
|
2
|
+
|
|
3
|
+
# Preview Spree digital download emails at /rails/mailers/spree/digital_asset
|
|
4
|
+
class Spree::DigitalAssetPreview < ActionMailer::Preview
|
|
5
|
+
include Spree::PreviewData::LocaleParam
|
|
6
|
+
|
|
7
|
+
def files_ready_email
|
|
8
|
+
Spree::DigitalAssetMailer.files_ready_email(order)
|
|
9
|
+
end
|
|
10
|
+
|
|
11
|
+
private
|
|
12
|
+
|
|
13
|
+
# The most recent order with downloads, with its locale overridden in memory
|
|
14
|
+
# when the preview toolbar requests one (the change is never saved).
|
|
15
|
+
def order
|
|
16
|
+
order = Spree::Order.complete.joins(line_items: :digital_links).last
|
|
17
|
+
order.locale = locale if order && locale.present?
|
|
18
|
+
order
|
|
19
|
+
end
|
|
20
|
+
end
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: spree_emails
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 6.0.0.
|
|
4
|
+
version: 6.0.0.rc2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Sean Schofield
|
|
@@ -10,7 +10,7 @@ authors:
|
|
|
10
10
|
autorequire:
|
|
11
11
|
bindir: bin
|
|
12
12
|
cert_chain: []
|
|
13
|
-
date: 2026-
|
|
13
|
+
date: 2026-10-13 00:00:00.000000000 Z
|
|
14
14
|
dependencies:
|
|
15
15
|
- !ruby/object:Gem::Dependency
|
|
16
16
|
name: spree
|
|
@@ -18,14 +18,14 @@ dependencies:
|
|
|
18
18
|
requirements:
|
|
19
19
|
- - '='
|
|
20
20
|
- !ruby/object:Gem::Version
|
|
21
|
-
version: 6.0.0.
|
|
21
|
+
version: 6.0.0.rc2
|
|
22
22
|
type: :runtime
|
|
23
23
|
prerelease: false
|
|
24
24
|
version_requirements: !ruby/object:Gem::Requirement
|
|
25
25
|
requirements:
|
|
26
26
|
- - '='
|
|
27
27
|
- !ruby/object:Gem::Version
|
|
28
|
-
version: 6.0.0.
|
|
28
|
+
version: 6.0.0.rc2
|
|
29
29
|
- !ruby/object:Gem::Dependency
|
|
30
30
|
name: email_spec
|
|
31
31
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -50,10 +50,6 @@ files:
|
|
|
50
50
|
- LICENSE
|
|
51
51
|
- README.md
|
|
52
52
|
- Rakefile
|
|
53
|
-
- app/helpers/spree/base_helper.rb
|
|
54
|
-
- app/helpers/spree/digital_asset_helper.rb
|
|
55
|
-
- app/helpers/spree/fulfillment_helper.rb
|
|
56
|
-
- app/helpers/spree/mail_helper.rb
|
|
57
53
|
- app/mailers/spree/company_mailer.rb
|
|
58
54
|
- app/mailers/spree/customer_mailer.rb
|
|
59
55
|
- app/mailers/spree/digital_asset_mailer.rb
|
|
@@ -64,6 +60,44 @@ files:
|
|
|
64
60
|
- app/mailers/spree/return_mailer.rb
|
|
65
61
|
- app/mailers/spree/seller_mailer.rb
|
|
66
62
|
- app/mailers/spree/shipment_mailer.rb
|
|
63
|
+
- app/models/spree/emails/amount_line.rb
|
|
64
|
+
- app/serializers/spree/emails/address_serializer.rb
|
|
65
|
+
- app/serializers/spree/emails/amount_line_serializer.rb
|
|
66
|
+
- app/serializers/spree/emails/applied_promotion_serializer.rb
|
|
67
|
+
- app/serializers/spree/emails/customer_group_serializer.rb
|
|
68
|
+
- app/serializers/spree/emails/customer_serializer.rb
|
|
69
|
+
- app/serializers/spree/emails/delivery_method_serializer.rb
|
|
70
|
+
- app/serializers/spree/emails/delivery_rate_serializer.rb
|
|
71
|
+
- app/serializers/spree/emails/delivery_serializer.rb
|
|
72
|
+
- app/serializers/spree/emails/fee_serializer.rb
|
|
73
|
+
- app/serializers/spree/emails/freight_summary_serializer.rb
|
|
74
|
+
- app/serializers/spree/emails/fulfillment_group_serializer.rb
|
|
75
|
+
- app/serializers/spree/emails/fulfillment_serializer.rb
|
|
76
|
+
- app/serializers/spree/emails/gift_card_serializer.rb
|
|
77
|
+
- app/serializers/spree/emails/line_item_serializer.rb
|
|
78
|
+
- app/serializers/spree/emails/market_serializer.rb
|
|
79
|
+
- app/serializers/spree/emails/newsletter_subscriber_serializer.rb
|
|
80
|
+
- app/serializers/spree/emails/option_value_serializer.rb
|
|
81
|
+
- app/serializers/spree/emails/order_group_serializer.rb
|
|
82
|
+
- app/serializers/spree/emails/order_serializer.rb
|
|
83
|
+
- app/serializers/spree/emails/parcel_item_serializer.rb
|
|
84
|
+
- app/serializers/spree/emails/payment_method_serializer.rb
|
|
85
|
+
- app/serializers/spree/emails/payment_serializer.rb
|
|
86
|
+
- app/serializers/spree/emails/purchase_summary_attributes.rb
|
|
87
|
+
- app/serializers/spree/emails/purchased_item_attributes.rb
|
|
88
|
+
- app/serializers/spree/emails/return_serializer.rb
|
|
89
|
+
- app/serializers/spree/emails/stock_location_serializer.rb
|
|
90
|
+
- app/services/spree/emails/samples/base.rb
|
|
91
|
+
- app/services/spree/emails/samples/company_invitation.rb
|
|
92
|
+
- app/services/spree/emails/samples/data_export.rb
|
|
93
|
+
- app/services/spree/emails/samples/downloads.rb
|
|
94
|
+
- app/services/spree/emails/samples/fulfillment.rb
|
|
95
|
+
- app/services/spree/emails/samples/newsletter_confirmation.rb
|
|
96
|
+
- app/services/spree/emails/samples/order.rb
|
|
97
|
+
- app/services/spree/emails/samples/order_group.rb
|
|
98
|
+
- app/services/spree/emails/samples/password_reset.rb
|
|
99
|
+
- app/services/spree/emails/samples/payment_link.rb
|
|
100
|
+
- app/services/spree/emails/samples/return.rb
|
|
67
101
|
- app/subscribers/spree/company_email_subscriber.rb
|
|
68
102
|
- app/subscribers/spree/customer_email_subscriber.rb
|
|
69
103
|
- app/subscribers/spree/data_request_email_subscriber.rb
|
|
@@ -74,56 +108,77 @@ files:
|
|
|
74
108
|
- app/subscribers/spree/order_group_email_subscriber.rb
|
|
75
109
|
- app/subscribers/spree/return_email_subscriber.rb
|
|
76
110
|
- app/subscribers/spree/seller_email_subscriber.rb
|
|
77
|
-
- app/views/spree/company_mailer/invitation_email.
|
|
78
|
-
- app/views/spree/
|
|
79
|
-
- app/views/spree/customer_mailer/
|
|
80
|
-
- app/views/spree/
|
|
81
|
-
- app/views/spree/
|
|
82
|
-
- app/views/spree/
|
|
83
|
-
- app/views/spree/
|
|
84
|
-
- app/views/spree/
|
|
85
|
-
- app/views/spree/
|
|
86
|
-
- app/views/spree/
|
|
87
|
-
- app/views/spree/
|
|
88
|
-
- app/views/spree/
|
|
89
|
-
- app/views/spree/
|
|
90
|
-
- app/views/spree/
|
|
91
|
-
- app/views/spree/
|
|
92
|
-
- app/views/spree/
|
|
93
|
-
- app/views/spree/
|
|
94
|
-
- app/views/spree/
|
|
95
|
-
- app/views/spree/
|
|
96
|
-
- app/views/spree/
|
|
97
|
-
-
|
|
98
|
-
-
|
|
99
|
-
-
|
|
100
|
-
-
|
|
101
|
-
-
|
|
102
|
-
-
|
|
103
|
-
-
|
|
104
|
-
-
|
|
105
|
-
-
|
|
106
|
-
-
|
|
107
|
-
- app/views/spree/seller_mailer/suspended_email.text.erb
|
|
108
|
-
- app/views/spree/shared/_fulfillment_group_section.html.erb
|
|
109
|
-
- app/views/spree/shared/_fulfillment_group_section.text.erb
|
|
110
|
-
- app/views/spree/shared/_item_thumbnail_link.html.erb
|
|
111
|
-
- app/views/spree/shared/_order_summary_section.html.erb
|
|
112
|
-
- app/views/spree/shared/_po_number.text.erb
|
|
113
|
-
- app/views/spree/shared/_purchase_totals.html.erb
|
|
114
|
-
- app/views/spree/shared/_purchase_totals.text.erb
|
|
115
|
-
- app/views/spree/shared/_purchased_items_table.html.erb
|
|
116
|
-
- app/views/spree/shared/_purchased_items_table.text.erb
|
|
117
|
-
- app/views/spree/shared/purchased_items_table/_line_item.html.erb
|
|
118
|
-
- app/views/spree/shared/purchased_items_table/_subtotal.html.erb
|
|
119
|
-
- app/views/spree/shared/purchased_items_table/_summary_row.html.erb
|
|
120
|
-
- app/views/spree/shared/purchased_items_table/_total.html.erb
|
|
121
|
-
- config/i18n-tasks.yml
|
|
111
|
+
- app/views/spree/company_mailer/invitation_email.liquid
|
|
112
|
+
- app/views/spree/customer_mailer/data_export_email.liquid
|
|
113
|
+
- app/views/spree/customer_mailer/password_reset_email.liquid
|
|
114
|
+
- app/views/spree/digital_asset_mailer/files_ready_email.liquid
|
|
115
|
+
- app/views/spree/fulfillment_mailer/fulfilled_email.liquid
|
|
116
|
+
- app/views/spree/newsletter_mailer/email_confirmation.liquid
|
|
117
|
+
- app/views/spree/order_group_mailer/confirm_email.liquid
|
|
118
|
+
- app/views/spree/order_group_mailer/store_owner_notification_email.liquid
|
|
119
|
+
- app/views/spree/order_mailer/cancel_email.liquid
|
|
120
|
+
- app/views/spree/order_mailer/confirm_email.liquid
|
|
121
|
+
- app/views/spree/order_mailer/payment_link_email.liquid
|
|
122
|
+
- app/views/spree/order_mailer/store_owner_notification_email.liquid
|
|
123
|
+
- app/views/spree/return_mailer/refunded_email.liquid
|
|
124
|
+
- app/views/spree/seller_mailer/approved_email.liquid
|
|
125
|
+
- app/views/spree/seller_mailer/rejected_email.liquid
|
|
126
|
+
- app/views/spree/seller_mailer/suspended_email.liquid
|
|
127
|
+
- app/views/spree/shared/_fulfillment_group.liquid
|
|
128
|
+
- app/views/spree/shared/_line_item.liquid
|
|
129
|
+
- app/views/spree/shared/_order_summary.liquid
|
|
130
|
+
- app/views/spree/shared/_purchase_totals.liquid
|
|
131
|
+
- config/initializers/typelizer.rb
|
|
132
|
+
- config/locales/ar.yml
|
|
133
|
+
- config/locales/be.yml
|
|
134
|
+
- config/locales/bg.yml
|
|
135
|
+
- config/locales/ca.yml
|
|
136
|
+
- config/locales/cs.yml
|
|
137
|
+
- config/locales/da.yml
|
|
138
|
+
- config/locales/de-CH.yml
|
|
139
|
+
- config/locales/de.yml
|
|
140
|
+
- config/locales/el.yml
|
|
122
141
|
- config/locales/en.yml
|
|
142
|
+
- config/locales/es-CL.yml
|
|
143
|
+
- config/locales/es-EC.yml
|
|
144
|
+
- config/locales/es-MX.yml
|
|
145
|
+
- config/locales/es.yml
|
|
146
|
+
- config/locales/et.yml
|
|
147
|
+
- config/locales/fa.yml
|
|
148
|
+
- config/locales/fi.yml
|
|
149
|
+
- config/locales/fr.yml
|
|
150
|
+
- config/locales/hu.yml
|
|
151
|
+
- config/locales/id.yml
|
|
152
|
+
- config/locales/it.yml
|
|
153
|
+
- config/locales/ja.yml
|
|
154
|
+
- config/locales/km.yml
|
|
155
|
+
- config/locales/ko.yml
|
|
156
|
+
- config/locales/ku.yml
|
|
157
|
+
- config/locales/lt.yml
|
|
158
|
+
- config/locales/lv.yml
|
|
159
|
+
- config/locales/nb.yml
|
|
160
|
+
- config/locales/ne.yml
|
|
161
|
+
- config/locales/nl.yml
|
|
162
|
+
- config/locales/pl.yml
|
|
163
|
+
- config/locales/pt-BR.yml
|
|
164
|
+
- config/locales/pt.yml
|
|
165
|
+
- config/locales/ro.yml
|
|
166
|
+
- config/locales/ru.yml
|
|
167
|
+
- config/locales/sk.yml
|
|
168
|
+
- config/locales/sl-SI.yml
|
|
169
|
+
- config/locales/sv.yml
|
|
170
|
+
- config/locales/th.yml
|
|
171
|
+
- config/locales/tr.yml
|
|
172
|
+
- config/locales/uk.yml
|
|
173
|
+
- config/locales/vi.yml
|
|
174
|
+
- config/locales/zh-CN.yml
|
|
175
|
+
- config/locales/zh-TW.yml
|
|
123
176
|
- lib/generators/spree/emails/install/install_generator.rb
|
|
124
177
|
- lib/spree/emails.rb
|
|
125
178
|
- lib/spree/emails/engine.rb
|
|
179
|
+
- lib/spree/emails/previews/company_preview.rb
|
|
126
180
|
- lib/spree/emails/previews/customer_preview.rb
|
|
181
|
+
- lib/spree/emails/previews/digital_asset_preview.rb
|
|
127
182
|
- lib/spree/emails/previews/fulfillment_preview.rb
|
|
128
183
|
- lib/spree/emails/previews/newsletter_preview.rb
|
|
129
184
|
- lib/spree/emails/previews/order_group_preview.rb
|
|
@@ -135,9 +190,9 @@ licenses:
|
|
|
135
190
|
- BSD-3-Clause
|
|
136
191
|
metadata:
|
|
137
192
|
bug_tracker_uri: https://github.com/spree/spree/issues
|
|
138
|
-
changelog_uri: https://github.com/spree/spree/releases/tag/v6.0.0.
|
|
193
|
+
changelog_uri: https://github.com/spree/spree/releases/tag/v6.0.0.rc2
|
|
139
194
|
documentation_uri: https://docs.spreecommerce.org/
|
|
140
|
-
source_code_uri: https://github.com/spree/spree/tree/v6.0.0.
|
|
195
|
+
source_code_uri: https://github.com/spree/spree/tree/v6.0.0.rc2
|
|
141
196
|
post_install_message:
|
|
142
197
|
rdoc_options: []
|
|
143
198
|
require_paths:
|
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
module Spree
|
|
2
|
-
module BaseHelper
|
|
3
|
-
# returns the URL of an object on the storefront
|
|
4
|
-
# @param resource [Spree::Product, Spree::Category] the resource to get the URL for
|
|
5
|
-
# @param options [Hash] the options for the URL
|
|
6
|
-
# @option options [String] :locale the locale of the resource, defaults to I18n.locale
|
|
7
|
-
# @option options [String] :store the store of the resource, defaults to current_store
|
|
8
|
-
# @option options [String] :relative whether to use the relative URL, defaults to false
|
|
9
|
-
# @option options [String] :preview_id the preview ID of the resource, usually the ID of the resource
|
|
10
|
-
# @option options [String] :variant_id the variant ID of the resource, usually the ID of the variant (only used for products)
|
|
11
|
-
# @return [String] the URL of the resource
|
|
12
|
-
def spree_storefront_resource_url(resource, options = {})
|
|
13
|
-
store = options[:store] || current_store
|
|
14
|
-
|
|
15
|
-
base_url = if options[:relative]
|
|
16
|
-
''
|
|
17
|
-
else
|
|
18
|
-
store.storefront_url
|
|
19
|
-
end
|
|
20
|
-
|
|
21
|
-
localize = if options[:locale].present?
|
|
22
|
-
"/#{options[:locale]}"
|
|
23
|
-
else
|
|
24
|
-
''
|
|
25
|
-
end
|
|
26
|
-
|
|
27
|
-
if resource.instance_of?(Spree::Product)
|
|
28
|
-
preview_id = ("preview_id=#{options[:preview_id]}" if options[:preview_id].present?)
|
|
29
|
-
|
|
30
|
-
variant_id = ("variant_id=#{options[:variant_id]}" if options[:variant_id].present?)
|
|
31
|
-
|
|
32
|
-
params = [preview_id, variant_id].compact_blank.join('&')
|
|
33
|
-
params = "?#{params}" if params.present?
|
|
34
|
-
|
|
35
|
-
"#{base_url + localize}/products/#{resource.slug}#{params}"
|
|
36
|
-
elsif resource.is_a?(Spree::Category)
|
|
37
|
-
"#{base_url + localize}/t/#{resource.permalink}"
|
|
38
|
-
elsif localize.blank?
|
|
39
|
-
base_url
|
|
40
|
-
else
|
|
41
|
-
base_url + localize
|
|
42
|
-
end
|
|
43
|
-
end
|
|
44
|
-
end
|
|
45
|
-
end
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
module Spree
|
|
2
|
-
module DigitalAssetHelper
|
|
3
|
-
# Emails need an absolute link — the route helper only produces a path, and
|
|
4
|
-
# the download endpoint lives on the backend rather than the storefront.
|
|
5
|
-
#
|
|
6
|
-
# The host is passed in rather than resolved per link: every link in one
|
|
7
|
-
# email belongs to the same order, so its store is already known.
|
|
8
|
-
#
|
|
9
|
-
# @param digital_link [Spree::DigitalLink]
|
|
10
|
-
# @param host [String] the backend's own URL
|
|
11
|
-
# @return [String]
|
|
12
|
-
def digital_link_download_url(digital_link, host)
|
|
13
|
-
Spree::Api::DigitalLinkUrls.download_url(digital_link, host)
|
|
14
|
-
end
|
|
15
|
-
end
|
|
16
|
-
end
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
module Spree
|
|
2
|
-
module FulfillmentHelper
|
|
3
|
-
def fulfillment_tracking_link_to(fulfillment:, name: nil, html_options: {})
|
|
4
|
-
tracking_url = fulfillment.tracking_url.presence
|
|
5
|
-
return '' unless tracking_url
|
|
6
|
-
|
|
7
|
-
display_text = name || fulfillment.tracking.presence || tracking_url
|
|
8
|
-
|
|
9
|
-
link_to display_text, tracking_url, html_options
|
|
10
|
-
end
|
|
11
|
-
end
|
|
12
|
-
end
|