padrino-admin 0.11.1 → 0.11.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -46,6 +46,14 @@ class Account < Ohm::Model
46
46
  self[id]
47
47
  end
48
48
 
49
+ ##
50
+ # This method is used by Admin Sessions Controller for login bypass
51
+ #
52
+ def self.first
53
+ first_id = key[:all].sort(:order => "asc", :limit => [0,1]).first
54
+ self[first_id] if first_id
55
+ end
56
+
49
57
  def has_password?(password)
50
58
  ::BCrypt::Password.new(crypted_password) == password
51
59
  end
@@ -37,7 +37,7 @@
37
37
  </div>
38
38
  </th>
39
39
  <% @orm.columns.each_with_index do |column, i| -%>
40
- <th class=header> <%%= :<%= column.name %> %></th>
40
+ <th class=header> <%%= mat(:<%= @orm.name_singular %>, :<%= column.name %>) %></th>
41
41
  <% end -%>
42
42
  <th class="header list-row-action-header"></th>
43
43
  </thead>
@@ -27,7 +27,7 @@
27
27
  =submit_tag pat(:delete), :class =>'list-menu-popover-delete-selected-btn btn btn-danger btn-small'
28
28
  .btn.btn-small.cancel=pat(:cancel)
29
29
  <%- @orm.columns.each_with_index do |column, i| -%>
30
- %th.header= :<%= column.name %>
30
+ %th.header= mat(:<%= @orm.name_singular %>, :<%= column.name %>)
31
31
  <%- end -%>
32
32
  %th.header.list-row-action-header
33
33
 
@@ -26,7 +26,7 @@ div class="tabs-content"
26
26
  = submit_tag pat(:delete), :class =>'list-menu-popover-delete-selected-btn btn btn-danger btn-small'
27
27
  div class='btn btn-small cancel' = pat(:cancel)
28
28
  <%- @orm.columns.each_with_index do |column, i| -%>
29
- th class='header' = :<%= column.name %>
29
+ th class='header' = mat(:<%= @orm.name_singular %>, :<%= column.name %>)
30
30
  <%- end -%>
31
31
  th class='header list-row-action-header'
32
32
 
@@ -5,9 +5,9 @@ ja:
5
5
  title: "ログイン"
6
6
  email: "メール"
7
7
  password: "パスワード"
8
- bypass: "ログインをバイパス?"
9
- sign_in: "にサインイン"
10
- error: "電子メールやパスワードが間違っています."
8
+ bypass: "ログインを省略する"
9
+ sign_in: "ログイン"
10
+ error: "メールアドレスかパスワードが間違っています."
11
11
  save: "保存"
12
12
  save_and_continue: "保存して続行"
13
13
  cancel: "キャンセル"
@@ -21,7 +21,7 @@ ja:
21
21
  all: "すべて"
22
22
  profile: "プロフィールの編集"
23
23
  settings: "設定"
24
- logout: "管理ページを終了します"
24
+ logout: "ログアウト"
25
25
  login_error: "メールアドレスかパスワードが間違っています。"
26
26
  select_all: "すべて選択"
27
27
  deselect_all: "すべて選択解除"
@@ -12,7 +12,7 @@ ru:
12
12
  save_and_continue: "Сохранить и продолжить"
13
13
  cancel: "Отмена"
14
14
  list: "Список"
15
- edit: "Edit"
15
+ edit: "Редактировать"
16
16
  new: "Новый"
17
17
  show: "Показать"
18
18
  delete: "Удалить"
@@ -24,3 +24,14 @@ cs:
24
24
  record_invalid: "Následující pole obsahují chybně vyplněné údaje: %{errors}"
25
25
  content_type: "nepodporovaný formát souboru"
26
26
  #activerecord: *activemodel
