public IEnumerable<FinaChargesStandardEntity> finaChargesStandardList { get; set; }
public IEnumerable<FinaChargesStandardEntity> finaChargesStandardListGroup { get; set; }
public FinaChargeStudentEntity stuitem { get; set; }
public UserInfo userInfo { get; set; }
}
private Thread thread = null;
public void SaveGenerateByCondition(FinaChargeStuYearEntity entity)
{
try
{
//获取缴费学生
var stulist = BaseRepository("CollegeMIS").FindList<FinaChargeStudentEntity>(m => m.F_CheckMark == true);
//获取已有年度学生缴费记录
var oldFinaChargeStuYearList = BaseRepository("CollegeMIS").FindList<FinaChargeStuYearEntity>(m => m.FSYear == entity.FSYear);
//获取已有年度学生缴费明细记录
var oldFinaChargeStuYearItemList = BaseRepository("CollegeMIS").FindList<FinaChargeStuYearItemEntity>(m => m.FSYear == entity.FSYear);
//获取收费标准
var finaChargesStandardList = BaseRepository("CollegeMIS").FindList<FinaChargesStandardEntity>("select a.Grade,a.DeptNo,a.MajorNo,a.Standard,a.SYear,b.ChargeItemName,b.ChargeItemCode,b.ChargeItemType,b.priority from [dbo].[FinaChargesStandard] a left join [dbo].[FinaChargeItem] b on a.ChargeItemID=b.[ChargeItemID] where b.ChargeItemType=1 and a.SYear='" + entity.FSYear + "' and a.F_DeleteMark=0 and a.CheckMark=1 and b.CheckMark=1 and b.F_DeleteMark=0");
var finaChargesStandardListGroup = BaseRepository("CollegeMIS").FindList<FinaChargesStandardEntity>(@"select a.Grade,a.DeptNo,a.MajorNo,sum(isnull(a.Standard,0)) as YJAmount,a.SYear
from[dbo].[FinaChargesStandard] a left join[dbo].[FinaChargeItem] b on a.ChargeItemID = b.[ChargeItemID] where b.ChargeItemType=1 and a.SYear='" + entity.FSYear + "' and a.F_DeleteMark=0 and a.CheckMark=1 and b.CheckMark=1 and b.F_DeleteMark=0 group by a.Grade, a.DeptNo, a.MajorNo, a.SYear");
var stulist = BaseRepository("CollegeMIS").FindList<FinaChargeStudentEntity>(m => m.F_CheckMark == true);
//获取已有年度学生缴费记录
var oldFinaChargeStuYearList = BaseRepository("CollegeMIS").FindList<FinaChargeStuYearEntity>(m => m.FSYear == entity.FSYear);
//获取已有年度学生缴费明细记录
var oldFinaChargeStuYearItemList = BaseRepository("CollegeMIS").FindList<FinaChargeStuYearItemEntity>(m => m.FSYear == entity.FSYear);
//获取收费标准
var finaChargesStandardList = BaseRepository("CollegeMIS").FindList<FinaChargesStandardEntity>("select a.Grade,a.DeptNo,a.MajorNo,a.Standard,a.SYear,b.ChargeItemName,b.ChargeItemCode,b.ChargeItemType,b.priority from [dbo].[FinaChargesStandard] a left join [dbo].[FinaChargeItem] b on a.ChargeItemID=b.[ChargeItemID] where b.ChargeItemType=1 and a.SYear='" + entity.FSYear + "' and a.F_DeleteMark=0 and a.CheckMark=1 and b.CheckMark=1 and b.F_DeleteMark=0");
var finaChargesStandardListGroup = BaseRepository("CollegeMIS").FindList<FinaChargesStandardEntity>(@"select a.Grade,a.DeptNo,a.MajorNo,sum(isnull(a.Standard,0)) as YJAmount,a.SYear
from[dbo].[FinaChargesStandard] a left join[dbo].[FinaChargeItem] b on a.ChargeItemID = b.[ChargeItemID] where b.ChargeItemType=1 and a.SYear='" + entity.FSYear + "' and a.F_DeleteMark=0 and a.CheckMark=1 and b.CheckMark=1 and b.F_DeleteMark=0 group by a.Grade, a.DeptNo, a.MajorNo, a.SYear");