20231115优化制定计划编辑页面打开速度
This commit is contained in:
@@ -560,7 +560,7 @@ namespace BLL
|
|||||||
select x;
|
select x;
|
||||||
if (listUnitIds.Count() > 0)
|
if (listUnitIds.Count() > 0)
|
||||||
{
|
{
|
||||||
getProjectPersons = getProjectPersons.Where(x => listUnitIds.Contains(x.UnitId));
|
getProjectPersons = getProjectPersons.Where(x => listUnitIds.Contains(x.UnitId)).OrderBy(x => x.PersonName);
|
||||||
}
|
}
|
||||||
if (listRoles.Count() > 0)
|
if (listRoles.Count() > 0)
|
||||||
{
|
{
|
||||||
@@ -579,6 +579,7 @@ namespace BLL
|
|||||||
{
|
{
|
||||||
list = (from x in getProjectPersons
|
list = (from x in getProjectPersons
|
||||||
join y in db.Person_Persons on x.PersonId equals y.PersonId
|
join y in db.Person_Persons on x.PersonId equals y.PersonId
|
||||||
|
orderby x.PersonName
|
||||||
select y).ToList();
|
select y).ToList();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -590,7 +591,7 @@ namespace BLL
|
|||||||
select x;
|
select x;
|
||||||
if (listUnitIds.Count() > 0)
|
if (listUnitIds.Count() > 0)
|
||||||
{
|
{
|
||||||
getPersons = getPersons.Where(x => listUnitIds.Contains(x.UnitId));
|
getPersons = getPersons.Where(x => listUnitIds.Contains(x.UnitId)).OrderBy(x=>x.PersonName);
|
||||||
}
|
}
|
||||||
if (listRoles.Count() > 0)
|
if (listRoles.Count() > 0)
|
||||||
{
|
{
|
||||||
@@ -605,11 +606,11 @@ namespace BLL
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
list = getPersons.ToList();
|
list = getPersons.OrderBy(x => x.PersonName).ToList();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return list.OrderBy(x => x.PersonName).ToList();
|
return list;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endregion
|
#endregion
|
||||||
|
|||||||
@@ -48,8 +48,9 @@
|
|||||||
<f:DatePicker ID="txtPlanDate" runat="server" Label="制定日期" LabelWidth="90px"
|
<f:DatePicker ID="txtPlanDate" runat="server" Label="制定日期" LabelWidth="90px"
|
||||||
EnableEdit="true">
|
EnableEdit="true">
|
||||||
</f:DatePicker>
|
</f:DatePicker>
|
||||||
<f:DropDownList ID="drpPlanMan" runat="server" Label="制定人" EnableEdit="true" LabelWidth="90px">
|
<f:TextBox ID="PlanManName" runat="server" Label="制定人" LabelWidth="90px">
|
||||||
</f:DropDownList>
|
</f:TextBox>
|
||||||
|
<f:TextBox ID="PlanManId" runat="server" Hidden="true"></f:TextBox>
|
||||||
</Items>
|
</Items>
|
||||||
</f:FormRow>
|
</f:FormRow>
|
||||||
<f:FormRow>
|
<f:FormRow>
|
||||||
|
|||||||
@@ -40,14 +40,16 @@ namespace FineUIPro.Web.PersonManage.Test
|
|||||||
this.TestPlanId = Request.Params["TestPlanId"];
|
this.TestPlanId = Request.Params["TestPlanId"];
|
||||||
this.btnClose.OnClientClick = ActiveWindow.GetHideReference();
|
this.btnClose.OnClientClick = ActiveWindow.GetHideReference();
|
||||||
Funs.FineUIPleaseSelect(this.drpUserType);
|
Funs.FineUIPleaseSelect(this.drpUserType);
|
||||||
Person_PersonsService.InitUserProjectIdUnitIdRoleIdDropDownList(this.drpPlanMan, this.CurrUser.LoginProjectId, null, null, true);
|
// Person_PersonsService.InitUserProjectIdUnitIdRoleIdDropDownList(this.drpPlanMan, this.CurrUser.LoginProjectId, Const.UnitId_SEDIN, null, true);
|
||||||
TestTrainingService.InitTestTrainingDropDownList(this.drpTraining, true);
|
TestTrainingService.InitTestTrainingDropDownList(this.drpTraining, true);
|
||||||
var getTestPlan = ServerTestPlanService.GetTestPlanById(this.TestPlanId);
|
var getTestPlan = ServerTestPlanService.GetTestPlanById(this.TestPlanId);
|
||||||
if (getTestPlan != null)
|
if (getTestPlan != null)
|
||||||
{
|
{
|
||||||
this.txtPlanCode.Text = getTestPlan.PlanCode;
|
this.txtPlanCode.Text = getTestPlan.PlanCode;
|
||||||
this.txtPlanName.Text = getTestPlan.PlanName;
|
this.txtPlanName.Text = getTestPlan.PlanName;
|
||||||
this.drpPlanMan.SelectedValue = getTestPlan.PlanManId;
|
this.PlanManName.Text =Person_PersonsService.GetPersonsNameById( getTestPlan.PlanManId);
|
||||||
|
this.PlanManId.Text = getTestPlan.PlanManId;
|
||||||
|
|
||||||
this.txtPlanDate.Text = string.Format("{0:yyyy-MM-dd}", getTestPlan.PlanDate);
|
this.txtPlanDate.Text = string.Format("{0:yyyy-MM-dd}", getTestPlan.PlanDate);
|
||||||
this.txtTestStartTime.Text = string.Format("{0:yyyy-MM-dd HH:mm:ss}", getTestPlan.TestStartTime);
|
this.txtTestStartTime.Text = string.Format("{0:yyyy-MM-dd HH:mm:ss}", getTestPlan.TestStartTime);
|
||||||
this.txtTestEndTime.Text = string.Format("{0:yyyy-MM-dd HH:mm:ss}", getTestPlan.TestEndTime);
|
this.txtTestEndTime.Text = string.Format("{0:yyyy-MM-dd HH:mm:ss}", getTestPlan.TestEndTime);
|
||||||
@@ -68,7 +70,8 @@ namespace FineUIPro.Web.PersonManage.Test
|
|||||||
{
|
{
|
||||||
this.txtPlanName.Text = DateTime.Now.Year.ToString() + "-" + DateTime.Now.Month.ToString("00") + "知识竞赛考试";
|
this.txtPlanName.Text = DateTime.Now.Year.ToString() + "-" + DateTime.Now.Month.ToString("00") + "知识竞赛考试";
|
||||||
this.txtPlanDate.Text = string.Format("{0:yyyy-MM-dd}", DateTime.Now);
|
this.txtPlanDate.Text = string.Format("{0:yyyy-MM-dd}", DateTime.Now);
|
||||||
this.drpPlanMan.SelectedValue = this.CurrUser.PersonId;
|
this.PlanManName.Text = this.CurrUser.PersonName;
|
||||||
|
this.PlanManId.Text = this.CurrUser.PersonId;
|
||||||
this.txtTestStartTime.Text = string.Format("{0:yyyy-MM-dd HH:mm:ss}", DateTime.Now.AddDays(1));
|
this.txtTestStartTime.Text = string.Format("{0:yyyy-MM-dd HH:mm:ss}", DateTime.Now.AddDays(1));
|
||||||
this.txtTestEndTime.Text = string.Format("{0:yyyy-MM-dd HH:mm:ss}", DateTime.Now.AddDays(2));
|
this.txtTestEndTime.Text = string.Format("{0:yyyy-MM-dd HH:mm:ss}", DateTime.Now.AddDays(2));
|
||||||
this.txtSValue.Text = "2";
|
this.txtSValue.Text = "2";
|
||||||
@@ -286,11 +289,9 @@ namespace FineUIPro.Web.PersonManage.Test
|
|||||||
SValue = Funs.GetNewInt(this.txtSValue.Text),
|
SValue = Funs.GetNewInt(this.txtSValue.Text),
|
||||||
MValue = Funs.GetNewInt(this.txtMValue.Text),
|
MValue = Funs.GetNewInt(this.txtMValue.Text),
|
||||||
JValue = Funs.GetNewInt(this.txtJValue.Text),
|
JValue = Funs.GetNewInt(this.txtJValue.Text),
|
||||||
|
PlanManId=this.PlanManId.Text,
|
||||||
};
|
};
|
||||||
if (this.drpPlanMan.SelectedValue != BLL.Const._Null)
|
|
||||||
{
|
|
||||||
newTestPlan.PlanManId = this.drpPlanMan.SelectedValue;
|
|
||||||
}
|
|
||||||
newTestPlan.States = Const.State_0;
|
newTestPlan.States = Const.State_0;
|
||||||
if (type == Const.BtnSubmit)
|
if (type == Const.BtnSubmit)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -7,10 +7,12 @@
|
|||||||
// </自动生成>
|
// </自动生成>
|
||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
|
|
||||||
namespace FineUIPro.Web.PersonManage.Test {
|
namespace FineUIPro.Web.PersonManage.Test
|
||||||
|
{
|
||||||
|
|
||||||
|
|
||||||
public partial class TestPlanEdit {
|
public partial class TestPlanEdit
|
||||||
|
{
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// form1 控件。
|
/// form1 控件。
|
||||||
@@ -112,13 +114,22 @@ namespace FineUIPro.Web.PersonManage.Test {
|
|||||||
protected global::FineUIPro.DatePicker txtPlanDate;
|
protected global::FineUIPro.DatePicker txtPlanDate;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// drpPlanMan 控件。
|
/// PlanManName 控件。
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <remarks>
|
/// <remarks>
|
||||||
/// 自动生成的字段。
|
/// 自动生成的字段。
|
||||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||||
/// </remarks>
|
/// </remarks>
|
||||||
protected global::FineUIPro.DropDownList drpPlanMan;
|
protected global::FineUIPro.TextBox PlanManName;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// PlanManId 控件。
|
||||||
|
/// </summary>
|
||||||
|
/// <remarks>
|
||||||
|
/// 自动生成的字段。
|
||||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||||
|
/// </remarks>
|
||||||
|
protected global::FineUIPro.TextBox PlanManId;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// txtSValue 控件。
|
/// txtSValue 控件。
|
||||||
|
|||||||
Reference in New Issue
Block a user