@@ -49,6 +49,15 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers | |||
ViewBag.ClassNo = ClassNos.TrimEnd(','); | |||
return View(); | |||
} | |||
/// <summary> | |||
/// 主页面【二级学院】 | |||
/// </summary> | |||
/// <returns></returns> | |||
[HttpGet] | |||
public ActionResult IndexOfTwo() | |||
{ | |||
return View(); | |||
} | |||
#endregion | |||
#region 获取数据 | |||
@@ -135,6 +144,32 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers | |||
stuFellowshipIBLL.SaveEntity(keyValue, entity); | |||
return Success("保存成功!"); | |||
} | |||
/// <summary> | |||
/// 提交 | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
/// <returns></returns> | |||
[HttpPost] | |||
[AjaxOnly] | |||
public ActionResult DoSubmit(string keyValue, string status, string step) | |||
{ | |||
stuFellowshipIBLL.DoSubmit(keyValue, status, step); | |||
return Success("操作成功!"); | |||
} | |||
/// <summary> | |||
/// 退回 | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
/// <returns></returns> | |||
[HttpPost] | |||
[AjaxOnly] | |||
public ActionResult DoBack(string keyValue, string status, string step) | |||
{ | |||
stuFellowshipIBLL.DoBack(keyValue, status, step); | |||
return Success("操作成功!"); | |||
} | |||
#endregion | |||
} | |||
@@ -6,74 +6,82 @@ | |||
var classs = "@ViewBag.ClassNo"; | |||
</script> | |||
<div class="lr-form-wrap" id="form"> | |||
<div class="col-xs-6 lr-form-item" data-table="StuFellowship" style="display:none;"> | |||
<div class="lr-form-item-title">助学金类型</div> | |||
<input id="Types" type="text" class="form-control" /> | |||
</div> | |||
<div class="col-xs-6 lr-form-item" data-table="StuFellowship"> | |||
<div class="lr-form-item-title">学号<font face="宋体">*</font></div> | |||
<input id="StuNo" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" /> | |||
<input id="DeptNo" type="text" class="form-control" style="display:none" /> | |||
<input id="MajorNo" type="text" class="form-control" style="display:none" /> | |||
<input id="ClassNo" type="text" class="form-control" style="display:none" /> | |||
<input id="OpenBank" type="text" class="form-control" style="display:none" /> | |||
<input id="OpenAccount" type="text" class="form-control" style="display:none" /> | |||
<div id="StuNo" isvalid="yes" checkexpession="NotNull"></div> | |||
</div> | |||
<div class="col-xs-6 lr-form-item" data-table="StuFellowship"> | |||
<div class="lr-form-item-title">姓名</div> | |||
<input id="StuName" type="text" class="form-control" readonly="readonly" /> | |||
</div> | |||
<div class="col-xs-6 lr-form-item" data-table="StuFellowship"> | |||
<div class="lr-form-item-title">院校</div> | |||
<div id="F_SchoolId" readonly="readonly"></div> | |||
</div> | |||
<div class="col-xs-6 lr-form-item" data-table="StuFellowship"> | |||
<div class="lr-form-item-title">姓名<font face="宋体" >*</font></div> | |||
<input id="StuName" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" readonly /> | |||
</div> | |||
@*<div class="col-xs-6 lr-form-item"> | |||
<div class="lr-form-item-title">系部<font face="宋体">*</font></div> | |||
<div id="DeptNo" isvalid="yes" checkexpession="NotNull"></div> | |||
</div> | |||
<div class="col-xs-6 lr-form-item"> | |||
<div class="lr-form-item-title">专业<font face="宋体">*</font></div> | |||
<div id="MajorNo" isvalid="yes" checkexpession="NotNull"></div> | |||
</div> | |||
<div class="col-xs-6 lr-form-item"> | |||
<div class="lr-form-item-title">班级<font face="宋体">*</font></div> | |||
<div id="ClassNo" isvalid="yes" checkexpession="NotNull"></div> | |||
</div>*@ | |||
<div class="col-xs-6 lr-form-item"> | |||
<div class="lr-form-item-title" data-table="StuFellowship">证件类型<font face="宋体">*</font></div> | |||
<div class="lr-form-item-title">班级</div> | |||
<div id="ClassNo" readonly="readonly"></div> | |||
</div> | |||
<div class="col-xs-6 lr-form-item" data-table="StuFellowship"> | |||
<div class="lr-form-item-title">身份证件类型<font face="宋体">*</font></div> | |||
<div id="IdCardType" isvalid="yes" checkexpession="NotNull"></div> | |||
</div> | |||
<div class="col-xs-6 lr-form-item"> | |||
<div class="lr-form-item-title" data-table="StuFellowship">身份证号<font face="宋体">*</font></div> | |||
<input id="IdentityCardNo" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" readonly/> | |||
<div class="col-xs-6 lr-form-item" data-table="StuFellowship"> | |||
<div class="lr-form-item-title">身份证件号</div> | |||
<input id="IdentityCardNo" type="text" class="form-control" readonly="readonly" /> | |||
</div> | |||
<div class="col-xs-6 lr-form-item"> | |||
<div class="lr-form-item-title" data-table="StuFellowship">开户行号<font face="宋体">*</font></div> | |||
<div class="col-xs-6 lr-form-item" data-table="StuFellowship"> | |||
<div class="lr-form-item-title">开户银行</div> | |||
<div id="OpenBank" readonly="readonly"></div> | |||
</div> | |||
<div class="col-xs-6 lr-form-item" data-table="StuFellowship"> | |||
<div class="lr-form-item-title">开户卡账号</div> | |||
<input id="OpenAccount" type="text" class="form-control" readonly="readonly" /> | |||
</div> | |||
<div class="col-xs-6 lr-form-item" data-table="StuFellowship"> | |||
<div class="lr-form-item-title">开户行号<font face="宋体">*</font></div> | |||
<input id="OpenBankNo" type="text" class="form-control" readonly value="20230307230" /> | |||
</div> | |||
<div class="col-xs-6 lr-form-item"> | |||
<div class="lr-form-item-title" data-table="StuFellowship">资助等级<font face="宋体">*</font></div> | |||
<div class="col-xs-6 lr-form-item" data-table="StuFellowship"> | |||
<div class="lr-form-item-title">资助等级<font face="宋体">*</font></div> | |||
<div id="SubsidizeType" isvalid="yes" checkexpession="NotNull"></div> | |||
</div> | |||
<div class="col-xs-4 lr-form-item"> | |||
<div class="lr-form-item-title" data-table="StuFellowship">资助标准<font face="宋体">*</font></div> | |||
<input id="FunderNationStandard" type="text" class="form-control" readonly/> | |||
<div class="col-xs-4 lr-form-item" data-table="StuFellowship"> | |||
<div class="lr-form-item-title">资助标准<font face="宋体">*</font></div> | |||
<input id="FunderNationStandard" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" readonly /> | |||
</div> | |||
<div class="col-xs-4 lr-form-item" data-table="StuFellowship"> | |||
<div class="lr-form-item-title">应发金额<font face="宋体">*</font></div> | |||
<input id="AmountPayable" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" readonly /> | |||
</div> | |||
<div class="col-xs-4 lr-form-item"> | |||
<div class="lr-form-item-title" data-table="StuFellowship">应发金额<font face="宋体">*</font></div> | |||
<input id="AmountPayable" type="text" class="form-control" readonly /> | |||
<div class="col-xs-4 lr-form-item" data-table="StuFellowship"> | |||
<div class="lr-form-item-title">实发金额<font face="宋体">*</font></div> | |||
<input id="FinalPayingAmount" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" readonly /> | |||
</div> | |||
<div class="col-xs-4 lr-form-item"> | |||
<div class="lr-form-item-title" data-table="StuFellowship">实发金额<font face="宋体">*</font></div> | |||
<input id="FinalPayingAmount" type="text" class="form-control" readonly /> | |||
<div class="col-xs-6 lr-form-item" data-table="StuFellowship"> | |||
<div class="lr-form-item-title">申请日期<font face="宋体">*</font></div> | |||
<input id="ApplyDate" type="text" class="form-control lr-input-wdatepicker" onfocus="WdatePicker({ dateFmt: 'yyyy-MM-dd', onpicked: function() { $('#ApplyDate').trigger('change'); } })" isvalid="yes" checkexpession="NotNull" /> | |||
</div> | |||
<div class="col-xs-6 lr-form-item"> | |||
<div class="lr-form-item-title" data-table="StuFellowship">申请日期<font face="宋体">*</font></div> | |||
<input id="CreateDate" type="text" class="form-control lr-input-wdatepicker" onfocus="WdatePicker({ dateFmt: 'yyyy-MM-dd', onpicked: function() { $('#Birthday').trigger('change'); } })" isvalid="yes" checkexpession="NotNull" /> | |||
<div class="col-xs-6 lr-form-item" data-table="StuFellowship"> | |||
<div class="lr-form-item-title">发放日期<font face="宋体">*</font></div> | |||
<input id="ReleaseDate" type="text" class="form-control lr-input-wdatepicker" onfocus="WdatePicker({ dateFmt: 'yyyy-MM-dd', onpicked: function() { $('#ReleaseDate').trigger('change'); } })" isvalid="yes" checkexpession="NotNull" /> | |||
</div> | |||
<div class="col-xs-6 lr-form-item"> | |||
<div class="lr-form-item-title" data-table="StuFellowship">发放日期<font face="宋体">*</font></div> | |||
<input id="ReleaseDate" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" /> | |||
<div class="col-xs-12 lr-form-item" data-table="StuFellowship"> | |||
<div class="lr-form-item-title">申请理由<font face="宋体">*</font></div> | |||
<textarea id="ApplyReason" class="form-control" style="height: 100px;" isvalid="yes" checkexpession="NotNull"></textarea> | |||
</div> | |||
<div class="col-xs-12 lr-form-item"> | |||
<div class="lr-form-item-title" data-table="StuFellowship">申请理由<font face="宋体">*</font></div> | |||
<textarea id="ApplyReason" class="form-control" style="height: 100px;"></textarea> | |||
<div class="col-xs-12 lr-form-item" data-table="StuFellowship"> | |||
<div class="lr-form-item-title">备注说明</div> | |||
<textarea id="Remark" class="form-control" style="height: 50px;" isvalid="yes" checkexpession="LenStrOrNull" length="100" placeholder="字符长度最多为100位"></textarea> | |||
</div> | |||
<div class="col-xs-12 lr-form-item"> | |||
<div class="lr-form-item-title" data-table="StuFellowship">备注</div> | |||
<textarea id="Remark" class="form-control" style="height: 100px;"></textarea> | |||
<div class="col-xs-12 lr-form-item" id="FilesDiv"> | |||
<div class="lr-form-item-title">附件</div> | |||
<div id="Files"></div> | |||
</div> | |||
</div> | |||
@Html.AppendJsFile("/Areas/EducationalAdministration/Views/StuFellowship/Form.js") |
@@ -6,24 +6,45 @@ | |||
*/ | |||
var acceptClick; | |||
var keyValue = request('keyValue'); | |||
var Step = request('Step');//第几步 | |||
var Types = request('Types');//助学金类型:1国家助学金,2校级助学金 | |||
if (Types != null && Types != undefined && Types != "") { | |||
$('#Types').val(Types); | |||
} | |||
var bootstrap = function ($, learun) { | |||
"use strict"; | |||
var page = { | |||
init: function () { | |||
$('.lr-form-wrap').lrscroll(); | |||
page.initData(); | |||
page.hide(); | |||
page.bind(); | |||
page.initData(); | |||
}, | |||
hide: function () { | |||
if (Step == "2") {//第二步:二级学院审核,时附件显示且必填; | |||
$('#FilesDiv').show(); | |||
$('#Files').attr('isvalid', 'yes'); | |||
$('#Files').attr('checkexpession', 'NotNull'); | |||
$('#Files').prev().html('附件<font face="宋体">*</font>'); | |||
} else { | |||
$('#Files').removeAttr('isvalid'); | |||
$('#Files').removeAttr('checkexpession'); | |||
$('#Files').prev().html('附件'); | |||
$('#FilesDiv').hide(); | |||
} | |||
}, | |||
bind: function () { | |||
$('#F_SchoolId').lrDataSourceSelect({ code: 'company', value: 'f_companyid', text: 'f_fullname' }); | |||
$('#ClassNo').lrDataSourceSelect({ code: 'bjsj', value: 'classno', text: 'classname' }); | |||
$('#IdCardType').lrDataItemSelect({ code: 'IdCardType' }); | |||
$('#IdCardType').lrselectSet("01"); | |||
$('#OpenBank').lrDataItemSelect({ code: 'DepositBank' }); | |||
//判断登录用户所带班级:学生弹框显示所带班级学生 | |||
if (classs != "" && classs != undefined && classs != null) { | |||
$('#StuNo').lrGirdSelect({ | |||
// 字段 | |||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=StuInfoBasic', | |||
param: { strWhere: " 1=1 and classno in (" + classs + ") order by deptno,majorno,classno,grade desc" }, | |||
selectWord: 'stuno', | |||
selectWord: 'stuname', | |||
value: 'stuno', | |||
text: 'stuno', | |||
headData: [ | |||
@@ -78,28 +99,23 @@ var bootstrap = function ($, learun) { | |||
{ label: "年级", name: "grade", width: 100, align: "left" } | |||
], | |||
select: function (item) { | |||
$("#StuNo").val(item.stuno); | |||
console.log(item); | |||
//自动带出内容:姓名 院校 班级 身份证件号 身份证件类型 开户银行 开户卡账号 | |||
$("#StuName").val(item.stuname); | |||
$("#F_SchoolId").lrselectSet(item.f_schoolid); | |||
$("#ClassNo").lrselectSet(item.classno); | |||
$("#IdentityCardNo").val(item.identitycardno); | |||
$("#DeptNo").val(item.deptno); | |||
$("#MajorNo").val(item.majorno); | |||
$("#ClassNo").val(item.classno); | |||
$("#OpenBank").val(item.depositbank); | |||
$("#OpenBank").lrselectSet(item.depositbank); | |||
$("#OpenAccount").val(item.bankcard); | |||
//绑定值到下拉框 1 | |||
//$("#DeptNo").lrselectSet(item.deptno); | |||
//$("#MajorNo").lrselectSet(item.majorno); | |||
//$('#ClassNo').lrselectSet(item.bankcard); | |||
//$('#DepositBank').lrselectSet(item.depositbank); | |||
$('#IdCardType').lrselectSet("01"); | |||
} | |||
}); | |||
} else { | |||
$('#StuNo').lrGirdSelect({ | |||
// 字段 | |||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=StuInfoBasic', | |||
param: { strWhere: " 1=1 " }, | |||
selectWord: 'stuno', | |||
selectWord: 'stuname', | |||
value: 'stuno', | |||
text: 'stuno', | |||
headData: [ | |||
@@ -154,37 +170,48 @@ var bootstrap = function ($, learun) { | |||
{ label: "年级", name: "grade", width: 100, align: "left" } | |||
], | |||
select: function (item) { | |||
$("#StuNo").val(item.stuno); | |||
//自动带出内容:姓名 院校 班级 身份证件号 身份证件类型 开户银行 开户卡账号 | |||
$("#StuName").val(item.stuname); | |||
$("#F_SchoolId").lrselectSet(item.f_schoolid); | |||
$("#ClassNo").lrselectSet(item.classno); | |||
$("#IdentityCardNo").val(item.identitycardno); | |||
$("#DeptNo").val(item.deptno); | |||
$("#MajorNo").val(item.majorno); | |||
$("#ClassNo").val(item.classno); | |||
$("#OpenBank").val(item.depositbank); | |||
$("#OpenBank").lrselectSet(item.depositbank); | |||
$("#OpenAccount").val(item.bankcard); | |||
//绑定值到下拉框 1 | |||
//$("#DeptNo").lrselectSet(item.deptno); | |||
//$("#MajorNo").lrselectSet(item.majorno); | |||
//$('#ClassNo').lrselectSet(item.bankcard); | |||
//$('#DepositBank').lrselectSet(item.depositbank); | |||
$('#IdCardType').lrselectSet("01"); | |||
} | |||
}); | |||
} | |||
$('#SubsidizeType').lrDataItemSelect({ | |||
code: 'StateStipend', | |||
select: function (item) { | |||
if (item != null && item != undefined) { | |||
$("#FunderNationStandard").val(item.id); | |||
$("#FinalPayingAmount").val(item.id); | |||
$("#AmountPayable").val(item.id); | |||
//判断助学金类型:1国家助学金,2校级助学金 | |||
if (Types == "1") { | |||
$('#SubsidizeType').lrDataItemSelect({ | |||
code: 'StateStipend', | |||
select: function (item) { | |||
//系统自动带出标准、应发金额和实发金额 | |||
if (item != null && item != undefined) { | |||
$("#FunderNationStandard").val(item.id); | |||
$("#FinalPayingAmount").val(item.id); | |||
$("#AmountPayable").val(item.id); | |||
} | |||
} | |||
}); | |||
} else if (Types == "2") { | |||
$('#SubsidizeType').lrDataItemSelect({ | |||
code: 'SchoolStipend', | |||
select: function (item) { | |||
//系统自动带出标准、应发金额和实发金额 | |||
if (item != null && item != undefined) { | |||
$("#FunderNationStandard").val(item.id); | |||
$("#FinalPayingAmount").val(item.id); | |||
$("#AmountPayable").val(item.id); | |||
} | |||
} | |||
} | |||
}); | |||
//绑定值到下拉框 2 | |||
//$('#DeptNo').lrDataSourceSelect({ code: 'CdDeptInfo', value: 'deptno', text: 'deptname' }); | |||
//$('#MajorNo').lrDataSourceSelect({ code: 'CdMajorInfo', value: 'majorno', text: 'majorname' }); | |||
//$('#ClassNo').lrDataSourceSelect({ code: 'bjsj', value: 'classno', text: 'classname' }); | |||
}); | |||
} | |||
//申请时间:默认当天 | |||
$('#ApplyDate').val(getNowDate()); | |||
$('#Files').lrUploader(); | |||
}, | |||
initData: function () { | |||
if (!!keyValue) { | |||
@@ -194,20 +221,11 @@ var bootstrap = function ($, learun) { | |||
$('#' + id).jfGridSet('refreshdata', data[id]); | |||
} | |||
else { | |||
$('[data-table="' + id + '"]').lrSetFormData(data[id]); | |||
} | |||
} | |||
$("#CreateDate").val(data.StuFellowship.CreateDate); | |||
$('#SubsidizeType').lrselectSet(data.StuFellowship.SubsidizeType); | |||
$("#FunderNationStandard").val(data.StuFellowship.FunderNationStandard); | |||
$("#AmountPayable").val(data.StuFellowship.AmountPayable); | |||
$("#ApplyReason").val(data.StuFellowship.ApplyReason); | |||
$("#ReleaseDate").val(data.StuFellowship.ReleaseDate) | |||
$("#FinalPayingAmount").val(data.StuFellowship.FinalPayingAmount) | |||
$("#ApplyReason").val(data.StuFellowship.ApplyReason) | |||
$("#Remark").val(data.StuFellowship.Remark) | |||
}); | |||
} | |||
} | |||
@@ -217,12 +235,11 @@ var bootstrap = function ($, learun) { | |||
if (!$('#form').lrValidform()) { | |||
return false; | |||
} | |||
var postData = $('body').lrGetFormData(); | |||
postData.State = 1; | |||
postData.Types = 1; | |||
var postData = $('#form').lrGetFormData(); | |||
var postDatas = { | |||
strEntity: JSON.stringify(postData) | |||
}; | |||
$.lrSaveForm(top.$.rootUrl + '/EducationalAdministration/StuFellowship/SaveForm?keyValue=' + keyValue, postDatas, function (res) { | |||
// 保存成功后才回调 | |||
if (!!callBack) { | |||
@@ -232,3 +249,19 @@ var bootstrap = function ($, learun) { | |||
}; | |||
page.init(); | |||
} | |||
//获取当前时间 | |||
function getNowDate() { | |||
var myDate = new Date; | |||
var year = myDate.getFullYear(); //获取当前年 | |||
var mon = myDate.getMonth() + 1; //获取当前月 | |||
var date = myDate.getDate(); //获取当前日 | |||
var h = myDate.getHours();//获取当前小时数(0-23) | |||
var m = myDate.getMinutes();//获取当前分钟数(0-59) | |||
var s = myDate.getSeconds();//获取当前秒 | |||
var week = myDate.getDay(); | |||
var weeks = ["星期日", "星期一", "星期二", "星期三", "星期四", "星期五", "星期六"]; | |||
//console.log(year, mon, date, weeks[week]) | |||
var result = year + "-" + mon + "-" + date; | |||
return result; | |||
} |
@@ -2,39 +2,51 @@ | |||
ViewBag.Title = "助学金管理"; | |||
Layout = "~/Views/Shared/_Index.cshtml"; | |||
} | |||
<style> | |||
.datesearchLabel { | |||
float: left; | |||
line-height: 28px; | |||
height: 40px; | |||
padding-top: 13px; | |||
padding-left: 5px; | |||
} | |||
.datesearchLabel:first-child { | |||
padding-left: 0px; | |||
} | |||
</style> | |||
<div class="lr-layout"> | |||
<div class="lr-layout-center"> | |||
<div class="lr-layout-wrap lr-layout-wrap-notitle"> | |||
<div class="lr-layout-tool"> | |||
<div class="lr-layout-tool-left"> | |||
<div class="datesearchLabel">申请</div> | |||
<div class="lr-layout-tool-item"> | |||
<div id="datesearch"></div> | |||
</div> | |||
<div class="datesearchLabel">发放</div> | |||
<div class="lr-layout-tool-item"> | |||
<div id="datesearchRelease"></div> | |||
</div> | |||
<div class="lr-layout-tool-item"> | |||
<div id="multiple_condition_query"> | |||
<div class="lr-query-formcontent"> | |||
<div class="col-xs-6 lr-form-item"> | |||
<div class="col-xs-12 lr-form-item"> | |||
<div class="lr-form-item-title">学号</div> | |||
<input id="StuNo" type="text" class="form-control" /> | |||
</div> | |||
<div class="col-xs-6 lr-form-item"> | |||
<div class="col-xs-12 lr-form-item"> | |||
<div class="lr-form-item-title">姓名</div> | |||
<input id="StuName" type="text" class="form-control" /> | |||
</div> | |||
<div class="col-xs-12 lr-form-item"> | |||
<div class="lr-form-item-title">系部</div> | |||
<div id="DeptNo"></div> | |||
</div> | |||
<div class="col-xs-12 lr-form-item"> | |||
<div class="lr-form-item-title">专业</div> | |||
<div id="MajorNo"></div> | |||
<div class="lr-form-item-title">院系</div> | |||
<div id="F_SchoolId"></div> | |||
</div> | |||
<div class="col-xs-12 lr-form-item"> | |||
<div class="lr-form-item-title">班级</div> | |||
<div id="ClassNo"></div> | |||
</div> | |||
<div class="col-xs-12 lr-form-item"> | |||
<div class="lr-form-item-title">发放日期</div> | |||
<input id="ReleaseDate" type="text" class="form-control" /> | |||
</div> | |||
<div class="col-xs-12 lr-form-item"> | |||
<div class="lr-form-item-title">身份证号</div> | |||
<input id="IdentityCardNo" type="text" class="form-control" /> | |||
@@ -44,29 +56,25 @@ | |||
<div id="SubsidizeType"></div> | |||
</div> | |||
<div class="col-xs-12 lr-form-item"> | |||
<div class="lr-form-item-title">开户行</div> | |||
<div id="OpenBank"></div> | |||
</div> | |||
<div class="col-xs-12 lr-form-item"> | |||
<div class="lr-form-item-title">开户行账户</div> | |||
<input id="OpenAccount" type="text" class="form-control" /> | |||
<div class="lr-form-item-title">开户行户</div> | |||
<input id="OpenBankNo" type="text" class="form-control" /> | |||
</div> | |||
</div> | |||
</div> | |||
</div> | |||
<div class="lr-layout-tool-item"> | |||
<div id="datesearch"></div> | |||
</div> | |||
</div> | |||
<div class="lr-layout-tool-right"> | |||
<div class=" btn-group btn-group-sm"> | |||
<a id="lr_refresh" class="btn btn-default"><i class="fa fa-refresh"></i></a> | |||
</div> | |||
<div class=" btn-group btn-group-sm" learun-authorize="yes"> | |||
<div class=" btn-group btn-group-sm" > | |||
<a id="lr_add" class="btn btn-default"><i class="fa fa-plus"></i> 新增</a> | |||
<a id="lr_edit" class="btn btn-default"><i class="fa fa-pencil-square-o"></i> 编辑</a> | |||
<a id="lr_delete" class="btn btn-default"><i class="fa fa-trash-o"></i> 删除</a> | |||
</div> | |||
<div class=" btn-group btn-group-sm" > | |||
<a id="lr_submit" class="btn btn-default"><i class="fa fa-pencil-square-o"></i> 提交二级学院</a> | |||
</div> | |||
</div> | |||
</div> | |||
<div class="lr-layout-body" id="gridtable"></div> | |||
@@ -5,10 +5,14 @@ | |||
* 描 述:定制功能助学金 | |||
*/ | |||
var refreshGirdData; | |||
var types = request('types');//助学金类型:1国家助学金,2校级助学金 | |||
console.log(types == "1" ? "国家助学金" : types == "2" ? "校级助学金" : ""); | |||
var bootstrap = function ($, learun) { | |||
"use strict"; | |||
var logbegin = ''; | |||
var logend = ''; | |||
var startTime; | |||
var endTime; | |||
var startTimeRelease; | |||
var endTimeRelease; | |||
var page = { | |||
init: function () { | |||
page.initGird(); | |||
@@ -20,7 +24,7 @@ var bootstrap = function ($, learun) { | |||
{ name: '今天', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00') }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } }, | |||
{ name: '近7天', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00', 'd', -6) }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } }, | |||
{ name: '近1个月', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00', 'm', -1) }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } }, | |||
{ name: '近3个月', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00', 'm', -3) }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } }, | |||
{ name: '近3个月', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00', 'm', -3) }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } } | |||
], | |||
// 月 | |||
mShow: false, | |||
@@ -34,21 +38,45 @@ var bootstrap = function ($, learun) { | |||
preyShow: false, | |||
yShow: false, | |||
// 默认 | |||
dfvalue: '1', | |||
selectfn: function (begin, end) { | |||
logbegin = begin; | |||
logend = end; | |||
startTime = begin; | |||
endTime = end; | |||
page.search(); | |||
} | |||
}); | |||
$('#datesearchRelease').lrdate({ | |||
dfdata: [ | |||
{ name: '今天', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00') }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } }, | |||
{ name: '近7天', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00', 'd', -6) }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } }, | |||
{ name: '近1个月', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00', 'm', -1) }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } }, | |||
{ name: '近3个月', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00', 'm', -3) }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } } | |||
], | |||
// 月 | |||
mShow: false, | |||
premShow: false, | |||
// 季度 | |||
jShow: false, | |||
prejShow: false, | |||
// 年 | |||
ysShow: false, | |||
yxShow: false, | |||
preyShow: false, | |||
yShow: false, | |||
// 默认 | |||
dfvalue: '1', | |||
selectfn: function (begin, end) { | |||
startTimeRelease = begin; | |||
endTimeRelease = end; | |||
page.search(); | |||
} | |||
}); | |||
$('#multiple_condition_query').lrMultipleQuery(function (queryJson) { | |||
page.search(queryJson); | |||
}, 400, 400); | |||
}, 350, 400); | |||
//下拉框绑定 | |||
$('#DeptNo').lrDataSourceSelect({ code: 'CdDeptInfo', value: 'deptno', text: 'deptname' }); | |||
$('#MajorNo').lrDataSourceSelect({ code: 'CdMajorInfo', value: 'majorno', text: 'majorname' }); | |||
$('#F_SchoolId').lrDataSourceSelect({ code: 'company', value: 'f_companyid', text: 'f_fullname' }); | |||
$('#ClassNo').lrDataSourceSelect({ code: 'bjsj', value: 'classno', text: 'classname' }); | |||
$('#OpenBank').lrDataItemSelect({ code: 'DepositBank' }); | |||
$('#SubsidizeType').lrDataItemSelect({ code: 'StateStipend' }); | |||
// 刷新 | |||
@@ -60,8 +88,8 @@ var bootstrap = function ($, learun) { | |||
learun.layerForm({ | |||
id: 'form', | |||
title: '新增', | |||
url: top.$.rootUrl + '/EducationalAdministration/StuFellowship/Form', | |||
width: 800, | |||
url: top.$.rootUrl + '/EducationalAdministration/StuFellowship/Form?Types=' + types, | |||
width: 1000, | |||
height: 600, | |||
callBack: function (id) { | |||
return top[id].acceptClick(refreshGirdData); | |||
@@ -72,11 +100,16 @@ var bootstrap = function ($, learun) { | |||
$('#lr_edit').on('click', function () { | |||
var keyValue = $('#gridtable').jfGridValue('ID'); | |||
if (learun.checkrow(keyValue)) { | |||
var Status = $('#gridtable').jfGridValue('Status'); | |||
if (Status != "0") { | |||
learun.alert.warning("当前项不属于草稿状态,无法编辑!"); | |||
return false; | |||
} | |||
learun.layerForm({ | |||
id: 'form', | |||
title: '编辑', | |||
url: top.$.rootUrl + '/EducationalAdministration/StuFellowship/Form?keyValue=' + keyValue, | |||
width: 800, | |||
url: top.$.rootUrl + '/EducationalAdministration/StuFellowship/Form?Types=' + types + '&keyValue=' + keyValue, | |||
width: 1000, | |||
height: 600, | |||
callBack: function (id) { | |||
return top[id].acceptClick(refreshGirdData); | |||
@@ -88,6 +121,11 @@ var bootstrap = function ($, learun) { | |||
$('#lr_delete').on('click', function () { | |||
var keyValue = $('#gridtable').jfGridValue('ID'); | |||
if (learun.checkrow(keyValue)) { | |||
var Status = $('#gridtable').jfGridValue('Status'); | |||
if (Status != "0") { | |||
learun.alert.warning("当前项不属于草稿状态,无法删除!"); | |||
return false; | |||
} | |||
learun.layerConfirm('是否确认删除该项!', function (res) { | |||
if (res) { | |||
learun.deleteForm(top.$.rootUrl + '/EducationalAdministration/StuFellowship/DeleteForm', { keyValue: keyValue }, function () { | |||
@@ -97,65 +135,93 @@ var bootstrap = function ($, learun) { | |||
}); | |||
} | |||
}); | |||
// 提交二级学院审核 | |||
$('#lr_submit').on('click', function () { | |||
var keyValue = $('#gridtable').jfGridValue('ID'); | |||
if (learun.checkrow(keyValue)) { | |||
var Status = $('#gridtable').jfGridValue('Status'); | |||
if (Status != "0") { | |||
learun.alert.warning("当前项不属于草稿状态,无法提交学院审核!"); | |||
return false; | |||
} | |||
learun.layerConfirm('是否确认提交该项!', function (res) { | |||
if (res) { | |||
learun.postForm(top.$.rootUrl + '/EducationalAdministration/StuFellowship/DoSubmit', { keyValue: keyValue, status: '1', step: '1' }, function () { | |||
refreshGirdData(); | |||
}); | |||
} | |||
}); | |||
} | |||
}); | |||
}, | |||
initGird: function () { | |||
$('#gridtable').lrAuthorizeJfGrid({ | |||
$('#gridtable').jfGrid({ | |||
url: top.$.rootUrl + '/EducationalAdministration/StuFellowship/GetPageList', | |||
headData: [ | |||
{ label: '学号', name: 'StuNo', width: 120, align: "left" }, | |||
{ label: '姓名', name: 'StuName', width: 150, align: "left" }, | |||
{ | |||
label: "系所", name: "DeptNo", width: 100, align: "left", | |||
label: '院校', name: 'F_SchoolId', width: 100, align: "left", | |||
formatterAsync: function (callback, value, row, op, $cell) { | |||
learun.clientdata.getAsync('custmerData', { | |||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'CdDeptInfo', | |||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'company', | |||
key: value, | |||
keyId: 'deptno', | |||
keyId: 'f_companyid', | |||
callback: function (_data) { | |||
callback(_data['deptname']); | |||
callback(_data['f_fullname']); | |||
} | |||
}); | |||
} | |||
}, | |||
{ | |||
label: "专业", name: "MajorNo", width: 100, align: "left", | |||
label: "所属班级", name: "ClassNo", width: 100, align: "left", | |||
formatterAsync: function (callback, value, row, op, $cell) { | |||
learun.clientdata.getAsync('custmerData', { | |||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'CdMajorInfo', | |||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'bjsj', | |||
key: value, | |||
keyId: 'majorno', | |||
keyId: 'classno', | |||
callback: function (_data) { | |||
callback(_data['majorname']); | |||
callback(_data['classname']); | |||
} | |||
}); | |||
} | |||
}, | |||
{ | |||
label: "班级", name: "ClassNo", width: 100, align: "left", | |||
formatterAsync: function (callback, value, row, op, $cell) { | |||
learun.clientdata.getAsync('custmerData', { | |||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'bjsj', | |||
label: '身份证件类型', name: 'IdCardType', width: 100, align: "left" | |||
, formatterAsync: function (callback, value, row, op, $cell) { | |||
learun.clientdata.getAsync('dataItem', { | |||
key: value, | |||
keyId: 'classno', | |||
code: 'IdCardType', | |||
callback: function (_data) { | |||
callback(_data['classname']); | |||
callback(_data.text); | |||
} | |||
}); | |||
} | |||
}, | |||
{ label: '身份证件号', name: 'IdentityCardNo', width: 160, align: "left" }, | |||
{ | |||
label: '证件类型', name: 'IdCardType', width: 100, align: "left" | |||
label: '资助等级', name: 'SubsidizeType', width: 100, align: "left" | |||
, formatterAsync: function (callback, value, row, op, $cell) { | |||
learun.clientdata.getAsync('dataItem', { | |||
key: value, | |||
code: 'IdCardType', | |||
code: 'StateStipend', | |||
callback: function (_data) { | |||
callback(_data.text); | |||
} | |||
}); | |||
} | |||
}, | |||
{ label: '身份证号', name: 'IdentityCardNo', width: 160, align: "left" }, | |||
{ label: '资助标准', name: 'FunderNationStandard', width: 100, align: "left" }, | |||
{ label: '应发金额', name: 'AmountPayable', width: 100, align: "left" }, | |||
{ label: '实发金额', name: 'FinalPayingAmount', width: 100, align: "left" }, | |||
{ | |||
label: '申请日期', name: 'ApplyDate', width: 100, align: "left", | |||
formatter: function (cellvalue) { | |||
return learun.formatDate(cellvalue, 'yyyy-MM-dd'); | |||
} | |||
}, | |||
{ label: '发放日期', name: 'ReleaseDate', width: 100, align: "left" }, | |||
{ label: '申请理由', name: 'ApplyReason', width: 200, align: "left" }, | |||
{ | |||
label: '开户银行', name: 'OpenBank', width: 200, align: "left" | |||
, formatterAsync: function (callback, value, row, op, $cell) { | |||
@@ -170,62 +236,82 @@ var bootstrap = function ($, learun) { | |||
}, | |||
{ label: '开户卡账号', name: 'OpenAccount', width: 200, align: "left" }, | |||
{ label: '开户行号', name: 'OpenBankNo', width: 120, align: "left" }, | |||
{ label: '备注说明', name: 'Remark', width: 200, align: "left" }, | |||
{ | |||
label: '资助等级', name: 'SubsidizeType', width: 100, align: "left" | |||
, formatterAsync: function (callback, value, row, op, $cell) { | |||
learun.clientdata.getAsync('dataItem', { | |||
label: '审核状态', name: 'Status', width: 100, align: "left", formatter: function (cellvalue) { | |||
return cellvalue == "0" ? "<span class=\"label label-default\">草稿</span>" : cellvalue == "1" ? "<span class=\"label label-success\">学院审核中</span>" : cellvalue == "2" ? "<span class=\"label label-success\">学工部审核中</span>" : cellvalue == "3" ? "<span class=\"label label-success\">已归档</span>" : "<span class=\"label label-default\">草稿</span>"; | |||
} | |||
}, | |||
{ | |||
label: '创建人', name: 'CreateUserId', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) { | |||
learun.clientdata.getAsync('custmerData', { | |||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'BaseUser', | |||
key: value, | |||
code: 'StateStipend', | |||
keyId: 'f_userid', | |||
callback: function (_data) { | |||
callback(_data.text); | |||
callback(_data['f_realname']); | |||
} | |||
}); | |||
} | |||
}, | |||
{ label: '资助标准', name: 'FunderNationStandard', width: 100, align: "left" }, | |||
{ label: '应发金额', name: 'AmountPayable', width: 100, align: "left" }, | |||
{ label: '实发金额', name: 'FinalPayingAmount', width: 100, align: "left" }, | |||
{ label: '创建时间', name: 'CreateTime', width: 130, align: "left" }, | |||
{ label: '提交时间', name: 'SubmitTime', width: 130, align: "left" }, | |||
{ | |||
label: '申请时间', name: 'CreateDate', width: 100, align: "left", | |||
formatter: function (cellvalue) { | |||
return learun.formatDate(cellvalue, 'yyyy-MM-dd'); | |||
label: '提交人', name: 'SubmitUserId', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) { | |||
learun.clientdata.getAsync('custmerData', { | |||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'BaseUser', | |||
key: value, | |||
keyId: 'f_userid', | |||
callback: function (_data) { | |||
callback(_data['f_realname']); | |||
} | |||
}); | |||
} | |||
}, | |||
{ label: '发放日期', name: 'ReleaseDate', width: 200, align: "left" }, | |||
{ label: '申请理由', name: 'ApplyReason', width: 200, align: "left" }, | |||
{ label: '备注', name: 'Remark', width: 200, align: "left" }, | |||
{ | |||
label: '状态', name: 'State', width: 100, align: "left", | |||
formatter: function (cellvalue, row) { | |||
if (cellvalue == 2) { | |||
return "<span class=\"label label-success\">二级学院</span>"; | |||
} else if (cellvalue == 3) { | |||
return "<span class=\"label label-danger\">学工部</span>"; | |||
} else if (cellvalue == 2) { | |||
return "<span class=\"label label-warning\">归档</span>"; | |||
} else if (cellvalue == 1) { | |||
return "<span class=\"label label-default\">草稿</span>"; | |||
} | |||
label: '学院审核人', name: 'FirstCheckUserId', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) { | |||
learun.clientdata.getAsync('custmerData', { | |||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'BaseUser', | |||
key: value, | |||
keyId: 'f_userid', | |||
callback: function (_data) { | |||
callback(_data['f_realname']); | |||
} | |||
}); | |||
} | |||
}, | |||
{ label: '学院审核时间', name: 'FirstCheckTime', width: 130, align: "left" }, | |||
{ | |||
label: '学工部审核人', name: 'SecondCheckUserId', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) { | |||
learun.clientdata.getAsync('custmerData', { | |||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'BaseUser', | |||
key: value, | |||
keyId: 'f_userid', | |||
callback: function (_data) { | |||
callback(_data['f_realname']); | |||
} | |||
}); | |||
} | |||
}, | |||
{ label: '学工部审核时间', name: 'SecondCheckTime', width: 130, align: "left" }, | |||
], | |||
mainId: 'ID', | |||
isPage: true, | |||
sidx: 'CreateDate', | |||
sord: 'ASC' | |||
sidx: 'CreateTime desc' | |||
}); | |||
page.search(); | |||
}, | |||
search: function (param) { | |||
param = param || {}; | |||
param.SqlParam = " and Types = 1" | |||
param.StartTime = logbegin; | |||
param.EndTime = logend; | |||
param.Types = types; | |||
param.StartTime = startTime; | |||
param.EndTime = endTime; | |||
param.StartTimeRelease = startTimeRelease; | |||
param.EndTimeRelease = endTimeRelease; | |||
$('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) }); | |||
} | |||
}; | |||
refreshGirdData = function () { | |||
$('#gridtable').jfGridSet('reload'); | |||
page.search(); | |||
}; | |||
page.init(); | |||
} |
@@ -0,0 +1,83 @@ | |||
@{ | |||
ViewBag.Title = "助学金管理"; | |||
Layout = "~/Views/Shared/_Index.cshtml"; | |||
} | |||
<style> | |||
.datesearchLabel { | |||
float: left; | |||
line-height: 28px; | |||
height: 40px; | |||
padding-top: 13px; | |||
padding-left: 5px; | |||
} | |||
.datesearchLabel:first-child { | |||
padding-left: 0px; | |||
} | |||
</style> | |||
<div class="lr-layout"> | |||
<div class="lr-layout-center"> | |||
<div class="lr-layout-wrap lr-layout-wrap-notitle"> | |||
<div class="lr-layout-tool"> | |||
<div class="lr-layout-tool-left"> | |||
<div class="datesearchLabel">申请</div> | |||
<div class="lr-layout-tool-item"> | |||
<div id="datesearch"></div> | |||
</div> | |||
<div class="datesearchLabel">发放</div> | |||
<div class="lr-layout-tool-item"> | |||
<div id="datesearchRelease"></div> | |||
</div> | |||
<div class="lr-layout-tool-item"> | |||
<div id="multiple_condition_query"> | |||
<div class="lr-query-formcontent"> | |||
<div class="col-xs-12 lr-form-item"> | |||
<div class="lr-form-item-title">学号</div> | |||
<input id="StuNo" type="text" class="form-control" /> | |||
</div> | |||
<div class="col-xs-12 lr-form-item"> | |||
<div class="lr-form-item-title">姓名</div> | |||
<input id="StuName" type="text" class="form-control" /> | |||
</div> | |||
<div class="col-xs-12 lr-form-item"> | |||
<div class="lr-form-item-title">院系</div> | |||
<div id="F_SchoolId"></div> | |||
</div> | |||
<div class="col-xs-12 lr-form-item"> | |||
<div class="lr-form-item-title">班级</div> | |||
<div id="ClassNo"></div> | |||
</div> | |||
<div class="col-xs-12 lr-form-item"> | |||
<div class="lr-form-item-title">身份证号</div> | |||
<input id="IdentityCardNo" type="text" class="form-control" /> | |||
</div> | |||
<div class="col-xs-12 lr-form-item"> | |||
<div class="lr-form-item-title">资助等级</div> | |||
<div id="SubsidizeType"></div> | |||
</div> | |||
<div class="col-xs-12 lr-form-item"> | |||
<div class="lr-form-item-title">开户行户</div> | |||
<input id="OpenBankNo" type="text" class="form-control" /> | |||
</div> | |||
</div> | |||
</div> | |||
</div> | |||
</div> | |||
<div class="lr-layout-tool-right"> | |||
<div class=" btn-group btn-group-sm"> | |||
<a id="lr_refresh" class="btn btn-default"><i class="fa fa-refresh"></i></a> | |||
</div> | |||
<div class=" btn-group btn-group-sm" > | |||
<a id="lr_edit" class="btn btn-default"><i class="fa fa-pencil-square-o"></i> 审核</a> | |||
</div> | |||
<div class=" btn-group btn-group-sm" > | |||
<a id="lr_submit" class="btn btn-default"><i class="fa fa-pencil-square-o"></i> 提交学工部</a> | |||
<a id="lr_back" class="btn btn-default"><i class="fa fa-pencil-square-o"></i> 退回辅导员</a> | |||
</div> | |||
</div> | |||
</div> | |||
<div class="lr-layout-body" id="gridtable"></div> | |||
</div> | |||
</div> | |||
</div> | |||
@Html.AppendJsFile("/Areas/EducationalAdministration/Views/StuFellowship/IndexOfTwo.js") |
@@ -0,0 +1,305 @@ | |||
/* * 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架(http://www.learun.cn) | |||
* Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||
* 创建人:超级管理员 | |||
* 日 期:2023-03-13 10:37 | |||
* 描 述:定制功能助学金 | |||
*/ | |||
var refreshGirdData; | |||
var types = request('types');//助学金类型:1国家助学金,2校级助学金 | |||
console.log(types == "1" ? "国家助学金" : types == "2" ? "校级助学金" : ""); | |||
var bootstrap = function ($, learun) { | |||
"use strict"; | |||
var startTime; | |||
var endTime; | |||
var startTimeRelease; | |||
var endTimeRelease; | |||
var page = { | |||
init: function () { | |||
page.initGird(); | |||
page.bind(); | |||
}, | |||
bind: function () { | |||
$('#datesearch').lrdate({ | |||
dfdata: [ | |||
{ name: '今天', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00') }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } }, | |||
{ name: '近7天', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00', 'd', -6) }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } }, | |||
{ name: '近1个月', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00', 'm', -1) }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } }, | |||
{ name: '近3个月', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00', 'm', -3) }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } } | |||
], | |||
// 月 | |||
mShow: false, | |||
premShow: false, | |||
// 季度 | |||
jShow: false, | |||
prejShow: false, | |||
// 年 | |||
ysShow: false, | |||
yxShow: false, | |||
preyShow: false, | |||
yShow: false, | |||
// 默认 | |||
dfvalue: '1', | |||
selectfn: function (begin, end) { | |||
startTime = begin; | |||
endTime = end; | |||
page.search(); | |||
} | |||
}); | |||
$('#datesearchRelease').lrdate({ | |||
dfdata: [ | |||
{ name: '今天', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00') }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } }, | |||
{ name: '近7天', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00', 'd', -6) }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } }, | |||
{ name: '近1个月', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00', 'm', -1) }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } }, | |||
{ name: '近3个月', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00', 'm', -3) }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } } | |||
], | |||
// 月 | |||
mShow: false, | |||
premShow: false, | |||
// 季度 | |||
jShow: false, | |||
prejShow: false, | |||
// 年 | |||
ysShow: false, | |||
yxShow: false, | |||
preyShow: false, | |||
yShow: false, | |||
// 默认 | |||
dfvalue: '1', | |||
selectfn: function (begin, end) { | |||
startTimeRelease = begin; | |||
endTimeRelease = end; | |||
page.search(); | |||
} | |||
}); | |||
$('#multiple_condition_query').lrMultipleQuery(function (queryJson) { | |||
page.search(queryJson); | |||
}, 350, 400); | |||
//下拉框绑定 | |||
$('#F_SchoolId').lrDataSourceSelect({ code: 'company', value: 'f_companyid', text: 'f_fullname' }); | |||
$('#ClassNo').lrDataSourceSelect({ code: 'bjsj', value: 'classno', text: 'classname' }); | |||
$('#SubsidizeType').lrDataItemSelect({ code: 'StateStipend' }); | |||
// 刷新 | |||
$('#lr_refresh').on('click', function () { | |||
location.reload(); | |||
}); | |||
// 编辑 | |||
$('#lr_edit').on('click', function () { | |||
var keyValue = $('#gridtable').jfGridValue('ID'); | |||
if (learun.checkrow(keyValue)) { | |||
var Status = $('#gridtable').jfGridValue('Status'); | |||
if (Status != "1") { | |||
learun.alert.warning("当前项不属于学院审核状态,无法编辑!"); | |||
return false; | |||
} | |||
learun.layerForm({ | |||
id: 'formOfTwo', | |||
title: '审核', | |||
url: top.$.rootUrl + '/EducationalAdministration/StuFellowship/Form?Types=' + types + '&Step=2&keyValue=' + keyValue, | |||
width: 1000, | |||
height: 600, | |||
callBack: function (id) { | |||
return top[id].acceptClick(refreshGirdData); | |||
} | |||
}); | |||
} | |||
}); | |||
// 提交学工部审核 | |||
$('#lr_submit').on('click', function () { | |||
var keyValue = $('#gridtable').jfGridValue('ID'); | |||
if (learun.checkrow(keyValue)) { | |||
var Status = $('#gridtable').jfGridValue('Status'); | |||
if (Status != "1") { | |||
learun.alert.warning("当前项不属于学院审核状态,无法提交学工部审核!"); | |||
return false; | |||
} | |||
learun.layerConfirm('是否确认提交该项!', function (res) { | |||
if (res) { | |||
learun.postForm(top.$.rootUrl + '/EducationalAdministration/StuFellowship/DoSubmit', { keyValue: keyValue, status: '2', step: '2' }, function () { | |||
refreshGirdData(); | |||
}); | |||
} | |||
}); | |||
} | |||
}); | |||
// 退回辅导员 | |||
$('#lr_back').on('click', function () { | |||
var keyValue = $('#gridtable').jfGridValue('ID'); | |||
if (learun.checkrow(keyValue)) { | |||
var Status = $('#gridtable').jfGridValue('Status'); | |||
if (Status != "1") { | |||
learun.alert.warning("当前项不属于学院审核状态,无法退回辅导员!"); | |||
return false; | |||
} | |||
learun.layerConfirm('是否确认退回该项!', function (res) { | |||
if (res) { | |||
learun.postForm(top.$.rootUrl + '/EducationalAdministration/StuFellowship/DoBack', { keyValue: keyValue, status: '0', step: '2' }, function () { | |||
refreshGirdData(); | |||
}); | |||
} | |||
}); | |||
} | |||
}); | |||
}, | |||
initGird: function () { | |||
$('#gridtable').jfGrid({ | |||
url: top.$.rootUrl + '/EducationalAdministration/StuFellowship/GetPageList', | |||
headData: [ | |||
{ label: '学号', name: 'StuNo', width: 120, align: "left" }, | |||
{ label: '姓名', name: 'StuName', width: 150, align: "left" }, | |||
{ | |||
label: '院校', name: 'F_SchoolId', width: 100, align: "left", | |||
formatterAsync: function (callback, value, row, op, $cell) { | |||
learun.clientdata.getAsync('custmerData', { | |||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'company', | |||
key: value, | |||
keyId: 'f_companyid', | |||
callback: function (_data) { | |||
callback(_data['f_fullname']); | |||
} | |||
}); | |||
} | |||
}, | |||
{ | |||
label: "所属班级", name: "ClassNo", width: 100, align: "left", | |||
formatterAsync: function (callback, value, row, op, $cell) { | |||
learun.clientdata.getAsync('custmerData', { | |||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'bjsj', | |||
key: value, | |||
keyId: 'classno', | |||
callback: function (_data) { | |||
callback(_data['classname']); | |||
} | |||
}); | |||
} | |||
}, | |||
{ | |||
label: '身份证件类型', name: 'IdCardType', width: 100, align: "left" | |||
, formatterAsync: function (callback, value, row, op, $cell) { | |||
learun.clientdata.getAsync('dataItem', { | |||
key: value, | |||
code: 'IdCardType', | |||
callback: function (_data) { | |||
callback(_data.text); | |||
} | |||
}); | |||
} | |||
}, | |||
{ label: '身份证件号', name: 'IdentityCardNo', width: 160, align: "left" }, | |||
{ | |||
label: '资助等级', name: 'SubsidizeType', width: 100, align: "left" | |||
, formatterAsync: function (callback, value, row, op, $cell) { | |||
learun.clientdata.getAsync('dataItem', { | |||
key: value, | |||
code: 'StateStipend', | |||
callback: function (_data) { | |||
callback(_data.text); | |||
} | |||
}); | |||
} | |||
}, | |||
{ label: '资助标准', name: 'FunderNationStandard', width: 100, align: "left" }, | |||
{ label: '应发金额', name: 'AmountPayable', width: 100, align: "left" }, | |||
{ label: '实发金额', name: 'FinalPayingAmount', width: 100, align: "left" }, | |||
{ | |||
label: '申请日期', name: 'ApplyDate', width: 100, align: "left", | |||
formatter: function (cellvalue) { | |||
return learun.formatDate(cellvalue, 'yyyy-MM-dd'); | |||
} | |||
}, | |||
{ label: '发放日期', name: 'ReleaseDate', width: 100, align: "left" }, | |||
{ label: '申请理由', name: 'ApplyReason', width: 200, align: "left" }, | |||
{ | |||
label: '开户银行', name: 'OpenBank', width: 200, align: "left" | |||
, formatterAsync: function (callback, value, row, op, $cell) { | |||
learun.clientdata.getAsync('dataItem', { | |||
key: value, | |||
code: 'DepositBank', | |||
callback: function (_data) { | |||
callback(_data.text); | |||
} | |||
}); | |||
} | |||
}, | |||
{ label: '开户卡账号', name: 'OpenAccount', width: 200, align: "left" }, | |||
{ label: '开户行号', name: 'OpenBankNo', width: 120, align: "left" }, | |||
{ label: '备注说明', name: 'Remark', width: 200, align: "left" }, | |||
{ | |||
label: '审核状态', name: 'Status', width: 100, align: "left", formatter: function (cellvalue) { | |||
return cellvalue == "0" ? "<span class=\"label label-default\">草稿</span>" : cellvalue == "1" ? "<span class=\"label label-success\">学院审核中</span>" : cellvalue == "2" ? "<span class=\"label label-success\">学工部审核中</span>" : cellvalue == "3" ? "<span class=\"label label-success\">已归档</span>" : "<span class=\"label label-default\">草稿</span>"; | |||
} | |||
}, | |||
{ | |||
label: '创建人', name: 'CreateUserId', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) { | |||
learun.clientdata.getAsync('custmerData', { | |||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'BaseUser', | |||
key: value, | |||
keyId: 'f_userid', | |||
callback: function (_data) { | |||
callback(_data['f_realname']); | |||
} | |||
}); | |||
} | |||
}, | |||
{ label: '创建时间', name: 'CreateTime', width: 130, align: "left" }, | |||
{ label: '提交时间', name: 'SubmitTime', width: 130, align: "left" }, | |||
{ | |||
label: '提交人', name: 'SubmitUserId', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) { | |||
learun.clientdata.getAsync('custmerData', { | |||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'BaseUser', | |||
key: value, | |||
keyId: 'f_userid', | |||
callback: function (_data) { | |||
callback(_data['f_realname']); | |||
} | |||
}); | |||
} | |||
}, | |||
{ | |||
label: '学院审核人', name: 'FirstCheckUserId', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) { | |||
learun.clientdata.getAsync('custmerData', { | |||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'BaseUser', | |||
key: value, | |||
keyId: 'f_userid', | |||
callback: function (_data) { | |||
callback(_data['f_realname']); | |||
} | |||
}); | |||
} | |||
}, | |||
{ label: '学院审核时间', name: 'FirstCheckTime', width: 130, align: "left" }, | |||
{ | |||
label: '学工部审核人', name: 'SecondCheckUserId', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) { | |||
learun.clientdata.getAsync('custmerData', { | |||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'BaseUser', | |||
key: value, | |||
keyId: 'f_userid', | |||
callback: function (_data) { | |||
callback(_data['f_realname']); | |||
} | |||
}); | |||
} | |||
}, | |||
{ label: '学工部审核时间', name: 'SecondCheckTime', width: 130, align: "left" }, | |||
], | |||
mainId: 'ID', | |||
isPage: true, | |||
sidx: 'SubmitTime desc' | |||
}); | |||
}, | |||
search: function (param) { | |||
param = param || {}; | |||
param.Types = types; | |||
param.StartTime = startTime; | |||
param.EndTime = endTime; | |||
param.StartTimeRelease = startTimeRelease; | |||
param.EndTimeRelease = endTimeRelease; | |||
param.Step = "2";//第二步:二级学院审核 | |||
$('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) }); | |||
} | |||
}; | |||
refreshGirdData = function () { | |||
page.search(); | |||
}; | |||
page.init(); | |||
} |
@@ -33,7 +33,7 @@ | |||
</div> | |||
<div class="col-xs-6 lr-form-item"> | |||
<div class="lr-form-item-title">身份证件类型<font face="宋体">*</font></div> | |||
<div id="IdCardType" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" readonly="readonly"></div> | |||
<div id="IdCardType" type="text" class="form-control" isvalid="yes" checkexpession="NotNull"></div> | |||
</div> | |||
<div class="col-xs-6 lr-form-item"> | |||
<div class="lr-form-item-title">申请时间<font face="宋体">*</font></div> | |||
@@ -33,6 +33,7 @@ var bootstrap = function ($, learun) { | |||
$('#F_SchoolId').lrDataSourceSelect({ code: 'company', value: 'f_companyid', text: 'f_fullname' }); | |||
$('#ClassNo').lrDataSourceSelect({ code: 'bjsj', value: 'classno', text: 'classname' }); | |||
$('#IdCardType').lrDataItemSelect({ code: 'IdCardType' }); | |||
$('#IdCardType').lrselectSet('01'); | |||
$('#StuNo').lrGirdSelect({ | |||
// 字段 | |||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=StuInfoBasic', | |||
@@ -97,7 +98,6 @@ var bootstrap = function ($, learun) { | |||
$("#F_SchoolId").lrselectSet(item.f_schoolid); | |||
$("#ClassNo").lrselectSet(item.classno); | |||
$("#IdentityCardNo").val(item.identitycardno); | |||
$('#IdCardType').lrselectSet('01'); | |||
} | |||
}); | |||
//申请时间:默认当天 | |||
@@ -997,6 +997,7 @@ | |||
<Content Include="Areas\EducationalAdministration\Views\CdMajor\IndexProvince.js" /> | |||
<Content Include="Areas\EducationalAdministration\Views\PsychologyInfo\FormView.js" /> | |||
<Content Include="Areas\EducationalAdministration\Views\SchoolLevelScholarship\IndexInStuScore.js" /> | |||
<Content Include="Areas\EducationalAdministration\Views\StuFellowship\IndexOfTwo.js" /> | |||
<Content Include="Areas\EducationalAdministration\Views\StuInfoBasic\SoonGraduateIndex.js" /> | |||
<Content Include="Areas\EducationalAdministration\Views\YKTStateMent\AnalysisByMonthForStudent.js" /> | |||
<Content Include="Areas\EducationalAdministration\Views\YKTStateMent\ManageIndexTeacher.js" /> | |||
@@ -8124,6 +8125,7 @@ | |||
<Content Include="Areas\LR_Desktop\Views\PsychologyReplyInfo\IndexGather.cshtml" /> | |||
<Content Include="Areas\LR_Desktop\Views\PsychologyReplyInfo\FormGatherView.cshtml" /> | |||
<Content Include="Areas\LR_Desktop\Views\PsychologyReplyInfo\IndexReply.cshtml" /> | |||
<Content Include="Areas\EducationalAdministration\Views\StuFellowship\IndexOfTwo.cshtml" /> | |||
<None Include="Properties\PublishProfiles\CustomProfile.pubxml" /> | |||
<None Include="Properties\PublishProfiles\FolderProfile.pubxml" /> | |||
<Content Include="Views\Login\Default-beifen.cshtml" /> | |||
@@ -132,10 +132,18 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
{ | |||
strSql.Append(" and t.LessonNo like '%" + queryParam["LessonNo"].ToString() + "%' "); | |||
} | |||
if (!queryParam["LessonName"].IsEmpty()) | |||
{ | |||
strSql.Append(" and t.LessonName like '%" + queryParam["LessonName"].ToString() + "%' "); | |||
} | |||
if (!queryParam["ClassNo"].IsEmpty()) | |||
{ | |||
strSql.Append(" and t.ClassNo='" + queryParam["ClassNo"].ToString() + "' "); | |||
} | |||
if (!queryParam["ClassName"].IsEmpty()) | |||
{ | |||
strSql.Append(" and t.ClassName like'%" + queryParam["ClassName"].ToString() + "%' "); | |||
} | |||
if (!queryParam["StuNo"].IsEmpty()) | |||
{ | |||
strSql.Append(" and t.StuNo='" + queryParam["StuNo"].ToString() + "' "); | |||
@@ -144,10 +152,18 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
{ | |||
strSql.Append(" and t.EmpNo like '%" + queryParam["EmpNo"].ToString() + "%' "); | |||
} | |||
if (!queryParam["EmpName"].IsEmpty()) | |||
{ | |||
strSql.Append(" and t.EmpName like '%" + queryParam["EmpName"].ToString() + "%' "); | |||
} | |||
if (!queryParam["ClassRoomNo"].IsEmpty()) | |||
{ | |||
strSql.Append(" and t.ClassRoomNo='" + queryParam["ClassRoomNo"].ToString() + "' "); | |||
} | |||
if (!queryParam["ClassRoomName"].IsEmpty()) | |||
{ | |||
strSql.Append(" and t.ClassRoomName like '%" + queryParam["ClassRoomName"].ToString() + "%' "); | |||
} | |||
if (!queryParam["StartTime"].IsEmpty() && !queryParam["EndTime"].IsEmpty()) | |||
{ | |||
strSql.Append(" AND ( ExamDate >= '" + queryParam["StartTime"].ToString() + "' AND ExamDate <= '" + queryParam["EndTime"].ToString() + "' ) "); | |||
@@ -167,6 +183,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
} | |||
} | |||
} | |||
/// <summary> | |||
/// 获取页面显示列表数据 | |||
/// </summary> | |||
@@ -142,6 +142,54 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
} | |||
} | |||
/// <summary> | |||
/// 提交 | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
public void DoSubmit(string keyValue, string status, string step) | |||
{ | |||
try | |||
{ | |||
stuFellowshipService.DoSubmit(keyValue, status, step); | |||
} | |||
catch (Exception ex) | |||
{ | |||
if (ex is ExceptionEx) | |||
{ | |||
throw; | |||
} | |||
else | |||
{ | |||
throw ExceptionEx.ThrowBusinessException(ex); | |||
} | |||
} | |||
} | |||
/// <summary> | |||
/// 退回 | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
public void DoBack(string keyValue, string status, string step) | |||
{ | |||
try | |||
{ | |||
stuFellowshipService.DoBack(keyValue, status, step); | |||
} | |||
catch (Exception ex) | |||
{ | |||
if (ex is ExceptionEx) | |||
{ | |||
throw; | |||
} | |||
else | |||
{ | |||
throw ExceptionEx.ThrowBusinessException(ex); | |||
} | |||
} | |||
} | |||
#endregion | |||
} | |||
@@ -27,54 +27,6 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
[Column("STUNO")] | |||
public string StuNo { get; set; } | |||
/// <summary> | |||
/// 姓名 | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("STUNAME")] | |||
public string StuName { get; set; } | |||
/// <summary> | |||
/// 系部 | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("DEPTNO")] | |||
public string DeptNo { get; set; } | |||
/// <summary> | |||
/// 专业 | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("MAJORNO")] | |||
public string MajorNo { get; set; } | |||
/// <summary> | |||
/// 班级 | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("CLASSNO")] | |||
public string ClassNo { get; set; } | |||
/// <summary> | |||
/// 证件类型 默认身份证 | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("IDCARDTYPE")] | |||
public string IdCardType { get; set; } | |||
/// <summary> | |||
/// 身份证号 | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("IDENTITYCARDNO")] | |||
public string IdentityCardNo { get; set; } | |||
/// <summary> | |||
/// 开户银行 | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("OPENBANK")] | |||
public string OpenBank { get; set; } | |||
/// <summary> | |||
/// 开户卡账号 | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("OPENACCOUNT")] | |||
public string OpenAccount { get; set; } | |||
/// <summary> | |||
/// 开户行号 | |||
/// </summary> | |||
/// <returns></returns> | |||
@@ -87,13 +39,13 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
[Column("SUBSIDIZETYPE")] | |||
public string SubsidizeType { get; set; } | |||
/// <summary> | |||
/// 资助金额 | |||
/// 资助标准 | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("FUNDERNATIONSTANDARD")] | |||
public decimal? FunderNationStandard { get; set; } | |||
/// <summary> | |||
/// AmountPayable | |||
/// 应发金额 | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("AMOUNTPAYABLE")] | |||
@@ -105,12 +57,6 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
[Column("FINALPAYINGAMOUNT")] | |||
public decimal? FinalPayingAmount { get; set; } | |||
/// <summary> | |||
/// 创建时间 | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("CREATEDATE")] | |||
public DateTime? CreateDate { get; set; } | |||
/// <summary> | |||
/// 申请时间 | |||
/// </summary> | |||
/// <returns></returns> | |||
@@ -121,7 +67,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("RELEASEDATE")] | |||
public string ReleaseDate { get; set; } | |||
public DateTime? ReleaseDate { get; set; } | |||
/// <summary> | |||
/// 申请理由 | |||
/// </summary> | |||
@@ -141,17 +87,89 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
[Column("FILES")] | |||
public string Files { get; set; } | |||
/// <summary> | |||
/// 1 草稿 2 二级学院 3 学工部 4 归档 | |||
/// 0 草稿 1 二级学院 2 学工部 3 归档 | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("STATE")] | |||
public string State { get; set; } | |||
[Column("STATUS")] | |||
public string Status { get; set; } | |||
/// <summary> | |||
/// 助学金类型 1国家级 2校级 | |||
/// 助学金类型:1国家助学金,2校级助学金 | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("TYPES")] | |||
public string Types { get; set; } | |||
/// <summary> | |||
/// 创建人 | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("CREATEUSERID")] | |||
public string CreateUserId { get; set; } | |||
/// <summary> | |||
/// 创建人 | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("CREATEUSERNO")] | |||
public string CreateUserNo { get; set; } | |||
/// <summary> | |||
/// 创建时间 | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("CREATETIME")] | |||
public DateTime? CreateTime { get; set; } | |||
/// <summary> | |||
/// 编辑人 | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("MODIFYUSERID")] | |||
public string ModifyUserId { get; set; } | |||
/// <summary> | |||
/// 编辑人 | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("MODIFYUSERNO")] | |||
public string ModifyUserNo { get; set; } | |||
/// <summary> | |||
/// 编辑时间 | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("MODIFYTIME")] | |||
public DateTime? ModifyTime { get; set; } | |||
/// <summary> | |||
/// 提交时间 | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("SUBMITTIME")] | |||
public DateTime? SubmitTime { get; set; } | |||
/// <summary> | |||
/// 提交人 | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("SUBMITUSERID")] | |||
public string SubmitUserId { get; set; } | |||
/// <summary> | |||
/// 学院审核人 | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("FIRSTCHECKUSERID")] | |||
public string FirstCheckUserId { get; set; } | |||
/// <summary> | |||
/// 学院审核时间 | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("FIRSTCHECKTIME")] | |||
public DateTime? FirstCheckTime { get; set; } | |||
/// <summary> | |||
/// 学工部审核人 | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("SECONDCHECKUSERID")] | |||
public string SecondCheckUserId { get; set; } | |||
/// <summary> | |||
/// 学工部审核时间 | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("SECONDCHECKTIME")] | |||
public DateTime? SecondCheckTime { get; set; } | |||
#endregion | |||
#region 扩展操作 | |||
@@ -161,6 +179,10 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
public void Create() | |||
{ | |||
this.ID = Guid.NewGuid().ToString(); | |||
this.CreateTime = DateTime.Now; | |||
this.CreateUserId = LoginUserInfo.Get().userId; | |||
this.CreateUserNo = LoginUserInfo.Get().account; | |||
this.Status = "0";//草稿 | |||
} | |||
/// <summary> | |||
/// 编辑调用 | |||
@@ -169,8 +191,59 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
public void Modify(string keyValue) | |||
{ | |||
this.ID = keyValue; | |||
this.ModifyTime = DateTime.Now; | |||
this.ModifyUserId = LoginUserInfo.Get().userId; | |||
this.ModifyUserNo = LoginUserInfo.Get().account; | |||
} | |||
#endregion | |||
#region 扩展字段 | |||
/// <summary> | |||
/// 姓名 | |||
/// </summary> | |||
/// <returns></returns> | |||
[NotMapped] | |||
public string StuName { get; set; } | |||
/// <summary> | |||
/// 院校 | |||
/// </summary> | |||
/// <returns></returns> | |||
[NotMapped] | |||
public string F_SchoolId { get; set; } | |||
/// <summary> | |||
/// 班级 | |||
/// </summary> | |||
/// <returns></returns> | |||
[NotMapped] | |||
public string ClassNo { get; set; } | |||
/// <summary> | |||
/// 身份证件号 | |||
/// </summary> | |||
/// <returns></returns> | |||
[NotMapped] | |||
public string IdentityCardNo { get; set; } | |||
/// <summary> | |||
/// 身份证件类型 | |||
/// </summary> | |||
/// <returns></returns> | |||
[NotMapped] | |||
public string IdCardType { get; set; } | |||
/// <summary> | |||
/// 开户银行 | |||
/// </summary> | |||
/// <returns></returns> | |||
[NotMapped] | |||
public string OpenBank { get; set; } | |||
/// <summary> | |||
/// 开户卡账号 | |||
/// </summary> | |||
/// <returns></returns> | |||
[NotMapped] | |||
public string OpenAccount { get; set; } | |||
#endregion | |||
} | |||
} | |||
@@ -49,6 +49,17 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
/// <param name="keyValue">主键</param> | |||
/// <param name="entity">实体</param> | |||
void SaveEntity(string keyValue, StuFellowshipEntity entity); | |||
/// <summary> | |||
/// 提交 | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
void DoSubmit(string keyValue, string status, string step); | |||
/// <summary> | |||
/// 退回 | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
void DoBack(string keyValue, string status, string step); | |||
#endregion | |||
} | |||
@@ -66,77 +66,84 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
try | |||
{ | |||
var strSql = new StringBuilder(); | |||
strSql.Append("SELECT t.*"); | |||
strSql.Append("SELECT t.*,s.StuName,s.F_SchoolId,s.ClassNo,s.IdentityCardNo,s.IdCardType,s.DepositBank as OpenBank,s.BankCard as OpenAccount "); | |||
strSql.Append(" FROM StuFellowship t "); | |||
strSql.Append(" left join StuInfoBasic s on t.StuNo=s.StuNo "); | |||
strSql.Append(" left join ClassInfo c on t.CreateUserNo=c.ClassTutorNo and s.ClassNo=c.ClassNo "); | |||
strSql.Append(" left join CdDept d on c.DeptNo=d.DeptNo "); | |||
strSql.Append(" where 1=1 "); | |||
var queryParam = queryJson.ToJObject(); | |||
// 虚拟参数 | |||
var dp = new DynamicParameters(new { }); | |||
if (!queryParam["SqlParam"].IsEmpty()) | |||
if (!queryParam["Types"].IsEmpty())//助学金类型:1国家助学金,2校级助学金 | |||
{ | |||
strSql.Append(queryParam["SqlParam"].ToString()); | |||
dp.Add("Types", queryParam["Types"].ToString(), DbType.String); | |||
strSql.Append(" AND t.Types=@Types "); | |||
} | |||
if (!queryParam["StuNo"].IsEmpty()) | |||
{ | |||
dp.Add("StuNo", "%"+queryParam["StuNo"].ToString()+ "%", DbType.String); | |||
dp.Add("StuNo", "%" + queryParam["StuNo"].ToString() + "%", DbType.String); | |||
strSql.Append(" AND t.StuNo Like @StuNo "); | |||
} | |||
if (!queryParam["IdentityCardNo"].IsEmpty()) | |||
{ | |||
dp.Add("IdentityCardNo", "%" + queryParam["IdentityCardNo"].ToString() + "%", DbType.String); | |||
strSql.Append(" AND t.IdentityCardNo like @IdentityCardNo "); | |||
} | |||
if (!queryParam["StuName"].IsEmpty()) | |||
{ | |||
dp.Add("StuName", "%" + queryParam["StuName"].ToString() + "%", DbType.String); | |||
strSql.Append(" AND t.StuName Like @StuName "); | |||
} | |||
if (!queryParam["DeptNo"].IsEmpty()) | |||
{ | |||
dp.Add("DeptNo", queryParam["DeptNo"].ToString(), DbType.String); | |||
strSql.Append(" AND t.DeptNo=@DeptNo "); | |||
strSql.Append(" AND s.StuName Like @StuName "); | |||
} | |||
if (!queryParam["MajorNo"].IsEmpty()) | |||
if (!queryParam["F_SchoolId"].IsEmpty()) | |||
{ | |||
dp.Add("MajorNo", queryParam["MajorNo"].ToString(), DbType.String); | |||
strSql.Append(" AND t.MajorNo=@MajorNo "); | |||
dp.Add("F_SchoolId", queryParam["F_SchoolId"].ToString(), DbType.String); | |||
strSql.Append(" AND s.F_SchoolId=@F_SchoolId "); | |||
} | |||
if (!queryParam["ClassNo"].IsEmpty()) | |||
{ | |||
dp.Add("ClassNo", queryParam["ClassNo"].ToString(), DbType.String); | |||
strSql.Append(" AND t.ClassNo=@ClassNo "); | |||
strSql.Append(" AND s.ClassNo=@ClassNo "); | |||
} | |||
if (!queryParam["Grade"].IsEmpty()) | |||
if (!queryParam["IdentityCardNo"].IsEmpty()) | |||
{ | |||
dp.Add("Grade", queryParam["Grade"].ToString(), DbType.String); | |||
strSql.Append(" AND t.Grade=@Grade "); | |||
dp.Add("IdentityCardNo", "%" + queryParam["IdentityCardNo"].ToString() + "%", DbType.String); | |||
strSql.Append(" AND s.IdentityCardNo like @IdentityCardNo "); | |||
} | |||
if (!queryParam["SubsidizeType"].IsEmpty()) | |||
{ | |||
dp.Add("SubsidizeType", "" + queryParam["SubsidizeType"].ToString() + "", DbType.String); | |||
dp.Add("SubsidizeType", queryParam["SubsidizeType"].ToString(), DbType.String); | |||
strSql.Append(" AND t.SubsidizeType=@SubsidizeType "); | |||
} | |||
if (!queryParam["OpenAccount"].IsEmpty()) | |||
if (!queryParam["OpenBankNo"].IsEmpty()) | |||
{ | |||
dp.Add("OpenAccount", "" + queryParam["OpenAccount"].ToString() + "", DbType.String); | |||
strSql.Append(" AND t.OpenAccount=@OpenAccount "); | |||
dp.Add("OpenBankNo", "%" + queryParam["OpenBankNo"].ToString() + "%", DbType.String); | |||
strSql.Append(" AND t.OpenBankNo Like @OpenBankNo "); | |||
} | |||
if (!queryParam["OpenBank"].IsEmpty()) | |||
if (!queryParam["StartTime"].IsEmpty() && !queryParam["EndTime"].IsEmpty()) | |||
{ | |||
dp.Add("OpenBank", "" + queryParam["OpenBank"].ToString() + "", DbType.String); | |||
strSql.Append(" AND t.OpenBank=@OpenBank "); | |||
dp.Add("startTime", queryParam["StartTime"].ToDate(), DbType.DateTime); | |||
dp.Add("endTime", queryParam["EndTime"].ToDate(), DbType.DateTime); | |||
strSql.Append(" AND ( t.ApplyDate >= @startTime AND t.ApplyDate <= @endTime ) "); | |||
} | |||
if (!queryParam["ReleaseDate"].IsEmpty()) | |||
if (!queryParam["StartTimeRelease"].IsEmpty() && !queryParam["EndTimeRelease"].IsEmpty()) | |||
{ | |||
dp.Add("ReleaseDate", "%" + queryParam["ReleaseDate"].ToString() + "%", DbType.String); | |||
strSql.Append(" AND t.ReleaseDate Like @ReleaseDate "); | |||
dp.Add("StartTimeRelease", queryParam["StartTimeRelease"].ToDate(), DbType.DateTime); | |||
dp.Add("EndTimeRelease", queryParam["EndTimeRelease"].ToDate(), DbType.DateTime); | |||
strSql.Append(" AND ( t.ReleaseDate >= @StartTimeRelease AND t.ReleaseDate <= @EndTimeRelease ) "); | |||
} | |||
if (!queryParam["StartTime"].IsEmpty() && !queryParam["EndTime"].IsEmpty()) | |||
if (!queryParam["Step"].IsEmpty() && queryParam["Step"].ToString() == "2")//第二步:二级学院审核 | |||
{ | |||
dp.Add("startTime", queryParam["StartTime"].ToDate(), DbType.DateTime); | |||
dp.Add("endTime", queryParam["EndTime"].ToDate(), DbType.DateTime); | |||
strSql.Append(" AND ( CreateDate >= @startTime AND CreateDate <= @endTime ) "); | |||
//不查看状态为草稿的记录 | |||
strSql.Append(" AND t.Status > 0 "); | |||
//二级学院审核专员==系部负责人==登录用户 | |||
strSql.Append($" and d.DeptDirector='{LoginUserInfo.Get().account}' "); | |||
} | |||
if (!queryParam["Step"].IsEmpty() && queryParam["Step"].ToString() == "3")//第三步:学工部审核 | |||
{ | |||
//不查看状态为草稿的记录 | |||
strSql.Append(" AND t.Status > 1 "); | |||
} | |||
if (!queryParam["Status"].IsEmpty()) | |||
{ | |||
dp.Add("Status", queryParam["Status"].ToString(), DbType.String); | |||
strSql.Append(" AND t.Status = @Status "); | |||
} | |||
return this.BaseRepository("CollegeMIS").FindList<StuFellowshipEntity>(strSql.ToString(), dp, pagination); | |||
} | |||
@@ -162,7 +169,8 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
{ | |||
try | |||
{ | |||
return this.BaseRepository("CollegeMIS").FindEntity<StuFellowshipEntity>(keyValue); | |||
var strsql = $"select t.*,s.StuName,s.F_SchoolId,s.ClassNo,s.IdentityCardNo,s.IdCardType,s.DepositBank as OpenBank,s.BankCard as OpenAccount from StuFellowship t left join StuInfoBasic s on t.StuNo=s.StuNo where 1=1 and t.ID='{keyValue}' "; | |||
return this.BaseRepository("CollegeMIS").FindEntity<StuFellowshipEntity>(strsql, null); | |||
} | |||
catch (Exception ex) | |||
{ | |||
@@ -237,6 +245,73 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
} | |||
} | |||
/// <summary> | |||
/// 提交 | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
public void DoSubmit(string keyValue, string status, string step) | |||
{ | |||
try | |||
{ | |||
if (step == "1")//第一步:提交二级学院审核 | |||
{ | |||
this.BaseRepository("CollegeMIS").ExecuteBySql($"update StuFellowship set SubmitTime='{DateTime.Now}',SubmitUserId='{LoginUserInfo.Get().userId}',Status='{status}' where Id='{keyValue}' "); | |||
} | |||
else if (step == "2")//第二步:提交学工部审核 | |||
{ | |||
this.BaseRepository("CollegeMIS").ExecuteBySql($"update StuFellowship set FirstCheckTime='{DateTime.Now}',FirstCheckUserId='{LoginUserInfo.Get().userId}',Status='{status}' where Id='{keyValue}' "); | |||
} | |||
else if (step == "3")//第三步:归档 | |||
{ | |||
this.BaseRepository("CollegeMIS").ExecuteBySql($"update StuFellowship set SecondCheckTime='{DateTime.Now}',SecondCheckUserId='{LoginUserInfo.Get().userId}',Status='{status}' where Id='{keyValue}' "); | |||
} | |||
} | |||
catch (Exception ex) | |||
{ | |||
if (ex is ExceptionEx) | |||
{ | |||
throw; | |||
} | |||
else | |||
{ | |||
throw ExceptionEx.ThrowServiceException(ex); | |||
} | |||
} | |||
} | |||
/// <summary> | |||
/// 退回 | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
public void DoBack(string keyValue, string status, string step) | |||
{ | |||
try | |||
{ | |||
if (step == "2")//第二步:退回辅导员 | |||
{ | |||
this.BaseRepository("CollegeMIS").ExecuteBySql($"update StuFellowship set FirstCheckTime='{DateTime.Now}',FirstCheckUserId='{LoginUserInfo.Get().userId}',Status='{status}' where Id='{keyValue}' "); | |||
} | |||
else if (step == "3")//第三步:退回辅导员、退回二级学院 | |||
{ | |||
this.BaseRepository("CollegeMIS").ExecuteBySql($"update StuFellowship set SecondCheckTime='{DateTime.Now}',SecondCheckUserId='{LoginUserInfo.Get().userId}',Status='{status}' where Id='{keyValue}' "); | |||
} | |||
} | |||
catch (Exception ex) | |||
{ | |||
if (ex is ExceptionEx) | |||
{ | |||
throw; | |||
} | |||
else | |||
{ | |||
throw ExceptionEx.ThrowServiceException(ex); | |||
} | |||
} | |||
} | |||
#endregion | |||
} | |||
@@ -735,22 +735,22 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
[Column("DOMICILE")] | |||
public string Domicile { get; set; } | |||
/// <summary> | |||
/// 开户银行位置 | |||
/// 父亲户籍地址 | |||
/// </summary> | |||
[Column("OneDomicile")] | |||
public string OneDomicile { get; set; } | |||
/// <summary> | |||
/// 开户银行位置 | |||
/// 母亲户籍地址 | |||
/// </summary> | |||
[Column("TWODOMICILE")] | |||
public string TwoDomicile { get; set; } | |||
/// <summary> | |||
/// 开户银行位置 | |||
/// 父亲现住址 | |||
/// </summary> | |||
[Column("ONEADDRESS")] | |||
public string OneAddress { get; set; } | |||
/// <summary> | |||
/// 开户银行位置 | |||
/// 母亲现住址 | |||
/// </summary> | |||
[Column("TWOADDRESS")] | |||
public string TwoAddress { get; set; } | |||
@@ -1155,6 +1155,20 @@ | |||
"style": { | |||
"navigationBarTitleText": "资产详情" | |||
} | |||
}, | |||
//考试安排教师功能 | |||
{ | |||
"path": "pages/EducationalAdministration/ArrangeExamTermNew/list", | |||
"style": { | |||
"navigationBarTitleText": "考试安排" | |||
} | |||
}, | |||
//考试安排学生功能 | |||
{ | |||
"path": "pages/EducationalAdministration/ArrangeExamTerm/list", | |||
"style": { | |||
"navigationBarTitleText": "考试安排" | |||
} | |||
} | |||
@@ -0,0 +1,368 @@ | |||
<template> | |||
<view class="page"> | |||
<!-- 主列表页 --> | |||
<view :class="sideOpen ? 'show' : ''" class="mainpage" style="padding-top: 80rpx;"> | |||
<!-- 顶部条目/分页信息栏 --> | |||
<l-customlist-banner @buttonClick="sideOpen = true">{{ tips }}</l-customlist-banner> | |||
<!-- 滚动列表,跨端支持上拉/下拉 --> | |||
<l-scroll-list v-if="ready" @pullDown="pullDown" @toBottom="fetchList()" ref="list"> | |||
<l-customlist :tips="loadState" showTips> | |||
<!-- 单条记录 --> | |||
<view class="customlist-item" v-for="item of list" :key="item.EPIId"> | |||
<view class="customlist-item-field"> | |||
<text class="customlist-item-field-title">考试日期:</text> | |||
{{ displayListItem(item, 'ExamDate') }} | |||
</view> | |||
<view class="customlist-item-field"> | |||
<text class="customlist-item-field-title">考试时间:</text> | |||
{{ displayListItem(item, 'ExamTime') }} | |||
</view> | |||
<view class="customlist-item-field"> | |||
<text class="customlist-item-field-title">课程编号:</text> | |||
{{ displayListItem(item, 'LessonNo') }} | |||
</view> | |||
<view class="customlist-item-field"> | |||
<text class="customlist-item-field-title">课程名称:</text> | |||
{{ displayListItem(item, 'LessonName') }} | |||
</view> | |||
<view class="customlist-item-field"> | |||
<text class="customlist-item-field-title">教师名称:</text> | |||
{{ displayListItem(item, 'EmpName') }} | |||
</view> | |||
<view class="customlist-item-field"> | |||
<text class="customlist-item-field-title">教室名称:</text> | |||
{{ displayListItem(item, 'ClassroomName') }} | |||
</view> | |||
<view class="customlist-item-field"> | |||
<text class="customlist-item-field-title">座位编号:</text> | |||
{{ displayListItem(item, 'SitNumber') }} | |||
</view> | |||
<!-- <l-customlist-action showEdit @edit="action('edit', item.EPIId)" showDelete @delete="action('delete', item.EPIId)" @view="action('view', item.EPIId)" /> --> | |||
</view> | |||
</l-customlist> | |||
</l-scroll-list> | |||
</view> | |||
<!-- 关闭侧边抽屉按钮 --> | |||
<view @click="sideOpen = false" :class="sideOpen ? 'show' : ''" class="sideclose"> | |||
<l-icon type="pullright" color="blue" /> | |||
</view> | |||
<!-- 侧边栏,用于设置查询条件 --> | |||
<scroll-view :class="sideOpen ? 'show' : ''" class="sidepage" scroll-y> | |||
<view v-if="ready" class="padding"> | |||
<l-customlist-sidepage-datefilter v-model="dateRange" @change="searchChange" title="按时间日期查询: " | |||
ref="datefilter" class="margin-bottom" /> | |||
<l-input v-model="queryData.LessonName" @change="searchChange" title="课程" placeholder="按课程查询" /> | |||
<l-input v-model="queryData.EmpName" @change="searchChange" title="教师" placeholder="按教师查询" /> | |||
<l-input v-model="queryData.ClassRoomName" @change="searchChange" title="教室" placeholder="按教室查询" /> | |||
<!-- 重置查询条件按钮 --> | |||
<view class="padding-tb"> | |||
<l-button @click="reset" line="orange" class="block" block>重置查询条件</l-button> | |||
</view> | |||
</view> | |||
</scroll-view> | |||
<!-- <l-customlist-add v-if="!sideOpen" @click="action('add')" /> --> | |||
</view> | |||
</template> | |||
<script> | |||
/* | |||
* 版 本 Learun-ADMS V7.0.3 力软敏捷开发框架(http://www.learun.cn) | |||
* Copyright (c) 2013-2020 上海力软信息技术有限公司 | |||
* 创建人:超级管理员 | |||
* 日 期:2020-10-14 11:43 | |||
* 描 述:1111 | |||
*/ | |||
/** | |||
* 本段代码由移动端代码生成器输出,移动端须 2.2.0 版本及以上可以使用 | |||
* 请在移动端 /pages.json 中的 pages 字段中添加一条记录: | |||
* { "path": "pages/EducationalAdministration/ArrangeExamTerm/list", "style": { "navigationBarTitleText": "表单列表页" } } | |||
* | |||
* (navigationBarTitleText 字段为本页面的标题文本,可以修改) | |||
* (必须自行操作该步骤,力软代码生成器不会自动帮您修改 /pages.json 文件) | |||
*/ | |||
import moment from 'moment' | |||
import get from 'lodash/get' | |||
import set from 'lodash/set' | |||
import pickBy from 'lodash/pickBy' | |||
import mapValues from 'lodash/mapValues' | |||
export default { | |||
data() { | |||
return { | |||
// 数据项的数据类型、结构 | |||
scheme: { | |||
ClassroomName: { | |||
type: 'text' | |||
}, | |||
ClassroomNo: { | |||
type: 'text' | |||
}, | |||
EPIId: { | |||
type: 'text' | |||
}, | |||
EPId: { | |||
type: 'text' | |||
}, | |||
EmpName: { | |||
type: 'text' | |||
}, | |||
EmpNo: { | |||
type: 'text' | |||
}, | |||
ExamDate: { | |||
type: 'datetime',dateformat: '0' | |||
}, | |||
ExamTime: { | |||
type: 'text' | |||
}, | |||
F_SchoolId: { | |||
type: 'text' | |||
}, | |||
LessonName: { | |||
type: 'text' | |||
}, | |||
LessonNo: { | |||
type: 'text' | |||
}, | |||
SitNumber: { | |||
type: 'text' | |||
}, | |||
}, | |||
// 查询条件 | |||
searchData: { | |||
StuNo: this.GET_GLOBAL('loginUser').account, | |||
}, | |||
defaultQueryData: {}, | |||
queryData: { | |||
//查询条件的文本框 | |||
StuNo: this.GET_GLOBAL('loginUser').account, | |||
LessonName:'', | |||
ClassRoomName:'', | |||
EmpName:'', | |||
}, | |||
// 数据源 | |||
dataSource: { | |||
// LessonNo:[], | |||
// ClassRoomNo:[], | |||
// EmpNo:[], | |||
}, | |||
// 时间查询参数 | |||
dateRange: null, | |||
// 页面相关参数 | |||
ready: false, | |||
tips: '加载中...', | |||
loadState: '向下翻以加载更多', | |||
sideOpen: false, | |||
// 列表与分页信息 | |||
page: 1, | |||
total: 2, | |||
list: [] | |||
} | |||
}, | |||
async onLoad() { | |||
await this.init() | |||
}, | |||
onUnload() { | |||
this.OFF('EducationalAdministrationArrangeExamTerm-list-change') | |||
}, | |||
methods: { | |||
// 页面初始化 | |||
async init() { | |||
let _this = this; | |||
_this.searchData.StuNo = this.GET_GLOBAL('loginUser').account; | |||
this.ON('EducationalAdministrationArrangeExamTerm-list-change', this.refreshList) | |||
// 拉取加载列表和数据源 | |||
await Promise.all([ | |||
// this.FETCH_DATASOURCE('LessonInfo').then(result => { | |||
// this.dataSource.LessonNo = result.data.sort((a,b)=>{return b.lessonno.lessonno}).map(t => ({ text: t.lessonname, value: t.lessonno })) | |||
// }), | |||
// this.FETCH_DATASOURCE('ClassRoomInfo').then(result => { | |||
// this.dataSource.ClassRoomNo = result.data.sort((a,b)=>{return b.classroomno.classroomno}).map(t => ({ text: t.classroomname, value: t.classroomno })) | |||
// }), | |||
// this.FETCH_DATASOURCE('EmpInfo').then(result => { | |||
// this.dataSource.EmpNo = result.data.sort((a,b)=>{return b.empno.empno}).map(t => ({ text: t.empname, value: t.empno })) | |||
// }), | |||
() => {} | |||
]) | |||
await this.fetchList() | |||
// 初始化查询条件 | |||
this.defaultQueryData = this.COPY(this.queryData) | |||
this.ready = true | |||
}, | |||
// 拉取列表 | |||
async fetchList(isConcat = true) { | |||
// if (this.page > this.total) { return } | |||
const result = await this.HTTP_GET( | |||
'learun/ask/teststulist', { | |||
// 这里 sidx 表示排序字段,sord 表示排序方式(DESC=降序,ASC=升序) | |||
// 代码生成器生成时默认按照主键排序,您可以修改成按创建时间的字段降序 | |||
pagination: { | |||
rows: 10, | |||
page: this.page, | |||
sidx: 'ExamDate desc,ExamTime asc,LessonNo asc,ClassroomNo asc', | |||
sord: 'DESC' | |||
}, | |||
queryJson: JSON.stringify(this.searchData) | |||
}, | |||
'加载数据时出错' | |||
) | |||
if (!result) { | |||
return | |||
} | |||
this.total = result.total | |||
this.page = result.page + 1 | |||
this.list = isConcat?this.list.concat(result.rows):result.rows | |||
this.tips = `已加载 ${Math.min(result.page, result.total)} / ${result.total} 页,共 ${result.records} 项` | |||
this.loadState = result.page >= result.total ? '已加载所有项目' : '向下翻以加载更多' | |||
}, | |||
// 刷新清空列表 | |||
async refreshList() { | |||
this.page = 1 | |||
this.total = 2 | |||
this.list = [] | |||
await this.fetchList(false) | |||
}, | |||
// 列表下拉 | |||
pullDown() { | |||
this.refreshList().then(() => { | |||
this.$refs.list.stopPullDown() | |||
}) | |||
}, | |||
// 设置搜索条件 | |||
async searchChange() { | |||
const result = {} | |||
// | |||
// 时间查询相关参数 | |||
if (this.dateRange) { | |||
result.StartTime = this.dateRange.start | |||
result.EndTime = this.dateRange.end | |||
} | |||
// 将其他查询项添加到查询 JSON 中 | |||
const queryObj = pickBy(this.queryData, t => (Array.isArray(t) ? t.length > 0 : t)) | |||
Object.assign(result, mapValues(queryObj, t => (Array.isArray(t) ? t.join(',') : t))) | |||
this.searchData = result | |||
await this.refreshList() | |||
}, | |||
// 点击「清空查询条件」按钮 | |||
reset() { | |||
this.$refs.datefilter.changeDateRange('all') | |||
this.queryData = this.COPY(this.defaultQueryData) | |||
this.searchChange() | |||
}, | |||
// 点击「编辑」、「查看」、「添加」、「删除」按钮 | |||
async action(type, id = '') { | |||
switch (type) { | |||
case 'view': | |||
this.NAV_TO(`./single?type=view&id=${id}`) | |||
return | |||
case 'add': | |||
this.NAV_TO('./single?type=create') | |||
return | |||
case 'edit': | |||
this.NAV_TO(`./single?type=edit&id=${id}`) | |||
return | |||
case 'delete': | |||
if (!(await this.CONFIRM('删除项目', '确定要删除该项吗?', true))) { | |||
return | |||
} | |||
this.HTTP_POST('learun/adms/EducationalAdministration/ArrangeExamTerm/delete', id, '删除失败') | |||
.then(success => { | |||
if (!success) { | |||
return | |||
} | |||
this.TOAST('删除成功', 'success') | |||
this.refreshList() | |||
}) | |||
return | |||
default: | |||
return | |||
} | |||
}, | |||
// 显示列表中的标题项 | |||
displayListItem(item, field) { | |||
const fieldItem = this.scheme[field] | |||
const value = item[field] | |||
switch (fieldItem.type) { | |||
case 'currentInfo': | |||
case 'organize': | |||
return fieldItem.dataType === 'time' ? value : get(this.GET_GLOBAL(fieldItem.dataType), | |||
`${value}.name`, '') | |||
case 'radio': | |||
case 'select': | |||
const selectItem = this.dataSource[field].find(t => t.value === String(value)) | |||
return get(selectItem, 'text', '') | |||
case 'checkbox': | |||
if (!value || value.split(',').length <= 0) { | |||
return '' | |||
} | |||
const checkboxItems = value.split(',') | |||
return this.dataSource[field].filter(t => checkboxItems.includes(t.value)).map(t => t.text).join( | |||
',') | |||
case 'datetime': | |||
if (!value) { | |||
return '' | |||
} | |||
return moment(value).format(Number(fieldItem.dateformat) === 0 ? 'YYYY年 M月 D日' : | |||
'YYYY-MM-DD HH:mm') | |||
default: | |||
return value === null || value === undefined ? '' : value | |||
} | |||
} | |||
} | |||
} | |||
</script> | |||
<style lang="less" scoped> | |||
@import '~@/common/css/sidepage.less'; | |||
@import '~@/common/css/customlist.less'; | |||
</style> |
@@ -0,0 +1,344 @@ | |||
<template> | |||
<view class="page"> | |||
<!-- 主列表页 --> | |||
<view :class="sideOpen ? 'show' : ''" class="mainpage" style="padding-top: 80rpx;"> | |||
<!-- 顶部条目/分页信息栏 --> | |||
<l-customlist-banner @buttonClick="sideOpen = true">{{ tips }}</l-customlist-banner> | |||
<!-- 滚动列表,跨端支持上拉/下拉 --> | |||
<l-scroll-list v-if="ready" @pullDown="pullDown" @toBottom="fetchList()" ref="list"> | |||
<l-customlist :tips="loadState" showTips> | |||
<!-- 单条记录 --> | |||
<view class="customlist-item" v-for="item of list" :key="item.EPIId"> | |||
<view class="customlist-item-field"> | |||
<text class="customlist-item-field-title">考试日期:</text> | |||
{{ displayListItem(item, 'ExamDate') }} | |||
</view> | |||
<view class="customlist-item-field"> | |||
<text class="customlist-item-field-title">考试时间:</text> | |||
{{ displayListItem(item, 'ExamTime') }} | |||
</view> | |||
<view class="customlist-item-field"> | |||
<text class="customlist-item-field-title">课程编号:</text> | |||
{{ displayListItem(item, 'LessonNo') }} | |||
</view> | |||
<view class="customlist-item-field"> | |||
<text class="customlist-item-field-title">课程名称:</text> | |||
{{ displayListItem(item, 'LessonName') }} | |||
</view> | |||
<view class="customlist-item-field"> | |||
<text class="customlist-item-field-title">教室名称:</text> | |||
{{ displayListItem(item, 'ClassroomName') }} | |||
</view> | |||
<!-- <l-customlist-action showEdit @edit="action('edit', item.EPIId)" showDelete @delete="action('delete', item.EPIId)" @view="action('view', item.EPIId)" /> --> | |||
</view> | |||
</l-customlist> | |||
</l-scroll-list> | |||
</view> | |||
<!-- 关闭侧边抽屉按钮 --> | |||
<view @click="sideOpen = false" :class="sideOpen ? 'show' : ''" class="sideclose"> | |||
<l-icon type="pullright" color="blue" /> | |||
</view> | |||
<!-- 侧边栏,用于设置查询条件 --> | |||
<scroll-view :class="sideOpen ? 'show' : ''" class="sidepage" scroll-y> | |||
<view v-if="ready" class="padding"> | |||
<l-customlist-sidepage-datefilter v-model="dateRange" @change="searchChange" title="按时间日期查询: " | |||
ref="datefilter" class="margin-bottom" /> | |||
<l-input v-model="queryData.LessonName" @change="searchChange" title="课程" placeholder="按课程查询" /> | |||
<!-- 重置查询条件按钮 --> | |||
<view class="padding-tb"> | |||
<l-button @click="reset" line="orange" class="block" block>重置查询条件</l-button> | |||
</view> | |||
</view> | |||
</scroll-view> | |||
<!-- <l-customlist-add v-if="!sideOpen" @click="action('add')" /> --> | |||
</view> | |||
</template> | |||
<script> | |||
/* | |||
* 版 本 Learun-ADMS V7.0.3 力软敏捷开发框架(http://www.learun.cn) | |||
* Copyright (c) 2013-2020 上海力软信息技术有限公司 | |||
* 创建人:超级管理员 | |||
* 日 期:2020-10-14 11:43 | |||
* 描 述:1111 | |||
*/ | |||
/** | |||
* 本段代码由移动端代码生成器输出,移动端须 2.2.0 版本及以上可以使用 | |||
* 请在移动端 /pages.json 中的 pages 字段中添加一条记录: | |||
* { "path": "pages/EducationalAdministration/ArrangeExamTermNew/list", "style": { "navigationBarTitleText": "表单列表页" } } | |||
* | |||
* (navigationBarTitleText 字段为本页面的标题文本,可以修改) | |||
* (必须自行操作该步骤,力软代码生成器不会自动帮您修改 /pages.json 文件) | |||
*/ | |||
import moment from 'moment' | |||
import get from 'lodash/get' | |||
import set from 'lodash/set' | |||
import pickBy from 'lodash/pickBy' | |||
import mapValues from 'lodash/mapValues' | |||
export default { | |||
data() { | |||
return { | |||
// 数据项的数据类型、结构 | |||
scheme: { | |||
ClassroomName: { | |||
type: 'text' | |||
}, | |||
ClassroomNo: { | |||
type: 'text' | |||
}, | |||
EPIId: { | |||
type: 'text' | |||
}, | |||
EPId: { | |||
type: 'text' | |||
}, | |||
EmpName: { | |||
type: 'text' | |||
}, | |||
EmpNo: { | |||
type: 'text' | |||
}, | |||
ExamDate: { | |||
type: 'datetime',dateformat: '0' | |||
}, | |||
ExamTime: { | |||
type: 'text' | |||
}, | |||
F_SchoolId: { | |||
type: 'text' | |||
}, | |||
LessonName: { | |||
type: 'text' | |||
}, | |||
LessonNo: { | |||
type: 'text' | |||
}, | |||
}, | |||
// 查询条件 | |||
searchData: { | |||
EmpNo: this.GET_GLOBAL('loginUser').account | |||
}, | |||
defaultQueryData: {}, | |||
queryData: { | |||
//查询条件的文本框 | |||
EmpNo: this.GET_GLOBAL('loginUser').account, | |||
LessonName:'', | |||
}, | |||
// 数据源 | |||
dataSource: { | |||
// LessonNo: [], | |||
}, | |||
// 时间查询参数 | |||
dateRange: null, | |||
// 页面相关参数 | |||
ready: false, | |||
tips: '加载中...', | |||
loadState: '向下翻以加载更多', | |||
sideOpen: false, | |||
// 列表与分页信息 | |||
page: 1, | |||
total: 2, | |||
list: [] | |||
} | |||
}, | |||
async onLoad() { | |||
await this.init() | |||
}, | |||
onUnload() { | |||
this.OFF('EducationalAdministrationArrangeExamTermNew-list-change') | |||
}, | |||
methods: { | |||
// 页面初始化 | |||
async init() { | |||
let _this = this; | |||
_this.searchData.EmpNo = this.GET_GLOBAL('loginUser').account; | |||
this.ON('EducationalAdministrationArrangeExamTermNew-list-change', this.refreshList) | |||
// 拉取加载列表和数据源 | |||
await Promise.all([ | |||
// this.FETCH_DATASOURCE('LessonInfo').then(result => { | |||
// this.dataSource.LessonNo = result.data.sort((a,b)=>{return b.lessonno.lessonno}).map(t => ({ text: t.lessonname, value: t.lessonno })) | |||
// }), | |||
() => {} | |||
]) | |||
await this.fetchList() | |||
// 初始化查询条件 | |||
this.defaultQueryData = this.COPY(this.queryData) | |||
this.ready = true | |||
}, | |||
// 拉取列表 | |||
async fetchList(isConcat = true) { | |||
// if (this.page > this.total) { return } | |||
const result = await this.HTTP_GET( | |||
'learun/ask/testlist', { | |||
// 这里 sidx 表示排序字段,sord 表示排序方式(DESC=降序,ASC=升序) | |||
// 代码生成器生成时默认按照主键排序,您可以修改成按创建时间的字段降序 | |||
pagination: { | |||
rows: 10, | |||
page: this.page, | |||
sidx: 'ExamDate desc,ExamTime asc,LessonNo asc,ClassroomNo asc', | |||
sord: 'DESC' | |||
}, | |||
queryJson: JSON.stringify(this.searchData) | |||
}, | |||
'加载数据时出错' | |||
) | |||
if (!result) { | |||
return | |||
} | |||
this.total = result.total | |||
this.page = result.page + 1 | |||
this.list = isConcat?this.list.concat(result.rows):result.rows | |||
this.tips = `已加载 ${Math.min(result.page, result.total)} / ${result.total} 页,共 ${result.records} 项` | |||
this.loadState = result.page >= result.total ? '已加载所有项目' : '向下翻以加载更多' | |||
}, | |||
// 刷新清空列表 | |||
async refreshList() { | |||
this.page = 1 | |||
this.total = 2 | |||
this.list = [] | |||
await this.fetchList(false) | |||
}, | |||
// 列表下拉 | |||
pullDown() { | |||
this.refreshList().then(() => { | |||
this.$refs.list.stopPullDown() | |||
}) | |||
}, | |||
// 设置搜索条件 | |||
async searchChange() { | |||
const result = {} | |||
// | |||
// 时间查询相关参数 | |||
if (this.dateRange) { | |||
result.StartTime = this.dateRange.start | |||
result.EndTime = this.dateRange.end | |||
} | |||
// 将其他查询项添加到查询 JSON 中 | |||
const queryObj = pickBy(this.queryData, t => (Array.isArray(t) ? t.length > 0 : t)) | |||
Object.assign(result, mapValues(queryObj, t => (Array.isArray(t) ? t.join(',') : t))) | |||
this.searchData = result | |||
await this.refreshList() | |||
}, | |||
// 点击「清空查询条件」按钮 | |||
reset() { | |||
this.$refs.datefilter.changeDateRange('all') | |||
this.queryData = this.COPY(this.defaultQueryData) | |||
this.searchChange() | |||
}, | |||
// 点击「编辑」、「查看」、「添加」、「删除」按钮 | |||
async action(type, id = '') { | |||
switch (type) { | |||
case 'view': | |||
this.NAV_TO(`./single?type=view&id=${id}`) | |||
return | |||
case 'add': | |||
this.NAV_TO('./single?type=create') | |||
return | |||
case 'edit': | |||
this.NAV_TO(`./single?type=edit&id=${id}`) | |||
return | |||
case 'delete': | |||
if (!(await this.CONFIRM('删除项目', '确定要删除该项吗?', true))) { | |||
return | |||
} | |||
this.HTTP_POST('learun/adms/EducationalAdministration/ArrangeExamTermNew/delete', id, '删除失败') | |||
.then(success => { | |||
if (!success) { | |||
return | |||
} | |||
this.TOAST('删除成功', 'success') | |||
this.refreshList() | |||
}) | |||
return | |||
default: | |||
return | |||
} | |||
}, | |||
// 显示列表中的标题项 | |||
displayListItem(item, field) { | |||
const fieldItem = this.scheme[field] | |||
const value = item[field] | |||
switch (fieldItem.type) { | |||
case 'currentInfo': | |||
case 'organize': | |||
return fieldItem.dataType === 'time' ? value : get(this.GET_GLOBAL(fieldItem.dataType), | |||
`${value}.name`, '') | |||
case 'radio': | |||
case 'select': | |||
const selectItem = this.dataSource[field].find(t => t.value === String(value)) | |||
return get(selectItem, 'text', '') | |||
case 'checkbox': | |||
if (!value || value.split(',').length <= 0) { | |||
return '' | |||
} | |||
const checkboxItems = value.split(',') | |||
return this.dataSource[field].filter(t => checkboxItems.includes(t.value)).map(t => t.text).join( | |||
',') | |||
case 'datetime': | |||
if (!value) { | |||
return '' | |||
} | |||
return moment(value).format(Number(fieldItem.dateformat) === 0 ? 'YYYY年 M月 D日' : | |||
'YYYY-MM-DD HH:mm') | |||
default: | |||
return value === null || value === undefined ? '' : value | |||
} | |||
} | |||
} | |||
} | |||
</script> | |||
<style lang="less" scoped> | |||
@import '~@/common/css/sidepage.less'; | |||
@import '~@/common/css/customlist.less'; | |||
</style> |