From 685a11abcf24f259bcb00efec898ace40b4e34ef Mon Sep 17 00:00:00 2001 From: rakcsle Date: Tue, 14 Nov 2023 14:55:02 -0700 Subject: [PATCH] Compras Vincualcion OC etiqueta ret ISR --- App_Code/ClsOS.vb | 6 ++-- CRM/Acercamiento.aspx.cs | 2 +- CRM/EmpresaCRM.aspx.cs | 2 +- Compras/Compras.aspx | 4 +-- OS/Asignaciones.aspx | 14 ++++++--- OS/Asignaciones.aspx.vb | 17 +++++++++++ OS/OrdenesServicios.aspx | 21 +++++++++---- OS/OrdenesServicios.aspx.vb | 32 ++++++++++++++++--- Ventas/VentasMedicas.aspx | 8 ++--- Ventas/VentasMedicas.aspx.vb | 59 ++++++++++++++---------------------- 10 files changed, 103 insertions(+), 62 deletions(-) diff --git a/App_Code/ClsOS.vb b/App_Code/ClsOS.vb index 253b1f566..64b381f1d 100644 --- a/App_Code/ClsOS.vb +++ b/App_Code/ClsOS.vb @@ -610,7 +610,7 @@ Public Class ClsOS Public Function AddOrdenesServicios(CveCliente As Integer, CveSubProyecto As Integer, PersonaSolicito As String, FechaRecepcion As Date, Descripcion As String, CveUsuarioRecibio As Integer, CveEstatusOrdenServicio As Integer, CveUsuario As Integer, CveEmpresa As Integer, CveCotizacion As Integer, CveVenta As Integer, CveOSPadre As Integer, CveOSTipo As Integer, Optional CveClienteSucursal As Integer = -1, Optional Direccion As String = "-1", Optional Telefono As String = "", Optional CveModeloAuto As Integer = -1, Optional Año As String = "-1", Optional Correo As String = "", - Optional Condiciones As String = "", Optional CveMedico As Integer = -1, Optional CveProcedimiento As Integer = -1, Optional CveTipoVenta As Integer = -1) As Boolean + Optional Condiciones As String = "", Optional CveMedico As Integer = -1, Optional CveProcedimiento As Integer = -1, Optional CveTipoVenta As Integer = -1, Optional FechaCita As DateTime = MinFecha) As Boolean Dim Retorno As Boolean = False DataAdapter("PA_OS_OrdenesServiciosAdd") @@ -640,6 +640,7 @@ Public Class ClsOS .Add("@CveMedico", SqlDbType.Int).Value = CveMedico .Add("@CveProcedimiento", SqlDbType.Int).Value = CveProcedimiento .Add("@CveTipoVenta", SqlDbType.Int).Value = CveTipoVenta + .Add("@FechaCita", SqlDbType.DateTime).Value = FechaCita .Add("@CveOS", SqlDbType.Int).Direction = ParameterDirection.Output .Add("@vFolio", SqlDbType.Int).Direction = ParameterDirection.Output @@ -685,7 +686,7 @@ Public Class ClsOS Public Function UpdateOrdenesServicios(PersonaSolicito As String, FechaRecepcion As String, Descripcion As String, CveUsuarioRecibio As Integer, CveEstatusOrdenServicio As Integer, CveOS As Integer, CveUsuarioModifico As Integer, CveOSTipo As Integer, Optional CveClienteSucursal As Integer = -1, Optional Direccion As String = "-1", Optional Telefono As String = "", Optional CveModeloAuto As Integer = -1, Optional Año As String = "-1", Optional CveSubProyecto As Integer = -1, Optional Correo As String = "-1", Optional Condiciones As String = "", - Optional CveMedico As Integer = -1, Optional CveProcedimiento As Integer = -1, Optional CveTipoVenta As Integer = -1) As Boolean + Optional CveMedico As Integer = -1, Optional CveProcedimiento As Integer = -1, Optional CveTipoVenta As Integer = -1, Optional FechaCita As DateTime = MinFecha) As Boolean Dim Retorno As Boolean = False DataAdapter("PA_OS_OrdenesServiciosUpdate") @@ -711,6 +712,7 @@ Public Class ClsOS .Add("@CveMedico", SqlDbType.Int).Value = CveMedico .Add("@CveProcedimiento", SqlDbType.Int).Value = CveProcedimiento .Add("@CveTipoVenta", SqlDbType.Int).Value = CveTipoVenta + .Add("@FechaCita", SqlDbType.DateTime).Value = FechaCita End With diff --git a/CRM/Acercamiento.aspx.cs b/CRM/Acercamiento.aspx.cs index 68f937f4e..3221ac521 100644 --- a/CRM/Acercamiento.aspx.cs +++ b/CRM/Acercamiento.aspx.cs @@ -330,7 +330,7 @@ public partial class CRM_Acercamiento : ClsPaginas - if (UsuarioActual.Empresa.Funcionalidad(590).ToString().ToEntero() == 1) + if (UsuarioActual.Empresa.Funcionalidad(578).ToString().ToEntero() == 1) { DVTipoVenta.Visible = true; DVAgenteProcedimiento.Visible = true; diff --git a/CRM/EmpresaCRM.aspx.cs b/CRM/EmpresaCRM.aspx.cs index 431c6c62c..ea0302fdd 100644 --- a/CRM/EmpresaCRM.aspx.cs +++ b/CRM/EmpresaCRM.aspx.cs @@ -312,7 +312,7 @@ public partial class CRM_EmpresaCRM : ClsPaginas DdlPS.SelectedValue = "-1"; - if(UsuarioActual.Empresa.Funcionalidad(590).ToString().ToEntero() == 1) + if(UsuarioActual.Empresa.Funcionalidad(578).ToString().ToEntero() == 1) { DVAgenteProcedimiento.Visible = true; DVTipoVenta.Visible = true; diff --git a/Compras/Compras.aspx b/Compras/Compras.aspx index 9d9280b60..cd06d558c 100644 --- a/Compras/Compras.aspx +++ b/Compras/Compras.aspx @@ -6312,8 +6312,8 @@ if ($get("C_Tab_TabOC_LbRetIVAOC1")) { $get("C_Tab_TabOC_LbRetIVAOC1").innerText = FormatoNumero(SumaRetIVA, 2); } - if ($get("C_Tab_TabOC_LbRetISROC1")) { - $get("C_Tab_TabOC_LbRetISROC1").innerText = FormatoNumero(SumaRetISR, 2); + if ($get("C_Tab_TabOC_LblRetISROC1")) { + $get("C_Tab_TabOC_LblRetISROC1").innerText = FormatoNumero(SumaRetISR, 2); } if ($get("C_Tab_TabOC_LbTotalOC1")) { $get("C_Tab_TabOC_LbTotalOC1").innerText = FormatoNumero(SumaTotal, 2); diff --git a/OS/Asignaciones.aspx b/OS/Asignaciones.aspx index 38ac67998..ee4ad4ec4 100644 --- a/OS/Asignaciones.aspx +++ b/OS/Asignaciones.aspx @@ -155,8 +155,14 @@ Ordenes Sin Asignar
- - + + + + + + +
+
@@ -175,7 +181,8 @@
- @@ -216,7 +223,6 @@ > - diff --git a/OS/Asignaciones.aspx.vb b/OS/Asignaciones.aspx.vb index 4044f2a1d..d68d1b33e 100644 --- a/OS/Asignaciones.aspx.vb +++ b/OS/Asignaciones.aspx.vb @@ -4,6 +4,7 @@ Option Strict On Imports System.Data Imports Extensiones Imports Microsoft.Reporting.WebForms +Imports MKB.TimePicker Partial Class OS_Asignaciones Inherits ClsPaginas @@ -453,6 +454,7 @@ Partial Class OS_Asignaciones #Region "GV" Private Sub GvNA_RowDataBound(sender As Object, e As GridViewRowEventArgs) Handles GvNA.RowDataBound If e.Row.RowType = DataControlRowType.DataRow Then + If e.Row.DataKey("CveUsuarioAtendio") <> "" Then e.Row.FCCheckBox("ChbxAsignar").Visible = False e.Row.FCTextBox("FechaOS").Visible = False @@ -471,6 +473,21 @@ Partial Class OS_Asignaciones e.Row.FindControl("TimeSelector").Visible = True End If + If UsuarioActual.Empresa.Funcionalidad(578).ToEntero = 1 Then + + Dim FechaCita = e.Row.DataKey("FechaCitaOS").ToDateTime + e.Row.FCTextBox("FechaOS").Text = FechaCita.ToString("dd/MM/yyyy") + e.Row.FCTextBox("FechaOS").Visible = True + + e.Row.FindControl("TimeSelector").Visible = True + + Dim TMSelector = DirectCast(e.Row.FindControl("TimeSelector"), TimeSelector) + TMSelector.Date = FechaCita + + + End If + + End If UpOS.Update() diff --git a/OS/OrdenesServicios.aspx b/OS/OrdenesServicios.aspx index a860a6096..09c1fde9c 100644 --- a/OS/OrdenesServicios.aspx +++ b/OS/OrdenesServicios.aspx @@ -86,10 +86,11 @@
-
+ +
Fecha Recibido:
-
+
@@ -103,6 +104,14 @@
+ +
+ Fecha De Cita: +
+
+ +
+
@@ -112,7 +121,7 @@ Sucursal del Cliente:
-
+
@@ -130,7 +139,7 @@
- Sub Proyecto: + Sub Proyecto:
@@ -203,10 +212,10 @@
-
+
- Agente: + Medico:
diff --git a/OS/OrdenesServicios.aspx.vb b/OS/OrdenesServicios.aspx.vb index dbe2026ce..424c967c2 100644 --- a/OS/OrdenesServicios.aspx.vb +++ b/OS/OrdenesServicios.aspx.vb @@ -418,10 +418,17 @@ Partial Class OS_OrdenesServicios End If - If UsuarioActual.Empresa.Funcionalidad(590).ToEntero = 1 Then - DVAgenteProcedimiento.Visible = True + If UsuarioActual.Empresa.Funcionalidad(578).ToEntero = 1 Then + DVAMedicoProcedimiento.Visible = True DVTipoVenta.Visible = True DVTipoVenta.Visible = True + + DvFechaRecivido1.Visible = False + DvFechaRecivido2.Visible = False + + DVFechaCita1.Visible = True + DVFechaCita2.Visible = True + End If End If @@ -591,6 +598,7 @@ Partial Class OS_OrdenesServicios CveOsDetalle = ObjOS.CveOSDetalle TxtFechaRecibido.Text = ObjOS.FechaRecepcion.ToString("dd/MM/yyyy") + TxtFechaCita.Text = ObjOS.FechaCita.ToDateTime.ToString("yyyy-MM-dd HH:mm:ss").Replace(" ", "T") CveFolio = ObjOS.Folio LblFolio.Text = ObjOS.Folio.ToString @@ -1198,6 +1206,19 @@ Partial Class OS_OrdenesServicios #Region "M E T O D O S" Protected Sub Guardar(Entregar As Boolean) + + Dim FechaCita As DateTime = MinFecha + + If UsuarioActual.Empresa.Funcionalidad(578).ToEntero = 1 Then + If Not IsDate(TxtFechaCita.Text.Replace(",", "")) Then + Alert("El campo Fecha De Cita no es valido.", TipoMensaje.MsgAdvertencia) + Exit Sub + End If + FechaCita = TxtFechaCita.Text.Replace(",", "").ToDateTime + End If + + + Dim ObjOrdenServicio As New ClsOS() Dim ObjGenerales As New ClsGenerales(ObjOrdenServicio.IniciaTransacSQL) MensajeAlert = New StringBuilder @@ -1212,7 +1233,7 @@ Partial Class OS_OrdenesServicios If Not ObjOrdenServicio.AddOrdenesServicios(CveCliente, DdlSubProyecto.SelectedValue.ToEntero, TxtSolicito.Text, TxtFechaRecibido.Text.ToDateTime, TxtDescripcion.Text, UsuarioActual.CveUsuario, EstatusOrdenServicio, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, CveCotizacion, -1, -1, DdlTipoOrdenOS.SelectedValue.ToEntero, CveClienteSucursal:=DdlSucursalCliente.SelectedValue.ToEntero, Direccion:=TxtDireccion.Text, Telefono:=TxtTelefono.Text, CveModeloAuto:=DdlModeloAuto.SelectedValue.ToEntero, Año:=TxtAnio.Text, CveMedico:=DdlMedico.SelectedValue.ToEntero, - CveProcedimiento:=DdlProcedimiento.SelectedValue.ToEntero, CveTipoVenta:=DdlTipoVenta.SelectedValue.ToEntero) Then + CveProcedimiento:=DdlProcedimiento.SelectedValue.ToEntero, CveTipoVenta:=DdlTipoVenta.SelectedValue.ToEntero, FechaCita:=FechaCita) Then Errores = True End If CargaCliente(CveCliente) @@ -1308,11 +1329,12 @@ Partial Class OS_OrdenesServicios End If Else - If CveTecnico = UsuarioActual.CveUsuario Then + If CveTecnico = UsuarioActual.CveUsuario Or UpGuardar.Visible Then + If ObjOrdenServicio.UpdateOrdenesServicios(TxtSolicito.Text, TxtFechaRecibido.Text, TxtDescripcion.Text, UsuarioActual.CveUsuario, DdlEstatusOS.SelectedValue.ToEntero, CveOS, UsuarioActual.CveUsuario, DdlTipoOrdenOS.SelectedValue.ToEntero, CveClienteSucursal:=DdlSucursalCliente.SelectedValue.ToEntero, Direccion:=TxtDireccion.Text, Telefono:=TxtTelefono.Text, CveModeloAuto:=DdlModeloAuto.SelectedValue.ToEntero, Año:=TxtAnio.Text, CveMedico:=DdlMedico.SelectedValue.ToEntero, - CveProcedimiento:=DdlProcedimiento.SelectedValue.ToEntero, CveTipoVenta:=DdlTipoVenta.SelectedValue.ToEntero) Then + CveProcedimiento:=DdlProcedimiento.SelectedValue.ToEntero, CveTipoVenta:=DdlTipoVenta.SelectedValue.ToEntero, FechaCita:=FechaCita) Then For Each Row As DataRow In TmpDT.Rows If Not Errores Then Dim CvePS As Integer = Row("CvePS").ToString.ToEntero diff --git a/Ventas/VentasMedicas.aspx b/Ventas/VentasMedicas.aspx index 3e6489868..525b3c1a6 100644 --- a/Ventas/VentasMedicas.aspx +++ b/Ventas/VentasMedicas.aspx @@ -207,7 +207,7 @@
- +
@@ -233,14 +233,14 @@
- +
- - diff --git a/Ventas/VentasMedicas.aspx.vb b/Ventas/VentasMedicas.aspx.vb index 0e8ea43b0..18dfa37de 100644 --- a/Ventas/VentasMedicas.aspx.vb +++ b/Ventas/VentasMedicas.aspx.vb @@ -5991,22 +5991,7 @@ Partial Class VentasMedicas End If End If - 'Try - ' 'RMF, cuando es pedido, se manda autorización. - ' If ObjFactura.TipoDocto.Contiene("PA") Then - ' Dim Titulo As String = "Solicitud de autorización" 'usuarios de crédito y cobranza - ' Dim Msg As String = String.Format("{0} - Folio {1} ", DdlSubProyectoDatos.SelectedItem.Text, TxtFolio.Text) - ' 'If UsuarioActual.CveEmpresa = 119 Then - ' ' ClsSisNotificaciones.SendNotificacionERP(1715, Titulo, Msg, 1) - ' ' ClsSisNotificaciones.SendNotificacionERP(1815, Titulo, Msg, 1) - ' ' ClsSisNotificaciones.SendNotificacionERP(1830, Titulo, Msg, 1) - ' 'End If - - ' End If - 'Catch ex As Exception - ' OnError("Ocurrió un error al mandar las notificaciones de autorización", ex) - 'End Try Try ViewState("CveVenta") = ObjFactura.CveVenta @@ -6516,8 +6501,8 @@ Partial Class VentasMedicas ObjFactura.UsuarioCreo = LblUsuario.Text.Trim ObjFactura.CveCondicionEntrega = --1 ObjFactura.CondicionEntrega = "-1" - ObjFactura.CondicionesPago = 0 ' 0 - Contado, 1 - Credito, 2 - termianl - ObjFactura.FormaPago = 0 'DdlFormaPago.SelectedValue.ToEntero() + ObjFactura.CondicionesPago = 2 ' 0 - Contado, 1 - Credito, 2 - termianl + ObjFactura.FormaPago = 0 ObjFactura.AtencionA = "" ObjFactura.FordGSDB = "" @@ -6732,13 +6717,13 @@ Partial Class VentasMedicas End If Next - ObjFactura.SubTotal = TmpDT.SUM("Total").ToDecimal - ObjFactura.Descuento = TmpDT.SUM("Descuento").ToDecimal + ObjFactura.SubTotal = TmpDT.SUM("Total") + ObjFactura.Descuento = TmpDT.SUM("Descuento") ObjFactura.Amortizacion = Math.Round(LblAmortizacion.Text.Trim.ToDecimal * ObjFactura.TipoCambio, NumeroDecimales) - ObjFactura.IVA = TmpDT.SUM("ImporteIVA").ToDecimal - ObjFactura.RetIVA = TmpDT.SUM("ImporteRetIVA").ToDecimal - ObjFactura.RetISR = TmpDT.SUM("ImporteRetISR").ToDecimal - ObjFactura.IEPS = TmpDT.SUM("ImporteIEPS").ToDecimal + ObjFactura.IVA = TmpDT.SUM("ImporteIVA") + ObjFactura.RetIVA = TmpDT.SUM("ImporteRetIVA") + ObjFactura.RetISR = TmpDT.SUM("ImporteRetISR") + ObjFactura.IEPS = TmpDT.SUM("ImporteIEPS") ObjFactura.Total = (ObjFactura.SubTotal - ObjFactura.Descuento - ObjFactura.Amortizacion + ObjFactura.IVA + ObjFactura.IEPS - ObjFactura.RetIVA - ObjFactura.RetISR - ImpuestosLocales).ToDecimal TipoCambioRemision = ObjFactura.TipoCambio @@ -6767,13 +6752,13 @@ Partial Class VentasMedicas End If Next - ObjFactura.SubTotal = TmpDT.SUM("Total").ToDecimal - ObjFactura.Descuento = TmpDT.SUM("Descuento").ToDecimal + ObjFactura.SubTotal = TmpDT.SUM("Total") + ObjFactura.Descuento = TmpDT.SUM("Descuento") ObjFactura.Amortizacion = Math.Round(LblAmortizacion.Text.Trim.ToDecimal / ObjFactura.TipoCambioDolares, NumeroDecimales) - ObjFactura.IVA = TmpDT.SUM("ImporteIVA").ToDecimal - ObjFactura.RetIVA = TmpDT.SUM("ImporteRetIVA").ToDecimal - ObjFactura.RetISR = TmpDT.SUM("ImporteRetISR").ToDecimal - ObjFactura.IEPS = TmpDT.SUM("ImporteIEPS").ToDecimal + ObjFactura.IVA = TmpDT.SUM("ImporteIVA") + ObjFactura.RetIVA = TmpDT.SUM("ImporteRetIVA") + ObjFactura.RetISR = TmpDT.SUM("ImporteRetISR") + ObjFactura.IEPS = TmpDT.SUM("ImporteIEPS") ObjFactura.Total = (ObjFactura.SubTotal - ObjFactura.Descuento - ObjFactura.Amortizacion + ObjFactura.IVA + ObjFactura.IEPS - ObjFactura.RetIVA - ObjFactura.RetISR - ImpuestosLocales).ToDecimal TipoCambioRemision = ObjFactura.TipoCambioDolares @@ -8074,11 +8059,11 @@ Partial Class VentasMedicas 'Se agregan los PS For Each Row As DataRow In TmpDTDetalle.Rows - If Not ObjVentas.AddVentaDetalle(ObjVentas.CveVenta, Row("CvePS").ToString().ToEntero(), Row("Cantidad").ToString().ToDouble, Row("CveUM").ToString().ToEntero(), - Row("PU").ToString().ToDouble(If(factura.ConvertirPesos, factura.TipoCambio, 1)), Row("ImporteIVA").ToString().ToDouble, Math.Round((Row("Total").ToString().ToDouble(If(factura.ConvertirPesos, factura.TipoCambio, 1)) * (1 + Row("PorcentajeIVA").ToString().ToDouble(If(factura.ConvertirPesos, factura.TipoCambio, 1)))), 6), - Row("Obs").ToString(), Row("Descuento").ToString().ToDouble(If(factura.ConvertirPesos, factura.TipoCambio, 1)), Row("TipoDescuento").ToString().ToEntero(), Row("CveSubProyecto").ToString().ToEntero(), Row("CvePresupuestoIngreso").ToString().ToEntero(), TiempoEntrega:=Row("TiempoEntrega").ToString(), CveVentaDetallePadre:=Row("CveVentaDetalle").ToString().ToEntero(), - CveContratoDetalle:=Row("CveContratoDetalle").ToString().ToEntero(), CvePromocionDetalle:=Row("CvePromocionDetalle").ToString().ToEntero(), IEPS:=Row("ImporteIEPS").ToString().ToDouble, CveMovimientoDetallePedido:=Row("CveMovimientoDetallePedido").ToString().ToEntero(), ImporteRetIVA:=Row("ImporteRetIVA").ToString().ToDouble, ImporteRetISR:=Row("ImporteRetISR").ToString().ToDouble, - PorcentajeIVA:=Row("PorcentajeIVA").ToString().ToDecimal, PorcentajeIEPS:=Row("PorcentajeIEPS").ToString().ToDouble, PorcentajeRetIVA:=Row("PorcentajeRetIVA").ToString().ToDouble, PorcentajeRetISR:=Row("PorcentajeRetISR").ToString().ToDouble, CuentaPredial:=Row("CuentaPredial").ToString(), CvePrecioLista:=Row("CvePrecioLista").ToString().ToEntero(), CveActivoFijo:=Row("CveActivoFijo").ToString().ToEntero(), NumTurnos:=Row("NumTurnos").ToString().ToDecimal()) Then + If Not ObjVentas.AddVentaDetalle(ObjVentas.CveVenta, Row("CvePS").ToString().ToEntero(), Row("Cantidad").ToString().ToDecimal, Row("CveUM").ToString().ToEntero(), + Row("PU").ToString().ToDecimal(If(factura.ConvertirPesos, factura.TipoCambio, 1)), Row("ImporteIVA").ToString().ToDecimal, Math.Round((Row("Total").ToString().ToDecimal(If(factura.ConvertirPesos, factura.TipoCambio, 1)) * (1 + Row("PorcentajeIVA").ToString().ToDecimal(If(factura.ConvertirPesos, factura.TipoCambio, 1)))), 6), + Row("Obs").ToString(), Row("Descuento").ToString().ToDecimal(If(factura.ConvertirPesos, factura.TipoCambio, 1)), Row("TipoDescuento").ToString().ToEntero(), Row("CveSubProyecto").ToString().ToEntero(), Row("CvePresupuestoIngreso").ToString().ToEntero(), TiempoEntrega:=Row("TiempoEntrega").ToString(), CveVentaDetallePadre:=Row("CveVentaDetalle").ToString().ToEntero(), + CveContratoDetalle:=Row("CveContratoDetalle").ToString().ToEntero(), CvePromocionDetalle:=Row("CvePromocionDetalle").ToString().ToEntero(), IEPS:=Row("ImporteIEPS").ToString().ToDecimal, CveMovimientoDetallePedido:=Row("CveMovimientoDetallePedido").ToString().ToEntero(), ImporteRetIVA:=Row("ImporteRetIVA").ToString().ToDecimal, ImporteRetISR:=Row("ImporteRetISR").ToString().ToDecimal, + PorcentajeIVA:=Row("PorcentajeIVA").ToString().ToDecimal, PorcentajeIEPS:=Row("PorcentajeIEPS").ToString().ToDouble, PorcentajeRetIVA:=Row("PorcentajeRetIVA").ToString().ToDouble, PorcentajeRetISR:=Row("PorcentajeRetISR").ToString().ToDecimal, CuentaPredial:=Row("CuentaPredial").ToString(), CvePrecioLista:=Row("CvePrecioLista").ToString().ToEntero(), CveActivoFijo:=Row("CveActivoFijo").ToString().ToEntero(), NumTurnos:=Row("NumTurnos").ToString().ToDecimal()) Then ErrorList.Add("Ocurrió un error al agregar un Producto o Servicio a la Factura.
Revise su factura y cualquier detalle comuníquese a Soporte Técnico") Exit For Else @@ -8275,7 +8260,7 @@ Partial Class VentasMedicas If ObjOrdenServicio.AddOrdenesServicios(CveCliente, DdlSubProyectoDatos.SelectedValue.ToEntero, UsuarioActual.Nombre, TxtFecha.Text.Replace(",", "").ToDateTime, $"Venta: {Serie}-{FolioActual}", UsuarioActual.CveUsuario, EstatusOrdenServicio, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, -1, -1, -1, CveOSTipo, CveClienteSucursal:=DdlSubProyectoDatos.SelectedValue.ToEntero, Direccion:="", Telefono:="", CveModeloAuto:=-1, Año:="", CveMedico:=DdlMedico.SelectedValue.ToEntero, - CveProcedimiento:=DdlProcedimiento.SelectedValue.ToEntero, CveTipoVenta:=RBLTipoVenta.SelectedValue.ToEntero) Then + CveProcedimiento:=DdlProcedimiento.SelectedValue.ToEntero, CveTipoVenta:=RBLTipoVenta.SelectedValue.ToEntero, FechaCita:=TxtFecha.Text.Replace(",", "").ToDateTime) Then CveOS = ObjOrdenServicio.CveOS Else errorList.Add("Se presento un error al guardar la orden de servicio.") @@ -13798,7 +13783,7 @@ Partial Class VentasMedicas End If If Not PermiteCredito AndAlso TienePagos AndAlso Total > 0 Then - Dim TotalPago As Decimal = DtPagos.SUM("Importe").ToDecimal() + AmortizacionNC + Dim TotalPago As Decimal = DtPagos.SUM("Importe") + AmortizacionNC If TotalPago < Total Then Alert("La suma de los pagos debe ser igual al total de la venta.", TipoMensaje.MsgAdvertencia) @@ -14110,7 +14095,7 @@ Partial Class VentasMedicas RowServicio("PorcentajeRetIVA") = ClienteRetIVA Next - TxtRetIVA.Text = TmpDT.SUM("ImporteRetIVA").ToDecimal().FormatoNumero(2) + TxtRetIVA.Text = TmpDT.SUM("ImporteRetIVA").FormatoNumero(2) Dim PorcentajeRetIVA As Decimal = (TmpDT.MAX("PorcentajeRetIVA").ToDecimal() * 100) LblRetIVA.Text = PorcentajeRetIVA.FormatoNumero(2) If PorcentajeRetIVA > 0 Then
Nombre:  + +