2015-01-16 15:34:25 +08:00
|
|
|
<%= form_for("",:url => update_poll_question_poll_index_path(:poll_question => poll_question.id),:remote => true) do |f|%>
|
2015-01-17 11:58:19 +08:00
|
|
|
<script type="text/javascript">
|
|
|
|
function resetQuestion<%=poll_question.id%>()
|
|
|
|
{
|
|
|
|
$("#poll_questions_title_<%=poll_question.id%>").val("<%= poll_question.question_title%>")
|
|
|
|
$("#is_necessary_<%=poll_question.id%>").replaceWith("<input type='checkbox' name='is_necessary' id='is_necessary_<%=poll_question.id%>' value='true' <%= poll_question.is_necessary == 1 ? 'checked' : ''%>/>");
|
|
|
|
}
|
|
|
|
</script>
|
2015-01-13 18:21:46 +08:00
|
|
|
<div class="ur_editor textarea"> <!--编辑多行文字start-->
|
|
|
|
<div class="ur_editor_title">
|
|
|
|
<label for="ur_question_title">问题: </label>
|
2015-01-16 15:34:25 +08:00
|
|
|
<input type="hidden" name="question_type" value="<%= poll_question.question_type%>"/>
|
2015-01-17 11:05:38 +08:00
|
|
|
<input maxlength="250" class="ur_question_title" type="text" name="poll_questions_title" id="poll_questions_title_<%=poll_question.id%>" placeholder="请输入多行主观标题" value="<%= poll_question.question_title%>"/>
|
2015-01-17 11:58:19 +08:00
|
|
|
<input type="checkbox" id="is_necessary_<%=poll_question.id%>" name="is_necessary" value="true" <%= poll_question.is_necessary == 1 ? "checked" : ""%>/>
|
2015-01-13 18:21:46 +08:00
|
|
|
<label for="ur_question_require">必答</label>
|
|
|
|
</div>
|
|
|
|
<div class="ur_editor_toolbar">
|
2015-01-16 15:34:25 +08:00
|
|
|
<!--<label>尺寸:</label>-->
|
|
|
|
<!--<label>宽 <input name="cols" type="number" min="1" value="60"> 字</label>,-->
|
|
|
|
<!--<label>高 <input name="rows" type="number" min="1" value="5"> 行</label>-->
|
2015-01-13 18:21:46 +08:00
|
|
|
</div>
|
|
|
|
<div class="ur_editor_footer">
|
2015-01-29 17:01:19 +08:00
|
|
|
<a class="btn_submit" data-button="ok" onclick="edit_poll_question($(this),<%= poll_question.id %>);">
|
2015-01-27 10:14:05 +08:00
|
|
|
<%= 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>
|
2015-01-13 18:21:46 +08:00
|
|
|
</div>
|
|
|
|
<div class="cl"></div>
|
2015-01-16 15:34:25 +08:00
|
|
|
</div><!--编辑多行文字end-->
|
|
|
|
<% end%>
|