<?php
include_once("c_esmo_magnit_pdd.php");
class c_page_cab_esmo_magnit_pdd_upload_file extends c_page_cab_esmo_magnit_pdd
{
  public $h1='Прием направления по АГ' ;
  public $rec_mo=array() ;
  public $rec_personal=array() ;
  public $rec_mess=array() ;

 function block_main()
 { $this->page_title() ;
   $this->panel_file_upload() ;
   ?><br><br><?
   //$this->panel_mess_history() ;

 }

 function panel_file_upload()
 { include(_DIR_EXT.'/upload_files/panel_upload_files.php')  ;
   panel_upload_files(array('text'=>'Перетяните и отпустите сюда<br><br>скан направления',
                            'upload_url'=>'/cab/esmo_magnit/pdd/upload/napravlenie/json/',
                            'file_filter'=>'jpg;jpeg;pdf',
                            //'style_panel'=>'margin:0;',
                            'SendFormOnUploadSuccess'=>0,
                            'view_debug_panel'=>1,
                            'style_panel'=>'width:600px;margin:20px auto;',
           )) ;

    }

 function panel_card_personal_view()
 { include_once('panel_personal_info.php') ;
   ?><div id="panel_card_personal_view">
       <table class="cols3">
         <tr><td class="img"><img class="shadow main" src="<?echo img_clone($this->rec_personal,'200')?>">
                             <img class=qrcode src="/services/qrcode/<?echo $this->rec_personal['propusk']?>/" />
                             <?if (!$this->rec_personal['enabled']){?><div class="personal_fired">Уволен</div><?}
                  else if (is_member_right('personal_change_info')) {?><button class="v2 fa fa-pencil-square-o" cmd="aspmo_personal/get_panel_delete_personal" id="<?echo $this->rec_personal['pkey']?>">Удалить сотрудника</button><?}
                 ?>
             </td>
             <td class="info"><?panel_personal_info($this->rec_personal,array('button'=>array('change_info'=>1,'change_photo'=>1)));?></td>
         </tr>
       </table>
    </div>
  <?
 }

    function panel_mess_history()
    { include_once(_DIR_EXT.'/log/report_log_events.php') ;
      $report_obj=new report_log_events() ;
      $report_obj->filter['reffer']=$this->rec_mess['_reffer'];
      $report_obj->filter['order']='pkey';
      $report_obj->view_as_HTML() ;
    }




}



?>