Commit graph

1461 commits

Author SHA1 Message Date
Zach Daniel
a22b689b07 improvement: support action level metadata 2021-08-27 20:34:20 -04:00
Zach Daniel
d786aadec7 improvement: add on_match: :destroy option 2021-08-27 01:45:13 -04:00
Zach Daniel
fed720bb59 fix: cast nil enum values propertly
improvement: if a map is given for a list, take it's keys
2021-08-22 03:54:11 -04:00
Zach Daniel
c6cafd94cc fix: set api in destroy action hooks
improvement: set better error paths for invalid relationships
improvement: include api in changeset inspect
2021-08-16 10:55:15 -04:00
Zach Daniel
a618eb0a07 chore: release version v1.47.9 2021-08-11 10:43:28 -04:00
Zach Daniel
ad2f678b7e fix: set argument defaults early
fix: don't add indices to non-list inputs in managed relationships
2021-08-11 10:43:21 -04:00
Zach Daniel
a6717a2622 chore: release version v1.47.8 2021-08-05 01:45:40 -04:00
Zach Daniel
7ae048ac9d fix: stop managed relationships from sourcing wrong data
This one took a while to finally figure out! Because belongs_to
relationships are managed *before* the action, and the data coming
into the calls to `manage_relationship` already has the new related
value, we need to use the original data from `changeset.data`. But
when I "fixed" it the first time, I made *everything* do that, which
is not correct, because the original data for the rest of the
relationships has not been loaded at that point yet. So belongs_to
gets its original data from `changeset.data` and the rest gets it
from the result of running the action.
2021-08-05 01:43:40 -04:00
Zach Daniel
46f17dcc51 test: test manage_relationship on update 2021-08-05 00:46:53 -04:00
Zach Daniel
36ae47cdf2 chore: release version v1.47.7 2021-08-04 19:17:50 -04:00
Zach Daniel
1d6d5c8542 fix: redact fields in the resource struct as well 2021-08-04 19:16:49 -04:00
Zach Daniel
1c83f96d27 fix: allow before_action to manage belongs_to relationships 2021-08-04 11:35:32 -04:00
Darren Black
f3b622744d
chore: Failing test for updating a relation in a change (#258) 2021-08-04 10:53:55 -04:00
Zach Daniel
8e11a63e83 fix: load belongs to relationships before managing them 2021-08-03 03:26:01 -04:00
Zach Daniel
4e11e3f0ac fix: don't lookup nil input 2021-08-03 00:50:45 -04:00
Zach Daniel
202c3344dc chore: proper case clause syntax 2021-08-03 00:34:26 -04:00
Zach Daniel
e81028170d fix: don't look for matches for nil 2021-08-03 00:17:36 -04:00
Zach Daniel
d82ea58dbe fix: don't accept list inputs for managed belongs_to 2021-08-03 00:12:05 -04:00
Zach Daniel
a382a8ae20 fix: don't use list inputs in belongs_to managed 2021-08-03 00:00:37 -04:00
Zach Daniel
6a189df2a0 chore: update CI elixir version 2021-08-02 12:06:38 -04:00
Zach Daniel
80cedce2a2 fix: remove belongs to related after action 2021-08-02 11:02:38 -04:00
Zach Daniel
a3ee29c433 fix: fix more cases where belongs_to isn't replaced 2021-08-01 18:48:12 -04:00
Zach Daniel
4872e357ed chore: format code 2021-08-01 14:08:03 -04:00
Zach Daniel
fa1372d433 chore: release version v1.47.6 2021-08-01 13:15:12 -04:00
Zach Daniel
288cf49153 fix: honor on_missing: behavior for belongs_to relationships 2021-07-31 16:07:51 -04:00
Zach Daniel
9e5e958feb fix: properly remove old belongs_to records 2021-07-30 12:42:24 -04:00
Zach Daniel
3216b90323 chore: release version v1.47.5 2021-07-27 23:04:33 -04:00
Zach Daniel
73578f6806 chore: remove IO.inspect 2021-07-27 23:04:22 -04:00
Zach Daniel
1f5538c7f0 fix: set source_query tenant in lateral join 2021-07-27 22:58:45 -04:00
Zach Daniel
13e06524a7 improvement: add belongs_to attributes *after* the others 2021-07-26 20:55:44 -04:00
Zach Daniel
73a0d3319f chore: release version v1.47.4 2021-07-25 17:58:40 -04:00
Zach Daniel
8f88cca020 improvement: pull relationship paths out of functions 2021-07-25 17:58:27 -04:00
Florian Kraft
10aacc05be
docs: Update backers.md (#256)
<3
2021-07-24 11:41:08 -04:00
Zach Daniel
a350ab73f3 chore: release version v1.47.3 2021-07-23 13:17:00 -04:00
Zach Daniel
dd7f5a8e8b fix: no need to trap exits anymore 2021-07-23 13:16:42 -04:00
Zach Daniel
d0d96c0949 chore: release version v1.47.2 2021-07-23 12:12:51 -04:00
Zach Daniel
80e64ee4ad fix: don't match on explicitly :exit 2021-07-23 12:12:37 -04:00
Zach Daniel
51906dd536 chore: release version v1.47.1 2021-07-23 12:10:54 -04:00
Zach Daniel
e0605f2bf0 fix: catch normal exit message from engine 2021-07-23 09:53:25 -04:00
Zach Daniel
b2ae6dc3ea fix: flush engine state always 2021-07-23 09:45:47 -04:00
Zach Daniel
afc74b7a89 chore: release version v1.47.0 2021-07-22 16:26:21 -04:00
Zach Daniel
4ea0e62a79 chore: ensure compiled in a different place
chore: credo
2021-07-22 16:26:02 -04:00
Frank Dugan III
8ba1a9a4c8
feat(Ash.Resource.Info): add &public_field/2 helper (#254)
feat(Ash.Resource.Info): add &sortable?/3 helper
2021-07-22 16:23:54 -04:00
Zach Daniel
d95a0e1662 fix: load calculations from sorts properly 2021-07-22 15:22:53 -04:00
Zach Daniel
759ef25577 fix: rename conflicting test name 2021-07-22 13:36:59 -04:00
Zach Daniel
11c1762f82 fix: fix complex attribute check 2021-07-22 13:20:42 -04:00
Zach Daniel
579c83e20c fix: disallow aggregate/calculation sorting w/ keyset pagination
This can be fixed by configuring pagination to fetch the resource by keyset
(so keyset is only ever primary key), but will perform worse because
we have to fetch the record. If someone would like to implement this,
let me know.
2021-07-22 12:47:43 -04:00
Zach Daniel
64568e5526 imrovement: handle sorts w/o an order in keyset pagination 2021-07-22 11:24:42 -04:00
Zach Daniel
a5c7b197ef chore: release version v1.46.13 2021-07-21 00:16:01 -04:00
Zach Daniel
0b8b704e2c fix: ensure calculation compiled 2021-07-21 00:07:35 -04:00