27
+ ohm:
28
+ errors:
29
+ messages:
30
+ format: "není platná hodnota"
31
+ not_present: "je povinná položka"
32
+ not_numeric: "není číslo"
33
+ not_url: "není platná hodnota"
34
+ not_email: "není platná hodnota"
35
+ not_valid: "není v seznamu povolených hodnot"
36
+ not_in_range: "není v seznamu povolených hodnot"
37
+ not_decimal: "není platná hodnota"
@@ -24,3 +24,14 @@ da:
24
24
  record_invalid: "Valideringsfejl: %{errors}"
25
25
  content_type: "fileformatet er ikke understøttet"
26
26
  activerecord: *activemodel
27
+ ohm:
28
+ errors:
29
+ messages:
30
+ format: "er ikke gyldig"
31
+ not_present: "må ikke være blank"
32
+ not_numeric: "er ikke et tal"
33
+ not_url: "er ikke gyldig"
34
+ not_email: "er ikke gyldig"
35
+ not_valid: "findes ikke i listen"
36
+ not_in_range: "findes ikke i listen"
37
+ not_decimal: "er ikke gyldig"
@@ -24,3 +24,14 @@ de:
24
24
  record_invalid: "Validierung schlug fehl: %{errors}"
25
25
  content_type: "Datei-Format wird nicht unterstützt"
26
26
  activerecord: *activemodel
27
+ ohm:
28
+ errors:
29
+ messages:
30
+ format: "ist ungültig"
31
+ not_present: "Darf nicht nur Leerzeichen enthalten"
32
+ not_numeric: "ist keine Nummer"
33
+ not_url: "ist ungültig"
34
+ not_email: "ist ungültig"
35
+ not_valid: "ist nicht in der Liste enthalten"
36
+ not_in_range: "ist nicht in der Liste enthalten"
37
+ not_decimal: "ist ungültig"
@@ -24,3 +24,14 @@ en:
24
24
  record_invalid: "Validation failed: %{errors}"
25
25
  content_type: "file format not supported"
26
26
  activerecord: *activemodel
27
+ ohm:
28
+ errors:
29
+ messages:
30
+ format: "is invalid"
31
+ not_present: "can't be blank"
32
+ not_numeric: "is not a number"
33
+ not_url: "is invalid"
34
+ not_email: "is invalid"
35
+ not_valid: "is not included in the list"
36
+ not_in_range: "is not included in the list"
37
+ not_decimal: "is invalid"
@@ -24,3 +24,14 @@ es:
24
24
  record_invalid: "Fallo la validación: %{errors}"
25
25
  content_type: "formato de archivo no soportado"
26
26
  activerecord: *activemodel
27
+ ohm:
28
+ errors:
29
+ messages:
30
+ format: "es inválido"
31
+ not_present: "no puede estar en blanco"
32
+ not_numeric: "no es un número"
33
+ not_url: "es inválido"
34
+ not_email: "es inválido"
35
+ not_valid: "no está incluido en la lista"
36
+ not_in_range: "no está incluido en la lista"
37
+ not_decimal: "es inválido"
@@ -24,3 +24,14 @@ fr:
24
24
  record_invalid: "La validation a échoué: %{errors}"
25
25
  content_type: "format de fichier non pris en charge"
26
26
  activerecord: *activemodel
27
+ ohm:
28
+ errors:
29
+ messages:
30
+ format: "est invalide"
31
+ not_present: "ne peut pas être vide"
32
+ not_numeric: "n'est pas un nombre"
33
+ not_url: "est invalide"
34
+ not_email: "est invalide"
35
+ not_valid: "n'est pas inclus dans la liste"
36
+ not_in_range: "n'est pas inclus dans la liste"
37
+ not_decimal: "est invalide"
@@ -24,3 +24,14 @@ hu:
24
24
  record_invalid: "Érvénytelen: %{errors}"
25
25
  content_type: ": a fájl formátuma nem támogatott"
26
26
  activerecord: *activemodel
