Compare commits

...

12 Commits

Author SHA1 Message Date
Gerardo 8bf7b188ab (firmas-e)Firmas electronicas
correcciones modelo
2023-08-04 00:35:27 +02:00
Gerardo d70a212443 (firmas-e)Firmas electronicas
desarrollo de modelo interno y listado
2023-08-03 22:36:18 +02:00
Gerardo 68c0c1baf0 correccion sintaxis 2023-08-03 13:39:20 +02:00
Gerardo e07edb65f4 Merge branch 'factura-e/firmas-e' into factura-e/firmas-e-modelo 2023-08-03 13:37:55 +02:00
Gerardo 3cb6211105 (firmas-e)Firmas electronicas
generacion de modelo entityframework
2023-08-03 13:36:18 +02:00
Gerardo 06eca71b22 (firmas-e)Firmas electronicas
actualizacion de script bbdd
2023-08-03 12:29:31 +02:00
Gerardo d9a77d2672 modificacion diseño bbdd 2023-08-03 12:27:57 +02:00
Gerardo e21308ed69 (firmas-e)Firmas electronicas
script tabla firmas electronicas
2023-08-03 10:45:14 +02:00
Gerardo 2e13e8ff4e Merge branch 'develop' into factura-e/firmas-e 2023-08-03 10:17:46 +02:00
Gerardo 96d90cf3f0 (firmas-e)Firmas electronicas
creaccion opcion en menu para ver firmas digitales
2023-08-03 10:11:26 +02:00
Gerardo 863f6aacfd factura- (rutas-r-e) script de actualizacion y defines 2023-08-02 13:59:31 +02:00
Gerardo 930725abc4 Error compilado exferia ventas 2023-08-02 12:58:15 +02:00
18 changed files with 1226 additions and 18 deletions

View File

@ -337,7 +337,7 @@
<Compile Include="Modelos_Volcado\INTERNO_PER_NominasPagos_Volcado_Modelo.cs" />
<Compile Include="Modelos_Volcado\INTERNO_PER_Nominas_Volcado_Modelo.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="Properties\Resources.Designer.cs">
<Compile Include="Properties\Resources.Designer.cs">
<AutoGen>True</AutoGen>
<DesignTime>True</DesignTime>
<DependentUpon>Resources.resx</DependentUpon>
@ -835,6 +835,9 @@
<Content Include="Resources\i_pdfFile.png" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<PropertyGroup>
<PostBuildEvent>copy $(TargetPath) $(SolutionDir)..\..\DLL\</PostBuildEvent>
</PropertyGroup>
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">

View File

@ -1524,6 +1524,7 @@ namespace Exferia_Aplicacion.General
public static string G_STR_OPCION_GEN_CAMBIARCLIENTE = "GEN_CAMBIARCLIENTE";
public static string G_STR_OPCION_GEN_CONEXION = "GEN_CONEXION";
public static string G_STR_OPCION_GEN_CONFIGURACION_INFORMES = "GEN_CONFIGURACION_INFORMES";
public static string G_STR_OPCION_GEN_FIRMAS_ELECTRONICAS = "GEN_FIRMAS_ELECTRONICAS";
public static string G_STR_OPCION_GEN_CONFIGURACIONEMAIL = "GEN_CONFIGURACIONEMAIL";
public static string G_STR_OPCION_GEN_CONFIGURACION_SW_SIGMA = "GEN_CONFIGURACION_SW_SIGMA";
public static string G_STR_OPCION_GEN_CONFIGURACIONESQUEMA_MENU = "GEN_CONFIGURACIONESQUEMA_MENU";
@ -2112,6 +2113,8 @@ namespace Exferia_Aplicacion.General
public static long G_LNG_RUTA_CARTASNOTIFICACIONTASAANUAL = 13;
public static long G_LNG_RUTA_Modelo347 = 14;
public static long G_LNG_RUTA_FACTURA_E_IN = 15;
public static long G_LNG_RUTA__FACTURA_E_OUT = 16;
public static List<INF_Rutas> G_LST_RUTAS = null;

View File

@ -0,0 +1,2 @@
<?xml version="1.0" encoding="utf-8"?>
<ClassDiagram />

View File

@ -1,10 +1,10 @@
// La generación de código T4 está habilitada para el modelo 'C:\Proyectos\Visual Studio 2015\Projects\Exferia_Librerias_Proyectos\Exferia_EntityFramework\Exferia_EntityFramework\EF_BaseDatos.edmx'.
// Para habilitar la generación de código heredada, cambie el valor de la propiedad del diseñador 'Estrategia de generación de código'
// por 'ObjectContext heredado'. Esta propiedad está disponible en la ventana Propiedades cuando se abre
// el modelo en el diseñador.
// T4 code generation is enabled for model 'D:\desa\Exferia\Exferia\Exferia_EntityFramework\Exferia_EntityFramework\EF_BaseDatos.edmx'.
// To enable legacy code generation, change the value of the 'Code Generation Strategy' designer
// property to 'Legacy ObjectContext'. This property is available in the Properties Window when the model
// is open in the designer.
// Si no se ha generado ninguna clase de contexto y de entidad, puede que haya creado un modelo vacío pero
// no haya elegido todavía la versión de Entity Framework que se va a usar. Para generar una clase de contexto y clases de entidad
// para el modelo, abra el modelo en el diseñador, haga clic con el botón secundario en la superficie del diseñador y
// seleccione 'Actualizar modelo desde base de datos...', 'Generar base de datos desde modelo...' o 'Agregar elemento de generación
// de código...'.
// If no context and entity classes have been generated, it may be because you created an empty model but
// have not yet chosen which version of Entity Framework to use. To generate a context class and entity
// classes for your model, open the model in the designer, right-click on the designer surface, and
// select 'Update Model from Database...', 'Generate Database from Model...', or 'Add Code Generation
// Item...'.

View File

