예제 #1
0
        private void UC_TestLogAsyn_Load(object sender, EventArgs e)
        {
            gridhelper = new GridControlHelper(this.gridView1, this.gridControl1);

            builder = new TB_TechniqueLogBuilder();
            adapter = new TB_TechniqueLogAdapter();


            adapter.Initial(builder);
            onIntial();
        }
예제 #2
0
        public void onCreateComponet()
        {
            builder = new TB_TechniqueLogBuilder();
            adapter = new TB_TechniqueLogAdapter();

            adapter.Initial(builder);
            adapter.NotifyCreateNewResultDataTable();

            gridHelper = new GridControlHelper(this.gridView1, this.gridControl1);

            gridHelper.GridControl.DataSource = adapter.ResultTable;

            //gridHelper.DisplayNewInputLine();
            gridHelper.AddNewRowInputCallBack(this);
            gridHelper.SetColMaxWidth(builder.Op_Delete, 80);
            gridHelper.SetColunmOption(builder.Date, false, false);
            gridHelper.SetColunmOption(builder.ID, false, false);
            gridHelper.SetColunmOption(builder.Op_Edit, false, false);
            gridHelper.SetCellResposity(builder.MissionID, repo_search_TechMission);
            gridHelper.SetCellResposity(builder.IsNeedTidy, repo_cke_Tidy);

            controller = new TechniqueLogController();
        }
예제 #3
0
        public void onCreateComponet()
        {
            builder_Mission = new TB_TechniqueMissionStateBuilder();
            adapter_Mission = new TB_TechniqueMissionStateAdapter();
            adapter_Mission.Initial(builder_Mission);
            gridHelper_Mission = new GridControlHelper(this.gridView1, this.gridControl1);

            adapter_Log = new TB_TechniqueLogAdapter();
            builder_Log = new TB_TechniqueLogBuilder();
            adapter_Log.Initial(builder_Log);

            this.gridControl2.DataSource = builder_Log.CreateDataTable();

            GridBand band_Date = new GridBand()
            {
                Caption = "日期"
            };
            GridBand band_Info = new GridBand()
            {
                Caption = "信息"
            };
            GridBand band_Op = new GridBand()
            {
                Caption = "操作"
            };
            GridBand band_ID = new GridBand()
            {
                Caption = "ID", Visible = false
            };

            this.advBandedGridView1.Bands.Clear();
            this.advBandedGridView1.Bands.AddRange(new GridBand[] { band_ID, band_Date, band_Info, band_Op });


            BandedGridColumn col_Date = new BandedGridColumn {
                FieldName = builder_Log.Date, Visible = true
            };
            BandedGridColumn col_Context = new BandedGridColumn {
                FieldName = builder_Log.Context, Visible = true
            };
            BandedGridColumn col_Url = new BandedGridColumn {
                FieldName = builder_Log.LogUrl, Visible = true
            };
            BandedGridColumn col_OpDelete = new BandedGridColumn {
                FieldName = builder_Log.Op_Delete, Visible = true
            };
            BandedGridColumn col_OpEdit = new BandedGridColumn {
                FieldName = builder_Log.Op_Edit, Visible = true
            };
            BandedGridColumn col_ID = new BandedGridColumn {
                FieldName = builder_Log.ID, Visible = false
            };

            UpdateColumnOption(col_Date, band_Date, false, true, 0);
            UpdateColumnOption(col_Context, band_Info, false, false, 0);
            UpdateColumnOption(col_Url, band_Info, false, false, 1);
            UpdateColumnOption(col_OpDelete, band_Op, false, true, 0);
            UpdateColumnOption(col_OpEdit, band_Op, false, true, 1);
            UpdateColumnOption(col_ID, band_ID, false, true, 0);

            advBandedGridView1.OptionsView.ColumnAutoWidth = true;
            advBandedGridView1.OptionsView.ShowBands       = false;
            advBandedGridView1.RowHeight = 35;
            advBandedGridView1.OptionsView.ShowColumnHeaders = false;
            band_Date.OptionsBand.FixedWidth = true;
            band_Op.OptionsBand.FixedWidth   = true;

            this.advBandedGridView1.Columns[builder_Log.Op_Delete].ColumnEdit = repo_HLE_delete;
            this.advBandedGridView1.Columns[builder_Log.Op_Delete].OptionsColumn.AllowEdit = true;

            this.advBandedGridView1.Columns[builder_Log.LogUrl].ColumnEdit = repo_HLE_gotoURL;
            this.advBandedGridView1.Columns[builder_Log.LogUrl].OptionsColumn.AllowEdit = true;

            this.advBandedGridView1.Columns[builder_Log.Op_Edit].ColumnEdit = repo_HLE_edit;
            this.advBandedGridView1.Columns[builder_Log.Op_Edit].OptionsColumn.AllowEdit = true;
        }