1.0.0 • Published 7 months ago

@iol-inc/fe-vat-utils v1.0.0

Weekly downloads
-
License
MIT
Repository
-
Last release
7 months ago

Functions

computeBase(price) ⇒ number

Computes the base price from the total price. Removes VAT AMOUNT

Kind: global function
Returns: number - The base price.

ParamTypeDescription
pricenumberThe total price. VAT INCLUSIVE

computeMarkupPercent() ⇒ number

Computes the markup percentage based on markup in peso and cost.

Kind: global function
Returns: number - The markup percentage.

ParamTypeDescription
params.markupPesonumberThe markup in peso.
params.costnumberThe cost of the item. VAT Exclusive

computeMarkupPeso() ⇒ number

Computes the markup in peso based on sales and cost.

Kind: global function
Returns: number - The markup in peso.

ParamTypeDescription
params.salesnumberThe total sales. VAT EXCLUSIVE
params.costnumberThe cost of the item. VAT EXCLUSIVE

computeOutputVAT(sales) ⇒ number

Computes the output VAT based on sales.

Kind: global function
Returns: number - The output VAT.

ParamTypeDescription
salesnumberThe total sales. VAT EXCLUSIVE

computeOutputVATFromSellingPrice() ⇒ number

Computes the output VAT from the selling price.

Kind: global function
Returns: number - The output VAT.

ParamTypeDescription
params.sellingPricenumberThe total selling price. VAT INCLUSIVE
params.salesnumberThe total sales. VAT EXCLUSIVE

computeSales() ⇒ number

Computes the sales amount based on cost and markup percentage.

Kind: global function
Returns: number - The computed sales amount.

ParamTypeDescription
params.costnumberThe cost of the item. VAT EXCLUSIVE
params.markupPercentnumberThe markup percentage.

computeSellingPrice(sales) ⇒ number

Computes the selling price from sales and output VAT.

Kind: global function
Returns: number - The total selling price. VAT INCLUSIVE

ParamTypeDescription
salesnumberThe total sales. VAT EXCLUSIVE

computeVATFromPrice(price) ⇒ number

Computes the VAT directly from the total price.

Kind: global function
Returns: number - The VAT amount.

ParamTypeDescription
pricenumberThe total price. VAT INCLUSIVE

computeVATFromBase(base) ⇒ number

Computes the VAT from the base price.

Kind: global function
Returns: number - The VAT amount.

ParamTypeDescription
basenumberThe base price. VAT INCLUSIVE
1.0.0

7 months ago