Skip to content

Commit

Permalink
Merge branch 'main' of github.com:avo-hq/avodocs
Browse files Browse the repository at this point in the history
  • Loading branch information
adrianthedev committed Jul 6, 2024
2 parents 0a6d49f + 6ae793b commit 6cd9b01
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions docs/3.0/associations/belongs_to.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,10 @@ Controls the creation link visibility on forms.
#### Possible values

`true`, `false`
:::warning Since version <Version version="3.10.2" />, the target resource policy takes precedence over this option.
`field :user, as: :belongs_to, can_create: true`

In this example, even if the `can_create` option is set to `true`, if the `UserPolicy` responds with `false` to the `create?` method, the creation link will **NOT** be visible.
:::

## Overview
Expand Down

0 comments on commit 6cd9b01

Please sign in to comment.