req->get('solicitud', '')); $solicitud = null; if ($idSolicitud === '') { throw new \yii\web\NotFoundHttpException("No se encontró la solicitud"); } $solicitud = Solicitud::find() ->andWhere(['id' => $idSolicitud]) ->andWhere(['eliminado' => null]) ->one(); if ($solicitud === null) { throw new \yii\web\NotFoundHttpException("No se encontró la solicitud"); } $request = \Yii::$app->request; $configuracion = [ 'mode' => 'utf-8', 'format' => 'letter', 'margin_top' => '50', ]; $view = new \yii\web\View(); $htmlPDF = $view->render("@app/modules/pdf/views/incompetencia-sujeto/oficio", [ "solicitud" => $solicitud, "recursoRevision" => [], ]); if ($request->get('header')) $header = $view->render("@app/modules/pdf/views/header/oficio-landing", [ "titulo" => "ACUSE DE SOLICITUD DE INFORMACIÓN PÚBLICA", ]); else $header = $view->render("@app/modules/pdf/views/header/oficio", [ "titulo" => "ACUSE DE SOLICITUD DE INFORMACIÓN PÚBLICA", ]); $pdf = self::crearPDF( 'AS-ISTAIAS-03', $htmlPDF, $configuracion, false, $header, '', '' ); } public function actionFormato() { //$request = \Yii::$app->request; $configuracion = [ 'mode' => 'utf-8', 'format' => 'letter', 'margin_top' => '36', ]; $view = new \yii\web\View(); $htmlPDF = $view->render("@app/modules/pdf/views/requerimiento-aclaracion/formato", [ "recursoRevision" => [], ]); $header = $view->render("@app/modules/pdf/views/header/formato", [ "titulo" => "ACUSE DE SOLICITUD DE INFORMACIÓN PÚBLICA", ]); $pdf = self::crearPDF( 'RA-ISTAIAS-02', $htmlPDF, $configuracion, false, $header, '', '' ); } public function actionOficio() { $request = \Yii::$app->request; $configuracion = [ 'mode' => 'utf-8', 'format' => 'letter', 'margin_top' => '50', ]; $view = new \yii\web\View(); $htmlPDF = $view->render("@app/modules/pdf/views/requerimiento-aclaracion/oficio", [ "recursoRevision" => [], ]); if ($request->get('header')) $header = $view->render("@app/modules/pdf/views/header/oficio-landing", [ "titulo" => "ACUSE DE SOLICITUD DE INFORMACIÓN PÚBLICA", ]); else $header = $view->render("@app/modules/pdf/views/header/oficio", [ "titulo" => "ACUSE DE SOLICITUD DE INFORMACIÓN PÚBLICA", ]); $pdf = self::crearPDF( 'AS-ISTAIAS-03', $htmlPDF, $configuracion, false, $header, '', '' ); } }