添加合作单位名称,url的非空验证、字符长度验证(不超过255)、url格式验证,及新建、编辑时的错误提示信息
This commit is contained in:
parent
af59cef90b
commit
984c33acfb
|
@ -6,6 +6,7 @@
|
|||
<div class="box tabular">
|
||||
<p><%= f.text_field :name, :required => true %></p>
|
||||
<p><%= f.text_field :url, :required => true %></p>
|
||||
<p><%= l(:label_url_prompt) %></p>
|
||||
<p>
|
||||
<label for='attachments_fields'> <%= l(:label_upload_logo) %>:</label>
|
||||
</p>
|
||||
|
|
|
@ -6,6 +6,6 @@
|
|||
<span class="footer_logo_link"><%= link_to image_tag(url_to_avatar(company),:size=>"100x30",:alt=>company.name),company.url, :target => "_blank" %></span>
|
||||
<%= link_to l(:button_edit),edit_web_footer_company_path(company) %>
|
||||
<%= delete_link web_footer_company_path(company) %>
|
||||
<br/>
|
||||
<hr/>
|
||||
<% end %>
|
||||
</div>
|
|
@ -6,7 +6,7 @@
|
|||
<div class="box tabular">
|
||||
<p><%= f.text_field :name, :required => true %></p>
|
||||
<p><%= f.text_field :url, :required => true %></p>
|
||||
|
||||
<p><%= l(:label_url_prompt) %></p>
|
||||
</div>
|
||||
<%= submit_tag l(:button_create) %>
|
||||
</div>
|
||||
|
|
|
@ -532,6 +532,11 @@ en:
|
|||
label_web_footer_cooperation_compnay: Site footer cooperation unit
|
||||
label_new_company: Add the cooperation unit
|
||||
label_upload_logo: Upload logo
|
||||
label_url_prompt: Web site needs to http or https at the beginning, for example 'http://forge.trustie.net'
|
||||
web_footer_company_create_fail: The cooperation unit creation failed
|
||||
web_footer_company_update_fail: The cooperation unit update failed
|
||||
is_not_url_error: Is not a valid URL
|
||||
|
||||
label_x_projects:
|
||||
zero: no projects
|
||||
one: 1 project
|
||||
|
|
|
@ -534,6 +534,10 @@ zh:
|
|||
label_new_company: 添加合作单位
|
||||
label_edit_company: 编辑合作单位
|
||||
label_upload_logo: 上传logo
|
||||
label_url_prompt: 网址需以"http://"或"https://"开头,例:http://forge.trustie.net
|
||||
web_footer_company_create_fail: 合作单位创建失败
|
||||
web_footer_company_update_fail: 合作单位更新失败
|
||||
is_not_url_error: 不是正确的url
|
||||
label_x_projects:
|
||||
zero: 无项目
|
||||
one: 1 个项目
|
||||
|
|
Loading…
Reference in New Issue