Proposal Summary
This proposal covers the scope of restricting items on sales order based on the shipping address and shipping method.
Requirement
- The requirement includes restricting certain products from being added to sales orders for customers in certain areas due to shipping restrictions and some items cannot be shipped internationally due to being hazardous cargo as well as some items restricted from certain markets per manufacturer requirements.
- The item level restrictions are required to prevent these items from going on a sales order so it will not cause further issues in the shipping department, etc.
- The options would be something like the below:
- No Australia
- No Germany
- No Canada
- No Air Shipment
- No International Shipment (continental US only)
- Continental US/Mex/Canada Ground Only (sort same as no air)
- When a user adds products to their sales order, the system should check the shipping address against the predefined shipping restriction of the item. If the customer’s shipping address matches a restricted area for a particular product, the system should prevent the user from adding that product to their order.
- Confirm whether the shipping method that was chosen for the sales order is not listed in the item record’s restricted shipping method. If the selected shipping method is not compatible with an item in the order, the system should prevent the customer from adding that product to their order using that particular shipping method.
Deliverables
For restricting the items while entering the order, we can implement scripts to validate and restrict the items to the sales order list.
Based on Shipping Address
- Customize the item record and add a multi-select field to select the restricted countries to which the product can’t be shipped, and this list of countries will be used for validation purposes while creating a sales order.
- Make sure that the user records the customer’s shipping address at the time of entering a sales order.
- The system needs to restrict the item if it is not allowed to ship to the selected address and make an alert that the item can’t be shipped to the selected shipping address.
- If the shipping address is tried to change after or in between the sales order item addition, an alert will be thrown to prevent the Shipping address change.
Based on Shipping Method
- Use a custom list field in the item record to specify the restricted shipping methods of that item. This list can be used for verifying the shipping methods while creating the sales order.
- Validate whether the selected product is available for the shipping method chosen by the user, and if not, give an alert that the item can’t be shipped through the selected method.
- If the shipping method is tried to change after or in between the sales order item addition, an alert will be thrown to prevent the Shipping address change.
On Save
Option 1
- On the saving of a sales order record, if any of the Items are restricted based on the selected shipping address or shipping method, a user error will be thrown, and all the line level data entered by the user will be gone.
Option 2
- On the saving of a sales order record, if any of the Items are restricted based on the selected shipping address or shipping method, an alert will be thrown, and the user will be prevented from saving. This method may affect the performance of the create page of the sales order if the Item entries are more than 25 (with more Kit Items this count may reduce).
- On checking the NetSuite account, the Sales Order line count have reached a maximum of 500-line entries. So, we do not entertain this way of alerting the user as the page will go unresponsive.
Assumptions
- The data in the Sales order remains the same even if the item record has been updated with a new list of countries/shipment methods or the shipping address/shipping method of the customer is modified.
- The conditions will be verified only for the creation of the sales order. Edit event will not be considered.
- If the product selected is a kit item, we will consider the shipping address and shipping method of the components of the kit item. If any of the components are banned by the shipping method or shipping address selected, the kit item will be restricted (only first level components of the kit will be considered).
- For make copy of a sales order the line level verification will not be applicable, conditions will be verified while saving the record.
- The functionalities like Add multiple, Upsell Items, Intelligent Recommendations cannot be considered due to the limitations of the customization in NetSuite.
- Shipping address or shipping method restrictions added to Items will be only applicable to newly created sales orders.
- This is only applicable for Sales orders created through UI. Any sales orders created via scripts, integration or webstore will not be considered for the proposed method of restriction.
Risks
- User may experience performance issues as the page might go unresponsive during validations for a sales order that has a large number of Items.
- Depending on how many distinct components a kit item has, validating the components for restriction may take time and can lead to the page being unresponsive.
- If we opt for Option 1 for the Save action, the entire Item list will be removed if at least one item satisfies the condition of restriction. This will be applicable for Make copy as well.
- Line level make copy will not be checked for the restriction.