Beispiel #1
0
        public async Task <ApiResponse> GetAll(int batteryType, string queryType, int?queryStatus, int?pageSize, int?pageNumber)
        {
            var batteries = (await _SellerService.GetAll(batteryType, queryType, queryStatus, pageSize, pageNumber))
                            .Select(battery => _mapper.Map <SellerResponse>(battery));

            return(new ApiResponse("Ok", batteries, 200));
        }
Beispiel #2
0
 private void ResetCollection()
 {
     sellers.Clear();
     foreach (SellerViewModel seller in sellerService.GetAll())
     {
         sellers.Add(seller);
     }
 }
Beispiel #3
0
        public MainWindow()
        {
            InitializeComponent();

            sellerService         = new SellerService("TestDbConnection");
            sellers               = sellerService.GetAll();
            cBoxGroup.DataContext = sellers;
        }
Beispiel #4
0
        public IActionResult GetAll()
        {
            var result = _sellerService.GetAll();

            if (result.Success)
            {
                return(Ok(result));
            }
            return(BadRequest(result));
        }
        public Threenine.Data.Paging.IPaginate <Seller> Get(int PageNumber = 0, int PageSize = 30)
        {
            var watch = System.Diagnostics.Stopwatch.StartNew();

            PagingParams pagingParams = new PagingParams();

            pagingParams.PageNumber = PageNumber;
            pagingParams.PageSize   = PageSize;
            _reqinfo.UserId         = Request.Headers["UserId"].ToString();
            _reqinfo.BranchId       = Request.Headers["BranchId"].ToString();
            _reqinfo.DeviceId       = Request.Headers["DeviceId"].ToString();
            var List = _Service.GetAll(pagingParams);

            watch.Stop();
            var elapsedMs = watch.ElapsedMilliseconds;

            _logger.LogInformation("Fetching Follow up Modes");
            return(List);
        }
        public JsonResult SellerList()
        {
            var result = sellerServices.GetAll();

            return(Json(result));
        }
Beispiel #7
0
 public IActionResult Get()
 {
     return(Ok(_sellerService.GetAll()));
 }
        public IActionResult GetAll()
        {
            var sellers = _sellerService.GetAll();

            return(Ok(sellers));
        }
Beispiel #9
0
 public List <Seller> GetAll()
 {
     return(sellerService.GetAll());
 }
Beispiel #10
0
 // GET: Admin/Seller
 public ActionResult Index()
 {
     return(View(_sellerService.GetAll().OrderBy(s => s.trading_name)));
 }
Beispiel #11
0
        public ActionResult <IEnumerable <SellerViewModel> > Get()
        {
            var res = Mapper.Map <IEnumerable <SellerDTO>, IEnumerable <SellerViewModel> >(_sellerService.GetAll());

            return(Ok(res));
        }
 private Threenine.Data.Paging.IPaginate <Seller> RefreshData(PagingParams pagingParams)
 {
     return(_repository.GetAll(pagingParams));
 }