-
- <% unless @course.nil? %>
- <% if @course.time == 2008 %>
- <%= l(:label_term) %> * |
-
- <%= select_tag 'time', "
+ <%# end %>
+ -->
+ <% unless @course.nil?%>
+ <%= l(:label_class_period) %> *
+ <%= text_field_tag :class_period, @course.class_period, :placeholder => "在此输入课时" %> <%= l(:label_class_hour)%>
+ |
+ <% else %>
+ <%= l(:label_class_period) %> *
+ <%= text_field_tag :class_period, nil, :placeholder => "在此输入课时" %><%= l(:label_class_hour)%>
+ |
+ <% end %>
+
+
+
+
+
+
+ <% unless @course.nil? %>
+ <% if @course.time == 2008 %>
+ <%= l(:label_term) %> * |
+
+ <%= select_tag 'time', "
@@ -94,12 +94,12 @@
".html_safe %> |
-
-
- <% elsif @course.time == 2009 %>
- <%= l(:label_term) %> * |
-
- <%= select_tag 'time', "
+
+
+ <% elsif @course.time == 2009 %>
+ <%= l(:label_term) %> * |
+
+ <%= select_tag 'time', "
@@ -109,11 +109,11 @@
".html_safe %> |
-
- <% elsif @course.time == 2010 %>
- <%= l(:label_term) %> * |
-
- <%= select_tag 'time', "
+
+ <% elsif @course.time == 2010 %>
+ <%= l(:label_term) %> * |
+
+ <%= select_tag 'time', "
@@ -123,11 +123,11 @@
".html_safe %> |
-
- <% elsif @course.time == 2011 %>
- <%= l(:label_term) %> * |
-
- <%= select_tag 'time', "
+
+ <% elsif @course.time == 2011 %>
+ <%= l(:label_term) %> * |
+
+ <%= select_tag 'time', "
@@ -137,12 +137,12 @@
".html_safe %> |
-
-
- <% elsif @course.time == 2012 %>
- <%= l(:label_term) %> * |
-
- <%= select_tag 'time', "
+
+
+ <% elsif @course.time == 2012 %>
+ <%= l(:label_term) %> * |
+
+ <%= select_tag 'time', "
@@ -152,11 +152,11 @@
".html_safe %> |
-
- <% elsif @course.time == 2013 %>
- <%= l(:label_term) %> * |
-
- <%= select_tag 'time', "
+
+ <% elsif @course.time == 2013 %>
+ <%= l(:label_term) %> * |
+
+ <%= select_tag 'time', "
@@ -166,11 +166,11 @@
".html_safe %> |
-
- <% elsif @course.time == 2014 %>
- <%= l(:label_term) %> * |
-
- <%= select_tag 'time', "
+
+ <% elsif @course.time == 2014 %>
+ <%= l(:label_term) %> * |
+
+ <%= select_tag 'time', "
@@ -180,11 +180,11 @@
".html_safe %> |
-
- <% elsif @course.time == 2015 %>
- <%= l(:label_term) %> * |
-
- <%= select_tag 'time', "
+
+ <% elsif @course.time == 2015 %>
+ <%= l(:label_term) %> * |
+
+ <%= select_tag 'time', "
@@ -194,11 +194,11 @@
".html_safe %> |
-
- <% elsif @course.time == 2016 %>
- <%= l(:label_term) %> * |
-
- <%= select_tag 'time', "
+
+ <% elsif @course.time == 2016 %>
+ <%= l(:label_term) %> * |
+
+ <%= select_tag 'time', "
@@ -208,11 +208,11 @@
".html_safe %> |
-
- <% elsif @course.time == 2017 %>
- <%= l(:label_term) %> * |
-
- <%= select_tag 'time', "
+
+ <% elsif @course.time == 2017 %>
+ <%= l(:label_term) %> * |
+
+ <%= select_tag 'time', "
@@ -222,10 +222,10 @@
".html_safe %> |
- <% else %>
- <%= l(:label_term) %> * |
-
- <%= select_tag 'time', "
+ <% else %>
+ <%= l(:label_term) %> * |
+
+ <%= select_tag 'time', "
@@ -235,72 +235,81 @@
".html_safe %> |
-
- <% end %>
- <% end %>
- |
-
- <% unless @course.nil? %>
- <% if @course.term == l(:label_spring) %>
-
-
- <%= select_tag 'term', "
+
+ <% end %>
+ <% end %>
+ |
+
+ <% unless @course.nil? %>
+ <% if @course.term == l(:label_spring) %>
+
+
+ <%= select_tag 'term', "
".html_safe %> |
-
- <% elsif @course.term == l(:label_summer)%>
-
-
- <%= select_tag 'term', "
+
+ <% elsif @course.term == l(:label_summer)%>
+
+
+ <%= select_tag 'term', "
".html_safe %> |
-
- <% elsif @course.term == l(:label_autumn)%>
-
-
- <%= select_tag 'term', "
+
+ <% elsif @course.term == l(:label_autumn)%>
+
+
+ <%= select_tag 'term', "
".html_safe %> |
-
- <% elsif @course.term == l(:label_winter)%>
-
-
- <%= select_tag 'term', "
-
- ".html_safe %> |
-
- <% else %>
-
-
- <%= select_tag 'term', "
-
- ".html_safe %> |
-
- <% end %>
-
- <% end %> |
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- <%= l(:text_command) %>
- <% end %>
-
+ <% elsif @course.term == l(:label_winter)%>
+
+
+ <%= select_tag 'term', "
+
+ ".html_safe %> |
+
+ <% else %>
+
+
+ <%= select_tag 'term', "
+
+ ".html_safe %> |
+
+ <% end %>
+
+ <% end %> |
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ <%= l(:text_command) %>
+<% end %>
+
-
+
+
+
+
+
+
<%= f.check_box :is_public, :style => "margin-left:10px;" %><%= l(:label_course_public_info) %>
@@ -310,7 +319,7 @@
<%= wikitoolbar_for 'course_description' %>
<% @course.custom_field_values.each do |value| %>
- <%= custom_field_tag_with_label :course, value %>
+ <%= custom_field_tag_with_label :course, value %>
<% end %>
<%= call_hook(:view_courses_form, :course => @course, :form => f) %>
@@ -319,8 +328,8 @@
<% unless @course.extra_frozen? %>
- <% content_for :header_tags do %>
- <%= javascript_include_tag 'course_identifier' %>
- <% end %>
+ <% content_for :header_tags do %>
+ <%= javascript_include_tag 'course_identifier' %>
+ <% end %>
<% end %>
diff --git a/app/views/issues/_form.html.erb b/app/views/issues/_form.html.erb
index 8f9554107..86b6742d6 100644
--- a/app/views/issues/_form.html.erb
+++ b/app/views/issues/_form.html.erb
@@ -28,7 +28,7 @@
<% end %>
<% if @issue.safe_attribute? 'description' %>
-
+
<%= f.label_for_field :description, :required => @issue.required_attribute?('description') %>
<%= link_to_function image_tag('edit.png'), '$(this).hide(); $("#issue_description_and_toolbar").show()' unless @issue.new_record? %>
<%= content_tag 'span', :id => "issue_description_and_toolbar", :style => (@issue.new_record? ? nil : 'display:none') do %>
diff --git a/app/views/projects/_form.html.erb b/app/views/projects/_form.html.erb
index ec0bf7fbf..420cc5100 100644
--- a/app/views/projects/_form.html.erb
+++ b/app/views/projects/_form.html.erb
@@ -5,14 +5,14 @@
<% end %>
<%= f.text_field :name, :required => true, :size => 60, :style => "width:490px;" %>
-
+
<%= f.text_area :description, :rows => 8, :class => 'wiki-edit', :style => "font-size:small;width:490px;margin-left:10px;" %>
<%= f.text_field :identifier, :required => true, :size => 60, :style => "width:488px;", :disabled => @project.identifier_frozen?, :maxlength => Project::IDENTIFIER_MAX_LENGTH %>
<% unless @project.identifier_frozen? %>
<%= l(:text_length_between, :min => 1, :max => Project::IDENTIFIER_MAX_LENGTH) %> <%= l(:text_project_identifier_info).html_safe %>
<% end %>
-
+
<%= f.check_box :is_public, :style => "margin-left:10px;" %>
<%= f.check_box :hidden_repo, :style => "margin-left:10px;" %>
<%= f.text_field :project_type, :value => 0 %>
diff --git a/lib/redmine/views/labelled_form_builder.rb b/lib/redmine/views/labelled_form_builder.rb
index 2bba17faf..22be40efe 100644
--- a/lib/redmine/views/labelled_form_builder.rb
+++ b/lib/redmine/views/labelled_form_builder.rb
@@ -43,7 +43,7 @@ class Redmine::Views::LabelledFormBuilder < ActionView::Helpers::FormBuilder
return ''.html_safe if options.delete(:no_label)
text = options[:label].is_a?(Symbol) ? l(options[:label]) : options[:label]
text ||= l(("field_" + field.to_s.gsub(/\_id$/, "")).to_sym)
- text += @template.content_tag("span", " *", :class => "required") if options.delete(:required)
+ text += @template.content_tag("span", "#{options.delete(:required) ? ' *' : ' '}".html_safe, :class => "required")
@template.content_tag("label", text.html_safe,
:class => (@object && @object.errors[field].present? ? "error" : nil),
:for => (@object_name.to_s + "_" + field.to_s))
|
|
|
|
|
|
|
|
|
|
|
|
|
|