avo icon indicating copy to clipboard operation
avo copied to clipboard

Improve STI / Polymorphic creation flow with type selection

Open Paul-Bob opened this issue 1 year ago • 1 comments

Context

  • [ ] Make this a guide

https://www.loom.com/share/31c8999bce3640ed9c69558472a74d06


  • [ ] Build a new view component for type selection
  • [ ] Add meta to the resource where the developer can configures the entities like
  • [ ] Use meta[:entities] on the new view component to
  • [ ] Add some links on the view component, each link redirecting to a STI / polymorphic type creation
def entities
    return @resource.meta[:entities] if @resource.meta[:entities].present?

    @resource.record.class.descendants
  end

  self.meta = {
    entities: [Spouse, Sibling]
  }

Paul-Bob avatar Mar 05 '25 08:03 Paul-Bob

This issue has been marked as stale because there was no activity for the past 15 days.

github-actions[bot] avatar Mar 21 '25 02:03 github-actions[bot]