This commit is contained in:
2024-06-19 11:04:19 -07:00
10 changed files with 226 additions and 185 deletions

View File

@@ -1448,11 +1448,33 @@ Partial Class Bancos_IE
'RecargaCuentas
CargaCuenta(CveMoneda)
RecargaCuentasDepositos()
ValidaFechaDocumentoDiasPosteriores()
UpDatos.Update()
BtnGuardar.Enabled = True
End Sub
Private Sub ValidaFechaDocumentoDiasPosteriores()
RVTxtFechaDocumento.MaximumValue = NowADS().AddDays(3).ToShortDateString
Calendario.EndDate = NowADS().AddDays(3)
RVTxtFechaDocumento.ErrorMessage = "<b><span style='text-decoration: underline'>ERROR:</span></b> <br/> La fecha del documento no puede ser superior a 3 días de la fecha actual"
If DdlTipoTransaccion.SelectedValue.Contiene("1", "16") Then 'cheques, 3meses
RVTxtFechaDocumento.MaximumValue = NowADS().AddMonths(3).ToShortDateString
RVTxtFechaDocumento.ErrorMessage = "<b><span style='text-decoration: underline'>ERROR:</span></b> <br/> La fecha del documento no puede ser superior a 3 meses de la fecha actual"
Calendario.EndDate = NowADS().AddMonths(3)
End If
If DdlTipoTransaccion.SelectedValue = "2" Then 'transfer, 3semanas
RVTxtFechaDocumento.MaximumValue = NowADS().AddDays(21).ToShortDateString
RVTxtFechaDocumento.ErrorMessage = "<b><span style='text-decoration: underline'>ERROR:</span></b> <br/> La fecha del documento no puede ser superior a 3 semanas de la fecha actual"
Calendario.EndDate = NowADS().AddDays(21)
End If
UpDatos.Update()
UpGuardar.Update()
End Sub
Protected Sub DdlCuenta_SelectedIndexChanged(sender As Object, e As EventArgs) Handles DdlCuenta.SelectedIndexChanged
'si solo es de egreso el movimiento debe de generar el siguiente folio.

View File

@@ -268,6 +268,7 @@
<asp:DropDownList ID="DdlOtrosPagos" Width="100%" CssClass="form-control input-sm select2me" runat="server" AutoPostBack="true" OnSelectedIndexChanged="DdlOtrosPagos_SelectedIndexChanged">
<asp:ListItem Value="-1">-</asp:ListItem>
<asp:ListItem Value="2">Otros Egresos</asp:ListItem>
<asp:ListItem Value="3">Deudores Diversos</asp:ListItem>
</asp:DropDownList>
</div>
</div>

View File

