From 05034bda0e0e38ea82f8ccdbbbc2352463ddb92d Mon Sep 17 00:00:00 2001 From: Antonio Gonzalez Date: Thu, 27 Aug 2020 17:33:56 -0700 Subject: [PATCH 1/4] =?UTF-8?q?Validaci=C3=B3n=20al=20cambiar=20la=20confi?= =?UTF-8?q?guraci=C3=B3n=20para=20no=20afectar=20a=20los=20productos=20con?= =?UTF-8?q?=20los=20qu=20eya=20se=20tienen=20existencias?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Ventas/ProductosServicios.aspx | 2 +- Ventas/ProductosServicios.aspx.vb | 56 +++++++++++++++++++++++++------ 2 files changed, 47 insertions(+), 11 deletions(-) diff --git a/Ventas/ProductosServicios.aspx b/Ventas/ProductosServicios.aspx index 089baf909..e3ff10271 100644 --- a/Ventas/ProductosServicios.aspx +++ b/Ventas/ProductosServicios.aspx @@ -184,7 +184,7 @@
- + diff --git a/Ventas/ProductosServicios.aspx.vb b/Ventas/ProductosServicios.aspx.vb index 8bbe6813d..963dfcda5 100644 --- a/Ventas/ProductosServicios.aspx.vb +++ b/Ventas/ProductosServicios.aspx.vb @@ -106,6 +106,15 @@ Partial Class ProductosyServicios End Set End Property + Private Property CveUnidadMedida As Integer + Get + Return ViewState("CveUnidadMedida").ToString.ToEntero + End Get + Set(value As Integer) + ViewState("CveUnidadMedida") = value + End Set + End Property + #End Region @@ -769,6 +778,7 @@ Partial Class ProductosyServicios End If DdlTipoPSDes.SelectedValueExist(ObjProductosServicios.CveClasificacionDetalle.ToString) DdlUnidadMedida.SelectedValue = ObjProductosServicios.CveUnidadMedida.ToString + CveUnidadMedida = ObjProductosServicios.CveUnidadMedida.ToString.ToEntero DdlMarca.SelectedValue = ObjProductosServicios.CveMarca.ToString DdlMarcaPSDes.SelectedValue = ObjProductosServicios.CveMarca.ToString TxtCodigo.Text = ObjProductosServicios.Codigo @@ -2653,23 +2663,32 @@ Partial Class ProductosyServicios End Sub Protected Sub ChkSerie_CheckedChanged(sender As Object, e As EventArgs) - If ChkSerie.Checked Then - ddlMetodos.SelectedValueExist("5") + If ElProductoTieneExistencia() Then + ChkSerie.Checked = Not ChkSerie.Checked + Alert("el producto no se puede cambiar la opcion, porque tiene existencia.", TipoMensaje.MsgAdvertencia) Else - ddlMetodos.SelectedValueExist("-1") + If ChkSerie.Checked Then + ddlMetodos.SelectedValueExist("5") + Else + ddlMetodos.SelectedValueExist("-1") + End If + UpConta.Update() End If - UpConta.Update() End Sub Protected Sub ChkSeccion_CheckedChanged(sender As Object, e As EventArgs) - - If ChkSeccion.Checked Then - DivSeccionAlmacen.Visible = True + If ElProductoTieneExistencia() Then + ChkSeccion.Checked = Not ChkSerie.Checked + Alert("el producto no se puede cambiar la opcion, porque tiene existencia.", TipoMensaje.MsgAdvertencia) Else - DivSeccionAlmacen.Visible = False - End If + If ChkSeccion.Checked Then + DivSeccionAlmacen.Visible = True + Else + DivSeccionAlmacen.Visible = False + End If - UpSeccionAlmacen.Update() + UpSeccionAlmacen.Update() + End If End Sub Protected Sub DdlAlmacen_SelectedIndexChanged(sender As Object, e As EventArgs) @@ -2680,4 +2699,21 @@ Partial Class ProductosyServicios UpModalSeccionAlmacen.Update() End Sub + + Protected Sub DdlUnidadMedida_SelectedIndexChanged(sender As Object, e As EventArgs) + If ElProductoTieneExistencia() Then + DdlUnidadMedida.SelectedValue = CveUnidadMedida.ToString + Alert("el producto no se puede cambiar la opcion, porque tiene existencia.") + End If + End Sub + + Private Function ElProductoTieneExistencia() As Boolean + Dim Existencia As Decimal = 0 + If CvePS > 0 Then + Dim ObjInventarios As New ClsInventarios + Existencia = ObjInventarios.GetExistenciasPS(CvePS, CveUnidadMedida, UsuarioActual.CveEmpresa, -1) + ObjInventarios.Dispose() + End If + Return Existencia > 0 + End Function End Class From b26361d2c2885157edec01c3257887f3faa04388 Mon Sep 17 00:00:00 2001 From: Antonio Gonzalez Date: Thu, 27 Aug 2020 18:13:23 -0700 Subject: [PATCH 2/4] acomodo de layout --- OI/ConvocatoriaDetalle.aspx | 64 +++++++++++++++++++++---------------- 1 file changed, 36 insertions(+), 28 deletions(-) diff --git a/OI/ConvocatoriaDetalle.aspx b/OI/ConvocatoriaDetalle.aspx index 78cfaaee9..503d5a1b1 100644 --- a/OI/ConvocatoriaDetalle.aspx +++ b/OI/ConvocatoriaDetalle.aspx @@ -13,7 +13,7 @@ tr[hide="1"] { display: none; - background-color: rgb(4,71,103) + background-color: rgb(4,71,103); } .portlet { @@ -138,10 +138,10 @@ Actualizar Participantes
  • - Asistencia + Asistencia
  • - Enviar correo + Enviar correo
  • @@ -150,7 +150,7 @@ - +
    @@ -180,6 +180,24 @@
    +
    +
    +
    + + + + <%----%> + +
    +
    +
    +
    + + + +
    +
    +
    @@ -198,28 +216,15 @@
    - -
    - - - -
    +
    <%----%>
    -
    -
    - - - - <%----%> - -
    -
    -