Commit graph

359 commits

Author SHA1 Message Date
Zach Daniel
b2b9e22f7c fix: don't generate duplicate types 2022-09-14 16:50:35 -04:00
Zach Daniel
378892e387 improvement: support latest ash 2022-09-14 12:46:12 -04:00
Zach Daniel
d70c68eed9 fix: error when selecting only the count for pagination 2022-09-12 12:23:58 -04:00
Zach Daniel
c3b63430f9 fix: reference proper modules in doc index 2022-08-30 19:33:11 -06:00
Zach Daniel
f4cb9213b3 update to latest ash 2022-08-30 19:08:16 -06:00
Zach Daniel
a10f61b9b4 improvement: update to latest ash 2022-08-10 17:34:13 -04:00
Zach Daniel
598e9c5616 improvement: handle Page.InvalidKeyset error 2022-05-30 16:46:20 -04:00
Zach Daniel
29909742e2 chore: don't explicitly set type when looking up actions 2022-05-28 21:30:34 -04:00
Zach Daniel
c717ad1ade chore: don't explicitly set type when validating action 2022-05-28 21:26:58 -04:00
Frank Dugan III
13c2abe11a
feat: add policy breakdowns option (#35) 2022-05-24 16:42:40 -04:00
Zach Daniel
0a241cb26e fix: update to latest ash and use new interval type 2022-05-23 16:33:27 -04:00
Frank Dugan III
62c2e4fecb
fix: Types with no constraints crash (#34) 2022-05-20 12:32:06 -04:00
Zach Daniel
96f3a63b74 fix: update to latest ash, fix transformer, get tests working 2022-05-17 12:30:19 -04:00
Maxim Martynov
cc5f3a31f2
fix: Handle error if multitenant resource was fetched without tenant being set (#33) 2022-05-11 12:45:49 -04:00
Zach Daniel
d00e0a6e5d improvement: require registry explicitly to help with compile times 2022-05-10 11:49:19 -04:00
Michael St Clair
6fb99a3ab0
improvement: setup generate_object? setting on resource (#32) 2022-05-09 21:53:01 -04:00
Zach Daniel
5e2b1bc16f fix: depend on registry at compile time 2022-04-26 12:46:51 -04:00
Zach Daniel
4fb3c7d8c6 fix: bug on enum_definitions/3 call 2022-04-26 12:15:48 -04:00
Zach Daniel
8ed9938201 improvement: fix lint/credo/versions 2022-04-26 11:35:09 -04:00
Zach Daniel
a8aa57e0f5 fix: add relay node type properly 2022-04-04 16:55:22 -04:00
Zach Daniel
5d35cf092e fix: ignore embedded resources accidentally placed in API 2022-03-25 13:17:35 -04:00
Zach Daniel
34bc363cf5 Revert "improvement: only do auto enums when doing resource types"
This reverts commit 64ef3efb52.
2022-03-24 18:53:46 -04:00
Zach Daniel
64ef3efb52 improvement: only do auto enums when doing resource types 2022-03-24 18:47:56 -04:00
Zach Daniel
fdee19c3a5 fix: don't include the same enum multiple times 2022-03-24 17:05:53 -04:00
Zach Daniel
191b9b2d80 fix: properly generate types for interval type 2022-01-31 15:06:06 -05:00
Zach Daniel
862bfdd7b4 improvement: updates to handle the new registry changes 2022-01-31 14:55:14 -05:00
Michael St Clair
2348d97534
fix: pass calculation to field type (#29) 2021-10-08 15:59:06 -04:00
Zach Daniel
bdf814cae2 fix: fix get resolver not_found message 2021-09-13 16:55:03 -04:00
Zach Daniel
2632e477b3 fix: authorize reads before destroy
fix: return error when get is nil w/ allow_nil? == false
2021-09-12 16:39:48 -04:00
Zach Daniel
300858f418 fix: select in the new after_action hook, for calculations 2021-09-12 02:13:19 -04:00
Michael St Clair
ffa7d3efdd
fix: fix changeset.errors on destroy (#26) 2021-09-11 15:18:38 -04:00
Zach Daniel
f9b1b75edc feat: more configurable error behavior
added `root_level_errors?` and `show_raised_errors?`
2021-09-09 11:49:36 -04:00
Zach Daniel
c11ad2a6a4 WIP 2021-09-09 00:27:49 -04:00
Zach Daniel
d2d8f199f7 fix: search for types in calculations 2021-09-07 17:06:20 -04:00
Zach Daniel
5dfff6a9a2 fix: if no primary key (only embeds support that), don't require id 2021-09-03 14:44:55 -04:00
Zach Daniel
4b78323550 fix: more non null primar keys! 2021-09-03 13:42:00 -04:00
Zach Daniel
91a457ed2e improvement: more non null constraints 2021-09-03 13:30:47 -04:00
Zach Daniel
50a3a1ccda fix: make primary key attributes appropriately non nil 2021-09-03 13:04:52 -04:00
Zach Daniel
d4f97febf5 improvement: support create/update metadata 2021-08-29 15:23:28 -04:00
Zach Daniel
d8a3e1b155 improvement: add groundwork for relay support 2021-08-03 18:56:08 -04:00
Zach Daniel
d4a7012d6e fix: set actor on initial read of record for update 2021-07-30 17:05:22 -04:00
Zach Daniel
476888717a improvement: support latest ash 2021-07-04 16:44:36 -04:00
Zach Daniel
6c92a23040 improvement: update to latest ash 2021-07-01 22:59:16 -04:00
Zach Daniel
3a0b0c3f83 improvement: add as_mutation for queries
improvement: support `modify_resolution` for queries
2021-06-29 12:17:33 -04:00
Zach Daniel
dffe4de9f5 improvement: update to latest rc
improvement: add `short_message` and `vars` to errors
2021-06-28 13:33:01 -04:00
Zach Daniel
b313618d3a fix: include new custom type 2021-06-21 17:20:24 -04:00
Zach Daniel
5e593ec40c improvement: old json -> json_string
improvement: new json does not stringify outpu
2021-06-15 11:16:10 -04:00
Zach Daniel
020ad849ea improvement: add modify_resolution for mutations 2021-06-14 12:08:26 -04:00
Zach Daniel
d86e60ec68 fix: catch error in `massage_filter/2 2021-06-08 17:37:59 -04:00
Zach Daniel
0cc81ce9f6 improvement: support expression calculations 2021-06-04 15:07:12 -04:00
Zach Daniel
0aa2787d52 improvement: support identity: false for read
improvement: don't type embedded resources is nullable
2021-05-22 23:49:31 -04:00
Zach Daniel
053cef4a65 fix: destroys can still have input objects 2021-05-21 10:56:10 -04:00
Zach Daniel
23094215ef fix: avoid dialyzer errors on generated code 2021-05-19 01:29:57 -04:00
Zach Daniel
31bcf8039e fix: traverse all nested embeds for enum type defs 2021-05-18 14:07:01 -04:00
Zach Daniel
3f0aab37e2 improvement: non nullable aggregates where possible 2021-05-15 12:03:58 -04:00
Zach Daniel
2f31650899 fix: don't load fields if no fields to load 2021-05-14 13:08:25 -04:00
Zach Daniel
77bf8788f5 improvement: log error stacktraces 2021-05-14 12:31:12 -04:00
Zach Daniel
8945851fd1 improvement: add stacktraces? option 2021-05-14 12:25:43 -04:00
Zach Daniel
84ca2e7125 chore: format 2021-05-12 06:49:08 -04:00
Simon Bergström
c222e8088a
fix: Check for nil rather than the value as not does not accept a function (#23)
Co-authored-by: Simon Bergström <simon.bergstrom@erlang-solutions.com>
2021-05-12 06:48:58 -04:00
Zach Daniel
2422440da7
test: Added a test case to managed_relationship with a many_to_many resource (#22)
fix: fix compiler warning

Co-authored-by: Simon Bergström <simon.bergstrom@erlang-solutions.com>
2021-05-11 19:35:50 -04:00
Zach Daniel
3215bdbe12 fix: identities -> lookup_identities 2021-05-11 17:36:09 -04:00
Zach Daniel
aed4306fb9 fix: don't require attributes that should not be required 2021-05-11 17:27:26 -04:00
Zach Daniel
5ecf8bf838 improvement: allow customizing identity/pkey on_lookup 2021-05-11 12:12:28 -04:00
Zach Daniel
b8ca64590f fix: support soft destroys
fix: support actions with no input objects
2021-05-10 02:19:47 -04:00
Zach Daniel
83e0e604a7 improvement: support eliding a type from an input object 2021-05-06 17:22:48 -04:00
WolfDan
c530245295
improvement: Add float type (#20) 2021-05-05 16:15:01 -04:00
Zach Daniel
5a1df9f95a fix: ensure api modules are properly compiled first 2021-05-05 14:50:03 -04:00
Zach Daniel
06d674aac6 fix: don't have leaky errors
fix: support filtering on aggregates in nested resolvers
2021-05-04 13:01:15 -04:00
Zach Daniel
405264911c fix: properly support limit/offset on relationships 2021-05-04 09:31:39 -04:00
Zach Daniel
98f76fa28d chore: fix after? 2021-05-01 16:30:55 -04:00
Zach Daniel
64d87106e5 fix: error rendering some paginated results
fix: ensure id is required after belongs_to attribute
2021-05-01 16:29:18 -04:00
Zach Daniel
a8df1da3cd fix: don't require input types for filters 2021-04-30 16:22:21 -04:00
Zach Daniel
13799c37e7 fix: don't raise on missing relationship actions
fix: properly detect selection of count
2021-04-28 16:54:06 -04:00
Zach Daniel
f1f96cebe7 fix: support Has operator 2021-04-27 13:17:16 -04:00
Zach Daniel
74c2b78d69 fix: properly calculate array aggregate types 2021-04-27 11:40:02 -04:00
Zach Daniel
1cef0d300a fix: only isNil is supported for array filters for now 2021-04-27 01:06:29 -04:00
Zach Daniel
ce0e275a9a fix: load fields before sorting 2021-04-26 17:37:43 -04:00
Zach Daniel
ae23048ba1 fix: load aggregates used in sort 2021-04-26 17:35:03 -04:00
Zach Daniel
3a88127d0b fix: load aggregates from sorts 2021-04-26 17:25:23 -04:00
Zach Daniel
73efedb8da fix: load any aggregates referenced in the filter 2021-04-26 17:22:45 -04:00
Zach Daniel
c293ae5744 fix: more aggregate type fixes 2021-04-26 17:05:29 -04:00
Zach Daniel
938e16d8c1 fix: properly determine aggregate type 2021-04-26 16:48:26 -04:00
Zach Daniel
347d73ec25 fix: properly unwrap invalid errors 2021-04-26 13:14:25 -04:00
Zach Daniel
d9ead2ef32 fix: unwrap invalid errors 2021-04-26 13:07:00 -04:00
Zach Daniel
019697578b feat: derived input objects for managed_relationships
fix: various input fixes (sorts)
improvement: support new style enums
2021-04-23 18:45:31 -04:00
Zach Daniel
68306a7265 improvement: support ash_context key 2021-04-19 16:17:35 -04:00
Zach Daniel
4f71d69c5d improvement: support read_action config for updates and destroys
improvement: support `identity: false` for udpates and destroys
2021-04-19 15:26:20 -04:00
Zach Daniel
e302731d99 fix: project down to multiple levels for result types 2021-04-18 23:19:46 -04:00
Zach Daniel
11db824adc fix: set actor when building changeset 2021-04-18 10:57:18 -04:00
Zach Daniel
6be5c593cd fix: proper not found errors 2021-04-16 13:49:51 -04:00
Zach Daniel
88f912a6aa fix: correctly select fields to clear 2021-04-16 12:59:04 -04:00
Zach Daniel
43dae2ad28 fix: don't clear fields on nil result
chore: add tests for destroy
2021-04-16 12:56:29 -04:00
Zach Daniel
1f098c5fa1 fix: load fields required for relationship 2021-04-15 16:28:04 -04:00
Zach Daniel
6b84bf0f46 fix: detect all embeddable types in arguments and nested
fix: detect enums in embeddable types and arguments
fix: error messages for `InvalidArgument`
improvement: log on unrenderable error messages
fix: store refs in graphql blueprint to fix error messages
improvement: update to latest ash
2021-04-13 17:49:10 -04:00
Zach Daniel
ea6a21586a fix: fix graphql subselections for pagination 2021-04-09 16:29:50 -04:00
Zach Daniel
5ab646b189 chore: small refactor in schema builder 2021-04-09 00:11:45 -04:00
Zach Daniel
e61f75ac40 fix: don't show non-predicate operators in filters 2021-04-06 10:17:04 -04:00
Zach Daniel
6ae8715a13 improvement: support upsert?: true flag on create 2021-04-05 14:41:16 -04:00
Zach Daniel
9cde7df795 fix: fully remove relationship changes 2021-04-05 13:08:39 -04:00
Michael St Clair
b97e81bc9e
improvement: add allow_nil? to queries (#16) 2021-04-05 10:36:52 -04:00
Michael St Clair
5fb50fe2bb
improvement: generate type based on allow_nil? (#14) 2021-04-04 03:16:05 -04:00
Michael St Clair
596dc90381
feat: add read_one query (#13) 2021-04-04 03:10:50 -04:00
Michael St Clair
cb9f5fd28d
support decimal type (#11) 2021-04-02 21:31:53 -04:00
Zach Daniel
004c69c291 feat: support custom types, add custom type test 2021-03-28 12:30:28 -04:00
Zach Daniel
69f34ba55b fix: select fields/aggregates/calculations 2021-03-22 13:03:18 -04:00
Zach Daniel
9151b712f1 improvement: start on error messaging groundwork
fix: properly handle relationship changes on updates
2021-03-15 15:51:17 -04:00
Zach Daniel
919a4edeac chore: format/dialyzer 2021-03-12 09:39:59 -05:00
Zach Daniel
afdaad2886 fix: allow referencing ash generated types 2021-03-12 09:19:33 -05:00
Zach Daniel
885b1d886e chore: modernize example action names
fix: don't fail on empty mutations list
improvement: support more builtin types
2021-03-12 09:04:38 -05:00
Zach Daniel
83b77121d1 improvement: validate action existence 2021-03-08 14:22:41 -05:00
Zach Daniel
b988c4c08c improvement: support debug? at the api level 2021-02-23 12:28:19 -05:00
Zach Daniel
12611b6c64 fix: proper supports for embeds
improvement: update to latest ash
2021-02-22 23:28:01 -05:00
Zach Daniel
33ce6b952d WIP 2021-02-18 10:16:00 -05:00
Zach Daniel
fbfdb7faf8 feat: update to latest ash
feat: support query arguments
2021-01-21 23:06:06 -05:00
Zach Daniel
a820beb474 feat: support embedded resources 2021-01-12 15:14:35 -05:00
Zach Daniel
6f5b081f03 chore: fix linter 2020-12-30 18:00:36 -05:00
Zach Daniel
aabdd4874d fix: in enum filters should be instances of the enum 2020-12-30 17:51:26 -05:00
Zach Daniel
89adb954e3 fix: resolve error with non-required pagination 2020-12-30 13:26:03 -05:00
Zach Daniel
0ca1b770e7 chore: don't parse filter input 2020-12-30 13:10:10 -05:00
Zach Daniel
6dae243a0f fix: properly represent boolean filters 2020-12-30 11:25:26 -05:00
Zach Daniel
539bb14065 feat: filters as input objects 2020-12-29 15:11:16 -05:00
Zach Daniel
9984b19c39 chore: format 2020-12-27 02:05:19 -05:00
Zach Daniel
90b969af2e improvement: update to latest ash 2020-12-27 01:49:35 -05:00
Zach Daniel
e433b57eda fix: resolve testing compilation errors 2020-12-02 00:55:25 -05:00
Zach Daniel
210057d1c3 test: actually have a test :) 2020-12-02 00:07:15 -05:00
Zach Daniel
fc62c6b8f4 fix: don't require attributes that have a default value 2020-11-30 20:00:55 -05:00
Zach Daniel
6c7c789696 fix: remove IO.inspect 2020-11-30 19:19:11 -05:00
Zach Daniel
553f751ddf fix: undo change of global types 2020-11-30 19:16:37 -05:00
Zach Daniel
66b2162d10 fix: always add global types 2020-11-30 19:04:59 -05:00
Zach Daniel
7123a6a492 chore: release version v0.7.1 2020-11-30 18:17:20 -05:00
Zach Daniel
37d0b6534d
feat: Support configuring identities (#8)
* feat: support using identities for gets
2020-11-18 02:14:33 -05:00
Zach Daniel
5b7626c28f
chore: fix sobelow 2020-11-11 23:01:48 -05:00
Zach Daniel
d1f35f420d
improvement: create input honors required relationships 2020-11-11 22:57:48 -05:00
Zach Daniel
cacec2de1d
improvement: add more NonNulls 2020-11-11 22:53:53 -05:00
Zach Daniel
daf8513c26
fix: correct sorting enum/args list 2020-11-11 22:41:54 -05:00
Zach Daniel
74ad0149ec
fix: allow null sorts 2020-11-05 22:12:28 -05:00
Zach Daniel
5534b1c464
fix: default_page_size -> default_limit 2020-11-05 21:44:33 -05:00
Zach Daniel
d5cf6ee3a0
feat: overhaul, better type support, pagination 2020-11-05 20:59:06 -05:00
Zach Daniel
51dc4b8a0c
fix: use the correct tenant function 2020-11-02 21:15:30 -05:00
Zach Daniel
c8b8fc5abd
feat: support multitenancy (#7) 2020-10-28 02:16:16 -04:00
Zach Daniel
bea776326f
chore: formatting 2020-10-09 21:17:40 -04:00
Zach Daniel
77566d96c4
fix: fix usage of new Ash.Query.filter/2 2020-10-09 21:10:22 -04:00
Zach Daniel
244da78444
feat: update to latest ash 2020-10-09 21:04:57 -04:00
Zach Daniel
711fbef250
chore: remove unused code 2020-10-08 13:59:36 -04:00
Zach Daniel
628865c819
fix: set api_opts properly 2020-09-28 09:42:36 -04:00
Zach Daniel
06f3954e83
fix: dataloader errors w/ associations 2020-09-28 09:18:58 -04:00
Zach Daniel
10292ec73d
docs: update docs and links 2020-09-23 21:32:45 -04:00
Zach Daniel
7adb8c0f22
feat: rewrite with dataloader 2020-09-23 20:54:57 -04:00
Zach Daniel
c74f76f8a0
fix: use module name specific to the api
fix: support booleans
2020-09-02 00:52:51 -04:00
Zach Daniel
1090d2f654
fix: use InputObjectDefinition for relationship change 2020-08-26 13:56:08 -04:00
Zach Daniel
a7e4b165e4
fix: don't add graphql types if API doesn't compile 2020-08-17 03:00:13 -04:00
Zach Daniel
b7eaa44376
fix: get mix check passing 2020-08-14 10:20:47 -04:00
Zach Daniel
2fc65976a7
chore: release version v0.1.0 2020-08-13 18:55:34 -04:00
Zach Daniel
cd16030324
feat: initial POC release 2020-08-13 17:39:59 -04:00
Zach Daniel
759c92553c
WIP 2020-06-05 14:41:00 -04:00
Zach Daniel
7563cbf971
fix; move pagination into graphql layer 2020-05-30 04:57:39 -04:00
Zach Daniel
705bbdd4ec
First stab at a schema 2020-05-01 18:35:12 -04:00
Zach Daniel
369f098cef
init 2020-05-01 12:32:56 -04:00