diff --git a/App_Code/ClsBancos.vb b/App_Code/ClsBancos.vb index 4e3b0b213..5098d660e 100644 --- a/App_Code/ClsBancos.vb +++ b/App_Code/ClsBancos.vb @@ -4350,11 +4350,13 @@ Public Class ClsBancos Return Retorno End Function - Public Function GetAcreedoresReporte(CveEmpresa As Integer) As Boolean + Public Function GetAcreedoresReporte(CveEmpresa As Integer, Optional FechaI As Date = MinFecha, Optional FechaF As Date = MaxFecha) As Boolean Dim Retorno As Boolean = False DataAdapter("PA_Banc_AcreedorReporte") With SqlAdapter.SelectCommand.Parameters .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa + .Add("@FechaI", SqlDbType.Date).Value = FechaI + .Add("@FechaF", SqlDbType.Date).Value = FechaF End With Try SqlAdapter.Fill(Data) diff --git a/App_Code/ClsNominas.vb b/App_Code/ClsNominas.vb index e40a7740e..79507b7fc 100644 --- a/App_Code/ClsNominas.vb +++ b/App_Code/ClsNominas.vb @@ -540,6 +540,33 @@ Public Class ClsNominas Return Retorno End Function + + Public Function PA_Nom_NominasAutorizarUP(cvePersonal As Int32, cvePeriodo As Int32, salarioDiario As Decimal, sBC As Decimal, sDI As Decimal, horasDobles As Int16, horasTriples As Int16, total As Double, subTotal As Double, diasPagados As Double, diasFaltados As Int32, diasVacaciones As Int32, diasIncapacidad As Int32) As Boolean + Dim retorno As Boolean = False + DataAdapter("PA_Nom_NominasAutorizarUP", CommandType.StoredProcedure) + With SqlAdapter.SelectCommand.Parameters + .Add("@CvePersonal", SqlDbType.Int).Value = cvePersonal + .Add("@CvePeriodo", SqlDbType.Int).Value = cvePeriodo + .Add("@SalarioDiario", SqlDbType.SmallMoney).Value = salarioDiario + .Add("@SBC", SqlDbType.SmallMoney).Value = sBC + .Add("@SDI", SqlDbType.SmallMoney).Value = sDI + .Add("@HorasDobles", SqlDbType.SmallInt).Value = horasDobles + .Add("@HorasTriples", SqlDbType.SmallInt).Value = horasTriples + .Add("@Total", SqlDbType.Float).Value = total + .Add("@SubTotal", SqlDbType.Float).Value = subTotal + .Add("@DiasPagados", SqlDbType.Float).Value = diasPagados + .Add("@DiasFaltados", SqlDbType.Int).Value = diasFaltados + .Add("@DiasVacaciones", SqlDbType.Int).Value = diasVacaciones + .Add("@DiasIncapacidad", SqlDbType.Int).Value = diasIncapacidad + End With + Try + SqlAdapter.Fill(Data) + Retorno = True + Catch ex As Exception + OnError("Ocurrió un error al autorizar la nomina.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo) + End Try + Return retorno + End Function Public Function AddNom_Nominas(FolioNom As Integer, CveNominaTipo As Integer, CvePersonal As Integer, CvePeriodo As Integer, SubTotal As Double, Descuento As Double, RetISR As Double, Total As Double, CveMoneda As Integer, TipoCambio As Double, CveMetodoPago As Integer, Fecha As Date, MotivoDescuento As String, Observaciones As String, Alfa1 As String, Alfa2 As String, Alfa3 As String, Num1 As Double, Num2 As Double, Num3 As Double, diff --git a/App_Code/ClsPaginas.vb b/App_Code/ClsPaginas.vb index cf19cedbd..ec50c30d6 100644 --- a/App_Code/ClsPaginas.vb +++ b/App_Code/ClsPaginas.vb @@ -5124,7 +5124,7 @@ Public Class ClsPaginas PaginaDict.Add("/Contabilidad/OCDetalleAlmacen.aspx".ToUpper(), -1) - + PaginaDict.Add("/testApi.aspx".ToUpper(), -1) 'PaginaDict.Add("/Compras/Efacturas.aspx".ToUpper(), 2007) 'PaginaDict.Add("/Compras/Compras.aspx".ToUpper(), 2008) @@ -7468,11 +7468,11 @@ Public Class ClsPaginas ' nombreautorizo = "Lic. LUIS JORGE CONTRERAS LANDGRAVE" 'End If Dim Archivo As New System.IO.FileInfo(String.Format("{0}Formatos\OC.rdlc", EmpresaActual.Ruta)) - If Not Archivo.Exists OrElse EmpresaActual.CveEmpresa.Contiene(4, 145, 7, 11, 12, 13, 72, 80, 83, 122, 126) Then + If Not Archivo.Exists OrElse EmpresaActual.CveEmpresa.Contiene(4, 145, 7, 11, 12, 13, 72, 80, 83, 122, 126, 158) Then params.Add(New ReportParameter("Descuento", DtDetalle.SUM("Descuento").ToString.FormatoNumero(2))) End If 'DATOS PARA DESCUENTO - If EmpresaActual.CveEmpresa.Contiene(4, 145, 7, 11, 12, 13, 72, 80, 83, 119, 122, 126) Then 'EMPRESAS QUE YA TIENEN EL AJUSTE EN EL FORMATO + If EmpresaActual.CveEmpresa.Contiene(4, 145, 7, 11, 12, 13, 72, 80, 83, 119, 122, 126, 158) Then 'EMPRESAS QUE YA TIENEN EL AJUSTE EN EL FORMATO params.Add(New ReportParameter("SubTotal", ObjOC.SubTotal.ToString)) params.Add(New ReportParameter("SubTotal2", DtDetalle.SUM("Total").ToString)) Else diff --git a/App_Code/Models/Request/RequestLogin.vb b/App_Code/Models/Request/RequestLogin.vb new file mode 100644 index 000000000..b1833aaa2 --- /dev/null +++ b/App_Code/Models/Request/RequestLogin.vb @@ -0,0 +1,9 @@ +Imports Microsoft.VisualBasic + +Namespace Models.Request + Public Class RequestLogin + Public Property UserName As String + Public Property Password As String + End Class + +End Namespace diff --git a/App_Code/Models/Response/ResponseGenericModel.vb b/App_Code/Models/Response/ResponseGenericModel.vb new file mode 100644 index 000000000..e0c18e717 --- /dev/null +++ b/App_Code/Models/Response/ResponseGenericModel.vb @@ -0,0 +1,10 @@ +Imports Microsoft.VisualBasic + +Namespace Models.Response + Public Class ResponseGenericModel(Of T) + Public Property IsSuccess As Boolean + Public Property Msg As String + Public Property Result As T + End Class + +End Namespace diff --git a/App_Code/Models/Response/ResponseLogin.vb b/App_Code/Models/Response/ResponseLogin.vb new file mode 100644 index 000000000..32213c941 --- /dev/null +++ b/App_Code/Models/Response/ResponseLogin.vb @@ -0,0 +1,93 @@ +Imports Microsoft.VisualBasic +Imports Newtonsoft.Json + + +Namespace Models.Response + Public Class ResponseLogin + Public Property CveUsuario As Long + Public Property Usuario As String + Public Property Nombre As String + Public Property Correo As String + Public Property CveEmpresa As Long + Public Property Empresa As String + Public Property CvePlataforma As Long + Public Property Estatus As Boolean + Public Property CveRol As Integer + Public Property Rol As String + Public Property CveToken As Long + Public Property AccessToken As String + Public Property RefreshToken As String + Public Property UsuarioModulos As List(Of UsuarioModulo) + Public Property UsuarioEmpresas As List(Of UsuarioEmpresa) + Public Property EmpresaFuncionalidades As List(Of EmpresaFuncionalidad) + End Class + + Public Class UsuarioModulo + Public Property CveModulo As Long + Public Property Modulo As String + Public Property CveUsuario As Long + Public Property Agrupacion As String + Public Property Descripcion As String + Public Property Liga As String + Public Property CveModuloAcceso As Long + Public Property CveProcesoAcceso As Long + Public Property Permitir As Long + Public Property Estilo As String + Public Property Padre As String + Public Property CvePadre As Long + Public Property Usuario As String + Public Property CveRol As Long + Public Property Rol As String + Public Property CvePlataforma As Long + Public Property Parametros As String + End Class + + Public Class UsuarioEmpresa + Public Property Tipo_CentroCosto As Long + Public Property CveEmpresa As Long + Public Property Empresa As String + Public Property CveUsuario As Long + Public Property Usuario As String + Public Property Contraseña As String + Public Property CveCliente As Long + Public Property Cliente As String + Public Property CveProveedor As Long + Public Property Proveedor As String + Public Property FechaUltimoAcceso As DateTime + Public Property Nombre As String + Public Property CveRol As Long + Public Property Rol As String + Public Property Telefono As String + Public Property Correo As String + Public Property Estatus As Boolean + Public Property FechaIng As DateTime + Public Property EsSupervisorRH As Boolean + Public Property CveSupervisa As Long + Public Property CveAutoriza As Long + Public Property CvePersonal As Long + Public Property CveVendedor As Long + Public Property CvePlataforma As Long + Public Property ComprasProgramadas As Long + Public Property ProveedoresResponsables As Long + Public Property CveSubProyecto As Long + Public Property CveUsuarioIng As Long + Public Property CveEncuestaCRM As Long + + + Public Property EmpresaFuncionalidades As List(Of EmpresaFuncionalidad) + + Public Function Funcionalidad(ByVal CveFuncionalidad As Long) As String + Return If(EmpresaFuncionalidades IsNot Nothing AndAlso EmpresaFuncionalidades.FirstOrDefault(Function(x) x.CveFuncionalidad = CveFuncionalidad) IsNot Nothing, EmpresaFuncionalidades.FirstOrDefault(Function(x) x.CveFuncionalidad = CveFuncionalidad).Valor, "") + End Function + End Class + + Public Class EmpresaFuncionalidad + Public Property CveEmpresa As Long + Public Property CveFuncionalidad As Long + Public Property Valor As String + Public Property Descripción As String + Public Property Funcionalidad As String + End Class + +End Namespace + diff --git a/App_Code/TimbradoB.vb b/App_Code/TimbradoB.vb new file mode 100644 index 000000000..6e044c5ed --- /dev/null +++ b/App_Code/TimbradoB.vb @@ -0,0 +1,36 @@ +Imports Microsoft.VisualBasic + +Public Class TimbradoB + + + + 'Public Function TimbrarFactura(UsuarioActual As Usuario, Ventas As Modelos.Factura, Optional CvePACEspecial As Integer = -1) As Boolean + + ' Dim Retorno As Boolean = False + ' Dim tCvePAC As Integer = UsuarioActual.Empresa.CvePAC + ' If CvePACEspecial <> -1 Then tCvePAC = CvePACEspecial + ' Dim objs As ADSTimbrado.TimbradoEmpresa + ' Dim result = ADSTimbrado.Timbrado.TimbrarFactura(Ventas, objs, ADSTimbrado.PacTimbrado.PADEv) + ' Retorno = result.isOK + ' If result.isOK Then + ' Else + + ' End If + + + ' Return Retorno + 'End Function +End Class + +'Public Class TimbradoEmpresa +' Inherits ADSTimbradoLibrary.TimbradoEmpresa + +' Public Overrides Function UpdateEstatusFactura(FolioFiscal As String, ObjCFDITimbre As ADSTimbradoLibrary.CFDITimbre, facturaCFDI As ADSTimbradoLibrary.Factura, CvePAC As Integer) As String +' Throw New NotImplementedException() +' End Function + +' Public Overrides Function Timbre() As String +' Throw New NotImplementedException() +' End Function +'End Class + diff --git a/Bancos/PagoAcreedor.aspx b/Bancos/PagoAcreedor.aspx index e51215961..934cc2d4e 100644 --- a/Bancos/PagoAcreedor.aspx +++ b/Bancos/PagoAcreedor.aspx @@ -385,6 +385,93 @@ + + +
+
+
+ + +
+
+
+ +
Fecha Inicio:
+
+
+ <%--width: 120px !important;--%> + + + + + + + + + + <%----%> + + + <%----%> + + +
+
+
Fecha Fin:
+
+ +
+ <%--width: 120px !important;--%> + + + + + + + + <%----%> + + + <%----%> + + +
+
+ +
+
+ +
+ +
+ + + + +
diff --git a/Bancos/PagoAcreedor.aspx.cs b/Bancos/PagoAcreedor.aspx.cs index cdcd5066d..bf115dfad 100644 --- a/Bancos/PagoAcreedor.aspx.cs +++ b/Bancos/PagoAcreedor.aspx.cs @@ -931,14 +931,29 @@ public partial class Bancos_PagoAcreedor : ClsPaginas #region"REPORTE" protected void CargaReporte() { + + DateTime FInicio = MinFecha; + DateTime FFin = MaxFecha; + + if(TxtFechaInicio.Text.Length == 10) + { + FInicio = TxtFechaInicio.Text.ToDate(); + } + + if(TxtFechaFin.Text.Length == 10) + { + FFin = TxtFechaFin.Text.ToDate(); + } + ClsBancos bancos = new ClsBancos(); - if (bancos.GetAcreedoresReporte(UsuarioActual.CveEmpresa)) + if (bancos.GetAcreedoresReporte(UsuarioActual.CveEmpresa, FInicio, FFin)) { GvReporte.DataSource = bancos.DtResultados; GvReporte.DataBind(); } bancos.Dispose(); UpReporte.Update(); + } protected void GvReporte_RowDataBound(object sender, GridViewRowEventArgs e) { @@ -970,4 +985,9 @@ public partial class Bancos_PagoAcreedor : ClsPaginas UpDatos.Update(); UpMovAcreedor.Update(); } + + protected void BtnConsultarReporte_Click(object sender, EventArgs e) + { + CargaReporte(); + } } diff --git a/CRM/CatEmpresasCRM.aspx b/CRM/CatEmpresasCRM.aspx index 4d47b17ab..1e7e82f94 100644 --- a/CRM/CatEmpresasCRM.aspx +++ b/CRM/CatEmpresasCRM.aspx @@ -13,11 +13,14 @@
  • Agregar
  • +
  • + Cargar Prospectos +
  • - +
    @@ -47,9 +50,9 @@ - + -
    +
    " style="display: inline-block; margin-right: -20px; width: 150px;" /> " style="margin-top: -3px;" class="btn btn-circle btn-sm label-info">
    @@ -59,7 +62,7 @@ - + @@ -72,21 +75,21 @@ - + - - + + - - + + - + @@ -95,14 +98,49 @@ - - + + +