Reportes contratos
This commit is contained in:
@@ -687,6 +687,94 @@ Public Class ClsContratos
|
||||
|
||||
#End Region
|
||||
|
||||
#Region "ESTIMACION OBRA"
|
||||
|
||||
Public Function GetContratosObraRepAvances(FechaI As Date, FechaF As Date, CveCliente As Integer, CveContrato As Integer, CveEmpresa As Integer) As Boolean
|
||||
Dim Retorno = False
|
||||
|
||||
DataAdapter("PA_Con_ContratosObraRepAvancesGet")
|
||||
With SqlAdapter.SelectCommand.Parameters
|
||||
.Add("@FechaI", SqlDbType.Date).Value = FechaI
|
||||
.Add("@FechaF", SqlDbType.Date).Value = FechaF
|
||||
.Add("@CveCliente", SqlDbType.Int).Value = CveCliente
|
||||
.Add("@CveContrato", SqlDbType.Int).Value = CveContrato
|
||||
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
||||
End With
|
||||
|
||||
Try
|
||||
SqlAdapter.Fill(Data)
|
||||
Retorno = True
|
||||
Catch ex As Exception
|
||||
OnError("Ocurrió un error al consultar el avance de contratos.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
|
||||
End Try
|
||||
|
||||
Return Retorno
|
||||
End Function
|
||||
|
||||
|
||||
Public Function GetContratosObraRepAvancesDetalle(CveContrato As Integer, CveEmpresa As Integer) As Boolean
|
||||
Dim Retorno = False
|
||||
|
||||
DataAdapter("PA_Con_ContratosObraRepAvancesDetalleGet")
|
||||
With SqlAdapter.SelectCommand.Parameters
|
||||
.Add("@CveContrato", SqlDbType.Int).Value = CveContrato
|
||||
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
||||
End With
|
||||
|
||||
Try
|
||||
SqlAdapter.Fill(Data)
|
||||
Retorno = True
|
||||
Catch ex As Exception
|
||||
OnError("Ocurrió un error al consultar el detalle del avance.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
|
||||
End Try
|
||||
|
||||
Return Retorno
|
||||
End Function
|
||||
|
||||
|
||||
Public Function GetContratosObraRepAvancesPartida(CveEstimacion As Integer, CveEmpresa As Integer) As Boolean
|
||||
Dim Retorno = False
|
||||
|
||||
DataAdapter("PA_Con_ContratosObraRepAvancesPartidaGet")
|
||||
With SqlAdapter.SelectCommand.Parameters
|
||||
.Add("@CveEstimacion", SqlDbType.Int).Value = CveEstimacion
|
||||
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
||||
End With
|
||||
|
||||
Try
|
||||
SqlAdapter.Fill(Data)
|
||||
Retorno = True
|
||||
Catch ex As Exception
|
||||
OnError("Ocurrió un error al consultar las partidas.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
|
||||
End Try
|
||||
|
||||
Return Retorno
|
||||
End Function
|
||||
|
||||
Public Function GetContratosObraRepAvancesPartida(FechaI As Date, FechaF As Date, CveCliente As Integer, CveContrato As Integer, CveEmpresa As Integer) As Boolean
|
||||
Dim Retorno = False
|
||||
|
||||
DataAdapter("PA_Con_ContratosObraRepAvancesPartidaGet")
|
||||
With SqlAdapter.SelectCommand.Parameters
|
||||
.Add("@FechaI", SqlDbType.Date).Value = FechaI
|
||||
.Add("@FechaF", SqlDbType.Date).Value = FechaF
|
||||
.Add("@CveCliente", SqlDbType.Int).Value = CveCliente
|
||||
.Add("@CveContrato", SqlDbType.Int).Value = CveContrato
|
||||
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
||||
End With
|
||||
|
||||
Try
|
||||
SqlAdapter.Fill(Data)
|
||||
Retorno = True
|
||||
Catch ex As Exception
|
||||
OnError("Ocurrió un error al consultar el avance de partida.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
|
||||
End Try
|
||||
|
||||
Return Retorno
|
||||
End Function
|
||||
|
||||
#End Region
|
||||
|
||||
#Region "C I C L O C O M E R C I A L"
|
||||
Public Function CicloComercialAdd(CveContrato As Integer, CveCotizacion As Integer, CveCliente As Integer, FueFacturado As Boolean, CveFactura As Integer, Estatus As Integer, CveEmpresa As Integer, FechaVenc As Date) As Boolean
|
||||
Dim Retorno As Boolean = False
|
||||
|
||||
@@ -4981,13 +4981,12 @@ Public Class ClsPaginas
|
||||
PaginaDict.Add("/PV/PVRepVentasCompras.aspx".ToUpper(), 273)
|
||||
|
||||
PaginaDict.Add("/Contratos/ContratoObra.aspx".ToUpper(), -1)
|
||||
|
||||
|
||||
|
||||
PaginaDict.Add("/Contratos/RepContratosObraAvances.aspx".ToUpper(), -1)
|
||||
PaginaDict.Add("/Contratos/RepContratosObraAvancesDetalle.aspx".ToUpper(), -1)
|
||||
PaginaDict.Add("/Contratos/RepContratosObraAvancesPartida.aspx".ToUpper(), -1)
|
||||
|
||||
|
||||
'Orden Produccion'
|
||||
|
||||
'RMA
|
||||
PaginaDict.Add("/RMA/Garantias.aspx".ToUpper(), 175)
|
||||
|
||||
|
||||
169
Contratos/RepContratosObraAvances.aspx
Normal file
169
Contratos/RepContratosObraAvances.aspx
Normal file
@@ -0,0 +1,169 @@
|
||||
<%@ Page Title="" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="RepContratosObraAvances.aspx.vb" Inherits="RepContratosObraAvances" %>
|
||||
|
||||
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>
|
||||
<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content2" ContentPlaceHolderID="Css" runat="Server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content3" ContentPlaceHolderID="HB" runat="Server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content4" ContentPlaceHolderID="E" runat="Server">
|
||||
Reporte Contratos Avance
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content5" ContentPlaceHolderID="H" runat="Server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content6" ContentPlaceHolderID="C" runat="Server">
|
||||
|
||||
<asp:UpdatePanel ID="UpFiltros" runat="server" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
|
||||
|
||||
<div class="portlet solid grey-cascade portlet-filter" style="">
|
||||
<div class="portlet-title portlet-filterT smalltitle" >
|
||||
|
||||
<div class="tools">
|
||||
<asp:Button ID="BtnConsultar" runat="server" Text="Consultar" class="btn btn-primary" CausesValidation="true" ValidationGroup="GrConsulta" />
|
||||
</div>
|
||||
|
||||
<div class="titlefiltros caption">
|
||||
<div class="row">
|
||||
|
||||
<div class="col-md-1">
|
||||
Fecha Inicio:
|
||||
</div>
|
||||
<div class="col-md-1">
|
||||
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 100px !important; padding: 0px;">
|
||||
<asp:TextBox Width="80px" ID="txtFechaI" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="10"></asp:TextBox>
|
||||
<span class="input-group-btn ">
|
||||
<asp:LinkButton ID="imgCalendario" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
|
||||
</span>
|
||||
</div>
|
||||
<ajax:MaskedEditExtender ID="MEEFechaI" runat="server" TargetControlID="txtFechaI" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
||||
<ajax:CalendarExtender runat="server" ID="Calendario" TargetControlID="txtFechaI" PopupButtonID="ImgCalendario" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
||||
<asp:RequiredFieldValidator ID="rfvFechaI" runat="server" ControlToValidate="txtFechaI" Display="None" ErrorMessage="El campo <b>''Fecha Inicial''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="GrConsulta"></asp:RequiredFieldValidator>
|
||||
<asp:CompareValidator ID="cvFechaI" runat="server" ControlToValidate="txtFechaI" Display="None" ErrorMessage="El campo <b>''Fecha Inicial''</b> no tienes el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="GrConsulta"></asp:CompareValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="vcoFfvFI" runat="server" HighlightCssClass="vco" TargetControlID="rfvFechaI" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
<ajax:ValidatorCalloutExtender ID="vcoCvFI" runat="server" HighlightCssClass="vco" TargetControlID="cvFechaI" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<div class="col-md-1">
|
||||
Fecha Fin:
|
||||
</div>
|
||||
<div class="col-md-1">
|
||||
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 100px !important; padding: 0px;">
|
||||
<asp:TextBox Width="80px" ID="txtFechaF" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="10"></asp:TextBox>
|
||||
<span class="input-group-btn ">
|
||||
<asp:LinkButton ID="imgCalendarioF" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
|
||||
</span>
|
||||
</div>
|
||||
<ajax:MaskedEditExtender ID="MEEFechaF" runat="server" TargetControlID="txtFechaF" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
||||
<ajax:CalendarExtender runat="server" ID="Calendario2" TargetControlID="txtFechaF" PopupButtonID="imgCalendarioF" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
||||
<asp:RequiredFieldValidator ID="rfvFechaF" runat="server" ControlToValidate="txtFechaF" Display="None" ErrorMessage="El campo <b>''Fecha Final''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="GrConsulta"></asp:RequiredFieldValidator>
|
||||
<asp:CompareValidator ID="cvFechaF" runat="server" ControlToValidate="txtFechaF" Display="None" ErrorMessage="El campo <b>''Fecha Final''</b> no tienes el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="GrConsulta"></asp:CompareValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="vcoRfvFF" runat="server" HighlightCssClass="vco" TargetControlID="rfvFechaF" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
<ajax:ValidatorCalloutExtender ID="vcoCvFF" runat="server" HighlightCssClass="vco" TargetControlID="cvFechaF" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
|
||||
<div class="col-md-1">
|
||||
Cliente:
|
||||
</div>
|
||||
<div class="col-md-1">
|
||||
<asp:DropDownList ID="DdlCliente" runat="server" DataTextField="NombreComercial" DataValueField="CveCliente" Class="select2me" Width="100PX" ></asp:DropDownList>
|
||||
</div>
|
||||
|
||||
<div class="col-md-1">
|
||||
Contrato:
|
||||
</div>
|
||||
<div class="col-md-1">
|
||||
<asp:DropDownList ID="DdlContrato" runat="server" DataTextField="NumeroContrato" DataValueField="CveContrato" Class="select2me" Width="100PX" ></asp:DropDownList>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
|
||||
<asp:UpdatePanel ID="UpDatos" runat="server" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
|
||||
|
||||
<div class="row">
|
||||
|
||||
<div class="col-md-12" style="text-align:right!important">
|
||||
<div style="display: inline-block">
|
||||
<input type="text" id="TxtBusqueda" class="form-control input-sm" onkeyup="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GVDatos.ClientID) %>" style="display: inline-block; margin-right: -20px; width: 150px; height: 25px; border-color: #89C4F4;" />
|
||||
<a href="javascript:;" onclick="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GVDatos.ClientID) %>" class="btn btn-circle btn-sm label-info"><i class="icon-magnifier"></i></a>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
|
||||
<asp:GridView ID="GVDatos" runat="server" AutoGenerateColumns="false" EmptyDataText="No se encontraron contratos con los Filtros seleccionados"
|
||||
DataKeyNames="CveContrato" ShowHeader="True"
|
||||
CssClass="table table-striped table-hover Widthall ScrollAD mysmallbtn" GridLines="None">
|
||||
<Columns>
|
||||
<asp:TemplateField HeaderText="Fecha I.">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="LitEst" runat="server" Text='<%# Eval("FechaInicial", "{0:dd/MM/yyyy}")%>' ></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Center"></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Cliente">
|
||||
<ItemTemplate>
|
||||
<asp:HyperLink ID="HplCliente" CssClass="Texto" runat="server" Text='<%# Eval("Nombre") %>' NavigateUrl='<%# Eval("CveCliente", "../Ventas/Clientes.aspx?CveCliente={0}")%>' Target="_blank" ></asp:HyperLink>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="# Contrato">
|
||||
<ItemTemplate>
|
||||
<asp:HyperLink ID="HplContratado" CssClass="Texto" runat="server" Text='<%# Eval("NumeroContrato")%>' NavigateUrl='<%# Eval("CveContrato", "RepContratosObraAvancesDetalle.aspx?CveContrato={0}") %>' Target="_blank" ></asp:HyperLink>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Descripción">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="LblDescripcion" CssClass="Texto" runat="server" Text='<%# Eval("DescripcionContrato")%>'> </asp:Label>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Importe">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="LblImporte" CssClass="Texto" runat="server" Text='<%# Eval("Importe", "{0:N2}")%>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Right"></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Avance %" >
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="LblIAvancePorcentaje" runat="server" Text='<%# Eval("AvancePorcentaje", "{0:N2}")%>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Right"></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Avance $">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="HplOFA" CssClass="Texto" runat="server" Text='<%# Eval("AvanceImporte", "{0:N2}")%>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Right"></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
</Columns>
|
||||
</asp:GridView>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<br />
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content7" ContentPlaceHolderID="JS" runat="Server">
|
||||
</asp:Content>
|
||||
|
||||
75
Contratos/RepContratosObraAvances.aspx.vb
Normal file
75
Contratos/RepContratosObraAvances.aspx.vb
Normal file
@@ -0,0 +1,75 @@
|
||||
Imports Extensiones
|
||||
Imports System.Data
|
||||
|
||||
Partial Class RepContratosObraAvances
|
||||
Inherits ClsPaginas
|
||||
|
||||
|
||||
|
||||
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
|
||||
If Not Page.IsPostBack Then
|
||||
|
||||
CargaClientes()
|
||||
CargaContratos()
|
||||
'CargaDatos()
|
||||
|
||||
End If
|
||||
End Sub
|
||||
|
||||
|
||||
Private Sub CargaDatos()
|
||||
|
||||
Dim Con As New ClsContratos
|
||||
|
||||
If Con.GetContratosObraRepAvances(txtFechaI.Text.ToDate, txtFechaF.Text.ToDate, DdlCliente.SelectedValue.ToEntero, DdlContrato.SelectedValue.ToEntero, UsuarioActual.CveEmpresa) Then
|
||||
GVDatos.DataSource = Con.DtResultados
|
||||
Else
|
||||
GVDatos.DataSource = Nothing
|
||||
End If
|
||||
|
||||
Con.Dispose()
|
||||
|
||||
GVDatos.DataBind()
|
||||
UpDatos.Update()
|
||||
|
||||
End Sub
|
||||
|
||||
#Region "C O M B O S"
|
||||
|
||||
|
||||
Private Sub CargaContratos()
|
||||
DdlContrato.DataSource = GlobalDTContratos.FiltraParametros($"CveEmpresa = {UsuarioActual.CveEmpresa} AND CveContratoTipo IN(30,31) ")
|
||||
DdlContrato.DataBind()
|
||||
DdlContrato.Items.Insert(0, New System.Web.UI.WebControls.ListItem("Todos", "-1"))
|
||||
End Sub
|
||||
|
||||
Private Sub CargaClientes()
|
||||
Dim dt As DataTable = Nothing
|
||||
Dim Cli As New ClsClientes
|
||||
If Cli.GetClientes(-1, "-1", "-1", "-1", "-1", "-1", "-1", -1, UsuarioActual.CveEmpresa) Then
|
||||
dt = Cli.DtResultados
|
||||
End If
|
||||
Cli.Dispose()
|
||||
DdlCliente.DataSource = dt
|
||||
DdlCliente.DataBind()
|
||||
DdlCliente.Items.Insert(0, New ListItem("Todos", "-1"))
|
||||
End Sub
|
||||
|
||||
#End Region
|
||||
|
||||
Protected Sub GV_RowDataBound(sender As Object, e As GridViewRowEventArgs) Handles GVDatos.RowDataBound
|
||||
|
||||
If e.Row.RowType = DataControlRowType.DataRow Then
|
||||
|
||||
End If
|
||||
|
||||
End Sub
|
||||
|
||||
Protected Sub CmdConsultar_Click(sender As Object, e As EventArgs) Handles BtnConsultar.Click
|
||||
CargaDatos()
|
||||
End Sub
|
||||
|
||||
|
||||
|
||||
|
||||
End Class
|
||||
175
Contratos/RepContratosObraAvancesDetalle.aspx
Normal file
175
Contratos/RepContratosObraAvancesDetalle.aspx
Normal file
@@ -0,0 +1,175 @@
|
||||
<%@ Page Title="" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="RepContratosObraAvancesDetalle.aspx.vb" Inherits="RepContratosObraAvancesDetalle" %>
|
||||
|
||||
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>
|
||||
<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content2" ContentPlaceHolderID="Css" runat="Server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content3" ContentPlaceHolderID="HB" runat="Server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content4" ContentPlaceHolderID="E" runat="Server">
|
||||
Reporte Contratos Avance Detalle
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content5" ContentPlaceHolderID="H" runat="Server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content6" ContentPlaceHolderID="C" runat="Server">
|
||||
|
||||
<%-- <asp:UpdatePanel ID="UpFiltros" runat="server" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
|
||||
|
||||
<div class="portlet solid grey-cascade portlet-filter" style="">
|
||||
<div class="portlet-title portlet-filterT smalltitle" >
|
||||
|
||||
<div class="tools">
|
||||
<asp:Button ID="BtnConsultar" runat="server" Text="Consultar" class="btn btn-primary" CausesValidation="true" ValidationGroup="GrConsulta" />
|
||||
</div>
|
||||
|
||||
<div class="titlefiltros caption">
|
||||
<div class="row">
|
||||
|
||||
<div class="col-md-1">
|
||||
Fecha Inicio:
|
||||
</div>
|
||||
<div class="col-md-1">
|
||||
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 100px !important; padding: 0px;">
|
||||
<asp:TextBox Width="80px" ID="txtFechaI" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="10"></asp:TextBox>
|
||||
<span class="input-group-btn ">
|
||||
<asp:LinkButton ID="imgCalendario" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
|
||||
</span>
|
||||
</div>
|
||||
<ajax:MaskedEditExtender ID="MEEFechaI" runat="server" TargetControlID="txtFechaI" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
||||
<ajax:CalendarExtender runat="server" ID="Calendario" TargetControlID="txtFechaI" PopupButtonID="ImgCalendario" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
||||
<asp:RequiredFieldValidator ID="rfvFechaI" runat="server" ControlToValidate="txtFechaI" Display="None" ErrorMessage="El campo <b>''Fecha Inicial''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="GrConsulta"></asp:RequiredFieldValidator>
|
||||
<asp:CompareValidator ID="cvFechaI" runat="server" ControlToValidate="txtFechaI" Display="None" ErrorMessage="El campo <b>''Fecha Inicial''</b> no tienes el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="GrConsulta"></asp:CompareValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="vcoFfvFI" runat="server" HighlightCssClass="vco" TargetControlID="rfvFechaI" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
<ajax:ValidatorCalloutExtender ID="vcoCvFI" runat="server" HighlightCssClass="vco" TargetControlID="cvFechaI" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<div class="col-md-1">
|
||||
Fecha Fin:
|
||||
</div>
|
||||
<div class="col-md-1">
|
||||
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 100px !important; padding: 0px;">
|
||||
<asp:TextBox Width="80px" ID="txtFechaF" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="10"></asp:TextBox>
|
||||
<span class="input-group-btn ">
|
||||
<asp:LinkButton ID="imgCalendarioF" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
|
||||
</span>
|
||||
</div>
|
||||
<ajax:MaskedEditExtender ID="MEEFechaF" runat="server" TargetControlID="txtFechaF" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
||||
<ajax:CalendarExtender runat="server" ID="Calendario2" TargetControlID="txtFechaF" PopupButtonID="imgCalendarioF" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
||||
<asp:RequiredFieldValidator ID="rfvFechaF" runat="server" ControlToValidate="txtFechaF" Display="None" ErrorMessage="El campo <b>''Fecha Final''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="GrConsulta"></asp:RequiredFieldValidator>
|
||||
<asp:CompareValidator ID="cvFechaF" runat="server" ControlToValidate="txtFechaF" Display="None" ErrorMessage="El campo <b>''Fecha Final''</b> no tienes el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="GrConsulta"></asp:CompareValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="vcoRfvFF" runat="server" HighlightCssClass="vco" TargetControlID="rfvFechaF" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
<ajax:ValidatorCalloutExtender ID="vcoCvFF" runat="server" HighlightCssClass="vco" TargetControlID="cvFechaF" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
|
||||
<div class="col-md-1">
|
||||
Cliente:
|
||||
</div>
|
||||
<div class="col-md-1">
|
||||
<asp:DropDownList ID="DdlCliente" runat="server" DataTextField="NombreComercial" DataValueField="CveCliente" Class="select2me" Width="100PX" ></asp:DropDownList>
|
||||
</div>
|
||||
|
||||
<div class="col-md-1">
|
||||
Contrato:
|
||||
</div>
|
||||
<div class="col-md-1">
|
||||
<asp:DropDownList ID="DdlContrato" runat="server" DataTextField="NumeroContrato" DataValueField="CveContrato" Class="select2me" Width="100PX" ></asp:DropDownList>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>--%>
|
||||
|
||||
|
||||
|
||||
<asp:UpdatePanel ID="UpDatos" runat="server" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
|
||||
<div class="row">
|
||||
|
||||
<div class="col-md-6" style="text-align:right!important">
|
||||
<div style="display: inline-block">
|
||||
<input type="text" id="TxtBusqueda" class="form-control input-sm" onkeyup="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GVDatos.ClientID) %>" style="display: inline-block; margin-right: -20px; width: 150px; height: 25px; border-color: #89C4F4;" />
|
||||
<a href="javascript:;" onclick="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GVDatos.ClientID) %>" class="btn btn-circle btn-sm label-info"><i class="icon-magnifier"></i></a>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
|
||||
<asp:GridView ID="GVDatos" runat="server" AutoGenerateColumns="false" EmptyDataText="No se encontraron contratos con los Filtros seleccionados"
|
||||
DataKeyNames="CveContrato" ShowHeader="True"
|
||||
CssClass="table table-striped table-hover Widthall ScrollAD mysmallbtn" GridLines="None">
|
||||
<Columns>
|
||||
<asp:TemplateField HeaderText="# Estimación">
|
||||
<ItemTemplate>
|
||||
<asp:HyperLink ID="LblNumeroEstimacion" CssClass="Texto" runat="server" Text='<%# Eval("NumeroEstimacion") %>' NavigateUrl='<%# Eval("CveEstimacion", "RepContratosObraAvancesPartida.aspx?CveEstimacion={0}")%>' Target="_blank" ></asp:HyperLink>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Center"></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
|
||||
<asp:TemplateField HeaderText="Fecha">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="LblFecha" runat="server" Text='<%# Eval("FechaEstimacion", "{0:dd/MM/yyyy}")%>' ></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Center"></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
|
||||
<asp:TemplateField HeaderText="Avance %" >
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="LblIAvancePorcentaje" runat="server" Text='<%# Eval("AvancePorcentaje", "{0:N2}")%>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Right"></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
|
||||
<asp:TemplateField HeaderText="Avance acumulado %" >
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="LblIAvancePorcentajeAcumulado" runat="server" Text='<%# Eval("AvanceAcumuladoPorcentaje", "{0:N2}")%>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Right"></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
|
||||
<asp:TemplateField HeaderText="Avance $">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="HplOFA" CssClass="Texto" runat="server" Text='<%# Eval("AvanceImporte", "{0:N2}")%>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Right"></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
|
||||
<asp:TemplateField HeaderText="Facturado">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="LblFacturado" CssClass="Texto" runat="server" Text='<%# Eval("Facturado")%>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Center"></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
</Columns>
|
||||
</asp:GridView>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<br />
|
||||
|
||||
|
||||
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content7" ContentPlaceHolderID="JS" runat="Server">
|
||||
</asp:Content>
|
||||
|
||||
95
Contratos/RepContratosObraAvancesDetalle.aspx.vb
Normal file
95
Contratos/RepContratosObraAvancesDetalle.aspx.vb
Normal file
@@ -0,0 +1,95 @@
|
||||
Imports Extensiones
|
||||
Imports System.Data
|
||||
|
||||
Partial Class RepContratosObraAvancesDetalle
|
||||
Inherits ClsPaginas
|
||||
|
||||
|
||||
Property CveContrato As Integer
|
||||
|
||||
Get
|
||||
If ViewState("CveContrato") Is Nothing Then
|
||||
Return -1
|
||||
Else
|
||||
Return ViewState("CveContrato").ToString.ToEntero
|
||||
End If
|
||||
End Get
|
||||
Set(value As Integer)
|
||||
ViewState("CveContrato") = value
|
||||
End Set
|
||||
|
||||
|
||||
End Property
|
||||
|
||||
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
|
||||
|
||||
If Not Page.IsPostBack Then
|
||||
|
||||
CveContrato = If(Request("CveContrato") IsNot Nothing AndAlso Request("CveContrato").ToString.ToEntero > 0, Request("CveContrato").ToString.ToEntero, -1)
|
||||
|
||||
If CveContrato > 0 Then
|
||||
CargaDatos()
|
||||
End If
|
||||
End If
|
||||
End Sub
|
||||
|
||||
|
||||
Private Sub CargaDatos()
|
||||
|
||||
Dim Con As New ClsContratos
|
||||
|
||||
If Con.GetContratosObraRepAvancesDetalle(CveContrato, UsuarioActual.CveEmpresa) Then
|
||||
GVDatos.DataSource = Con.DtResultados
|
||||
|
||||
If Con.DtResultados.Rows.Count = 0 Then
|
||||
Alert("No se encontraron estimaciones.", TipoMensaje.MsgAdvertencia)
|
||||
End If
|
||||
Else
|
||||
GVDatos.DataSource = Nothing
|
||||
|
||||
End If
|
||||
|
||||
Con.Dispose()
|
||||
|
||||
GVDatos.DataBind()
|
||||
UpDatos.Update()
|
||||
|
||||
End Sub
|
||||
|
||||
'#Region "C O M B O S"
|
||||
|
||||
|
||||
' Private Sub CargaContratos()
|
||||
' DdlContrato.DataSource = GlobalDTContratos.FiltraParametros($"CveEmpresa = {UsuarioActual.CveEmpresa} AND CveContratoTipo IN(30,31) ")
|
||||
' DdlContrato.DataBind()
|
||||
' DdlContrato.Items.Insert(0, New System.Web.UI.WebControls.ListItem("Todos", "-1"))
|
||||
' End Sub
|
||||
|
||||
' Private Sub CargaClientes()
|
||||
' Dim dt As DataTable = Nothing
|
||||
' Dim Cli As New ClsClientes
|
||||
' If Cli.GetClientes(-1, "-1", "-1", "-1", "-1", "-1", "-1", -1, UsuarioActual.CveEmpresa) Then
|
||||
' dt = Cli.DtResultados
|
||||
' End If
|
||||
' Cli.Dispose()
|
||||
' DdlCliente.DataSource = dt
|
||||
' DdlCliente.DataBind()
|
||||
' DdlCliente.Items.Insert(0, New ListItem("Todos", "-1"))
|
||||
' End Sub
|
||||
|
||||
'#End Region
|
||||
|
||||
Protected Sub GV_RowDataBound(sender As Object, e As GridViewRowEventArgs) Handles GVDatos.RowDataBound
|
||||
|
||||
If e.Row.RowType = DataControlRowType.DataRow Then
|
||||
|
||||
End If
|
||||
|
||||
End Sub
|
||||
|
||||
'Protected Sub CmdConsultar_Click(sender As Object, e As EventArgs) Handles BtnConsultar.Click
|
||||
' CargaDatos()
|
||||
'End Sub
|
||||
|
||||
|
||||
End Class
|
||||
@@ -1,4 +1,4 @@
|
||||
<%@ Page Title="" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="RepContratosAvances.aspx.vb" Inherits="RepContratosAvances" %>
|
||||
<%@ Page Title="" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="RepContratosObraAvancesPartida.aspx.vb" Inherits="RepContratosObraAvancesPartida" %>
|
||||
|
||||
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>
|
||||
<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
|
||||
@@ -8,12 +8,14 @@
|
||||
<asp:Content ID="Content3" ContentPlaceHolderID="HB" runat="Server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content4" ContentPlaceHolderID="E" runat="Server">
|
||||
Reporte de Contratos
|
||||
Reporte Contratos Avance por partida
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content5" ContentPlaceHolderID="H" runat="Server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content6" ContentPlaceHolderID="C" runat="Server">
|
||||
<asp:UpdatePanel ID="UpFiltros" runat="server" UpdateMode="Conditional">
|
||||
|
||||
|
||||
<%-- <asp:UpdatePanel ID="UpFiltros" runat="server" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
<asp:Panel ID="PnlFiltros" runat="server" DefaultButton="CmdConsultar">
|
||||
<div class="portlet solid grey-cascade portlet-filter" style="">
|
||||
@@ -44,80 +46,111 @@
|
||||
</div>
|
||||
</asp:Panel>
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
</asp:UpdatePanel>--%>
|
||||
|
||||
|
||||
<asp:UpdatePanel ID="UpDatos" runat="server" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
<table class="table table-striped table-advance table-hover">
|
||||
<thead>
|
||||
<tr class="Titulos">
|
||||
<th width="60px">#</th>
|
||||
<th width="300px">
|
||||
<asp:LinkButton ID="LbSubSeccion" runat="server" CausesValidation="false" Text="Cliente/ Contrato / Partida" /></th>
|
||||
<th width="120px">
|
||||
<asp:LinkButton ID="LinkButton1" runat="server" CausesValidation="false" Text="Contratado" /></th>
|
||||
<th width="120px">
|
||||
<asp:LinkButton ID="LinkButton4" runat="server" CausesValidation="false" Text="Actual" /></th>
|
||||
<th width="120px">
|
||||
<asp:LinkButton ID="LinkButton5" runat="server" CausesValidation="false" Text="Por Estimar" /></th>
|
||||
<th width="120px">
|
||||
<asp:LinkButton ID="LinkButton2" runat="server" CausesValidation="false" Text="Ejecutado" /></th>
|
||||
<th width="120px">
|
||||
<asp:LinkButton ID="LinkButton3" runat="server" CausesValidation="false" Text="Obra Faltante" /></th>
|
||||
</tr>
|
||||
</thead>
|
||||
</table>
|
||||
<asp:GridView ID="GV" runat="server" AutoGenerateColumns="false" EmptyDataText="No se encontraron Estimaciones con los Filtros seleccionados" DataKeyNames="CveContrato" ShowHeader="false" SelectedRowStyle-BackColor="#CCFF66" CssClass="table table-striped table-advance table-hover" Style="margin-top: -10px; text-align: center;" GridLines="None">
|
||||
|
||||
|
||||
<div class="row">
|
||||
|
||||
<div class="col-md-6" style="text-align:right!important">
|
||||
<div style="display: inline-block">
|
||||
<input type="text" id="TxtBusqueda" class="form-control input-sm" onkeyup="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GVDatos.ClientID) %>" style="display: inline-block; margin-right: -20px; width: 150px; height: 25px; border-color: #89C4F4;" />
|
||||
<a href="javascript:;" onclick="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GVDatos.ClientID) %>" class="btn btn-circle btn-sm label-info"><i class="icon-magnifier"></i></a>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
|
||||
<asp:GridView ID="GVDatos" runat="server" AutoGenerateColumns="false" EmptyDataText="No se encontraron contratos con los Filtros seleccionados"
|
||||
DataKeyNames="CveContrato" ShowHeader="True"
|
||||
CssClass="table table-striped table-hover Widthall ScrollAD mysmallbtn" GridLines="None">
|
||||
<Columns>
|
||||
<asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Producto">
|
||||
<ItemTemplate>
|
||||
<asp:Literal ID="LitEst" runat="server" Text='<%# Eval("CveContrato")%>' />
|
||||
<asp:Label ID="LblPS" runat="server" Text='<%# Eval("PS")%>' ></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Center"></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField>
|
||||
|
||||
<asp:TemplateField HeaderText="PU" >
|
||||
<ItemTemplate>
|
||||
<asp:HyperLink ID="HplAgrupador" CssClass="Texto" runat="server" Text='<%# Eval("Agrupador") %>' NavigateUrl='<%# Eval("CveContrato", "ContratosDetalle.aspx?CveContrato={0}&Op=2")%>'></asp:HyperLink>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField>
|
||||
<ItemTemplate>
|
||||
<asp:HyperLink ID="HplContratado" CssClass="Texto" runat="server" Text='<%# Eval("Contratado", "{0:N2}")%>'></asp:HyperLink>
|
||||
<asp:Label ID="LblPU" runat="server" Text='<%# Eval("PU", "{0:N2}")%>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Right"></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField>
|
||||
|
||||
<asp:TemplateField HeaderText="Avance $">
|
||||
<ItemTemplate>
|
||||
<asp:HyperLink ID="HplActual" CssClass="Texto" runat="server" Text='<%# Eval("LoQueEstoyHaciendo", "{0:N2}")%>'></asp:HyperLink>
|
||||
<asp:Label ID="LblAvanceImporte" CssClass="Texto" runat="server" Text='<%# Eval("AvanceImporte", "{0:N2}")%>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Right"></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField>
|
||||
|
||||
<asp:TemplateField HeaderText="Avance Anterior$">
|
||||
<ItemTemplate>
|
||||
<asp:HyperLink ID="HPlPorEstimar" CssClass="Texto" runat="server" Text='<%# Eval("PorEstimar", "{0:N2}")%>'></asp:HyperLink>
|
||||
<asp:Label ID="LblAvanceImporteAnterior" CssClass="Texto" runat="server" Text='<%# Eval("AvanceImporteAnterior", "{0:N2}")%>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Right"></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField>
|
||||
|
||||
<asp:TemplateField HeaderText="Avance Acumulado $">
|
||||
<ItemTemplate>
|
||||
<asp:HyperLink ID="HplEjecutado" CssClass="Texto" runat="server" Text='<%# Eval("Ejecutado", "{0:N2}")%>'></asp:HyperLink>
|
||||
<asp:Label ID="LblAvanceImporte" CssClass="Texto" runat="server" Text='<%# Eval("AvanceAcumulado", "{0:N2}")%>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Right"></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField>
|
||||
|
||||
<%-- <asp:TemplateField HeaderText="Cliente">
|
||||
<ItemTemplate>
|
||||
<asp:HyperLink ID="HplOFA" CssClass="Texto" runat="server" Text='<%# Eval("OFA", "{0:N2}")%>'></asp:HyperLink>
|
||||
<asp:HyperLink ID="HplCliente" CssClass="Texto" runat="server" Text='<%# Eval("Nombre") %>' NavigateUrl='<%# Eval("CveCliente", "../Ventas/Clientes.aspx?CveCliente={0}")%>' Target="_blank" ></asp:HyperLink>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="# Contrato">
|
||||
<ItemTemplate>
|
||||
<asp:HyperLink ID="HplContratado" CssClass="Texto" runat="server" Text='<%# Eval("NumeroContrato")%>' NavigateUrl='<%# Eval("CveContrato", "RepContratosObraAvancesDetalle.aspx?CveContrato={0}") %>' Target="_blank" ></asp:HyperLink>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Descripción">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="LblDescripcion" CssClass="Texto" runat="server" Text='<%# Eval("DescripcionContrato")%>'> </asp:Label>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
|
||||
|
||||
<asp:TemplateField HeaderText="Avance %" >
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="LblIAvancePorcentaje" runat="server" Text='<%# Eval("AvancePorcentaje", "{0:N2}")%>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Right"></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
</Columns>
|
||||
<RowStyle CssClass="Texto" />
|
||||
<AlternatingRowStyle CssClass="TextoAlterno" />
|
||||
<HeaderStyle CssClass="Titulos" />
|
||||
</asp:GridView>
|
||||
<asp:TemplateField HeaderText="Avance $">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="HplOFA" CssClass="Texto" runat="server" Text='<%# Eval("AvanceImporte", "{0:N2}")%>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Right"></ItemStyle>
|
||||
</asp:TemplateField>--%>
|
||||
|
||||
|
||||
</Columns>
|
||||
</asp:GridView>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<br />
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
|
||||
|
||||
|
||||
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content7" ContentPlaceHolderID="JS" runat="Server">
|
||||
</asp:Content>
|
||||
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