2026821
This commit is contained in:
@@ -0,0 +1,113 @@
|
||||
using System;
|
||||
using System.Data;
|
||||
using System.Configuration;
|
||||
using System.Collections;
|
||||
using System.Web;
|
||||
using System.Web.Security;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using System.Web.UI.WebControls.WebParts;
|
||||
using System.Web.UI.HtmlControls;
|
||||
using GThinking.N_MODEL.Page;
|
||||
using GThinking.N_WORKFLOW;
|
||||
using GThinking.N_MISPRO;
|
||||
using GThinking.N_MISPRO.Data;
|
||||
using GThinking.N_MISPRO.Utility;
|
||||
using System.Text;
|
||||
|
||||
|
||||
namespace GThinking.N_XLXSBJ
|
||||
{
|
||||
public partial class TZYZBJE_BSY1List : SingleGridBase
|
||||
{
|
||||
TZYZBJE_BSY1 entity = new TZYZBJE_BSY1();
|
||||
|
||||
#region Page事件继承
|
||||
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
this.UMID = 100860086;
|
||||
this.UMName = "按型号电压主芯截面范围报价数量区间调报价";
|
||||
this.CurMaster = Master;
|
||||
this.ModuleGV = grdContentGrid;
|
||||
this.CurEntity = entity;
|
||||
this.sURLTarget = "TZYZBJE_BSY1Info.aspx";
|
||||
this.PageWidth = 750;
|
||||
this.PageHeight = 600;
|
||||
|
||||
base.DataKeyNames = new string[] { "XLXSBJDYZZEBSY1_CPYT" };
|
||||
|
||||
this.Master.EnableQueryBtn = false;
|
||||
this.Master.EnableAttachBtn = false;
|
||||
|
||||
base.InitPage();
|
||||
|
||||
if (!IsPostBack)
|
||||
{
|
||||
Master_OnStandardQuery(null, null);
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region 模板事件继承
|
||||
|
||||
protected override void Master_OnStandardQuery(object sender, EventArgs e)
|
||||
{
|
||||
entity.EntityTable.QuerySelSql = GetQuerySelSQL().ToString();
|
||||
base.Master_OnStandardQuery(sender, e);
|
||||
entity.GridDataBind(grdContentGrid, tSession);
|
||||
}
|
||||
|
||||
protected override void moduleGV_RowDataBound(object sender, GridViewRowEventArgs e)
|
||||
{
|
||||
if (e.Row.RowType == DataControlRowType.DataRow)
|
||||
{
|
||||
LinkPageParam.AddString("XLXSBJDYZZEBSY1_CPYT", grdContentGrid.DataKeys[e.Row.RowIndex]["XLXSBJDYZZEBSY1_CPYT"].ToString().Trim());
|
||||
}
|
||||
base.moduleGV_RowDataBound(sender, e);
|
||||
}
|
||||
protected override void moduleGV_PageIndexChanging(object sender, GridViewPageEventArgs e)
|
||||
{
|
||||
entity.EntityTable.QuerySelSql = GetQuerySelSQL().ToString();
|
||||
grdContentGrid.SelectedIndex = -1;
|
||||
base.moduleGV_PageIndexChanging(sender, e);
|
||||
}
|
||||
|
||||
protected override void BeforeDelete(TDatabase db, ref bool ActionIsDone)
|
||||
{
|
||||
entity.Param.Add("XLXSBJDYZZEBSY1_CPYT", grdContentGrid.DataKeys[grdContentGrid.SelectedIndex]["XLXSBJDYZZEBSY1_CPYT"].ToString().Trim());
|
||||
base.BeforeDelete(db, ref ActionIsDone);
|
||||
}
|
||||
|
||||
protected override bool Master_AfterDeleteAction(object sender, EventArgs e)
|
||||
{
|
||||
if (!base.Master_AfterDeleteAction(sender, e)) { return false; }
|
||||
entity.EntityTable.QuerySelSql = GetQuerySelSQL().ToString();
|
||||
entity.GridDataBind(grdContentGrid, tSession);
|
||||
grdContentGrid.SelectedIndex = -1;
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
|
||||
protected override void AfterDelete(TDatabase db, ref bool ActionIsDone)
|
||||
{
|
||||
base.AfterDelete(db, ref ActionIsDone);
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region 私有函数
|
||||
private StringBuilder GetQuerySelSQL()
|
||||
{
|
||||
StringBuilder strSQL = new StringBuilder();
|
||||
strSQL.AppendLine(" select rtrim(XLXSBJDYZZEBSY1_CPYT)|| '|' || XLCPYT_CPYTMC as CPYT,XLXSBJDYZZEBSY1_CPYT, XLXSBJDYZZEBSY1_BZ, ");
|
||||
strSQL.AppendLine(" XLXSBJDYZZEBSY1_WHR, XLXSBJDYZZEBSY1_WHRID,XLXSBJDYZZEBSY1_WHSJ from XLXSBJDYZZEBSY1 ");
|
||||
strSQL.AppendLine(" left join XLCPYT on XLCPYT_CPYT = XLXSBJDYZZEBSY1_CPYT ");
|
||||
strSQL.AppendLine("where 1=1 ");
|
||||
strSQL.AppendLine(" order by XLXSBJDYZZEBSY1_CPYT desc ");
|
||||
return strSQL;
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user