-
Notifications
You must be signed in to change notification settings - Fork 47
CP-4131: Tax List V2 Migration #116
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
base: feature-branch-commerce-service
Are you sure you want to change the base?
CP-4131: Tax List V2 Migration #116
Conversation
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.
Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.
| ) : RecyclerAdapterItem<CatalogTax, TaxItemBinding>(item, onBinding) | ||
| val amountString: String = if (item.tax.amount != null) ( | ||
| item.tax.amount?.amount?.value.toString() + ' ' + item.tax.amount?.amount?.currencyCode | ||
| ) else "N/A", |
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.
Should it be a localized string from R.string.*? Since we support multiple Locales
| } | ||
|
|
||
|
|
||
| // Step 2: create tax association. Tax Association creates one-to-many relationship, one tax to many products/categories. |
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.
Do we want to keep the commented code or we can simply remove it?
| private const val DEFAULT_TAX_PRODUCTS_PAGE_SIZE = 100 | ||
| private const val DEFAULT_TAX_PRODUCTS_PAGE_OFFSET = 0 | ||
| } | ||
| enum class DialogType{ |
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.
The formatting is a bit wrong in many places like here:
// Correct formatting:
enum class DialogType {
ADD_CLASSIFICATION,
ADD_OVERRIDE,
REMOVE_CLASSIFICATION,
REMOVE_OVERRIDE,
NO_SHOW,
}Here is the formatting that we should follow: https://kotlinlang.org/docs/coding-conventions.html#indentation
If you want to fix the formatting all at once, in Android Studio double press "Shift" button and then type "Reformat Code" action. When you select it, it will reformat the entire file correctly according to Kotlin Conventions
| if (id.isNotNullOrBlank()) { | ||
| return@bindTo Toast.makeText( | ||
| requireContext(), | ||
| "Category with id [${id}] was updated", |
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 should be a localized string
Screen_recording_20250828_174157.mp4