feat: Define data models and set up DB connection with Dapper

This commit is contained in:
2025-07-01 11:10:28 -03:00
parent 76635a0da9
commit 656137f2bc
12 changed files with 121 additions and 34 deletions

View File

@@ -1,6 +0,0 @@
namespace Mercados.Core;
public class Class1
{
}

View File

@@ -0,0 +1,14 @@
namespace Mercados.Core.Entities
{
public class CotizacionBolsa
{
public long Id { get; set; }
public string Ticker { get; set; } = string.Empty; // "AAPL", "GGAL.BA", etc.
public string Mercado { get; set; } = string.Empty; // "EEUU" o "Local"
public decimal PrecioActual { get; set; }
public decimal Apertura { get; set; }
public decimal CierreAnterior { get; set; }
public decimal PorcentajeCambio { get; set; }
public DateTime FechaRegistro { get; set; }
}
}

View File

@@ -0,0 +1,18 @@
namespace Mercados.Core.Entities
{
public class CotizacionGanado
{
public long Id { get; set; }
public string Categoria { get; set; } = string.Empty;
public string Especificaciones { get; set; } = string.Empty;
public decimal Maximo { get; set; }
public decimal Minimo { get; set; }
public decimal Promedio { get; set; }
public decimal Mediano { get; set; }
public int Cabezas { get; set; }
public int KilosTotales { get; set; }
public int KilosPorCabeza { get; set; }
public decimal ImporteTotal { get; set; }
public DateTime FechaRegistro { get; set; }
}
}

View File

@@ -0,0 +1,12 @@
namespace Mercados.Core.Entities
{
public class CotizacionGrano
{
public long Id { get; set; }
public string Nombre { get; set; } = string.Empty; // "Soja", "Trigo", etc.
public decimal Precio { get; set; }
public decimal VariacionPrecio { get; set; }
public DateTime FechaOperacion { get; set; }
public DateTime FechaRegistro { get; set; }
}
}

View File

@@ -0,0 +1,10 @@
namespace Mercados.Core.Entities
{
public class FuenteDato
{
public long Id { get; set; }
public string Nombre { get; set; } = string.Empty; // "BCR", "Finnhub", "YahooFinance", "MercadoAgroganadero"
public DateTime UltimaEjecucionExitosa { get; set; }
public string? Url { get; set; }
}
}