atk4 / mastercrud

Manipulates ATK CRUD through the force of references
https://atk4.org
MIT License
9 stars 7 forks source link

Ability to use Mastercrud inside tabs as it is with CRUD? #25

Closed rapgithub closed 1 year ago

rapgithub commented 5 years ago

Is it possible to use mastercrud inside tabs as it is with CRUD only?

I tried to do this but only works for one single model in this case Events model...

  $tabs->addTab('Events', function($p) use($app) {

    $m = $p->add(new MasterCRUD());
    $m->setModel(new Events($app->db), ['Images'=>[]]);

  });

if I click the relational model Images the layout is destroyed and the url address change to this:

html ?atk_narrow_tabs_tabssubview_virtualpage=cut&all_events_id=52

Instead the code below works inside tabs without issues, but only for one model definition...

  $tabs->addTab('Events', function($p) use($app) {
    $m = $p->add('CRUD')->setModel(new Events($app->db));
  });

Any ideas how to make use of mastercrud inside tabs? thanks for the ideas!

romaninsh commented 5 years ago

i don't think that's possible. Wizard and MasterCRUD cannot be contained inside a JS element because they rely on links.

PhilippGrashoff commented 5 years ago

related to atk4/ui#451

PhilippGrashoff commented 5 years ago

So should we close this or keep it as a feature request?

DarkSide666 commented 5 years ago

Not sure. @romaninsh @ibelar what you think about this?

mvorisek commented 1 year ago

closing in favor of https://github.com/atk4/ui/issues/2070