- 2026-04-24 1.0.0.0 Primera versión estable

This commit is contained in:
2026-04-29 15:34:38 +02:00
parent 6a31fe40be
commit 7b0e488994
15 changed files with 37 additions and 52 deletions

View File

@@ -3,8 +3,6 @@ Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 18
VisualStudioVersion = 18.1.11312.151
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WSAsegasa", "WSAsegasa\WSAsegasa.csproj", "{C891F2E3-60D2-449F-962A-BF78F58C67D6}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "bdAsegasa", "bdAsegasa\bdAsegasa.csproj", "{E42D668E-CB26-498B-89AF-8A205528C4EF}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "APIFicheros", "APIFicheros\APIFicheros.csproj", "{729F814F-BBAF-A079-B0A1-D5890DA11543}"
@@ -21,10 +19,6 @@ Global
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{C891F2E3-60D2-449F-962A-BF78F58C67D6}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{C891F2E3-60D2-449F-962A-BF78F58C67D6}.Debug|Any CPU.Build.0 = Debug|Any CPU
{C891F2E3-60D2-449F-962A-BF78F58C67D6}.Release|Any CPU.ActiveCfg = Release|Any CPU
{C891F2E3-60D2-449F-962A-BF78F58C67D6}.Release|Any CPU.Build.0 = Release|Any CPU
{E42D668E-CB26-498B-89AF-8A205528C4EF}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{E42D668E-CB26-498B-89AF-8A205528C4EF}.Debug|Any CPU.Build.0 = Debug|Any CPU
{E42D668E-CB26-498B-89AF-8A205528C4EF}.Release|Any CPU.ActiveCfg = Release|Any CPU

View File

@@ -44,57 +44,33 @@ namespace Servicio_Gestion_Asegasa
if (sStackTrace != "")
Mensaje += Constants.vbCrLf + "|StackTrace: " + sStackTrace;
}
bdAsegasa.db.cuentascorreo? cta = null;
try
{
var bd = tscgestionasegasa.NuevoContexto(ProcesosConf.Conf.NombreConexionBD, true, false, true, "WSAsegasa");
cta = bd.cuentascorreo.First(x => x.Codigo == "DEFECTO");
}
catch
{
}
switch (Tipo)
{
case tsUtilidades.Enumeraciones.TipoLog.Fallo:
Mensaje = "Error WSAsegasa. " + " Enviado desde " + Environment.MachineName + ". Version:" + Assembly.GetEntryAssembly()?.GetName().Version + ". Mensaje: " + Mensaje;
Log.Fatal(Mensaje);
if (cta != null) {
tsUtilidades.TsNotificacionesClient.RegistrarAsync("Error en Servicio Gestion Asegasa", Mensaje, tsUtilidades.TsNotificacionesClient.TipoNotificacionEnum.ERROR);
}
Log.Fatal(Mensaje);
tsUtilidades.TsNotificacionesClient.RegistrarAsync("Error en Servicio Gestion Asegasa", Mensaje, tsUtilidades.TsNotificacionesClient.TipoNotificacionEnum.ERROR);
break;
case tsUtilidades.Enumeraciones.TipoLog.Advertencia:
Mensaje = "Advertencia WSAsegasa. " + " Enviado desde " + Environment.MachineName + ". Version:" + Assembly.GetEntryAssembly()?.GetName().Version + ". " + Mensaje;
Log.Warning(Mensaje);
if (cta != null) {
tsUtilidades.TsNotificacionesClient.RegistrarAsync("Advertencia en Servicio Gestion Asegasa", Mensaje, tsUtilidades.TsNotificacionesClient.TipoNotificacionEnum.ADVERTENCIA);
}
tsUtilidades.TsNotificacionesClient.RegistrarAsync("Advertencia en Servicio Gestion Asegasa", Mensaje, tsUtilidades.TsNotificacionesClient.TipoNotificacionEnum.ADVERTENCIA);
break;
case tsUtilidades.Enumeraciones.TipoLog.InicioServicio:
Mensaje = "Inicio WSAsegasa. " + " Enviado desde " + Environment.MachineName + ". Version:" + Assembly.GetEntryAssembly()?.GetName().Version + ". Mensaje: " + Mensaje;
Log.Information(Mensaje);
if (cta != null) {
tsUtilidades.TsNotificacionesClient.RegistrarAsync("Inicio Servicio Gestion Asegasa", Mensaje, tsUtilidades.TsNotificacionesClient.TipoNotificacionEnum.INFO);
}
tsUtilidades.TsNotificacionesClient.RegistrarAsync("Inicio Servicio Gestion Asegasa", Mensaje, tsUtilidades.TsNotificacionesClient.TipoNotificacionEnum.INFO);
break;
case tsUtilidades.Enumeraciones.TipoLog.FinServicio:
Mensaje = "Finalización WSAsegasa. " + " Enviado desde " + Environment.MachineName + ". Version:" + Assembly.GetEntryAssembly()?.GetName().Version + ". Mensaje: " + Mensaje;
Log.Information(Mensaje);
if (cta != null) {
tsUtilidades.TsNotificacionesClient.RegistrarAsync("Finalización Servicio Gestion Asegasa", Mensaje, tsUtilidades.TsNotificacionesClient.TipoNotificacionEnum.INFO);
}
tsUtilidades.TsNotificacionesClient.RegistrarAsync("Finalización Servicio Gestion Asegasa", Mensaje, tsUtilidades.TsNotificacionesClient.TipoNotificacionEnum.INFO);
break;
default:
Mensaje = Tipo.ToString() + " WSAsegasa. " + " Enviado desde " + Environment.MachineName + ". Version:" + Assembly.GetEntryAssembly()?.GetName().Version + ". " + Mensaje;
Log.Information(Mensaje);
break;
}
}
catch (Exception ex)
{

View File

@@ -104,7 +104,7 @@ namespace Servicio_Gestion_Asegasa.Procesos
catch (Exception ex)
{
ServicioSMSSuspendido = true;
await tsUtilidades.TsNotificacionesClient.RegistrarAsync("SERVICIO SMS SUSPENDIDO", ex.Message, TsNotificacionesClient.TipoNotificacionEnum.ERROR);
await Logs.AñadeLogAsync(tsUtilidades.Enumeraciones.TipoLog.Fallo, ex.Message, ex);
}
}
@@ -112,7 +112,7 @@ namespace Servicio_Gestion_Asegasa.Procesos
}
catch (Exception ex)
{
await tsUtilidades.TsNotificacionesClient.RegistrarAsync("Error", ex.Message, TsNotificacionesClient.TipoNotificacionEnum.ERROR);
await Logs.AñadeLogAsync(tsUtilidades.Enumeraciones.TipoLog.Fallo, ex.Message, ex);
}
}
}

View File

@@ -40,7 +40,7 @@ namespace Servicio_Gestion_Asegasa
catch (Exception ex)
{
Debug.WriteLine(@"Procesar: EXCEPCIÓN: " + ex.Message + " " + ex.StackTrace);
await Logs.AñadeLogAsync(tsUtilidades.Enumeraciones.TipoLog.Fallo, ex.Message,ex);
}
finally
{

View File

@@ -1,11 +1,14 @@
using Servicio_Gestion_Asegasa;
using Microsoft.Extensions.Hosting;
var builder = Host.CreateApplicationBuilder(args);
builder.Services.AddHostedService<Worker>();
builder.Services.Configure<Configuracion>(
builder.Configuration.GetSection("Configuracion"));
builder.Services.AddWindowsService(); // <-- NECESARIO EN .NET 8
var host = builder.Build();
host.Run();

View File

@@ -2,7 +2,11 @@
<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<Nullable>enable</Nullable>
<AssemblyVersion>1.0.0.0</AssemblyVersion>
<PackageReleaseNotes>
- 2026-04-24 1.0.0.0 Primera versión estable
</PackageReleaseNotes>
<Nullable>enable</Nullable>
<ImplicitUsings>enable</ImplicitUsings>
<UserSecretsId>dotnet-Servicio_Gestion_Asegasa-408b0288-12a3-42df-8545-97be3626a4a9</UserSecretsId>
<RootNamespace>Servicio_Gestion_Asegasa</RootNamespace>
@@ -10,10 +14,11 @@
<ItemGroup>
<PackageReference Include="Microsoft.Extensions.Hosting" Version="8.0.1" />
<PackageReference Include="Microsoft.Extensions.Hosting.WindowsServices" Version="8.0.1" />
<PackageReference Include="Quartz" Version="3.15.0" />
<PackageReference Include="Serilog.Extensions.Hosting" Version="9.0.0" />
<PackageReference Include="Serilog.Sinks.File" Version="7.0.0" />
<PackageReference Include="tsUtilidades" Version="1.1.10" />
<PackageReference Include="tsUtilidades" Version="1.1.14" />
</ItemGroup>
<ItemGroup>

View File

@@ -2,7 +2,7 @@
"Configuracion": {
"SegundosMinimosEntreProcesos": "60",
"HoraProcesosDiarios": "06:30",
"NombreConexionBD": "Producción Remoto"
"NombreConexionBD": "Producción"
},
"Logging": {
"LogLevel": {
@@ -12,8 +12,9 @@
},
"TsNotificaciones": {
//"ApiUrl": "http://192.168.41.32:5000/", prod
"ApiUrl": "https://catcher.tecnosis.online",
"IdAplicacion": 2,
"ApiKey": "0a47a1eada0143278b9d4de4e8911100"
"ApiUrl": "https://apinotificaciones.tecnosis.online",
"IdAplicacion": 12,
"Aplicacion": "Servicio Asegasa",
"ApiKey": "33357e95a8384ac99f7fa1d66b0033f3"
}
}

View File

@@ -21,7 +21,7 @@ namespace bdAsegasa.db
public int? idRecibo { get; set; }
public DateOnly FechaInicioAmortizacion { get; set; }
public DateOnly FechaFinAmortizacion { get; set; }
public double PorcentajeAnual { get; set; }
public double? PorcentajeAnual { get; set; }
public DateOnly? FechaBaja { get; set; }
public int? idMotivoBaja { get; set; }
public int idEmpresa { get; set; }

View File

@@ -1,4 +1,5 @@
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
namespace bdAsegasa.db
@@ -22,6 +23,7 @@ namespace bdAsegasa.db
}
}
[NotMapped]
public int? ValorEntero1
{
get

View File

@@ -16,7 +16,7 @@
<PackageReference Include="Pomelo.EntityFrameworkCore.MySql" Version="8.0.3" />
<PackageReference Include="PropertyChanged.Fody" Version="4.1.0" />
<PackageReference Include="tsEFCore8" Version="1.0.5" />
<PackageReference Include="tsUtilidades" Version="1.1.10" />
<PackageReference Include="tsUtilidades" Version="1.1.14" />
</ItemGroup>
<ItemGroup>

View File

@@ -15,7 +15,7 @@ public partial class amortizacionrecibos
public DateOnly FechaFinAmortizacion { get; set; }
public double PorcentajeAnual { get; set; }
public double? PorcentajeAnual { get; set; }
public DateOnly? FechaBaja { get; set; }

View File

@@ -39,5 +39,7 @@ public partial class pagostelematicos
public string? Telefono { get; set; }
public int TipoPago { get; set; }
public virtual recibos? idReciboNavigation { get; set; }
}

