Skip to content

[BUG] PostNL shippingmethods custom not working when create shipment in backend #384

Open
@JoostWan

Description

@JoostWan

To Reproduce
Steps to reproduce the behavior:

  1. Set a custom shipping method in the backend option Path: tig_postnl/extra_settings_advanced/allowed_shipping_methods
  2. Place a backend order with the selected custom shipping method.
  3. Create a shipment for the placed order with the custom shipping method.

Now there are no PostNL options available.

Screenshot 2024-05-12 at 22 25 14

In this file is there a check that returns false
https://github.com/postnl/postnl-magento2/blob/master/view/adminhtml/templates/shipment/create/options.phtml#L6

This function is checked from the options.phtml and returns false
https://github.com/postnl/postnl-magento2/blob/master/Block/Adminhtml/Shipment/OptionsAbstract.php#L92

When you change this for testing to return true the shipping options are visible. But on the next page where you can download the labels there is again a check on shipping method. https://github.com/postnl/postnl-magento2/blob/master/Block/Adminhtml/Shipment/View.php#L62

  • Magento version: 2.4.6
  • PHP version: 8.2
  • TIG PostNL version: 1.14.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions