-
-
Notifications
You must be signed in to change notification settings - Fork 391
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
[16.0][IMP] account_statement_base: add possibility to navigate from statement lines to the associated journal entry #678
Conversation
Hi @alexis-via, |
self.ensure_one() | ||
if not self: | ||
return {} | ||
action = self.env.ref("account.action_move_line_form").sudo().read()[0] |
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.
Please use the newer form to do this with self.env["ir.actions.actions"]._for_xml_id()
action["view_mode"] = "form" | ||
action["res_id"] = self.move_id.id | ||
del action["view_id"] | ||
del action["views"] |
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.
You are removing here the possible specific form view. This can have side effects.
@pedrobaeza Thanks. I have attended your review comments |
You should squash by default the commits, as it doesn't add value. We have here in GitHub a differential view of the latest changes already. |
7e00485
to
d258d50
Compare
Squashed. What I don't like about adding the button is that it shows always. We cannot make it optional, as it happens with normal fields. |
Really? You can make it invisible AFAIK. |
…ent lines to the associated journal entry through a button. Adds also the journal entry number as an optional field
d258d50
to
ce3600d
Compare
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.
I don't see a problem on leaving the button visible 🤔
Sorry, I wrote the reverse sentence: "you can make the button invisible with the |
@pedrobaeza Can we merge this one? |
Please do it invisible when no move present. |
I do not understand your suggestion. there's always a move. |
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.
Oh, sorry, my bad.
/ocabot merge minor
This PR looks fantastic, let's merge it! |
Congratulations, your PR was merged at 0869f74. Thanks a lot for contributing to OCA. ❤️ |
… in tree view Related to OCA#678 TT50970
… in tree view Related to OCA#678 TT50970
… in tree view Related to OCA#678 TT50970
… in tree view Related to OCA#678 TT50970
Through a button. Adds also the journal entry number as an optional field.
cc @etobella @pedrobaeza @alexis-via