public IHttpActionResult GetQuotationValidity(int QuotationShipmentId) { FrayteResult result = new FrayteResult(); result = new QuotationRepository().QuotationValidity(QuotationShipmentId); return(Ok(result)); }
public IHttpActionResult RemoveQuotation(int QuotationShipmentId) { FrayteResult result = new FrayteResult(); result = new QuotationRepository().DeleteQuotation(QuotationShipmentId); return(Ok(result)); }
public AgencyViewBLL() { AgencyRepository = new AgencyRepository(); AgencyContractRepository = new AgencyContractRepository(); ContractRepository = new ContractRepository(); QuotationRepository = new QuotationRepository(); }
public FrayteManifestName GetQuotation(int QuotationShipmentId, string CustomerName, string FromPostCode, string ToPostCode, int CreatedBy) { FrayteManifestName result = new FrayteManifestName(); var item = new QuotationRepository().GetQuotationDetail(QuotationShipmentId, CustomerName); var TimeZone = new QuotationRepository().GetUserTimeZone(CreatedBy); var UserType = UtilityRepository.GetUserType(CreatedBy); var DateObj = DateTime.UtcNow; TimeZoneInfo TimeZoneInformation = TimeZoneInfo.FindSystemTimeZoneById(TimeZone.Name); var remoteTime = TimeZoneInfo.ConvertTime(DateObj, TimeZoneInformation).ToString("hh:mm:ss tt"); if (item != null) { int CartoonQty = new QuotationRepository().SumofCartoonQty(item.QuotationShipmentId); decimal Volume = new QuotationRepository().TotalVolume(item.QuotationShipmentId, item.PackageCalculationType); if (item.OperationZoneId == 1) { result = HKQuoteReport(item, Volume, CartoonQty, TimeZoneInformation, remoteTime); } else if (item.OperationZoneId == 2) { result = UKQuoteReport(item, Volume, CartoonQty, TimeZoneInformation, remoteTime, UserType, CreatedBy); } } return(result); }
public void Dispose() { if (QuotationRepository != null) { QuotationRepository.Dispose(); QuotationRepository = null; } }
public AgencyViewBLL() { AgencyRepository = new AgencyRepository(); AgencyContractRepository = new AgencyContractRepository(); ContractRepository = new ContractRepository(); QuotationRepository = new QuotationRepository(); AgencyContactRepository = new AgencyContactRepository(); CruiseRepository = new CruiseRepository(); ActivityRepository = new ActivityRepository(); AgencyNotesRepository = new AgencyNotesRepository(); RoleRepository = new RoleRepository(); }
public IHttpActionResult GetQuotationShipments(int operationZoneId, int UserId, int CustomerId) { try { List <FrayteQuotationShipment> list = new List <FrayteQuotationShipment>(); list = new QuotationRepository().GetQuotationShipments(operationZoneId, UserId, CustomerId); return(Ok(list)); } catch (Exception ex) { return(BadRequest()); } }
public IHttpActionResult EditQuotation(FrayteQuotationShipment quotationDetail) { try { FrayteQuotationResult result = new FrayteQuotationResult(); result = new QuotationRepository().EditQuotation(quotationDetail); return(Ok(result)); } catch (Exception ex) { return(BadRequest()); } }
public IHttpActionResult QuotationServices(DirectBookingFindService serviceRequest) { try { List <DirectBookingService> lstDirectBookingServices = new List <DirectBookingService>(); lstDirectBookingServices = new QuotationRepository().GetServices(serviceRequest); return(Ok(lstDirectBookingServices)); } catch (Exception ex) { return(InternalServerError(ex)); } }
public void Dispose() { if (AgencyRepository != null) { AgencyRepository.Dispose(); AgencyRepository = null; } if (AgencyContractRepository != null) { AgencyContractRepository.Dispose(); AgencyContractRepository = null; } if (ContractRepository != null) { ContractRepository.Dispose(); ContractRepository = null; } if (QuotationRepository != null) { QuotationRepository.Dispose(); QuotationRepository = null; } if (AgencyContactRepository != null) { AgencyContactRepository.Dispose(); AgencyContactRepository = null; } if (CruiseRepository != null) { CruiseRepository.Dispose(); CruiseRepository = null; } if (ActivityRepository != null) { ActivityRepository.Dispose(); ActivityRepository = null; } if (AgencyNotesRepository != null) { AgencyNotesRepository.Dispose(); AgencyNotesRepository = null; } if (RoleRepository != null) { RoleRepository.Dispose(); RoleRepository = null; } }
public void DatabaseConnection() { try { //act IQuotationRepository repository = new QuotationRepository(DB); // arrange List <QuotationDataView> quotations = repository.Get().ToList(); //assert Assert.IsTrue(quotations.Any(), "No elements in sequence"); } catch (Exception ex) { Assert.Fail(ex.Message); } }
public UnitOfWork(ApplicationDbContext context) { _context = context; StockItems = new StockRepository(_context); Invoices = new InvoiceRepository(_context); JobCards = new JobCardRepository(_context); JobStatuses = new JobStatusRepository(_context); Suppliers = new SupplierRepository(_context); JobTypes = new JobTypeRepository(_context); Customers = new CustomerRepository(_context); ServiceContracts = new ServiceContractRepository(_context); MaintenanceContracts = new MaintenanceContractRepository(_context); Areas = new AreaRepository(_context); PurchaseOrders = new PurchaseOrderRepository(_context); PurchaseOrderItems = new PurchaseOrderItemRepository(_context); ApplicationUserSignatures = new ApplicationUserSignatureRepository(_context); CustomerSignatures = new CustomerSignatureRepository(_context); JobStatusHistory = new JobStatusHistoryRepository(_context); Quotes = new QuotationRepository(_context); StockItemQuantities = new StockItemQuantityRepository(_context); }
public void Dispose() { if (AgencyRepository != null) { AgencyRepository.Dispose(); AgencyRepository = null; } if (AgencyContractRepository != null) { AgencyContractRepository.Dispose(); AgencyContractRepository = null; } if (ContractRepository != null) { ContractRepository.Dispose(); ContractRepository = null; } if (QuotationRepository != null) { QuotationRepository.Dispose(); QuotationRepository = null; } }
public QuotationController() { corepo = new QuotationRepository(); }
public FrayteSalesRepresentiveEmail GetSalesRepresentiveEmail(int UserId, int RoleId) { FrayteSalesRepresentiveEmail email = new QuotationRepository().SalesRepresentiveEmail(UserId, RoleId); return(email); }
public IHttpActionResult GetCustomerAddressType(int CustomerId) { string address = new QuotationRepository().CustomerAddressType(CustomerId); return(Ok(address)); }
public Quotation QuotationGetById(int quotationId) { return(QuotationRepository.QuotationGetById(quotationId)); }
public IList <Quotation> QuotationGetAll() { return(QuotationRepository.QuotationGetAll()); }
public IHttpActionResult GetTNTSupplemetoryInformation(int LogisticServiceId) { var info = new QuotationRepository().GetTNTInforamtion(LogisticServiceId); return(Ok(info)); }
public QuotationManagementBLL() { QuotationRepository = new QuotationRepository(); }
public void QuotationSaveOrUpdate(Quotation quotation) { QuotationRepository.SaveOrUpdate(quotation); }
public QuotationCreateBLL() { QuotationRepository = new QuotationRepository(); QuotationPriceRepository = new QuotationPriceRepository(); }
public QuotationViewBLL() { QuotationRepository = new QuotationRepository(); }
public IHttpActionResult GetCustomerLogisticServices(int CustomerId) { bool services = new QuotationRepository().CustomerLogisticServices(CustomerId); return(Ok(services)); }