From 60c859810ecb7ba9577405b6952a40ec61eae57c Mon Sep 17 00:00:00 2001 From: ismail Akbudak Date: Tue, 21 Jun 2016 10:18:44 +0300 Subject: [PATCH] add email locale file and improve content of locale files --- lib/cybele/app_builder.rb | 8 ++- templates/config/locales/email.tr.yml | 28 +++++++++ templates/config/locales/en.yml | 2 - templates/config/locales/models.en.yml | 54 ---------------- templates/config/locales/models.tr.yml | 2 +- templates/config/locales/responders.en.yml | 10 --- templates/config/locales/responders.tr.yml | 2 +- templates/config/locales/show_for.en.yml | 7 --- templates/config/locales/show_for.tr.yml | 2 +- templates/config/locales/simple_form.en.yml | 30 --------- templates/config/locales/simple_form.tr.yml | 2 +- templates/config/locales/tr.yml | 35 ++++++++++- templates/config/locales/view.en.yml | 51 --------------- templates/config/locales/view.tr.yml | 69 ++++++++++++++++----- 14 files changed, 124 insertions(+), 178 deletions(-) create mode 100644 templates/config/locales/email.tr.yml delete mode 100644 templates/config/locales/en.yml delete mode 100644 templates/config/locales/models.en.yml delete mode 100644 templates/config/locales/responders.en.yml delete mode 100644 templates/config/locales/show_for.en.yml delete mode 100644 templates/config/locales/simple_form.en.yml delete mode 100644 templates/config/locales/view.en.yml diff --git a/lib/cybele/app_builder.rb b/lib/cybele/app_builder.rb index ee470a8..d50e460 100644 --- a/lib/cybele/app_builder.rb +++ b/lib/cybele/app_builder.rb @@ -46,8 +46,8 @@ def install_responder_gem copy_file 'app/controllers/application_controller.rb', 'app/controllers/application_controller.rb' copy_file 'app/controllers/concerns/basic_authentication.rb', 'app/controllers/concerns/basic_authentication.rb' copy_file 'lib/templates/rails/responders_controller/controller.rb', 'lib/templates/rails/responders_controller/controller.rb' - copy_file 'config/locales/responders.en.yml', 'config/locales/responders.en.yml' copy_file 'config/locales/responders.tr.yml', 'config/locales/responders.tr.yml' + copy_file 'config/locales/email.tr.yml', 'config/locales/email.tr.yml' end def replace_database_yml @@ -85,6 +85,12 @@ def setup_asset_precompile config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s] config.assets.precompile += %w(*.png *.jpg *.jpeg *.gif) config.sass.preferred_syntax = :sass + config.i18n.default_locale = :tr + config.time_zone = 'Istanbul' + config.i18n.fallbacks = true + config.active_job.queue_adapter = :sidekiq + # Do not swallow errors in after_commit/after_rollback callbacks. + config.active_record.raise_in_transactional_callbacks = true RUBY inject_into_file 'config/application.rb', config, :after => '# config.i18n.default_locale = :de' diff --git a/templates/config/locales/email.tr.yml b/templates/config/locales/email.tr.yml new file mode 100644 index 0000000..90c3e02 --- /dev/null +++ b/templates/config/locales/email.tr.yml @@ -0,0 +1,28 @@ +--- +tr: + email: + salut: 'Merhaba %{user};' + hello: 'Merhaba;' + devise: + confirmation_instruction: + desc1: E-posta adresinizi aşağıdaki link ile doğrulayabilirsiniz + btn_confirm: Hesabımı doğrula + reset_password: + desc1: Parolanızı değiştirmek için link isteğinde bulundunuz. Aşağıdaki link ile bunu yapabilirsiniz. + change: Parolamı değiştir + desc2: Eğer bu isteği siz yapmadıysanız bu e-posta'yı yok sayınız. + desc3: Parolanız yukarıdaki link'e erişip yeni bir parola oluşturmadığınız sürece değişmeyecektir. + admin: + send_login_information: + title: Yönetici Giriş Bilgileriniz + first_info: Portal üzerinden yönetici hesabınız oluşturuldu. Artık yönetici portalına giriş yapabilirsiniz. + second_info: Giriş bilgileriniz şu şekildedir + btn_login: Giriş yapmak için tıklayınız + last_info: "Eğer 'Giriş Yap' butonunu kullanamıyorsanız giriş linkiniz şu şekildedir
Link : %{link}
Bu linki kopyalayıp tarayıcınıza yapıştırınız.." + user: + send_login_information: + title: Kullanıcı Giriş Bilgileriniz + first_info: Portal üzerinden kullanıcı hesabınız oluşturuldu. Artık kullanıcı portalına giriş yapabilirsiniz. + second_info: Giriş bilgileriniz şu şekildedir + btn_login: Giriş yapmak için tıklayınız + last_info: "Eğer 'Giriş Yap' butonunu kullanamıyorsanız giriş linkiniz şu şekildedir
Link : %{link}
Bu linki kopyalayıp tarayıcınıza yapıştırınız.." diff --git a/templates/config/locales/en.yml b/templates/config/locales/en.yml deleted file mode 100644 index ae09dd9..0000000 --- a/templates/config/locales/en.yml +++ /dev/null @@ -1,2 +0,0 @@ -en: - hello: "Hello world" \ No newline at end of file diff --git a/templates/config/locales/models.en.yml b/templates/config/locales/models.en.yml deleted file mode 100644 index 0b1bc82..0000000 --- a/templates/config/locales/models.en.yml +++ /dev/null @@ -1,54 +0,0 @@ -en: - activerecord: - models: - schemamigration: Schemamigration - user: User - user_profiles: User Profile - admin: Admin - admin_profiles: Admin Profile - attributes: - user: - id: Id - email: Email - password: Password - password_confirmation: Password Confirmation - current_password: Current Password - encrypted_password: Encrypted_password - reset_password_token: Reset_password_token - reset_password_sent_at: Reset_password_sent_at - remember_created_at: Remember_created_at - sign_in_count: Sign_in_count - current_sign_in_at: Current_sign_in_at - last_sign_in_at: Last_sign_in_at - current_sign_in_ip: Current_sign_in_ip - last_sign_in_ip: Last_sign_in_ip - active: Active - created_at: Created_at - updated_at: Updated_at - active: Active - user_profile: - first_name: Name - last_name: Surname - gsm: Phone - admin: - id: Id - email: Email - password: Password - password_confirmation: Password Confirmation - current_password: Current Password - encrypted_password: Encrypted_password - reset_password_token: Reset_password_token - reset_password_sent_at: Reset_password_sent_at - remember_created_at: Remember_created_at - sign_in_count: Sign_in_count - current_sign_in_at: Current_sign_in_at - last_sign_in_at: Last_sign_in_at - current_sign_in_ip: Current_sign_in_ip - last_sign_in_ip: Last_sign_in_ip - created_at: Created_at - updated_at: Updated_at - active: Active - admin_profile: - first_name: Name - last_name: Surname - gsm: Phone \ No newline at end of file diff --git a/templates/config/locales/models.tr.yml b/templates/config/locales/models.tr.yml index 310f3de..30bc1b4 100644 --- a/templates/config/locales/models.tr.yml +++ b/templates/config/locales/models.tr.yml @@ -1,4 +1,4 @@ -# encoding: utf-8 +--- tr: activerecord: models: diff --git a/templates/config/locales/responders.en.yml b/templates/config/locales/responders.en.yml deleted file mode 100644 index 4e5bf47..0000000 --- a/templates/config/locales/responders.en.yml +++ /dev/null @@ -1,10 +0,0 @@ -en: - flash: - actions: - create: - notice: '%{resource_name} was successfully created.' - update: - notice: '%{resource_name} was successfully updated.' - destroy: - notice: '%{resource_name} was successfully destroyed.' - alert: '%{resource_name} could not be destroyed.' \ No newline at end of file diff --git a/templates/config/locales/responders.tr.yml b/templates/config/locales/responders.tr.yml index ae8fbf9..86aaa32 100644 --- a/templates/config/locales/responders.tr.yml +++ b/templates/config/locales/responders.tr.yml @@ -1,4 +1,4 @@ -# encoding: utf-8 +--- tr: flash: actions: diff --git a/templates/config/locales/show_for.en.yml b/templates/config/locales/show_for.en.yml deleted file mode 100644 index ed08650..0000000 --- a/templates/config/locales/show_for.en.yml +++ /dev/null @@ -1,7 +0,0 @@ -en: - show_for: - blank: "Not specified" - # If you want to use html tags with blank value use blank html translation - # blank_html: "Not specified" - "yes": "Yes" - "no": "No" \ No newline at end of file diff --git a/templates/config/locales/show_for.tr.yml b/templates/config/locales/show_for.tr.yml index 8cf8697..94fdcfd 100644 --- a/templates/config/locales/show_for.tr.yml +++ b/templates/config/locales/show_for.tr.yml @@ -1,4 +1,4 @@ -# encoding: utf-8 +--- tr: show_for: blank: "Belirtilmedi" diff --git a/templates/config/locales/simple_form.en.yml b/templates/config/locales/simple_form.en.yml deleted file mode 100644 index f07eb3e..0000000 --- a/templates/config/locales/simple_form.en.yml +++ /dev/null @@ -1,30 +0,0 @@ -en: - simple_form: - "yes": 'Yes' - "no": 'No' - required: - text: 'required' - mark: '*' - # You can uncomment the line below if you need to overwrite the whole required html. - # When using html, text and mark won't be used. - # html: '*' - error_notification: - default_message: "Please review the problems below:" - # Labels and hints examples - # labels: - # defaults: - # password: 'Password' - # user: - # new: - # email: 'E-mail to sign in.' - # edit: - # email: 'E-mail.' - # hints: - # defaults: - # username: 'User name to sign in.' - # password: 'No special characters, please.' - # user: - # new: - # email: 'E-mail to sign in.' - # edit: - # email: 'E-mail.' \ No newline at end of file diff --git a/templates/config/locales/simple_form.tr.yml b/templates/config/locales/simple_form.tr.yml index 95389d0..5545d26 100644 --- a/templates/config/locales/simple_form.tr.yml +++ b/templates/config/locales/simple_form.tr.yml @@ -1,4 +1,4 @@ -# encoding: utf-8 +--- tr: simple_form: "yes": 'Evet' diff --git a/templates/config/locales/tr.yml b/templates/config/locales/tr.yml index 2ebb62c..a135f80 100644 --- a/templates/config/locales/tr.yml +++ b/templates/config/locales/tr.yml @@ -1,3 +1,34 @@ -# encoding: utf-8 +--- tr: - hello: "Hello world" \ No newline at end of file + phone: + formats: + long: '+99 (999) 999-9999' + date: + formats: + excel: + rails: '%d/%m/%Y' + datepicker: + rails: '%d/%m/%Y' + js: 'd/m/Y' + default: "%d/%m/%Y" + year_month: "%Y-%B" + date: '%d %B %Y' + time: + formats: + certificate_completed_at_english: '%m/%d/%Y' + certificate_completed_at: '%d/%m/%Y' + datetimepicker_rails: '%d/%m/%Y %H:%M' + datetimepicker: + rails: '%d/%m/%Y %H:%M' + js: 'd/m/Y H:i' + default: "%d/%m/%Y %H:%M" + year_month: "%Y-%B" + date: '%d %B %Y' + due_at: + rails: '%d/%m/%Y %H:%M' + js: 'd/m/Y H:i' + number: + currency: + format: + format: "%u %n" + unit: "₺" \ No newline at end of file diff --git a/templates/config/locales/view.en.yml b/templates/config/locales/view.en.yml deleted file mode 100644 index 209eb26..0000000 --- a/templates/config/locales/view.en.yml +++ /dev/null @@ -1,51 +0,0 @@ -en: - btn: - back: Back - update: Update - view: - select: Please choose! - navbar: - settings: Settings - signout: Sign Out - signin: Sign In - dock: - dashboard: Dashboard - number: - currency: - format: - format: "%u %n" - unit: "₺" - internal_server_error: "Sory! Error an occurred.." - not_found: "Sory! Page not found. This page should be moved!" - devise: - session: - title: Login - button: Login - remember_me: Remember Me - registration: - title: '%{model} Update Login Information' - waiting_confirmation: 'Currently waiting confirmation for: %{email}' - hint_password: Leave it blank if you don't want to change it - hint_current_password: We need your current password to confirm your changes - new: - title: '%{model} New Registration' - character_hint: '%{length} characters minimum' - button: Register - shared: - links: - signup: Sign Up - signin: Sign In - forgot_password: Forgot your password? - confirmation_instructions: Didn't receive confirmation instructions? - unlock_instructions: Didn't receive unlock instructions? - signin_with: 'Sign in with %{name}' - signin_with: 'Sign up with %{name}' - password: - reset: - title: Forgot Your Password? - instructions: Send my password reset instructions - edit: - title: Change Your Password - new_password: New password - confirmation: New password confirmation - button: Change My Password \ No newline at end of file diff --git a/templates/config/locales/view.tr.yml b/templates/config/locales/view.tr.yml index 4d842b9..b476a62 100644 --- a/templates/config/locales/view.tr.yml +++ b/templates/config/locales/view.tr.yml @@ -1,21 +1,47 @@ -# encoding: utf-8 +--- tr: btn: back: Geri update: Güncelle view: - select: Lütfen seçiniz! + excel_export: Excel Olarak Çıkart + make_passive: Pasif et + make_active: Aktif et + actions: İşlemler + select: Seçiniz + active: Aktif + passive: Pasif + start: Başlangıç + end: Bitiş + used: Kullanılan + not_used: Kullanılmayan + cancel: İptal et + all: Hepsi + reset: Temizle + quick_search: Arama yap.. + reload: Yeniden yükle + there_is_no_data: Hiç %{resource} eklenmemiş. navbar: settings: Ayarlar - signout: Çıkış signin: Giriş Yap + sign_out: Çıkış yap + edit_login_info: Giriş bilgilerini güncelle + tooltips: + delete: Sil + are_you_sure: Devam etmek istedğinize emin misiniz? + choose: Seç + btn: + add: Ekle + update: Güncelle + back: Geri + detail: Detaylar + delete: Sil dock: - dashboard: Kontrol Paneli - number: - currency: - format: - format: "%u %n" - unit: "₺" + dashboard: Kontrol Paneli + dashboard: Kontrol paneli + profile: Profil + system_users: Sistem kullanıcıları + system_datas: Sistem verileri internal_server_error: "Üzgünüz. Şu anda bir hata var. Mühendislerimiz bu hata üzerinde çalışma yapıyorlar. En kısa sürede çözeceğiz." not_found: "Üzgünüz. Bu sayfa bulunamadı. Taşınmış olabilir. Buraya gitmek istediğinizden emin olun." devise: @@ -23,30 +49,39 @@ tr: title: '%{model} Girişi' button: Giriş Yap remember_me: Beni Hatırla + deactivated: Üzgünüz, bu hesap pasif hale getirilmiştir. registration: title: '%{model} Giriş Bilgilerini Güncelle' waiting_confirmation: 'E-posta addresi onayı için bekleniyor: %{email}' hint_password: Değiştirmek istemiyorsanız boş bırakınız - hint_current_password: Değişiklikleri onaylamak için şuan ki şifrenizi girmelisiniz + hint_current_password: Değişiklikleri onaylamak için şuan ki parolanız girmelisiniz new: title: '%{model} Kayıt İşlemi' character_hint: 'Minimum %{length} karakter' button: Kayıt Ol + edit: + title: '%{model} Giriş Bilgilerini Güncelle' shared: links: signup: Kayıt Ol signin: Giriş Yap - forgot_password: Şifrenizi mi unuttunuz? + forgot_password: Parolanızı mı unuttunuz? confirmation_instructions: Onaylama yönergesini mi almadınız? unlock_instructions: Kapatma yönergesini mi almadınız? signin_with: '%{name} ile Giriş Yap' signup_with: '%{name} ile Kayıt Ol' + confirmation: + new: + title: Onaylama Talimatlarını Yeniden Gönder + btn: + resend: Gönder password: + new: + title: Parolanızı mı unuttunuz? reset: - title: Şifrenizi mi unuttunuz? - instructions: Şifre sıfırlama talimatlarını gönder + instructions: Parola sıfırlama talimatlarını gönder edit: - title: Şifrenizi Değiştriniz - new_password: Yeni şifre - confirmation: Yeni şifre doğrulması - button: Şifremi Değiştir \ No newline at end of file + title: Parolanızı Değiştiriniz + new_password: Yeni parolanız + confirmation: Yeni parola doğrulması + button: Parolamı Değiştir \ No newline at end of file