Skip to content
Permalink
Browse files

Improve UX for index autocreation

  • Loading branch information
flack committed Nov 19, 2019
1 parent f692518 commit ac645394a35530e1c2f1a8618ad6a49e73dc2564
Showing with 7 additions and 1 deletion.
  1. +4 −1 lib/net/nehmer/static/handler/view.php
  2. +3 −0 lib/net/nehmer/static/style/index-missing.php
@@ -7,6 +7,7 @@
*/
use midcom\datamanager\datamanager;
use midcom\workflow\dialog;
/**
* n.n.static index page handler
@@ -130,7 +131,9 @@ private function _load_index_article()
$index_qb->add_constraint('name', '=', 'index');
if ($index_qb->count_unchecked() == 0) {
$schema = $this->_request_data['schemadb']->get_first();
return new midcom_response_relocate("createindex/{$schema->get_name()}/");
$this->_request_data['schema'] = $schema->get_name();
dialog::add_head_elements();
return $this->show('index-missing');
}
}
@@ -0,0 +1,3 @@
<script>
create_dialog($('<div>'), '', 'createindex/&(data['schema']);/');
</script>

0 comments on commit ac64539

Please sign in to comment.
You can’t perform that action at this time.