Developer forum

Forum » Development » Flat rate tax provider - shipping fee provider conflict

Flat rate tax provider - shipping fee provider conflict

Jesper Splidsboel
Reply

Hi, I have made a shippingfee provider to handle Free shipping on some products.

public class ShippingFeeProvider : Dynamicweb.Ecommerce.Orders.FeeProvider {
    public override PriceRaw FindFee(Order order)
    {
      // returning my custom fee on some products      
    }    
  }

This has been used on a DW for a while with no problems.

Then I activated Flat Tax Provider to add an extra tax (10%) on an order and my ShippingFeeProvider stops working.

Is this an error or can you give an explanation.

DW version: 9.13.8


 


Replies

 
Nicolai Pedersen Dynamicweb Employee
Nicolai Pedersen
Reply

It does not sound very related. But it is code....

I have asked QA to look into a reproduction.

 
Oleg Rodionov Dynamicweb Employee
Oleg Rodionov
Reply

Hi Jesper,

I've checked the issue using custom Dynamicweb.Ecommerce.Orders.FeeProvider provider on last DW9.14.8. So, I see the following results can be consider as expected: If DW shipping created in DW is based on a shipping provider (USPS was used) then fee by the provider is provided and the free from the custom fee provider is rendered (note it can be overriden by 'Shipping-Fee settings-No fee for purchases over' setting has hight priority and is applied correctly as well now) otherwise regardless Free Tax is rendered in cart or isn't.  Please, provide info about DW version where the issue is not reproduced on, specify you case and your expected results. Thanks.

BR, Oleg QA 

 

 

 
Jesper Splidsboel
Reply

DW version: 9.13.9

Tax is caclulated correct and is rendered in the cart.

The problem is that my Custom FeeProvider is not called or the fee-amount is overwritten.
I set the shippingfee to 0 if some special products is added(in custom fee provider), but my fee is rendered as my default fee from my shippingmethod intead.
We changed the tax-provider from "All products" to "Products and/or groups" and now the fee is calculated correct (0,- from fee provider)
Can you explain or check if there is an error ?

 
Oleg Rodionov Dynamicweb Employee
Oleg Rodionov
Reply

I was not able to reproduce the issue on DW9.13.9 as well. See attached code of custom fee provider used in my check and video has setup and steps to test the issue.

BR, Oleg QA

2023-01-26_09-45-06.png
 
Nicolai Pedersen Dynamicweb Employee
Nicolai Pedersen
Reply
This post has been marked as an answer

Jesper - can we see the code of the feeprovider?

Votes for this answer: 1
 
Jesper Splidsboel
Reply

I think the custom fee provider is the problem.

The tax provider creates an ekstra orderline, and my provider does not handle this correct.

 

You must be logged in to post in the forum