55 lines
2.0 KiB
C#
55 lines
2.0 KiB
C#
using Microsoft.AspNetCore.Mvc;
|
|
using Nop.Core;
|
|
using Nop.Plugin.Misc.AuctionPlugin.Domains;
|
|
using Nop.Plugin.Misc.AuctionPlugin.Domains.Dtos;
|
|
using Nop.Plugin.Misc.AuctionPlugin.Domains.Entities;
|
|
|
|
namespace Nop.Plugin.Misc.AuctionPlugin.Services;
|
|
|
|
/// <summary>
|
|
/// Store pickup point service interface
|
|
/// </summary>
|
|
public interface IAuctionService
|
|
{
|
|
/// <summary>
|
|
/// Gets all bids
|
|
/// </summary>
|
|
/// <param name="customerId">The store identifier; pass 0 to load all records</param>
|
|
/// <param name="pageIndex">Page index</param>
|
|
/// <param name="pageSize">Page size</param>
|
|
/// <returns>
|
|
/// A task that represents the asynchronous operation
|
|
/// The task result contains the bids
|
|
/// </returns>
|
|
Task<IPagedList<AuctionBid>> GetAllBidsAsync(int customerId = 0, int pageIndex = 0, int pageSize = int.MaxValue);
|
|
|
|
Task<AuctionBid> GetBidByIdAsync(int bidId);
|
|
|
|
Task InsertBidAsync(AuctionBid auctionBid);
|
|
|
|
Task UpdateBidAsync(AuctionBid auctionBid);
|
|
|
|
Task DeleteBidAsync(AuctionBid pickupPoint);
|
|
|
|
Task InsertAuctionAsync(Auction auction);
|
|
|
|
Task<IList<Auction>> GetAllAuctionsAsync();
|
|
|
|
Task<List<ProductToAuctionMapping>> GetProductToAuctionsByAuctionIdAsync(int auctionId, bool onlyActiveItems = false);
|
|
|
|
Task<AuctionDto> GetAuctionDtoByIdAsync(int auctionId);
|
|
|
|
|
|
Task<AuctionDto> GetAuctionDtoWithProductByIdAsync(int auctionId, int productId);
|
|
|
|
Task<ProductToAuctionDto> GetProductToAuctionDtoByIdAsync(int productToAuctionId);
|
|
|
|
Task<AuctionBidDto> GetAuctionBidDtoByIdAsync(int auctionBidId);
|
|
|
|
Task<ProductToAuctionMapping> AssignProductToAuctionAsync(int productId, decimal startingPrice, decimal bidPrice, int auctionId);
|
|
Task<List<ProductToAuctionMapping>> GetProductToAuctionsByProductIdAsync(int productId);
|
|
|
|
Task<List<ProductToAuctionMapping>> GetProductToAuctionByAuctionIdAndProductIdAsync(int auctionId, int productId);
|
|
|
|
Task<bool> AssignProductToAuctionAsync(int productId, decimal startingPrice, decimal bidPrice, int auctionId);
|
|
} |