Exemplo n.º 1
0
        public void WriteRenta(int rentaId, string qrEncoded)
        {
            var qr    = EreminQrService.GetPayload(qrEncoded);
            var renta = Get <Renta>(p => p.Id == rentaId && p.HasQRWrite && string.IsNullOrEmpty(p.QRRecorded), r => r.Sku.Nomenklatura.Specialisation.ProductType);

            if (renta == null)
            {
                throw new BillingNotFoundException($"offer {rentaId} записать на qr невозможно");
            }
            WriteRenta(renta, qr);
            SaveContext();
        }