history->pop(); $lookup = new MLookup(); $text = MIOLO::_Request('selText'); if ( $text && $text != 'undefined') { $lookup->setSelectionText( $text ); } $MIOLO->conf->loadConf( $lookup->module ); $file = $MIOLO->GetModulePath($lookup->module,'db/lookup.class'); if ( file_exists( $file ) ) { $ok = $MIOLO->Uses('/db/lookup.class',$lookup->module); } else { $ok = $MIOLO->Uses('/classes/lookup.class',$lookup->module); } $MIOLO->Assert($ok,_M('Arquivo modules/@1/classes/lookup.class não encontrado.', 'admin') . '
' . _M('Este arquivo deve implementar a classe Business@1Lookup ', 'admin', $lookup->module) . _M('contendo a função Lookup@1.','admin', $lookup->item) ); $page->AddScript('m_lookup.js'); $page->SetTitle('Janela de Pesquisa'); $businessClass = "Business{$lookup->module}Lookup"; $lookupMethod = "Lookup{$lookup->item}"; $object = new $businessClass(); $object->$lookupMethod($lookup); $page->SetAction($lookup->href); $theme = $MIOLO->GetTheme($MIOLO->GetConf('theme.lookup'),'lookup'); $theme->SetContent($lookup->generate( )); $theme->SetLayout('lookup'); ?>