Replies: 2 comments 15 replies
-
So what is the error you are getting @lpe? Is the validation failing because the field is not being sent in? |
Beta Was this translation helpful? Give feedback.
4 replies
-
Yes. Please note that I dit not set a context in the avo.rb intializer as |
Beta Was this translation helpful? Give feedback.
11 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
This is my code in the resource :
field :accountnr, as: :text, name: "Code comptable", readonly: -> { !current_user.compta? }
This is the error when I try to edit / save :
method=PUT path=/resources/accounts/22772 format=turbo_stream controller=Avo::AccountsController action=update status=302 duration=27.26 view=0.00 db=4.79 location=http://localhost:3000/resources/accounts/22772 unpermitted_params=["_method", "authenticity_token", "account", "resellers-dummy", "categories-dummy", "fake_lastcontact", "button", "accountnr"] ...
It seems this is due to the block as this is working :
field :accountnr, as: :text, name: "Code comptable", readonly: false
This is working on another field :
field :actif, as: :boolean, index_text_align: :center, hide_on: [:show], readonly: -> { !current_user.compta? }
I don't understand why ...
Updated to 2.19, same issue.
Any idea ? Thx by advance.
Beta Was this translation helpful? Give feedback.
All reactions