176 lines
6.1 KiB
HTML
176 lines
6.1 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 class="labeldiv">作业状态</div>
|
|
{{zyzt.zyzt}}
|
|
<div class="labeldiv">作业详情</div>
|
|
<table class='detailtable'>
|
|
<tr>
|
|
<td>作业编号:{{zynum}}</td>
|
|
<td>提交时间:{{submittime| dateFormat 'yyyy-MM-dd hh:mm'}}</td>
|
|
</tr>
|
|
<tr>
|
|
<td>作业区域:{{zyqy__name}}</td>
|
|
<td>作业地点:{{zydd}}</td>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="2">作业类型:{{zylx__dickeyname}}</td>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="2">作业内容:{{zynr}}</td>
|
|
</tr>
|
|
<tr>
|
|
<td style="width:50%">作业部门:{{zybm__partname}}</td>
|
|
<td style="width:50%">作业负责人:{{zyfzr__name}}</td>
|
|
</tr>
|
|
<tr>
|
|
<td style="width:50%">开始时间:{{kssj| dateFormat 'yyyy-MM-dd hh:mm'}}</td>
|
|
<td style="width:50%">结束时间:{{jssj| dateFormat 'yyyy-MM-dd hh:mm'}}</td>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="2">作业人员:{{zyry_names}}</td>
|
|
</tr>
|
|
</table>
|
|
<div class="labeldiv">作业人员确认详情</div>
|
|
<table class='detailtable'>
|
|
<thead>
|
|
<tr>
|
|
<th style="width:40%">
|
|
作业人员
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
{{each qrxq}}
|
|
<tr>
|
|
<td>{{$value.operzyry__name}}</td>
|
|
</tr>
|
|
{{/each}}
|
|
</table>
|
|
<div class="labeldiv">风险分析和安全措施</div>
|
|
<table class='detailtable'>
|
|
<thead>
|
|
<tr>
|
|
<th style="width:40%">
|
|
风险
|
|
</th>
|
|
<th style="width:40%">
|
|
措施
|
|
</th>
|
|
<th style="width:20%">
|
|
类型
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
{{each fxcs_}}
|
|
<tr>
|
|
<td>{{$value.fxfx}}</td>
|
|
<td>{{$value.aqcs}}</td>
|
|
<td>{{$value.cslx}}</td>
|
|
</tr>
|
|
{{/each}}
|
|
</table>
|
|
<div class="labeldiv">作业审批详情</div>
|
|
<table class='detailtable'>
|
|
<thead>
|
|
<tr>
|
|
<th style="width:30%">
|
|
节点名称
|
|
</th>
|
|
<th style="width:20%">
|
|
审批人
|
|
</th>
|
|
<th style="width:20%">
|
|
审批部门
|
|
</th>
|
|
<th style="width:30%">
|
|
提交时间
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
{{each spxq}}
|
|
<tr>
|
|
<td>{{$value.jdmc}}</td>
|
|
<td>{{$value.spr__name}}</td>
|
|
<td>{{$value.spbm__partname}}</td>
|
|
<td>{{$value.submittime| dateFormat 'yyyy-MM-dd hh:mm'}}</td>
|
|
</tr>
|
|
{{/each}}
|
|
</table>
|
|
<div class="labeldiv">现场照片</div>
|
|
<table class='detailtable'>
|
|
|
|
<tr>
|
|
{{each zyimg value index}}
|
|
<td><img onclick='bigger(this)' class='tp' width="200" height="200" src='{{value}}' /></td>
|
|
{{/each}}
|
|
</tr>
|
|
|
|
</table>
|
|
<div class="labeldiv">关闭照片</div>
|
|
<table class='detailtable'>
|
|
|
|
<tr>
|
|
{{each zyimg2 value index}}
|
|
<td><img onclick='bigger(this)' class='tp' width="200" height="200" src='{{value}}' /></td>
|
|
{{/each}}
|
|
</tr>
|
|
|
|
</table>
|
|
|
|
</div>
|
|
{% endverbatim %}
|
|
</script>
|
|
<script type="text/javascript" src="/static/safesite/mystatic/js/template-web.js"></script>
|
|
<script>
|
|
var html;
|
|
var state;
|
|
var zyid = {{ zyid }};
|
|
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/operation?a=detail",
|
|
data: { 'zyid': zyid },
|
|
async: false, // ajax同步使用false
|
|
success: function (data) {
|
|
console.log(data)
|
|
html = template('text', data);
|
|
state = data.state;
|
|
}
|
|
});
|
|
|
|
$('#result').html(html);
|
|
</script> |