国际化部分代码

This commit is contained in:
sw 2015-01-27 10:14:05 +08:00
parent fe06ca503a
commit 649c65fbe2
10 changed files with 58 additions and 22 deletions

View File

@ -64,13 +64,13 @@ module PollHelper
def options_show pq
case pq
when 1
"单选题"
l(:label_MC)
when 2
"多选题"
l(:label_MCQ)
when 3
"单行主观题"
l(:label_single)
else
"多行主观题"
l(:label_mulit)
end
end

View File

@ -39,8 +39,12 @@
</ul>
</div>
<div class="ur_editor_footer">
<a class="btn btn_dark btn_submit" data-button="ok" onclick="$(this).parent().parent().parent().submit();">确定</a>
<a class="btn btn_light btn_cancel" data-button="cancel" onclick="resetQuestion<%=poll_question.id%>();pollQuestionCancel(<%= poll_question.id%>);">取消</a>
<a class="btn btn_dark btn_submit" data-button="ok" onclick="$(this).parent().parent().parent().submit();">
<%= l(:label_button_ok)%>
</a>
<a class="btn btn_light btn_cancel" data-button="cancel" onclick="resetQuestion<%=poll_question.id%>();pollQuestionCancel(<%= poll_question.id%>);">
<%= l(:button_cancel)%>
</a>
</div>
<div class="cl"></div>
</div>

View File

@ -36,8 +36,12 @@
</ul>
</div>
<div class="ur_editor_footer">
<a class="btn btn_dark btn_submit" data-button="ok" onclick="$(this).parent().parent().parent().submit();">确定</a>
<a class="btn btn_light btn_cancel" data-button="cancel" onclick="resetQuestion<%=poll_question.id%>();pollQuestionCancel(<%= poll_question.id%>);">取消</a>
<a class="btn btn_dark btn_submit" data-button="ok" onclick="$(this).parent().parent().parent().submit();">
<%= l(:label_button_ok)%>
</a>
<a class="btn btn_light btn_cancel" data-button="cancel" onclick="resetQuestion<%=poll_question.id%>();pollQuestionCancel(<%= poll_question.id%>);">
<%= l(:button_cancel)%>
</a>
</div>
<div class="cl"></div>
</div><!--编辑多选 end-->

View File

@ -7,8 +7,12 @@
<textarea name="polls_description" maxlength="300" id="polls_description" class="textarea_editor"><%= @poll.polls_description%></textarea>
</div>
<div class="ur_editor_footer">
<a class="btn_submit" data-button="ok" onclick="pollsSubmit($(this));">确定</a>
<a class="btn_cancel" data-button="cancel" onclick="pollsCancel();">取消</a>
<a class="btn_submit" data-button="ok" onclick="pollsSubmit($(this));">
<%= l(:label_button_ok)%>
</a>
<a class="btn_cancel" data-button="cancel" onclick="pollsCancel();">
<%= l(:button_cancel)%>
</a>
</div>
<div class="cl"></div>
</div><!--编辑头部 end-->

View File

@ -20,8 +20,12 @@
<!--<label>高 <input name="rows" type="number" min="1" value="5"> 行</label>-->
</div>
<div class="ur_editor_footer">
<a class="btn_submit" data-button="ok" onclick="$(this).parent().parent().parent().submit();">确定</a>
<a class="btn_cancel" data-button="cancel" onclick="resetQuestion<%=poll_question.id%>();pollQuestionCancel(<%= poll_question.id%>);">取消</a>
<a class="btn_submit" data-button="ok" onclick="$(this).parent().parent().parent().submit();">
<%= l(:label_button_ok)%>
</a>
<a class="btn_cancel" data-button="cancel" onclick="resetQuestion<%=poll_question.id%>();pollQuestionCancel(<%= poll_question.id%>);">
<%= l(:button_cancel)%>
</a>
</div>
<div class="cl"></div>
</div><!--编辑多行文字end-->

