Reportes contratos
This commit is contained in:
71
Contratos/RepContratosObraAvancesPartida.aspx.vb
Normal file
71
Contratos/RepContratosObraAvancesPartida.aspx.vb
Normal file
@@ -0,0 +1,71 @@
|
||||
Imports Extensiones
|
||||
Imports System.Data
|
||||
|
||||
Partial Class RepContratosObraAvancesPartida
|
||||
Inherits ClsPaginas
|
||||
|
||||
|
||||
|
||||
Property CveEstimacion As Integer
|
||||
|
||||
Get
|
||||
If ViewState("CveEstimacion") Is Nothing Then
|
||||
Return -1
|
||||
Else
|
||||
Return ViewState("CveEstimacion").ToString.ToEntero
|
||||
End If
|
||||
End Get
|
||||
Set(value As Integer)
|
||||
ViewState("CveEstimacion") = value
|
||||
End Set
|
||||
|
||||
|
||||
End Property
|
||||
|
||||
|
||||
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
|
||||
|
||||
If Not Page.IsPostBack Then
|
||||
|
||||
CveEstimacion = If(Request("CveEstimacion") IsNot Nothing AndAlso Request("CveEstimacion").ToString.ToEntero > 0, Request("CveEstimacion").ToString.ToEntero, -1)
|
||||
|
||||
If CveEstimacion > 0 Then
|
||||
CargaDatos()
|
||||
End If
|
||||
End If
|
||||
End Sub
|
||||
|
||||
|
||||
Private Sub CargaDatos()
|
||||
|
||||
Dim Con As New ClsContratos
|
||||
|
||||
If Con.GetContratosObraRepAvancesPartida(CveEstimacion, UsuarioActual.CveEmpresa) Then
|
||||
GVDatos.DataSource = Con.DtResultados
|
||||
|
||||
If Con.DtResultados.Rows.Count = 0 Then
|
||||
Alert("No se encontraron partidas.", TipoMensaje.MsgAdvertencia)
|
||||
End If
|
||||
Else
|
||||
GVDatos.DataSource = Nothing
|
||||
End If
|
||||
|
||||
Con.Dispose()
|
||||
|
||||
GVDatos.DataBind()
|
||||
UpDatos.Update()
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
|
||||
Protected Sub GV_RowDataBound(sender As Object, e As GridViewRowEventArgs) Handles GVDatos.RowDataBound
|
||||
|
||||
If e.Row.RowType = DataControlRowType.DataRow Then
|
||||
|
||||
End If
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
End Class
|
||||
Reference in New Issue
Block a user