Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Keith Donnell 82 posts 187 karma points
    May 05, 2015 @ 21:52
    Keith Donnell
    0

    Calculating taxes prior to invoicing

    It appears the only time the system calculates taxes is when the invoice is created and there is a shipping address, however we only create an invoice when payment information is entered in the checkout process, but we want to show the user the calculated tax amount and grand total prior to them entering payment (makes sense right?).

    So I guess the question is how do I create an in-memory Invoice (I don't want to load the dashboard with more "junk" invoices than it already creates) based on the current Basket and shipping address?  Or is there a different way to calculate taxes without having to create an invoice (ideally)?

  • Rusty Swayne 1655 posts 4993 karma points c-trib
    May 05, 2015 @ 22:49
    Rusty Swayne
    1

    That is what the PrepareInvoice() method does in the SalesPreparationBase class. Calling this method does not save anything to the database. Internally, it uses the InvoiceBuilderChain class to execute each "TaskChain" task which includes the calculate taxes for invoice task.

  • Keith Donnell 82 posts 187 karma points
    May 06, 2015 @ 00:04
    Keith Donnell
    0

    Perfect, thank you!

  • Biagio Paruolo 1583 posts 1814 karma points c-trib
    May 18, 2015 @ 23:17
    Biagio Paruolo
    0

    Keith I think that this a must for everyone to know the amout ( plus tax ) before. Why Does Merchello don't put this into the application?

  • Rusty Swayne 1655 posts 4993 karma points c-trib
    May 18, 2015 @ 23:50
    Rusty Swayne
    0

    Biagio

    I'm hoping to make the taxation process more configurable but we can't just by default add tax to each product price and assume that we are always dealing with a system like VAT. In the US for example taxes can get extremely complicated - like in the state I live in (Washington State) we have to calculate taxes based on the destination address of recipient of whatever we are shipping and account for local municipality, county and state tax so the combination can vary quite a lot. Also, if we ship outside of the state we do not have to charge tax at all.

    I have a concept to add a global setting to indicate if the taxes are origin or destination based and if origin, have an additional setting that would allow for computing the product cost with taxes included for things like VAT but that will also require some additional stuff in front end implementations to when rendering the price so it really needs to be thought through so things can continue to get easier to implement rather than add another complexity.

  • Biagio Paruolo 1583 posts 1814 karma points c-trib
    May 19, 2015 @ 08:54
    Biagio Paruolo
    0

    Hi, also in Europe the VAT law on ecommerce is changed and can be based on destination for not company purchase.

    Is't possible to configure a default VAT?

Please Sign in or register to post replies

Write your reply to:

Draft