Compras mensaje GDiaz fecha devolucion, Clientes liga NS y Ancipos a Venta
This commit is contained in:
@@ -1260,6 +1260,21 @@ Partial Class Compras_Compras
|
|||||||
End Set
|
End Set
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
|
Private Property FechaMovtoDev As Date
|
||||||
|
Get
|
||||||
|
If ViewState("FechaMovtoDev") Is Nothing Then
|
||||||
|
ViewState("FechaMovtoDev") = MinFecha
|
||||||
|
End If
|
||||||
|
Return ViewState("FechaMovtoDev").ToString.ToDate
|
||||||
|
End Get
|
||||||
|
Set(value As Date)
|
||||||
|
ViewState("FechaMovtoDev") = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Protected Sub Page_Load(sender As Object, e As System.EventArgs) Handles Me.Load
|
Protected Sub Page_Load(sender As Object, e As System.EventArgs) Handles Me.Load
|
||||||
If Not IsPostBack Then
|
If Not IsPostBack Then
|
||||||
@@ -13954,6 +13969,7 @@ Partial Class Compras_Compras
|
|||||||
|
|
||||||
Private Sub cargaddldevoluciones(CveProveedor As Integer, SubTotal As Double)
|
Private Sub cargaddldevoluciones(CveProveedor As Integer, SubTotal As Double)
|
||||||
Dim objcompras As New ClsCompras()
|
Dim objcompras As New ClsCompras()
|
||||||
|
|
||||||
If objcompras.GetCompraParaDevolucion(CveProveedor, UsuarioActual.CveEmpresa, SubTotal) Then
|
If objcompras.GetCompraParaDevolucion(CveProveedor, UsuarioActual.CveEmpresa, SubTotal) Then
|
||||||
DDLDevolucion.Items.Clear()
|
DDLDevolucion.Items.Clear()
|
||||||
Dim dtt As DataTable = objcompras.DtResultados
|
Dim dtt As DataTable = objcompras.DtResultados
|
||||||
@@ -13971,6 +13987,9 @@ Partial Class Compras_Compras
|
|||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Protected Sub DDLDevolucion_SelectedIndexChanged(sender As Object, e As EventArgs) Handles DDLDevolucion.SelectedIndexChanged
|
Protected Sub DDLDevolucion_SelectedIndexChanged(sender As Object, e As EventArgs) Handles DDLDevolucion.SelectedIndexChanged
|
||||||
|
|
||||||
|
FechaMovtoDev = MinFecha
|
||||||
|
|
||||||
If DdlTipoComprobante.SelectedValue.Contiene("DEV") Then
|
If DdlTipoComprobante.SelectedValue.Contiene("DEV") Then
|
||||||
DivAlmacenDev.Visible = True
|
DivAlmacenDev.Visible = True
|
||||||
End If
|
End If
|
||||||
@@ -13978,6 +13997,7 @@ Partial Class Compras_Compras
|
|||||||
Dim objcompras As New ClsCompras()
|
Dim objcompras As New ClsCompras()
|
||||||
If objcompras.GetCompraDetalleAlmacen(UsuarioActual.CveEmpresa, DDLDevolucion.SelectedValue.ToEntero) Then
|
If objcompras.GetCompraDetalleAlmacen(UsuarioActual.CveEmpresa, DDLDevolucion.SelectedValue.ToEntero) Then
|
||||||
GVDevolucion.DataSource = objcompras.DtResultados
|
GVDevolucion.DataSource = objcompras.DtResultados
|
||||||
|
FechaMovtoDev = objcompras.DtResultados.FiltroPrimeroValor("FechaMovto").ToDate.ToString("dd/MM/yyyy").ToDate
|
||||||
End If
|
End If
|
||||||
objcompras.Dispose()
|
objcompras.Dispose()
|
||||||
GVDevolucion.DataBind()
|
GVDevolucion.DataBind()
|
||||||
@@ -13988,8 +14008,12 @@ Partial Class Compras_Compras
|
|||||||
End If
|
End If
|
||||||
Next
|
Next
|
||||||
DdlAlmacenDevolucion.SelectedValueExist(CveAlmacen)
|
DdlAlmacenDevolucion.SelectedValueExist(CveAlmacen)
|
||||||
|
|
||||||
UPDevolucion.Update()
|
UPDevolucion.Update()
|
||||||
|
|
||||||
|
If EsGrupoDiaz AndAlso FechaMovtoDev <> MinFecha AndAlso (FechaMovtoDev >= TxtFecha.Text.ToDate) Then
|
||||||
|
Alert("La fecha de la devolución se cambiará a una fecha posterior al ingreso.", TipoMensaje.ToastAdventencia)
|
||||||
|
End If
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
'Protected Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click
|
'Protected Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click
|
||||||
' cargaddldevoluciones(CveProveedor, TextBox1.Text.ToDouble)
|
' cargaddldevoluciones(CveProveedor, TextBox1.Text.ToDouble)
|
||||||
@@ -14026,6 +14050,13 @@ Partial Class Compras_Compras
|
|||||||
If UsuarioActual.Empresa.Funcionalidad(574) = "1" Then tTolerancia = Math.Abs(TxtSubTotal2.Text.ToDecimal - subtotaldevolucion)
|
If UsuarioActual.Empresa.Funcionalidad(574) = "1" Then tTolerancia = Math.Abs(TxtSubTotal2.Text.ToDecimal - subtotaldevolucion)
|
||||||
If Math.Abs(TxtSubTotal2.Text.ToDecimal - subtotaldevolucion) <= tTolerancia Then
|
If Math.Abs(TxtSubTotal2.Text.ToDecimal - subtotaldevolucion) <= tTolerancia Then
|
||||||
VinculaDevolucion()
|
VinculaDevolucion()
|
||||||
|
|
||||||
|
If EsGrupoDiaz AndAlso FechaMovtoDev <> MinFecha AndAlso (FechaMovtoDev >= TxtFecha.Text.ToDate) Then
|
||||||
|
TxtFecha.Text = FechaMovtoDev.AddDays(1).ToString("dd/MM/yyyy")
|
||||||
|
Alert("La fecha de la devolución se cambiará a una fecha posterior al ingreso.", TipoMensaje.ToastAdventencia)
|
||||||
|
UpParametros.Update()
|
||||||
|
End If
|
||||||
|
|
||||||
Else
|
Else
|
||||||
Alert("El Total de la NC debe ser igual al total de la devolucion", TipoMensaje.MsgAdvertencia)
|
Alert("El Total de la NC debe ser igual al total de la devolucion", TipoMensaje.MsgAdvertencia)
|
||||||
End If
|
End If
|
||||||
|
|||||||
@@ -3039,12 +3039,14 @@ Partial Class Clientes
|
|||||||
If e.Row.RowIndex > -1 Then
|
If e.Row.RowIndex > -1 Then
|
||||||
If e.Row.DBCampo("Folio") = "N/D" Then
|
If e.Row.DBCampo("Folio") = "N/D" Then
|
||||||
e.Row.FCLiteral("LtlFactura").Text = e.Row.DataKey("Folio")
|
e.Row.FCLiteral("LtlFactura").Text = e.Row.DataKey("Folio")
|
||||||
Else
|
Else
|
||||||
If e.Row.DataKey("CveIE").ToString().ToEntero() > 0 Then
|
If e.Row.DataKey("Tipo").ToUpper().Contiene("NC", "ANT") Then
|
||||||
e.Row.FCLiteral("LtlFactura").Text = String.Format("<a class=""Texto"" href=""/Bancos/IE.aspx?CveIE={0}"">{1}</a>", e.Row.DataKey("CveIE"), e.Row.DataKey("Folio"))
|
e.Row.FCLiteral("LtlFactura").Text = String.Format("<a class=""Texto"" href=""/Ventas/Ventas.aspx?CveVenta={0}"">{1}</a>", e.Row.DataKey("CveVenta"), e.Row.DataKey("Folio"))
|
||||||
Else
|
Else
|
||||||
e.Row.FCLiteral("LtlFactura").Text = String.Format("<a class=""Texto"" href=""/Ventas/Ventas.aspx?CveVenta={0}"">{1}</a>", e.Row.DataKey("CveVenta"), e.Row.DataKey("Folio"))
|
If e.Row.DataKey("CveIE").ToString().ToEntero() > 0 Then
|
||||||
End If
|
e.Row.FCLiteral("LtlFactura").Text = String.Format("<a class=""Texto"" href=""/Bancos/IE.aspx?CveIE={0}"">{1}</a>", e.Row.DataKey("CveIE"), e.Row.DataKey("Folio"))
|
||||||
|
End If
|
||||||
|
End If
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user