--- pago por empleado
This commit is contained in:
@@ -1149,7 +1149,6 @@ Partial Class Bancos_PopIEVentas
|
||||
End If
|
||||
|
||||
Dim MsgError As String = ""
|
||||
Dim CveConceptoPrePoliza As Integer = -1
|
||||
Dim Inserta As Boolean = True
|
||||
Dim ImportePagado As Decimal = 0
|
||||
Dim Fecha As Date = TxtFechaDocumento.Text.Trim.ToDate
|
||||
@@ -1162,7 +1161,6 @@ Partial Class Bancos_PopIEVentas
|
||||
Case "2" 'FyE
|
||||
ImportePagado = TxtImporte.Text.Trim.ToDecimal
|
||||
Fecha = TxtFechaDocumento.Text.Trim.ToDate
|
||||
CveConceptoPrePoliza = 29
|
||||
CveIE = -1
|
||||
Dim stringPersonal As String = DdlFuncionarioEmpleado.SelectedItem.ToString
|
||||
'CvePersonal = DdlFuncionarioEmpleado.SelectedValue.ToEntero
|
||||
@@ -1252,7 +1250,7 @@ Partial Class Bancos_PopIEVentas
|
||||
Case "1" ' Banco
|
||||
CveIE = ObjIE.AddBancos_IE(DdlCuenta.SelectedValue.ToEntero, DdlTipoTransaccion.SelectedValue.ToEntero, Fecha, TxtFolio.Text.Trim, TxtPagueseA.Text.Trim, ImportePagado, CveMoneda, tipoCambioPago, TxtObservaciones.Text.Trim, "", True, True, -1, CvePrePoliza, "", UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, CveCuentaTarjeta:=If(DivTarjeta.Visible, DdlTarjeta.SelectedValue.ToEntero, -1), CveCuentaDeposito:=CveCuentaDeposito, Referencia:=If(TxtReferenciaCIE.Visible, TxtReferenciaCIE.Text, "-1"), CveCorte:=CveCorte)
|
||||
If CveIE > 0 Then
|
||||
If CveVenta > 0 Then
|
||||
|
||||
Pago.ImportePago = ImportePagado
|
||||
Pago.ImportePagoVenta = ImportePagado
|
||||
Pago.CveIE = CveIE
|
||||
@@ -1261,14 +1259,25 @@ Partial Class Bancos_PopIEVentas
|
||||
If MsgError = "" AndAlso AplicaPrePolizaPagoVenta(VentaActual, Pago, CvePrePoliza, ObjMov) Then
|
||||
MsgError = "No se pudo insertar la póliza"
|
||||
End If
|
||||
End If
|
||||
|
||||
Else
|
||||
MsgError = "Ocurrio un Error al registrarse el movimiento bancario."
|
||||
Inserta = False
|
||||
End If
|
||||
Case "2" ' FyE
|
||||
|
||||
Pago.ImportePago = ImportePagado
|
||||
Pago.ImportePagoVenta = ImportePagado
|
||||
Pago.TipoPago = "FyE"
|
||||
Pago.CvePersonal = DdlFuncionarioEmpleado.SelectedValue.ToEntero
|
||||
Pago.Referencia = DdlFuncionarioEmpleado.SelectedItem.ToString
|
||||
|
||||
If MsgError = "" AndAlso AplicaPrePolizaPagoVenta(VentaActual, Pago, CvePrePoliza, ObjMov) Then
|
||||
MsgError = "No se pudo insertar la póliza"
|
||||
End If
|
||||
|
||||
Case "3" 'Ingresos x Comprobar
|
||||
If CveVenta > 0 Then
|
||||
CveConceptoPrePoliza = 2
|
||||
|
||||
CveCliente = DdlIngreso.SelectedValue.ToEntero
|
||||
CveIE = -1
|
||||
ImportePagado = TxtImporte.Text.Trim.ToDecimal
|
||||
@@ -1295,11 +1304,10 @@ Partial Class Bancos_PopIEVentas
|
||||
End If
|
||||
End If
|
||||
Next
|
||||
End If
|
||||
|
||||
Case "4" 'Deudores Diversos
|
||||
If CveVenta > 0 Then
|
||||
|
||||
ImportePagado = TxtImporte.Text.Trim.ToDecimal
|
||||
CveConceptoPrePoliza = 2
|
||||
'CveProveedor2 = DdlDeudor.SelectedValue.ToEntero
|
||||
CveIE = -1
|
||||
If DdlDeudor.SelectedValue.ToEntero <= 0 Then
|
||||
@@ -1322,9 +1330,9 @@ Partial Class Bancos_PopIEVentas
|
||||
End If
|
||||
End If
|
||||
Next
|
||||
End If
|
||||
|
||||
Case "5" 'Compras
|
||||
If CveVenta > 0 Then
|
||||
|
||||
ImportePagado = TxtImporte.Text.Trim.ToDecimal
|
||||
CveIE = -1
|
||||
For Each rw As GridViewRow In GvCompras.Rows
|
||||
@@ -1353,7 +1361,7 @@ Partial Class Bancos_PopIEVentas
|
||||
|
||||
End If
|
||||
Next
|
||||
End If
|
||||
|
||||
Case Else
|
||||
'NO SE HA DEFINIDO PARA FUNCIONARIO Y EMPLEADO
|
||||
If RBLContado.SelectedValue <> "2" Then
|
||||
@@ -1372,7 +1380,8 @@ Partial Class Bancos_PopIEVentas
|
||||
MsgError = "No se pudo insertar la poliza detalle"
|
||||
End If
|
||||
End If
|
||||
|
||||
Else
|
||||
MsgError = "venta no identificada"
|
||||
End If
|
||||
Else
|
||||
MsgError = "No se pudo insertar la póliza"
|
||||
|
||||
Reference in New Issue
Block a user