Merge branch 'master' of http://192.168.10.111:8383/SIG
This commit is contained in:
@@ -2340,6 +2340,11 @@ Partial Class Ventas
|
||||
|
||||
If Not IsPostBack Then
|
||||
|
||||
''SOLO SISTEMA DEBE VER ESTA OPCION
|
||||
'If UsuarioActual.CveUsuario = 100 Then
|
||||
' LnkCancelarSoloCFDI.Visible = True
|
||||
'End If
|
||||
|
||||
If IfNull(Request("Opcionx"), "").ToString = "Saldar" And UsuarioActual.CveUsuario = 100 Then
|
||||
TxtFechaSaldarVenta.Text = "2021/12/31"
|
||||
SaldarVenta()
|
||||
@@ -16194,6 +16199,8 @@ Partial Class Ventas
|
||||
#Region " BTN ELIMINAR "
|
||||
Protected Sub BtnEmitir_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BtnEmitir.Click
|
||||
|
||||
'ChkEnviarFactura.Checked = False
|
||||
|
||||
If CveVenta <= 0 Then
|
||||
Alert("Ocurrió un error al emitir la factura", TipoMensaje.MsgError)
|
||||
Exit Sub
|
||||
@@ -35733,5 +35740,32 @@ Partial Class Ventas
|
||||
|
||||
#End Region
|
||||
|
||||
Protected Sub LnkCancelarSoloCFDI_Click(sender As Object, e As EventArgs)
|
||||
If CveVenta > 0 Then
|
||||
Dim RowVenta As DataRow = Nothing
|
||||
|
||||
Using ObjVentas As New ClsVentas
|
||||
If (ObjVentas.GetVenta(CveVenta, UsuarioActual.CveEmpresa)) Then
|
||||
RowVenta = ObjVentas.DtResultados.Copy().Rows(0)
|
||||
End If
|
||||
End Using
|
||||
|
||||
If RowVenta IsNot Nothing Then
|
||||
Dim FolioFiscal As String = RowVenta("FolioFiscal").ToString().Trim()
|
||||
Dim Total As Decimal = RowVenta("Total").ToString().ToDecimal()
|
||||
Dim RFCReceptor As String = RowVenta("RFCReceptor").ToString()
|
||||
Dim ObjTimbrado As New Timbrado
|
||||
Dim resp = ObjTimbrado.CFDICancelar(UsuarioActual.Empresa, FolioFiscal, Total, RFCReceptor, UsuarioActual.Empresa.RFC, CvePACCancelacion:=4, ValidaFactura:=False, CveSATMotivoCancelacion:=2)
|
||||
If resp IsNot Nothing Then
|
||||
Alert(resp.Estado)
|
||||
End If
|
||||
|
||||
End If
|
||||
End If
|
||||
|
||||
|
||||
|
||||
|
||||
End Sub
|
||||
End Class
|
||||
|
||||
|
||||
Reference in New Issue
Block a user