Class app\components\Utilidad

Inheritanceapp\components\Utilidad

Public Methods

Hide inherited methods

MethodDescriptionDefined By
borrarImgS3() Borra la imagen alojada en el bucket de aws app\components\Utilidad
borrarPdfS3() Borra el fichero alojado en el bucket de aws app\components\Utilidad
botonResponder() app\components\Utilidad
existeComentario() Función para comprobar si el usuario ya ha comentado un recurso app\components\Utilidad
formatoFecha() app\components\Utilidad
getImg() Devuelve la url de la imagen almacenada en el bucket app\components\Utilidad
getPdf() Devuelve la url del pdf almacenado en el bucket app\components\Utilidad
mostrarPdf() app\components\Utilidad
mostrarRespuesta() Función para mostrar la respuesta a un comentario app\components\Utilidad
s3Eliminar() Elimina un recurso de Amazon S3 app\components\Utilidad
subirImgS3() Sube la imagen a AWS S3 app\components\Utilidad
subirPdfS3() Sube el fichero pdf a AWS S3 app\components\Utilidad

Method Details

borrarImgS3() public static method

Borra la imagen alojada en el bucket de aws

public static void borrarImgS3 ( $imagen )
$imagen
borrarPdfS3() public static method

Borra el fichero alojado en el bucket de aws

public static void borrarPdfS3 ( $pdf_pdf )
$pdf_pdf
botonResponder() public static method

public static void botonResponder ( $receptor, $emisor, $recurso_id )
$receptor
$emisor
$recurso_id
existeComentario() public static method

Función para comprobar si el usuario ya ha comentado un recurso

public static void existeComentario ( $id, $usuarioId )
$id
$usuarioId
formatoFecha() public static method

public static void formatoFecha ( $dt )
$dt
getImg() public static method

Devuelve la url de la imagen almacenada en el bucket

public static string getImg ( $img )
$img string
return string

$imagen

getPdf() public static method

Devuelve la url del pdf almacenado en el bucket

public static string getPdf ( $pdf )
$pdf string
return string

$pdfPdf

mostrarPdf() public static method

public static void mostrarPdf ( $pdf_pdf )
$pdf_pdf
mostrarRespuesta() public static method

Función para mostrar la respuesta a un comentario

public static void mostrarRespuesta ( $comentario_id )
$comentario_id
s3Eliminar() public static method

Elimina un recurso de Amazon S3

public static void s3Eliminar ( $key, $bucketName )
$key \app\components\[type]
$bucketName \app\components\[type]
subirImgS3() public static method

Sube la imagen a AWS S3

public static string subirImgS3 ( $archivo, $titulo, $rutaImg )
$archivo \app\components\file
$titulo string
$rutaImg mixed
return string

$titulo

subirPdfS3() public static method

Sube el fichero pdf a AWS S3

public static string subirPdfS3 ( $archivo, $titulo, $rutaPdf )
$archivo \app\components\file
$titulo string
$rutaPdf mixed
return string

$titulo