/// <summary> /// Добавление характеристики в заказ /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void NomenclatureFeatures_OnGridCommand(object sender, GridCommandEventArgs e) { var model = e.Value as IFeatureModel; if (model == null) { return; } var newOrderSpesific = new OrderSpecificationItemModel() { Guid = Guid.NewGuid(), Nomenclature = model.Nomenclature, Feature = model, Count = 1, Price = model.Price, }; AddInOrderSpecifics(newOrderSpesific); }
/// <summary> /// Добавление номенклатуры в заказ /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void Exposition_OnGridCommand(object sender, GridCommandEventArgs e) { var model = e.Value as IExpositionModel; if (model == null || model.Count <= 0) { return; } model.Count--; gcExposition.RefreshDataSource(); var newOrderSpesific = new OrderSpecificationItemModel() { Guid = Guid.NewGuid(), Nomenclature = model.Nomenclature, Feature = model.Feature, Count = 1, Price = model.Price, }; AddInOrderSpecifics(newOrderSpesific); }