View File

@ -16,8 +16,12 @@
<label for="ur_question_require">必答</label>
</div>
<div class="ur_editor_footer">
<a class="btn_submit" data-button="ok" onclick="$(this).parent().parent().parent().submit();">确定</a>
<a class="btn_cancel" data-button="cancel" onclick="resetQuestion<%=poll_question.id%>();pollQuestionCancel(<%= poll_question.id%>);">取消</a>
<a class="btn_submit" data-button="ok" onclick="$(this).parent().parent().parent().submit();">
<%= l(:label_button_ok)%>
</a>
<a class="btn_cancel" data-button="cancel" onclick="resetQuestion<%=poll_question.id%>();pollQuestionCancel(<%= poll_question.id%>);">
<%= l(:button_cancel)%>
</a>
</div>
<div class="cl"></div>
</div><!--编辑单行文字end-->

View File

@ -34,8 +34,12 @@
</ul>
</div>
<div class="ur_editor_footer">
<a class="btn btn_dark btn_submit" data-button="ok" onclick="$(this).parent().parent().parent().submit();">确定</a>
<a class="btn btn_light btn_cancel" data-button="cancel" onclick="$(this).parent().parent().parent().remove();">取消</a>
<a class="btn btn_dark btn_submit" data-button="ok" onclick="$(this).parent().parent().parent().submit();">
<%= l(:label_button_ok)%>
</a>
<a class="btn btn_light btn_cancel" data-button="cancel" onclick="$(this).parent().parent().parent().remove();">
<%= l(:button_cancel)%>
</a>
</div>
<div class="cl"></div>
</div>

View File

@ -33,8 +33,12 @@
</ul>
</div>
<div class="ur_editor_footer">
<a class="btn btn_dark btn_submit" data-button="ok" onclick="$(this).parent().parent().parent().submit();">确定</a>
<a class="btn btn_light btn_cancel" data-button="cancel" onclick="$(this).parent().parent().parent().remove();">取消</a>
<a class="btn btn_dark btn_submit" data-button="ok" onclick="$(this).parent().parent().parent().submit();">
<%= l(:label_button_ok)%>
</a>
<a class="btn btn_light btn_cancel" data-button="cancel" onclick="$(this).parent().parent().parent().remove();">
<%= l(:button_cancel)%>
</a>
</div>
<div class="cl"></div>
</div>

View File

@ -13,8 +13,12 @@
<!--<label>高 <input name="rows" type="number" min="1" value="5"> 行</label>-->
</div>
<div class="ur_editor_footer">
<a class="btn_submit" data-button="ok" onclick="$(this).parent().parent().parent().submit();">确定</a>
<a class="btn_cancel" data-button="cancel" onclick="$(this).parent().parent().parent().remove();">取消</a>
<a class="btn_submit" data-button="ok" onclick="$(this).parent().parent().parent().submit();">
<%= l(:label_button_ok)%>
</a>
<a class="btn_cancel" data-button="cancel" onclick="$(this).parent().parent().parent().remove();">
<%= l(:button_cancel)%>
</a>
</div>
<div class="cl"></div>
</div><!--编辑多行文字end-->

View File

@ -8,8 +8,12 @@
<label for="ur_question_require">必答</label>
</div>
<div class="ur_editor_footer">
<a class="btn_submit" data-button="ok" onclick="$(this).parent().parent().parent().submit();">确定</a>
<a class="btn_cancel" data-button="cancel" onclick="$(this).parent().parent().parent().remove();">取消</a>
<a class="btn_submit" data-button="ok" onclick="$(this).parent().parent().parent().submit();">
<%= l(:label_button_ok)%>
</a>
<a class="btn_cancel" data-button="cancel" onclick="$(this).parent().parent().parent().remove();">
<%= l(:button_cancel)%>
</a>
</div>
<div class="cl"></div>
</div><!--编辑单行文字end-->