Exemplo n.º 1
0
 protected override void Nested_PrepareForCreation()
 {
     _current = null;
     layoutControl1.Visible = true;
     //commandBar1.CustomGUI_SetInterfaceState(WIN.SCHEDULING_APP.GUI.Utility.GUIState.Creazione);
     //commandBar1.Custom_SetFunctionName("Creazione nuova causale");
     commandBar1.Custom_SetIdentifier("");
 }
Exemplo n.º 2
0
        private void DoRowDoubleClick(GridView view, Point pt)
        {
            GridHitInfo info = view.CalcHitInfo(pt);

            if (info.InRowCell)
            {
                WIN.SCHEDULING_APPLICATION.DOMAIN.Booking.BookingType label = view.GetRow(view.FocusedRowHandle) as WIN.SCHEDULING_APPLICATION.DOMAIN.Booking.BookingType;
                SetSelectedId(label);
            }
        }
Exemplo n.º 3
0
        //protected override void Nested_PostLoadingActions()
        //{
        //    commandBar1.Custom_SetFunctionName(string.Format("Visualizzazione causale: {0}", _current.Descrizione));
        //    commandBar1.CustomGUI_SetInterfaceState(GUIState.Visualizzazione);

        //}
        #endregion

        #region Salvataggio

        public override void Nested_InsertData()
        {
            _current               = new WIN.SCHEDULING_APPLICATION.DOMAIN.Booking.BookingType();
            _current.CreatoDa      = SecurityManager.Instance.CurrentUser.Username;
            _current.DataCreazione = DateTime.Now;

            SaveOrUpdate();

            m_IdShowedObject = _current.Id;
        }
Exemplo n.º 4
0
        protected override void Nested_LoadDataFromDataSource()
        {
            BookingTypeHandler h = new BookingTypeHandler();

            _current = h.GetElementById(m_IdShowedObject.ToString()) as WIN.SCHEDULING_APPLICATION.DOMAIN.Booking.BookingType;

            if (_current == null)
            {
                throw new Exception("Elemento non trovato");
            }
        }
Exemplo n.º 5
0
        private void cmdOk_Click(object sender, EventArgs e)
        {
            _id = -1;

            if (gridView1.SelectedRowsCount != 1)
            {
                XtraMessageBox.Show("Selezionare almeno un tipo prenotazione!", "Informazione", MessageBoxButtons.OK, MessageBoxIcon.Information);
                return;
            }

            WIN.SCHEDULING_APPLICATION.DOMAIN.Booking.BookingType label = gridView1.GetRow(gridView1.FocusedRowHandle) as WIN.SCHEDULING_APPLICATION.DOMAIN.Booking.BookingType;
            SetSelectedId(label);
        }
Exemplo n.º 6
0
 private void SetSelectedId(WIN.SCHEDULING_APPLICATION.DOMAIN.Booking.BookingType label)
 {
     if (label != null)
     {
         _id = label.Id;
         this.DialogResult = DialogResult.OK;
         this.Close();
     }
     else
     {
         XtraMessageBox.Show("Selezionare un tipo prestazione!", "Informazione", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
     }
 }