Пример #1
0
        protected virtual void FillRefundItemStoreId(RefundItem item)
        {
            if (!Guid.TryParse(item.GetProperty <string>("StoreId"), out var storeId))
            {
                throw new StoreIdNotFoundException();
            }

            item.SetStoreId(storeId);
        }
Пример #2
0
        protected virtual void FillRefundItemStoreId(RefundItem item)
        {
            var storeId = item.GetProperty <Guid?>(nameof(RefundItem.StoreId));

            if (storeId is null)
            {
                throw new StoreIdNotFoundException();
            }

            item.SetStoreId(storeId.Value);
        }