@@ -25,7 +25,8 @@ | |||||
</div> | </div> | ||||
<div class="col-xs-6 lr-form-item" data-table="FillinFrom"> | <div class="col-xs-6 lr-form-item" data-table="FillinFrom"> | ||||
<div class="lr-form-item-title">填报时间</div> | <div class="lr-form-item-title">填报时间</div> | ||||
<div id="FillingTime"></div> | |||||
<div id="FillingTime1"></div> | |||||
<div id="FillingTime2"></div> | |||||
</div> | </div> | ||||
<div class="col-xs-12 lr-form-item" data-table="FillinFrom"> | <div class="col-xs-12 lr-form-item" data-table="FillinFrom"> | ||||
<div class="lr-form-item-title">公 式<font face="宋体">*</font></div> | <div class="lr-form-item-title">公 式<font face="宋体">*</font></div> | ||||
@@ -33,25 +33,37 @@ var bootstrap = function ($, learun) { | |||||
$('#lrPeople').val(learun.clientdata.get(['userinfo']).realName); | $('#lrPeople').val(learun.clientdata.get(['userinfo']).realName); | ||||
$('#lrTime').val(learun.formatDate(new Date(), 'yyyy-MM-dd hh:mm:ss')); | $('#lrTime').val(learun.formatDate(new Date(), 'yyyy-MM-dd hh:mm:ss')); | ||||
$('#FillingDept').lrDataSourceSelect({ code: 'classdata', value: 'id', text: 'name' }); | $('#FillingDept').lrDataSourceSelect({ code: 'classdata', value: 'id', text: 'name' }); | ||||
//$('#FillingPeople').lrDataSourceSelect({ code: 'teacheruserdata', value: 'f_userid', text: 'f_realname' }); | |||||
$('#FillingCycle').lrDataItemSelect({ | $('#FillingCycle').lrDataItemSelect({ | ||||
code: 'ThisCycle', | code: 'ThisCycle', | ||||
select: function (item) { | select: function (item) { | ||||
var Cycles = $("#FillingCycle").lrselectGet(); | var Cycles = $("#FillingCycle").lrselectGet(); | ||||
if (Cycles != null && Cycles != "" && Cycles != undefined && Cycles == 3) { | |||||
$('#FillingTime').lrDataItemSelect({ code: 'CycleTime' }); | |||||
} else if (Cycles != null && Cycles != "" && Cycles != undefined && Cycles == 2) { | |||||
$('#FillingTime').lrDataItemSelect({ | |||||
code: 'CycleTime', | |||||
maxHeight: 200, | |||||
if (Cycles == 3) { | |||||
$('#FillingTime1').show(); | |||||
$('#FillingTime2').hide(); | |||||
$('#FillingTime1').lrDataItemSelect({ | |||||
code: 'CycleTime' | |||||
}); | }); | ||||
//$('#FillingTime').lrDataItemSelect({ code: 'undefined' }); | |||||
} else { | |||||
$('#FillingTime').lrDataItemSelect({ code: 'undefined' }); | |||||
} else if (Cycles == 2) { | |||||
$('#FillingTime1').hide(); | |||||
//$('#FillingTime1').lrDataItemSelect({ code: 'undefined' }); | |||||
$('#FillingTime2').show(); | |||||
//$('#FillingTime2').lrDataItemSelect({ | |||||
// type: 'multiple', | |||||
// code: 'CycleTime' | |||||
//}); | |||||
} else if (Cycles == 1) { | |||||
$('#FillingTime1').show(); | |||||
$('#FillingTime2').hide(); | |||||
$('#FillingTime1').lrDataItemSelect({ code: 'undefined' }); | |||||
} | } | ||||
} | } | ||||
}); | }); | ||||
$('#lrselect').lrselect(); | |||||
$('#FillingTime1').lrselect(); | |||||
$('#FillingTime2').lrDataItemSelect({ | |||||
type: 'multiple', | |||||
code: 'CycleTime' | |||||
}); | |||||
$('#FillingTime2').hide(); | |||||
}, | }, | ||||
initData: function () { | initData: function () { | ||||
if (!!keyValue) { | if (!!keyValue) { | ||||
@@ -46,8 +46,6 @@ | |||||
<li id="lr_cancel"><a><i></i> <span class="lrlt">撤回</span></a></li> | <li id="lr_cancel"><a><i></i> <span class="lrlt">撤回</span></a></li> | ||||
<li id="lr_people"><a><i></i> <span class="lrlt">设置填报人</span></a></li> | <li id="lr_people"><a><i></i> <span class="lrlt">设置填报人</span></a></li> | ||||
<li id="lr_hide"><a><i></i> <span class="lrlt">隐藏/显示</span></a></li> | <li id="lr_hide"><a><i></i> <span class="lrlt">隐藏/显示</span></a></li> | ||||
<li id="lr_import"><a><i></i> <span class="lrlt">导入</span></a></li> | |||||
</ul> | </ul> | ||||
</div> | </div> | ||||
</div> | </div> | ||||
@@ -71,20 +71,22 @@ var bootstrap = function ($, learun) { | |||||
return; | return; | ||||
} | } | ||||
learun.layerConfirm('是否确认修改该项,修改成后会影响数据!', function (res) { | learun.layerConfirm('是否确认修改该项,修改成后会影响数据!', function (res) { | ||||
learun.layerForm({ | |||||
id: 'form', | |||||
title: '编辑', | |||||
url: top.$.rootUrl + '/EducationalAdministration/FillinFrom/Form?keyValue=' + keyValue, | |||||
width: 600, | |||||
height: 400, | |||||
callBack: function (id) { | |||||
learun.layerConfirm('确定要修改当前项吗!', function (res) { | |||||
if (res) { | |||||
return top[id].acceptClick(refreshGirdData); | |||||
} | |||||
}) | |||||
} | |||||
}); | |||||
if (res) { | |||||
learun.layerForm({ | |||||
id: 'form', | |||||
title: '编辑', | |||||
url: top.$.rootUrl + '/EducationalAdministration/FillinFrom/Form?keyValue=' + keyValue, | |||||
width: 600, | |||||
height: 400, | |||||
callBack: function (id) { | |||||
learun.layerConfirm('确定要修改当前项吗!', function (res) { | |||||
if (res) { | |||||
return top[id].acceptClick(refreshGirdData); | |||||
} | |||||
}) | |||||
} | |||||
}); | |||||
} | |||||
}) | }) | ||||
} | } | ||||
}); | }); | ||||