@ -2006,6 +2006,17 @@
<Property Name="opcion" Type="varchar" MaxLength="100" Nullable="false" />
<Property Name="nombreCampoCodigo" Type="varchar" MaxLength="50" Nullable="false" />
</EntityType>
<EntityType Name="GEN_Firmas_Electronicas">
<Key>
<PropertyRef Name="id" />
</Key>
<Property Name="id" Type="bigint" StoreGeneratedPattern="Identity" Nullable="false" />
<Property Name="codigo" Type="varchar" MaxLength="10" Nullable="false" />
<Property Name="descripcion" Type="varchar" MaxLength="50" Nullable="false" />
<Property Name="fecha_fin" Type="datetime" />
<Property Name="idEmpresa" Type="bigint" Nullable="false"/>
<Property Name="text_perm" Type="text"/>
</EntityType>
<EntityType Name="GEN_Configuracion_Informes">
<Key>
<PropertyRef Name="id" />
@ -12451,7 +12462,19 @@
</Dependent>
</ReferentialConstraint>
</Association>
<Association Name="FK_GEN_Control_GEN_PerfilesFuncionalidad">
<Association Name="FK_GEN_Firmas_Electronicas_GEN_Empresas">
<End Role="GEN_Empresas" Type="Self.GEN_Empresas" Multiplicity="1" />
<End Role="GEN_Firmas_Electronicas" Type="Self.GEN_Firmas_Electronicas" Multiplicity="*" />
<ReferentialConstraint>
<Principal Role="GEN_Empresas">
<PropertyRef Name="id" />
</Principal>
<Dependent Role="GEN_Firmas_Electronicas">
<PropertyRef Name="idEmpresa" />
</Dependent>
</ReferentialConstraint>
</Association>
<Association Name="FK_GEN_Control_GEN_PerfilesFuncionalidad">
<End Role="GEN_PerfilesFuncionalidad" Type="Self.GEN_PerfilesFuncionalidad" Multiplicity="1" />
<End Role="GEN_Control" Type="Self.GEN_Control" Multiplicity="*" />
<ReferentialConstraint>
@ -26653,6 +26676,7 @@
<EntitySet Name="GEN_Almacenes" EntityType="Self.GEN_Almacenes" Schema="dbo" store:Type="Tables" />
<EntitySet Name="GEN_Configuracion_CampoCodigo" EntityType="Self.GEN_Configuracion_CampoCodigo" Schema="dbo" store:Type="Tables" />
<EntitySet Name="GEN_Configuracion_Informes" EntityType="Self.GEN_Configuracion_Informes" Schema="dbo" store:Type="Tables" />
<EntitySet Name="GEN_Firmas_Electronicas" EntityType="Self.GEN_Firmas_Electronicas" Schema="dbo" store:Type="Tables" />
<EntitySet Name="GEN_Configuracion_SW_Sigma" EntityType="Self.GEN_Configuracion_SW_Sigma" Schema="dbo" store:Type="Tables" />
<EntitySet Name="GEN_ConfiguracionesEmails" EntityType="Self.GEN_ConfiguracionesEmails" Schema="dbo" store:Type="Tables" />
<EntitySet Name="GEN_Control" EntityType="Self.GEN_Control" Schema="dbo" store:Type="Tables" />
@ -28478,6 +28502,10 @@
<End Role="GEN_EjerciciosActivos_Empresa" EntitySet="GEN_EjerciciosActivos_Empresa" />
<End Role="GEN_Configuracion_Informes" EntitySet="GEN_Configuracion_Informes" />
</AssociationSet>
<AssociationSet Name="FK_GEN_Firmas_Electronicas_GEN_Empresas" Association="Self.FK_GEN_Firmas_Electronicas_GEN_Empresas">
<End Role="GEN_Empresas" EntitySet="GEN_Empresas" />
<End Role="GEN_Firmas_Electronicas" EntitySet="GEN_Firmas_Electronicas" />
</AssociationSet>
<AssociationSet Name="FK_GEN_Control_GEN_PerfilesFuncionalidad" Association="Self.FK_GEN_Control_GEN_PerfilesFuncionalidad">
<End Role="GEN_PerfilesFuncionalidad" EntitySet="GEN_PerfilesFuncionalidad" />
<End Role="GEN_Control" EntitySet="GEN_Control" />
@ -37372,6 +37400,7 @@
<End Role="EPD_Procedimientos" EntitySet="EPD_Procedimientos" />
</AssociationSet>
<EntitySet Name="GEN_Configuracion_Informes" EntityType="SigmaERP2017Model.GEN_Configuracion_Informes" />
<EntitySet Name="GEN_Firmas_Electronicas" EntityType="SigmaERP2017Model.GEN_Firmas_Electronicas" />
<EntitySet Name="MYT_Configuracion_Informes" EntityType="SigmaERP2017Model.MYT_Configuracion_Informes" />
<EntitySet Name="CTA_DiarioCabecera" EntityType="SigmaERP2017Model.CTA_DiarioCabecera" />
<AssociationSet Name="FK_CTA_DiarioCabecera_CTA_PredefinidosFicheros" Association="SigmaERP2017Model.FK_CTA_DiarioCabecera_CTA_PredefinidosFicheros">
@ -38793,6 +38822,10 @@
<AssociationSet Name="FK_GEN_Configuracion_Informes_GEN_EjerciciosActivos_Empresa" Association="SigmaERP2017Model.FK_GEN_Configuracion_Informes_GEN_EjerciciosActivos_Empresa">
<End Role="GEN_EjerciciosActivos_Empresa" EntitySet="GEN_EjerciciosActivos_Empresa" />
<End Role="GEN_Configuracion_Informes" EntitySet="GEN_Configuracion_Informes" />
</AssociationSet>
<AssociationSet Name="FK_GEN_Firmas_Electronicas_GEN_Empresas" Association="SigmaERP2017Model.FK_GEN_Firmas_Electronicas_GEN_Empresas">
<End Role="GEN_Empresas" EntitySet="GEN_Empresas" />
<End Role="GEN_Firmas_Electronicas" EntitySet="GEN_Firmas_Electronicas" />
</AssociationSet>
<AssociationSet Name="FK_GEN_EjerciciosActivos_Empresa_GEN_Empresas" Association="SigmaERP2017Model.FK_GEN_EjerciciosActivos_Empresa_GEN_Empresas">
<End Role="GEN_Empresas" EntitySet="GEN_Empresas" />
@ -50392,6 +50425,7 @@
<Property Name="fechaBorrado" Type="DateTime" Precision="3" />
<Property Name="NRBE" Type="String" MaxLength="20" FixedLength="false" Unicode="false" />
<Property Name="permiteCobrarAlbaran" Type="Boolean" />
<NavigationProperty Name="GEN_Firmas_Electronicas" Relationship="SigmaERP2017Model.FK_GEN_Firmas_Electronicas_GEN_Empresas" FromRole="GEN_Empresas" ToRole="GEN_Firmas_Electronicas" />
<NavigationProperty Name="CRM_ClientesPotenciales" Relationship="SigmaERP2017Model.FK_CRM_ClientesPotenciales_GEN_Empresas" FromRole="GEN_Empresas" ToRole="CRM_ClientesPotenciales" />
<NavigationProperty Name="CRM_Terminales" Relationship="SigmaERP2017Model.FK_CRM_Terminales_GEN_Empresas" FromRole="GEN_Empresas" ToRole="CRM_Terminales" />
<NavigationProperty Name="CTA_AmortizacionesCabecera" Relationship="SigmaERP2017Model.FK_CTA_AmortizacionesCabecera_GEN_Empresas" FromRole="GEN_Empresas" ToRole="CTA_AmortizacionesCabecera" />
@ -57030,6 +57064,18 @@
<Property Name="venta_Factura_Informe_TextoFinal" Type="String" MaxLength="Max" FixedLength="false" Unicode="false" />
<NavigationProperty Name="GEN_EjerciciosActivos_Empresa" Relationship="SigmaERP2017Model.FK_GEN_Configuracion_Informes_GEN_EjerciciosActivos_Empresa" FromRole="GEN_Configuracion_Informes" ToRole="GEN_EjerciciosActivos_Empresa" />
</EntityType>
<EntityType Name="GEN_Firmas_Electronicas">
<Key>
<PropertyRef Name="id" />
</Key>
<Property Name="id" Type="Int64" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
<Property Name="codigo" Type="String" Nullable="false" MaxLength="10" FixedLength="false" Unicode="false" />
<Property Name="descripcion" Type="String" Nullable="false" MaxLength="50" FixedLength="false" Unicode="false" />
<Property Name="idEmpresa" Type="Int64" Nullable="false" />
<Property Name="fecha_fin" Type="DateTime" Precision="3" />
<Property Name="text_perm" Type="String" MaxLength="Max" FixedLength="false" Unicode="false" />
<NavigationProperty Name="GEN_Empresas" Relationship="SigmaERP2017Model.FK_GEN_Firmas_Electronicas_GEN_Empresas" FromRole="GEN_Firmas_Electronicas" ToRole="GEN_Empresas" />
</EntityType>
<EntityType Name="MYT_Configuracion_Informes">
<Key>
<PropertyRef Name="id" />
@ -62995,6 +63041,18 @@
</Dependent>
</ReferentialConstraint>
</Association>
<Association Name="FK_GEN_Firmas_Electronicas_GEN_Empresas">
<End Type="SigmaERP2017Model.GEN_Empresas" Role="GEN_Empresas" Multiplicity="1" />
<End Type="SigmaERP2017Model.GEN_Firmas_Electronicas" Role="GEN_Firmas_Electronicas" Multiplicity="*" />
<ReferentialConstraint>
<Principal Role="GEN_Empresas">
<PropertyRef Name="id" />
</Principal>
<Dependent Role="GEN_Firmas_Electronicas">
<PropertyRef Name="idEmpresa" />
</Dependent>
</ReferentialConstraint>
</Association>
<Association Name="FK_GEN_EjerciciosActivos_Empresa_GEN_Empresas">
<End Type="SigmaERP2017Model.GEN_Empresas" Role="GEN_Empresas" Multiplicity="1" />
<End Type="SigmaERP2017Model.GEN_EjerciciosActivos_Empresa" Role="GEN_EjerciciosActivos_Empresa" Multiplicity="*" />
@ -74646,6 +74704,18 @@
</MappingFragment>
</EntityTypeMapping>
</EntitySetMapping>
<EntitySetMapping Name="GEN_Firmas_Electronicas">
<EntityTypeMapping TypeName="SigmaERP2017Model.GEN_Firmas_Electronicas">
<MappingFragment StoreEntitySet="GEN_Firmas_Electronicas">
<ScalarProperty Name="text_perm" ColumnName="text_perm" />
<ScalarProperty Name="idEmpresa" ColumnName="idEmpresa" />
<ScalarProperty Name="fecha_fin" ColumnName="fecha_fin" />
<ScalarProperty Name="descripcion" ColumnName="descripcion" />
<ScalarProperty Name="codigo" ColumnName="codigo" />
<ScalarProperty Name="id" ColumnName="id" />
</MappingFragment>
</EntityTypeMapping>
</EntitySetMapping>
<EntitySetMapping Name="MYT_Configuracion_Informes">
<EntityTypeMapping TypeName="SigmaERP2017Model.MYT_Configuracion_Informes">
<MappingFragment StoreEntitySet="MYT_Configuracion_Informes">

View File

@ -490,6 +490,9 @@
<Compile Include="GEN_FicherosASCII.cs">
<DependentUpon>EF_BaseDatos.tt</DependentUpon>
</Compile>
<Compile Include="GEN_Firmas_Electronicas.cs">
<DependentUpon>EF_BaseDatos.tt</DependentUpon>
</Compile>
<Compile Include="GEN_ImpuestosCabecera.cs">
<DependentUpon>EF_BaseDatos.tt</DependentUpon>
</Compile>
@ -1714,6 +1717,7 @@
<Compile Include="Script_Actualizacion\Scripts_Version_1419.cs" />
<Compile Include="Script_Actualizacion\Scripts_Version_1418.cs" />
<Compile Include="Script_Actualizacion\Scripts_Version_1417.cs" />
<Compile Include="Script_Actualizacion\Scripts_Version_1440.cs" />
<Compile Include="Script_Actualizacion\Versiones_EF.cs" />
<Compile Include="Script_Iniciales\Scripts_Iniciales.cs" />
<Compile Include="SGA_InventarioCabecera_TMP.cs">

View File

