Webiant Logo Webiant Logo
  1. No results found.

    Try your search with a different keyword or use * as a wildcard.

ITaxService.cs

using Nop.Core.Domain.Catalog;
using Nop.Core.Domain.Customers;
using Nop.Core.Domain.Orders;
using Nop.Core.Domain.Tax;

namespace Nop.Services.Tax;

/// 
/// Tax service
/// 
public partial interface ITaxService
{
    #region Product price

    /// 
    /// Gets price
    /// 
    /// Product
    /// Price
    /// 
    /// A task that represents the asynchronous operation
    /// The task result contains the price. Tax rate
    /// 
    Task<(decimal price, decimal taxRate)> GetProductPriceAsync(Product product, decimal price);

    /// 
    /// Gets price
    /// 
    /// Product
    /// Price
    /// Customer
    /// 
    /// A task that represents the asynchronous operation
    /// The task result contains the price. Tax rate
    /// 
    Task<(decimal price, decimal taxRate)> GetProductPriceAsync(Product product, decimal price, Customer customer);

    /// 
    /// Gets price
    /// 
    /// Product
    /// Price
    /// A value indicating whether calculated price should include tax
    /// Customer
    /// 
    /// A task that represents the asynchronous operation
    /// The task result contains the price. Tax rate
    /// 
    Task<(decimal price, decimal taxRate)> GetProductPriceAsync(Product product, decimal price,
        bool includingTax, Customer customer);

    /// 
    /// Gets price
    /// 
    /// Product
    /// Tax category identifier
    /// Price
    /// A value indicating whether calculated price should include tax
    /// Customer
    /// A value indicating whether price already includes tax
    /// 
    /// A task that represents the asynchronous operation
    /// The task result contains the price. Tax rate
    /// 
    Task<(decimal price, decimal taxRate)> GetProductPriceAsync(Product product, int taxCategoryId, decimal price,
        bool includingTax, Customer customer,
        bool priceIncludesTax);

    /// 
    /// Gets a value indicating whether a product is tax exempt
    /// 
    /// Product
    /// Customer
    /// 
    /// A task that represents the asynchronous operation
    /// The task result contains a value indicating whether a product is tax exempt
    /// 
    Task IsTaxExemptAsync(Product product, Customer customer);

    #endregion

    #region Shipping price

    /// 
    /// Gets shipping price
    /// 
    /// Price
    /// Customer
    /// 
    /// A task that represents the asynchronous operation
    /// The task result contains the price. Tax rate
    /// 
    Task<(decimal price, decimal taxRate)> GetShippingPriceAsync(decimal price, Customer customer);

    /// 
    /// Gets shipping price
    /// 
    /// Price
    /// A value indicating whether calculated price should include tax
    /// Customer
    /// 
    /// A task that represents the asynchronous operation
    /// The task result contains the price. Tax rate
    /// 
    Task<(decimal price, decimal taxRate)> GetShippingPriceAsync(decimal price, bool includingTax, Customer customer);

    #endregion

    #region Payment additional fee

    /// 
    /// Gets payment method additional handling fee
    /// 
    /// Price
    /// Customer
    /// 
    /// A task that represents the asynchronous operation
    /// The task result contains the price. Tax rate
    /// 
    Task<(decimal price, decimal taxRate)> GetPaymentMethodAdditionalFeeAsync(decimal price, Customer customer);

    /// 
    /// Gets payment method additional handling fee
    /// 
    /// Price
    /// A value indicating whether calculated price should include tax
    /// Customer
    /// 
    /// A task that represents the asynchronous operation
    /// The task result contains the price. Tax rate
    /// 
    Task<(decimal price, decimal taxRate)> GetPaymentMethodAdditionalFeeAsync(decimal price, bool includingTax, Customer customer);

    #endregion

    #region Checkout attribute price

    /// 
    /// Gets checkout attribute value price
    /// 
    /// Checkout attribute
    /// Checkout attribute value
    /// 
    /// A task that represents the asynchronous operation
    /// The task result contains the price. Tax rate
    /// 
    Task<(decimal price, decimal taxRate)> GetCheckoutAttributePriceAsync(CheckoutAttribute ca, CheckoutAttributeValue cav);

    /// 
    /// Gets checkout attribute value price
    /// 
    /// Checkout attribute
    /// Checkout attribute value
    /// Customer
    /// 
    /// A task that represents the asynchronous operation
    /// The task result contains the price. Tax rate
    /// 
    Task<(decimal price, decimal taxRate)> GetCheckoutAttributePriceAsync(CheckoutAttribute ca, CheckoutAttributeValue cav, Customer customer);

    /// 
    /// Gets checkout attribute value price
    /// 
    /// Checkout attribute
    /// Checkout attribute value
    /// A value indicating whether calculated price should include tax
    /// Customer
    /// 
    /// A task that represents the asynchronous operation
    /// The task result contains the price. Tax rate
    /// 
    Task<(decimal price, decimal taxRate)> GetCheckoutAttributePriceAsync(CheckoutAttribute ca, CheckoutAttributeValue cav,
        bool includingTax, Customer customer);

    #endregion

    #region VAT

    /// 
    /// Gets VAT Number status
    /// 
    /// Two letter ISO code of a country and VAT number (e.g. GB 111 1111 111)
    /// 
    /// A task that represents the asynchronous operation
    /// The task result contains the vAT Number status
    /// 
    Task<(VatNumberStatus vatNumberStatus, string name, string address)> GetVatNumberStatusAsync(string fullVatNumber);

    #endregion

    #region Tax total

    /// 
    /// Get tax total for the passed shopping cart
    /// 
    /// Shopping cart
    /// A value indicating whether we should use payment method additional fee when calculating tax
    /// 
    /// A task that represents the asynchronous operation
    /// The task result contains the result
    /// 
    Task GetTaxTotalAsync(IList cart, bool usePaymentMethodAdditionalFee = true);

    #endregion
}