示例#1
0
 public function getShow($id = null)
 {
     if ($this->access['is_detail'] == 0) {
         return Redirect::to('dashboard')->with('messagetext', \Lang::get('core.note_restric'))->with('msgstatus', 'error');
     }
     $row = $this->model->getRow($id);
     if ($row) {
         $this->data['row'] = $row;
     } else {
         $this->data['row'] = $this->model->getColumnTable('company_t');
     }
     $this->data['fields'] = \SiteHelpers::fieldLang($this->info['config']['grid']);
     $this->data['id'] = $id;
     $this->data['access'] = $this->access;
     return view('company.view', $this->data);
 }
示例#2
0
 /**
  * @param $id
  * @return mixed|string
  */
 public function getHtmlContent($id)
 {
     $row = $this->model->getRow($id);
     if ($row) {
         $this->data['row'] = $row;
     } else {
         $this->data['row'] = $this->model->getColumnTable('cabfactu');
     }
     $this->data['fields'] = \SiteHelpers::fieldLang($this->info['config']['grid']);
     $this->data['subgrid'] = $this->detailview($this->modelview, $this->data['subgrid'], $id);
     if ($this->data['row']->reducida) {
         $groups = $this->getGroupsInvoice();
         $this->data['groups'] = $groups;
     }
     $this->data['id'] = $id;
     $this->data['access'] = $this->access;
     $view = view('factura.pdf', $this->data)->render();
     $view = str_replace("http://localhost:8080/sximo51/public", public_path(), $view);
     return $view;
 }