mirror of
https://github.com/ash-project/ash.git
synced 2024-09-20 05:23:03 +12:00
chore: update docs showing map values for composite types
This commit is contained in:
parent
51b02c6459
commit
198b290b10
2 changed files with 2 additions and 2 deletions
|
@ -834,7 +834,7 @@ defmodule Ash.Actions.Read do
|
|||
if multitenancy_attribute && query.tenant do
|
||||
{m, f, a} = Ash.Resource.Info.multitenancy_parse_attribute(query.resource)
|
||||
attribute_value = apply(m, f, [query.tenant | a])
|
||||
Ash.Query.filter(query, [{multitenancy_attribute, attribute_value}])
|
||||
Ash.Query.filter(query, ref(^multitenancy_attribute) == ^attribute_value)
|
||||
else
|
||||
query
|
||||
end
|
||||
|
|
|
@ -156,7 +156,7 @@ defmodule Ash.Type do
|
|||
And you can also *construct* composite types in expressions, for example:
|
||||
|
||||
```elixir
|
||||
calculate :coordinates, :composite_point, expr(composite_type({some_value, some_other_value}, Point))
|
||||
calculate :coordinates, :composite_point, expr(composite_type(%{x: some_value, y: some_other_value}, Point))
|
||||
```
|
||||
"""
|
||||
|
||||
|
|
Loading…
Reference in a new issue