27
+ ohm:
28
+ errors:
29
+ messages:
30
+ format: ": érvénytelen"
31
+ not_present: ": nem lehet üres"
32
+ not_numeric: ": nem szám"
33
+ not_url: ": érvénytelen"
34
+ not_email: ": érvénytelen"
35
+ not_valid: ": a lista nem tartalmazza"
36
+ not_in_range: ": a lista nem tartalmazza"
37
+ not_decimal: ": érvénytelen"
@@ -24,3 +24,14 @@ it:
24
24
  record_invalid: "Validazione fallita: %{errors}"
25
25
  content_type: "il seguente tipo di file non è supportato"
26
26
  activerecord: *activemodel
27
+ ohm:
28
+ errors:
29
+ messages:
30
+ format: "non è valido"
31
+ not_present: "non può essere lasciato in bianco"
32
+ not_numeric: "non è un numero"
33
+ not_url: "non è valido"
34
+ not_email: "non è valido"
35
+ not_valid: "non è incluso nella lista"
36
+ not_in_range: "non è incluso nella lista"
37
+ not_decimal: "non è valido"
@@ -24,3 +24,14 @@ ja:
24
24
  record_invalid: "不正なレコードです: %{errors}"
25
25
  content_type: "そのファイルフォーマットはサポートされていません。"
26
26
  activerecord: *activemodel
27
+ ohm:
28
+ errors:
29
+ messages:
30
+ format: "は、不正な値です"
31
+ not_present: "は、空欄であってはなりません"
32
+ not_numeric: "は、数字である必要があります"
33
+ not_url: "は、不正な値です"
34
+ not_email: "は、不正な値です"
35
+ not_valid: "は、次の値のうちどれかでなければなりません:"
36
+ not_in_range: "は、次の値のうちどれかでなければなりません:"
37
+ not_decimal: "は、不正な値です"
@@ -24,3 +24,14 @@ lv:
24
24
  record_invalid: "Pārbaude neizdevās: %{errors}"
25
25
  content_type: "faila formāts netiek atblastīts"
26
26
  activerecord: *activemodel
27
+ ohm:
28
+ errors:
29
+ messages:
30
+ format: "nav derīgs"
31
+ not_present: "ir jābūt aizpildītam"
32
+ not_numeric: "nav skaitlis"
33
+ not_url: "nav derīgs"
34
+ not_email: "nav derīgs"
35
+ not_valid: "nav iekļauts sarakstā"
36
+ not_in_range: "nav iekļauts sarakstā"
37
+ not_decimal: "nav derīgs"
@@ -24,3 +24,14 @@ nl:
24
24
  record_invalid: "Validatie mislukt: %{errors}"
25
25
  content_type: "bestandsformaat niet ondersteund"
26
26
  activerecord: *activemodel
27
+ ohm:
28
+ errors:
29
+ messages:
30
+ format: "is ongeldig"
31
+ not_present: "moet opgegeven zijn"
32
+ not_numeric: "is geen getal"
33
+ not_url: "is ongeldig"
34
+ not_email: "is ongeldig"
35
+ not_valid: "is niet in de lijst opgenomen"
36
+ not_in_range: "is niet in de lijst opgenomen"
37
+ not_decimal: "is ongeldig"
@@ -24,3 +24,14 @@
24
24
  record_invalid: "Valideringsfeil: %{errors}"
25
25
  content_type: "fileformatet er ikke støttet"
26
26
  activerecord: *activemodel
27
+ ohm:
28
+ errors:
29
+ messages:
30
+ format: "er ikke gyldig"
31
+ not_present: "kan ikke være blank"
32
+ not_numeric: "er ikke et tall"
33
+ not_url: "er ikke gyldig"
34
+ not_email: "er ikke gyldig"
35
+ not_valid: "finnes ikke i listen"
36
+ not_in_range: "finnes ikke i listen"
37
+ not_decimal: "er ikke gyldig"
@@ -25,3 +25,14 @@ pl:
25
25
  record_invalid: "Negatywne sprawdzenie poprawności: %{errors}"
26
26
  content_type: "nieodozwolony format pliku"
