-- activación valorxhora,
This commit is contained in:
@@ -33,7 +33,7 @@
|
|||||||
<asp:UpdatePanel ID="UpDatos" runat="server" UpdateMode="Conditional">
|
<asp:UpdatePanel ID="UpDatos" runat="server" UpdateMode="Conditional">
|
||||||
<ContentTemplate>
|
<ContentTemplate>
|
||||||
<asp:GridView ID="GvPuestos" runat="server" AutoGenerateColumns="False" ShowHeader="true"
|
<asp:GridView ID="GvPuestos" runat="server" AutoGenerateColumns="False" ShowHeader="true"
|
||||||
DataKeyNames="CvePuesto,Puesto,CveOcupacion,Estatus" EmptyDataText="No se encontraron Subtemas"
|
DataKeyNames="CvePuesto,Puesto,CveOcupacion,Estatus,ValorXHora" EmptyDataText="No se encontraron Subtemas"
|
||||||
ToolTip="Listado de Puestos" CssClass="ScrollAD table table-striped table-advance table-hover Widthall" GridLines="None" data-cols="0" data-heighterror="280">
|
ToolTip="Listado de Puestos" CssClass="ScrollAD table table-striped table-advance table-hover Widthall" GridLines="None" data-cols="0" data-heighterror="280">
|
||||||
<Columns>
|
<Columns>
|
||||||
<asp:TemplateField HeaderText="Puesto" ItemStyle-HorizontalAlign ="Left">
|
<asp:TemplateField HeaderText="Puesto" ItemStyle-HorizontalAlign ="Left">
|
||||||
@@ -50,6 +50,11 @@
|
|||||||
<ItemTemplate>
|
<ItemTemplate>
|
||||||
<asp:Literal ID="LtlOcupacion" runat="server" Text='<%# Eval("Ocupacion") %>'></asp:Literal>
|
<asp:Literal ID="LtlOcupacion" runat="server" Text='<%# Eval("Ocupacion") %>'></asp:Literal>
|
||||||
</ItemTemplate>
|
</ItemTemplate>
|
||||||
|
</asp:TemplateField>
|
||||||
|
<asp:TemplateField HeaderText="Valor x Hora" ItemStyle-HorizontalAlign ="Left" Visible="false">
|
||||||
|
<ItemTemplate>
|
||||||
|
<asp:Literal ID="LtlValorXHora" runat="server" Text='<%# Eval("ValorXHora") %>'></asp:Literal>
|
||||||
|
</ItemTemplate>
|
||||||
</asp:TemplateField>
|
</asp:TemplateField>
|
||||||
<asp:TemplateField HeaderText="Fecha" ItemStyle-HorizontalAlign ="Center" ItemStyle-Width="80">
|
<asp:TemplateField HeaderText="Fecha" ItemStyle-HorizontalAlign ="Center" ItemStyle-Width="80">
|
||||||
<ItemTemplate>
|
<ItemTemplate>
|
||||||
@@ -129,6 +134,13 @@
|
|||||||
<label for="<%= DdlArea.ClientID.ToString()%>">Ocupacion:</label>
|
<label for="<%= DdlArea.ClientID.ToString()%>">Ocupacion:</label>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div class="form-group form-md-line-input input-iconright" runat="server" id="divValorxhora" visible="false">
|
||||||
|
<asp:TextBox ID="TxtValorXHora" CssClass="form-control " runat="server" MaxLength="50" CausesValidation="true"></asp:TextBox>
|
||||||
|
<%--<asp:RequiredFieldValidator InitialValue="-1" ID="rfvDdlOcupacion" ControlToValidate="DdlOcupacion" Display="None" ValidationGroup="GrpPuesto" runat="server" Text="*" ErrorMessage="Seleccione una de las opciones"></asp:RequiredFieldValidator>
|
||||||
|
<ajax:ValidatorCalloutExtender ID="rfvcDdlOcupacion" runat="server" TargetControlID="rfvDdlOcupacion" HighlightCssClass="validatorCalloutHighlight"></ajax:ValidatorCalloutExtender>--%>
|
||||||
|
<label for="<%= TxtValorXHora.ClientID.ToString()%>">Valor x Hora:</label>
|
||||||
|
</div>
|
||||||
|
|
||||||
<div class="form-group form-md-line-input input-iconright">
|
<div class="form-group form-md-line-input input-iconright">
|
||||||
<asp:CheckBox Text="Activo" runat="server" ID="ChkEstatusPuesto" Checked="true" Visible="true" />
|
<asp:CheckBox Text="Activo" runat="server" ID="ChkEstatusPuesto" Checked="true" Visible="true" />
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -64,9 +64,6 @@ Partial Class RH_CatPuesto
|
|||||||
End Set
|
End Set
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Private Property DTArea As DataTable
|
Private Property DTArea As DataTable
|
||||||
Get
|
Get
|
||||||
If ViewState("DTArea") Is Nothing Then
|
If ViewState("DTArea") Is Nothing Then
|
||||||
@@ -134,17 +131,18 @@ Partial Class RH_CatPuesto
|
|||||||
|
|
||||||
CargaCatalogoOcupaciones()
|
CargaCatalogoOcupaciones()
|
||||||
|
|
||||||
|
|
||||||
If ObjPuestos.GetPuestos(UsuarioActual.CveEmpresa) Then
|
If ObjPuestos.GetPuestos(UsuarioActual.CveEmpresa) Then
|
||||||
GvPuestos.DataSource = ObjPuestos.DtResultados.FiltraParametros("CveEmpresa = " & UsuarioActual.CveEmpresa)
|
GvPuestos.DataSource = ObjPuestos.DtResultados
|
||||||
|
|
||||||
GlobalDTRHPuestos(UsuarioActual.CveEmpresa) = ObjPuestos.DtResultados
|
|
||||||
Else
|
Else
|
||||||
Me.GvPuestos.DataSource = Nothing
|
Me.GvPuestos.DataSource = Nothing
|
||||||
End If
|
End If
|
||||||
|
|
||||||
ObjPuestos.Dispose()
|
ObjPuestos.Dispose()
|
||||||
GvPuestos.DataBind()
|
GvPuestos.DataBind()
|
||||||
|
If UsuarioActual.CveEmpresa = 153 Then
|
||||||
|
GvPuestos.Columns(3).Visible = True
|
||||||
|
divValorxhora.Visible = True
|
||||||
|
End If
|
||||||
UpDatos.Update()
|
UpDatos.Update()
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
@@ -294,8 +292,6 @@ Partial Class RH_CatPuesto
|
|||||||
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
UpModalPuesto.Update()
|
UpModalPuesto.Update()
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
@@ -343,13 +339,13 @@ Partial Class RH_CatPuesto
|
|||||||
End If
|
End If
|
||||||
|
|
||||||
If CvePuesto = -1 And Actualizar = False Then
|
If CvePuesto = -1 And Actualizar = False Then
|
||||||
If ObjPuestos.AddPuesto(TxtPuesto.Text.Trim, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, DdlOcupacion.SelectedValue.ToEntero) Then
|
If ObjPuestos.AddPuesto(TxtPuesto.Text.Trim, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, DdlOcupacion.SelectedValue.ToEntero, TxtValorXHora.text.todecimal) Then
|
||||||
If ObjPuestos.GetPuestos(UsuarioActual.CveEmpresa) Then Application("GlobalDTRHPuestos") = ObjPuestos.DtResultados Else Application("GlobalDTRHPuestos") = Nothing
|
GlobalDTRHPuestos(UsuarioActual.CveEmpresa) = Nothing
|
||||||
Alert("Puesto agregado correctamente.")
|
Alert("Puesto agregado correctamente.")
|
||||||
End If
|
End If
|
||||||
Else
|
Else
|
||||||
If ObjPuestos.UpdatePuesto(CvePuesto, TxtPuesto.Text.Trim, estatus, UsuarioActual.CveUsuario, DdlOcupacion.SelectedValue.ToEntero) Then
|
If ObjPuestos.UpdatePuesto(CvePuesto, TxtPuesto.Text.Trim, estatus, UsuarioActual.CveUsuario, DdlOcupacion.SelectedValue.ToEntero, TxtValorXHora.Text.ToDecimal) Then
|
||||||
If ObjPuestos.GetPuestos(UsuarioActual.CveEmpresa) Then Application("GlobalDTRHPuestos") = ObjPuestos.DtResultados Else Application("GlobalDTRHPuestos") = Nothing
|
GlobalDTRHPuestos(UsuarioActual.CveEmpresa) = Nothing
|
||||||
Alert("Puesto actualizado correctamente.")
|
Alert("Puesto actualizado correctamente.")
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
@@ -388,6 +384,7 @@ Partial Class RH_CatPuesto
|
|||||||
|
|
||||||
CvePuesto = GvRow.DataKey("CvePuesto").ToEntero
|
CvePuesto = GvRow.DataKey("CvePuesto").ToEntero
|
||||||
TxtPuesto.Text = GvRow.DataKey("Puesto")
|
TxtPuesto.Text = GvRow.DataKey("Puesto")
|
||||||
|
TxtValorXHora.Text = GvRow.DataKey("ValorXHora").ToString
|
||||||
LtlTituloModalPuesto.Text = "Editar Puesto"
|
LtlTituloModalPuesto.Text = "Editar Puesto"
|
||||||
|
|
||||||
If Boolean.Parse(GvRow.DataKey("Estatus")) Then
|
If Boolean.Parse(GvRow.DataKey("Estatus")) Then
|
||||||
|
|||||||
Reference in New Issue
Block a user