AAAAtmpl/index.html000066600000000054151376417640007536 0ustar00tmpl/cron.php000066600000002246151376417640007220 0ustar00input; $csvilog = $jinput->get('csvilog', null, null); // Display any messages there are if (!empty($csvilog->logmessage)) echo $csvilog->logmessage; else { echo JText::sprintf('COM_CSVI_RESULTS_FOR', $csvilog->getFilename())."\n"; echo str_repeat("=", (strlen(JText::_('COM_CSVI_RESULTS_FOR'))+strlen($csvilog->getFilename())+1))."\n"; if (!empty($this->logresult['result'])) { echo JText::_('COM_CSVI_TOTAL')."\t\t".JText::_('COM_CSVI_RESULT')."\t\t".JText::_('COM_CSVI_STATUS')."\n"; foreach ($this->logresult['result'] as $result => $log) { echo $log->total_result."\t\t".$log->result."\t\t".JText::_('COM_CSVI_'.$log->status)."\n"; } } else echo JText::_('COM_CSVI_NO_RESULTS_FOUND')."\n"; } ?>tmpl/default.php000066600000010064151376417640007700 0ustar00input; ?>
template_name); ?>
tmpl/.htaccess000066600000000177151376417640007345 0ustar00 Order allow,deny Deny from all view.html.php000066600000002521151376417640007214 0ustar00input; $template = $jinput->get('template', null, null); $this->template_name = $template->get('template_name'); // Toolbar $jinput->set('hidemainmenu', 1); JToolBarHelper::title(JText::_( 'COM_CSVI_IMPORTING' ), 'csvi_import_48'); JToolBarHelper::custom('process.cancelimport', 'csvi_cancel_32', 'csvi_cancel_32', JText::_('COM_CSVI_CANCEL'), false); JToolBarHelper::custom('importfile.doimport', 'csvi_import_32', 'csvi_import_32', JText::_('COM_CSVI_IMPORT'), false); // Display it all parent::display($tpl); } } ?>view.json.php000066600000005214151376417640007223 0ustar00input; if ($jinput->get('importsession', true, 'bool')) { // Process the data $this->get('ProcessData'); // Empty the message stack $app = JFactory::getApplication(); $app->set('_messageQueue', array()); // Collect the results $result = array(); // Set the view mode if ($jinput->get('csvipreview', false, 'bool')) { $result['view'] = 'preview'; $result['headers'] = $jinput->get('headers_preview', null, null); $result['output'] = $jinput->get('data_preview', null, null); if (empty($results['headers']) && empty($result['output'])) { $result['process'] = false; $csvilog = $jinput->get('csvilog', null, null); $result['url'] = JURI::root().'administrator/index.php?option=com_csvi&task=process.finished&run_id='.$csvilog->getId(); // Clean the session, nothing to import $this->get('CleanSession'); } else $result['process'] = true; } else { $result['view'] = ''; // Get the number of records processed $result['records'] = $jinput->get('recordsprocessed', 0, 'int'); if ($result['records'] == 0) { $result['process'] = false; $result['url'] = JURI::root().'administrator/index.php?option=com_csvi&task=process.finished&run_id='.$jinput->get('run_id', 0, 'int'); } else { $result['process'] = true; } } } else { $csvilog = $jinput->get('csvilog', null, null); // Collect the results $result = array(); $result['process'] = false; $result['url'] = JURI::root().'administrator/index.php?option=com_csvi&task=process.finished&run_id='.$jinput->get('run_id', 0, 'int'); // Clean the session, nothing to import $this->get('CleanSession'); } if ($result['process']) { // Import is not finished, lets sleep $settings = new CsviSettings(); sleep($settings->get('import.import_wait', 0)); } // Output the results echo json_encode($result); } } ?>index.html000066600000000054151376417640006562 0ustar00.htaccess000066600000000177151376417640006371 0ustar00 Order allow,deny Deny from all view.cron.php000066600000002042151376417640007207 0ustar00input; if (!$jinput->get('error', false, 'bool')) { // Process the data $this->get('ProcessData'); } // Assign the data $this->assignRef('logresult', $this->get('Stats', 'log')); // Display it all parent::display($tpl); } } ?>