Example #1
0
        public void AccountingPriceList_CantDeleteStoragesFromAutocreation()
        {
            try
            {
                var accountingPriceList = new AccountingPriceList("234", DateTime.Today.AddYears(1), DateTime.Today.AddYears(2), storage1, articleAccountingPriceCorrectList1, user);

                accountingPriceList.RemoveStorage(storage1);

                Assert.Fail("Исключения не было.");
            }
            catch (Exception ex)
            {
                Assert.AreEqual("Невозможно удалить место хранения из распространения реестра с основанием «По месту хранения».", ex.Message);
            }
        }
        public void DeleteStorage(AccountingPriceList accPriceList, Storage storage, IEnumerable <Storage> storageList, User user)
        {
            CheckPossibilityToRemoveStorage(accPriceList, user);

            accPriceList.RemoveStorage(storage);
        }