Exemplo n.º 1
0
        public FeatureMasterViewModel(UserInformation userInformation)
        {
            this.FeatureMaster                = new FeatureMasterModel();
            _featureMasterbll                 = new FeatureMasterBll(userInformation);
            this.selectChangeComboCommand     = new DelegateCommand(this.SelectDataRow);
            this.selectChangeComboCommandOper = new DelegateCommand(this.SelectDataRowOper);
            this._deleteCommandChar           = new DelegateCommand <System.Windows.Controls.DataGrid>(this.DeleteChar);
            this.gridRowEndEditing            = new DelegateCommand <Object>(this.GridEditEnding);
            this.gridAddingNewItem            = new DelegateCommand(this.GridAddingNew);
            this._onAddCommand                = new DelegateCommand(this.Add);
            this._onEditViewCommand           = new DelegateCommand(this.Edit);
            this._onSaveCommand               = new DelegateCommand <DataView>(this.Save);
            this._onCloseCommand              = new DelegateCommand(this.Close);
            this.deleteCommand                = new DelegateCommand <DataRowView>(this.DeleteSubmitCommand);
            FeatureMaster.FeatureCode         = string.Empty;
            FeatureMaster.Feature             = string.Empty;
            FeatureMaster.OperationCode       = string.Empty;
            FeatureMaster.Operations          = string.Empty;

            SetdropDownItems();
            ButtonEnable                               = Visibility.Collapsed;
            ButtonVisibleOper                          = Visibility.Visible;
            FeatureMaster.FeatureCode                  = _featureMasterbll.GenerateFeatuerCode();
            FeatureMaster.OperationCodeDetails         = _featureMasterbll.GetOpertionMaster();
            FeatureMaster.CharacteristicsMasterDetails = _featureMasterbll.GetCharactersiticsMasterGrid(FeatureMaster.OperationCode, FeatureMaster.FeatureCode);
            GetRights();
            //   AddButtonIsEnable = true;
            setRights();
        }
Exemplo n.º 2
0
        public FeatureMasterViewModel()
        {
            this.FeatureMaster                = new FeatureMasterModel();
            _featureMasterbll                 = new FeatureMasterBll();
            this.selectChangeComboCommand     = new DelegateCommand(this.SelectDataRow);
            this.selectChangeComboCommandOper = new DelegateCommand(this.SelectDataRowOper);
            this._onAddCommand                = new DelegateCommand(this.Add);
            this._onEditViewCommand           = new DelegateCommand(this.Edit);
            this._onSaveCommand               = new DelegateCommand(this.Save);
            this._onCloseCommand              = new DelegateCommand(this.Close);

            ButtonEnable                       = Visibility.Collapsed;
            ButtonVisibleOper                  = Visibility.Visible;
            FeatureMaster.FeatureCode          = _featureMasterbll.GenerateFeatuerCode();
            FeatureMaster.OperationCodeDetails = _featureMasterbll.GetOpertionMaster();
            AddEnable  = false;
            EditEnable = true;
        }