@ -1,9 +1,9 @@
//------------------------------------------------------------------------------
// <auto-generated>
// Este código se generó a partir de una plantilla.
// This code was generated from a template.
//
// Los cambios manuales en este archivo pueden causar un comportamiento inesperado de la aplicación.
// Los cambios manuales en este archivo se sobrescribirán si se regenera el código.
// Manual changes to this file may cause unexpected behavior in your application.
// Manual changes to this file will be overwritten if the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
@ -16,6 +16,7 @@ namespace Exferia_EntityFramework
{
public GEN_Empresas()
{
this.GEN_Firmas_Electronicas = new HashSet<GEN_Firmas_Electronicas>();
this.CRM_ClientesPotenciales = new HashSet<CRM_ClientesPotenciales>();
this.CRM_Terminales = new HashSet<CRM_Terminales>();
this.CTA_AmortizacionesCabecera = new HashSet<CTA_AmortizacionesCabecera>();
@ -193,6 +194,7 @@ namespace Exferia_EntityFramework
public string NRBE { get; set; }
public Nullable<bool> permiteCobrarAlbaran { get; set; }
public virtual ICollection<GEN_Firmas_Electronicas> GEN_Firmas_Electronicas { get; set; }
public virtual ICollection<CRM_ClientesPotenciales> CRM_ClientesPotenciales { get; set; }
public virtual ICollection<CRM_Terminales> CRM_Terminales { get; set; }
public virtual ICollection<CTA_AmortizacionesCabecera> CTA_AmortizacionesCabecera { get; set; }

View File

@ -0,0 +1,26 @@
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated from a template.
//
// Manual changes to this file may cause unexpected behavior in your application.
// Manual changes to this file will be overwritten if the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
namespace Exferia_EntityFramework
{
using System;
using System.Collections.Generic;
public partial class GEN_Firmas_Electronicas
{
public long id { get; set; }
public string codigo { get; set; }
public string descripcion { get; set; }
public long idEmpresa { get; set; }
public Nullable<System.DateTime> fecha_fin { get; set; }
public string text_perm { get; set; }
public virtual GEN_Empresas GEN_Empresas { get; set; }
}
}

View File

@ -0,0 +1,106 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Exferia_EntityFramework.Script_Actualizacion
{
class Scripts_Version_1440
{
public static Version G_VRS_VERSION = new Version("1.4.4.0");
public static long G_LNG_VERSION = 1437;
public static int G_INT_TIPO = 0;
public static string G_STR_SCRIPT =
//creaccion de rutas--------------------------------
$@"
IF (not exists
(
SELECT *
FROM INF_Rutas
WHERE id = 15
)
)
BEGIN
INSERT INTO INF_Rutas(id, codigo, descripcion, rutaFichero) VALUES (15, 15, 'Recepción de facturas electrónicas', 'C:\Pruebas\factura-e-recep')
END
IF (exists
(
SELECT *
FROM INFORMATION_SCHEMA.TABLES
WHERE TABLE_NAME = 'INF_Rutas'
)
) AND
(not exists
(
SELECT *
FROM INF_Rutas
WHERE id = 16
)
)
BEGIN
INSERT INTO INF_Rutas(id, codigo, descripcion, rutaFichero) VALUES (16, 16, 'Emisión de facturas electrónicas', 'C:\Pruebas\factura-e-emi')
END
"+
//CREAR TABLA GEN_Firmas_Electronicas---------------------------------------------------
" IF not exists " +
" ( " +
" SELECT * " +
" FROM INFORMATION_SCHEMA.TABLES " +
" WHERE TABLE_NAME = 'GEN_Firmas_Electronicas' " +
" ) " +
" BEGIN " +
" CREATE TABLE[dbo].[GEN_Firmas_Electronicas]" +
" (" +
" [id][bigint] IDENTITY(1,1) NOT NULL," +
" [codigo] [varchar](10) NOT NULL," +
" [descripcion] [varchar](50) NOT NULL," +
" [fecha_fin] [datetime] NOT NULL," +
" [idEmpresa] [bigint] NULL," +
" [text_perm][text] NULL," +
" CONSTRAINT[PK_GEN_Firmas_Electronicas] PRIMARY KEY CLUSTERED" +
" (" +
" [id] ASC" +
" )WITH(PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON[PRIMARY]" +
" ) ON[PRIMARY]" +
"ALTER TABLE [dbo].[GEN_Firmas_Electronicas] WITH CHECK ADD CONSTRAINT [FK_GEN_Firmas_Electronicas_GEN_Empresas] FOREIGN KEY([idEmpresa])"+
"REFERENCES [dbo].[GEN_Empresas] ([id])"+
" END "
+
//opciones firmas electronicas
$@" IF (not exists
(
SELECT*
FROM PRV_Opciones
WHERE opcion = 'GEN_FIRMAS_ELECTRONICAS'
)
)
BEGIN
INSERT into PRV_Opciones
(opcion, libreria, descripcionAMostrar, mostrable_Arbol, fechaCreacion)
VALUES
('GEN_FIRMAS_ELECTRONICAS', 'Exferia_General', 'Firmas electronicas',1, GETDATE())
END" +
" END " +
//opciones detalle firmas electronicas
$@" IF (not exists
(
SELECT*
FROM PRV_OpcionesDetalle
WHERE opcion = 'GEN_FIRMAS_ELECTRONICAS'
)
)
BEGIN
INSERT into PRV_OpcionesDetalle
(opcion, descripcion_TituloListado, descripcion_TituloMantenimiento, descripcion_Plural, descripcion_Singular)
VALUES
('GEN_FIRMAS_ELECTRONICAS', 'Firmas electronicas', 'Firmas electronicas', 'Firmas electronicas', 'Firmas electronicas')
END" +
" END "
;
}
}

View File

@ -0,0 +1,75 @@
using Exferia_Aplicacion.General;
using Exferia_EntityFramework;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Exferia_General._0_Modelos
{
public class INTERNO_GEN_Firmas_Electronicas_Listado_Modelo : GEN_Firmas_Electronicas
{
public INTERNO_GEN_Firmas_Electronicas_Listado_Modelo()
{ }
public long codigo_Long
{
get
{
long lng_Codigo = 0;
if (Funciones.IsNumeric(codigo))
{
lng_Codigo = long.Parse(codigo);
}
return lng_Codigo;
}
}
public string Empresa
{
get
{
try
{
if (GEN_Empresas != null)
return GEN_Empresas.descripcion;
}
catch
{
}
return DescripcionEmpresa;
}
}
public string DescripcionEmpresa { get; set; }
/*
//Ejercicio
public string Ejercicio_Codigo { get; set; }
public string Ejercicio_Descripcion { get; set; }
public DateTime? Ejercicio_FechaBorrado { get; set; }
public string Ejercicio
{
get
{
string str_Aux = "";
//Codigo
if (Ejercicio_Codigo != null && Ejercicio_Codigo.Trim().Length > 0)
{
str_Aux = "(" + Ejercicio_Codigo + ") ";
}
//Descripcion
if (Ejercicio_Descripcion != null && Ejercicio_Descripcion.Trim().Length > 0)
{
str_Aux += Ejercicio_Descripcion;
}
return str_Aux;
}
}*/
}
}

View File

