public UCWeekTimeRecording() { InitializeComponent(); _Context_ChangeContext = new ChangedContext(_context_ChangedContext); Disposed += new EventHandler(UCWeekTimeRecording_Disposed); GridViewRecording.KeyDown += new KeyEventHandler(View_KeyDown); ApplyAppearanceNoWrap(gbcSunday); ApplyAppearanceNoWrap(gbcMonday); ApplyAppearanceNoWrap(gbcTuesday); ApplyAppearanceNoWrap(gbcWednesday); ApplyAppearanceNoWrap(gbcThursday); ApplyAppearanceNoWrap(gbcFriday); ApplyAppearanceNoWrap(gbcSaturday); ApplyAppearanceWrap(band_ContractWorkingHours); //ApplyAppearanceWrap(band_Employee ); //ApplyAppearanceWrap(band_HWGR); ApplyAppearanceWrap(band_EmployeeBalanceHours ); ApplyAppearanceWrap(band_PlusMinusHours ); ApplyAppearanceWrap(band_SummOfAdditionalCharges); foreach (BandedGridColumn gc in GridViewRecording.Columns) { if (gc != gc_HWGR && gc != gc_Employee) { gc.OptionsColumn.AllowMove = false; gc.AppearanceHeader.TextOptions.HAlignment = DevExpress.Utils.HorzAlignment.Center; gc.AppearanceHeader.TextOptions.VAlignment = DevExpress.Utils.VertAlignment.Center; gc.AppearanceCell.TextOptions.HAlignment = DevExpress.Utils.HorzAlignment.Center; gc.AppearanceCell.TextOptions.VAlignment = DevExpress.Utils.VertAlignment.Center; } if (gc.SummaryItem != null) _summaryTocolumn[gc.SummaryItem ] = gc; } BuildIndex(); arr[0] = gbcSunday; arr[1] = gbcMonday; arr[2] = gbcTuesday; arr[3] = gbcWednesday; arr[4] = gbcThursday; arr[5] = gbcFriday; arr[6] = gbcSaturday; deMonday.Properties.MinValue = DateTimeSql.SmallDatetimeMin; deMonday.Properties.MaxValue = DateTimeHelper.GetSunday (DateTime.Today ); deMonday.DateTime = DateTimeHelper.GetMonday(DateTime.Today); }
public UCDayTimeRecording() { InitializeComponent(); if (!IsDesignMode) { BuildFixedColumnDiction(); BuildColumns(); gridControl.DataSource = _rowList; _Context_ChangeContext = new ChangedContext(_context_ChangedContext); } Disposed += new EventHandler(UCDayTimeRecording_Disposed); deDate.Properties.MinValue = DateTimeSql.SmallDatetimeMin; deDate.Properties.MaxValue = DateTime.Today; }