-
Notifications
You must be signed in to change notification settings - Fork 121
[Shipping Labels] Woomob 891 make hs tariff number mandatory for eu destination #15946
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Shipping Labels] Woomob 891 make hs tariff number mandatory for eu destination #15946
Conversation
|
|
|
Version |
6d00010 to
53e9359
Compare
itsmeichigo
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This works as described 👍 I left some non-blocking comments.
| .foregroundColor(warningRedColor) | ||
| .footnoteStyle() | ||
| .renderedIf(!viewModel.isValidTariffNumber) | ||
| /// |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: redundant line.
|
|
||
| let ((description, valuePerUnit, weightPerUnit, selectedCountry), hsTariffNumber, isHSTariffNumberRequired) = result | ||
|
|
||
| let hsTariffNumberRequirementMet = hsTariffNumber.isEmpty && !isHSTariffNumberRequired || isValidTariffNumber && hsTariffNumber.isNotEmpty |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: I didn't know that && takes priority over ||. Still, should we add braces or split this into two properties for readability?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👌 Gonna add braces for readability

Part of: WOOMOB-891
Description
Makes the HS tariff number required for shipments where destination country is in EU.
isHSTariffNumberRequiredvar forWooShippingCustomsItemViewModelthat's driven by destination country being a member ofCountry.countriesFollowingEUCustoms.isHSTariffNumberRequiredparticipates inrequiredInformationIsEnteredcalculation.WooShippingCustomsItemview:Testing Steps
RELEASE-NOTES.txtif necessary.