@ -0,0 +1,653 @@
using Exferia_Aplicacion.General;
using Exferia_Aplicacion.Herencia.Capas;
using Exferia_EntityFramework;
using Exferia_General._0_Modelos;
using System;
using System.Collections.Generic;
using System.Data;
using System.Data.SqlClient;
using System.Linq;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using System.Transactions;
using static Exferia_Aplicacion.General.Enumerados;
namespace Exferia_General._1_Datos
{
public class GEN_Firmas_Electronicas_Datos : ABS_Datos
{
#region Listado
private List<INTERNO_GEN_Firmas_Electronicas_Listado_Modelo> g_lst_INTERNO_GEN_Firmas_Electronicas_Modelo = null;
public override List<dynamic> Obtener_Listado(long _lng_idEmpresaSeleccionada, long _lng_idEjercicioActual, List<string> _lst_CamposConRelacionABuscar, List<INTERNO_Filtro_OpcionPadre_Modelo> _lst_INTERNO_Filtro_OpcionPadre_Modelo, List<INTERNO_Filtro_Modelo> _lst_INTERNO_Filtro_Modelo)
{
Exferia_Entities obj_Exferia_Entities = null;
List<dynamic> lst_INF = null;
try
{
obj_Exferia_Entities = new Exferia_Entities();
obj_Exferia_Entities.Configuration.LazyLoadingEnabled = false;
// Consulta .....................................................
ConsultaRellenar_Listado(obj_Exferia_Entities, _lng_idEmpresaSeleccionada, _lng_idEjercicioActual, Datos_Generales.GEN_Empresas_Devolver_EmpresasCompartidas_SegunFichero(_lng_idEmpresaSeleccionada, typeof(GEN_Firmas_Electronicas).Name), _lst_CamposConRelacionABuscar, -1, null, _lst_INTERNO_Filtro_OpcionPadre_Modelo, _lst_INTERNO_Filtro_Modelo);
// ..............................................................
if ((g_lst_INTERNO_GEN_Firmas_Electronicas_Modelo != null) && (g_lst_INTERNO_GEN_Firmas_Electronicas_Modelo.Count() > 0))
{
lst_INF = g_lst_INTERNO_GEN_Firmas_Electronicas_Modelo.Cast<dynamic>().ToList();
}
}
catch (Control_Errores)
{
throw;
}
catch (Exception ex)
{
throw new Control_Errores("", ex, nameof(GEN_Firmas_Electronicas_Datos) + "/" + nameof(Obtener_Listado), true);
}
finally
{
obj_Exferia_Entities.Database.Connection.Close();
obj_Exferia_Entities.Dispose();
}
return lst_INF;
}
public override dynamic Obtener_RegistroListado(long _lng_idEmpresaSeleccionada, long _lng_idEjercicioActual, List<string> _lst_CamposConRelacionABuscar, List<INTERNO_Filtro_OpcionPadre_Modelo> _lst_INTERNO_Filtro_OpcionPadre_Modelo, List<INTERNO_Filtro_Modelo> _lst_INTERNO_Filtro_Modelo, long _lng_id, List<long> _lst_ids)
{
Exferia_Entities obj_Exferia_Entities = null;
dynamic dnm_INF = null;
try
{
obj_Exferia_Entities = new Exferia_Entities();
obj_Exferia_Entities.Configuration.LazyLoadingEnabled = false;
// Consulta .....................................................
ConsultaRellenar_Listado(obj_Exferia_Entities, _lng_idEmpresaSeleccionada, _lng_idEjercicioActual, Datos_Generales.GEN_Empresas_Devolver_EmpresasCompartidas_SegunFichero(_lng_idEmpresaSeleccionada, typeof(GEN_Firmas_Electronicas).Name), _lst_CamposConRelacionABuscar, _lng_id, _lst_ids, _lst_INTERNO_Filtro_OpcionPadre_Modelo, _lst_INTERNO_Filtro_Modelo);
// ..............................................................
if ((g_lst_INTERNO_GEN_Firmas_Electronicas_Modelo != null) && (g_lst_INTERNO_GEN_Firmas_Electronicas_Modelo.Count() > 0))
{
dnm_INF = g_lst_INTERNO_GEN_Firmas_Electronicas_Modelo.Cast<dynamic>().ToList();
}
}
catch (Control_Errores)
{
throw;
}
catch (Exception ex)
{
throw new Control_Errores("", ex, nameof(GEN_Firmas_Electronicas_Datos) + "/" + nameof(Obtener_RegistroListado), true);
}
finally
{
obj_Exferia_Entities.Database.Connection.Close();
obj_Exferia_Entities.Dispose();
}
return dnm_INF;
}
protected override void ConsultaRellenar_Listado(Exferia_Entities _obj_Exferia_Entities, long _lng_idEmpresaSeleccionada, long _lng_idEjercicioActual, List<long> _lst_idEmpresasRelacionas, List<string> _lst_CamposConRelacionABuscar, long _lng_id, List<long> _lst_ids, List<INTERNO_Filtro_OpcionPadre_Modelo> _lst_INTERNO_Filtro_OpcionPadre_Modelo, List<INTERNO_Filtro_Modelo> _lst_INTERNO_Filtro_Modelo)
{
try
{
string where = "";
if(_lng_idEmpresaSeleccionada>-1)
{
where=nameof(GEN_Firmas_Electronicas.idEmpresa) + "=@idEmpresa and ";
}
string str_SQL =
" SELECT " +
//GEN_Configuracion_Informes
"f."+nameof(INTERNO_GEN_Firmas_Electronicas_Listado_Modelo.id) + "," +
"f." + nameof(GEN_Firmas_Electronicas.codigo) +"," +
"f." + nameof(GEN_Firmas_Electronicas.descripcion) + "," +
"f." + nameof(GEN_Firmas_Electronicas.fecha_fin) + "," +
"f." + nameof(GEN_Firmas_Electronicas.idEmpresa) + ","+
"f." + nameof(GEN_Firmas_Electronicas.text_perm) + ","+
"e." + nameof(GEN_Firmas_Electronicas.descripcion) + " " + nameof(INTERNO_GEN_Firmas_Electronicas_Listado_Modelo.DescripcionEmpresa) +
" FROM " + nameof(GEN_Firmas_Electronicas) +" f inner join " + nameof(GEN_Empresas)+
" e on e." + nameof(GEN_Empresas.id) +"="+ nameof(GEN_Firmas_Electronicas.idEmpresa) +
" WHERE "+ where+ (_lng_id > -1 ? (nameof(GEN_Firmas_Electronicas.id) + "=@id") : "1 = 1");
//Parametros
object[] arr_Parametros = new object[]
{
new SqlParameter("@id", _lng_id),
new SqlParameter("@idEmpresa", _lng_idEmpresaSeleccionada)
};
//Rellenar el Modelo
g_lst_INTERNO_GEN_Firmas_Electronicas_Modelo = _obj_Exferia_Entities.Database.SqlQuery<INTERNO_GEN_Firmas_Electronicas_Listado_Modelo>(str_SQL, arr_Parametros).ToList();
}
catch (Control_Errores)
{
throw;
}
catch (Exception ex)
{
throw new Control_Errores("", ex, nameof(GEN_Firmas_Electronicas_Datos) + "/" + nameof(ConsultaRellenar_Listado), true);
}
}
#endregion
#region Listado Secundario
public override List<dynamic> Obtener_Listado_Secundario(long _lng_idEmpresaSeleccionada, long _lng_idEjercicioActual, List<string> _lst_CamposConRelacionABuscar, List<INTERNO_Filtro_OpcionPadre_Modelo> _lst_INTERNO_Filtro_OpcionPadre_Modelo, List<INTERNO_Filtro_Modelo> _lst_INTERNO_Filtro_Modelo)
{
return null;
}
public override dynamic Obtener_RegistroListado_Secundario(long _lng_idEmpresaSeleccionada, long _lng_idEjercicioActual, List<string> _lst_CamposConRelacionABuscar, List<INTERNO_Filtro_OpcionPadre_Modelo> _lst_INTERNO_Filtro_OpcionPadre_Modelo, List<INTERNO_Filtro_Modelo> _lst_INTERNO_Filtro_Modelo, long _lng_id, List<long> _lst_ids)
{
return null;
}
protected override void ConsultaRellenar_Listado_Secundario(Exferia_Entities _obj_Exferia_Entities, long _lng_idEmpresaSeleccionada, long _lng_idEjercicioActual, List<long> _lst_idEmpresasRelacionadas, List<string> _lst_CamposConRelacionABuscar, long _lng_id, List<long> _lst_ids, List<INTERNO_Filtro_OpcionPadre_Modelo> _lst_INTERNO_Filtro_OpcionPadre_Modelo, List<INTERNO_Filtro_Modelo> _lst_INTERNO_Filtro_Modelo)
{ }
#endregion
#region F3
public override dynamic Obtener_F3(string _str_filtro, string _str_CampoBusqueda, long _lng_idEmpresaSeleccionada, long _lng_idEjercicioActual, List<INTERNO_Filtro_OpcionPadre_Modelo> _lst_INTERNO_Filtro_OpcionPadre_Modelo, List<INTERNO_Filtro_Modelo> _lst_INTERNO_Filtro_Modelo)
{
throw new NotImplementedException();
}
public override dynamic Obtener_F3_PorId(long _lng_id, long _lng_idEmpresaSeleccionada, long _lng_idEjercicioActual, List<INTERNO_Filtro_OpcionPadre_Modelo> _lst_INTERNO_Filtro_OpcionPadre_Modelo, List<INTERNO_Filtro_Modelo> _lst_INTERNO_Filtro_Modelo)
{
throw new NotImplementedException();
}
protected override void ConsultaRellenar_F3(Exferia_Entities _obj_Exferia_Entities, long _lng_idEmpresaSeleccionada, long _lng_idEjercicioActual, List<long> _lst_idEmpresasRelacionadas, string _str_CampoBusqueda, string _str_Filtro, long _lng_id, List<INTERNO_Filtro_OpcionPadre_Modelo> _lst_INTERNO_Filtro_OpcionPadre_Modelo, List<INTERNO_Filtro_Modelo> _lst_INTERNO_Filtro_Modelo)
{ }
#endregion
#region Obtener
#region Obtener Simple
private dynamic g_dnm_Modelo_Obtener = null;
private static int g_int_TotalHilos_Obtener = 1;
private bool[] g_bol_Hilos_Terminados_Obtener = new bool[g_int_TotalHilos_Obtener];
public override dynamic Obtener(long _lng_id)
{
Exferia_Entities obj_Exferia_Entities = null;
try
{
obj_Exferia_Entities = new Exferia_Entities();
obj_Exferia_Entities.Configuration.LazyLoadingEnabled = false;
string str_SQL =
" SELECT " +
nameof(GEN_Firmas_Electronicas.id) + "," +
nameof(GEN_Firmas_Electronicas.codigo) + "," +
nameof(GEN_Firmas_Electronicas.descripcion) + "," +
nameof(GEN_Firmas_Electronicas.fecha_fin) + "," +
nameof(GEN_Firmas_Electronicas.text_perm) + "," +
nameof(GEN_Firmas_Electronicas.idEmpresa) +
" FROM " + nameof(GEN_Firmas_Electronicas) +
" WHERE " + nameof(GEN_Firmas_Electronicas.id) + "=@id ";
//Parametros
object[] arr_Parametros = new object[]
{
new SqlParameter("@id", _lng_id)
};
//Rellenar el Modelo
g_dnm_Modelo_Obtener = obj_Exferia_Entities.Database.SqlQuery<GEN_Firmas_Electronicas>(str_SQL, arr_Parametros).FirstOrDefault();
#region Rellenar tablas Relacionadas
if (g_dnm_Modelo_Obtener != null)
{
//reiniciar Valores de los hilos
for (int int_Contador = 0; int_Contador < g_int_TotalHilos_Obtener; int_Contador++)
{
g_bol_Hilos_Terminados_Obtener[int_Contador] = false;
}
//GEN_EjerciciosActivos_Empresa ##########################################################################################
ThreadStart obj_ThreadStart_EJERCICIO = new ThreadStart(Obtener_Ejercicio_Modelo_Obtener);
Thread obj_Thread_EJERCICIO = new Thread(obj_ThreadStart_EJERCICIO);
obj_Thread_EJERCICIO.Start();
//Esperando a que terminen todos los hilos .........................................
bool bol_Termino = false;
while (bol_Termino == false)
{
bol_Termino = true;
foreach (bool bol_Termino_Hilo in g_bol_Hilos_Terminados_Obtener)
{
if (bol_Termino_Hilo == false)
{
bol_Termino = false;
break;
}
}
Thread.Sleep(10);
}
//.................................................................................
}
#endregion
}
catch (Control_Errores)
{
throw;
}
catch (Exception ex)
{
throw new Control_Errores("", ex, nameof(GEN_Firmas_Electronicas) + "/" + nameof(Obtener), true);
}
finally
{
obj_Exferia_Entities.Database.Connection.Close();
obj_Exferia_Entities.Dispose();
}
return g_dnm_Modelo_Obtener;
}
#region Tablas Relacionadas
private void Obtener_Ejercicio_Modelo_Obtener()
{
try
{
g_dnm_Modelo_Obtener.GEN_EjerciciosActivos_Empresa = Datos_Generales.GEN_EjerciciosActivos_Empresa_Obtener_Por_Id(g_dnm_Modelo_Obtener.idEjercicio, false, false, false);
}
catch (Control_Errores)
{ }
finally
{
g_bol_Hilos_Terminados_Obtener[0] = true;
}
}
#endregion
#endregion
public override dynamic Obtener_Registro_PorCampo(string _str_Filtro, string _str_CampoBusqueda, long _lng_idEmpresaSeleccionada, long _lng_idEjercicioActual)
{
throw new NotImplementedException();
}
public List<dynamic> Obtener_Listado_Simple()
{
Exferia_Entities obj_Exferia_Entities = null;
List<dynamic> lst_INF = null;
try
{
obj_Exferia_Entities = new Exferia_Entities();
obj_Exferia_Entities.Configuration.LazyLoadingEnabled = false;
string str_SQL =
" SELECT " +
//GEN_Configuracion_Informes
"f." + nameof(INTERNO_GEN_Firmas_Electronicas_Listado_Modelo.id) + "," +
"f." + nameof(INTERNO_GEN_Firmas_Electronicas_Listado_Modelo.codigo) + "," +
"f." + nameof(INTERNO_GEN_Firmas_Electronicas_Listado_Modelo.descripcion) + "," +
"f." + nameof(INTERNO_GEN_Firmas_Electronicas_Listado_Modelo.fecha_fin) + "," +
"f." + nameof(INTERNO_GEN_Firmas_Electronicas_Listado_Modelo.text_perm) + ","+
"e." + nameof(INTERNO_GEN_Firmas_Electronicas_Listado_Modelo.idEmpresa) +
" FROM " + nameof(GEN_Firmas_Electronicas) + " f inner join " + nameof(GEN_Empresas) +
" e on e." + nameof(GEN_Empresas.id) + "=" + nameof(GEN_Firmas_Electronicas.idEmpresa);
//Rellenar el Modelo
List<INTERNO_GEN_Firmas_Electronicas_Listado_Modelo> lst_INTERNO_GEN_Configuracion_Informes_Listado_Modelo = obj_Exferia_Entities.Database.SqlQuery<INTERNO_GEN_Firmas_Electronicas_Listado_Modelo>(str_SQL, new object[] { }).ToList();
if ((lst_INTERNO_GEN_Configuracion_Informes_Listado_Modelo != null) && (lst_INTERNO_GEN_Configuracion_Informes_Listado_Modelo.Count() > 0))
{
lst_INF = lst_INTERNO_GEN_Configuracion_Informes_Listado_Modelo.Cast<dynamic>().ToList();
}
}
catch (Control_Errores)
{
throw;
}
catch (Exception ex)
{
throw new Control_Errores("", ex, nameof(GEN_Firmas_Electronicas_Datos) + "/" + nameof(Obtener_Listado_Simple), true);
}
finally
{
obj_Exferia_Entities.Database.Connection.Close();
obj_Exferia_Entities.Dispose();
}
return lst_INF;
}
#endregion
#region MODELOS
#region Modelo Simple
private GEN_Firmas_Electronicas g_mdl_GEN_Configuracion_Informes = null;
public GEN_Firmas_Electronicas Obtener_Modelo_Por_Id(long _lng_Id,
bool _bol_Cargar_Ejercicio)
{
try
{
string str_SQL = Obtener_Consulta_Modelo() +
//WHERE
" WHERE " +
nameof(GEN_Firmas_Electronicas) + "." + nameof(GEN_Firmas_Electronicas.id) + "=@id ";
//Parametros
object[] arr_Parametros = new object[]
{
new SqlParameter("@id", _lng_Id)
};
//Ejecutar y rellenar el modelo
Ejecutar_Consulta_Modelo(str_SQL,
arr_Parametros,
_bol_Cargar_Ejercicio);
}
catch (Control_Errores)
{
throw;
}
catch (Exception ex)
{
throw new Control_Errores("", ex, nameof(GEN_Firmas_Electronicas_Datos) + "/" + nameof(Obtener_Modelo_Por_Id), true);
}
return g_mdl_GEN_Configuracion_Informes;
}
/*
public GEN_Configuracion_Informes Obtener_Modelo_Por_IdEjercicio(long _lng_idEjercicio)
{
try
{
string str_SQL = Obtener_Consulta_Modelo() +
//WHERE
" WHERE " +
nameof(GEN_Firmas_Electronicas) + "." + nameof(GEN_Configuracion_Informes.idEjercicio) + "=@idEjercicio";
//Parametros
object[] arr_Parametros = new object[]
{
new SqlParameter("@idEjercicio", _lng_idEjercicio)
};
//Ejecutar y rellenar el modelo
Ejecutar_Consulta_Modelo(str_SQL,
arr_Parametros,
false);
}
catch (Control_Errores)
{
throw;
}
catch (Exception ex)
{
throw new Control_Errores("", ex, nameof(GEN_Configuracion_Informes_Datos) + "/" + nameof(Obtener_Modelo_Por_IdEjercicio), true);
}
return g_mdl_GEN_Configuracion_Informes;
}
*/
#region Ejecutar_Consulta_Modelo
private static int g_int_TotalHilos_Modelo = 1;
private bool[] g_bol_Hilos_Terminados_Modelo = new bool[g_int_TotalHilos_Modelo];
private void Ejecutar_Consulta_Modelo(string _str_SQL,
object[] _arr_Parametros,
bool _bol_Cargar_Ejercicio)
{
Exferia_Entities obj_Exferia_Entities = null;
try
{
//Conexion
obj_Exferia_Entities = new Exferia_Entities();
obj_Exferia_Entities.Configuration.LazyLoadingEnabled = false;
//Rellenar el Modelo
g_mdl_GEN_Configuracion_Informes = obj_Exferia_Entities.Database.SqlQuery<GEN_Firmas_Electronicas>(_str_SQL, _arr_Parametros).FirstOrDefault();
}
catch (Control_Errores)
{
throw;
}
catch (Exception ex)
{
throw new Control_Errores("", ex, nameof(GEN_Firmas_Electronicas_Datos) + "/" + nameof(Ejecutar_Consulta_Modelo), true);
}
finally
{
obj_Exferia_Entities.Database.Connection.Close();
obj_Exferia_Entities.Dispose();
}
}
#region Tablas Relacionadas
#endregion
#endregion
#endregion
#region ModeloListado
#endregion
private string Obtener_Consulta_Modelo()
{
return
" SELECT " +
nameof(GEN_Firmas_Electronicas.id) + "," +
nameof(GEN_Firmas_Electronicas.codigo) + "," +
nameof(GEN_Firmas_Electronicas.descripcion) + "," +
nameof(GEN_Firmas_Electronicas.idEmpresa) + "," +
nameof(GEN_Firmas_Electronicas.fecha_fin) + "," +
nameof(GEN_Firmas_Electronicas.text_perm) +
" FROM " + nameof(GEN_Firmas_Electronicas);
}
#endregion
#region Grabar
public override INTERNO_ValorDevuelto_Modelo Grabar(object _mdl_obj)
{
Exferia_Entities obj_Exferia_Entities = null;
INTERNO_ValorDevuelto_Modelo mdl_INTERNO_ValorDevuelto_Modelo = new INTERNO_ValorDevuelto_Modelo();
mdl_INTERNO_ValorDevuelto_Modelo.TodoCorrecto = true;
try
{
obj_Exferia_Entities = new Exferia_Entities();
obj_Exferia_Entities.Configuration.LazyLoadingEnabled = false;
GEN_Firmas_Electronicas mdl_GEN_Configuracion_Informes_AGrabar = (GEN_Firmas_Electronicas)_mdl_obj;
GEN_Firmas_Electronicas mdl_GEN_Configuracion_Informes_DatosViejos = new GEN_Firmas_Electronicas();
// Ver si existe ######################################################################
GEN_Firmas_Electronicas mdl_GEN_Configuracion_Informes_Final = Obtener_Modelo_Por_Id(mdl_GEN_Configuracion_Informes_AGrabar.id, false);
//######################################################################################
if (mdl_GEN_Configuracion_Informes_Final != null)
{
//Tipo de Accion que se va a realizar
mdl_INTERNO_ValorDevuelto_Modelo.TipoAccion = G_ENUM_TIPOACCION.INT_MODIFICAR;
//Datos viejos para la trazabilidad
Funciones.CopiarPropiedadesObjetos(mdl_GEN_Configuracion_Informes_Final, mdl_GEN_Configuracion_Informes_DatosViejos, false, false);
// Cargar los Datos Nuevos del Modelo
Funciones.CopiarPropiedadesObjetos(mdl_GEN_Configuracion_Informes_AGrabar, mdl_GEN_Configuracion_Informes_Final, false, false);
#region Update
string str_SQL_Update = " UPDATE " + nameof(GEN_Firmas_Electronicas) +
" SET " +
nameof(GEN_Firmas_Electronicas.codigo) + "=@codigo," +
nameof(GEN_Firmas_Electronicas.descripcion) + "=@descripcion," +
nameof(GEN_Firmas_Electronicas.idEmpresa) + "=@idEmpresa," +
nameof(GEN_Firmas_Electronicas.text_perm) + "=@text_perm," +
nameof(GEN_Firmas_Electronicas.fecha_fin) + "=@fecha_fin" +
" WHERE " +
nameof(GEN_Firmas_Electronicas.id) + "=@id";
//Parametros
SqlParameter obj_SqlParameter_imagen_Logo_SuperiorIzquierda = new SqlParameter("@imagen_Logo_SuperiorIzquierda", SqlDbType.Binary);
object[] arr_Parametros_Update = new object[]
{
new SqlParameter("@codigo", mdl_GEN_Configuracion_Informes_AGrabar.codigo),
new SqlParameter("@descripcion", mdl_GEN_Configuracion_Informes_AGrabar.descripcion),
new SqlParameter("@idEmpresa", mdl_GEN_Configuracion_Informes_AGrabar.idEmpresa),
new SqlParameter("@text_perm", mdl_GEN_Configuracion_Informes_AGrabar.text_perm),
new SqlParameter("@fecha_fin", mdl_GEN_Configuracion_Informes_AGrabar.fecha_fin),
new SqlParameter("@id", mdl_GEN_Configuracion_Informes_AGrabar.id)
};
#endregion
//Update
obj_Exferia_Entities.Database.ExecuteSqlCommand(str_SQL_Update, arr_Parametros_Update);
//Id de la tabla
mdl_INTERNO_ValorDevuelto_Modelo.Id = mdl_GEN_Configuracion_Informes_AGrabar.id;
}
else
{
mdl_GEN_Configuracion_Informes_Final = new GEN_Firmas_Electronicas();
//Tipo de Accion que se va a realizar
mdl_INTERNO_ValorDevuelto_Modelo.TipoAccion = G_ENUM_TIPOACCION.INT_INSERTAR;
// Cargar los Datos del Modelo
Funciones.CopiarPropiedadesObjetos(mdl_GEN_Configuracion_Informes_AGrabar, mdl_GEN_Configuracion_Informes_Final, false, false);
#region INSERT
string str_SQL_Insert = " INSERT INTO " + nameof(GEN_Firmas_Electronicas) +
" (" +
nameof(GEN_Firmas_Electronicas.codigo) + "," +
nameof(GEN_Firmas_Electronicas.descripcion) + "," +
nameof(GEN_Firmas_Electronicas.idEmpresa) + "," +
nameof(GEN_Firmas_Electronicas.text_perm) + "," +
nameof(GEN_Firmas_Electronicas.fecha_fin) +
" ) " +
" OUTPUT INSERTED." + nameof(GEN_Firmas_Electronicas.id) +
" VALUES " +
" ( " +
"@codigo," +
"@descripcion," +
"@idEmpresa," +
"@text_perm," +
"@fecha_fin," +
" ) ";
//Parametros
object[] arr_Parametros_Insert = new object[]
{
new SqlParameter("@codigo", mdl_GEN_Configuracion_Informes_AGrabar.codigo),
new SqlParameter("@descripcion", mdl_GEN_Configuracion_Informes_AGrabar.descripcion),
new SqlParameter("@idEmpresa", mdl_GEN_Configuracion_Informes_AGrabar.idEmpresa),
new SqlParameter("@text_perm", mdl_GEN_Configuracion_Informes_AGrabar.text_perm),
new SqlParameter("@fecha_fin", mdl_GEN_Configuracion_Informes_AGrabar.fecha_fin)
};
#endregion
//Id de la tabla
mdl_INTERNO_ValorDevuelto_Modelo.Id = obj_Exferia_Entities.Database.SqlQuery<long>(str_SQL_Insert, arr_Parametros_Insert).Single();
}
// Grabar un registro de trazabilidad con los datos de la transaccion realizada.
Datos_Generales.USR_Trazabilidad_Grabar(typeof(GEN_Firmas_Electronicas), mdl_GEN_Configuracion_Informes_DatosViejos, mdl_GEN_Configuracion_Informes_Final, mdl_INTERNO_ValorDevuelto_Modelo.TipoAccion, obj_Exferia_Entities);
}
catch (Control_Errores)
{
throw;
}
catch (Exception ex)
{
throw new Control_Errores("", ex, nameof(GEN_Firmas_Electronicas_Datos) + "/" + nameof(Grabar), true);
}
finally
{
obj_Exferia_Entities.Database.Connection.Close();
obj_Exferia_Entities.Dispose();
}
return mdl_INTERNO_ValorDevuelto_Modelo;
}
#endregion
#region Borrar
public override INTERNO_ValorDevuelto_Modelo Borrar(long _lng_id)
{
Exferia_Entities obj_Exferia_Entities = null;
INTERNO_ValorDevuelto_Modelo mdl_INTERNO_ValorDevuelto_Modelo = new INTERNO_ValorDevuelto_Modelo();
mdl_INTERNO_ValorDevuelto_Modelo.TodoCorrecto = true;
//Tipo de Accion que se va a realizar
mdl_INTERNO_ValorDevuelto_Modelo.TipoAccion = G_ENUM_TIPOACCION.INT_ELIMINAR;
try
{
obj_Exferia_Entities = new Exferia_Entities();
obj_Exferia_Entities.Configuration.LazyLoadingEnabled = false;
// Ver si existe ######################################################################
GEN_Firmas_Electronicas mdl_GEN_Firma_electronica_Final = Obtener_Modelo_Por_Id(_lng_id, false);
//######################################################################################
if (mdl_GEN_Firma_electronica_Final != null)
{
#region Delete
string str_SQL_Delete = " DELETE FROM " + nameof(GEN_Firmas_Electronicas) +
" WHERE " +
nameof(GEN_Firmas_Electronicas.id) + "=@id";
//Parametros
object[] arr_Parametros_Delete = new object[]
{
new SqlParameter("@id", _lng_id)
};
#endregion
//Update
obj_Exferia_Entities.Database.ExecuteSqlCommand(str_SQL_Delete, arr_Parametros_Delete);
// Grabar un registro de trazabilidad con los datos de la transaccion realizada.
Datos_Generales.USR_Trazabilidad_Grabar(typeof(GEN_Firmas_Electronicas), null, mdl_GEN_Firma_electronica_Final, G_ENUM_TIPOACCION.INT_ELIMINAR, obj_Exferia_Entities);
}
// Devolver también el Objeto
mdl_INTERNO_ValorDevuelto_Modelo.Id = _lng_id;
}
catch (Control_Errores)
{
throw;
}
catch (Exception ex)
{
throw new Control_Errores("", ex, nameof(GEN_Firmas_Electronicas_Datos) + "/" + nameof(Borrar), true);
}
finally
{
obj_Exferia_Entities.Database.Connection.Close();
obj_Exferia_Entities.Dispose();
}
return mdl_INTERNO_ValorDevuelto_Modelo;
}
public override INTERNO_ValorDevuelto_Modelo Borrar(long _lng_id, long _lng_idAuxiliar)
{
throw new NotImplementedException();
}
public override INTERNO_ValorDevuelto_Modelo Borrar(object _mdl_obj)
{
return null;
}
#endregion
}
}

