This commit is contained in:
2026-03-20 19:34:45 +08:00
parent 327b94c42b
commit dc8a8ad193
14 changed files with 1650 additions and 122 deletions
@@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using System.Linq;
using BLL;
@@ -71,15 +71,15 @@ namespace FineUIPro.Web.BaseInfo
private void BindGrid()
{
var q = from x in Funs.DB.Sys_Const
where x.GroupId == "RewardType" || x.GroupId == "PunishType"
orderby x.SortIndex
select new
{
ID = x.ID,
ConstText = x.ConstText,
Remark = x.Remark,
GroupName = x.GroupId == "RewardType" ? "奖励" : "处罚"
};
where x.GroupId == "RewardType" || x.GroupId == "PunishType"
orderby x.SortIndex
select new
{
ID = x.ID,
ConstText = x.ConstText,
Remark = x.Remark,
GroupName = x.GroupId == "RewardType" ? "奖励" : "处罚"
};
Grid1.RecordCount = q.Count();
// 2.获取当前分页数据
var table = GetPagedDataTable(Grid1.PageIndex, Grid1.PageSize);
@@ -95,15 +95,15 @@ namespace FineUIPro.Web.BaseInfo
{
var source =
(from x in Funs.DB.Sys_Const
where x.GroupId == "RewardType" || x.GroupId == "PunishType"
orderby x.SortIndex
select new
{
ID = x.ID,
ConstText = x.ConstText,
Remark = x.Remark,
GroupName = x.GroupId == "RewardType" ? "奖励" : "处罚"
}).ToList();
where x.GroupId == "RewardType" || x.GroupId == "PunishType"
orderby x.SortIndex
select new
{
ID = x.ID,
ConstText = x.ConstText,
Remark = x.Remark,
GroupName = x.GroupId == "RewardType" ? "奖励" : "处罚"
}).ToList();
List<dynamic> paged = new List<dynamic>();
@@ -283,14 +283,14 @@ namespace FineUIPro.Web.BaseInfo
model.GroupId = "PunishType";
}
}
if (string.IsNullOrEmpty(strRowID))
{
model.ID = SQLHelper.GetNewID(typeof(Model.Base_TrainLevel));
model.SortIndex = Funs.DB.Sys_Const.Where(x => x.GroupId == "RewardType" || x.GroupId == "PunishType")
.ToList().Count + 1;
if (!string.IsNullOrEmpty(this.rblIsType.SelectedValue))
{
if (this.rblIsType.SelectedValue == "奖励")
@@ -304,7 +304,7 @@ namespace FineUIPro.Web.BaseInfo
.ToList().Count + 1).ToString();
}
}
Funs.DB.Sys_Const.InsertOnSubmit(model);
Funs.DB.SubmitChanges();
}