diff --git a/App_Code/ClsFinanzas.vb b/App_Code/ClsFinanzas.vb index b5cb2e91a..021e97a86 100644 --- a/App_Code/ClsFinanzas.vb +++ b/App_Code/ClsFinanzas.vb @@ -277,6 +277,7 @@ Public Class ClsFinanzas .Add("@Opcion", SqlDbType.Int).Value = Opcion End With Try + SqlAdapter.SelectCommand.CommandTimeout = 0 SqlAdapter.Fill(Data) Retorno = True Catch ex As Exception @@ -304,6 +305,7 @@ Public Class ClsFinanzas End With Try + SqlAdapter.SelectCommand.CommandTimeout = 0 SqlAdapter.Fill(Data) Retorno = True Catch ex As Exception @@ -355,6 +357,7 @@ Public Class ClsFinanzas End With Try + SqlAdapter.SelectCommand.CommandTimeout = 0 SqlAdapter.Fill(Data) Retorno = True Catch ex As Exception diff --git a/App_Code/ClsPaginas.vb b/App_Code/ClsPaginas.vb index 3ad022eb2..dc1f524d2 100644 --- a/App_Code/ClsPaginas.vb +++ b/App_Code/ClsPaginas.vb @@ -9207,7 +9207,7 @@ Public Class ClsPaginas 'PaginaDict.Add("/Sistemas/CatEmpresas.aspx".ToUpper(), 2) PaginaDict.Add("/Sistemas/CatEmpresas.aspx".ToUpper(), 24) PaginaDict.Add("/Sistemas/Empresa.aspx".ToUpper(), 2) - PaginaDict.Add("/Sistemas/Empresa2.aspx".ToUpper(), -1) + PaginaDict.Add("/Sistemas/Empresa2.aspx".ToUpper(), 1341) PaginaDict.Add("/Sistemas/CatUsuarios.aspx".ToUpper(), 20) PaginaDict.Add("/Sistemas/Usuarios.aspx".ToUpper(), 20) PaginaDict.Add("/Sistemas/UsuarioDetalle.aspx".ToUpper(), 20) diff --git a/Empresas/Grales/Formatos/RepExistenciasCostos.rdlc b/Empresas/Grales/Formatos/RepExistenciasCostos.rdlc index 8256084a2..7c840dd7e 100644 --- a/Empresas/Grales/Formatos/RepExistenciasCostos.rdlc +++ b/Empresas/Grales/Formatos/RepExistenciasCostos.rdlc @@ -339,6 +339,9 @@ Textbox24 + + =IIF(Parameters!OcultarImportes.Value.ToString() = "False", True,False) + @@ -450,6 +453,9 @@ Textbox33 + + =IIF(Parameters!OcultarImportes.Value.ToString() = "False", True,False) + @@ -636,6 +642,9 @@ Textbox16 + + =IIF(Parameters!OcultarImportes.Value.ToString() = "False", True,False) + @@ -738,6 +747,9 @@ Textbox22 + + =IIF(Parameters!OcultarImportes.Value.ToString() = "False", True,False) + @@ -1026,6 +1038,9 @@ ImporteE2 + + =IIF(Parameters!OcultarImportes.Value.ToString() = "False", True,False) + @@ -1051,6 +1066,7 @@ =Fields!Salidas.Value @@ -1136,6 +1152,9 @@ ImporteS2 + + =IIF(Parameters!OcultarImportes.Value.ToString() = "False", True,False) + @@ -1234,7 +1253,11 @@ - + + + =IIF(Parameters!OcultarImportes.Value.ToString() = "False", False,True) + + diff --git a/Finanzas/RepRazonesFinancieras2.aspx b/Finanzas/RepRazonesFinancieras2.aspx index 7af11eece..94e3f8019 100644 --- a/Finanzas/RepRazonesFinancieras2.aspx +++ b/Finanzas/RepRazonesFinancieras2.aspx @@ -61,7 +61,8 @@ - + +
@@ -81,9 +82,20 @@ SubProyecto:
- +
+ + + + +
+ + Comparativo + Trazabilidad + +
+
diff --git a/Finanzas/RepRazonesFinancieras2.aspx.vb b/Finanzas/RepRazonesFinancieras2.aspx.vb index 872931ebe..107f5fdcb 100644 --- a/Finanzas/RepRazonesFinancieras2.aspx.vb +++ b/Finanzas/RepRazonesFinancieras2.aspx.vb @@ -63,10 +63,6 @@ Partial Class Finanzas_RepRazonesFinancieras2 End If End Sub - - - - Protected Sub DdlEjercicio_SelectedIndexChanged(sender As Object, e As EventArgs) ValidaEjercicios() End Sub @@ -332,9 +328,6 @@ Partial Class Finanzas_RepRazonesFinancieras2 GVRatiosOcultarColumnas(GVRatios, 1) - - - Dim CveSubProyecto = DdlSubproyecto.SelectedValue.ToEntero Dim FechasConsultar As String = GetFechasConsultar() @@ -505,6 +498,9 @@ Partial Class Finanzas_RepRazonesFinancieras2 DivPeriodo.Visible = False DdlPeriodo.SelectedValueExist(12) + DVVisualizacion.Visible = False + LblVisualizacion.Visible = False + DdlEjercicio.SelectedValue = Nothing DdlEjercicio2.SelectedValue = Nothing @@ -521,6 +517,8 @@ Partial Class Finanzas_RepRazonesFinancieras2 AddHandler DdlEjercicio2.SelectedIndexChanged, AddressOf DdlEjercicio2_SelectedIndexChanged CargaEjercicios() Else + DVVisualizacion.Visible = True + LblVisualizacion.Visible = True RemoveHandler CType(DdlEjercicio, DropDownList).SelectedIndexChanged, AddressOf DdlEjercicio_SelectedIndexChanged RemoveHandler CType(DdlEjercicio2, DropDownList).SelectedIndexChanged, AddressOf DdlEjercicio2_SelectedIndexChanged @@ -614,7 +612,6 @@ Partial Class Finanzas_RepRazonesFinancieras2 If DdlEjercicio2.SelectedValue.ToEntero >= DdlEjercicio.SelectedValue.ToEntero Then Dim x As Integer = DdlEjercicio.SelectedValue.ToEntero - For x = DdlEjercicio.SelectedValue.ToEntero To DdlEjercicio2.SelectedValue.ToEntero ListaFechas.Add($"{x}-12-31") Next x @@ -623,8 +620,24 @@ Partial Class Finanzas_RepRazonesFinancieras2 Else ' POR MESES - ListaFechas.Add($"{DdlEjercicio.SelectedValue}-01".ToDate.LastDayOfMonth.ToString("yyyy-MM-dd")) - ListaFechas.Add($"{DdlEjercicio2.SelectedValue}-01".ToDate.LastDayOfMonth.ToString("yyyy-MM-dd")) + If DdlVisualizacion.SelectedValue.ToEntero = 1 Then + ListaFechas.Add($"{DdlEjercicio.SelectedValue}-01".ToDate.LastDayOfMonth.ToString("yyyy-MM-dd")) + ListaFechas.Add($"{DdlEjercicio2.SelectedValue}-01".ToDate.LastDayOfMonth.ToString("yyyy-MM-dd")) + Else + + Dim FechaInicial As Date = $"{DdlEjercicio.SelectedValue}-01".ToDate.LastDayOfMonth.ToString("yyyy-MM-dd").ToDate + Dim FechaFinal As Date = $"{DdlEjercicio2.SelectedValue}-01".ToDate.LastDayOfMonth.ToString("yyyy-MM-dd").ToDate + + Dim FechaTemp As Date = FechaInicial.LastDayOfMonth + + ListaFechas.Add(FechaTemp.ToString("yyyy-MM-dd")) + While FechaFinal >= FechaTemp + FechaTemp = FechaTemp.AddMonths(1).LastDayOfMonth + ListaFechas.Add(FechaTemp.ToString("yyyy-MM-dd")) + End While + + + End If End If diff --git a/Sistemas/Empresa.aspx b/Sistemas/Empresa.aspx index 1b70303c2..7326a7b7f 100644 --- a/Sistemas/Empresa.aspx +++ b/Sistemas/Empresa.aspx @@ -1635,82 +1635,170 @@ - - -
-
-
-
-
- - Plantilla Manda Correo -
-
-
-
-
-
- -
-
-
- -
-
- -
  • {"FolioFactura"}
  • -
  • {"ImporteFactura"}
  • -
  • {"FechaFactura"}
  • -
  • {"FechaVencimiento"}
  • -
  • {"RazonSocialEmisor"}
  • -
  • {"RazonSocialReceptor"}
  • - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    -
    -
    -
    -
    + + + +
    + +
    +
    +
    +
    + + Plantilla Manda Correo Venta +
    +
    +
    +
    +
    + +
    +
    + + +
    +
    + +
    + + + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    +
    +
    +
    +
    + +
    +
    +
    +
    + + Plantilla Manda Correo Cotización +
    +
    +
    + +
    +
    + +
    +
    + +
    +
    + +
    + + + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    +
    +
    +
    +
    + +
    + +
    +
    + +
    +
    + +
    + + + + @@ -1788,6 +1876,38 @@ + + + + diff --git a/Sistemas/Empresa.aspx.vb b/Sistemas/Empresa.aspx.vb index f09547665..f7deb0655 100644 --- a/Sistemas/Empresa.aspx.vb +++ b/Sistemas/Empresa.aspx.vb @@ -199,8 +199,7 @@ Partial Class Sistemas_Empresa BtnGuardar.Text = "Guardar Cambios" 'Plantilla Correo - TxtPlantillaVenta.Text = UsuarioActual.Empresa.PlantillaMailVenta - TxtAsunto.Text = UsuarioActual.Empresa.AsuntoPlantillaMailVenta + Else 'Configuración de Modalidad Insert @@ -320,6 +319,12 @@ Partial Class Sistemas_Empresa TxtImporte.Text = .Importe.ToString TipoContabilidad = .TipoContabilidad + TxtPlantillaVenta.Text = .PlantillaMailVenta + TxtAsunto.Text = .AsuntoPlantillaMailVenta + + TxtPlantillaCotizacion.Text = .AsuntoPlantillaMailVentaCotizacion + TxtAsuntoCotizacion.Text = .PlantillaMailVentaCotizacion + 'NUEVOS TxtAreaGeografica.Text = .AreaGeografica DdlProtocolo.Text = .Buzon_Tipo @@ -1317,10 +1322,19 @@ Partial Class Sistemas_Empresa End If Dim ObjEmpresa As New ClsSisEmpresas() - If ObjEmpresa.UpdatePlantillaMail("AsuntoPlantillaMailVenta", TxtAsunto.Text.Trim, "PlantillaMailVenta", TxtPlantillaVenta.Text.Trim, UsuarioActual.CveEmpresa) Then + If ObjEmpresa.UpdatePlantillaMail("AsuntoPlantillaMailVenta", TxtAsunto.Text.Trim, "PlantillaMailVenta", TxtPlantillaVenta.Text.Trim, CveEmpresa) Then + + If ObjEmpresa.UpdatePlantillaMail("AsuntoPlantillaMailVentaCotizacion", TxtAsuntoCotizacion.Text.Trim, "PlantillaMailVentaCotizacion", TxtPlantillaCotizacion.Text.Trim, CveEmpresa) Then + + End If Alert("La plantilla de mail de ventas se guardó correctamente.", TipoMensaje.MsgInformacion) + UsuarioActual.Empresa.PlantillaMailVenta = TxtPlantillaVenta.Text.Trim UsuarioActual.Empresa.AsuntoPlantillaMailVenta = TxtAsunto.Text.Trim + + UsuarioActual.Empresa.AsuntoPlantillaMailVentaCotizacion = TxtPlantillaCotizacion.Text.Trim + UsuarioActual.Empresa.PlantillaMailVentaCotizacion = TxtAsuntoCotizacion.Text.Trim + 'TxtPlantillaVenta.Text = "" 'TxtAsunto.Text = "" End If diff --git a/Sistemas/Empresa2.aspx b/Sistemas/Empresa2.aspx index fb562ab4b..71875ef12 100644 --- a/Sistemas/Empresa2.aspx +++ b/Sistemas/Empresa2.aspx @@ -171,7 +171,7 @@
    - + @@ -218,25 +218,31 @@ - +
    +
    - - +
    + + +
    - - +
    + + +
    -
    + <%--
    @@ -248,7 +254,7 @@
    -
    +
    --%>
    @@ -279,7 +285,7 @@
    -
    +
    @@ -299,7 +305,7 @@
    -
    +
    @@ -320,7 +326,7 @@
    -
    +
    @@ -362,11 +368,7 @@

    -
    -
    - Registrar en ProFact -
    -
    + @@ -461,7 +463,7 @@
    - +
    @@ -522,7 +524,7 @@
    - +
    @@ -673,7 +675,7 @@
    - +
    @@ -710,7 +712,7 @@
    - +
    @@ -785,11 +787,14 @@
    -
    +
    - - - Asunto: +
    + + + +
    +
    @@ -855,7 +860,14 @@
    - Asunto: +
    + + + +
    +
    + + @@ -909,6 +921,7 @@ + diff --git a/Sistemas/Empresa2.aspx.vb b/Sistemas/Empresa2.aspx.vb index 29353fd60..a326f9178 100644 --- a/Sistemas/Empresa2.aspx.vb +++ b/Sistemas/Empresa2.aspx.vb @@ -480,7 +480,7 @@ Partial Class Sistemas_Empresa2 'DdlCvePac.SelectedValueExist(.CvePAC.ToString) DdlRegimen.SelectedValue = .CveRegimenFiscal.ToString TxtCURP.Text = .CURP - TxtImporte.Text.ToDecimal + 'TxtImporte.Text.ToDecimal TxtCIEC.Text = .CIEC 'DdlPlataforma.SelectedValue = .CvePlataforma.ToString UsaAC = .UsaAC @@ -496,7 +496,7 @@ Partial Class Sistemas_Empresa2 DdlTipoCentroDeCostos.SelectedValue = .Tipo_CentroCosto.ToString ChkReqCentroCostos.Checked = .RequiereCentroCostos DdlTerminalTipo.SelectedValue = .PV_TerminalTipo.ToString - TxtImporte.Text = .Importe.ToString + 'TxtImporte.Text = .Importe.ToString TipoContabilidad = .TipoContabilidad TxtPlantillaVenta.Text = .PlantillaMailVenta @@ -760,7 +760,7 @@ Partial Class Sistemas_Empresa2 ChkBuzon_SSL.Checked, TxtBuzon_USR.Text.Trim, TxtBuzon_PWD.Text.Trim, UsuarioActual.CveEmpresa, DdlProtocolo.SelectedValue, "-1", "-1", -1, SSLSoporte, "-1", "-1", "-1", -1, -1, -1, -1, -1, -1, -1, -1, "", TxtAreaGeografica.Text.Trim, -1, -1, TxtNombreCorto.Text, TxtCURP.Text.Trim, DdlRegimen.SelectedValue.ToEntero, 1, - TxtImporte.Text.ToDecimal, TxtCIEC.Text, 1, UsaAC, + -1, TxtCIEC.Text, 1, UsaAC, TxtPorDepreciacion.Text.ToDecimal, TxtExtension.Text, TxtLocalidad.Text, DdlMetodoInventario.SelectedValue.ToEntero, AsientoContable, TxtPeriodoActual.Text.ToEntero, TxtEjercicioActual.Text.ToEntero, ChkDefaultAsistencias.Checked, TxtDiasPermitidos.Text.ToEntero, DdlTipoCentroDeCostos.SelectedValue.ToEntero, ChkReqCentroCostos.Checked, DdlTerminalTipo.SelectedValue.ToEntero, IdCuentaDSV:=-1, IdCuentaImpuestosLocales:=-1, IdCuentaIEPSxAcreditar:=-1, IdCuentaIEPSAcreditable:=-1, diff --git a/Ventas/Clientes.aspx.vb b/Ventas/Clientes.aspx.vb index fe85578dc..7bd9cbc18 100644 --- a/Ventas/Clientes.aspx.vb +++ b/Ventas/Clientes.aspx.vb @@ -2245,26 +2245,53 @@ Partial Class Clientes End If ObjVenta.Dispose() - If UsuarioActual.Empresa.PlantillaMailVenta.Trim.Length > 0 Then - Cuerpo = UsuarioActual.Empresa.PlantillaMailVenta - Cuerpo = Cuerpo.Replace("{""NombreEmpresa""}", UsuarioActual.Empresa.Empresa) - Cuerpo = Cuerpo.Replace("{""NombreCliente""}", LtlCliente.Text.Trim) - Cuerpo = Cuerpo.Replace("{""TipoDocumento""}", TipoComprobante) - Cuerpo = Cuerpo.Replace("{""SerieFolio""}", HdnSerieFolio.Value.ToString()) - If Dr IsNot Nothing Then - Cuerpo = Cuerpo.Replace("{""Fecha""}", Dr("Fecha").ToString().ToDate().ToShortDateString()) - Cuerpo = Cuerpo.Replace("{""Total""}", Dr("Total").ToString().FormatoNumero()) - Cuerpo = Cuerpo.Replace("{""FechaVencimiento""}", Dr("FechaVencimiento").ToString().ToDate().ToShortDateString()) - End If - End If - - If UsuarioActual.Empresa.AsuntoPlantillaMailVenta.Trim.Length > 0 Then - Asunto = UsuarioActual.Empresa.AsuntoPlantillaMailVenta - Asunto = Asunto.Replace("{""TipoDocumento""}", TipoComprobante) - Asunto = Asunto.Replace("{""Sucursal""}", HdnSubProyecto.Value.ToString()) - Asunto = Asunto.Replace("{""SerieFolio""}", HdnSerieFolio.Value.ToString()) - End If - + If HdnTipoDocto.Value.ToString() = "Cot" Then + + If UsuarioActual.Empresa.AsuntoPlantillaMailVentaCotizacion.Trim.Length > 0 Then + Cuerpo = UsuarioActual.Empresa.AsuntoPlantillaMailVentaCotizacion + Cuerpo = Cuerpo.Replace("{""NombreEmpresa""}", UsuarioActual.Empresa.Empresa) + Cuerpo = Cuerpo.Replace("{""NombreCliente""}", LtlCliente.Text.Trim) + Cuerpo = Cuerpo.Replace("{""TipoDocumento""}", TipoComprobante) + Cuerpo = Cuerpo.Replace("{""SerieFolio""}", HdnSerieFolio.Value.ToString()) + If Dr IsNot Nothing Then + Cuerpo = Cuerpo.Replace("{""Fecha""}", Dr("Fecha").ToString().ToDate().ToShortDateString()) + Cuerpo = Cuerpo.Replace("{""Total""}", Dr("Total").ToString().FormatoNumero()) + Cuerpo = Cuerpo.Replace("{""FechaVencimiento""}", Dr("FechaVencimiento").ToString().ToDate().ToShortDateString()) + End If + End If + + If UsuarioActual.Empresa.AsuntoPlantillaMailVentaCotizacion.Trim.Length > 0 Then + Asunto = UsuarioActual.Empresa.AsuntoPlantillaMailVentaCotizacion + Asunto = Asunto.Replace("{""TipoDocumento""}", TipoComprobante) + Asunto = Asunto.Replace("{""Sucursal""}", HdnSubProyecto.Value.ToString()) + Asunto = Asunto.Replace("{""SerieFolio""}", HdnSerieFolio.Value.ToString()) + End If + + Else + + If UsuarioActual.Empresa.PlantillaMailVenta.Trim.Length > 0 Then + Cuerpo = UsuarioActual.Empresa.PlantillaMailVenta + Cuerpo = Cuerpo.Replace("{""NombreEmpresa""}", UsuarioActual.Empresa.Empresa) + Cuerpo = Cuerpo.Replace("{""NombreCliente""}", LtlCliente.Text.Trim) + Cuerpo = Cuerpo.Replace("{""TipoDocumento""}", TipoComprobante) + Cuerpo = Cuerpo.Replace("{""SerieFolio""}", HdnSerieFolio.Value.ToString()) + If Dr IsNot Nothing Then + Cuerpo = Cuerpo.Replace("{""Fecha""}", Dr("Fecha").ToString().ToDate().ToShortDateString()) + Cuerpo = Cuerpo.Replace("{""Total""}", Dr("Total").ToString().FormatoNumero()) + Cuerpo = Cuerpo.Replace("{""FechaVencimiento""}", Dr("FechaVencimiento").ToString().ToDate().ToShortDateString()) + End If + End If + + If UsuarioActual.Empresa.AsuntoPlantillaMailVenta.Trim.Length > 0 Then + Asunto = UsuarioActual.Empresa.AsuntoPlantillaMailVenta + Asunto = Asunto.Replace("{""TipoDocumento""}", TipoComprobante) + Asunto = Asunto.Replace("{""Sucursal""}", HdnSubProyecto.Value.ToString()) + Asunto = Asunto.Replace("{""SerieFolio""}", HdnSerieFolio.Value.ToString()) + End If + End If + + + If UsuarioActual.Empresa.TipoFacturacion = "CFDi" AndAlso HdnTipoDocto.Value.Contiene("Ing", "Egs", "Ant", "Dev") Then Dim PDF As String = $"{Ruta}PDF\{HdnTipoDocto.Value}\{HdnFolioVenta.Value}.pdf" Dim XML As String = $"{Ruta}XML\{HdnTipoDocto.Value}\{HdnFolioVenta.Value}.xml"