View File

@ -0,0 +1,115 @@
using Exferia_Aplicacion.General;
using Exferia_Aplicacion.Modelos_Listado_Filtros;
using Exferia_EntityFramework;
using Exferia_General._0_Modelos;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using static Exferia_Aplicacion.General.Enumerados;
namespace Exferia_General._3_Vistas.Listados
{
public class ABS_Listado_GEN_Firmas_Electronicas : ABS_Listado
{
private Dictionary<string, INTERNO_ABS_Listado_ColumnasDatos_Modelo> g_dct_INTERNO_ABS_Listado_ColumnasDatos_Modelo = new Dictionary<string, INTERNO_ABS_Listado_ColumnasDatos_Modelo>();
//Constructor
public ABS_Listado_GEN_Firmas_Electronicas()
{
Rellenar_Columnas();
}
private void Rellenar_Columnas()
{
g_dct_INTERNO_ABS_Listado_ColumnasDatos_Modelo.Add(nameof(INTERNO_GEN_Firmas_Electronicas_Listado_Modelo.id), new INTERNO_ABS_Listado_ColumnasDatos_Modelo(true, nameof(INTERNO_GEN_Firmas_Electronicas_Listado_Modelo.id), "id", G_ENUM_TIPOSDATOS.LONG, true, 0, false, false, true, false, "", null));
g_dct_INTERNO_ABS_Listado_ColumnasDatos_Modelo.Add(nameof(INTERNO_GEN_Firmas_Electronicas_Listado_Modelo.codigo), new INTERNO_ABS_Listado_ColumnasDatos_Modelo(false, nameof(INTERNO_GEN_Firmas_Electronicas_Listado_Modelo.codigo), "Código", G_ENUM_TIPOSDATOS.LONG_TEXT, false, 90, true, true, true, false, "", null));
g_dct_INTERNO_ABS_Listado_ColumnasDatos_Modelo.Add(nameof(INTERNO_GEN_Firmas_Electronicas_Listado_Modelo.descripcion), new INTERNO_ABS_Listado_ColumnasDatos_Modelo(false, nameof(INTERNO_GEN_Firmas_Electronicas_Listado_Modelo.descripcion), "Descripción", G_ENUM_TIPOSDATOS.TEXT, false, 250, true, true, true, false, "", null));
//Empresa
g_dct_INTERNO_ABS_Listado_ColumnasDatos_Modelo.Add(nameof(INTERNO_GEN_Firmas_Electronicas_Listado_Modelo.Empresa), new INTERNO_ABS_Listado_ColumnasDatos_Modelo(false, nameof(INTERNO_GEN_Firmas_Electronicas_Listado_Modelo.Empresa), "Empresa", G_ENUM_TIPOSDATOS.TEXT, false, 250, true, true, true, false, "", null));
g_dct_INTERNO_ABS_Listado_ColumnasDatos_Modelo.Add(nameof(INTERNO_GEN_Firmas_Electronicas_Listado_Modelo.text_perm), new INTERNO_ABS_Listado_ColumnasDatos_Modelo(false, nameof(INTERNO_GEN_Firmas_Electronicas_Listado_Modelo.text_perm), "Text_perm", G_ENUM_TIPOSDATOS.TEXT, false, 250, true, true, true, false, "", null));
}
public override List<dynamic> LISTADO()
{
return Registros;
}
public override INTERNO_OpcionesDetalle_Modelo DATOS_OPCION()
{
return Datos_Generales.PRV_Opciones_Buscar_Detalles(Variables.G_STR_OPCION_GEN_FIRMAS_ELECTRONICAS);
}
public override string NOMBRELISTADO_ALMACENARCONFIGURACION()
{
return Variables.G_STR_OPCION_GEN_FIRMAS_ELECTRONICAS;
}
public override Dictionary<string, INTERNO_ABS_Listado_ColumnasDatos_Modelo> LISTADO_COLUMNAS()
{
return g_dct_INTERNO_ABS_Listado_ColumnasDatos_Modelo;
}
public override string ORDENACION_NOMBRECOLUMNA_PORDEFECTO()
{
return nameof(INTERNO_GEN_Firmas_Electronicas_Listado_Modelo.codigo);
}
public override string ORDENACION_TIPO_PORDEFECTO()
{
return "0";
}
public override INTERNO_Listado_BotonesAuxiliares_Modelo BOTONAUXILIAR_1()
{
return null;
}
public override INTERNO_Listado_BotonesAuxiliares_Modelo BOTONAUXILIAR_2()
{
return null;
}
public override INTERNO_Listado_BotonesAuxiliares_Modelo BOTONAUXILIAR_3()
{
return null;
}
public override INTERNO_Listado_BotonesAuxiliares_Modelo BOTONAUXILIAR_4()
{
return null;
}
public override INTERNO_Listado_BotonesAuxiliares_Modelo BOTONAUXILIAR_5()
{
return null;
}
public override INTERNO_Listado_BotonesAuxiliares_Modelo BOTONAUXILIAR_6()
{
return null;
}
public override INTERNO_Listado_BotonesAuxiliares_Modelo BOTONAUXILIAR_7()
{
return null;
}
public override List<INTERNO_ArbolSecundarioSeleccion_Modelo> LISTADO_ARBOLSECUNDARIOSELECCION()
{
return null;
}
public override List<INTERNO_Listado_Paginado_Filtro_Modelo> FILTRADO_PARAPAGINADO()
{
return null;
}
public override List<string> LISTADOCAMPOS_ENVIAR_A_MANTENIMIENTO()
{
return null;
}
}
}

