Commit graph

2122 commits

Author SHA1 Message Date
Zach Daniel
6e43784535 docs: update docs, add some context, remove dead link 2022-10-25 09:11:54 -06:00
Zach Daniel
a66a487cf8 chore: add resource builder to hex docs 2022-10-24 12:06:07 -06:00
Zach Daniel
1a1714a37c docs: add resource builder to doc index 2022-10-24 12:05:41 -06:00
Zach Daniel
6b9cff5d43 feat: add Ash.Resource.Builder, the start of DSL builder utilities of rextension writing 2022-10-24 12:04:56 -06:00
Zach Daniel
72171da732 docs: update some descriptions 2022-10-24 08:57:22 -06:00
Zach Daniel
8c0e4de6bd improvement: allow using get_path/2 by name, as well as bracket access
prior to this, you had to say `map[:foo][:bar]`, but now you can also say
`get_path(map, [:foo, :bar])`. This makes certain things much clearer, i.e
`^arg(:foo)[:foo]`, which is problematic, would normally need to be written
as `(^arg(:foo))[:foo]` so that the pin only applied to the `arg/1` call.
This looks much nicer as `get_path(^arg(:foo), [:foo])`.
2022-10-24 07:57:21 -06:00
Josh Price
3d05bfa95e
improvement: SVG, PDF, PNG, Markdown and plain mermaid formats (#428) 2022-10-24 07:55:05 -06:00
Zach Daniel
67814a2160 docs: add more context to manual relationship guide
docs: add a "Defining Idiomatic Actions" guide

chore: fix flaky tests
2022-10-23 23:08:17 -06:00
Zach Daniel
3dd16304f7 improvement: optimize nested exists filter statements
i.e `exists(friends, exists(friends, name == ^name))`
will be automatically translated to `exists(friends.friends, name == ^name)`.
2022-10-23 22:16:50 -06:00
Zach Daniel
5e3b71e79b fix: properly load manual to_one relationships 2022-10-23 22:16:50 -06:00
Zach Daniel
03482cf908 docs: add an initial "Why Ash?" guide 2022-10-23 22:16:50 -06:00
Mykolas Mankevicius
6a9ea80eae
docs: Update get started guide to be more beginner friendly (#429)
Co-authored-by: Zach Daniel <zachary.s.daniel@gmail.com>
2022-10-23 22:07:51 -06:00
Zach Daniel
986e08e0c2 fix: properly compare against decimal values
improvement: support floats & decimals in the `compare` validation
2022-10-21 10:46:46 -04:00
Zach Daniel
7540b31244 chore: release version v2.2.0 2022-10-21 08:31:50 -04:00
Zach Daniel
87877e7f87 improvement: when returning a page, choose keyset if before or after was supplied
This allows for better pagination experiences because you clearly expect
an `Ash.Page.Keyset` if you are using `before/after`
2022-10-21 08:24:51 -04:00
Zach Daniel
d439ac9cbc improvement: add keysets to records if any action supports keysets
feat: add `Ash.Api.Info.depend_on_resources/1` to get the list of resources at compile time

A common desire is to have modules that validate things across Api modules, however `Ash.Api.Info.resources/1`
is not safe to use at compile time. `Ash.Api.Info.depend_on_resources/1` will set up the proper compile
time dependencies, making it safe to use at compile time
2022-10-20 21:57:51 -04:00
Zach Daniel
d1f05b6c42 fix: don't attempt to re-authorize access to already retrieved records in Api.load/2
improvement: show conditions in policy breakdowns
2022-10-20 13:00:23 -04:00
Zach Daniel
8092cd899a docs: remove more experimental warnings 2022-10-20 02:00:56 -04:00
Zach Daniel
d22cf2714b docs: remove experimental warning from manual relationships 2022-10-20 01:59:52 -04:00
Zach Daniel
57466b3498 docs: remove outdated statement about calculations being limited 2022-10-19 22:17:44 -04:00
Zach Daniel
2d7dfc4948 chore: release version v2.1.0 2022-10-19 17:46:19 -04:00
zimt28
9337ed6479
feat: Custom short names for types (#423)
A compile env can be set to allow customizing the available type short names. This supports two things:

1. Adding custom type short names, like `attribute :price, :money` mapping to `MyApp.Type.Money`
2. Overriding the builtin type short names, like `attribute, :price, :string` mapping to a custom string type implementation (there is likely no reason to do this)
2022-10-19 15:24:40 -04:00
Zach Daniel
235e965627 improvement: sort relationship in order of input when managing it
This helps with things like https://github.com/ash-project/ash_phoenix/issues/57
which involve rendering the relationship value after editing it. Retaining
the order allows direct reuse without any gymnastics
2022-10-19 00:39:10 -04:00
Zach Daniel
5a11736931 docs: remove outdated @authorizers reference 2022-10-18 17:43:33 -05:00
Zach Daniel
37074207d8 docs: update actions guide 2022-10-18 17:32:50 -05:00
Zach Daniel
f774e60749 fix: set defaults before running changes 2022-10-18 14:27:35 -05:00
Zach Daniel
4ca69be25e improvement: generate example class/er diagrams 2022-10-18 14:26:42 -05:00
Zach Daniel
4915e5d583 improvement: add now() to expression syntax 2022-10-18 14:19:28 -05:00
zimt28
e4e6be1550
Update README.md (#421) 2022-10-17 16:59:56 -05:00
Zach Daniel
a894651caf
Update README.md 2022-10-17 16:46:20 -05:00
Zach Daniel
8b7beb1fc8
Update README.md 2022-10-17 16:44:26 -05:00
Zach Daniel
e9de4f7997 chore: update readme 2022-10-17 16:44:01 -05:00
Zach Daniel
cac0e41c0e
Update README.md 2022-10-17 14:57:07 -05:00
Zach Daniel
05855fea60 chore: release version v2.0.0 2022-10-17 12:21:03 -05:00
Zach Daniel
8474e60828 chore: more livebook cleanup 2022-10-17 11:04:28 -05:00
Zach Daniel
a365103087 clean up livebook/mermaid diagrams 2022-10-17 10:18:47 -05:00
Josh Price
3f572c65a2
feat: basic livebook generator and mix task (#420) 2022-10-17 08:52:24 -05:00
Zach Daniel
ce35d41ed1 improvement: don't eager evaluate type/2 2022-10-17 08:27:31 -05:00
Zach Daniel
f3a1ee2364 chore: add back private_vars for InvalidAttribute 2022-10-17 08:00:29 -05:00
Josh Price
7db6aa049c
feat: mermaid class diagram mix task (#417) 2022-10-16 19:37:24 -05:00
Josh Price
bb86a13323
docs: refactor diagram, fix doc typos and formatting (#419) 2022-10-16 19:36:37 -05:00
Zach Daniel
6751afc683 improvement: support depending on requests that will be added
docs: improve flow docs

closes: #418
improvement: support dynamic action steps in `Ash.Flow`
2022-10-16 14:07:57 -05:00
Zach Daniel
652342c41d docs: remove the word simply from the docs 2022-10-15 10:16:38 -05:00
Zach Daniel
1e6be17618 fix: properly lateral join when possible
improvement: add `prepend?: true` option to sort
fix: use `prepend?: true` when applying relationship sorts
fix: don't miss dependencies in flow diagrams
improvement: use `simple_equality?/0` to allow for optimized equality checking
2022-10-15 00:03:03 -05:00
Josh Price
5c5ef1976c
refactor: simplify mermaid mix tasks (#416) 2022-10-14 09:32:44 -04:00
Zach Daniel
b0f245b961 chore: update flow pdfs 2022-10-14 01:26:16 -04:00
Zach Daniel
0534518a35 fix: fix deps finding in flow charts & flows 2022-10-14 01:17:52 -04:00
Josh Price
d1a49276b8
improvement: mermaid mix task for ER diagrams (#415) 2022-10-14 01:07:05 -04:00
Zach Daniel
362180190c fix: properly load calcs/aggs on manual relationships
It needs to be optimized, but it will do the trick for now.
2022-10-13 00:36:29 -04:00
Zach Daniel
48d96fc417 fix: properly load nested manual relationships 2022-10-12 21:30:48 -04:00