コード例 #1
0
        public void Delete(ExcludeViewModel model)
        {
            var entity = model.ToEntity();

            this._ExcludesRepository.Delete(entity);

            #region Commit Changes
            this._unitOfWork.Commit();
            #endregion
        }
コード例 #2
0
        public ExcludeViewModel Add(ExcludeViewModel model)
        {
            this.ThrowExceptionIfExist(model);

            var entity = model.ToEntity();

            entity = this._ExcludesRepository.Add(entity);

            #region Commit Changes
            this._unitOfWork.Commit();
            #endregion

            model = entity.ToModel();
            return(model);
        }