数据描述使用editorMD
This commit is contained in:
parent
a54226a5e7
commit
691b59d856
|
@ -2,55 +2,52 @@
|
|||
<%= javascript_include_tag '/editormd/lib/marked.min.js','/editormd/lib/prettify.min.js','/editormd/lib/raphael.min.js','/editormd/lib/underscore.min.js','/editormd/lib/sequence-diagram.min.js',
|
||||
'/editormd/lib/flowchart.min.js','/editormd/lib/jquery.flowchart.min.js','/editormd/editormd.js' %>
|
||||
<div class="data_showdetail">
|
||||
<!--<p id="notice"><%#= notice %></p>-->
|
||||
<div class="detail_part">
|
||||
<label>数据类别名称:</label>
|
||||
<%= @statistic.name %>
|
||||
</div>
|
||||
|
||||
<div class="detail_part">
|
||||
<label>数据类别名称:</label>
|
||||
<%= @statistic.name %>
|
||||
<div class="cl detail_part">
|
||||
<label>描述:</label>
|
||||
<div id="statistic_description" style="width: 80%;">
|
||||
<textarea class="detail_des fl" style="display: none;width: 85%"><%= @statistic.description %></textarea>
|
||||
</div>
|
||||
|
||||
<div class="cl detail_part">
|
||||
<label>描述:</label>
|
||||
<textarea readonly="readonly" class="detail_des"><%= @statistic.description %></textarea>
|
||||
</div>
|
||||
<div class="detail_part">
|
||||
<label>添加时间:</label>
|
||||
<%= format_time @statistic.created_at %>
|
||||
</div>
|
||||
<div class="detail_part">
|
||||
<label>用户id:</label>
|
||||
<%= @statistic.user_id %>
|
||||
</div>
|
||||
<div class="detail_part">
|
||||
<label>状态:</label>
|
||||
<%= @statistic.status %>
|
||||
</div>
|
||||
|
||||
<%# 附件局部刷新 %>
|
||||
<% if @attachments.present? %>
|
||||
</div>
|
||||
<div class="detail_part">
|
||||
<label>添加时间:</label>
|
||||
<%= format_time @statistic.created_at %>
|
||||
</div>
|
||||
<div class="detail_part">
|
||||
<label>用户id:</label>
|
||||
<%= @statistic.user_id %>
|
||||
</div>
|
||||
<div class="detail_part">
|
||||
<label>状态:</label>
|
||||
<%= @statistic.status %>
|
||||
</div>
|
||||
<%# 附件局部刷新 %>
|
||||
<% if @attachments.present? %>
|
||||
<div class="detail_part cl">
|
||||
<label>附件:</label>
|
||||
<div class="fl">
|
||||
<%= render :partial => 'attachments',:locals => {:attachments => @attachments} %>
|
||||
</div>
|
||||
</div>
|
||||
<% end %>
|
||||
<div class="detail_part">
|
||||
<label> </label>
|
||||
<%= link_to '编辑', edit_statistic_path(@statistic) ,:class => "submit_btn" %>
|
||||
<%= link_to '返回', statistics_path ,:class=>"grey_btn" %>
|
||||
</div>
|
||||
<% end %>
|
||||
<div class="detail_part">
|
||||
<label> </label>
|
||||
<%= link_to '编辑', edit_statistic_path(@statistic) ,:class => "submit_btn" %>
|
||||
<%= link_to '返回', statistics_path ,:class=>"grey_btn" %>
|
||||
</div>
|
||||
</div>
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
editormd.loadKaTeX(function() {
|
||||
var taskPassMD = editormd.markdownToHTML("challenge_task_pass_show", {
|
||||
htmlDecode: "style,script,iframe", // you can filter tags decode
|
||||
taskList: true,
|
||||
tex: true, // 默认不解析
|
||||
flowChart: true, // 默认不解析
|
||||
sequenceDiagram: true // 默认不解析
|
||||
});
|
||||
var taskPassMD = editormd.markdownToHTML("statistic_description", {
|
||||
htmlDecode: "style,script,iframe", // you can filter tags decode
|
||||
taskList: true,
|
||||
tex: true, // 默认不解析
|
||||
flowChart: true, // 默认不解析
|
||||
sequenceDiagram: true // 默认不解析
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
|
Loading…
Reference in New Issue