normalization = $normalization; } public function __invoke(ServerRequest $request): void { if (isset($_POST['getColumns'])) { $html = '' . ''; //get column whose datatype falls under string category $html .= $this->normalization->getHtmlForColumnsList( $GLOBALS['db'], $GLOBALS['table'], _pgettext('string types', 'String') ); echo $html; return; } if (isset($_POST['splitColumn'])) { $num_fields = min(4096, intval($_POST['numFields'])); $html = $this->normalization->getHtmlForCreateNewColumn($num_fields, $GLOBALS['db'], $GLOBALS['table']); $html .= Url::getHiddenInputs($GLOBALS['db'], $GLOBALS['table']); echo $html; return; } if (isset($_POST['findPdl'])) { $html = $this->normalization->findPartialDependencies($GLOBALS['table'], $GLOBALS['db']); echo $html; return; } $this->addScriptFiles(['normalization.js', 'vendor/jquery/jquery.uitablefilter.js']); $this->render('table/normalization/normalization', [ 'db' => $GLOBALS['db'], 'table' => $GLOBALS['table'], ]); } }