You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
defchangeset(struct,params\\%{})dostruct|>cast(params,@all_fields)|>validate_required(@all_fields)|>validate_field_relational(:cms_learn_category_id)enddefpvalidate_field_relational(changeset,field)dofield_concerned=get_field(changeset,field)caseEcto.UUID.cast(field_concerned)do:error->add_error(changeset,field,"relational field is invalid")_->changesetendend
The text was updated successfully, but these errors were encountered:
Environment
Expected behavior
it is likely that phoenix Json can't know its relation table which is UUID , For this purpose I have an error, but it know invalid UUID of id table.
please see this post which I have described.
https://elixirforum.com/t/how-to-stop-500-errors-when-uuid-doesnt-match/14072/27
I was forced to write this :
The text was updated successfully, but these errors were encountered: