-
Notifications
You must be signed in to change notification settings - Fork 116
[IMP] account: add more visibility about the sent status of invoices #4861
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: 18.0-rd-accounting-onboarding-malb
Are you sure you want to change the base?
[IMP] account: add more visibility about the sent status of invoices #4861
Conversation
|
This PR targets the un-managed branch odoo-dev/odoo:18.0-rd-accounting-onboarding-malb, it needs to be retargeted before it can be merged. |
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.
Commit message needs to be modified to fit the guidelines 😄
| tracking=True, | ||
| help="It indicates that the invoice/payment has been sent or the PDF has been generated.", | ||
| ) | ||
| is_move_sent_string = fields.Selection( |
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.
In python it's kind of a bad practice to name a field with his type, why ? Because the type can change at any time during the execution. So maybe we could name the field move_sent_values
| selection=[ | ||
| ("sent", "Sent"), | ||
| ("not_sent", "Not Sent") | ||
| ], | ||
| copy=False, | ||
| compute="_compute_is_move_sent_string" | ||
| ) |
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.
Rule of thumb when working with quotes in python --> Double quote for what the user will see, and single quote for other cases 😄
| selection=[ | |
| ("sent", "Sent"), | |
| ("not_sent", "Not Sent") | |
| ], | |
| copy=False, | |
| compute="_compute_is_move_sent_string" | |
| ) | |
| selection=[ | |
| ('sent', "Sent"), | |
| ('not_sent', "Not Sent") | |
| ], | |
| copy=False, | |
| compute='_compute_is_move_sent_string' | |
| ) |
| if move.is_move_sent: | ||
| move.is_move_sent_string = "sent" | ||
| else: | ||
| move.is_move_sent_string = "not_sent" |
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.
| if move.is_move_sent: | |
| move.is_move_sent_string = "sent" | |
| else: | |
| move.is_move_sent_string = "not_sent" | |
| move.is_move_sent_string = 'sent' if move.is_move_sent else 'not_sent' |
In the account module, we want to help customers visualize which invoice has been sent or not. task-5231288
011e0b2 to
c72bfe9
Compare
In the account module, we want to help customers visualize which invoice
has been sent or not.
task-5231288