--
This commit is contained in:
@@ -3020,7 +3020,7 @@ Public Class ClsNominas
|
||||
Return retorno
|
||||
End Function
|
||||
|
||||
Public Function PrimaRiesgoUP(CveEmpresa As Integer, Fecha As DateTime, PrimadeRiesgo As Decimal) As Boolean
|
||||
Public Function PrimaRiesgoUP(CveEmpresa As Integer, Fecha As DateTime, PrimadeRiesgo As Decimal, CveRegistroPatronal As Integer) As Boolean
|
||||
Dim retorno As Boolean = False
|
||||
Try
|
||||
DTSet = New DataSet()
|
||||
@@ -3029,6 +3029,7 @@ Public Class ClsNominas
|
||||
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
||||
.Add("@Fecha", SqlDbType.Date).Value = Fecha
|
||||
.Add("@PrimadeRiesgo", SqlDbType.Money).Value = PrimadeRiesgo
|
||||
.Add("@CveRegistroPatronal", SqlDbType.Money).Value = CveRegistroPatronal
|
||||
End With
|
||||
SqlAdapter.Fill(DTSet)
|
||||
retorno = True
|
||||
|
||||
@@ -2615,7 +2615,7 @@
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Asignar a cuenta ">
|
||||
<ItemTemplate>
|
||||
<asp:DropDownList ID="Ddlcuentassd" runat="server" Width="100%"AppendDataBoundItems="True" DataTextField="CtaCodigo" DataValueField="CveCuenta" Class="form-control hidden input-sm select2me" ></asp:DropDownList>
|
||||
<asp:DropDownList ID="Ddlcuentassd" runat="server" Width="100%" AppendDataBoundItems="True" DataTextField="CtaCodigo" DataValueField="CveCuenta" Class="form-control hidden input-sm select2me" ></asp:DropDownList>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
</Columns>
|
||||
@@ -3191,6 +3191,14 @@
|
||||
<asp:LinkButton ID="ImgFechaBaja" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
|
||||
</span>
|
||||
<ajax:ValidatorCalloutExtender ID="vcoTxtFechaPRT" runat="server" HighlightCssClass="vco" TargetControlID="RfvTxtFechaPRT" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
|
||||
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<asp:Label runat="server" AssociatedControlID="DdlRegistroPatronalPR" Text="Registro Patronal:" ></asp:Label>
|
||||
<div >
|
||||
<asp:DropDownList ID="DdlRegistroPatronalPR" runat="server" Width="100%" DataTextField="RegistroPatronal" CssClass="form-control input-sm select2me" DataValueField="CveRegistroPatronal" ></asp:DropDownList>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<asp:LinkButton ID="LnkupPrimaRiesgo" OnClick="LnkupPrimaRiesgo_Click" CssClass="btn btn-primary" ValidationGroup="GrpGuardarprimariesgo" runat="server">Actualizar</asp:LinkButton>
|
||||
@@ -3223,6 +3231,11 @@
|
||||
<asp:Label ID="lblRiesgodeTrabajo" runat="server" Text='<%# Eval("Riesgo de trabajo","{0:N2}")%>'> </asp:Label>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Registro Patronal" ItemStyle-HorizontalAlign="right">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="lblRegistroPatronal" runat="server" Text='<%# Eval("Registro Patronal","{0:N2}")%>'> </asp:Label>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
</Columns>
|
||||
</asp:GridView>
|
||||
</div>
|
||||
|
||||
@@ -463,8 +463,10 @@ public partial class Nomina_Nomina2 : ClsPaginas
|
||||
{
|
||||
DdlRegistroPatronal.DataSource = onom.DtResultados;
|
||||
DdlRegistroPatronal.DataBind();
|
||||
DdlRegistroPatronalPR.DataSource = onom.DtResultados;
|
||||
DdlRegistroPatronalPR.DataBind();
|
||||
}
|
||||
}
|
||||
}
|
||||
if (dtperinc != null)
|
||||
{
|
||||
DdlSRINCcveTipodeIncidencia.DataSource = dtperinc.FiltraParametros("Tipo = -1 OR Tipo =1 ");
|
||||
@@ -9839,16 +9841,22 @@ public partial class Nomina_Nomina2 : ClsPaginas
|
||||
|
||||
protected void LnkupPrimaRiesgo_Click(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
int CveRegistroPatronal = DdlRegistroPatronalPR.SelectedValue.ToEntero();
|
||||
if (CveRegistroPatronal > 0)
|
||||
{
|
||||
|
||||
using (ClsNominas objnom = new ClsNominas())
|
||||
{
|
||||
if (objnom.PrimaRiesgoUP(UsuarioActual.CveEmpresa, TxtFechaPRT.Text.ToDateTime(), TxtPrimaRiesgo.Text.ToDecimal()))
|
||||
if (objnom.PrimaRiesgoUP(UsuarioActual.CveEmpresa, TxtFechaPRT.Text.ToDateTime(), TxtPrimaRiesgo.Text.ToDecimal(), CveRegistroPatronal))
|
||||
{
|
||||
}
|
||||
|
||||
}
|
||||
loadtablas();
|
||||
}
|
||||
else
|
||||
{
|
||||
Alert("Favor de seleccionar un registro patronal", TipoMensaje.MsgAdvertencia);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user