Merge branch 'master' of http://192.168.10.111:8383/SIG
This commit is contained in:
@@ -3629,6 +3629,8 @@ Partial Class Ventas
|
||||
ImgAntiPend.Visible = False
|
||||
End If
|
||||
|
||||
InicializaDevolucionAlmacen()
|
||||
|
||||
End If
|
||||
|
||||
End Sub
|
||||
@@ -6846,6 +6848,8 @@ Partial Class Ventas
|
||||
|
||||
RBLPago.Items(0).Enabled = True
|
||||
|
||||
Dim CveUsoCFDICliente As Integer = -1
|
||||
|
||||
Dim ObjCliente As New ClsClientes()
|
||||
|
||||
If ObjCliente.GetClientes(CveCliente, "-1", "-1", "-1", "-1", "-1", "-1", -1, UsuarioActual.CveEmpresa, Estatus, TipoCliente:=-1) Then
|
||||
@@ -6999,46 +7003,10 @@ Partial Class Ventas
|
||||
DdlMetodoPago33.Enabled = True
|
||||
End If
|
||||
|
||||
Dim CveCotizacion As Integer = IfNull(ViewState("CveCotizacion"), 0).ToString().ToEntero()
|
||||
|
||||
Me.CveMetodoPago33Cliente = ObjCliente.CveMetodoPago33
|
||||
Me.CveFormaPago33Cliente = ObjCliente.CveFormaPago33
|
||||
|
||||
If (CveVenta <= 0 AndAlso CveCotizacion <= 0) Or EsCreaApartirDe Or NuevaFactura = 1 OrElse ModalidadEdicion Then
|
||||
'CveMetodoPagoCliente = ObjCliente.CveMetodoPago
|
||||
If UsuarioActual.Empresa.Funcionalidad(589) = "1" Then
|
||||
'SI EL METODO DE PAGO ES PUE, SELECCIONA CONTADO
|
||||
If Me.CveMetodoPago33Cliente = 1 Then
|
||||
RBLPago.SelectedValue = "2"
|
||||
ElseIf Me.CveMetodoPago33Cliente = 3 Then
|
||||
RBLPago.SelectedValue = "1"
|
||||
End If
|
||||
RBLPago_SelectedIndexChanged(RBLPago, Nothing)
|
||||
UPCondicionesPago.Update()
|
||||
Else
|
||||
DdlMetodoPago33.SelectedValueExist(ObjCliente.CveMetodoPago33)
|
||||
CambiaMetodoPago33()
|
||||
DdlFormaPago33.SelectedValueExist(ObjCliente.CveFormaPago33)
|
||||
End If
|
||||
DdlUsoCFDI.SelectedValueExist(ObjCliente.CveUsoCFDI)
|
||||
'SI ES RFC GENERICO NO TIENE OBLIGACIONES FISCALES
|
||||
If LblRFC.Text.Contiene("XAXX010101000", "XEXX010101000") Then
|
||||
'S01 Sin efectos fiscales.
|
||||
DdlUsoCFDI.SelectedValueExist("23")
|
||||
DdlUsoCFDI.Enabled = False
|
||||
RegimenFiscalCliente = "616"
|
||||
ClienteCodigoRegimenFiscal = "616"
|
||||
Else
|
||||
If UsuarioActual.Empresa.Funcionalidad(109) = "1" Then
|
||||
DdlUsoCFDI.Enabled = True
|
||||
End If
|
||||
|
||||
If NuevaFactura = 1 Then
|
||||
DdlUsoCFDI.Enabled = True
|
||||
End If
|
||||
End If
|
||||
|
||||
End If
|
||||
CveUsoCFDICliente = ObjCliente.CveUsoCFDI
|
||||
|
||||
PlazoCobranza = ObjCliente.PlazoCobranza
|
||||
PlazoCobranzaRemision = ObjCliente.PlazoCobranzaRemision
|
||||
@@ -7388,6 +7356,48 @@ Partial Class Ventas
|
||||
|
||||
CargaRestriccionesCreditoCliente(True, CveVentaRef)
|
||||
|
||||
Dim CveCotizacion As Integer = IfNull(ViewState("CveCotizacion"), 0).ToString().ToEntero()
|
||||
|
||||
If (CveVenta <= 0 AndAlso CveCotizacion <= 0) Or EsCreaApartirDe Or NuevaFactura = 1 OrElse ModalidadEdicion Then
|
||||
'CveMetodoPagoCliente = ObjCliente.CveMetodoPago
|
||||
If UsuarioActual.Empresa.Funcionalidad(589) = "1" Then
|
||||
'SI EL METODO DE PAGO ES PUE, SELECCIONA CONTADO
|
||||
If Me.CveMetodoPago33Cliente = 1 Then
|
||||
RBLPago.SelectedValue = "2"
|
||||
ElseIf Me.CveMetodoPago33Cliente = 3 Then
|
||||
RBLPago.SelectedValue = "1"
|
||||
'SI ESTA BLOQUEADO EL CREDITO, DEJAR CONTADO
|
||||
If Not RBLPago.Items(0).Enabled Then
|
||||
RBLPago.SelectedValue = "2"
|
||||
End If
|
||||
End If
|
||||
RBLPago_SelectedIndexChanged(RBLPago, Nothing)
|
||||
UPCondicionesPago.Update()
|
||||
Else
|
||||
DdlMetodoPago33.SelectedValueExist(Me.CveMetodoPago33Cliente)
|
||||
CambiaMetodoPago33()
|
||||
DdlFormaPago33.SelectedValueExist(Me.CveFormaPago33Cliente)
|
||||
End If
|
||||
DdlUsoCFDI.SelectedValueExist(CveUsoCFDICliente)
|
||||
'SI ES RFC GENERICO NO TIENE OBLIGACIONES FISCALES
|
||||
If LblRFC.Text.Contiene("XAXX010101000", "XEXX010101000") Then
|
||||
'S01 Sin efectos fiscales.
|
||||
DdlUsoCFDI.SelectedValueExist("23")
|
||||
DdlUsoCFDI.Enabled = False
|
||||
RegimenFiscalCliente = "616"
|
||||
ClienteCodigoRegimenFiscal = "616"
|
||||
Else
|
||||
If UsuarioActual.Empresa.Funcionalidad(109) = "1" Then
|
||||
DdlUsoCFDI.Enabled = True
|
||||
End If
|
||||
|
||||
If NuevaFactura = 1 Then
|
||||
DdlUsoCFDI.Enabled = True
|
||||
End If
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
If CveVenta <= 0 Then
|
||||
CalculaLineasAdicionales()
|
||||
HabilitaRemisionPublicoGeneral = 0
|
||||
@@ -8986,6 +8996,17 @@ Partial Class Ventas
|
||||
GvPS.Rows(e.NewEditIndex).FCTextBox("TxtDescuento").Enabled = False
|
||||
End If
|
||||
|
||||
If (CveVenta <= 0 OrElse EsCreaApartirDe) AndAlso UsuarioActual.Empresa.Funcionalidad(531) = "1" Then
|
||||
Try
|
||||
If GvPS.Rows(e.NewEditIndex).DataKey("CvePrecioLista").ToString().ToEntero() > 0 Then
|
||||
GvPS.Rows(e.NewEditIndex).FCTextBox("TxtPrecio").Enabled = False
|
||||
End If
|
||||
Catch ex As Exception
|
||||
End Try
|
||||
|
||||
GvPS.Rows(e.NewEditIndex).FCTextBox("TxtDescuento").Enabled = False
|
||||
End If
|
||||
|
||||
If EsVentaMedica Then
|
||||
|
||||
GvPS.Rows(e.NewEditIndex).FCTextBox("TxtPrecio").Enabled = False
|
||||
@@ -9021,6 +9042,8 @@ Partial Class Ventas
|
||||
|
||||
End If
|
||||
|
||||
UpPS.Update()
|
||||
|
||||
End Sub
|
||||
Protected Sub GvPS_RowCancelingEdit(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.GridViewCancelEditEventArgs) Handles GvPS.RowCancelingEdit
|
||||
GvPS.EditIndex = -1
|
||||
@@ -12623,7 +12646,12 @@ Partial Class Ventas
|
||||
If UsuarioActual.Empresa.Funcionalidad(578) = "1" Then
|
||||
ObjFactura.Medico = DdlMedico.SelectedItem.Text
|
||||
ObjFactura.Procedimiento = DdlProcedimiento.SelectedItem.Text
|
||||
ObjFactura.FechaParaSurtir = TxtFechaOS.Text.Trim.ToDateTime
|
||||
|
||||
Dim FechaParaSurtir As DateTime = MinFecha
|
||||
If TxtFechaOS.Text.Replace(",", "").ToDateTime() > MinFecha Then
|
||||
FechaParaSurtir = TxtFechaOS.Text.Replace(",", "").ToDateTime()
|
||||
End If
|
||||
ObjFactura.FechaParaSurtir = FechaParaSurtir
|
||||
End If
|
||||
|
||||
'CONVERTIR REMISION - TIPO MONEDA -DOLARES A PESOS
|
||||
|
||||
Reference in New Issue
Block a user