View File

@@ -3618,6 +3618,7 @@ public partial class gestionasegasaContext : DbContext
entity.Property(e => e.Referencia).HasMaxLength(100);
entity.Property(e => e.RespuestaPasarela).HasMaxLength(4096);
entity.Property(e => e.Telefono).HasMaxLength(20);
entity.Property(e => e.TipoPago).HasColumnType("int(11)");
entity.Property(e => e.idEmailAvisoAPagador).HasColumnType("int(11)");
entity.Property(e => e.idEmailAvisoContabilidad).HasColumnType("int(11)");
entity.Property(e => e.idRecibo).HasColumnType("int(11)");

View File

@@ -5,7 +5,7 @@
"FilterSchemas": false,
"IncludeConnectionString": false,
"IrregularWords": null,
"MinimumProductVersion": "2.6.1248",
"MinimumProductVersion": "2.6.1382",
"ModelNamespace": null,
"OutputContextPath": "dbcontext",
"OutputPath": "db",
@@ -817,5 +817,6 @@
"UseSchemaNamespaces": false,
"UseSpatial": false,
"UseT4": true,
"UseT4Split": false
"UseT4Split": false,
"UseTypedTvpParameters": true
}

View File

@@ -9,6 +9,6 @@
<PackageReference Include="System.ServiceModel.Http" Version="8.*" />
<PackageReference Include="System.ServiceModel.NetTcp" Version="8.*" />
<PackageReference Include="System.ServiceModel.Primitives" Version="8.*" />
<PackageReference Include="tsUtilidades" Version="1.1.10" />
<PackageReference Include="tsUtilidades" Version="1.1.14" />
</ItemGroup>
</Project>