@@ -348,7 +348,10 @@ public partial class Bancos_PagoAcreedor : ClsPaginas
if (ImporteComision != 0 && MsgError == "")
{
ImporteComisionMN = (ImporteComision * TCPago).RoundSQL();
if (!ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovtoComision, ImporteComision, ImporteComisionMN, 255, Ref, Conc, CveIE: CveIE, CveProveedor: DdlProveedores.SelectedValue.ToEntero(),CveIEDevolucion: gvr.DataKey("CveIE").ToEntero(), TipoCambio: TC, TipoCambioPago: TCPago, CveSubProyecto: DdlSubProyectoPago.SelectedValue.ToEntero()))
int tTipoConceptoOtro = 255;
if (DdlOtrosPagos.SelectedValue == "3") tTipoConceptoOtro = 43; //deudores diversos
if (!ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovtoComision, ImporteComision, ImporteComisionMN, tTipoConceptoOtro, Ref, Conc, CveIE: CveIE, CveProveedor: DdlProveedores.SelectedValue.ToEntero(),CveIEDevolucion: gvr.DataKey("CveIE").ToEntero(), TipoCambio: TC, TipoCambioPago: TCPago, CveSubProyecto: DdlSubProyectoPago.SelectedValue.ToEntero()))
{
MsgError = "No se pudo insertar concepto de pago acreedor";
break;
@@ -394,9 +397,10 @@ public partial class Bancos_PagoAcreedor : ClsPaginas
if (MsgError.Equals(""))
{
ObjIE.Commit();
if (Msg.ToString().Equals(""))
{
Msg.AppendFormat("El Documento se guardo correctamente. Folio <b><a href='/Bancos/IE.aspx?CveIE={0}' target='_blank' class='Texto'>{1}</a></b> <br/>", CveIE, ObjIE.Folio);
Msg.AppendFormat("El Documento se guardo correctamente. <br/> Folio <b><a href='/Bancos/IE.aspx?CveIE={0}' target='_blank' class='Texto'>{1}</a></b> <br/>", CveIE, ObjIE.Folio);
}
//GUARDA COMPROBANTE
@@ -432,11 +436,14 @@ public partial class Bancos_PagoAcreedor : ClsPaginas
// }
//}
if (IDPoliza > 0)
{
Msg.AppendFormat(@"<br/><br/><a class=""Texto"" target='_blank' href=""/Contabilidad/RegPoliza.aspx?IdPoliza={0}"">Ver Póliza</a>", IDPoliza);
}
ObjIE.Commit();
//if (IDPoliza > 0)
//{
// Msg.AppendFormat(@"<br/><br/><a class=""Texto"" target='_blank' href=""/Contabilidad/RegPoliza.aspx?IdPoliza={0}"">Ver Póliza</a>", IDPoliza);
//}
Msg.AppendFormat(@"<a class=""Texto"" target='_blank' href=""/Contabilidad/RegPrePoliza.aspx?CvePrePoliza={0}"">Ver Póliza</a><br/>", CvePrePoliza);
Msg.AppendFormat($"<a class='Texto' target='_blank' href='/Compras/PopUpVerFactura.aspx?P={Encripta($"OP=PREPO&CvePrePoliza={CvePrePoliza}")}'>Imprimir</a>");
}
else
{
@@ -616,9 +623,10 @@ public partial class Bancos_PagoAcreedor : ClsPaginas
if (MsgError.Equals(""))
{
ObjIE.Commit();
if (Msg.ToString().Equals(""))
{
Msg.Append("El Documento se guardo correctamente");
Msg.Append("El Documento se guardo correctamente.<br/>");
}
System.IO.FileInfo archivo = null;
@@ -648,11 +656,13 @@ public partial class Bancos_PagoAcreedor : ClsPaginas
// }
//}
if (IDPoliza > 0)
{
Msg.AppendFormat(@"<br/><br/><a class=""Texto"" target='_blank' href=""/Contabilidad/RegPoliza.aspx?IdPoliza={0}"">Ver Póliza</a>", IDPoliza);
}
ObjIE.Commit();
//if (IDPoliza > 0)
//{
// Msg.AppendFormat(@"<br/><br/><a class=""Texto"" target='_blank' href=""/Contabilidad/RegPoliza.aspx?IdPoliza={0}"">Ver Póliza</a>", IDPoliza);
//}
Msg.AppendFormat(@"<a class=""Texto"" target='_blank' href=""/Contabilidad/RegPrePoliza.aspx?CvePrePoliza={0}"">Ver Póliza</a><br/>", CvePrePoliza);
Msg.AppendFormat($"<a class='Texto' target='_blank' href='/Compras/PopUpVerFactura.aspx?P={Encripta($"OP=PREPO&CvePrePoliza={CvePrePoliza}")}'>Imprimir</a>");
}
else
{

View File

@@ -311,12 +311,13 @@ public partial class Bancos_PagoDeudor : ClsPaginas
if (MsgError.Equals(""))
{
ObjIE.Commit();
if (Msg.ToString().Equals(""))
{
Msg.Append("El Documento se guardo correctamente");
Msg.Append("El Documento se guardo correctamente.<br/>");
}
System.IO.FileInfo archivo = null;
Msg.AppendFormat("<br/><br/> Folio: <a class='Texto' target='_blank' href='/Bancos/IE.aspx?CveIE={0}'>{1}</a><br/>", CveIE, TxtFolioPrestamo.Text.Trim());
Msg.AppendFormat("Folio: <a class='Texto' target='_blank' href='/Bancos/IE.aspx?CveIE={0}'>{1}</a><br/>", CveIE, TxtFolioPrestamo.Text.Trim());
if (DdlTipoTransaccionPrestamo.SelectedValue.ToEntero().Contiene(2, 8, 9))
{
@@ -344,11 +345,13 @@ public partial class Bancos_PagoDeudor : ClsPaginas
// }
//}
if (IDPoliza > 0)
{
Msg.AppendFormat(@"<br/><br/><a class=""Texto"" target='_blank' href=""/Contabilidad/RegPoliza.aspx?IdPoliza={0}"">Ver Póliza</a>", IDPoliza);
}
ObjIE.Commit();
//if (IDPoliza > 0)
//{
// Msg.AppendFormat(@"<br/><br/><a class=""Texto"" target='_blank' href=""/Contabilidad/RegPoliza.aspx?IdPoliza={0}"">Ver Póliza</a>", IDPoliza);
//}
Msg.AppendFormat(@"<a class=""Texto"" target='_blank' href=""/Contabilidad/RegPrePoliza.aspx?CvePrePoliza={0}"">Ver Póliza</a><br/>", CvePrePoliza);
Msg.AppendFormat($"<a class='Texto' target='_blank' href='/Compras/PopUpVerFactura.aspx?P={Encripta($"OP=PREPO&CvePrePoliza={CvePrePoliza}")}'>Imprimir</a>");
}
else
{
@@ -682,12 +685,13 @@ public partial class Bancos_PagoDeudor : ClsPaginas
if (MsgError.Equals(""))
{
ObjIE.Commit();
if (Msg.ToString().Equals(""))
{
Msg.Append("El Documento se guardo correctamente");
Msg.Append("El Documento se guardo correctamente.<br/>");
}
System.IO.FileInfo archivo = null;
Msg.AppendFormat("<br/><br/> Folio: <a class='Texto' target='_blank' href='/Bancos/IE.aspx?CveIE={0}'>{1}</a><br/>", CveIE, TxtFolio.Text.Trim());
Msg.AppendFormat("Folio: <a class='Texto' target='_blank' href='/Bancos/IE.aspx?CveIE={0}'>{1}</a><br/>", CveIE, TxtFolio.Text.Trim());
if (DdlTipoTransaccion.SelectedValue.ToEntero().Contiene(2, 8, 9))
{
@@ -715,11 +719,13 @@ public partial class Bancos_PagoDeudor : ClsPaginas
// }
//}
if (IDPoliza > 0)
{
Msg.AppendFormat(@"<br/><br/><a class=""Texto"" target='_blank' href=""/Contabilidad/RegPoliza.aspx?IdPoliza={0}"">Ver Póliza</a>", IDPoliza);
}
ObjIE.Commit();
//if (IDPoliza > 0)
//{
// Msg.AppendFormat(@"<br/><br/><a class=""Texto"" target='_blank' href=""/Contabilidad/RegPoliza.aspx?IdPoliza={0}"">Ver Póliza</a>", IDPoliza);
//}
Msg.AppendFormat(@"<a class=""Texto"" target='_blank' href=""/Contabilidad/RegPrePoliza.aspx?CvePrePoliza={0}"">Ver Póliza</a><br/>", CvePrePoliza);
Msg.AppendFormat($"<a class='Texto' target='_blank' href='/Compras/PopUpVerFactura.aspx?P={Encripta($"OP=PREPO&CvePrePoliza={CvePrePoliza}")}'>Imprimir</a>");
}
else
{

View File

@@ -849,12 +849,11 @@ Partial Class Bancos_PopIECompras
#Region "DDL'S CHANGED"
Protected Sub DdlTipoTransaccion_SelectedIndexChanged(sender As Object, e As EventArgs) Handles DdlTipoTransaccion.SelectedIndexChanged
Dim valor As Integer = DirectCast(sender, DropDownList).SelectedValue.ToEntero
Dim dr As DataRow = GlobalDTTipoTransacciones.FiltroPrimero(String.Format("CveTipoTransaccion = {0}", DdlTipoTransaccion.SelectedValue)) 'Egs o Ing
'Dim dr As DataRow = GlobalDTTipoTransacciones.FiltroPrimero(String.Format("CveTipoTransaccion = {0}", DdlTipoTransaccion.SelectedValue)) 'Egs o Ing
Select Case valor
Case 1
LblPagueseA.Text = "Páguese a"
Case 2
LblPagueseA.Text = "Beneficiario"
End Select
@@ -1723,17 +1722,20 @@ Partial Class Bancos_PopIECompras
Private Sub ValidaFechaDocumentoDiasPosteriores()
RVTxtFechaDocumento.MaximumValue = NowADS().AddDays(3).ToShortDateString
Calendario.EndDate = NowADS().AddDays(3)
RVTxtFechaDocumento.ErrorMessage = "<b><span style='text-decoration: underline'>ERROR:</span></b> <br/> La fecha del documento no puede ser superior a 3 días de la fecha actual"
RVTxtFechaDocumento.MaximumValue = NowADS().AddDays(2).ToShortDateString
Calendario.EndDate = NowADS().AddDays(2)
RVTxtFechaDocumento.ErrorMessage = "<b><span style='text-decoration: underline'>ERROR:</span></b> <br/> La fecha del documento no puede ser superior a 6 meses de la fecha actual"
If DdlTipoTransaccion.SelectedValue.ToEntero.Contiene(1, 16) Then
RVTxtFechaDocumento.MaximumValue = NowADS().AddDays(30).ToShortDateString
RVTxtFechaDocumento.ErrorMessage = "<b><span style='text-decoration: underline'>ERROR:</span></b> <br/> La fecha del documento no puede ser superior a 6 meses de la fecha actual"
Calendario.EndDate = NowADS().AddDays(30)
If DdlTipoTransaccion.SelectedValue.Contiene("1", "16") Then 'cheques, 3meses
RVTxtFechaDocumento.MaximumValue = NowADS().AddMonths(3).ToShortDateString
RVTxtFechaDocumento.ErrorMessage = "<b><span style='text-decoration: underline'>ERROR:</span></b> <br/> La fecha del documento no puede ser superior a 3 meses de la fecha actual"
Calendario.EndDate = NowADS().AddMonths(3)
End If
If DdlTipoTransaccion.SelectedValue = "2" Then 'transfer, 3semanas
RVTxtFechaDocumento.MaximumValue = NowADS().AddDays(21).ToShortDateString
RVTxtFechaDocumento.ErrorMessage = "<b><span style='text-decoration: underline'>ERROR:</span></b> <br/> La fecha del documento no puede ser superior a 3 semanas de la fecha actual"
Calendario.EndDate = NowADS().AddDays(21)
End If
UpDatos.Update()
UpGuardar.Update()

View File

@@ -161,7 +161,7 @@
</div>
</div>
<div class="row" runat="server" id="rowComisiones" visible="false">
<div class="row" runat="server" id="rowComisiones" >
<label class="col-xs-4" runat="server" id="lblpagocomisiones">Comisiones:</label>
<div class="col-xs-8">
<asp:DropDownList ID="DdlOtrosPagos" CssClass="form-control input-sm select2me" runat="server" AutoPostBack="true" Width="100%">

View File

@@ -325,9 +325,7 @@ Partial Class Bancos_PopIEVentas
ViewState("CveIE") = -1
End If
If UsuarioActual.CveEmpresa.Contiene(1, 4, 7, 11, 12, 72, 80, 119) Then
rowComisiones.Visible = True
End If
'rowComisiones.Visible = True
'SI USUARIO USA AMORTIZACIÓN CONTABLE
If UsuarioActual.Empresa.TipoContabilidad = 2 AndAlso UsuarioActual.Empresa.UsaAC Then
@@ -547,10 +545,11 @@ Partial Class Bancos_PopIEVentas
CargaCorteCaja()
End If
If UsuarioActual.Empresa.Funcionalidad(531) = "1" Then 'toma como proridad el que viene de
If UsuarioActual.Empresa.Funcionalidad(531) = "1" OrElse (dr("CveCorte").ToString.ToEntero > 0) Then 'toma como proridad el que viene de
CveCorte = dr("CveCorte").ToString.ToEntero
End If
If RFCCliente.ToUpper <> "XAXX010101000" Then
Dim CveProveedor As Integer = GlobalDTCompProveedores(UsuarioActual.CveEmpresa, RFC:=RFCCliente.ToUpper).FiltroPrimeroValor("CveProveedor").ToEntero
@@ -753,7 +752,7 @@ Partial Class Bancos_PopIEVentas
#Region "DDL'S CHANGED"
Protected Sub DdlTipoTransaccion_SelectedIndexChanged(sender As Object, e As EventArgs) Handles DdlTipoTransaccion.SelectedIndexChanged
Dim valor As Integer = DirectCast(sender, DropDownList).SelectedValue.ToEntero
Dim dr As DataRow = GlobalDTTipoTransacciones.FiltroPrimero(String.Format("CveTipoTransaccion = {0}", DdlTipoTransaccion.SelectedValue)) 'Egs o Ing
'Dim dr As DataRow = GlobalDTTipoTransacciones.FiltroPrimero(String.Format("CveTipoTransaccion = {0}", DdlTipoTransaccion.SelectedValue)) 'Egs o Ing
Select Case valor
Case 1
@@ -1239,7 +1238,7 @@ Partial Class Bancos_PopIEVentas
Pago.CveMonedaPago = CveMoneda
Pago.Referencia = VentaActual.SerieFolio
If DdlOtrosPagos.SelectedValue = "2" Then
ImportePagado = TxtImporte.Text.Trim.ToDecimal.RoundSQL - TxtComision.Text.ToDecimal
ImportePagado = TxtImporte.Text.Trim.ToDecimal.RoundSQL + TxtComision.Text.ToDecimal
Else
ImportePagado = TxtImporte.Text.Trim.ToDecimal.RoundSQL
End If
@@ -1266,7 +1265,7 @@ Partial Class Bancos_PopIEVentas
If CveIE > 0 Then
Pago.ImportePago = ImportePagado
Pago.ImportePagoVenta = ImportePagado
Pago.ImportePagoVenta = ImportePagado - Pago.OtroGastoIngreso
Pago.CveIE = CveIE
Pago.TipoPago = "B"
@@ -1281,7 +1280,7 @@ Partial Class Bancos_PopIEVentas
Case "2" ' FyE
Pago.ImportePago = ImportePagado
Pago.ImportePagoVenta = ImportePagado
Pago.ImportePagoVenta = ImportePagado - Pago.OtroGastoIngreso
Pago.TipoPago = "FyE"
Pago.CvePersonal = DdlFuncionarioEmpleado.SelectedValue.ToEntero
Pago.Referencia = DdlFuncionarioEmpleado.SelectedItem.ToString

View File

@@ -1627,20 +1627,21 @@ Partial Class Bancos_ProveedoresAbonar
Private Sub ValidaFechaDocumentoDiasPosteriores()
RVTxtFechaDocumento.MaximumValue = NowADS().AddDays(2).ToShortDateString
RVTxtFechaDocumentoMenor.MaximumValue = NowADS().AddDays(2).ToShortDateString
RVTxtFechaDocumento.MaximumValue = NowADS().AddDays(3).ToShortDateString
RVTxtFechaDocumentoMenor.MaximumValue = NowADS().AddDays(3).ToShortDateString
RVTxtFechaDocumento.ErrorMessage = "<b><span style='text-decoration: underline'>ERROR:</span></b> <br/> La fecha del documento no puede ser superior a 3 días de la fecha actual"
RVTxtFechaDocumento.ErrorMessage = "<b><span style='text-decoration: underline'>ERROR:</span></b> <br/> La fecha del documento no puede ser superior a 6 meses de la fecha actual"
Calendario.EndDate = NowADS().AddDays(3)
Calendario.EndDate = NowADS().AddDays(2)
If DdlTipoTransaccion.SelectedValue.ToEntero.Contiene(1, 16) Then
RVTxtFechaDocumento.MaximumValue = NowADS().AddDays(182).ToShortDateString
RVTxtFechaDocumentoMenor.MaximumValue = NowADS().AddDays(182).ToShortDateString
RVTxtFechaDocumento.ErrorMessage = "<b><span style='text-decoration: underline'>ERROR:</span></b> <br/> La fecha del documento no puede ser superior a 6 meses de la fecha actual"
Calendario.EndDate = NowADS().AddDays(182)
If DdlTipoTransaccion.SelectedValue.Contiene("1", "16") Then 'cheques, 3meses
RVTxtFechaDocumento.MaximumValue = NowADS().AddMonths(3).ToShortDateString
RVTxtFechaDocumento.ErrorMessage = "<b><span style='text-decoration: underline'>ERROR:</span></b> <br/> La fecha del documento no puede ser superior a 3 meses de la fecha actual"
Calendario.EndDate = NowADS().AddMonths(3)
End If
If DdlTipoTransaccion.SelectedValue = "2" Then 'transfer, 3semanas
RVTxtFechaDocumento.MaximumValue = NowADS().AddDays(21).ToShortDateString
RVTxtFechaDocumento.ErrorMessage = "<b><span style='text-decoration: underline'>ERROR:</span></b> <br/> La fecha del documento no puede ser superior a 3 semanas de la fecha actual"
Calendario.EndDate = NowADS().AddDays(21)
End If
UpDatos.Update()

View File

@@ -468,7 +468,7 @@ Partial Class ContabilidadC_RegPrePolizaS
End If
ObjContabilidad.GetContabilizacionDiarioDetalle(CvePrePoliza, UsuarioActual.CveEmpresa)
DtMovimientos = ObjContabilidad.DtResultados.FiltraParametros($"CveEmpresa = {UsuarioActual.CveEmpresa}")
DtMovimientos = ObjContabilidad.DtResultados
If dr("Modulo").ToString.Contiene("Banc/FluctuaA", "Banc/FluctuaC", "Banc/FluctuaV", "Banc/FluctuaFilial", "Banc/FluctuaAD") Then
BtnEliminar.Enabled = False

View File

@@ -87,8 +87,8 @@
<div class="titlefiltros caption">
<div class="row">
<asp:Label ID="LblSubProyecto" runat="server" class="col-md-1 truncate">SubProyecto:</asp:Label>
<div runat="server" id="DivSubProyecto" class="col-md-2">
<asp:ListBox ID="DdlSubProyectos" CssClass="select2me" runat="server" DataTextField="SubProyecto" DataValueField="CveSubProyecto" Style="width: 100%" data-text="Todos" SelectionMode="Multiple"></asp:ListBox>
<div runat="server" id="DivSubProyecto" class="col-md-3">
<asp:ListBox ID="DdlSubProyectos" CssClass="form-control ddlFiltros input-sm select2me Widthall" Height="30px" runat="server" DataTextField="SubProyecto" DataValueField="CveSubProyecto" Style="width: 100%" data-text="Todos" SelectionMode="Multiple"></asp:ListBox>
</div>
<div class="col-md-1 truncate">
Fecha Inicio: