Discount module spryker on saving gives error "forbidden"

mohammed.shamim
mohammed.shamim Posts: 35 🧑🏻‍🚀 - Cadet

we customized the discount module and storing the condition in a column . everything working fine on local when we save form with condition (rule column) but on server while saving the form with condition gives "forbidden error". Just didn't get it why , I already spend considerable time on this. please help if someone familiar with this error or faced this in person.

Best Answer

  • mohammed.shamim
    mohammed.shamim Posts: 35 🧑🏻‍🚀 - Cadet
    Answer ✓

    its was an issue of firewall and resolved by spryker!

Answers

  • Salmanali Agharia
    Salmanali Agharia Posts: 9 🧑🏻‍🚀 - Cadet

    Hi @mohammed.shamim ,

    As per the error message, it seems that server might be having some firewall settings which doesn't allow to save it. Please check the same.

    Thanks

  • mohammed.shamim
    mohammed.shamim Posts: 35 🧑🏻‍🚀 - Cadet

    Thanks, But I have other form also that working fine on server. what so special for this that need firwall setting to be changed!? why same thing not happen in other form. ? that what i m tried to get.

  • Salman Agharia
    Salman Agharia Posts: 4 🧑🏻‍🚀 - Cadet

    @mohammed.shamim Sometimes, it happens that all things work correctly locally but in server it doesn't work due to some issues. And firewall can also be one of the reason based on my experience . Is there any specific error getting logged while submitting the form ? If not, put the breakpoint in the code to debug it using XDebug. It might help you if the issue is in the code. You can also check the permissions of the backoffice user using which you're trying to save the form.

  • vinod.agarwal
    vinod.agarwal Spryker Solution Partner Posts: 12 🧑🏻‍🚀 - Cadet

    Hi,

    We are also using spryker paas, from the last 1 month we have been facing this kind of random issue. Whenever we save/update any discount, we are getting 403 issue intermittently. This is not replicable on local environment.

  • mohammed.shamim
    mohammed.shamim Posts: 35 🧑🏻‍🚀 - Cadet

    Yes, same issue but its sort of permanent . I attached two screen shot. When ever i tried to add a condition and a saved it , it throw error like '403 forbidden.' although without adding any condition it works fine . on local its work fine even with condition. This issue persist so long perm ant not intermittently at my end.

  • vikram.bishnoi
    vikram.bishnoi Spryker Solution Partner Posts: 15 🧑🏻‍🚀 - Cadet

    Did you try adding the currency in the condition tab with SKU? We faced similar issue with Grand Total condition.

  • mohammed.shamim
    mohammed.shamim Posts: 35 🧑🏻‍🚀 - Cadet

    At my end, we not have currency option. please see the screen shot for option detail.

  • vikram.bishnoi
    vikram.bishnoi Spryker Solution Partner Posts: 15 🧑🏻‍🚀 - Cadet

    Can you please post the screenshots of all the tabs?

  • mohammed.shamim
    mohammed.shamim Posts: 35 🧑🏻‍🚀 - Cadet
    edited March 29

    above screen shot contain all tabs for discount module!

  • vikram.bishnoi
    vikram.bishnoi Spryker Solution Partner Posts: 15 🧑🏻‍🚀 - Cadet

    My observation so far is related to condition tab. Add conditions for example -

    currency

    Grandtotal

    and try to save it, it may fail, change the price try again. I got this error many times andalways changing the conditions solves the issue. Once it is saved, you can upadate the condition as desired.

  • fsmeier
    fsmeier Senior Software Engineer & Developer Enablement Advocate Sprykee Posts: 1,057 ⚖️ - Guardians (admin)

    Heyhey,

    does the problem still exist?

    All the best,

    Florian

  • mohammed.shamim
    mohammed.shamim Posts: 35 🧑🏻‍🚀 - Cadet
    Answer ✓

    its was an issue of firewall and resolved by spryker!