protected void Page_Load(object sender, EventArgs e) { gridHelper = new GridHelperNew(gridWebGrid, DtSource); if (!this.IsPostBack) { // 初始化页面语言 this.InitPageLanguage(this.languageComponent1, false); this.UCWhereConditions1.InitUserControl(this.languageComponent1, this.DataProvider); this.UCGroupConditions1.InitUserControl(this.languageComponent1, this.DataProvider); this.UCDisplayConditions1.InitUserControl(this.languageComponent1, this.DataProvider); //this.OWCPivotTable1.LanguageComponent = this.languageComponent1; this.columnChart.Visible = false; this.lineChart.Visible = false; this.RefreshController1.Interval = ConfigSection.Current.DomainSetting.Interval; } //加载控件的值 LoadDisplayControls(); //根据是否选择车间设定一些控件的可见性 SetControlByFacCode(UCGroupConditions1.FacCodeChecked); this.gridWebGrid.Behaviors.RowSelectors.RowNumbering = false; this.gridWebGrid.Behaviors.Sorting.Enabled = false; }
protected void Page_Load(object sender, System.EventArgs e) { //this.pagerSizeSelector.Readonly = true; this.gridHelper = new GridHelperNew(this.gridWebGrid, this.DtSource); this.txtOQCLotQuery.Text = this.GetRequestParam("oqclot"); this._gridHelper = new GridHelperNew(this.gridWebGrid, this.DtSource); this._helper = new WebQueryHelperNew(null, this.cmdGridExport, this.gridWebGrid, this.pagerSizeSelector, this.pagerToolBar, this.languageComponent1, this.DtSource); this._helper.LoadGridDataSource += new EventHandler(_helper_LoadGridDataSource); this._helper.DomainObjectToGridRow += new EventHandler(_helper_DomainObjectToGridRow); this._helper.DomainObjectToExportRow += new EventHandler(_helper_DomainObjectToExportRow); this._helper.GetExportHeadText += new EventHandler(_helper_GetExportHeadText); //this.gridWebGrid.DisplayLayout.CellClickActionDefault = CellClickAction.NotSet; if (!this.IsPostBack) { // 初始化页面语言 this.InitPageLanguage(this.languageComponent1, false); this._initialWebGrid(); this._helper.Query(sender); } }
//protected GridHelper gridHelper = null; protected void Page_Load(object sender, System.EventArgs e) { gridHelper = new GridHelperNew(this.gridWebGrid, DtSource); //this.gridWebGrid.DisplayLayout.CellClickActionDefault = CellClickAction.NotSet; if (!this.IsPostBack) { // 初始化页面语言 this.InitPageLanguage(this.languageComponent1, false); this.dateStartDateQuery.Text = FormatHelper.ToDateString(FormatHelper.TODateInt(System.DateTime.Now)); this.dateEndDateQuery.Text = FormatHelper.ToDateString(FormatHelper.TODateInt(System.DateTime.Now)); this.dateStartTimeQuery.Text = FormatHelper.ToTimeString(FormatHelper.TOTimeInt(System.DateTime.Now)); this.dateEndTimeQuery.Text = FormatHelper.ToTimeString(235959); this._initialWebGrid(); } if (!this.IsPostBack) { //如果接受到其它页面的参数直接执行查询 if (this.GetRequestParam("post") != null && this.GetRequestParam("post") != string.Empty) { //日期 this.dateStartDateQuery.Text = this.GetRequestParam("shiftday"); this.dateStartTimeQuery.Text = this.GetRequestParam("shiftday"); this._doQuery(); } } }
protected void Page_Load(object sender, System.EventArgs e) { //this.pagerSizeSelector.Readonly = true; this.gridHelper = new GridHelperNew(this.gridWebGrid, this.DtSource); this.txtKeypartsQuery.Text = this.GetRequestParam("Keyparts"); this.txtKeyparts.Text = this.GetRequestParam("MCARD"); this._gridHelper = new GridHelperNew(this.gridWebGrid, this.DtSource); this._helper = new WebQueryHelperNew(null, this.cmdGridExport, this.gridWebGrid, this.pagerSizeSelector, this.pagerToolBar, this.languageComponent1, this.DtSource); this._helper.LoadGridDataSource += new EventHandler(_helper_LoadGridDataSource); this._helper.DomainObjectToGridRow += new EventHandler(_helper_DomainObjectToGridRow); this._helper.DomainObjectToExportRow += new EventHandler(_helper_DomainObjectToExportRow); this._helper.GetExportHeadText += new EventHandler(_helper_GetExportHeadText); if (!this.IsPostBack) { // 初始化页面语言 this.InitPageLanguage(this.languageComponent1, false); this._initialWebGrid(); this._helper.Query(sender); } }
public ImportDateEngine(IDomainDataProvider dataProvider, LanguageComponent languageComponent1, string importType, DataTable table, string userCode, ArrayList importGridRow, GridHelperNew _gridHelper) { _DataProvider = dataProvider; _LanguageComponent1 = languageComponent1; _ImportType = importType; _ImportDataTable = table; _UserCode = userCode; _ImportGridRow = importGridRow; this.gridHelper = _gridHelper; }
protected void Page_Load(object sender, System.EventArgs e) { gridHelper = new GridHelperNew(gridWebGrid, DtSource); if (!IsPostBack) { // 初始化页面语言 this.InitPageLanguage(this.languageComponent1, false); this.txtDctCommandQuery.Text = this.GetRequestParam("dctCode"); } }
protected void Page_Load(object sender, System.EventArgs e) { this.gridHelper = new GridHelperNew(this.gridWebGrid, this.DtSource); this._gridHelper = new GridHelperNew(this.gridWebGrid, this.DtSource); this._helper = new WebQueryHelperNew(this.cmdQuery, this.cmdGridExport, this.gridWebGrid, this.pagerSizeSelector, this.pagerToolBar, this.languageComponent1, this.DtSource); this._helper.LoadGridDataSource += new EventHandler(_helper_LoadGridDataSource); this._helper.DomainObjectToGridRow += new EventHandler(_helper_DomainObjectToGridRow); this._helper.DomainObjectToExportRow += new EventHandler(_helper_DomainObjectToExportRow); this._helper.GetExportHeadText += new EventHandler(_helper_GetExportHeadText); //this._helper.GridCellClick += new EventHandler(_helper_GridCellClick); FormatHelper.SetSNRangeValue(txtStartSnQuery, txtEndSnQuery); if (!this.IsPostBack) { // 初始化页面语言 this.InitPageLanguage(this.languageComponent1, false); this._initialWebGrid(); this.drpCrewCodeQuery_Load(); bool loaddata = false; txtOQCBeginDate.Text = FormatHelper.ToDateString(FormatHelper.TODateInt(DateTime.Today)); txtOQCEndDate.Text = FormatHelper.ToDateString(FormatHelper.TODateInt(DateTime.Today)); //this.txtOQCBeginTime.Text = FormatHelper.ToTimeString(0); //this.txtOQCEndTime.Text = FormatHelper.ToTimeString(235959); if (Page.Request["reworkrcard"] != null && Page.Request["reworkrcard"] != string.Empty) { this.txtStartSnQuery.Text = Page.Request["reworkrcard"]; this.txtEndSnQuery.Text = this.txtStartSnQuery.Text; loaddata = true; } if (Page.Request["reworklotno"] != null && Page.Request["reworklotno"] != string.Empty) { this.txtOQCLotQuery.Text = Page.Request["reworklotno"]; loaddata = true; } if (loaddata) { DateTime begin = new DateTime(DateTime.Now.Year - 2, DateTime.Now.Month, DateTime.Now.Day); this.txtOQCBeginDate.Text = FormatHelper.ToDateString(FormatHelper.TODateInt(begin)); this._helper.Query(null); } } }
protected void Page_Load(object sender, EventArgs e) { gridHelper = new GridHelperNew(gridWebGrid, DtSource); if (!this.IsPostBack) { // 初始化页面语言 this.InitPageLanguage(this.languageComponent1, false); this.UCWhereConditions1.InitUserControl(this.languageComponent1, this.DataProvider); this.UCGroupConditions1.InitUserControl(this.languageComponent1, this.DataProvider); this.UCDisplayConditions1.InitUserControl(this.languageComponent1, this.DataProvider); this.RefreshController1.Interval = ConfigSection.Current.DomainSetting.Interval; } LoadDisplayControls(); this.gridWebGrid.Behaviors.RowSelectors.RowNumbering = false; this.gridWebGrid.Behaviors.Sorting.Enabled = false; }
protected void Page_Load(object sender, System.EventArgs e) { this.gridHelper = new GridHelperNew(this.gridWebGrid, this.DtSource); this._gridHelper = new GridHelperNew(this.gridWebGrid, this.DtSource); if (!this.IsPostBack) { // 初始化页面语言 this.InitPageLanguage(this.languageComponent1, false); this._initialWebGrid(); } this._helper = new WebQueryHelperNew(this.cmdQuery, this.cmdGridExport, this.gridWebGrid, this.pagerSizeSelector, this.pagerToolBar, this.languageComponent1, this.DtSource); this._helper.LoadGridDataSource += new EventHandler(_helper_LoadGridDataSource); this._helper.DomainObjectToGridRow += new EventHandler(_helper_DomainObjectToGridRow); this._helper.DomainObjectToExportRow += new EventHandler(_helper_DomainObjectToExportRow); this._helper.GetExportHeadText += new EventHandler(_helper_GetExportHeadText); }
//该方法用于Grid显示的列,如果不需要显示的列,隐藏以来就行了,下面以SMT防呆工序为例子,具体导出的页面参考FOperationMP public virtual void CreateOperationListColumns(GridHelperNew gridHelper) { gridHelper.AddCheckBoxColumn("OP_componentloading", "上料工序", false, null); gridHelper.AddCheckBoxColumn("OP_testing", "测试工序", false, null); gridHelper.AddCheckBoxColumn("OP_idtranslate", "序号转换工序", false, null); gridHelper.AddCheckBoxColumn("OP_packing", "包装工序", false, null); gridHelper.AddCheckBoxColumn("OP_oqc", "OQC工序", false, null); gridHelper.AddCheckBoxColumn("OP_ts", "维修工序", false, null); gridHelper.AddCheckBoxColumn("OP_outside_route", "线外工序", false, null); gridHelper.AddCheckBoxColumn("OP_smt", "SMT防呆工序", false, null); gridHelper.AddCheckBoxColumn("OP_spc", "SPC工序", false, null); gridHelper.AddCheckBoxColumn("OP_deduct", "扣料工序", false, null); gridHelper.AddCheckBoxColumn("OP_midistoutput", "中间产量工序", false, null); gridHelper.AddCheckBoxColumn("OP_midistinput", "中间投入工序", false, null); gridHelper.AddCheckBoxColumn("OP_ComponentDown", "下料工序", false, null); gridHelper.AddCheckBoxColumn("OP_BurnIn", "Burn In工序", false, null); gridHelper.AddCheckBoxColumn("OP_BurnOut", "Burn Out工序", false, null); gridHelper.AddCheckBoxColumn("OP_Offline", "下线工序", false, null); gridHelper.Grid.Columns.FromKey("OP_smt").Hidden = true; }
//protected GridHelper gridHelper = null; protected void Page_Load(object sender, System.EventArgs e) { gridHelper = new GridHelperNew(this.gridWebGrid, this.DtSource); this._helper = new WebQueryHelperNew(this.cmdQuery, this.cmdGridExport, this.gridWebGrid, this.pagerSizeSelector, this.pagerToolBar, this.languageComponent1, DtSource); this._helper.LoadGridDataSource += new EventHandler(_helper_LoadGridDataSource); this._helper.DomainObjectToGridRow += new EventHandler(_helper_DomainObjectToGridRow); this._helper.DomainObjectToExportRow += new EventHandler(_helper_DomainObjectToExportRow); this._helper.GetExportHeadText += new EventHandler(_helper_GetExportHeadText); //this._helper.GridCellClick += new EventHandler(_helper_GridCellClick); FormatHelper.SetSNRangeValue(txtStartSnQuery, txtEndSnQuery); FormatHelper.SetSNRangeValue(txtStartKeypartsQuery, txtEndKeypartsQuery); if (!this.IsPostBack) { // 初始化页面语言 this.InitPageLanguage(this.languageComponent1, false); this._initialWebGrid(); } }
protected void cmdCheck_ServerClick(object sender, EventArgs e) { if (_DocumentFacade == null) { _DocumentFacade = new DocumentFacade(base.DataProvider); } if (gridHelper == null) { gridHelper = new GridHelperNew(this.gridWebGrid, this.DtSource); } try { if (!_DocumentFacade.GetDocDirRight(int.Parse(this.txtDocDirQuery.Text.Trim()), this.GetUserCode(), "CHECK")) { WebInfoPublish.PublishInfo(this, "$Error_No_CheckFile_Right", this.languageComponent1); return; } this.DataProvider.BeginTransaction(); foreach (object obj in gridHelper.GetCheckedRows()) { int serial = int.Parse((obj as GridRecord).Items.FindItemByKey("DOCSERIAL").Value.ToString()); Doc doc = (Doc)_DocumentFacade.GetDOC(serial); doc.Checkedstatus = "Y"; _DocumentFacade.UpdateDOC(doc); } this.DataProvider.CommitTransaction(); this.gridHelper.RefreshData(); WebInfoPublish.PublishInfo(this, "$Success_Check", this.languageComponent1); } catch (Exception ex) { this.DataProvider.RollbackTransaction(); WebInfoPublish.PublishInfo(this, "$Error_Check_Exception", this.languageComponent1); } }
protected void Page_Load(object sender, System.EventArgs e) { this.gridHelper = new GridHelperNew(this.gridWebGrid, this.DtSource); this._gridHelper = new GridHelperNew(this.gridWebGrid, this.DtSource); this._helper = new WebQueryHelperNew(this.cmdQuery, this.cmdGridExport, this.gridWebGrid, this.pagerSizeSelector, this.pagerToolBar, this.languageComponent1, this.DtSource); this._helper.LoadGridDataSource += new EventHandler(_helper_LoadGridDataSource); this._helper.DomainObjectToGridRow += new EventHandler(_helper_DomainObjectToGridRow); this._helper.DomainObjectToExportRow += new EventHandler(_helper_DomainObjectToExportRow); this._helper.GetExportHeadText += new EventHandler(_helper_GetExportHeadText); //this._helper.GridCellClick +=new EventHandler(_helper_GridCellClick); if (!this.IsPostBack) { // 初始化页面语言 this.InitPageLanguage(this.languageComponent1, false); this._initialWebGrid(); this.dateStartDateQuery.Text = FormatHelper.ToDateString(FormatHelper.TODateInt(System.DateTime.Now)); this.dateEndDateQuery.Text = this.dateStartDateQuery.Text; } }
protected void Page_Load(object sender, System.EventArgs e) { this.gridHelper = new GridHelperNew(this.gridWebGrid, this.DtSource); this._gridHelper = new GridHelperNew(this.gridWebGrid, this.DtSource); if (!IsPostBack) { // 初始化页面语言 this.InitPageLanguage(this.languageComponent1, false); this._initialWebGrid(); this.txtDateFrom.Text = FormatHelper.ToDateString(FormatHelper.TODateInt(DateTime.Today)); this.txtDateTo.Text = FormatHelper.ToDateString(FormatHelper.TODateInt(DateTime.Today)); } this._helper = new WebQueryHelperNew(this.cmdQuery, this.cmdGridExport, this.gridWebGrid, this.pagerSizeSelector, this.pagerToolBar, this.languageComponent1, this.DtSource); this._helper.LoadGridDataSource += new EventHandler(_helper_LoadGridDataSource); this._helper.DomainObjectToGridRow += new EventHandler(_helper_DomainObjectToGridRow); this._helper.DomainObjectToExportRow += new EventHandler(_helper_DomainObjectToExportRow); this._helper.GetExportHeadText += new EventHandler(_helper_GetExportHeadText); FormatHelper.SetSNRangeValue(txtStartSnQuery, txtEndSnQuery); this.chbFrmDate.Visible = false; }