avance: estado pre implementacion de notificaciones

This commit is contained in:
2025-01-06 21:22:58 -03:00
parent 5b3e65db2f
commit ed0d83dafe
14 changed files with 294 additions and 8 deletions
+9
View File
@@ -0,0 +1,9 @@
using System.Runtime.CompilerServices;
using Minio.Helper;
public abstract class Builder<T> where T:new() {
protected T data = new T();
public T Build() {
return data;
}
}
+40
View File
@@ -0,0 +1,40 @@
using System;
using Entidades;
public class NotificacioneBuilder : Builder<Notificacione>
{
public NotificacioneBuilder SetDnicliente(long dnicliente) {
data.Dnicliente = dnicliente;
return this;
}
public NotificacioneBuilder SetDniremitente(long dniremitente) {
data.Dniremitente = dniremitente;
return this;
}
public NotificacioneBuilder SetFecha(DateTime fecha) {
data.Fecha = fecha;
return this;
}
public NotificacioneBuilder SetMensaje(string mensaje) {
data.Mensaje = mensaje;
return this;
}
public NotificacioneBuilder SetAccion(string accion) {
data.Accion = accion;
return this;
}
public NotificacioneBuilder SetIdpropiedad(int idpropiedad) {
data.Idpropiedad = idpropiedad;
return this;
}
public NotificacioneBuilder SetLeido(bool leido) {
data.Leido = leido;
return this;
}
}
+30
View File
@@ -0,0 +1,30 @@
namespace AlquilaFacil.Builder;
using Entidades.Dto;
public class NotificacionDtoBuilder: Builder<NotificacionDto> {
public NotificacionDtoBuilder SetRemitente(string remitente) {
data.Remitente = remitente;
return this;
}
public NotificacionDtoBuilder SetAccion(string accion) {
data.Accion = accion;
return this;
}
public NotificacionDtoBuilder SetMensaje(string mensaje) {
data.Mensaje = mensaje;
return this;
}
public NotificacionDtoBuilder SetFecha(DateTime? fecha) {
data.Fecha = fecha;
return this;
}
public NotificacionDtoBuilder SetPropiedad(string propiedad) {
data.Propiedad = propiedad;
return this;
}
}