27
27
  activerecord: *activemodel
28
+ ohm:
29
+ errors:
30
+ messages:
31
+ format: "jest nieprawidłowe"
32
+ not_present: "nie może być puste"
33
+ not_numeric: "nie jest liczbą"
34
+ not_url: "jest nieprawidłowe"
35
+ not_email: "jest nieprawidłowe"
36
+ not_valid: "nie znajduje się na liście dopuszczalnych wartości"
37
+ not_in_range: "nie znajduje się na liście dopuszczalnych wartości"
38
+ not_decimal: "jest nieprawidłowe"
@@ -24,3 +24,14 @@ pt_br:
24
24
  record_invalid: "Falha na validação: %{errors}"
25
25
  content_type: "o seguinte tipo de arquivo não é suportado"
26
26
  activerecord: *activemodel
27
+ ohm:
28
+ errors:
29
+ messages:
30
+ format: "não é válido"
31
+ not_present: "não pode ser deixado em branco"
32
+ not_numeric: "não é um número"
33
+ not_url: "não é válido"
34
+ not_email: "não é válido"
35
+ not_valid: "não está incluído na lista"
36
+ not_in_range: "não está incluído na lista"
37
+ not_decimal: "não é válido"
@@ -24,3 +24,14 @@ ro:
24
24
  record_invalid: "Eroare la validare: %{errors}"
25
25
  content_type: "format de fișier neacceptat"
26
26
  activerecord: *activemodel
27
+ ohm:
28
+ errors:
29
+ messages:
30
+ format: "nu este valid"
31
+ not_present: "nu poate fi gol"
32
+ not_numeric: "nu este un număr"
33
+ not_url: "nu este valid"
34
+ not_email: "nu este valid"
35
+ not_valid: "nu este inclus în listă"
36
+ not_in_range: "nu este inclus în listă"
37
+ not_decimal: "nu este valid"
@@ -24,3 +24,14 @@ ru:
24
24
  record_invalid: "Проверка не удалась: %{errors}"
25
25
  content_type: "формат файла не поддерживается"
26
26
  activerecord: *activemodel
27
+ ohm:
28
+ errors:
29
+ messages:
30
+ format: "неправильный"
31
+ not_present: "не может быть пустым"
32
+ not_numeric: "не число"
33
+ not_url: "неправильный"
34
+ not_email: "неправильный"
35
+ not_valid: "не входит в список"
36
+ not_in_range: "не входит в список"
37
+ not_decimal: "неправильный"
@@ -24,3 +24,14 @@ sv:
24
24
  record_invalid: "Validering misslyckades: %{errors}"
25
25
  content_type: "filformatet stöds ej"
26
26
  activerecord: *activemodel
27
+ ohm:
28
+ errors:
29
+ messages:
30
+ format: "är ogiltig"
31
+ not_present: "kan inte vara blankt"
32
+ not_numeric: "är inte ett tal"
33
+ not_url: "är ogiltig"
34
+ not_email: "är ogiltig"
35
+ not_valid: "är inte inkluderad i listan"
36
+ not_in_range: "är inte inkluderad i listan"
37
+ not_decimal: "är ogiltig"
@@ -24,3 +24,14 @@ tr:
24
24
  record_invalid: "Doğrulama gerçekleşmedi: %{errors}"
25
25
  content_type: "Dosya biçimi desteklenmiyor"
26
26
  activerecord: *activemodel
27
+ ohm:
28
+ errors:
29
+ messages:
30
+ format: "geçerli değil"
31
+ not_present: "boş bırakılamaz"
32
+ not_numeric: "sayı değil"
33
+ not_url: "geçerli değil"
34
+ not_email: "geçerli değil"
35
+ not_valid: "listede yok"
36
+ not_in_range: "listede yok"
37
+ not_decimal: "geçerli değil"
@@ -24,3 +24,14 @@ uk:
24
24
  record_invalid: "Перевірка не вдалася: %{errors}"
25
25
  content_type: "формат файлу не підтримується"
26
26
  activerecord: *activemodel
27
+ ohm:
28
+ errors:
29
+ messages:
30
+ format: "недійсний"
31
+ not_present: "не може бути порожнім"
32
+ not_numeric: "не число"
33
+ not_url: "недійсний"
34
+ not_email: "недійсний"
35
+ not_valid: "не входить у список"
36
+ not_in_range: "не входить у список"
37
+ not_decimal: "недійсний"
@@ -24,3 +24,14 @@ zh_cn:
24
24
  record_invalid: "验证失败: %{errors}"
25
25
  content_type: "文件格式不支持"
26
26
  activerecord: *activemodel
27
+ ohm:
28
+ errors:
29
+ messages:
30
+ format: "是无效的"
31
+ not_present: "不能是空白字元"
32
+ not_numeric: "不是数字"
33
+ not_url: "是无效的"
34
+ not_email: "是无效的"
35
+ not_valid: "没有包含在列表中"
36
+ not_in_range: "没有包含在列表中"
37
+ not_decimal: "是无效的"
@@ -24,3 +24,14 @@ zh_tw:
24
24
  record_invalid: "校驗失敗: %{errors}"
25
25
  content_type: "檔案格式不支援"
26
26
  activerecord: *activemodel
27
+ ohm:
28
+ errors:
29
+ messages:
30
+ format: "是無效的"
31
+ not_present: "不能是空白字元"
32
+ not_numeric: "不是數字"
33
+ not_url: "是無效的"
34
+ not_email: "是無效的"
35
+ not_valid: "沒有包含在列表中"
36
+ not_in_range: "沒有包含在列表中"
37
+ not_decimal: "是無效的"
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: padrino-admin
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.11.1
4
+ version: 0.11.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -12,7 +12,7 @@ authors:
12
12
  autorequire:
13
13
  bindir: bin
14
14
  cert_chain: []
15
- date: 2013-04-07 00:00:00.000000000 Z
15
+ date: 2013-05-21 00:00:00.000000000 Z
16
16
  dependencies:
17
17
  - !ruby/object:Gem::Dependency
18
18
  name: padrino-core
@@ -21,7 +21,7 @@ dependencies:
21
21
  requirements:
22
22
  - - '='
23
23
  - !ruby/object:Gem::Version
24
- version: 0.11.1
24
+ version: 0.11.2
25
25
  type: :runtime
26
26
  prerelease: false
27
27
  version_requirements: !ruby/object:Gem::Requirement
@@ -29,7 +29,7 @@ dependencies:
29
29
  requirements:
30
30
  - - '='
31
31
  - !ruby/object:Gem::Version
32
- version: 0.11.1
32
+ version: 0.11.2
33
33
  - !ruby/object:Gem::Dependency
34
34
  name: padrino-helpers
35
35
  requirement: !ruby/object:Gem::Requirement
@@ -37,7 +37,7 @@ dependencies:
37
37
  requirements:
38
38
  - - '='
39
39
  - !ruby/object:Gem::Version
40
- version: 0.11.1
40
+ version: 0.11.2
41
41
  type: :runtime
42
42
  prerelease: false
43
43
  version_requirements: !ruby/object:Gem::Requirement
@@ -45,7 +45,7 @@ dependencies:
45
45
  requirements:
46
46
  - - '='
47
47
  - !ruby/object:Gem::Version
48
- version: 0.11.1
48
+ version: 0.11.2
49
49
  - !ruby/object:Gem::Dependency
50
50
  name: therubyracer
51
51
  requirement: !ruby/object:Gem::Requirement
@@ -278,7 +278,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
278
278
  version: '0'
279
279
  segments:
280
280
  - 0
281
- hash: -2878817817186852969
281
+ hash: -3212063610916847106
282
282
  required_rubygems_version: !ruby/object:Gem::Requirement
283
283
  none: false
284
284
  requirements: