抽题时出现重复
This commit is contained in:
parent
323d2eb222
commit
e8f73c7847
|
@ -1,15 +1,18 @@
|
|||
<div class="easyui-layout" style="width:100%;height:100%">
|
||||
<div id='southdiv' data-options="region:'south'" style="width:100%;height:50px;text-align:center;padding:5px 0">
|
||||
<a href="javascript:void(0)" iconCls="fa-check" class="easyui-linkbutton" onclick="submitpass()" style="width:auto"
|
||||
id="pass">提交</a>
|
||||
<a href="javascript:void(0)" iconCls="fa-close" class="easyui-linkbutton" onclick="submitreject()" style="width:auto"
|
||||
id="reject">驳回</a>
|
||||
<a href="javascript:void(0)" iconCls="fa-close" class="easyui-linkbutton" onclick="closeForm()" style="width:auto">取消</a>
|
||||
<a href="javascript:void(0)" iconCls="fa-check" class="easyui-linkbutton" onclick="submitpass()"
|
||||
style="width:auto" id="pass">提交</a>
|
||||
<a href="javascript:void(0)" iconCls="fa-close" class="easyui-linkbutton" onclick="submitreject()"
|
||||
style="width:auto" id="reject">驳回</a>
|
||||
<a href="javascript:void(0)" iconCls="fa-close" class="easyui-linkbutton" onclick="closeForm()"
|
||||
style="width:auto">取消</a>
|
||||
</div>
|
||||
<div data-options="region:'center'" style="width:100%;height:100%;padding:5px 15px;">
|
||||
<div class='labeldiv'>流程信息</div>
|
||||
<div><span id="0">待新增</span><span id="1">----->待评估</span><span id="7">----->整改措施/方案待提交</span><span id="2">----->整改措施/方案待确认</span></div>
|
||||
<div><span id="3">----->待整改</span><span id="4">----->待审核</span><span id="5">----->待复查</span><span id="6">----->已归档</span></div>
|
||||
<div><span id="0">待新增</span><span id="1">----->待评估</span><span id="7">----->整改措施/方案待提交</span><span
|
||||
id="2">----->整改措施/方案待确认</span></div>
|
||||
<div><span id="3">----->待整改</span><span id="4">----->待审核</span><span id="5">----->待复查</span><span
|
||||
id="6">----->已归档</span></div>
|
||||
<form id="accessff" method="post" enctype="multipart/form-data">
|
||||
<input id="shresult" name="shresult" value="pass" style="display:none;" />
|
||||
<div id="yhxq">
|
||||
|
@ -21,8 +24,7 @@
|
|||
method: 'get',
|
||||
valueField:'value',
|
||||
textField:'text',
|
||||
"
|
||||
required=true /></div>
|
||||
" required=true /></div>
|
||||
<div style="margin-bottom:5px">
|
||||
<input editable="false" class="easyui-combobox" name="jclx" id="jclx" style="width:480px;"
|
||||
data-options="
|
||||
|
@ -30,19 +32,27 @@
|
|||
method: 'get',
|
||||
valueField:'value',
|
||||
textField:'text',
|
||||
"
|
||||
required=true /></div>
|
||||
" required=true /></div>
|
||||
<div style="margin-bottom:5px">
|
||||
<input id="fxsj" editable="false" type="text" name="fxsj" class="easyui-datetimebox" style="width:480px"
|
||||
data-options="label:'发现时间',currentText:'今天',closeText:'关闭'" required=true></div>
|
||||
<input id="fxsj" editable="false" type="text" name="fxsj" class="easyui-datetimebox"
|
||||
style="width:480px" data-options="label:'发现时间',currentText:'今天',closeText:'关闭'" required=true>
|
||||
</div>
|
||||
<div style="margin-bottom:5px">
|
||||
<input editable="false" name="yhqy" id="yhqy" style="width:480px" data-options="
|
||||
label:'发现区域',
|
||||
method: 'get',
|
||||
valueField:'id',
|
||||
textField:'name',
|
||||
" />
|
||||
</div>
|
||||
<div style="margin-bottom:5px">
|
||||
<input id="yhdd" class="easyui-textbox" name="yhdd" style="width:480px" data-options="label:'隐患地点'"
|
||||
required=true>
|
||||
</div>
|
||||
<div style="margin-bottom:5px">
|
||||
<input id="yhms" class="easyui-textbox" name="yhms" style="width:480px;height:60px" data-options="label:'隐患描述',multiline:true"
|
||||
required=true>
|
||||
<!-- <a id="duibiao" class='easyui-linkbutton' onclick="duibiaoaccess()" style="width:auto" >对标</a> -->
|
||||
<input id="yhms" class="easyui-textbox" name="yhms" style="width:480px;height:60px"
|
||||
data-options="label:'隐患描述',multiline:true" required=true>
|
||||
<!-- <a id="duibiao" class='easyui-linkbutton' onclick="duibiaoaccess()" style="width:auto" >对标</a> -->
|
||||
</div>
|
||||
|
||||
<div style="margin-bottom:5px">
|
||||
|
@ -56,7 +66,7 @@
|
|||
<input type="checkbox" onclick="shide2()" id="checkboxid2"></input>
|
||||
<label style="font-weight:bold;color:red;font-size: 18px">转交他人</label>
|
||||
<input type="checkbox" onclick="shide()" id="checkboxid"></input>
|
||||
|
||||
|
||||
</div>
|
||||
<div id="newpgr">
|
||||
<div style="margin-bottom:5px">
|
||||
|
@ -74,8 +84,7 @@
|
|||
}
|
||||
return s;
|
||||
},
|
||||
"
|
||||
required=true /></div>
|
||||
" required=true /></div>
|
||||
<div style="margin-bottom:5px">
|
||||
<input id="newr" name="newr" editable="false" class="easyui-textbox" style="width:480px"
|
||||
data-options="label:'新评估人'" required=true>
|
||||
|
@ -90,8 +99,7 @@
|
|||
method: 'get',
|
||||
valueField:'value',
|
||||
textField:'text',
|
||||
"
|
||||
required=true />
|
||||
" required=true />
|
||||
</div>
|
||||
<div style="margin-bottom:5px">
|
||||
<input class="easyui-combobox" name="yhlx" id="yhlx" style="width:480px;" editable="false"
|
||||
|
@ -101,8 +109,7 @@
|
|||
valueField:'value',
|
||||
textField:'text',
|
||||
groupField:'group'
|
||||
"
|
||||
required=true /></div>
|
||||
" required=true /></div>
|
||||
<div style="margin-bottom:5px">
|
||||
<input class="easyui-combobox" name="yhlb" id="yhlb" style="width:480px;" editable="false"
|
||||
data-options="
|
||||
|
@ -111,8 +118,7 @@
|
|||
valueField:'value',
|
||||
textField:'text',
|
||||
groupField:'group'
|
||||
"
|
||||
required=true />
|
||||
" required=true />
|
||||
</div>
|
||||
</div>
|
||||
<div id="zpzgr">
|
||||
|
@ -132,11 +138,10 @@
|
|||
}
|
||||
return s;
|
||||
},
|
||||
"
|
||||
required=true /></div>
|
||||
" required=true /></div>
|
||||
<div style="margin-bottom:5px">
|
||||
<input id="zgr" name="zgr" editable="false" class="easyui-textbox" style="width:480px" data-options="label:'整改人'"
|
||||
required=true>
|
||||
<input id="zgr" name="zgr" editable="false" class="easyui-textbox" style="width:480px"
|
||||
data-options="label:'整改人'" required=true>
|
||||
</div>
|
||||
<input id="zgqx" editable="false" type="text" name="zgqx" class="easyui-datetimebox" style="width:480px"
|
||||
data-options="label:'整改期限',currentText:'今天',closeText:'关闭'" required=true>
|
||||
|
@ -144,20 +149,23 @@
|
|||
<div id="fxcs">
|
||||
<div id="fxcsh" class='labeldiv'>措施/方案</div>
|
||||
<div style="margin-bottom:5px">
|
||||
<input id="yyfx" class="easyui-textbox" name="yyfx" style="width:480px;height:60px" data-options="label:'原因分析',multiline:true,prompt:'如不填写将由整改人填写'" />
|
||||
<input id="yyfx" class="easyui-textbox" name="yyfx" style="width:480px;height:60px"
|
||||
data-options="label:'原因分析',multiline:true,prompt:'如不填写将由整改人填写'" />
|
||||
</div>
|
||||
<div style="margin-bottom:5px">
|
||||
<input id="zgcs" class="easyui-textbox" name="zgcs" style="width:480px;height:60px" data-options="label:'整改措施',multiline:true,prompt:'如不填写将由整改人填写'" />
|
||||
<input id="zgcs" class="easyui-textbox" name="zgcs" style="width:480px;height:60px"
|
||||
data-options="label:'整改措施',multiline:true,prompt:'如不填写将由整改人填写'" />
|
||||
</div>
|
||||
</div>
|
||||
<div id="zgxq">
|
||||
<div class='labeldiv'>整改结果</div>
|
||||
<div style="margin-bottom:5px">
|
||||
<input id="zgms" class="easyui-textbox" name="zgms" style="width:480px;height:60px" data-options="label:'整改描述',multiline:true"
|
||||
required=true></div>
|
||||
<input id="zgms" class="easyui-textbox" name="zgms" style="width:480px;height:60px"
|
||||
data-options="label:'整改描述',multiline:true" required=true></div>
|
||||
<div style="margin-bottom:5px">
|
||||
<input type="hidden" name="zghtp" id="zghtp" />
|
||||
<label>整改后图片</label><input type="file" id="file2" name="" accept="image/*" style="margin-left: 15px" />
|
||||
<label>整改后图片</label><input type="file" id="file2" name="" accept="image/*"
|
||||
style="margin-left: 15px" />
|
||||
<span id='ps2' style="display:none">
|
||||
<progress id="progressBar2" value="0" max="100" style="width: 100px;"></progress>
|
||||
<span id="percentage2"></span><span id="time2"></span></span>
|
||||
|
@ -166,15 +174,18 @@
|
|||
</div>
|
||||
<div id="shyjdiv">
|
||||
<div id="shyjh" class='labeldiv'>审核信息</div>
|
||||
<input id="shyj" class="easyui-textbox" name="shyj" style="width:480px;" value="" data-options="label:'审核意见'">
|
||||
<input id="shyj" class="easyui-textbox" name="shyj" style="width:480px;" value=""
|
||||
data-options="label:'审核意见'">
|
||||
</div>
|
||||
<div id="fcyjdiv">
|
||||
<div id="fcyjh" class='labeldiv'>复查信息</div>
|
||||
<input id="fcyj" class="easyui-textbox" name="fcyj" style="width:480px;" value="" data-options="label:'审核意见'">
|
||||
<input id="fcyj" class="easyui-textbox" name="fcyj" style="width:480px;" value=""
|
||||
data-options="label:'审核意见'">
|
||||
</div>
|
||||
<div id="pgyjdiv" style="display:none">
|
||||
<div id="pgyjh" class='labeldiv'>退回原因</div>
|
||||
<input id="pgyj" class="easyui-textbox" name="pgyj" style="width:480px;" value="" data-options="label:'退回原因'">
|
||||
<input id="pgyj" class="easyui-textbox" name="pgyj" style="width:480px;" value=""
|
||||
data-options="label:'退回原因'">
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
|
@ -200,6 +211,8 @@
|
|||
$("#zgms").textbox('setValue', data.zgms);
|
||||
$("#yyfx").textbox('setValue', data.yyfx);
|
||||
$("#zgcs").textbox('setValue', data.zgcs);
|
||||
console.log(data.yhqy__name)
|
||||
// $("#yhqy").textbox('setValue', data.yhqy__name);
|
||||
var yhtp = data.yhtp;
|
||||
for (var i = 0; i < yhtp.length; i++) {
|
||||
$("#addImage").append('<li ><img title="点击放大" style="display:block;" onclick="bigger(this)" class = "yhtpimg" width="120" height="120" filepath="' + yhtp[i] + '" src="http://' + window.location.host + '/' + yhtp[i] + '"/></li>');
|
||||
|
@ -208,7 +221,7 @@
|
|||
var zghtp = data.zghtp;
|
||||
if (data.yhzt == 5) {
|
||||
if (zghtp == []) { $("#addImage2").append('<b >无图片</b>') }
|
||||
else{for (var i = 0; i < zghtp.length; i++) { $("#addImage2").append('<li style="display: inline-block; margin-right:10px;"><img onclick="bigger(this)" class = "zghtpimg" width="120" height="120" filepath="' + zghtp[i] + '" src="http://' + window.location.host + '/' + zghtp[i] + '"/></li>'); }}
|
||||
else { for (var i = 0; i < zghtp.length; i++) { $("#addImage2").append('<li style="display: inline-block; margin-right:10px;"><img onclick="bigger(this)" class = "zghtpimg" width="120" height="120" filepath="' + zghtp[i] + '" src="http://' + window.location.host + '/' + zghtp[i] + '"/></li>'); } }
|
||||
if (data.zgms == '' && data.sybzt == 0) {
|
||||
$("#pg,#zpzgr,#fxcs,#zgxq,#shyjdiv,#reject,#fcyjdiv").hide();
|
||||
} //无隐患
|
||||
|
@ -274,7 +287,7 @@
|
|||
$("#fcyjdiv").show(); $("#fcyj").textbox('setValue', data.fcyj).textbox('disable');
|
||||
$("#fcyjh").after('<div style="margin-bottom:5px"><span style="color:blue;font-weight:bold">' + data.fcr__ubelongpart__partname + ' ' + data.fcr__name + ' ' + '</span><span style="font-weight:bold">驳回该整改结果</span></div>');
|
||||
}
|
||||
if(data.sybzt==4||data.sybzt==5){
|
||||
if (data.sybzt == 4 || data.sybzt == 5) {
|
||||
for (var i = 0; i < zghtp.length; i++) { $("#addImage2").append('<li style="display: inline-block; margin-right:10px;"><img onclick="bigger(this)" class = "zghtpimg" width="120" height="120" filepath="' + zghtp[i] + '" src="http://' + window.location.host + '/' + zghtp[i] + '"/><button href="#" onclick="removep(this)" >删除</button></li>'); }
|
||||
}
|
||||
}
|
||||
|
@ -294,23 +307,25 @@
|
|||
$("#yhxqh").after('<div style="margin-bottom:5px"><span style="color:blue;font-weight:bold">' + data.fxbm__partname + ' ' + data.fxr__name + ' ' + '</span><span style="font-weight:bold">提报</span></div>');
|
||||
$("#pgh").after('<div style="margin-bottom:5px"><span style="color:blue;font-weight:bold">' + data.pgr__ubelongpart__partname + ' ' + data.pgr__name + ' ' + '</span><span style="font-weight:bold">完成评估</span></div>');
|
||||
$("#zpzgrh").after('<div style="margin-bottom:5px"><span style="color:blue;font-weight:bold">' + data.zpr__ubelongpart__partname + ' ' + data.zpr__name + ' ' + '</span><span style="font-weight:bold">指派整改</span></div>');
|
||||
if (zghtp == []){ $("#addImage2").append('<b >无图片</b>') }
|
||||
else{for (var i = 0; i < zghtp.length; i++) { $("#addImage2").append('<li style="display: inline-block; margin-right:10px;"><img onclick="bigger(this)" class = "zghtpimg" width="120" height="120" filepath="' + zghtp[i] + '" src="http://' + window.location.host + '/' + zghtp[i] + '"/></li>'); }}
|
||||
if (zghtp == []) { $("#addImage2").append('<b >无图片</b>') }
|
||||
else { for (var i = 0; i < zghtp.length; i++) { $("#addImage2").append('<li style="display: inline-block; margin-right:10px;"><img onclick="bigger(this)" class = "zghtpimg" width="120" height="120" filepath="' + zghtp[i] + '" src="http://' + window.location.host + '/' + zghtp[i] + '"/></li>'); } }
|
||||
}
|
||||
else if (data.yhzt == 1) {
|
||||
$("#yhms").textbox('disable');
|
||||
$('#fcyjdiv,#file2,#zgxq,#shyjdiv,#csyj,#reject').hide(); $('#jxpg').show();
|
||||
$("#yhpg").combobox({ url: 'getdickey?dicclass=19&a=combobox', });
|
||||
$("#zgbm").combotree({ url: 'parthandle?a=tree3', onSelect: function (node) {
|
||||
$('#zgr').combobox({
|
||||
url: 'getuser?partid=' + node.id + '&a=combobox',
|
||||
editable: false,
|
||||
filter: function (q, row) {
|
||||
var opts = $(this).combobox('options');
|
||||
return row[opts.textField].indexOf(q) >= 0;//这里改成>=即可在任意地方匹配
|
||||
},
|
||||
});
|
||||
} });
|
||||
$("#zgbm").combotree({
|
||||
url: 'parthandle?a=tree3', onSelect: function (node) {
|
||||
$('#zgr').combobox({
|
||||
url: 'getuser?partid=' + node.id + '&a=combobox',
|
||||
editable: false,
|
||||
filter: function (q, row) {
|
||||
var opts = $(this).combobox('options');
|
||||
return row[opts.textField].indexOf(q) >= 0;//这里改成>=即可在任意地方匹配
|
||||
},
|
||||
});
|
||||
}
|
||||
});
|
||||
// if (data.yhpg__dickeyname != '' & data.yhpg__dickeyname != null) {
|
||||
// $("#yhpg").combobox('setValue', data.yhpg__dickeyid).combobox('readonly');
|
||||
// $("#yhlx").combobox({ url: 'getdicclass?dicid=15' }).combobox('setValue', data.yhlx__dicid).combobox('readonly');
|
||||
|
@ -321,12 +336,12 @@
|
|||
// $("#pgh").after('<div style="margin-bottom:5px"><span style="color:blue;font-weight:bold">' + data.pgr__ubelongpart__partname + ' ' + data.pgr__name + ' ' + '</span><span style="font-weight:bold">完成评估</span></div>');
|
||||
// }
|
||||
// else {
|
||||
$("#yhlx").combobox({
|
||||
url: 'getdicclass?dicid=15', onSelect: function (node) {
|
||||
$('#yhlb').combobox({ url: 'getdickey?dicclass=' + node.value + '&a=combobox', });
|
||||
}
|
||||
});
|
||||
$("#yhxqh").after('<div style="margin-bottom:5px"><span style="color:blue;font-weight:bold">' + data.fxbm__partname + ' ' + data.fxr__name + ' ' + '</span><span style="font-weight:bold">提报</span></div>');
|
||||
$("#yhlx").combobox({
|
||||
url: 'getdicclass?dicid=15', onSelect: function (node) {
|
||||
$('#yhlb').combobox({ url: 'getdickey?dicclass=' + node.value + '&a=combobox', });
|
||||
}
|
||||
});
|
||||
$("#yhxqh").after('<div style="margin-bottom:5px"><span style="color:blue;font-weight:bold">' + data.fxbm__partname + ' ' + data.fxr__name + ' ' + '</span><span style="font-weight:bold">提报</span></div>');
|
||||
// }
|
||||
|
||||
}
|
||||
|
@ -372,16 +387,17 @@
|
|||
if ($('#checkboxid').prop('checked') == true) {
|
||||
$('#checkboxid2').attr("disabled", "disabled");
|
||||
$("#pg,#zpzgr,#fxcs").hide(); $('#newpgr').show(); $("#newbm").combotree({ url: 'parthandle?a=tree', onSelect: function (node) { $('#newr').combobox({ url: '/getuser?partid=' + node.id + '&a=combobox', }); } });
|
||||
} else {
|
||||
} else {
|
||||
$('#checkboxid2').removeAttr("disabled");
|
||||
$("#pg,#zpzgr,#fxcs").show(); $('#newpgr').hide(); $("#yhpg,#yhlx,#yhlb").combobox('clear'); $("#zgr").textbox('clear'); $("#zgqx").datetimebox('clear'); }
|
||||
$("#pg,#zpzgr,#fxcs").show(); $('#newpgr').hide(); $("#yhpg,#yhlx,#yhlb").combobox('clear'); $("#zgr").textbox('clear'); $("#zgqx").datetimebox('clear');
|
||||
}
|
||||
}
|
||||
function shide2() {
|
||||
if ($('#checkboxid2').prop('checked') == true) {
|
||||
$("#shresult").attr("value", 'reject');
|
||||
$('#checkboxid').attr("disabled", "disabled");
|
||||
$("#pg,#zpzgr,#fxcs,#newpgr").hide(); $('#pgyjdiv').show();
|
||||
} else { $("#pg,#zpzgr,#fxcs").show(); $('#newpgr,#pgyjdiv').hide(); $('#checkboxid').removeAttr("disabled");$("#shresult").attr("value", 'pass');}
|
||||
$("#pg,#zpzgr,#fxcs,#newpgr").hide(); $('#pgyjdiv').show();
|
||||
} else { $("#pg,#zpzgr,#fxcs").show(); $('#newpgr,#pgyjdiv').hide(); $('#checkboxid').removeAttr("disabled"); $("#shresult").attr("value", 'pass'); }
|
||||
}
|
||||
|
||||
function submitreject() {
|
||||
|
@ -397,20 +413,20 @@
|
|||
}
|
||||
function submit() {
|
||||
var yhdata = $('#accessff').serializeJSON();
|
||||
var a = GetQueryString("troubleid");yhdata['troubleid']=a;
|
||||
var b = GetQueryString("yhzt");yhdata['yhzt']=b;
|
||||
var checkarray=[]
|
||||
var a = GetQueryString("troubleid"); yhdata['troubleid'] = a;
|
||||
var b = GetQueryString("yhzt"); yhdata['yhzt'] = b;
|
||||
var checkarray = []
|
||||
if (b == 3) { var checkarray = [yhdata['zgms']]; }
|
||||
else if (b == 1) {
|
||||
if ($('#checkboxid').prop('checked') == true) { var checkarray = [yhdata['yhms'], yhdata['newbm'], yhdata['newr']]; yhdata['zppg']='yes'; }
|
||||
else if($('#checkboxid2').prop('checked') == true){yhdata['accept']='yes'}
|
||||
else { var checkarray = [yhdata['yhms'], yhdata['yhpg'], yhdata['yhlx'], yhdata['yhlb'], yhdata['zgbm'], yhdata['zgr'], yhdata['zgqx']]; yhdata['zppg']='no'; }
|
||||
if ($('#checkboxid').prop('checked') == true) { var checkarray = [yhdata['yhms'], yhdata['newbm'], yhdata['newr']]; yhdata['zppg'] = 'yes'; }
|
||||
else if ($('#checkboxid2').prop('checked') == true) { yhdata['accept'] = 'yes' }
|
||||
else { var checkarray = [yhdata['yhms'], yhdata['yhpg'], yhdata['yhlx'], yhdata['yhlb'], yhdata['zgbm'], yhdata['zgr'], yhdata['zgqx']]; yhdata['zppg'] = 'no'; }
|
||||
}
|
||||
else if (b == 7) { var checkarray = [yhdata['zgcs']] }
|
||||
else if (b == 2) { var checkarray = [yhdata['zgcs']] }
|
||||
var zghtp = new Array();
|
||||
$(".zghtpimg").each(function () { zghtp.push($(this).attr("filepath")); });
|
||||
yhdata['zghtp']=zghtp
|
||||
yhdata['zghtp'] = zghtp
|
||||
console.log(yhdata)
|
||||
if (myCheck(checkarray)) {
|
||||
$.ajax({
|
||||
|
@ -518,32 +534,32 @@
|
|||
}
|
||||
|
||||
}
|
||||
function duibiaoaccess(){
|
||||
var yhmsdata = $('#yhms').val()
|
||||
loading('正在比对,请稍等..');
|
||||
$.post('api/duibiao', { 'yhms': yhmsdata }, function (result, status) {
|
||||
if (result.code = 1) {
|
||||
html = '<p style="color:red;margin-left: 10px">根据您的描述,搜索到以下安标结果:</p>'
|
||||
for (var j = 0, len = result.data.length; j < len; j++) {
|
||||
html = html + '<p style="margin-left: 10px;margin-right: 10px">' + result.data[j] + '</p>'
|
||||
}
|
||||
$("<div/>").dialog({
|
||||
title: '对标结果',
|
||||
width: 800,
|
||||
height: 400,
|
||||
closed: false,
|
||||
cache: false,
|
||||
content: html,
|
||||
modal: true,
|
||||
border: false,
|
||||
onClose: function () {
|
||||
$(this).dialog('close');
|
||||
}
|
||||
});
|
||||
function duibiaoaccess() {
|
||||
var yhmsdata = $('#yhms').val()
|
||||
loading('正在比对,请稍等..');
|
||||
$.post('api/duibiao', { 'yhms': yhmsdata }, function (result, status) {
|
||||
if (result.code = 1) {
|
||||
html = '<p style="color:red;margin-left: 10px">根据您的描述,搜索到以下安标结果:</p>'
|
||||
for (var j = 0, len = result.data.length; j < len; j++) {
|
||||
html = html + '<p style="margin-left: 10px;margin-right: 10px">' + result.data[j] + '</p>'
|
||||
}
|
||||
removeLoading()
|
||||
});
|
||||
|
||||
}
|
||||
$("<div/>").dialog({
|
||||
title: '对标结果',
|
||||
width: 800,
|
||||
height: 400,
|
||||
closed: false,
|
||||
cache: false,
|
||||
content: html,
|
||||
modal: true,
|
||||
border: false,
|
||||
onClose: function () {
|
||||
$(this).dialog('close');
|
||||
}
|
||||
});
|
||||
}
|
||||
removeLoading()
|
||||
});
|
||||
|
||||
}
|
||||
</script>
|
||||
</div>
|
|
@ -30,10 +30,19 @@
|
|||
textField:'text',
|
||||
" />
|
||||
</div>
|
||||
|
||||
<div style="margin-bottom:5px">
|
||||
<input id="fxsj" editable="false" type="text" name="fxsj" class="easyui-datetimebox" style="width:480px"
|
||||
data-options="label:'发现时间',currentText:'今天',closeText:'关闭',showSeconds:false" required=true />
|
||||
</div>
|
||||
<div style="margin-bottom:5px">
|
||||
<input editable="false" name="yhqy" id="yhqy" style="width:480px" data-options="
|
||||
label:'发现区域',
|
||||
method: 'get',
|
||||
valueField:'id',
|
||||
textField:'name',
|
||||
" />
|
||||
</div>
|
||||
<div style="margin-bottom:5px">
|
||||
<input id="yhdd" class="easyui-textbox" name="yhdd" style="width:480px" data-options="label:'隐患地点'"
|
||||
required=true />
|
||||
|
@ -179,6 +188,7 @@
|
|||
}
|
||||
});
|
||||
$("#jclx").combobox({ url: 'getdickey?dicclass=14&a=combobox', });
|
||||
$("#yhqy").combobox({ url: 'api/area?a=tree', });
|
||||
$('#pg,#zghxq,#fxcs,#zpzgr').hide();
|
||||
if (a == 'edityh') {
|
||||
$.ajax({
|
||||
|
@ -192,6 +202,7 @@
|
|||
$("#yhdd").textbox('setValue', data.yhdd);
|
||||
$("#yhms").textbox('setValue', data.yhms);
|
||||
$("#fxsj").datetimebox('setValue', data.fxsj);
|
||||
$("#yhqy").combobox('setValue', data.yhqy__id);
|
||||
if (data.yhtp != '') {
|
||||
var yhtp = data.yhtp
|
||||
for (var i = 0; i < yhtp.length; i++) { $("#addImage").append('<li ><img style="display:block;" onclick ="bigger(this)" class = "yhtpimg" width="120" height="120" filepath="' + yhtp[i] + '" src="http://' + window.location.host + '/' + yhtp[i] + '"/><button onclick="removep(this)" >删除</button></li>'); }
|
||||
|
|
|
@ -1221,7 +1221,7 @@ def getyh(req):
|
|||
userid = req.session['userid']
|
||||
troubleid = req.GET.get('troubleid')
|
||||
a = Trouble.objects.filter(troubleid=troubleid).values('sybzt', 'troubleid', 'fxr__userid', 'fxr__name', 'yhms', 'yhzt', 'fxsj', 'tbsj', 'yhlb__dickeyname', 'yhlb__dickeyid', 'todouser__name', 'yhpg__dickeyname', 'yhnum', 'yhdd', 'fxbm__partname', 'yhdj__dickeyname', 'yhdj__dickeyid', 'yhpg__dickeyname', 'yhpg__dickeyid', 'jclx__dickeyname', 'jclx__dickeyid', 'yhlx__dicname',
|
||||
'yhlx__dicid', 'yyfx', 'zgcs', 'yhtp', 'zghtp', 'zgms', 'zgbm__partname', 'zgbm__partid', 'zgr__name', 'zgqx', 'fcr__ubelongpart__partname', 'fcr__name', 'shr__ubelongpart__partname', 'shr__name', 'pgr__ubelongpart__partname', 'pgr__name', 'zpr__ubelongpart__partname', 'zpr__name', 'csqrr__ubelongpart__partname', 'csqrr__name', 'shyj', 'fcyj', 'shresult', 'zgbm', 'zgr', 'pgyj')[0]
|
||||
'yhlx__dicid', 'yyfx', 'zgcs', 'yhtp', 'zghtp', 'zgms', 'zgbm__partname', 'zgbm__partid', 'zgr__name', 'zgqx', 'fcr__ubelongpart__partname', 'fcr__name', 'shr__ubelongpart__partname', 'shr__name', 'pgr__ubelongpart__partname', 'pgr__name', 'zpr__ubelongpart__partname', 'zpr__name', 'csqrr__ubelongpart__partname', 'csqrr__name', 'shyj', 'fcyj', 'shresult', 'zgbm', 'zgr', 'pgyj', 'yhqy__name', 'yhqy__id')[0]
|
||||
# print(a['yhtp'])
|
||||
if a['yhtp'] != '':
|
||||
a['yhtp'] = a['yhtp'].split('?')
|
||||
|
@ -1893,7 +1893,7 @@ def troublehandle(req):
|
|||
troubleid = req.GET.get('troubleid')
|
||||
a = Trouble.objects.filter(troubleid=troubleid)
|
||||
x = a.values('yhnum', 'fxr__name', 'yhms', 'yhzt', 'fxsj', 'tbsj', 'yhlb__dickeyname', 'yhpg__dickeyname', 'yhdd', 'fxbm__partname', 'yhdj__dickeyname', 'yhpg__dickeyname',
|
||||
'jclx__dickeyname', 'yhlx__dicname', 'yyfx', 'zgcs', 'yhtp', 'zghtp', 'zgms', 'zgbm__partname', 'zgr__name', 'zgqx', 'yhqy__name')[0]
|
||||
'jclx__dickeyname', 'yhlx__dicname', 'yyfx', 'zgcs', 'yhtp', 'zghtp', 'zgms', 'zgbm__partname', 'zgr__name', 'zgqx', 'yhqy__name', 'yhqy__id')[0]
|
||||
b = TroubleAccess.objects.filter(troubleid=a[0]).order_by(
|
||||
'accesssj').values('clr__name', 'opinion', 'action', 'accesssj')
|
||||
x['lcxq'] = list(b)
|
||||
|
@ -6270,8 +6270,7 @@ def apiexamtest(req):
|
|||
objpaper.total = {'total': {'num': totalnum, 'score': totalscore}, 'dx': {
|
||||
'num': dxnum, 'score': dxs}, 'duox': {'num': duoxnum, 'score': duoxs}, 'pd': {'num': pdnum, 'score': pds}}
|
||||
objpaper.save()
|
||||
questionobjs = Question.objects.filter(
|
||||
questioncat__id__in=data['tmfls'])
|
||||
questionobjs = Question.objects.filter(questioncat__id__in=data['tmfls'], deletemark=1)
|
||||
if 'repeat' in data and data['repeat'] == 'no':
|
||||
excludequestions = ExamTest.objects.filter(usecomps__contains=','+companyid +
|
||||
',').exclude(nousecomps__contains=','+companyid+',').values_list('exampaper__question__id',flat=True).distinct()
|
||||
|
@ -6791,7 +6790,7 @@ def apiarea(req):
|
|||
mapobj = Map.objects.filter(usecomp__partid=companyid, deletemark=1)
|
||||
if mapobj.count() == 1:
|
||||
objs = Area.objects.filter(belongmap=mapobj[0], deletemark=1).order_by(
|
||||
'order').values('id', 'name')
|
||||
'order').annotate(parentId=F('parent__id')).values('id', 'parentId', 'name')
|
||||
return HttpResponse(json.dumps(list(objs)), content_type="application/json")
|
||||
elif a == 'add':
|
||||
data = json.loads(req.body.decode('utf-8'))
|
||||
|
|
Loading…
Reference in New Issue