View File

@ -38,6 +38,8 @@
this.ex_btn_P_ConfiguracioGeneral_ConfiguracionInformes = new Exferia_Controles.Exferia_Button();
this.exferia_Label5 = new Exferia_Controles.Exferia_Label();
this.ex_btn_P_ConfiguracioGeneral_ConfiguracionSWSigma = new Exferia_Controles.Exferia_Button();
this.exferia_Button1 = new Exferia_Controles.Exferia_Button();
this.exferia_Label6 = new Exferia_Controles.Exferia_Label();
this.SuspendLayout();
//
// ex_btn_P_ConfiguracioGeneral_ConfiguracionCampoCodigo
@ -190,10 +192,42 @@
this.ex_btn_P_ConfiguracioGeneral_ConfiguracionSWSigma.UseVisualStyleBackColor = false;
this.ex_btn_P_ConfiguracioGeneral_ConfiguracionSWSigma.Click += new System.EventHandler(this.ex_btn_P_ConfiguracioGeneral_ConfiguracionSWSigma_Click);
//
// firmas digitales
//
this.exferia_Button1.BackColor = System.Drawing.Color.Maroon;
this.exferia_Button1.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Stretch;
this.exferia_Button1.Exferia_Button_Bloqueable = true;
this.exferia_Button1.Exferia_Button_Imagen = Exferia_Aplicacion.General.Imagenes.G_ENUM_IMAGENES.G_IMG_IMPRIMIR_VERTICAL;
this.exferia_Button1.Exferia_Button_Permitir_CambioFuenteAutomatico = true;
this.exferia_Button1.Exferia_Button_ReadOnly = false;
this.exferia_Button1.Exferia_Button_TabStop = false;
this.exferia_Button1.Exferia_Button_ToolTip = "Configuración de informes";
this.exferia_Button1.FlatAppearance.BorderSize = 0;
this.exferia_Button1.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.exferia_Button1.Location = new System.Drawing.Point(12, 285);
this.exferia_Button1.Name = "exferia_Button1";
this.exferia_Button1.Size = new System.Drawing.Size(31, 36);
this.exferia_Button1.TabIndex = 55;
this.exferia_Button1.TabStop = false;
this.exferia_Button1.TextAlign = System.Drawing.ContentAlignment.BottomCenter;
this.exferia_Button1.UseVisualStyleBackColor = false;
this.exferia_Button1.Click += new System.EventHandler(this.firmasDigitales_Click);
//
// firmas digitales
//
this.exferia_Label6.AutoSize = true;
this.exferia_Label6.Location = new System.Drawing.Point(48, 308);
this.exferia_Label6.Name = "exferia_Label6";
this.exferia_Label6.Size = new System.Drawing.Size(78, 13);
this.exferia_Label6.TabIndex = 56;
this.exferia_Label6.Text = "Firmas digitales";
//
// P_ConfiguracionGeneral
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.ClientSize = new System.Drawing.Size(797, 670);
this.Controls.Add(this.exferia_Label6);
this.Controls.Add(this.exferia_Button1);
this.Controls.Add(this.exferia_Label5);
this.Controls.Add(this.ex_btn_P_ConfiguracioGeneral_ConfiguracionSWSigma);
this.Controls.Add(this.exferia_Label4);
@ -215,6 +249,8 @@
this.Controls.SetChildIndex(this.exferia_Label4, 0);
this.Controls.SetChildIndex(this.ex_btn_P_ConfiguracioGeneral_ConfiguracionSWSigma, 0);
this.Controls.SetChildIndex(this.exferia_Label5, 0);
this.Controls.SetChildIndex(this.exferia_Button1, 0);
this.Controls.SetChildIndex(this.exferia_Label6, 0);
this.ResumeLayout(false);
this.PerformLayout();
@ -232,5 +268,7 @@
private Exferia_Controles.Exferia_Button ex_btn_P_ConfiguracioGeneral_ConfiguracionInformes;
private Exferia_Controles.Exferia_Label exferia_Label5;
private Exferia_Controles.Exferia_Button ex_btn_P_ConfiguracioGeneral_ConfiguracionSWSigma;
private Exferia_Controles.Exferia_Button exferia_Button1;
private Exferia_Controles.Exferia_Label exferia_Label6;
}
}

