Repository navigation
[18.0][FIX] barcode_scanner: notify errors as danger - #25
Conversation
|
Hi @szalatyzuzanna, |
edescalona
left a comment
There was a problem hiding this comment.
The code looks good to me; just a suggestion—feel free to proceed as you see fit.
| @@ -0,0 +1,41 @@ | |||
| /* @odoo-module */ | |||
There was a problem hiding this comment.
I don’t think it would be necessary; what do you think?
There was a problem hiding this comment.
You're right, files under static/tests are already treated as Odoo modules. Removed in 50926f2. Thanks!
szalatyzuzanna
left a comment
There was a problem hiding this comment.
Thanks for the fix! LGTM.
Could you squash both commits into a single [FIX] one and force-push?
|
This PR has the |
d668a30 to
c237026
Compare
|
/ocabot merge patch |
|
On my way to merge this fine PR! |
BarcodeScannerFeedbackService forwarded the feedback level directly as the notification type. Odoo expects "danger" for error notifications, so "error" was not rendered as a danger notification. Map feedback levels to valid Odoo notification types and add a regression test covering all levels.
c237026 to
bcc67c1
Compare
|
/ocabot merge patch |
|
On my way to merge this fine PR! |
|
@szalatyzuzanna your merge command was aborted due to failed check(s), which you can inspect on this commit of 18.0-ocabot-merge-pr-25-by-szalatyzuzanna-bump-patch. After fixing the problem, you can re-issue a merge command. Please refrain from merging manually as it will most probably make the target branch red. |
|
/ocabot merge patch |
|
What a great day to merge this nice PR. Let's do it! |
|
It looks like something changed on |
|
Congratulations, your PR was merged at b1c4eb8. Thanks a lot for contributing to OCA. ❤️ |
Description
BarcodeScannerFeedbackServiceforwarded the feedback level directly as the notification type. Odoo expectsdangerfor error notifications, soerrorproduced an invalid notification type and error feedback was not rendered as a danger notification.This maps feedback levels to valid Odoo notification types and adds a regression test covering
success,warning,infoanderror.