mirror of
https://github.com/ash-project/ash_postgres.git
synced 2024-09-20 05:23:18 +12:00
fix: fix type specification for foreign_key_names
This commit is contained in:
parent
5805f07d69
commit
c6d71d74bf
2 changed files with 70 additions and 70 deletions
|
@ -1294,9 +1294,3 @@ check_constraint :price, "price_must_be_positive", check: "price > 0", message:
|
|||
### Introspection
|
||||
|
||||
Target: `AshPostgres.CheckConstraint`
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -335,7 +335,13 @@ defmodule AshPostgres.DataLayer do
|
|||
"""
|
||||
],
|
||||
foreign_key_names: [
|
||||
type: {:list, {:or, [{:tuple, [:atom, :string]}, {:tuple, [:string, :string]}]}},
|
||||
type:
|
||||
{:list,
|
||||
{:or,
|
||||
[
|
||||
{:tuple, [{:or, [:atom, :string]}, :string]},
|
||||
{:tuple, [{:or, [:atom, :string]}, :string, :string]}
|
||||
]}},
|
||||
default: [],
|
||||
doc: """
|
||||
A list of foreign keys that could raise errors, or an mfa to a function that takes a changeset and returns a list. In the format: `{:key, "name_of_constraint"}` or `{:key, "name_of_constraint", "custom error message"}`
|
||||
|
|
Loading…
Reference in a new issue