-
This commit is contained in:
@@ -1025,6 +1025,21 @@ Partial Class Compras_Compras
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Private Property SubTotalRefacturacion As Decimal
|
||||
Get
|
||||
|
||||
If ViewState("SubTotalRefacturacion") Is Nothing Then
|
||||
ViewState("SubTotalRefacturacion") = 0.0D
|
||||
End If
|
||||
|
||||
Return ViewState("SubTotalRefacturacion").ToString.ToDecimal
|
||||
|
||||
End Get
|
||||
Set(value As Decimal)
|
||||
ViewState("SubTotalRefacturacion") = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Private Property IVAOriginal As Double
|
||||
Get
|
||||
|
||||
@@ -2165,7 +2180,7 @@ Partial Class Compras_Compras
|
||||
|
||||
DdlRetIVAConcepto.Items.Add(New ListItem("Arrendamiento", "4"))
|
||||
''If UsuarioActual.Empresa.Funcionalidad(577).ToEntero = 1 Then
|
||||
'DdlRetIVAConcepto.Items.Add(New ListItem("Ret IVA Servicios", "5"))
|
||||
DdlRetIVAConcepto.Items.Add(New ListItem("Ret IVA Servicios", "5"))
|
||||
''End If
|
||||
|
||||
End If
|
||||
@@ -6310,7 +6325,7 @@ Partial Class Compras_Compras
|
||||
Funcionalidad = 313
|
||||
ConceptoContable = 248
|
||||
ElseIf DdlRetIVAConcepto.SelectedValue.ToEntero = 5 Then
|
||||
Funcionalidad = 577
|
||||
Funcionalidad = 578
|
||||
ConceptoContable = 285
|
||||
End If
|
||||
|
||||
@@ -6513,7 +6528,14 @@ Partial Class Compras_Compras
|
||||
Exit Select 'Es credito el concepto 6 se agrega en CASE 17
|
||||
End If
|
||||
|
||||
If Not CveCompraRefacturacion > 0 OrElse (ChkRefacNC.Checked) Then
|
||||
|
||||
Dim DifSubTotatles As Decimal = 0D
|
||||
|
||||
If CveCompraRefacturacion > 0 Then
|
||||
DifSubTotatles = Math.Abs(SubTotalRefacturacion - TxtSubTotal2.Text.ToDecimal)
|
||||
End If
|
||||
|
||||
If DifSubTotatles > 0 Or (Not CveCompraRefacturacion > 0 OrElse (ChkRefacNC.Checked)) Then
|
||||
'AF TipoAF 2 Es para las compras
|
||||
DT = TmpDT.FiltraParametros("ISNULL(TipoAF,0) = 2 And ISNULL(AplicaCostoIndirecto,0) <> 1 ")
|
||||
If DT.Rows.Count > 0 AndAlso Not DdlTipoComprobante.SelectedValue.Contiene("NC", "DEV", "Ant") Then
|
||||
@@ -8963,7 +8985,7 @@ Partial Class Compras_Compras
|
||||
IdCtaContable = 0
|
||||
Dim Concepto As String = String.Format("{0}-{1}", TxtSerie.Text, TxtFolio.Text)
|
||||
Dim importeMN As Decimal = 0
|
||||
Dim Multiplicador As Integer = If(Row("Multiplicador").ToString.ToEntero = 1, -1, 1)
|
||||
Dim Multiplicador As Integer = If(Row("Multiplicador").ToString.ToEntero = 1, 1, -1)
|
||||
Dim PorcentajeImpuesto As Decimal = 0
|
||||
Dim ConceptoPartida As String = String.Format("{0}-{1}", TxtSerie.Text, TxtFolio.Text)
|
||||
|
||||
@@ -10582,7 +10604,7 @@ Partial Class Compras_Compras
|
||||
Dim importeMovimiento As Decimal = 0
|
||||
Dim IdCtaContable As Integer = 0
|
||||
Dim importeMN As Decimal = 0
|
||||
Dim Multiplicador As Integer = If(Row("Multiplicador").ToString.ToEntero = 1, -1, 1)
|
||||
Dim Multiplicador As Integer = If(Row("Multiplicador").ToString.ToEntero = 1, 1, -1)
|
||||
Dim Referencia As String = $"{TxtSerie.Text}-{TxtFolio.Text}" ' concatenation interpolation
|
||||
|
||||
Select Case ConceptoContable
|
||||
@@ -14722,14 +14744,19 @@ Partial Class Compras_Compras
|
||||
|
||||
Private Sub DdlRefacturacionFacturas_SelectedIndexChanged(sender As Object, e As EventArgs) Handles DdlRefacturacionFacturas.SelectedIndexChanged
|
||||
|
||||
SubTotalRefacturacion = 0.0D
|
||||
|
||||
If DdlRefacturacionFacturas.SelectedValue.ToEntero > 0 Then
|
||||
Dim dr As DataRow = DtRefacturacion.FiltroPrimero(String.Format("CveCompra ={0}", DdlRefacturacionFacturas.SelectedValue))
|
||||
If dr IsNot Nothing Then
|
||||
|
||||
HdnRefacturacionConcepto.Value = dr("CveConceptoContableAlmacen").ToString
|
||||
ChkRefacturacionConAlmacen.Checked = If(dr("CveMovimientoAlmacen").ToString.ToEntero > 0, True, False)
|
||||
SubTotalRefacturacion = dr("SubTotal").ToString.ToDecimal
|
||||
End If
|
||||
|
||||
|
||||
|
||||
End If
|
||||
|
||||
End Sub
|
||||
@@ -17502,8 +17529,8 @@ Partial Class Compras_Compras
|
||||
|
||||
'RETENCIONES
|
||||
Dim Retenciones = 0D
|
||||
Retenciones = TxtRetIVA.Text.ToDecimal
|
||||
Retenciones += TxtRetISR.Text.ToDecimal
|
||||
Retenciones = RetIVA.ToDecimal
|
||||
Retenciones += RetISR.ToDecimal
|
||||
|
||||
|
||||
SubTotal2 = SubTotal - Descuentos ' - Amortizacion '[IPP] COMENTADO CASO JAM 12653 CON NC 27122 | 23/MAYO/2018
|
||||
@@ -18394,7 +18421,7 @@ Partial Class Compras_Compras
|
||||
End If
|
||||
|
||||
Next
|
||||
TmpDT.AcceptChanges()
|
||||
TmpDT.AcceptChanges()
|
||||
'Else
|
||||
' Retorno = False
|
||||
'End If
|
||||
|
||||
@@ -343,7 +343,7 @@ Partial Class PopUpVerFactura
|
||||
lrds.Add(rds)
|
||||
'"Empresas/Grales/Formatos/EquiposGPS.rdlc"
|
||||
'"D:\\ADSistemas\\Proyectos\\SIG\\SIGIT\\GPS\\PalletEtiqueta.rdlc"
|
||||
ImprimirPDF("GPS/EmbarqueManifiesto.rdlc", lrds, params, "Manifesto")
|
||||
ImprimirPDF("GPS/EmbarqueManifiesto.rdlc", lrds, params, "Manifesto", Content_Disposition:="Inline")
|
||||
End Sub
|
||||
|
||||
Private Sub imprimirManifiestoRemision(cveEmbarqueManifiesto As Integer)
|
||||
@@ -373,6 +373,7 @@ Partial Class PopUpVerFactura
|
||||
Dim TotalDlls As String = ""
|
||||
Dim Cliente As String = ""
|
||||
Dim Direccion As String = ""
|
||||
Dim BinsPrecio As String = ""
|
||||
|
||||
|
||||
|
||||
@@ -403,6 +404,7 @@ Partial Class PopUpVerFactura
|
||||
CAJASDECARTON = String.Format("{0:N0}", row("CAJASDECARTON"))
|
||||
RPC = String.Format("{0:N0}", row("RPC"))
|
||||
BINSDECARTON = String.Format("{0:N0}", row("BINSDECARTON"))
|
||||
BinsPrecio = String.Format("{0:N0}", row("BINSDECARTON").ToString().ToDecimal() * 5)
|
||||
TotalDlls = String.Format("{0:N0}", row("TotalDlls"))
|
||||
|
||||
|
||||
@@ -482,6 +484,8 @@ Partial Class PopUpVerFactura
|
||||
params.Add(New ReportParameter("CAJASDECARTON", CAJASDECARTON))
|
||||
params.Add(New ReportParameter("RPC", RPC))
|
||||
params.Add(New ReportParameter("BINSDECARTON", BINSDECARTON))
|
||||
params.Add(New ReportParameter("BinsPrecio", BinsPrecio))
|
||||
|
||||
params.Add(New ReportParameter("TotalDlls", TotalDlls))
|
||||
|
||||
|
||||
@@ -493,7 +497,7 @@ Partial Class PopUpVerFactura
|
||||
lrds.Add(rds)
|
||||
'"Empresas/Grales/Formatos/EquiposGPS.rdlc"
|
||||
'"D:\\ADSistemas\\Proyectos\\SIG\\SIGIT\\GPS\\PalletEtiqueta.rdlc"
|
||||
ImprimirPDF("GPS/EmbarqueManifiestoRemision.rdlc", lrds, params, "Remisión")
|
||||
ImprimirPDF("GPS/EmbarqueManifiestoRemision.rdlc", lrds, params, "Remisión", Content_Disposition:="Inline")
|
||||
End Sub
|
||||
|
||||
|
||||
@@ -521,6 +525,7 @@ Partial Class PopUpVerFactura
|
||||
Dim CAJASDECARTON As String = ""
|
||||
Dim RPC As String = ""
|
||||
Dim BINSDECARTON As String = ""
|
||||
Dim BinsPrecio As String = ""
|
||||
Dim TotalDlls As String = ""
|
||||
Dim Cliente As String = ""
|
||||
Dim Direccion As String = ""
|
||||
@@ -659,7 +664,7 @@ Partial Class PopUpVerFactura
|
||||
'GuardaLogFacturacion($"Ruta XML {ArchivoXML}")
|
||||
'ResultadoMail = 3
|
||||
End If
|
||||
ImprimirPDF("GPS/EmbarqueManifiestoCartaPorte.rdlc", lrds, params, "DatosCartaPorte", Content_Disposition:="inline")
|
||||
ImprimirPDF("GPS/EmbarqueManifiestoCartaPorte.rdlc", lrds, params, "DatosCartaPorte", Content_Disposition:="Inline")
|
||||
|
||||
|
||||
End Sub
|
||||
@@ -728,7 +733,7 @@ Partial Class PopUpVerFactura
|
||||
'endimg
|
||||
'"Empresas/Grales/Formatos/EquiposGPS.rdlc"
|
||||
'"D:\\ADSistemas\\Proyectos\\SIG\\SIGIT\\GPS\\PalletEtiqueta.rdlc"
|
||||
ImprimirPDF("GPS/PalletEtiqueta2.rdlc", lrds, params, "Pallet")
|
||||
ImprimirPDF("GPS/PalletEtiqueta2.rdlc", lrds, params, "Pallet", Content_Disposition:="Inline")
|
||||
End Sub
|
||||
Private Sub imprimirpallet(cvePallet As Integer)
|
||||
Dim Envase As String = ""
|
||||
@@ -825,7 +830,7 @@ Partial Class PopUpVerFactura
|
||||
'If CvetypeImpresion = 2 Then
|
||||
' ruta = "GPS/PalletEtiqueta_2.rdlc"
|
||||
'End If
|
||||
ImprimirPDF(ruta, lrds, params, "Pallet Caja")
|
||||
ImprimirPDF(ruta, lrds, params, "Pallet Caja", Content_Disposition:="Inline")
|
||||
End Sub
|
||||
#Region "U S U A R I O - T O K E N"
|
||||
|
||||
|
||||
@@ -728,15 +728,10 @@ Partial Class Compras_Proveedores
|
||||
cfdVer = "http://www.sat.gob.mx/cfd/4"
|
||||
End If
|
||||
|
||||
|
||||
|
||||
'If Prefijo.ToLower <> "cfdi" Then cfdVer = "http://www.sat.gob.mx/cfd/2"
|
||||
namespaces.AddNamespace(Prefijo, cfdVer)
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Dim node As XmlNode
|
||||
node = XMLDoc.SelectSingleNode(String.Format("//{0}:Emisor", Prefijo), namespaces)
|
||||
If node IsNot Nothing Then
|
||||
|
||||
@@ -2883,7 +2883,7 @@ Partial Class Compras_eFacturas
|
||||
DTDocumentosRelacionados.Columns.Add("Manual", GetType(Boolean))
|
||||
|
||||
|
||||
|
||||
Dim TieneRegistros As Boolean = False
|
||||
If IO.File.Exists(Archivo) Then
|
||||
|
||||
|
||||
@@ -3034,18 +3034,29 @@ Partial Class Compras_eFacturas
|
||||
End If
|
||||
End If
|
||||
|
||||
|
||||
ObjCompraFolios.Dispose()
|
||||
DTDocumentosRelacionados = DTDocumentosRelacionados.FiltraParametros("CveIE > 0 AND LEN(IdDocumento) > 0")
|
||||
GVPDocumentosRelacionadosPagos.DataSource = DTDocumentosRelacionados
|
||||
GVPDocumentosRelacionadosPagos.DataBind()
|
||||
|
||||
DTGVPagosVinculacion = DTDocumentosRelacionados
|
||||
|
||||
BtnVincularPago.Visible = False
|
||||
If DTDocumentosRelacionados.Rows.Count > 0 Then
|
||||
SerieFolioIE = DTDocumentosRelacionados.Rows(0)("SerieFolio").ToString
|
||||
DivVincularPagoManualmente.Visible = False
|
||||
BtnVincularPago.Visible = True
|
||||
TieneRegistros = True
|
||||
Else
|
||||
DivVincularPagoManualmente.Visible = True
|
||||
BtnVincularPago.Visible = False
|
||||
End If
|
||||
|
||||
ComprasEnComplemento = DTGVPagosVinculacion.COUNT("CveCompra", " CveCompra > 0")
|
||||
|
||||
|
||||
|
||||
|
||||
If DTDocumentosRelacionados.MAX("CveCompra").ToString.ToEntero > 0 Then
|
||||
TieneCompras = True
|
||||
Else
|
||||
@@ -3096,25 +3107,25 @@ Partial Class Compras_eFacturas
|
||||
Dim ObjCompras As New ClsCompras
|
||||
|
||||
|
||||
Dim TieneRegistros As Boolean = False
|
||||
|
||||
If ObjCompras.GetCompararComplementoPago(gvRow.DataKey("CveProveedor").ToEntero, Monto, nodePagos2.InnerXml.Replace("pago10:", "").Replace("pagos10:", ""), UsuarioActual.CveEmpresa) Then
|
||||
GvVincularPago.DataSource = ObjCompras.DtResultados
|
||||
|
||||
If ObjCompras.DtResultados.Rows.Count > 0 Then
|
||||
SerieFolioIE = ObjCompras.DtResultados.Rows(0)("SerieFolio").ToString
|
||||
DivVincularPagoManualmente.Visible = False
|
||||
BtnVincularPago.Visible = True
|
||||
TieneRegistros = True
|
||||
Else
|
||||
DivVincularPagoManualmente.Visible = True
|
||||
BtnVincularPago.Visible = False
|
||||
End If
|
||||
'ImportePago = ObjCompras.DtResultados.SUMD("Monto")
|
||||
Else
|
||||
DivVincularPagoManualmente.Visible = False
|
||||
BtnVincularPago.Visible = False
|
||||
End If
|
||||
'If ObjCompras.GetCompararComplementoPago(gvRow.DataKey("CveProveedor").ToEntero, Monto, nodePagos2.InnerXml.Replace("pago10:", "").Replace("pagos10:", ""), UsuarioActual.CveEmpresa) Then
|
||||
' GvVincularPago.DataSource = ObjCompras.DtResultados
|
||||
|
||||
' If ObjCompras.DtResultados.Rows.Count > 0 Then
|
||||
' SerieFolioIE = ObjCompras.DtResultados.Rows(0)("SerieFolio").ToString
|
||||
' DivVincularPagoManualmente.Visible = False
|
||||
' BtnVincularPago.Visible = True
|
||||
' TieneRegistros = True
|
||||
' Else
|
||||
' DivVincularPagoManualmente.Visible = True
|
||||
' BtnVincularPago.Visible = False
|
||||
' End If
|
||||
' 'ImportePago = ObjCompras.DtResultados.SUMD("Monto")
|
||||
'Else
|
||||
' DivVincularPagoManualmente.Visible = False
|
||||
' BtnVincularPago.Visible = False
|
||||
'End If
|
||||
|
||||
For Each GvRowF As GridViewRow In GVPDocumentosRelacionadosPagos.Rows
|
||||
|
||||
|
||||
Reference in New Issue
Block a user