Skip to content
Browse files

Fix i18n notation

t.key => t('key')
  • Loading branch information...
1 parent 2458f29 commit d0c5d0ed67c6bd60ff162c82dbd1b000f015c030 @ktns ktns committed Mar 15, 2012
Showing with 19 additions and 19 deletions.
  1. +3 −3 views/aside.haml
  2. +2 −2 views/edit.haml
  3. +4 −4 views/form.haml
  4. +8 −8 views/index.haml
  5. +2 −2 views/new.haml
View
6 views/aside.haml
@@ -2,9 +2,9 @@
%link{:rel => 'stylesheet', :href => '/plugin/lokka-links/views/link.css', :type => 'text/css'}
- content_for :admin_aside do
%li.link.parent
- %h3.title= t.links
+ %h3.title= t('links')
%ul
%li.list
- %a{:href => '/admin/plugins/links'}= t.list
+ %a{:href => '/admin/plugins/links'}= t('list')
%li.new
- %a{:href => '/admin/plugins/links/new'}= t.new
+ %a{:href => '/admin/plugins/links/new'}= t('new')
View
4 views/edit.haml
@@ -1,6 +1,6 @@
-%h2= t.edit_link
+%h2= t('edit_link')
%form{:action => "/admin/plugins/links/#{@link.id}", :method => 'post'}
%input{:type => 'hidden', :name => '_method', :value => 'put'}
= haml :"plugin/lokka-links/views/form"
%p
- %input{:type => 'submit', :value => t.edit}
+ %input{:type => 'submit', :value => t('edit')}
View
8 views/form.haml
@@ -1,18 +1,18 @@
- unless @link.errors.empty?
#error
- .title= t.error
+ .title= t('error')
%ul
- @link.errors.each do |error|
%li= error
%p
- %label{:for => 'link_title'}= t.link_title
+ %label{:for => 'link_title'}= t('link_title')
%br
%input{:type => 'text', :id => 'link_title', :name => 'link[title]', :value => @link.title}
%p
- %label{:for => 'link_url'}= t.link_url
+ %label{:for => 'link_url'}= t('link_url')
%br
%input{:type => 'text', :id => 'link_url', :name => 'link[url]', :value => @link.url}
%p
- %label{:for => 'link_target'}= t.link_target
+ %label{:for => 'link_target'}= t('link_target')
%br
%input{:type => 'text', :id => 'link_target', :name => 'link[target]', :value => @link.target}
View
16 views/index.haml
@@ -1,9 +1,9 @@
-%h2= t.listing_links
+%h2= t('listing_links')
%table
%tr
- %th= t.link_sort
- %th= t.link_title
- %th= t.link_url
+ %th= t('link_sort')
+ %th= t('link_title')
+ %th= t('link_url')
%th{:colspan => 4}
- @links.each_with_index do |link, i|
%tr{:class => (i+1).odd? ? 'odd' : 'even'}
@@ -13,11 +13,11 @@
%a{:href => "#{link.url}", :target => "#{link.target}"}=h link.url
%td
- if link.sort > 1
- %a.button{:href => "/admin/plugins/links/#{link.id}/up"}= t.link_sort_up
+ %a.button{:href => "/admin/plugins/links/#{link.id}/up"}= t('link_sort_up')
%td
- if link.sort < @links.size
- %a.button{:href => "/admin/plugins/links/#{link.id}/down"}= t.link_sort_down
+ %a.button{:href => "/admin/plugins/links/#{link.id}/down"}= t('link_sort_down')
%td
- %a.button{:href => "/admin/plugins/links/#{link.id}/edit"}= t.edit
+ %a.button{:href => "/admin/plugins/links/#{link.id}/edit"}= t('edit')
%td
- = link_to t.delete, "/admin/plugins/links/#{link.id}", :class => 'button', :confirm => t.are_you_sure, :method => :delete
+ = link_to t('delete'), "/admin/plugins/links/#{link.id}", :class => 'button', :confirm => t('are_you_sure'), :method => :delete
View
4 views/new.haml
@@ -1,5 +1,5 @@
-%h2= t.new_link
+%h2= t('new_link')
%form{:action => '/admin/plugins/links', :method => 'post'}
= haml :"plugin/lokka-links/views/form"
%p
- %input{:type => 'submit', :value => t.new}
+ %input{:type => 'submit', :value => t('new')}

0 comments on commit d0c5d0e

Please sign in to comment.
Something went wrong with that request. Please try again.