DB = $DB; } function HTML(){ GLOBAL $WorkDIR; $CHPU = new class_CHPU($WorkDIR); $URLS = $CHPU->uri(); $smartyC = new class_smarty(); $smarty = $smartyC->config(__DIR__.'\..\tpl'); $view = 'all'; $out = array('name'=>'Отчет по ФОС','body'=>''); $kafedra = $_SESSION['user']['teacher']['kafedra']; $fc = $this->file_report = $_SESSION['user']['id'].'_'.$kafedra; $this->saveFOS_inFile('','clear'); $lists = array(); $cache = $this->cache($fc); if($cache=='') { $RPD = new class_RPD(); $RPDsign = new class_RPDSign(); //$out .= $this->HTML_head(); //получим все РПД подписанные $rez = $RPDsign->Disciplins_for_ZAVYPKAF(); //echo '
'.print_r($rez,1).'';exit(); if (isset($rez['items']) && count($rez['items'])) { foreach ($rez['items'] as $key => $item) { $name_item = 'rpd_fos_'.$item['id']; $cache_item = $this->cache_item($name_item,'','is'); //echo $name_item.':'.$cache_item.'
'.print_r($lists,1).''; exit(); $this->cache_item($name_item,$doc['html']); //$out .= $doc['html']; //$this->saveFOS_inFile($doc['html']); }else{ // //$out .= $cache_item; // //$doc['html'] = $this->prepare_html2word($doc['html'],''); // $this->saveFOS_inFile($cache_item); } $lists[] = array('file'=>$name_item,'name'=>$item['name'],'shifr'=> $item['shifr'],'program'=> $item['program'],'naprav'=> $item['naprav'],'god_nach_podgot'=> $item['god_nach_podgot'],'fo'=> $item['fo']); } } //$out = $this->prepare_html2word($out); //$this->cache($fc,$out); }else{ $out = $cache; } //$this->saveFOS_inFile('','download'); //$this->file_force_download('tmp/sFOS/'.$fc.'.html'); //$out['body'] = $smarty->fetch('page_library_check.html'); $out['body'] = '
'.print_r($lists,1).''; $out['body'] .= '
'.$v['shifr'].' '.$v['name'].' '.$v['fo'].' | '; $out['body'] .= ''.$v['naprav'].' | '; $out['body'] .= ''.$v['program'].' | '; $out['body'] .= ''.$v['god_nach_podgot'].' | '; $out['body'] .= 'Скачать | '; $out['body'] .= '