114 lines
3.7 KiB
HTML
114 lines
3.7 KiB
HTML
<div class="easyui-layout" id="result" style="width:100%;height:100%"></div>
|
||
<script type="text/html" id="text">
|
||
{% verbatim %}
|
||
<div id='southdiv' data-options="region:'south'" style="height:50px;text-align:center;padding:5px">
|
||
|
||
<a iconCls="fa-close" class="easyui-linkbutton" onclick="closeForm()">关闭</a>
|
||
</div>
|
||
|
||
<div data-options="region:'center'" style="height:100%;padding:15px 15px;">
|
||
<div style="text-align:center;font-size: 24px;font-weight: bold;margin-bottom: 20px;">任务名:{{checktaskname}}</div>
|
||
<table class='detailtable' style="text-align:center;">
|
||
|
||
<tr>
|
||
<td style="font-weight: bold;">检查表名:</td>
|
||
<td>{{checktype__checktitle}}</td>
|
||
<td style="font-weight: bold;">排查频率:</td>
|
||
{{if tasktype==1}}
|
||
<td>每天一次</td>
|
||
{{else if tasktype==2}}
|
||
<td>每周一次</td>
|
||
{{else if tasktype==3}}
|
||
<td>每月一次</td>
|
||
{{else if tasktype==4}}
|
||
<td>每季度一次</td>
|
||
{{else if tasktype==5}}
|
||
<td>每半年一次</td>
|
||
{{else if tasktype==6}}
|
||
<td>每年一次</td>
|
||
{{/if}}
|
||
|
||
|
||
</tr>
|
||
<tr style="height:80px">
|
||
<td style="font-weight: bold;">检查内容:</td>
|
||
<td colspan="3">{{checktype__checkcontent}}</td>
|
||
</tr>
|
||
<tr style="height:80px">
|
||
<td style="font-weight: bold;">检查人员:</td>
|
||
<td colspan="3">{{bcfr}}</td>
|
||
</tr>
|
||
<tr style="height:80px">
|
||
<td style="font-weight: bold;">执行情况:</td>
|
||
<td>{{zxstate==1?'同时执行':'单人执行'}}</td>
|
||
|
||
|
||
<td style="font-weight: bold;">更新时间:</td>
|
||
<td>{{checktime| dateFormat 'yyyy-MM-dd hh:mm:ss'}}</td>
|
||
|
||
</tr>
|
||
<tr>
|
||
|
||
|
||
<td style="font-weight: bold;">检查地点:</td>
|
||
<td colspan="3">{{checkplace}}</td>
|
||
|
||
|
||
</tr>
|
||
|
||
|
||
</table>
|
||
|
||
</div>
|
||
{% endverbatim %}
|
||
</script>
|
||
<script type="text/javascript" src="/static/safesite/mystatic/js/template-web.js"></script>
|
||
<script>
|
||
var html;
|
||
var state;
|
||
var id = {{ id }};
|
||
template.defaults.imports.dateFormat = function (date, format) {
|
||
date = new Date(date);
|
||
var map = {
|
||
"M": date.getMonth() + 1, //月份
|
||
"d": date.getDate(), //日
|
||
"h": date.getHours(), //小时
|
||
"m": date.getMinutes(), //分
|
||
"s": date.getSeconds(), //秒
|
||
"q": Math.floor((date.getMonth() + 3) / 3), //季度
|
||
"S": date.getMilliseconds() //毫秒
|
||
};
|
||
format = format.replace(/([yMdhmsqS])+/g, function (all, t) {
|
||
var v = map[t];
|
||
if (v !== undefined) {
|
||
if (all.length > 1) {
|
||
v = '0' + v;
|
||
v = v.substr(v.length - 2);
|
||
}
|
||
return v;
|
||
}
|
||
else if (t === 'y') {
|
||
return (date.getFullYear() + '').substr(4 - all.length);
|
||
}
|
||
return all;
|
||
});
|
||
return format;
|
||
};
|
||
template.defaults.imports.gfilename = function(value){
|
||
x = value.split('/').pop();
|
||
return x;
|
||
}
|
||
$.ajax({
|
||
type: "get",
|
||
url: "api/checkproject?a=checkdetail",
|
||
data: { id: id },
|
||
async: false, // ajax同步使用false
|
||
success: function (data) {
|
||
html = template('text', data);
|
||
|
||
}
|
||
});
|
||
|
||
$('#result').html(html);
|
||
|
||
</script> |