Agregar, editar y borrar comentarios
This commit is contained in:
@ -3,9 +3,11 @@ namespace Incoviba\Model\Venta;
|
||||
|
||||
use DateTimeInterface;
|
||||
use Incoviba\Common\Ideal;
|
||||
use Incoviba\Model\Venta;
|
||||
|
||||
class Comentario extends Ideal\Model
|
||||
{
|
||||
public Venta $venta;
|
||||
public DateTimeInterface $fecha;
|
||||
public string $texto;
|
||||
public bool $activo;
|
||||
@ -13,6 +15,7 @@ class Comentario extends Ideal\Model
|
||||
public function jsonSerialize(): mixed
|
||||
{
|
||||
return array_merge(parent::jsonSerialize(), [
|
||||
'venta_id' => $this->venta->id,
|
||||
'fecha' => $this->fecha->format('Y-m-d'),
|
||||
'texto' => $this->texto,
|
||||
'activo' => $this->activo
|
||||
|
Reference in New Issue
Block a user