Пример #1
0
        public Offer GetOfferDefaultsWithQt()
        {
            Offer offer = new Offer(1, "1299659801", GetSupplierTenderQuantityTables(), 1, false);

            offer.Tender = new TenderDefault().GetGeneralTender();
            offer.Tender.UpdateTenderStatus(Enums.TenderStatus.OffersOppenedConfirmed);
            offer.Tender.UpdateTenderDates(DateTime.Now.Date.AddDays(1), DateTime.Now.Date.AddDays(2), DateTime.Now.Date.AddDays(3), DateTime.Now.Date.AddDays(-1), null, null, false, null, 1, "building name", "Floar number", "Department Number", null);
            offer.AddRegisteredCombinedSupplier(new OfferSolidarity("1299659801", Enums.SupplierSolidarityStatus.Approved, Enums.UnRegisteredSuppliersInvitationType.SolidarityLeader));
            offer.AddAttachment(new SupplierOriginalAttachment("name", "1"));
            offer.UpdateTechnicianReportAttachments(new List <TechnicianReportAttachment>()
            {
                new TechnicianReportAttachment("name", "1", (int)Enums.AttachmentType.TechnicianReport)
            });
            return(offer);
        }
Пример #2
0
        public void Should_AddAttachment_Second()
        {
            Offer offer = new Offer(tenderId, commericalRegisterNo, new List <SupplierTenderQuantityTable> {
                new SupplierTenderQuantityTable()
                {
                    Id = 1, QuantitiyItemsJson = new SupplierTenderQuantityTableItemJson(new List <SupplierTenderQuantityTableItem>()
                    {
                        new SupplierTenderQuantityTableItem()
                        {
                            Id = 1
                        }
                    })
                }
            }, offerPresentationWayid);

            offer.AddAttachment(new SupplierTechnicalProposalAttachment()
            {
            });
            Assert.NotEmpty(offer.Attachment);
        }
Пример #3
0
        public void Should_DeleteAttachment()
        {
            Offer offer = new Offer(tenderId, commericalRegisterNo, new List <SupplierTenderQuantityTable> {
                new SupplierTenderQuantityTable()
                {
                    Id = 1, QuantitiyItemsJson = new SupplierTenderQuantityTableItemJson(new List <SupplierTenderQuantityTableItem>()
                    {
                        new SupplierTenderQuantityTableItem()
                        {
                            Id = 1
                        }
                    })
                }
            }, offerPresentationWayid);

            offer.AddAttachment(new List <SupplierAttachment>()
            {
                new SupplierTechnicalProposalAttachment()
                {
                }
            });
            offer.DeleteAttachment();
            Assert.Equal(ObjectState.Deleted, offer.Attachment[0].State);
        }