dev_ec
jingquan huang 6 years ago
commit 2d3cb54288

@ -2929,7 +2929,7 @@ end
attachment.save attachment.save
path = attachment.disk_directory path = attachment.disk_directory
name = attachment.disk_filename name = attachment.disk_filename
if name.split(".").last == "xls" || name.split(".").last == "xlsx" if name.split(".").last == "xlsx"
# lists = readXlsData("files/baolong.xlsx") # lists = readXlsData("files/baolong.xlsx")
lists = readXlsData("files/#{path}/#{name}") lists = readXlsData("files/#{path}/#{name}")
school_id = nil school_id = nil

@ -35,7 +35,7 @@
<li>实训</li> <li>实训</li>
<li>实训报告</li> <li>实训报告</li>
<li>学员实战时间</li> <li>学员实战时间</li>
<li>云主机</li> <!-- <li>云主机</li>-->
</div> </div>
<div class="base_status_value"> <div class="base_status_value">
<li><span><%= @teachers_count %></span>人</li> <li><span><%= @teachers_count %></span>人</li>
@ -44,7 +44,7 @@
<li><span><%= @shixuns_count %></span>个</li> <li><span><%= @shixuns_count %></span>个</li>
<li><span><%= @shixun_report_count %></span>个</li> <li><span><%= @shixun_report_count %></span>个</li>
<li><span data-tip-down="所有学员的实训耗时之和"><span><%= @shixun_time_sum %></span>天</span></li> <li><span data-tip-down="所有学员的实训耗时之和"><span><%= @shixun_time_sum %></span>天</span></li>
<li><span><%= @department.present? ? @department.host_count.to_i : @school.departments.first.try(:host_count).to_i %></span>台</li> <!-- <li><span><%#= @department.present? ? @department.host_count.to_i : @school.departments.first.try(:host_count).to_i %></span>台</li>-->
</div> </div>
</div> </div>

@ -1,3 +1,5 @@
<% if @status == 1 %> <% if @status == 1 %>
notice_box("导入成功"); notice_box("导入成功");
<% else %>
notice_box("导入失败只支持xlsx文件");
<% end %> <% end %>

@ -41,7 +41,7 @@
formatTime:'H:i', formatTime:'H:i',
formatDate:'Y-m-d', formatDate:'Y-m-d',
validateOnBlur:false, validateOnBlur:false,
step:30 step:10
}); });
$('#notice_end_time').datetimepicker({ $('#notice_end_time').datetimepicker({
allowBlank:true, allowBlank:true,
@ -50,7 +50,7 @@
formatTime:'H:i', formatTime:'H:i',
formatDate:'Y-m-d', formatDate:'Y-m-d',
validateOnBlur:false, validateOnBlur:false,
step:30 step:10
}); });
}); });

@ -59,9 +59,9 @@
<a href="javascript:void(0);" class="fl task-btn task-btn-orange ml5 mt5" onclick="$('#management_search_user').submit();">搜索</a> <a href="javascript:void(0);" class="fl task-btn task-btn-orange ml5 mt5" onclick="$('#management_search_user').submit();">搜索</a>
<a href="javascript:void(0);" class="fl task-btn ml5 mt5" id="clear_contents">清除</a> <a href="javascript:void(0);" class="fl task-btn ml5 mt5" id="clear_contents">清除</a>
</div> </div>
<!--<div class="fr">--> <div class="fr">
<!--<a href="javascript:void(0);" onclick="import_student_accounts();" class="white-btn orange-btn">+&nbsp;导入学生账号</a>--> <a href="javascript:void(0);" onclick="import_student_accounts();" class="white-btn orange-btn">+&nbsp;导入学生账号</a>
<!--</div>--> </div>
<div class="mt5 fr"> <div class="mt5 fr">
<input type="checkbox" class="magic-checkbox" id="only_t"> <input type="checkbox" class="magic-checkbox" id="only_t">
<label for="only_t" class="mr10 fl">只看T</label> <label for="only_t" class="mr10 fl">只看T</label>

@ -1115,14 +1115,15 @@ function _initZoomCheck() {
} }
var ratio = Math.round(window.devicePixelRatio * 100); var ratio = Math.round(window.devicePixelRatio * 100);
// A value of 1 indicates a classic 96 DPI (76 DPI on some platforms) display, while a value of 2 is expected for HiDPI/Retina displays // A value of 1 indicates a classic 96 DPI (76 DPI on some platforms) display, while a value of 2 is expected for HiDPI/Retina displays
var isNormalZoom = ratio === 100 || ratio === 200 // 有个显示器默认值是1.25
var isNormalZoom = ratio === 100 || ratio === 200 || ratio === 125
if (!isNormalZoom) { if (!isNormalZoom) {
suofang(); suofang();
} }
$(window).resize(function() { $(window).resize(function() {
var ratio = Math.round(window.devicePixelRatio * 100); var ratio = Math.round(window.devicePixelRatio * 100);
var isNormalZoom = ratio === 100 || ratio === 200 var isNormalZoom = ratio === 100 || ratio === 200 || ratio === 125
if (!isNormalZoom) { if (!isNormalZoom) {
suofang(); suofang();
} else { } else {

Loading…
Cancel
Save