Merge branch 'master' of http://192.168.10.111:8383/SIG
This commit is contained in:
@@ -220,6 +220,7 @@ Partial Class Ventas_FacturacionGlobal
|
||||
ObjFactura.DtRemisionesPS = DtRemisionesPS
|
||||
ObjFactura.DtRemisiones = DtRemisiones.FiltraParametros($"CveVenta IN ({SbRemisiones.ToString()})")
|
||||
ObjFactura.DtPagosFacturaGlobal = DtPagosFacturaGlobal
|
||||
ObjFactura.CveUsoCFDI = 23 'S01 - Sin efectos fiscales'
|
||||
|
||||
Dim RowNum As Integer = 0
|
||||
For Each Dr As DataRow In ObjFactura.DtRemisionesPS.Rows
|
||||
|
||||
@@ -4,6 +4,7 @@ Option Strict On
|
||||
Imports System.Data
|
||||
Imports System.IO
|
||||
Imports System.Net.Http
|
||||
Imports CrystalDecisions.CrystalReports.Engine
|
||||
Imports Extensiones
|
||||
Imports Modelos.Factura
|
||||
|
||||
@@ -469,6 +470,28 @@ Partial Class Ventas_PVCobranza
|
||||
Else
|
||||
e.Row.FCLinkButton("BtnPagar").Visible = False
|
||||
End If
|
||||
End If
|
||||
|
||||
If e.Row.DBCampo("Fecha") <> Now.ToShortDateString Then
|
||||
e.Row.FCLinkButton("BtnPagar").Enabled = False
|
||||
e.Row.FCLinkButton("BtnPagar").Text = "Cobrar"
|
||||
'e.Row.FCLinkButton("BtnPagar").CssClass = "btn btn-xs default"
|
||||
e.Row.FCLinkButton("BtnPagar").OnClientClick =
|
||||
"bootbox.dialog({" &
|
||||
"message: 'No se puede realizar un cobro a una remisión de días anteriores.<br/> Favor de cancelar la remisión y generarla con fecha actual. ', " &
|
||||
"className: 'header-yellow', " &
|
||||
"onEscape: function() {}, " &
|
||||
"title: '<i class=""fa fa-warning""></i> Advertencia', " &
|
||||
"buttons: { " &
|
||||
"success: { label: '', className: 'hide', callback: function() {} }, " &
|
||||
"danger: { label: '', className: 'hide', callback: function() {} }, " &
|
||||
"main: { label: 'Aceptar', className: 'yellow', callback: function() {} } " &
|
||||
"} " &
|
||||
"});" &
|
||||
"return false;"
|
||||
|
||||
'e.Row.BackColor = Drawing.ColorTranslator.FromHtml("#3598dc")
|
||||
'e.Row.CssClass = "blue-madison"
|
||||
End If
|
||||
|
||||
End If
|
||||
@@ -819,6 +842,14 @@ Partial Class Ventas_PVCobranza
|
||||
GuardaLog(ex.ToString())
|
||||
End Try
|
||||
|
||||
If MsgError = "" Then
|
||||
If ObjConta.ValidacionesPrePoliza(CvePrePoliza, UsuarioActual, Opcion:=5, CveVenta:=respFactura.CveVenta) Then
|
||||
If ObjConta.ValorPolizaDescuadre > 0 Then
|
||||
GuardaLogAD($"Ventas/Ventas-NCGeneradas | Error:{ObjConta.MensajePolizaDescuadre} Diferencia:{ObjConta.ValorDiferencia} | CvePrePoliza:{CvePrePoliza}", "LogPrePolizas")
|
||||
End If
|
||||
End If
|
||||
End If
|
||||
|
||||
If MsgError = "" Then
|
||||
ObjVentas2.Commit()
|
||||
Dim msBuild As New StringBuilder()
|
||||
@@ -877,33 +908,34 @@ Partial Class Ventas_PVCobranza
|
||||
msBuild.AppendFormat("{0}", pdfNC)
|
||||
End If
|
||||
|
||||
If respNC IsNot Nothing Then
|
||||
For Each dr As DataRow In respNC.Factura.DtAnticiposAplicados.Rows
|
||||
msBuild.AppendLine($"<br><a class=""Texto"" target='_blank' href=""/Compras/PopUpVerFactura.aspx?P={Encripta(String.Format("OP=AMORTIZACIONHIS&CVEIE={0}&CVEVENTA={1}&CVECLIENTE={2}&CVEVENTAAMORTIZADA={3}&MONTO={4}",
|
||||
dr("CveIE").ToString,
|
||||
dr("CveVenta").ToString,
|
||||
respNC.Factura.CveCliente,
|
||||
respNC.CveVenta,
|
||||
respNC.Factura.Total))}"">Imprimir Saldo Aplicado {dr("Folio").ToString}</a><br/>")
|
||||
Next
|
||||
Else
|
||||
For Each dr As DataRow In respFactura.Factura.DtAnticiposAplicados.Rows
|
||||
msBuild.AppendLine($"<br><a class=""Texto"" target='_blank' href=""/Compras/PopUpVerFactura.aspx?P={Encripta(String.Format("OP=AMORTIZACIONHIS&CVEIE={0}&CVEVENTA={1}&CVECLIENTE={2}&CVEVENTAAMORTIZADA={3}&MONTO={4}",
|
||||
dr("CveIE").ToString,
|
||||
dr("CveVenta").ToString,
|
||||
respFactura.Factura.CveCliente,
|
||||
respFactura.CveVenta,
|
||||
respFactura.Factura.Total))}"">Imprimir Saldo Aplicado {dr("Folio").ToString}</a><br/>")
|
||||
Next
|
||||
End If
|
||||
|
||||
|
||||
If Not String.IsNullOrEmpty(MsgTimbrado) Then
|
||||
msBuild.AppendFormat("<br/>{0}<br/>", MsgTimbrado)
|
||||
End If
|
||||
|
||||
|
||||
|
||||
If respNC IsNot Nothing Then
|
||||
For Each dr As DataRow In respNC.Factura.DtAnticiposAplicados.Rows
|
||||
msBuild.AppendLine($"<br><a class=""Texto"" target='_blank' href=""/Compras/PopUpVerFactura.aspx?P={Encripta(String.Format("OP=AMORTIZACIONHIS&CVEIE={0}&CVEVENTA={1}&CVECLIENTE={2}&CVEVENTAAMORTIZADA={3}&MONTO={4}&SALDO={5}",
|
||||
dr("CveIE").ToString,
|
||||
dr("CveVenta").ToString,
|
||||
respNC.Factura.CveCliente,
|
||||
respNC.CveVenta,
|
||||
respNC.Factura.Total,
|
||||
(respNC.Factura.Total - respNC.Factura.DtAnticiposAplicados.SUM("Importe"))))}"">Imprimir historial {dr("Folio").ToString}</a><br/>")
|
||||
Next
|
||||
Else
|
||||
For Each dr As DataRow In respFactura.Factura.DtAnticiposAplicados.Rows
|
||||
msBuild.AppendLine($"<br><a class=""Texto"" target='_blank' href=""/Compras/PopUpVerFactura.aspx?P={Encripta(String.Format("OP=AMORTIZACIONHIS&CVEIE={0}&CVEVENTA={1}&CVECLIENTE={2}&CVEVENTAAMORTIZADA={3}&MONTO={4}&SALDO={5}",
|
||||
dr("CveIE").ToString,
|
||||
dr("CveVenta").ToString,
|
||||
respFactura.Factura.CveCliente,
|
||||
respFactura.CveVenta,
|
||||
respFactura.Factura.Total,
|
||||
(respFactura.Factura.Total - respFactura.Factura.DtAnticiposAplicados.SUM("Importe"))))}"">Imprimir historial {dr("Folio").ToString}</a><br/>")
|
||||
Next
|
||||
End If
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -58,7 +58,7 @@
|
||||
<tr align="left">
|
||||
<td class="text-right"><b>Folio:</b></td>
|
||||
<td>
|
||||
<asp:TextBox ID="TxtFolio" runat="server" MaxLength="12" Width="230px" Height="30px"></asp:TextBox>
|
||||
<asp:TextBox ID="TxtFolio" runat="server" MaxLength="16" Width="230px" Height="30px"></asp:TextBox>
|
||||
</td>
|
||||
<td class="text-right"><b>Folio Fiscal (UUID):</b></td>
|
||||
<td>
|
||||
|
||||
@@ -425,8 +425,26 @@ Partial Class Ventas_Promociones
|
||||
End If
|
||||
End Sub
|
||||
Protected Sub DdlPS_SelectedIndexChanged(sender As Object, e As EventArgs) Handles DdlPS.selectedindexchange
|
||||
|
||||
DdlTipoPromocion.Items.FindByValue("1").Enabled = True
|
||||
DdlTipoPromocion.Items.FindByValue("3").Enabled = True
|
||||
|
||||
If EmpresaGrupoDiaz Then
|
||||
BtnAgregar.Enabled = False
|
||||
Dim CvePS As Integer = DdlPS.SelectedValue.ToEntero
|
||||
|
||||
Dim TipCveTipoPS As Integer = GlobalDTPS(UsuarioActual.CveEmpresa, CvePS).FiltroPrimeroValor("CveTipoPS").ToEntero
|
||||
|
||||
If TipCveTipoPS = 1 Then
|
||||
Alert("El producto esta registrado como servicio", TipoMensaje.MsgAdvertencia)
|
||||
Else
|
||||
BtnAgregar.Enabled = True
|
||||
End If
|
||||
|
||||
UpAgregar.Update()
|
||||
|
||||
End If
|
||||
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
@@ -1409,6 +1427,8 @@ Partial Class Ventas_Promociones
|
||||
DTPlantilla.Columns.Add("CodigoPS", GetType(String))
|
||||
DTPlantilla.Columns.Add("RinTamaño", GetType(String))
|
||||
|
||||
Dim HayServicios As Boolean = False
|
||||
Dim SBServiciosEnconrtados As New StringBuilder
|
||||
|
||||
Dim DTPS As DataTable = New DataTable
|
||||
Dim DTRines As DataTable = New DataTable
|
||||
@@ -1499,16 +1519,32 @@ Partial Class Ventas_Promociones
|
||||
dRow("CodigoPS") = If(CveClasificacion > 0, "Todos", CodigoPS)
|
||||
End If
|
||||
|
||||
If EmpresaGrupoDiaz AndAlso CvePS > 0 Then
|
||||
Dim CveTipoPS As Integer = DTPS.FiltroPrimeroValor("CveTipoPS", $"Codigo = '{CodigoStr}'").ToString().ToEntero()
|
||||
If CveTipoPS = 1 Then
|
||||
HayServicios = True
|
||||
SBServiciosEnconrtados.AppendLine($"{CodigoStr}<br>")
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
End If
|
||||
RegistroActual = RegistroActual + 1
|
||||
|
||||
Next
|
||||
|
||||
If Errores.ToString.Length = 0 Then
|
||||
If Errores.ToString.Length = 0 AndAlso Not HayServicios Then
|
||||
DTPlantilla.AcceptChanges()
|
||||
Return True
|
||||
Else
|
||||
Alert(Errores.ToString, TipoMensaje.MsgAdvertencia)
|
||||
|
||||
If EmpresaGrupoDiaz AndAlso HayServicios Then
|
||||
Alert($"{Errores.ToString} <br>Se detectaron productos que estan registrados como servicios:<br>{SBServiciosEnconrtados.ToString}", TipoMensaje.MsgAdvertencia)
|
||||
|
||||
Else
|
||||
Alert(Errores.ToString, TipoMensaje.MsgAdvertencia)
|
||||
End If
|
||||
|
||||
Return False
|
||||
End If
|
||||
|
||||
|
||||
@@ -249,8 +249,8 @@
|
||||
<div class="col-md-1 truncate">Condiciones de Pago</div>
|
||||
<div class="col-md-2">
|
||||
<asp:DropDownList ID="DdlCondicionesPago" runat="server" AppendDataBoundItems="true" Class="table-group-action-input form-control input-inline input-small input-sm select2me">
|
||||
<asp:ListItem Selected="True" Text="Todos" Value="-1"></asp:ListItem>
|
||||
<asp:ListItem Text="Crédito" Value="1"></asp:ListItem>
|
||||
<asp:ListItem Text="Todos" Value="-1"></asp:ListItem>
|
||||
<asp:ListItem Selected="True" Text="Crédito" Value="1"></asp:ListItem>
|
||||
<asp:ListItem Text="Contado" Value="0"></asp:ListItem>
|
||||
</asp:DropDownList>
|
||||
|
||||
|
||||
@@ -107,6 +107,8 @@ Partial Class Ventas_RepRecuperacion
|
||||
DdlClientes.ddl.Items.Insert(0, New ListItem("Todos", "-1"))
|
||||
End If
|
||||
|
||||
If UsuarioActual.CveEmpresa = 119 Then DdlCondicionesPago.SelectedValue = "-1"
|
||||
|
||||
'Carga SubProyectos
|
||||
'DdlSubProyecto.DataSource = GlobalDTSubProyectosUsuarios(UsuarioActual.CveUsuario, -1, UsuarioActual.CveEmpresa, -1, 1)
|
||||
'DdlSubProyecto.DataBind()
|
||||
|
||||
@@ -8360,7 +8360,7 @@
|
||||
</div>
|
||||
<div class="form-group form-md-line-input input-iconright col-xs-6">
|
||||
<asp:TextBox ID="TxtTelefonoCliente" CssClass="form-control " runat="server" MaxLength="10" CausesValidation="true"></asp:TextBox>
|
||||
<asp:RequiredFieldValidator ID="RFVTelefonoCliente" runat="server" ControlToValidate="TxtTelefonoCliente" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Teléfono''</b> es necesario, por favor ingréselo." ValidationGroup="GrpGuardarCliente"></asp:RequiredFieldValidator>
|
||||
<%--<asp:RequiredFieldValidator ID="RFVTelefonoCliente" runat="server" ControlToValidate="TxtTelefonoCliente" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Teléfono''</b> es necesario, por favor ingréselo." ValidationGroup="GrpGuardarCliente"></asp:RequiredFieldValidator>--%>
|
||||
<asp:RegularExpressionValidator ID="RevTelefonoCliente" runat="server" CssClass="help-block errorimput" ValidationExpression="\d{10}" ControlToValidate="TxtTelefonoCliente" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Teléfono''</b> no es válido, por favor ingrése uno correcto." ValidationGroup="GrpGuardarCliente"></asp:RegularExpressionValidator>
|
||||
<label for="<%= TxtTelefonoCliente.ClientID.ToString()%>">Teléfono:</label>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user