View File

@ -246,8 +246,41 @@ namespace Exferia_General._3_Vistas
Control_Errores.Errores_Log("", ex, nameof(P_ConfiguracionGeneral) + "/" + nameof(ConfiguracionDireccionesSWSigma));
}
}
#endregion
private void firmasDigitales_Click(object sender, EventArgs e)
{
ConfiguracionFirmasDigitales();
}
private void ConfiguracionFirmasDigitales()
{
try
{
INTERNO_OpcionesDetalle_Modelo mdl_INTERNO_OpcionesDetalle_Modelo = Datos_Generales.PRV_Opciones_Buscar_Detalles(Variables.G_STR_OPCION_GEN_FIRMAS_ELECTRONICAS);
if (mdl_INTERNO_OpcionesDetalle_Modelo != null)
{
//Cargamos el ensamblado
Assembly m_assembly = Assembly.LoadFrom(Variables.G_STR_LIBRERIA_RUTAINICIAL + @"\" + Variables.G_STR_LIBRERIA_GENERAL + ".dll");
//Obtenemos el tipo de la clase
Type m_type = m_assembly.GetType(Variables.G_STR_LIBRERIA_GENERAL + "." + Variables.G_STR_LIBRERIA_OPCIONES);
//creamos la instancia
var obj_Clase = Activator.CreateInstance(m_type);
//Cargamos el metodo solicitado
MethodInfo obj_MethodInfo = obj_Clase.GetType().GetMethod(Variables.G_STR_LIBRERIA_OPCIONES_PROCEDIMIENTO_CARGAR_LISTADO, BindingFlags.Instance | BindingFlags.NonPublic);
//Obtener valores
object[] arr_Parametros = { mdl_INTERNO_OpcionesDetalle_Modelo.opcion, false, 0, null, Variables.G_MDL_INTERNO_VALORESGENERALES_MODELO, Variables.G_DTT_FECHA_INICIAL_PORDEFECTO, "", "", false, false, null, null, null, null, null, null };
//Pasamos los parametros al metodo y lo ejecutamos
obj_MethodInfo.Invoke(obj_Clase, arr_Parametros);
}
}
catch (Exception ex)
{
Control_Errores.Errores_Log("", ex, nameof(P_ConfiguracionGeneral) + "/" + nameof(ConfiguracionFirmasDigitales));
}
}
}
}

View File

@ -81,6 +81,7 @@
<Compile Include="0_Modelos\INTERNO_Criterio.cs" />
<Compile Include="0_Modelos\INTERNO_GEN_Configuracion_Informes_Listado_Modelo.cs" />
<Compile Include="0_Modelos\INTERNO_ERP_ValoresGenerales_Listado_Modelo.cs" />
<Compile Include="0_Modelos\INTERNO_GEN_Firmas_Electronicas_Listado_Modelo.cs" />
<Compile Include="0_Modelos\INTERNO_GEN_Terminales_Listado_Modelo.cs" />
<Compile Include="0_Modelos\INTERNO_GEN_Delegaciones_Modelo.cs" />
<Compile Include="0_Modelos\INTERNO_OpcionesDisponibles_Actualizacion_Modelo.cs" />
@ -129,6 +130,7 @@
<Compile Include="1_Datos\GEN_Delegaciones_AlmacenesAControlar_Datos.cs" />
<Compile Include="1_Datos\GEN_Delegaciones_DelegacionesAsociadas_Datos.cs" />
<Compile Include="1_Datos\GEN_EmpresasLogos_Datos.cs" />
<Compile Include="1_Datos\GEN_Firmas_Electronicas_Datos.cs" />
<Compile Include="1_Datos\GEN_RetencionesTipos_Datos.cs" />
<Compile Include="1_Datos\GEN_Terminales_Delegaciones_Configuracion_Datos.cs" />
<Compile Include="1_Datos\GEN_Terminales_ValidacionesHistorico_Datos.cs" />
@ -333,6 +335,7 @@
<Compile Include="3_Vistas\ListadosSeleccion\ABS_ListadoSeleccion_Parametros.cs" />
<Compile Include="3_Vistas\ListadosSeleccion\ABS_ListadoSeleccion_TipoEmail.cs" />
<Compile Include="3_Vistas\ListadosSeleccion\ABS_ListadoSeleccion_GEN_Configuracion_Informes.cs" />
<Compile Include="3_Vistas\Listados\ABS_Listado_GEN_Firmas_Electronicas.cs" />
<Compile Include="3_Vistas\Listados\ABS_Listado_HRM_PreciosCombustible_Historico.cs" />
<Compile Include="3_Vistas\Listados\ABS_Listado_GEN_Almacenes_P_Delegacion_IncluirRegistros.cs" />
<Compile Include="3_Vistas\Listados\ABS_Listado_GEN_Almacenes_P_Delegacion.cs" />

View File

@ -110,6 +110,10 @@ namespace Exferia_General
{
obj_ABS_Listado_Auxiliar = new ABS_Listado_GEN_Configuracion_Informes();
}
else if (_str_Opcion.Equals(Variables.G_STR_OPCION_GEN_FIRMAS_ELECTRONICAS))
{
obj_ABS_Listado_Auxiliar = new ABS_Listado_GEN_Firmas_Electronicas();
}
//CONFIGURACIONEMAIL
else if (_str_Opcion.Equals(Variables.G_STR_OPCION_GEN_CONFIGURACIONEMAIL))
{
@ -288,6 +292,12 @@ namespace Exferia_General
GEN_Configuracion_Informes_Datos obj_GEN_Configuracion_Informes_Datos = new GEN_Configuracion_Informes_Datos();
lst_Valores = obj_GEN_Configuracion_Informes_Datos.Obtener_Listado(_lng_idEmpresaSeleccionada, _lng_idEjercicioActual, _lst_CamposConRelacionABuscar, _lst_INTERNO_Filtro_OpcionPadre_Modelo, _lst_INTERNO_Filtro_Modelo);
}
//CONFIGURACION_FIRMAS DIGITALES
else if (_str_Opcion.Equals(Variables.G_STR_OPCION_GEN_FIRMAS_ELECTRONICAS))
{
GEN_Firmas_Electronicas_Datos obj_GEN_Firmas_Electronicas_Datos = new GEN_Firmas_Electronicas_Datos();
lst_Valores = obj_GEN_Firmas_Electronicas_Datos.Obtener_Listado(_lng_idEmpresaSeleccionada, _lng_idEjercicioActual, _lst_CamposConRelacionABuscar, _lst_INTERNO_Filtro_OpcionPadre_Modelo, _lst_INTERNO_Filtro_Modelo);
}
//CONFIGURACIONEMAIL
else if (_str_Opcion.Equals(Variables.G_STR_OPCION_GEN_CONFIGURACIONEMAIL))
{
@ -465,6 +475,13 @@ namespace Exferia_General
GEN_Configuracion_Informes_Datos obj_GEN_Configuracion_Informes_Datos = new GEN_Configuracion_Informes_Datos();
dnm_Valor = obj_GEN_Configuracion_Informes_Datos.Obtener_RegistroListado(_lng_idEmpresaSeleccionada, _lng_idEjercicioActual, _lst_CamposConRelacionABuscar, _lst_INTERNO_Filtro_OpcionPadre_Modelo, _lst_INTERNO_Filtro_Modelo, _lng_id, _lst_ids);
}
//Firmas electronicas
//todo firmas-electronicas
/*else if (_str_Opcion.Equals(Variables.G_STR_OPCION_GEN_FIRMAS_ELECTRONICAS))
{
GEN_Firmas_Electronicas_Datos obj_GEN_Firmas_Electronicas_Datos = new GEN_Firmas_Electronicas_Datos();
dnm_Valor = obj_GEN_Firmas_Electronicas_Datos.Obtener_RegistroListado(_lng_idEmpresaSeleccionada, _lng_idEjercicioActual, _lst_CamposConRelacionABuscar, _lst_INTERNO_Filtro_OpcionPadre_Modelo, _lst_INTERNO_Filtro_Modelo);
}*/
//CONFIGURACIONEMAIL
else if (_str_Opcion.Equals(Variables.G_STR_OPCION_GEN_CONFIGURACIONEMAIL))
{
@ -1131,6 +1148,45 @@ namespace Exferia_General
Funciones_PanelPrincipal.Cargar_PantallaEmpotrada(frm_P_Configuracion_Informes, _str_Opcion);
}
//firmas electronicas
else if (_str_Opcion.Equals(Variables.G_STR_OPCION_GEN_FIRMAS_ELECTRONICAS))
{
//todo firmas-electronicas
/*
P_Configuracion_Informes frm_P_Configuracion_Informes = new P_Configuracion_Informes(_mdl_INTERNO_ValoresGenerales_Modelo, _dtt_FechaPorDefecto, _mdl_INTERNO_OpcionesDetalle_Modelo);
frm_P_Configuracion_Informes.P_Base_Campo_1 = _str_Campo1_Valor;
frm_P_Configuracion_Informes.P_Base_Campo_2 = _str_Campo2_Valor;
//Se llamo desde una pantalla
if (_frm_P_Base_Origen != null)
{
frm_P_Configuracion_Informes.P_Base_PantallaPadre_IdentificadorTAG = _frm_P_Base_Origen.Tag.ToString();
frm_P_Configuracion_Informes.P_Base_PantallaOrigen = _frm_P_Base_Origen;
}
//Se llamo desde un control F3
else
{
frm_P_Configuracion_Informes.P_Base_PantallaPadre_IdentificadorTAG = "";
frm_P_Configuracion_Informes.P_Base_F3Origen = _usc_Exferia_F3_Origen;
}
//Modificar
if (_lng_RegistroSeleccionado > 0)
{
frm_P_Configuracion_Informes.P_Base_TituloPantalla_CaminoHormigas = _mdl_INTERNO_OpcionesDetalle_Modelo.descripcion_TituloMantenimiento.ToUpper();
frm_P_Configuracion_Informes.P_Base_id = _lng_RegistroSeleccionado;
frm_P_Configuracion_Informes.P_Base_TipoAperturaPantalla = 1;
}
//Alta
else
{
frm_P_Configuracion_Informes.P_Base_TipoAperturaPantalla = 0;
frm_P_Configuracion_Informes.P_Base_TituloPantalla_CaminoHormigas = _mdl_INTERNO_OpcionesDetalle_Modelo.descripcion_TituloMantenimiento.ToUpper() + " -> Alta";
}
Funciones_PanelPrincipal.Cargar_PantallaEmpotrada(frm_P_Configuracion_Informes, _str_Opcion);
*/
}
//CONFIGURACIONEMAIL
else if (_str_Opcion.Equals(Variables.G_STR_OPCION_GEN_CONFIGURACIONEMAIL))
{
@ -1807,6 +1863,12 @@ namespace Exferia_General
GEN_Configuracion_Informes_Datos obj_GEN_Configuracion_Informes_Datos = new GEN_Configuracion_Informes_Datos();
dnm_Valores = obj_GEN_Configuracion_Informes_Datos.Obtener(_lng_id);
}
//Firmas electronicas
else if (_str_Opcion.Equals(Variables.G_STR_OPCION_GEN_FIRMAS_ELECTRONICAS))
{
GEN_Firmas_Electronicas_Datos obj_GEN_Firmas_Electronicas_Datos = new GEN_Firmas_Electronicas_Datos();
dnm_Valores = obj_GEN_Firmas_Electronicas_Datos.Obtener(_lng_id);
}
//CONFIGURACIONEMAIL
else if (_str_Opcion.Equals(Variables.G_STR_OPCION_GEN_CONFIGURACIONEMAIL))
{
@ -1919,6 +1981,12 @@ namespace Exferia_General
GEN_Configuracion_Informes_Datos obj_GEN_Configuracion_Informes_Datos = new GEN_Configuracion_Informes_Datos();
dnm_Valores = obj_GEN_Configuracion_Informes_Datos.Grabar(_dnm_Modelo);
}
//Firmas electronicas
else if (_str_Opcion.Equals(Variables.G_STR_OPCION_GEN_FIRMAS_ELECTRONICAS))
{
GEN_Firmas_Electronicas_Datos obj_GEN_Firmas_Electronicas_Datos = new GEN_Firmas_Electronicas_Datos();
dnm_Valores = obj_GEN_Firmas_Electronicas_Datos.Grabar(_dnm_Modelo);
}
//CONFIGURACIONEMAIL
else if (_str_Opcion.Equals(Variables.G_STR_OPCION_GEN_CONFIGURACIONEMAIL))
{
@ -2036,6 +2104,12 @@ namespace Exferia_General
GEN_Configuracion_Informes_Datos obj_GEN_Configuracion_Informes_Datos = new GEN_Configuracion_Informes_Datos();
dnm_Valores = obj_GEN_Configuracion_Informes_Datos.Borrar(_lng_id);
}
//Firmas electronicas
else if (_str_Opcion.Equals(Variables.G_STR_OPCION_GEN_FIRMAS_ELECTRONICAS))
{
GEN_Firmas_Electronicas_Datos obj_GEN_Firmas_Electronicas_Datos = new GEN_Firmas_Electronicas_Datos();
dnm_Valores = obj_GEN_Firmas_Electronicas_Datos.Borrar(_lng_id);
}
//CONFIGURACIONEMAIL
else if (_str_Opcion.Equals(Variables.G_STR_OPCION_GEN_CONFIGURACIONEMAIL))
{

View File

@ -181,6 +181,7 @@
"GEN_EJERCICIOACTIVO",
"GEN_EMPRESA",
"GEN_ENTIDADBANCARIA",
"GEN_FIRMAS_ELECTRONICAS",
"GEN_IMPUESTOCABECERA",
"GEN_IMPUESTOLINEA",
"GEN_IMPUESTOTIPO",

View File

@ -1114,7 +1114,7 @@ namespace Exferia_Ventas._1_Datos
_lst_ids);
string cif = "cif";// nameof(INTERNO_VTA_FacturasCabecera_Listado_Modelo.MAE_Clientes.cif);
string str_SQL =
" SELECT " +
@ -1202,14 +1202,14 @@ namespace Exferia_Ventas._1_Datos
) +
//Cliente_Cif
(
(_lst_CamposConRelacionABuscar.Contains(nameof(INTERNO_VTA_FacturasCabecera_Listado_Modelo.MAE_Clientes.cif)))
(_lst_CamposConRelacionABuscar.Contains(cif/*nameof(INTERNO_VTA_FacturasCabecera_Listado_Modelo.MAE_Clientes.cif)*/))
?
(
nameof(INTERNO_VTA_FacturasCabecera_Listado_Modelo.MAE_Clientes.cif) + " = " + nameof(MAE_Clientes) + "." + nameof(MAE_Clientes.cif) + ","
cif/*nameof(INTERNO_VTA_FacturasCabecera_Listado_Modelo.MAE_Clientes.cif)*/ + " = " + nameof(MAE_Clientes) + "." + nameof(MAE_Clientes.cif) + ","
)
:
(
nameof(INTERNO_VTA_FacturasCabecera_Listado_Modelo.MAE_Clientes.cif) + " = '',"
cif/*nameof(INTERNO_VTA_FacturasCabecera_Listado_Modelo.MAE_Clientes.cif)*/ + " = '',"
)
) +
//Socio