-- activación valorxhora,
This commit is contained in:
@@ -33,7 +33,7 @@
|
||||
<asp:UpdatePanel ID="UpDatos" runat="server" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
<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">
|
||||
<Columns>
|
||||
<asp:TemplateField HeaderText="Puesto" ItemStyle-HorizontalAlign ="Left">
|
||||
@@ -50,6 +50,11 @@
|
||||
<ItemTemplate>
|
||||
<asp:Literal ID="LtlOcupacion" runat="server" Text='<%# Eval("Ocupacion") %>'></asp:Literal>
|
||||
</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 HeaderText="Fecha" ItemStyle-HorizontalAlign ="Center" ItemStyle-Width="80">
|
||||
<ItemTemplate>
|
||||
@@ -129,6 +134,13 @@
|
||||
<label for="<%= DdlArea.ClientID.ToString()%>">Ocupacion:</label>
|
||||
</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">
|
||||
<asp:CheckBox Text="Activo" runat="server" ID="ChkEstatusPuesto" Checked="true" Visible="true" />
|
||||
</div>
|
||||
|
||||
@@ -64,9 +64,6 @@ Partial Class RH_CatPuesto
|
||||
End Set
|
||||
End Property
|
||||
|
||||
|
||||
|
||||
|
||||
Private Property DTArea As DataTable
|
||||
Get
|
||||
If ViewState("DTArea") Is Nothing Then
|
||||
@@ -134,17 +131,18 @@ Partial Class RH_CatPuesto
|
||||
|
||||
CargaCatalogoOcupaciones()
|
||||
|
||||
|
||||
If ObjPuestos.GetPuestos(UsuarioActual.CveEmpresa) Then
|
||||
GvPuestos.DataSource = ObjPuestos.DtResultados.FiltraParametros("CveEmpresa = " & UsuarioActual.CveEmpresa)
|
||||
|
||||
GlobalDTRHPuestos(UsuarioActual.CveEmpresa) = ObjPuestos.DtResultados
|
||||
GvPuestos.DataSource = ObjPuestos.DtResultados
|
||||
Else
|
||||
Me.GvPuestos.DataSource = Nothing
|
||||
End If
|
||||
|
||||
ObjPuestos.Dispose()
|
||||
GvPuestos.DataBind()
|
||||
If UsuarioActual.CveEmpresa = 153 Then
|
||||
GvPuestos.Columns(3).Visible = True
|
||||
divValorxhora.Visible = True
|
||||
End If
|
||||
UpDatos.Update()
|
||||
|
||||
End Sub
|
||||
@@ -294,8 +292,6 @@ Partial Class RH_CatPuesto
|
||||
|
||||
End If
|
||||
|
||||
|
||||
|
||||
UpModalPuesto.Update()
|
||||
|
||||
End Sub
|
||||
@@ -343,13 +339,13 @@ Partial Class RH_CatPuesto
|
||||
End If
|
||||
|
||||
If CvePuesto = -1 And Actualizar = False Then
|
||||
If ObjPuestos.AddPuesto(TxtPuesto.Text.Trim, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, DdlOcupacion.SelectedValue.ToEntero) Then
|
||||
If ObjPuestos.GetPuestos(UsuarioActual.CveEmpresa) Then Application("GlobalDTRHPuestos") = ObjPuestos.DtResultados Else Application("GlobalDTRHPuestos") = Nothing
|
||||
If ObjPuestos.AddPuesto(TxtPuesto.Text.Trim, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, DdlOcupacion.SelectedValue.ToEntero, TxtValorXHora.text.todecimal) Then
|
||||
GlobalDTRHPuestos(UsuarioActual.CveEmpresa) = Nothing
|
||||
Alert("Puesto agregado correctamente.")
|
||||
End If
|
||||
Else
|
||||
If ObjPuestos.UpdatePuesto(CvePuesto, TxtPuesto.Text.Trim, estatus, UsuarioActual.CveUsuario, DdlOcupacion.SelectedValue.ToEntero) Then
|
||||
If ObjPuestos.GetPuestos(UsuarioActual.CveEmpresa) Then Application("GlobalDTRHPuestos") = ObjPuestos.DtResultados Else Application("GlobalDTRHPuestos") = Nothing
|
||||
If ObjPuestos.UpdatePuesto(CvePuesto, TxtPuesto.Text.Trim, estatus, UsuarioActual.CveUsuario, DdlOcupacion.SelectedValue.ToEntero, TxtValorXHora.Text.ToDecimal) Then
|
||||
GlobalDTRHPuestos(UsuarioActual.CveEmpresa) = Nothing
|
||||
Alert("Puesto actualizado correctamente.")
|
||||
End If
|
||||
End If
|
||||
@@ -388,6 +384,7 @@ Partial Class RH_CatPuesto
|
||||
|
||||
CvePuesto = GvRow.DataKey("CvePuesto").ToEntero
|
||||
TxtPuesto.Text = GvRow.DataKey("Puesto")
|
||||
TxtValorXHora.Text = GvRow.DataKey("ValorXHora").ToString
|
||||
LtlTituloModalPuesto.Text = "Editar Puesto"
|
||||
|
||||
If Boolean.Parse(GvRow.DataKey("Estatus")) Then
|
||||
|
||||
Reference in New Issue
Block a user