This commit is contained in:
@@ -812,7 +812,7 @@ Public Class ClsNominas
|
||||
|
||||
Public Function AddConcepto(Codigo As String, Concepto As String, Tipo As String, Formula As String, Sistema As Boolean, Estado As Boolean, CveConceptoPadre As Integer, CveUsuario As Integer, CveEmpresa As Integer,
|
||||
EsRetencion As Boolean, CveClasificacion As Integer, IdCtaContable As Integer, CveTipoGasto As Integer, TipoCalculo As Boolean, CveConceptoContable As Integer,
|
||||
AplicaFiniquito As Integer, AutomaticoGlobal As Integer, Especie As Integer, Imprimir As Integer) As Integer
|
||||
AplicaFiniquito As Integer, AutomaticoGlobal As Integer, Especie As Integer, Imprimir As Integer, CveSATConcepto As Integer) As Integer
|
||||
Dim Retorno As Integer = -1
|
||||
|
||||
DataAdapter("PA_Nom_ConceptosAdd")
|
||||
@@ -838,6 +838,7 @@ Public Class ClsNominas
|
||||
.Add("AutomaticoGlobal", SqlDbType.Bit).Value = AutomaticoGlobal
|
||||
.Add("Especie", SqlDbType.Bit).Value = Especie
|
||||
.Add("Imprimir", SqlDbType.Bit).Value = Imprimir
|
||||
.Add("CveSATConcepto", SqlDbType.Int).Value = CveSATConcepto
|
||||
End With
|
||||
|
||||
Try
|
||||
@@ -858,7 +859,7 @@ Public Class ClsNominas
|
||||
|
||||
Public Function UpdateConcepto(Codigo As String, Concepto As String, Tipo As String, Formula As String, Sistema As Boolean, Estado As Boolean, CveConceptoPadre As Integer, CveConcepto As Integer,
|
||||
EsRetencion As Boolean, CveClasificacion As Integer, IdCtaContable As Integer, CveTipoGasto As Integer, TipoCalculo As Boolean, CveConceptoContable As Integer,
|
||||
AplicaFiniquito As Integer, AutomaticoGlobal As Integer, Especie As Integer, Imprimir As Integer) As Boolean
|
||||
AplicaFiniquito As Integer, AutomaticoGlobal As Integer, Especie As Integer, Imprimir As Integer, CveSATConcepto As Integer) As Boolean
|
||||
Dim Retorno As Boolean = False
|
||||
|
||||
DataAdapter("PA_Nom_ConceptosUpdate")
|
||||
@@ -882,6 +883,7 @@ Public Class ClsNominas
|
||||
.Add("AutomaticoGlobal", SqlDbType.Bit).Value = AutomaticoGlobal
|
||||
.Add("Especie", SqlDbType.Bit).Value = Especie
|
||||
.Add("Imprimir", SqlDbType.Bit).Value = Imprimir
|
||||
.Add("CveSATConcepto", SqlDbType.Int).Value = CveSATConcepto
|
||||
End With
|
||||
|
||||
Try
|
||||
@@ -1859,14 +1861,35 @@ Public Class ClsNominas
|
||||
retorno = True
|
||||
Catch sqEx As SqlException
|
||||
retorno = False
|
||||
OnError("Ocurrió un error al Realizar el calculo de utilidades.", sqEx, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
|
||||
OnError("Ocurrió un error al Realizar el calculo de nomina.", sqEx, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
|
||||
Catch ex As Exception
|
||||
retorno = False
|
||||
OnError("Ocurrió un error al Realizar el calculo de utilidades.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
|
||||
OnError("Ocurrió un error al Realizar el calculo de nomina.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
|
||||
End Try
|
||||
Return retorno
|
||||
End Function
|
||||
|
||||
Public Function GetTablasNomina(CveEmpresa As Integer) As Boolean
|
||||
Dim retorno As Boolean = False
|
||||
Try
|
||||
DTSet = New DataSet()
|
||||
DataAdapter("PA_Nom_Tablas", CommandType.StoredProcedure)
|
||||
With SqlAdapter.SelectCommand.Parameters
|
||||
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
||||
End With
|
||||
|
||||
|
||||
SqlAdapter.Fill(DTSet)
|
||||
retorno = True
|
||||
Catch sqEx As SqlException
|
||||
retorno = False
|
||||
OnError("Ocurrió un error al obtener las tablas.", sqEx, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
|
||||
Catch ex As Exception
|
||||
retorno = False
|
||||
OnError("Ocurrió un error al obtener las tablas.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
|
||||
End Try
|
||||
Return retorno
|
||||
End Function
|
||||
#Region "IDisposable Support"
|
||||
' IDisposable
|
||||
Protected Overridable Sub Dispose(ByVal disposing As Boolean)
|
||||
|
||||
36
App_Code/DSNominas.xsd
Normal file
36
App_Code/DSNominas.xsd
Normal file
@@ -0,0 +1,36 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<xs:schema id="DSNominas" targetNamespace="http://tempuri.org/DSNominas.xsd" xmlns:mstns="http://tempuri.org/DSNominas.xsd" xmlns="http://tempuri.org/DSNominas.xsd" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata" xmlns:msprop="urn:schemas-microsoft-com:xml-msprop" attributeFormDefault="qualified" elementFormDefault="qualified">
|
||||
<xs:annotation>
|
||||
<xs:appinfo source="urn:schemas-microsoft-com:xml-msdatasource">
|
||||
<DataSource DefaultConnectionIndex="0" FunctionsComponentName="QueriesTableAdapter" Modifier="AutoLayout, AnsiClass, Class, Public" SchemaSerializationMode="IncludeSchema" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
|
||||
<Connections />
|
||||
<Tables />
|
||||
<Sources />
|
||||
</DataSource>
|
||||
</xs:appinfo>
|
||||
</xs:annotation>
|
||||
<xs:element name="DSNominas" msdata:IsDataSet="true" msdata:UseCurrentLocale="true" msprop:Generator_DataSetName="DSNominas" msprop:Generator_UserDSName="DSNominas">
|
||||
<xs:complexType>
|
||||
<xs:choice minOccurs="0" maxOccurs="unbounded">
|
||||
<xs:element name="DtConcepto" msprop:Generator_TableClassName="DtConceptoDataTable" msprop:Generator_TableVarName="tableDtConcepto" msprop:Generator_RowChangedName="DtConceptoRowChanged" msprop:Generator_TablePropName="DtConcepto" msprop:Generator_RowDeletingName="DtConceptoRowDeleting" msprop:Generator_RowChangingName="DtConceptoRowChanging" msprop:Generator_RowEvHandlerName="DtConceptoRowChangeEventHandler" msprop:Generator_RowDeletedName="DtConceptoRowDeleted" msprop:Generator_RowClassName="DtConceptoRow" msprop:Generator_UserTableName="DtConcepto" msprop:Generator_RowEvArgName="DtConceptoRowChangeEvent">
|
||||
<xs:complexType>
|
||||
<xs:sequence>
|
||||
<xs:element name="ConceptoP" msprop:Generator_ColumnVarNameInTable="columnConceptoP" msprop:Generator_ColumnPropNameInRow="ConceptoP" msprop:Generator_ColumnPropNameInTable="ConceptoPColumn" msprop:Generator_UserColumnName="ConceptoP" type="xs:string" minOccurs="0" />
|
||||
<xs:element name="LabelValorP" msprop:Generator_ColumnVarNameInTable="columnLabelValorP" msprop:Generator_ColumnPropNameInRow="LabelValorP" msprop:Generator_ColumnPropNameInTable="LabelValorPColumn" msprop:Generator_UserColumnName="LabelValorP" type="xs:string" minOccurs="0" />
|
||||
<xs:element name="CveConceptoP" msprop:Generator_ColumnVarNameInTable="columnCveConceptoP" msprop:Generator_ColumnPropNameInRow="CveConceptoP" msprop:Generator_ColumnPropNameInTable="CveConceptoPColumn" msprop:Generator_UserColumnName="CveConceptoP" type="xs:int" minOccurs="0" />
|
||||
<xs:element name="ImporteP" msprop:Generator_ColumnVarNameInTable="columnImporteP" msprop:Generator_ColumnPropNameInRow="ImporteP" msprop:Generator_ColumnPropNameInTable="ImportePColumn" msprop:Generator_UserColumnName="ImporteP" type="xs:double" minOccurs="0" />
|
||||
<xs:element name="ValorP" msprop:Generator_ColumnVarNameInTable="columnValorP" msprop:Generator_ColumnPropNameInRow="ValorP" msprop:Generator_ColumnPropNameInTable="ValorPColumn" msprop:Generator_UserColumnName="ValorP" type="xs:double" minOccurs="0" />
|
||||
<xs:element name="EstatusP" msprop:Generator_ColumnVarNameInTable="columnEstatusP" msprop:Generator_ColumnPropNameInRow="EstatusP" msprop:Generator_ColumnPropNameInTable="EstatusPColumn" msprop:Generator_UserColumnName="EstatusP" type="xs:int" minOccurs="0" />
|
||||
<xs:element name="ConceptoD" msprop:Generator_ColumnVarNameInTable="columnConceptoD" msprop:Generator_ColumnPropNameInRow="ConceptoD" msprop:Generator_ColumnPropNameInTable="ConceptoDColumn" msprop:Generator_UserColumnName="ConceptoD" type="xs:string" minOccurs="0" />
|
||||
<xs:element name="LabelValorD" msprop:Generator_ColumnVarNameInTable="columnLabelValorD" msprop:Generator_ColumnPropNameInRow="LabelValorD" msprop:Generator_ColumnPropNameInTable="LabelValorDColumn" msprop:Generator_UserColumnName="LabelValorD" type="xs:string" minOccurs="0" />
|
||||
<xs:element name="CveConceptoD" msprop:Generator_ColumnVarNameInTable="columnCveConceptoD" msprop:Generator_ColumnPropNameInRow="CveConceptoD" msprop:Generator_ColumnPropNameInTable="CveConceptoDColumn" msprop:Generator_UserColumnName="CveConceptoD" type="xs:int" minOccurs="0" />
|
||||
<xs:element name="ImporteD" msprop:Generator_ColumnVarNameInTable="columnImporteD" msprop:Generator_ColumnPropNameInRow="ImporteD" msprop:Generator_ColumnPropNameInTable="ImporteDColumn" msprop:Generator_UserColumnName="ImporteD" type="xs:double" minOccurs="0" />
|
||||
<xs:element name="ValorD" msprop:Generator_ColumnVarNameInTable="columnValorD" msprop:Generator_ColumnPropNameInRow="ValorD" msprop:Generator_ColumnPropNameInTable="ValorDColumn" msprop:Generator_UserColumnName="ValorD" type="xs:double" minOccurs="0" />
|
||||
<xs:element name="EstatusD" msprop:Generator_ColumnVarNameInTable="columnEstatusD" msprop:Generator_ColumnPropNameInRow="EstatusD" msprop:Generator_ColumnPropNameInTable="EstatusDColumn" msprop:Generator_UserColumnName="EstatusD" type="xs:int" minOccurs="0" />
|
||||
</xs:sequence>
|
||||
</xs:complexType>
|
||||
</xs:element>
|
||||
</xs:choice>
|
||||
</xs:complexType>
|
||||
</xs:element>
|
||||
</xs:schema>
|
||||
12
App_Code/DSNominas.xss
Normal file
12
App_Code/DSNominas.xss
Normal file
@@ -0,0 +1,12 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--<autogenerated>
|
||||
This code was generated by a tool to store the dataset designer's layout information.
|
||||
Changes to this file may cause incorrect behavior and will be lost if
|
||||
the code is regenerated.
|
||||
</autogenerated>-->
|
||||
<DiagramLayout xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" ex:showrelationlabel="False" ViewPortX="0" ViewPortY="0" xmlns:ex="urn:schemas-microsoft-com:xml-msdatasource-layout-extended" xmlns="urn:schemas-microsoft-com:xml-msdatasource-layout">
|
||||
<Shapes>
|
||||
<Shape ID="DesignTable:DtConcepto" ZOrder="1" X="355" Y="165" Height="257" Width="150" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="253" />
|
||||
</Shapes>
|
||||
<Connectors />
|
||||
</DiagramLayout>
|
||||
@@ -72,9 +72,18 @@ Namespace Extensiones
|
||||
Public Sub GuardaLog(Str As String)
|
||||
Dim ArchivoW As StreamWriter
|
||||
Dim strLineaTMP As String
|
||||
Dim Urlstring As String = ""
|
||||
Try
|
||||
If Not IsNothing(System.Web.HttpContext.Current) Then
|
||||
If Not IsNothing(System.Web.HttpContext.Current.Request) Then
|
||||
|
||||
Urlstring = $"{HttpContext.Current.Request.Url.LocalPath.ToString()}{HttpContext.Current.Request.Url.Query}{Environment.NewLine}"
|
||||
End If
|
||||
End If
|
||||
Catch
|
||||
End Try
|
||||
' strLineaTMP = Chr(13) & Chr(10) & Day(Now) & "/" & Month(Now) & "/" & Year(Now) & " " & Hour(Now) & ":" & Minuto & ". " & Str & Chr(13) & Chr(10)
|
||||
strLineaTMP = String.Format("{0}{1}Log: {2}{3}:{4}", Chr(13), Chr(10), Str, DateTime.Now.ToShortDateString, DateTime.Now.ToShortTimeString)
|
||||
strLineaTMP = String.Format("{0}{1}Log: {5}{2}{3}:{4}", Chr(13), Chr(10), Str, DateTime.Now.ToShortDateString, DateTime.Now.ToShortTimeString, Urlstring)
|
||||
Try
|
||||
ArchivoW = New StreamWriter(String.Format("{0}\Log.txt", AppDomain.CurrentDomain.BaseDirectory), True, System.Text.Encoding.UTF8)
|
||||
Catch ex As UnauthorizedAccessException
|
||||
|
||||
@@ -190,7 +190,7 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div id="Div3" runat="server" class="form-group form-md-line-input form-md-floating-label input-iconright">
|
||||
<div class="form-group form-md-line-input form-md-floating-label input-iconright">
|
||||
<asp:Label runat="server" Text="Tipo de gasto" AssociatedControlID="DdlTipoGasto"></asp:Label>
|
||||
<asp:DropDownList ID="DdlTipoGasto" runat="server" AppendDataBoundItems="True" DataTextField="TipoGasto" DataValueField="CveTipoGasto" Class="form-control input-sm select2me" Width="100%" ValidationGroup="GrpGuardar"></asp:DropDownList>
|
||||
</div>
|
||||
@@ -199,12 +199,16 @@
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div id="Div4" runat="server" class="form-group form-md-line-input form-md-floating-label input-iconright">
|
||||
<div class="form-group form-md-line-input form-md-floating-label input-iconright">
|
||||
<asp:Label runat="server" Text="Cuenta contable" AssociatedControlID="DdlCtaContable"></asp:Label>
|
||||
<asp:DropDownList ID="DdlCtaContable" runat="server" AppendDataBoundItems="True" DataTextField="CtaCodigo" DataValueField="Id" Class="form-control input-sm select2me" Width="100%" ValidationGroup="GrpGuardar"></asp:DropDownList>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group form-md-line-input form-md-floating-label input-iconright">
|
||||
<asp:Label runat="server" Text="Concepto SAT" AssociatedControlID="DdlConceptoSAT"></asp:Label>
|
||||
<asp:DropDownList ID="DdlConceptoSAT" runat="server" AppendDataBoundItems="True" DataTextField="NombreClave" DataValueField="CveSATConcepto" Class="form-control input-sm select2me" Width="100%" ValidationGroup="GrpGuardar"></asp:DropDownList>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -324,7 +328,7 @@
|
||||
<asp:Label runat="server" Text="Estado" AssociatedControlID="ChkEstado"></asp:Label>
|
||||
</div>
|
||||
<div class="col-xs-6">
|
||||
<asp:CheckBox ID="ChkEstado" Text=" " CssClass="chksino" runat="server" />
|
||||
<asp:CheckBox ID="ChkEstado" Text=" " Checked="true" CssClass="chksino" runat="server" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -199,7 +199,7 @@ public partial class Nomina_CatConcepto : ClsPaginas
|
||||
CargaClasificacion();
|
||||
CargaTipoGasto();
|
||||
CargaCtaContable();
|
||||
|
||||
CargaConceptoSAT();
|
||||
CargaDatos();
|
||||
}
|
||||
|
||||
@@ -241,6 +241,18 @@ public partial class Nomina_CatConcepto : ClsPaginas
|
||||
DdlTipoGasto.Items.Insert(0, new ListItem("Seleccione", "-1"));
|
||||
DdlTipoGasto.SelectedValueExist("-1");
|
||||
}
|
||||
protected void CargaConceptoSAT()
|
||||
{
|
||||
using (ClsNominas objnom = new ClsNominas())
|
||||
{
|
||||
objnom.GetConceptos();
|
||||
DdlConceptoSAT.DataSource = objnom.DtResultados;
|
||||
|
||||
}
|
||||
DdlConceptoSAT.DataBind();
|
||||
DdlConceptoSAT.Items.Insert(0, new ListItem("Seleccione", "-1"));
|
||||
DdlConceptoSAT.SelectedValueExist("-1");
|
||||
}
|
||||
|
||||
protected void CargaCtaContable()
|
||||
{
|
||||
@@ -298,6 +310,7 @@ public partial class Nomina_CatConcepto : ClsPaginas
|
||||
int AutomaticoGlobal = ChkAutomaticoGlobal.Checked ? 1 : 0;
|
||||
int Especie = ChkEspecie.Checked ? 1 : 0;
|
||||
int Imprimir = ChkImprimir.Checked ? 1 : 0;
|
||||
int CveSATConcepto = DdlConceptoSAT.SelectedValue.ToEntero();
|
||||
ClsNominas ObjNomina = new ClsNominas();
|
||||
ObjNomina.IniciaTransacSQL();
|
||||
|
||||
@@ -305,7 +318,7 @@ public partial class Nomina_CatConcepto : ClsPaginas
|
||||
|
||||
if (EsEditar)
|
||||
{
|
||||
TieneError = !ObjNomina.UpdateConcepto(codigo, concepto, tipo, formula, sistema, estado, CveConceptoPadre, CveConcepto, retencion, CveClasificacion, IdCtaContable, CveTipoGasto, tipoCalculo, CveConceptoContable, AplicaFiniquito, AutomaticoGlobal, Especie, Imprimir);
|
||||
TieneError = !ObjNomina.UpdateConcepto(codigo, concepto, tipo, formula, sistema, estado, CveConceptoPadre, CveConcepto, retencion, CveClasificacion, IdCtaContable, CveTipoGasto, tipoCalculo, CveConceptoContable, AplicaFiniquito, AutomaticoGlobal, Especie, Imprimir, CveSATConcepto);
|
||||
|
||||
if (TieneError)
|
||||
{
|
||||
@@ -319,7 +332,7 @@ public partial class Nomina_CatConcepto : ClsPaginas
|
||||
}
|
||||
else
|
||||
{
|
||||
CveConcepto = ObjNomina.AddConcepto(codigo, concepto, tipo, formula, sistema, estado, CveConceptoPadre, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, retencion, CveClasificacion, IdCtaContable, CveTipoGasto, tipoCalculo, CveConceptoContable, AplicaFiniquito, AutomaticoGlobal, Especie, Imprimir);
|
||||
CveConcepto = ObjNomina.AddConcepto(codigo, concepto, tipo, formula, sistema, estado, CveConceptoPadre, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, retencion, CveClasificacion, IdCtaContable, CveTipoGasto, tipoCalculo, CveConceptoContable, AplicaFiniquito, AutomaticoGlobal, Especie, Imprimir, CveSATConcepto);
|
||||
|
||||
if (CveConcepto == -1)
|
||||
{
|
||||
@@ -403,6 +416,7 @@ public partial class Nomina_CatConcepto : ClsPaginas
|
||||
DdlClasificacion.SelectedValueExist(drow["CveClasificacion"]);
|
||||
DdlTipoGasto.SelectedValueExist(drow["CveTipoGasto"]);
|
||||
DdlCtaContable.SelectedValueExist(drow["IdCtaContable"]);
|
||||
DdlConceptoSAT.SelectedValueExist(drow["CveSATConcepto"]);
|
||||
}
|
||||
ObjNomina.Dispose();
|
||||
|
||||
@@ -416,8 +430,8 @@ public partial class Nomina_CatConcepto : ClsPaginas
|
||||
ChkRetencion.Checked = false;
|
||||
DdlConceptoPadre.SelectedValueExist("-1");
|
||||
DdlConceptoContable.SelectedValueExist("-1");
|
||||
|
||||
ChkEstado.Checked = false;
|
||||
ChkImprimir.Checked = true;
|
||||
ChkEstado.Checked = true;
|
||||
ChkSistema.Checked = false;
|
||||
|
||||
DdlClasificacion.SelectedValueExist("-1");
|
||||
|
||||
@@ -8,6 +8,12 @@
|
||||
border: 1px solid #E87E04;
|
||||
}
|
||||
|
||||
.ddlInfolabel {
|
||||
font-size: 13px;
|
||||
color: #888888;
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
table.GvConceptos td {
|
||||
white-space: nowrap;
|
||||
}
|
||||
@@ -60,7 +66,11 @@
|
||||
<asp:UpdatePanel ID="UpAccciones" runat="server" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
<li>
|
||||
<asp:HyperLink ID="HypModalNomina" data-target="#DModalNominas" data-toggle="modal" runat="server">Cargar Nomina</asp:HyperLink></li>
|
||||
<asp:HyperLink ID="HypModalNomina" data-target="#DModalNominas" data-toggle="modal" runat="server">Cargar Nomina</asp:HyperLink>
|
||||
</li>
|
||||
<li>
|
||||
<asp:LinkButton ID="LnkVerTablas" OnClick="LnkVerTablas_Click" runat="server">Tablas</asp:LinkButton>
|
||||
</li>
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
</asp:Content>
|
||||
@@ -93,7 +103,9 @@
|
||||
</asp:DropDownList>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<asp:LinkButton ID="LnkConsultar" OnClick="LnkConsultar_Click" runat="server" Text="Mostrar" Visible="False" class="btn btn-primary" />
|
||||
<asp:LinkButton ID="LnkConsultar" OnClick="LnkConsultar_Click" runat="server" Text="Calcular" Visible="False" class="btn btn-primary" />
|
||||
<%--<asp:Label AssociatedControlID="chkesListaderaya" runat="server" Text="¿es lista de raya?"></asp:Label>--%>
|
||||
<%--<asp:CheckBox ID="chkesListaderaya" Text=" " data-checkbox=" icheckbox_minimal-blue blue " Checked="false" CssClass="icheck chekVal " runat="server" />--%>
|
||||
<asp:Button ID="BtnAutorizar" runat="server" Text="Autorizar" Visible="False" class="btn btn-primary" />
|
||||
<asp:Button ID="BtnGeneraPDF" runat="server" Text="PDF" Visible="False" class="btn btn-primary" />
|
||||
<asp:Button ID="BtnEmitir" runat="server" Text="Timbrar" Visible="False" class="btn btn-primary" />
|
||||
@@ -162,7 +174,7 @@
|
||||
<div class="portlet light xspadding bordered " id="pnldl">
|
||||
<div class="portlet-title">
|
||||
<div class="caption ">
|
||||
<i class="icon-pin font-yellow-gold"></i>
|
||||
<i class="fa fa-bookmark font-yellow-gold"></i>
|
||||
<span class="caption-subject font-yellow-gold bold uppercase">Nomina</span>
|
||||
</div>
|
||||
|
||||
@@ -533,6 +545,7 @@
|
||||
|
||||
|
||||
|
||||
<asp:Button ID="BtnImprimirsobrerecibo" OnClick="BtnImprimirsobrerecibo_Click" runat="server" Text="Imprimir" CssClass="btn btn-primary hidden" />
|
||||
<div id="ModalConceptos" class="modal ADS fade" role="dialog">
|
||||
|
||||
<asp:UpdatePanel class="modal-dialog modal-lg" runat="server" ID="UpModalConceptos" UpdateMode="Conditional">
|
||||
@@ -543,78 +556,260 @@
|
||||
<asp:Label ID="LblEmpleado" runat="server" Text="Label"></asp:Label></h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<div class="portlet light xspadding bordered " id="pnlConceptos">
|
||||
<div class="portlet-title">
|
||||
<div class="caption ">
|
||||
<i class="icon-pin font-yellow-gold"></i>
|
||||
<span class="caption-subject font-yellow-gold bold uppercase">Sobre Recibo</span>
|
||||
</div>
|
||||
<div class="portlet-body " style="padding: 0px;">
|
||||
|
||||
<asp:GridView ID="GvConceptos" runat="server" AutoGenerateColumns="False" CssClass="table table-striped table-hover Widthall GvConceptos"
|
||||
Style="text-align: center;" GridLines="None" OnRowDataBound="GvConceptos_RowDataBound"
|
||||
DataKeyNames="ConceptoP,CveConceptoP,ImporteP,ValorP,EstatusP,ConceptoD,CveConceptoD,ImporteD,EstatusD,ValorD">
|
||||
<Columns>
|
||||
<asp:TemplateField HeaderText="Concepto">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="LtlConcepto" runat="server" Text='<%# Eval("ConceptoP") %>' Style="word-break: break-all;"></asp:Label>
|
||||
<asp:LinkButton ID="LnkConcepto" OnClick="LnkConcepto_Click" runat="server" Text='<%# Eval("ConceptoP") %>'></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Left" Width="37%" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Valor">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="LtlValorP" runat="server" Text='<%# Eval("ValorP", "{0:##,###.##}") %>' Style="word-break: break-all;"></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Right" Width="13%" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Importe">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="LtlImporte" runat="server" Text='<%# Eval("ImporteP", "${0:N}") %>' Style="word-break: break-all;"></asp:Label>
|
||||
<asp:LinkButton ID="LnkImporte" OnClick="LnkConcepto_Click" runat="server" Text='<%# Eval("ImporteP", "${0:N}") %>'></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Right" Width="13%" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Concepto">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="LtlConceptoD" runat="server" Text='<%# Eval("ConceptoD") %>' Style="word-break: break-all;"></asp:Label>
|
||||
<asp:LinkButton ID="LnkConceptoD" OnClick="LnkConceptoD_Click" runat="server" Text='<%# Eval("ConceptoD") %>'></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Left" Width="37%" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Valor">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="LtlValorD" runat="server" Text='<%# Eval("ValorD", "{0:##,###.##}") %>' Style="word-break: break-all;"></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Right" Width="13%" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Importe">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="LtlImporteD" runat="server" Text='<%# Eval("ImporteD", "${0:N}") %>' Style="word-break: break-all;"></asp:Label>
|
||||
<asp:LinkButton ID="LnkImporteD" OnClick="LnkConceptoD_Click" runat="server" Text='<%# Eval("ImporteD", "${0:N}") %>'></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Right" Width="13%" />
|
||||
</asp:TemplateField>
|
||||
</Columns>
|
||||
<HeaderStyle CssClass="SearchADHeader" />
|
||||
</asp:GridView>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<asp:UpdatePanel runat="server" UpdateMode="Conditional">
|
||||
<ajax:TabContainer ID="TabPersonal" runat="server" Width="100%">
|
||||
<ajax:TabPanel ID="TabSobreRecivo" runat="server" HeaderText="Sobre Recibo">
|
||||
<ContentTemplate>
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">Cancelar</button>
|
||||
<div class="portlet light xspadding bordered " id="pnlConceptos">
|
||||
<div class="portlet-title">
|
||||
<div class="caption ">
|
||||
<i class="icon-pin font-yellow-gold"></i>
|
||||
<span class="caption-subject font-yellow-gold bold uppercase">Sobre Recibo</span>
|
||||
</div>
|
||||
|
||||
<div class="actions">
|
||||
<div class="btn-group">
|
||||
<a onclick="$('#C_BtnImprimirsobrerecibo').click()" class="btn btn-primary">Imprimir</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="portlet-body " style="padding: 0px;">
|
||||
|
||||
<asp:GridView ID="GvConceptos" runat="server" AutoGenerateColumns="False" CssClass="table table-striped table-hover Widthall GvConceptos"
|
||||
Style="text-align: center;" GridLines="None" OnRowDataBound="GvConceptos_RowDataBound"
|
||||
DataKeyNames="ConceptoP,CveConceptoP,ImporteP,ValorP,EstatusP,ConceptoD,CveConceptoD,ImporteD,EstatusD,ValorD">
|
||||
<Columns>
|
||||
<asp:TemplateField HeaderText="Concepto">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="LtlConcepto" runat="server" Text='<%# Eval("ConceptoP") %>' Style="word-break: break-all;"></asp:Label>
|
||||
<asp:LinkButton ID="LnkConcepto" OnClick="LnkConcepto_Click" runat="server" Text='<%# Eval("ConceptoP") %>'></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Left" Width="37%" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Valor">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="LtlValorP" runat="server" Text='<%# Eval("ValorP", "{0:##,###.##}") %>' Style="word-break: break-all;"></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Right" Width="13%" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Importe">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="LtlImporte" runat="server" Text='<%# Eval("ImporteP", "${0:N}") %>' Style="word-break: break-all;"></asp:Label>
|
||||
<asp:LinkButton ID="LnkImporte" OnClick="LnkConcepto_Click" runat="server" Text='<%# Eval("ImporteP", "${0:N}") %>'></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Right" Width="13%" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Concepto">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="LtlConceptoD" runat="server" Text='<%# Eval("ConceptoD") %>' Style="word-break: break-all;"></asp:Label>
|
||||
<asp:LinkButton ID="LnkConceptoD" OnClick="LnkConceptoD_Click" runat="server" Text='<%# Eval("ConceptoD") %>'></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Left" Width="37%" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Valor">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="LtlValorD" runat="server" Text='<%# Eval("ValorD", "{0:##,###.##}") %>' Style="word-break: break-all;"></asp:Label>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Right" Width="13%" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Importe">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="LtlImporteD" runat="server" Text='<%# Eval("ImporteD", "${0:N}") %>' Style="word-break: break-all;"></asp:Label>
|
||||
<asp:LinkButton ID="LnkImporteD" OnClick="LnkConceptoD_Click" runat="server" Text='<%# Eval("ImporteD", "${0:N}") %>'></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Right" Width="13%" />
|
||||
</asp:TemplateField>
|
||||
</Columns>
|
||||
<HeaderStyle CssClass="SearchADHeader" />
|
||||
</asp:GridView>
|
||||
</div>
|
||||
</div>
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
</div>
|
||||
</ajax:TabPanel>
|
||||
|
||||
<ajax:TabPanel ID="TabInfonavit" runat="server" HeaderText="Infonavit">
|
||||
<ContentTemplate>
|
||||
<div class="portlet light bordered xspadding" id="porletInfonavit">
|
||||
<div class="portlet-title">
|
||||
<div class="caption font-green">
|
||||
<i class="fa fa-home font-green"></i>
|
||||
<span class="caption-subject bold uppercase">Infonavit</span>
|
||||
</div>
|
||||
<div class="tools">
|
||||
<a href="javascript:;" class="collapse" data-original-title="" title=""></a>
|
||||
<a href="javascript:;" class="fullscreen" data-original-title="" title=""></a>
|
||||
</div>
|
||||
<div class="actions">
|
||||
<div class="btn-group">
|
||||
<asp:Button ID="BtnGuardarInfornavit" OnClick="BtnGuardarInfornavit_Click" runat="server" Text="Guardar" class="btn btn-primary" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="portlet-body form">
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:TextBox CssClass="form-control" ID="TxtInfoNumCredito" runat="server" MaxLength="20"></asp:TextBox>
|
||||
<asp:Label AssociatedControlID="TxtInfoNumCredito" runat="server" Text="Número de crédito"></asp:Label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:TextBox CssClass="form-control" ID="TxtInfoDescripcion" runat="server" MaxLength="20"></asp:TextBox>
|
||||
<asp:Label AssociatedControlID="TxtInfoDescripcion" runat="server" Text="Descripción"></asp:Label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="">
|
||||
<asp:Label AssociatedControlID="DdlInfoTipoAplicacion" CssClass="ddlInfolabel" runat="server" Text="Tipo Aplicación"></asp:Label>
|
||||
|
||||
<asp:DropDownList ID="DdlInfoTipoAplicacion" AutoPostBack="true" runat="server" Class="form-control select2me" Width="100%">
|
||||
<asp:ListItem Text="Seleccione" Value="-1"></asp:ListItem>
|
||||
<asp:ListItem Text="Infonavit(Movto Permanente)" Value="5000"></asp:ListItem>
|
||||
<asp:ListItem Text="Infonavit(Porcentaje)" Value="5001"></asp:ListItem>
|
||||
<asp:ListItem Text="Infonavit(Factor Descuento)" Value="5002"></asp:ListItem>
|
||||
<asp:ListItem Text="Infonavit(Cuota Fija)" Value="5003"></asp:ListItem>
|
||||
</asp:DropDownList>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:TextBox CssClass="form-control" ID="TxtInfoValor" runat="server" MaxLength="20"></asp:TextBox>
|
||||
<asp:Label AssociatedControlID="TxtInfoValor" runat="server" Text="Valor"></asp:Label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group form-md-line-input input-iconright " style="width: 120px !important; display: inline-block;">
|
||||
<asp:TextBox CssClass="form-control" ID="TxtInfoFechaInicio" runat="server" MaxLength="20"></asp:TextBox>
|
||||
<asp:Label AssociatedControlID="TxtInfoFechaInicio" runat="server" Text="Fecha Inicio"></asp:Label>
|
||||
<asp:RequiredFieldValidator runat="server" ID="REQFechaF" ControlToValidate="TxtInfoFechaInicio" ErrorMessage="Debe ingresar una fecha" ValidationGroup="vgEstFin" />
|
||||
<ajax:MaskedEditExtender ID="MaskedEditExtender4" runat="server" TargetControlID="TxtInfoFechaInicio" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
||||
<ajax:CalendarExtender runat="server" ID="CEEFechaF" TargetControlID="TxtInfoFechaInicio" PopupButtonID="ImgFechaFEstFin" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
||||
</div>
|
||||
<div style="display: inline-block; vertical-align: top; padding-top: 10px;">
|
||||
<span class="input-group-btn ">
|
||||
<asp:LinkButton ID="ImgFechaFEstFin" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<div class="">
|
||||
<asp:Label AssociatedControlID="ChkInfo" runat="server" Text="Estado (Activo)"></asp:Label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<asp:CheckBox ID="ChkInfo" CssClass="chksino" runat="server" Text=" " />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</ContentTemplate>
|
||||
</ajax:TabPanel>
|
||||
</ajax:TabContainer>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">Cancelar</button>
|
||||
</div>
|
||||
</div>
|
||||
</ContentTemplate>
|
||||
<Triggers>
|
||||
<%--<asp:PostBackTrigger ControlID="BtnImprimirsobrerecibo" />--%>
|
||||
</Triggers>
|
||||
</asp:UpdatePanel>
|
||||
</div>
|
||||
|
||||
<div id="ModalTablas" class="modal ADS fade" role="dialog">
|
||||
|
||||
<asp:UpdatePanel class="modal-dialog modal-lg" runat="server" ID="UpModalTablas" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
<div class="modal-content">
|
||||
<div class="modal-header ">
|
||||
<h4 class="modal-title">
|
||||
<asp:Label ID="Label1" runat="server" Text="Tablas"></asp:Label></h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
|
||||
<ajax:TabContainer ID="TabTablas" runat="server" Width="100%">
|
||||
<ajax:TabPanel ID="TTAntiguedad" runat="server" HeaderText="Antiguedad" Visible ="false">
|
||||
<ContentTemplate>
|
||||
<asp:GridView ID="gvAntigudad" runat="server" CssClass="table table-striped table-hover mysmallbtn Widthall GvNominas" GridLines="None"></asp:GridView>
|
||||
</ContentTemplate>
|
||||
</ajax:TabPanel>
|
||||
<ajax:TabPanel ID="TTFactorDesctInfonavit" runat="server" HeaderText="Factor descuento Infonavit">
|
||||
<ContentTemplate>
|
||||
<asp:GridView ID="GVFactorDesctInfonavit" runat="server" CssClass="table table-striped table-hover mysmallbtn Widthall GvNominas" GridLines="None"></asp:GridView>
|
||||
</ContentTemplate>
|
||||
</ajax:TabPanel>
|
||||
<ajax:TabPanel ID="TTFactorSDI" runat="server" HeaderText="Factor SD" Visible ="false">
|
||||
<ContentTemplate>
|
||||
<asp:GridView ID="GVFactorSDI" runat="server" CssClass="table table-striped table-hover mysmallbtn Widthall GvNominas" GridLines="None"></asp:GridView>
|
||||
</ContentTemplate>
|
||||
</ajax:TabPanel>
|
||||
|
||||
<ajax:TabPanel ID="TTFiniquito" runat="server" HeaderText="Finiquito" Visible ="false">
|
||||
<ContentTemplate>
|
||||
<asp:GridView ID="GVFiniquito" runat="server" CssClass="table table-striped table-hover mysmallbtn Widthall GvNominas" GridLines="None"></asp:GridView>
|
||||
</ContentTemplate>
|
||||
</ajax:TabPanel>
|
||||
<ajax:TabPanel ID="TTRepartoMonetario" runat="server" HeaderText="RepartoMonetario" Visible ="false">
|
||||
<ContentTemplate>
|
||||
<asp:GridView ID="GVRepartoMonetario" runat="server" CssClass="table table-striped table-hover mysmallbtn Widthall GvNominas" GridLines="None"></asp:GridView>
|
||||
</ContentTemplate>
|
||||
</ajax:TabPanel>
|
||||
<ajax:TabPanel ID="TTSalariosMinimos" runat="server" HeaderText="Salarios Minimos">
|
||||
<ContentTemplate>
|
||||
<asp:GridView ID="GVSalariosMinimos" runat="server" CssClass="table table-striped table-hover mysmallbtn Widthall GvNominas" GridLines="None"></asp:GridView>
|
||||
</ContentTemplate>
|
||||
</ajax:TabPanel>
|
||||
<ajax:TabPanel ID="TTIMMSRiesgot" runat="server" HeaderText="IMSS riesgo de trabajo">
|
||||
<ContentTemplate>
|
||||
<asp:GridView ID="GVIMMSRiesgot" runat="server" CssClass="table table-striped table-hover mysmallbtn Widthall GvNominas" GridLines="None"></asp:GridView>
|
||||
</ContentTemplate>
|
||||
</ajax:TabPanel>
|
||||
<ajax:TabPanel ID="TTInfonavitSegViv" runat="server" HeaderText="Infonavit seguro de vivienda">
|
||||
<ContentTemplate>
|
||||
<asp:GridView ID="GVInfonavitSegViv" runat="server" CssClass="table table-striped table-hover mysmallbtn Widthall GvNominas" GridLines="None"></asp:GridView>
|
||||
</ContentTemplate>
|
||||
</ajax:TabPanel>
|
||||
<ajax:TabPanel ID="TTVigISRAnual" runat="server" HeaderText="ISR Anual" Visible ="false">
|
||||
<ContentTemplate>
|
||||
<asp:GridView ID="GVVigISRAnual" runat="server" CssClass="table table-striped table-hover mysmallbtn Widthall GvNominas" GridLines="None"></asp:GridView>
|
||||
</ContentTemplate>
|
||||
</ajax:TabPanel>
|
||||
<ajax:TabPanel ID="TTVigISRMensual" runat="server" HeaderText="ISR Mensual">
|
||||
<ContentTemplate>
|
||||
<asp:GridView ID="GVVigISRMensual" runat="server" CssClass="table table-striped table-hover mysmallbtn Widthall GvNominas" GridLines="None"></asp:GridView>
|
||||
</ContentTemplate>
|
||||
</ajax:TabPanel>
|
||||
<ajax:TabPanel ID="TTVigSubEmpAnual" runat="server" HeaderText="Subsidio Anual" Visible ="false">
|
||||
<ContentTemplate>
|
||||
<asp:GridView ID="GVVigSubEmpAnual" runat="server" CssClass="table table-striped table-hover mysmallbtn Widthall GvNominas" GridLines="None"></asp:GridView>
|
||||
</ContentTemplate>
|
||||
</ajax:TabPanel>
|
||||
<ajax:TabPanel ID="TTVigSubEmpMensual" runat="server" HeaderText="Subsidio Mensual">
|
||||
<ContentTemplate>
|
||||
<asp:GridView ID="GVVigSubEmpMensual" runat="server" CssClass="table table-striped table-hover mysmallbtn Widthall GvNominas" GridLines="None"></asp:GridView>
|
||||
</ContentTemplate>
|
||||
</ajax:TabPanel>
|
||||
<ajax:TabPanel ID="TTUma" runat="server" HeaderText="UMA">
|
||||
<ContentTemplate>
|
||||
<asp:GridView ID="GVUma" runat="server" CssClass="table table-striped table-hover mysmallbtn Widthall GvNominas" GridLines="None"></asp:GridView>
|
||||
</ContentTemplate>
|
||||
</ajax:TabPanel>
|
||||
</ajax:TabContainer>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">Cancelar</button>
|
||||
</div>
|
||||
</div>
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div id="DModalNominas" class="modal ADS fade" role="dialog">
|
||||
<asp:UpdatePanel ID="UpCargarNomina" class="modal-dialog" tabindex="-1" runat="server" UpdateMode="Conditional">
|
||||
|
||||
@@ -328,7 +328,8 @@ public partial class Nomina_Nomina2 : ClsPaginas
|
||||
GvNominas.Columns[i].Visible = false;
|
||||
|
||||
}
|
||||
if (false)
|
||||
bool tr = false;
|
||||
if (tr)
|
||||
{
|
||||
bool sumaPercepciones = false;
|
||||
bool sumaDeducciones = false;
|
||||
@@ -734,7 +735,7 @@ public partial class Nomina_Nomina2 : ClsPaginas
|
||||
}
|
||||
using (ClsRH objpersonal = new ClsRH())
|
||||
{
|
||||
using (ClsNominas objNomina = new ClsNominas())
|
||||
using (ClsNominas objNomina = new ClsNominas(objpersonal.IniciaTransacSQL()))
|
||||
{
|
||||
foreach (DataRow row in DTEXcel.Rows)
|
||||
{
|
||||
@@ -799,6 +800,14 @@ public partial class Nomina_Nomina2 : ClsPaginas
|
||||
}
|
||||
}
|
||||
}
|
||||
if (rollback)
|
||||
{
|
||||
objpersonal.RollBack();
|
||||
}
|
||||
else
|
||||
{
|
||||
objpersonal.Commit();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -821,15 +830,172 @@ public partial class Nomina_Nomina2 : ClsPaginas
|
||||
|
||||
#region SobreRecibo
|
||||
|
||||
protected int SRCvePersonal
|
||||
{
|
||||
get
|
||||
{
|
||||
if (ViewState["SRCvePersonal"] == null) { return 0; }
|
||||
else { return ViewState["SRCvePersonal"].ToString().ToEntero(); }
|
||||
}
|
||||
|
||||
set { ViewState["SRCvePersonal"] = value; }
|
||||
}
|
||||
|
||||
protected int SRCvePeriodo
|
||||
{
|
||||
get
|
||||
{
|
||||
if (ViewState["SRCvePeriodo"] == null) { return 0; }
|
||||
else { return ViewState["SRCvePeriodo"].ToString().ToEntero(); }
|
||||
}
|
||||
|
||||
set { ViewState["SRCvePeriodo"] = value; }
|
||||
}
|
||||
protected void LnkSobreRecibo_Click(object sender, EventArgs e)
|
||||
{
|
||||
GridViewRow gvrow = (GridViewRow)(((LinkButton)sender).NamingContainer);
|
||||
|
||||
string Nombre = gvrow.DataKey("Nombre").ToString();
|
||||
int cvePersonal = gvrow.DataKey("CvePersonal").ToEntero();
|
||||
int CvePeriodo = gvrow.DataKey("CvePeriodo").ToEntero();
|
||||
SRCvePersonal = gvrow.DataKey("CvePersonal").ToEntero();
|
||||
SRCvePeriodo = gvrow.DataKey("CvePeriodo").ToEntero();
|
||||
int CveNomina = gvrow.DataKey("CveNomina").ToEntero();
|
||||
LblEmpleado.Text = Nombre;
|
||||
TabPersonal.ActiveTabIndex = 0;
|
||||
mostrarConceptos();
|
||||
RegistraScript("$('#ModalConceptos').modal();");
|
||||
}
|
||||
private void mostrarConceptos()
|
||||
{
|
||||
#region "Sobre Recibo"
|
||||
{
|
||||
DataTable dtper = dtConceptos.FiltraParametros("Tipo IN ('P') AND EsPadre = 1 ");
|
||||
DataTable dtded = dtConceptos.FiltraParametros("Tipo IN ('D') AND EsPadre = 1 ");
|
||||
dtper.Columns.Add("BorradoLogico", typeof(int));
|
||||
dtded.Columns.Add("BorradoLogico", typeof(int));
|
||||
|
||||
foreach (DataRow row in dtper.Rows)
|
||||
{
|
||||
int BorradoLogico = 0;
|
||||
int CveConcepto = row["CveConcepto"].ToString().ToEntero();
|
||||
if (!(dtempleados.SUM(string.Format("[V_{0}]", CveConcepto)) > 0))
|
||||
{
|
||||
BorradoLogico = 1;
|
||||
}
|
||||
row["BorradoLogico"] = BorradoLogico;
|
||||
}
|
||||
dtper.AcceptChanges();
|
||||
foreach (DataRow row in dtded.Rows)
|
||||
{
|
||||
int BorradoLogico = 0;
|
||||
int CveConcepto = row["CveConcepto"].ToString().ToEntero();
|
||||
if (!(dtempleados.SUM(string.Format("[V_{0}]", CveConcepto)) > 0))
|
||||
{
|
||||
BorradoLogico = 1;
|
||||
}
|
||||
row["BorradoLogico"] = BorradoLogico;
|
||||
}
|
||||
dtded.AcceptChanges();
|
||||
dtper = dtper.FiltraParametros("BorradoLogico=0");
|
||||
dtded = dtded.FiltraParametros("BorradoLogico=0");
|
||||
int maxper = dtper.Rows.Count;
|
||||
int maxded = dtded.Rows.Count;
|
||||
int i = 0;
|
||||
List<NConcepto> lconc = new List<NConcepto>();
|
||||
for (i = 0; i < maxper || i < maxded; i++)
|
||||
{
|
||||
NConcepto nConcepto = new NConcepto();
|
||||
DataRow row;
|
||||
if (maxper > i)
|
||||
{
|
||||
row = dtper.Rows[i];
|
||||
int CveConcepto = row["CveConcepto"].ToString().ToEntero();
|
||||
string Concepto = row["Concepto"].ToString();
|
||||
string Codigo = row["Codigo"].ToString();
|
||||
//bool visible = (dtempleados.SUM(string.Format("[V_{0}]", CveConcepto)) > 0);
|
||||
double Importe = dtempleados.SUM(string.Format("[V_{0}]", CveConcepto), string.Format("CvePersonal = {0}", SRCvePersonal));
|
||||
nConcepto.CveConceptoP = CveConcepto;
|
||||
nConcepto.ConceptoP = Concepto;
|
||||
nConcepto.NoConceptoP = Codigo;
|
||||
nConcepto.ImporteP = Importe;
|
||||
nConcepto.ValorP = dtempleados.SUM(string.Format("[VAL_{0}]", CveConcepto), string.Format("CvePersonal = {0}", SRCvePersonal));
|
||||
}
|
||||
if (maxded > i)
|
||||
{
|
||||
row = dtded.Rows[i];
|
||||
int CveConcepto = row["CveConcepto"].ToString().ToEntero();
|
||||
string Concepto = row["Concepto"].ToString();
|
||||
string Codigo = row["Codigo"].ToString();
|
||||
//bool visible = (dtempleados.SUM(string.Format("[V_{0}]", CveConcepto)) > 0);
|
||||
double Importe = dtempleados.SUM(string.Format("[V_{0}]", CveConcepto), string.Format("CvePersonal = {0}", SRCvePersonal));
|
||||
nConcepto.CveConceptoD = CveConcepto;
|
||||
nConcepto.ConceptoD = Concepto;
|
||||
nConcepto.NoConceptoD = Codigo;
|
||||
nConcepto.ImporteD = Importe;
|
||||
nConcepto.ValorD = dtempleados.SUM(string.Format("[VAL_{0}]", CveConcepto), string.Format("CvePersonal = {0}", SRCvePersonal));
|
||||
}
|
||||
lconc.Add(nConcepto);
|
||||
}
|
||||
|
||||
lconc.Add(new NConcepto());
|
||||
|
||||
NConcepto SubTotales = new NConcepto();
|
||||
SubTotales.CveConceptoP = 0;
|
||||
SubTotales.ConceptoP = "Total Percepciones";
|
||||
SubTotales.EstatusP = -2;
|
||||
SubTotales.ImporteP = dtempleados.SUM("SumaPercepciones", string.Format("CvePersonal = {0}", SRCvePersonal));
|
||||
///Alert(SubTotales.ImporteP.ToString());
|
||||
|
||||
SubTotales.CveConceptoD = 0;
|
||||
SubTotales.ConceptoD = "Total Deducciones";
|
||||
SubTotales.EstatusD = -2;
|
||||
SubTotales.ImporteD = dtempleados.SUM("SumaDeducciones", string.Format("CvePersonal = {0}", SRCvePersonal));
|
||||
|
||||
NConcepto Totales = new NConcepto();
|
||||
Totales.CveConceptoD = 0;
|
||||
Totales.ConceptoD = "Total";
|
||||
Totales.EstatusD = -3;
|
||||
Totales.ImporteD = dtempleados.SUM("Total", string.Format("CvePersonal = {0}", SRCvePersonal));
|
||||
|
||||
lconc.Add(SubTotales);
|
||||
lconc.Add(Totales);
|
||||
GvConceptos.DataSource = lconc;
|
||||
GvConceptos.DataBind();
|
||||
}
|
||||
#endregion
|
||||
#region "Infonavit"
|
||||
{
|
||||
using (ClsRH objper = new ClsRH())
|
||||
{
|
||||
objper.GetPersonalConceptos(SRCvePersonal, UsuarioActual.CveEmpresa);
|
||||
DataRow frow = objper.DtResultados.FiltroPrimero("CveSistema =3");
|
||||
TxtInfoValor.Text = "";
|
||||
DdlInfoTipoAplicacion.SelectedValueExist("-1");
|
||||
TxtInfoDescripcion.Text = "";
|
||||
TxtInfoNumCredito.Text = "";
|
||||
TxtInfoFechaInicio.Text = "";
|
||||
ChkInfo.Checked = false;
|
||||
if (frow != null)
|
||||
{
|
||||
|
||||
TxtInfoValor.Text = String.Format("{0:###,###.##}", frow["Importe"]);
|
||||
DdlInfoTipoAplicacion.SelectedValueExist(frow["TipoAplicacion"].ToString());
|
||||
|
||||
TxtInfoDescripcion.Text = String.Format("{0}", frow["Descripcion02"]);
|
||||
TxtInfoNumCredito.Text = String.Format("{0}", frow["Descripcion01"]);
|
||||
TxtInfoFechaInicio.Text = String.Format("{0:dd/MM/yyyy}", frow["FInicioAplicacion"]);
|
||||
ChkInfo.Checked = frow["estatus"].ToString().ToUpper().Contiene("1", "TRUE");
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
UpModalConceptos.Update();
|
||||
}
|
||||
|
||||
protected void BtnImprimirsobrerecibo_Click(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
DataTable dtper = dtConceptos.FiltraParametros("Tipo IN ('P') AND EsPadre = 1 ");
|
||||
DataTable dtded = dtConceptos.FiltraParametros("Tipo IN ('D') AND EsPadre = 1 ");
|
||||
dtper.Columns.Add("BorradoLogico", typeof(int));
|
||||
@@ -872,24 +1038,28 @@ public partial class Nomina_Nomina2 : ClsPaginas
|
||||
row = dtper.Rows[i];
|
||||
int CveConcepto = row["CveConcepto"].ToString().ToEntero();
|
||||
string Concepto = row["Concepto"].ToString();
|
||||
string Codigo = row["Codigo"].ToString();
|
||||
//bool visible = (dtempleados.SUM(string.Format("[V_{0}]", CveConcepto)) > 0);
|
||||
double Importe = dtempleados.SUM(string.Format("[V_{0}]", CveConcepto), string.Format("CvePersonal = {0}", cvePersonal));
|
||||
double Importe = dtempleados.SUM(string.Format("[V_{0}]", CveConcepto), string.Format("CvePersonal = {0}", SRCvePersonal));
|
||||
nConcepto.CveConceptoP = CveConcepto;
|
||||
nConcepto.ConceptoP = Concepto;
|
||||
nConcepto.NoConceptoP = Codigo;
|
||||
nConcepto.ImporteP = Importe;
|
||||
nConcepto.ValorP = dtempleados.SUM(string.Format("[VAL_{0}]", CveConcepto), string.Format("CvePersonal = {0}", cvePersonal));
|
||||
nConcepto.ValorP = dtempleados.SUM(string.Format("[VAL_{0}]", CveConcepto), string.Format("CvePersonal = {0}", SRCvePersonal));
|
||||
}
|
||||
if (maxded > i)
|
||||
{
|
||||
row = dtded.Rows[i];
|
||||
int CveConcepto = row["CveConcepto"].ToString().ToEntero();
|
||||
string Concepto = row["Concepto"].ToString();
|
||||
string Codigo = row["Codigo"].ToString();
|
||||
//bool visible = (dtempleados.SUM(string.Format("[V_{0}]", CveConcepto)) > 0);
|
||||
double Importe = dtempleados.SUM(string.Format("[V_{0}]", CveConcepto), string.Format("CvePersonal = {0}", cvePersonal));
|
||||
double Importe = dtempleados.SUM(string.Format("[V_{0}]", CveConcepto), string.Format("CvePersonal = {0}", SRCvePersonal));
|
||||
nConcepto.CveConceptoD = CveConcepto;
|
||||
nConcepto.ConceptoD = Concepto;
|
||||
nConcepto.NoConceptoD = Codigo;
|
||||
nConcepto.ImporteD = Importe;
|
||||
nConcepto.ValorD = dtempleados.SUM(string.Format("[VAL_{0}]", CveConcepto), string.Format("CvePersonal = {0}", cvePersonal));
|
||||
nConcepto.ValorD = dtempleados.SUM(string.Format("[VAL_{0}]", CveConcepto), string.Format("CvePersonal = {0}", SRCvePersonal));
|
||||
}
|
||||
lconc.Add(nConcepto);
|
||||
}
|
||||
@@ -900,55 +1070,116 @@ public partial class Nomina_Nomina2 : ClsPaginas
|
||||
SubTotales.CveConceptoP = 0;
|
||||
SubTotales.ConceptoP = "Total Percepciones";
|
||||
SubTotales.EstatusP = -2;
|
||||
SubTotales.ImporteP = dtempleados.SUM("SumaPercepciones", string.Format("CvePersonal = {0}", cvePersonal));
|
||||
SubTotales.ImporteP = dtempleados.SUM("SumaPercepciones", string.Format("CvePersonal = {0}", SRCvePersonal));
|
||||
///Alert(SubTotales.ImporteP.ToString());
|
||||
|
||||
SubTotales.CveConceptoD = 0;
|
||||
SubTotales.ConceptoD = "Total Deducciones";
|
||||
SubTotales.EstatusD = -2;
|
||||
SubTotales.ImporteD = dtempleados.SUM("SumaDeducciones", string.Format("CvePersonal = {0}", cvePersonal));
|
||||
SubTotales.ImporteD = dtempleados.SUM("SumaDeducciones", string.Format("CvePersonal = {0}", SRCvePersonal));
|
||||
|
||||
NConcepto Totales = new NConcepto();
|
||||
Totales.CveConceptoD = 0;
|
||||
Totales.ConceptoD = "Total";
|
||||
Totales.EstatusD = -3;
|
||||
Totales.ImporteD = dtempleados.SUM("Total", string.Format("CvePersonal = {0}", cvePersonal));
|
||||
Totales.ImporteD = dtempleados.SUM("Total", string.Format("CvePersonal = {0}", SRCvePersonal));
|
||||
|
||||
lconc.Add(SubTotales);
|
||||
lconc.Add(Totales);
|
||||
GvConceptos.DataSource = lconc;
|
||||
GvConceptos.DataBind();
|
||||
UpModalConceptos.Update();
|
||||
RegistraScript("$('#ModalConceptos').modal();");
|
||||
//if (true)
|
||||
//{
|
||||
// BoundField field = (BoundField)GvNominas.Columns[CurrentColumn];
|
||||
List<Microsoft.Reporting.WebForms.ReportDataSource> lrds = new List<Microsoft.Reporting.WebForms.ReportDataSource>();
|
||||
Microsoft.Reporting.WebForms.ReportDataSource rds = new Microsoft.Reporting.WebForms.ReportDataSource();
|
||||
rds.Name = "DataSet1";
|
||||
rds.Value = lconc;
|
||||
lrds.Add(rds);
|
||||
List<Microsoft.Reporting.WebForms.ReportParameter> parametros = new List<Microsoft.Reporting.WebForms.ReportParameter>();
|
||||
|
||||
// field.HeaderText = "Percepciones";
|
||||
// field.DataField = "SumaPercepciones";
|
||||
// field.ItemStyle.BackColor = System.Drawing.Color.LightGray;
|
||||
// GvNominas.Columns[CurrentColumn].Visible = true;
|
||||
// CurrentColumn++;
|
||||
//}
|
||||
string CodigoEmpleado = "";
|
||||
string NombreCompleto = "";
|
||||
string RFC = "";
|
||||
string CURP = "";
|
||||
string TipoPeriodo = "";
|
||||
string NSS = "";
|
||||
string DiasLaborados = "";
|
||||
string DiasFaltados = "";
|
||||
string DiasVacaciones = "";
|
||||
string FechaInicio = "";
|
||||
string FechaFin = "";
|
||||
string DiasRetardos = "";
|
||||
|
||||
//if (true)
|
||||
//{
|
||||
// BoundField field = (BoundField)GvNominas.Columns[CurrentColumn];
|
||||
// field.HeaderText = "Deducciones";
|
||||
// field.DataField = "SumaDeducciones";
|
||||
// field.ItemStyle.BackColor = System.Drawing.Color.LightGray;
|
||||
// GvNominas.Columns[CurrentColumn].Visible = true;
|
||||
// CurrentColumn++;
|
||||
{
|
||||
DataRow drow = dtempleados.FiltroPrimero(string.Format("CvePersonal = {0}", SRCvePersonal));
|
||||
if (drow != null)
|
||||
{
|
||||
DiasLaborados = string.Format("{0}", drow["DiasLaborados"].ToString().ToEntero());
|
||||
DiasFaltados = string.Format("{0}", drow["DiasFaltados"].ToString().ToEntero());
|
||||
DiasVacaciones = string.Format("{0}", drow["DiasVacaciones"].ToString().ToEntero());
|
||||
FechaInicio = string.Format("{0:dd/MM/yyyy}", drow["FechaInicio"]);
|
||||
FechaFin = string.Format("{0:dd/MM/yyyy}", drow["FechaFin"]);
|
||||
DiasRetardos = string.Format("{0}", drow["DiasRetardos"].ToString().ToEntero());
|
||||
}
|
||||
}
|
||||
//string Codigo = "";
|
||||
using (ClsRH objrh = new ClsRH())
|
||||
{
|
||||
if (objrh.GetPersonal(SRCvePersonal, UsuarioActual.CveEmpresa) && objrh.DtResultados.Rows.Count > 0)
|
||||
{
|
||||
DataRow drow = objrh.DtResultados.Rows[0];
|
||||
CodigoEmpleado = drow["Codigo"].ToString();
|
||||
NombreCompleto = drow["NombreCompleto"].ToString();
|
||||
RFC = drow["RFC"].ToString();
|
||||
CURP = drow["CURP"].ToString();
|
||||
TipoPeriodo = drow["TipoPeriodo"].ToString();
|
||||
NSS = drow["NSS"].ToString();
|
||||
}
|
||||
}
|
||||
parametros.Add(new Microsoft.Reporting.WebForms.ReportParameter("Codigo", CodigoEmpleado));
|
||||
parametros.Add(new Microsoft.Reporting.WebForms.ReportParameter("NombreCompleto", NombreCompleto));
|
||||
parametros.Add(new Microsoft.Reporting.WebForms.ReportParameter("RFC", RFC));
|
||||
parametros.Add(new Microsoft.Reporting.WebForms.ReportParameter("CURP", ""));
|
||||
parametros.Add(new Microsoft.Reporting.WebForms.ReportParameter("TipoPeriodo", TipoPeriodo));
|
||||
parametros.Add(new Microsoft.Reporting.WebForms.ReportParameter("NSS", NSS));
|
||||
parametros.Add(new Microsoft.Reporting.WebForms.ReportParameter("DiasLaborados", DiasLaborados));
|
||||
parametros.Add(new Microsoft.Reporting.WebForms.ReportParameter("DiasFaltados", DiasFaltados));
|
||||
parametros.Add(new Microsoft.Reporting.WebForms.ReportParameter("DiasVacaciones", DiasVacaciones));
|
||||
parametros.Add(new Microsoft.Reporting.WebForms.ReportParameter("FechaInicio", FechaInicio));
|
||||
parametros.Add(new Microsoft.Reporting.WebForms.ReportParameter("FechaFin", FechaFin));
|
||||
parametros.Add(new Microsoft.Reporting.WebForms.ReportParameter("DiasRetardos", DiasRetardos));
|
||||
parametros.Add(new Microsoft.Reporting.WebForms.ReportParameter("FechaPago", ""));
|
||||
//parametros.Add(new Microsoft.Reporting.WebForms.ReportParameter("", ""));
|
||||
//parametros.Add(new Microsoft.Reporting.WebForms.ReportParameter("", ""));
|
||||
//parametros.Add(new Microsoft.Reporting.WebForms.ReportParameter("", ""));
|
||||
//parametros.Add(new Microsoft.Reporting.WebForms.ReportParameter("", ""));
|
||||
//parametros.Add(new Microsoft.Reporting.WebForms.ReportParameter("", ""));
|
||||
|
||||
// field = (BoundField)GvNominas.Columns[CurrentColumn];
|
||||
// field.HeaderText = "Total";
|
||||
// field.DataField = "Total";
|
||||
// field.ItemStyle.BackColor = System.Drawing.Color.LightGray;
|
||||
// GvNominas.Columns[CurrentColumn].Visible = true;
|
||||
// CurrentColumn++;
|
||||
//}
|
||||
ImprimirPDF("D:/ADSistemas/Proyectos/SIG/WEB/Empresas/Grales/Formatos/SobreRecibo.rdlc", lrds, parametros, "SobreRecibo.pdf", "PDF", null);
|
||||
}
|
||||
protected void BtnGuardarInfornavit_Click(object sender, EventArgs e)
|
||||
{
|
||||
double importe = TxtInfoValor.Text.ToDouble();
|
||||
int TipoAplicacion = DdlInfoTipoAplicacion.SelectedValue.ToEntero();
|
||||
int NoPagos = 0;
|
||||
double SaldoIni = 0;
|
||||
string descripcion02 = TxtInfoDescripcion.Text;
|
||||
string descripcion01 = TxtInfoNumCredito.Text;
|
||||
string fecha = TxtInfoFechaInicio.Text.Replace("_", "");
|
||||
int estatus = ChkInfo.Checked ? 1 : 0;
|
||||
if (fecha.Length > 8)
|
||||
fecha = fecha.ToDateTime().ToString("yyyy/MM/dd");
|
||||
else
|
||||
fecha = "";
|
||||
bool continuar = true;
|
||||
using (ClsRH ObjPersonal = new ClsRH())
|
||||
{
|
||||
if (!ObjPersonal.AddConcepto(SRCvePersonal, -1, importe, TipoAplicacion, NoPagos, SaldoIni, UsuarioActual.CveUsuario, 3, descripcion01, descripcion02, fecha, "", estatus, UsuarioActual.CveEmpresa))
|
||||
continuar = false;
|
||||
}
|
||||
if (continuar)
|
||||
{
|
||||
LnkConsultar_Click(null, null);
|
||||
mostrarConceptos();
|
||||
Alert("Se actualizo el calculo de infonavit");
|
||||
}
|
||||
}
|
||||
|
||||
protected void LnkFormato_Click(object sender, EventArgs e)
|
||||
{
|
||||
try
|
||||
@@ -1033,14 +1264,18 @@ public partial class Nomina_Nomina2 : ClsPaginas
|
||||
}
|
||||
private class NConcepto
|
||||
{
|
||||
public string NoConceptoP { get; set; }
|
||||
public string ConceptoP { get; set; }
|
||||
public string LabelValorP { get; set; }
|
||||
public int CveConceptoP { get; set; }
|
||||
public double ImporteP { get; set; }
|
||||
public double ValorP { get; set; }
|
||||
public int EstatusP { get; set; }
|
||||
|
||||
|
||||
public string NoConceptoD { get; set; }
|
||||
public string ConceptoD { get; set; }
|
||||
public string LabelValorD { get; set; }
|
||||
public int CveConceptoD { get; set; }
|
||||
public double ImporteD { get; set; }
|
||||
public double ValorD { get; set; }
|
||||
@@ -1107,4 +1342,34 @@ public partial class Nomina_Nomina2 : ClsPaginas
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
|
||||
protected void LnkVerTablas_Click(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
using (ClsNominas objnom = new ClsNominas())
|
||||
{
|
||||
if (objnom.GetTablasNomina (UsuarioActual.CveEmpresa) && objnom.DTSetResultados.Tables.Count > 1)
|
||||
{
|
||||
GVFactorDesctInfonavit.DataSource = objnom.DTSetResultados.Tables[0];
|
||||
GVSalariosMinimos.DataSource = objnom.DTSetResultados.Tables[1];
|
||||
GVIMMSRiesgot.DataSource = objnom.DTSetResultados.Tables[2];
|
||||
GVInfonavitSegViv.DataSource = objnom.DTSetResultados.Tables[3];
|
||||
GVVigISRMensual.DataSource = objnom.DTSetResultados.Tables[4];
|
||||
GVVigSubEmpMensual.DataSource = objnom.DTSetResultados.Tables[5];
|
||||
GVUma.DataSource = objnom.DTSetResultados.Tables[6];
|
||||
}
|
||||
|
||||
}
|
||||
GVFactorDesctInfonavit.DataBind();
|
||||
GVSalariosMinimos.DataBind();
|
||||
GVIMMSRiesgot.DataBind();
|
||||
GVInfonavitSegViv.DataBind();
|
||||
GVVigISRMensual.DataBind();
|
||||
GVVigSubEmpMensual.DataBind();
|
||||
GVVigSubEmpMensual.DataBind();
|
||||
GVUma.DataBind();
|
||||
UpModalTablas.Update();
|
||||
RegistraScript("$('#ModalTablas').modal();");
|
||||
}
|
||||
}
|
||||
8241
RH/Personal.aspx
8241
RH/Personal.aspx
File diff suppressed because it is too large
Load Diff
@@ -620,139 +620,143 @@ Partial Class RH_Personal
|
||||
Const wdCharacter As Integer = 1
|
||||
'Configuración
|
||||
Protected Sub Page_Load(sender As Object, e As System.EventArgs) Handles Me.Load
|
||||
If Not IsPostBack Then
|
||||
ViewState("Orden") = ""
|
||||
ViewState("Orden1") = ""
|
||||
Session("FileUpload") = ""
|
||||
ViewState("Archivo") = ""
|
||||
DTConsumos = Nothing
|
||||
|
||||
If UsuarioActual.CveRol = 1 Or UsuarioActual.CveEmpresa = 74 Then
|
||||
TabGES.Visible = True
|
||||
End If
|
||||
|
||||
SetValues()
|
||||
'SetPermisos()
|
||||
|
||||
CargaEscolaridad()
|
||||
CargaEstadoCivil()
|
||||
CargaDepartamento()
|
||||
CargaPuestos()
|
||||
CargaEstatusPersonal()
|
||||
CargaGenero()
|
||||
CargaMotivoBaja()
|
||||
CargaRuta()
|
||||
CargaTiposContrato()
|
||||
CargaTipoPeriodo()
|
||||
CargaTurno()
|
||||
CargaJornadas()
|
||||
CargaProyecto()
|
||||
CargaTiposAsistencia()
|
||||
'CargaMotivoHoraExtra()
|
||||
CargaMotivosHorasExtras()
|
||||
CargaSupervisores()
|
||||
CargaMetodosPago()
|
||||
CargaTipoRegimen()
|
||||
CargaRiesgoPuesto()
|
||||
CargaBancos()
|
||||
CargaSubProyectosZona()
|
||||
CargaEstados(1)
|
||||
CargaMonedas()
|
||||
CargaSuperioresOrganigrama()
|
||||
CargaUsuariosNomina()
|
||||
CargaComboUniformes()
|
||||
CargaPermisos()
|
||||
CargaCombosBuzon()
|
||||
CargaPermisosReemplazos()
|
||||
|
||||
|
||||
If Request("CvePersonal") IsNot Nothing AndAlso IsNumeric(Request("CvePersonal")) AndAlso Request("CvePersonal").ToEntero > 0 Then
|
||||
ViewState("CvePersonal") = Request("CvePersonal")
|
||||
'CvePersonal = ViewState("CvePersonal").ToString.ToEntero
|
||||
CargaDatos()
|
||||
CargaDocumentacionFirmaDecontratos()
|
||||
'LnkAddLicencias.Visible = True
|
||||
'TabLicencias.Visible = True
|
||||
'Configuración de Modalidad Update
|
||||
BtnGuardar.Text = "Guardar Cambios"
|
||||
LtlTitulo.Text = "Consulta de Personal:"
|
||||
If UsuarioActual.CveRol = 1 Then
|
||||
'ImgImprimir.Visible = True
|
||||
ImgImprimirExpediente.Visible = True
|
||||
End If
|
||||
|
||||
'ImgAddObs.Attributes.Add("onclick", "javascript: PosicionaObjeto(this.id,'DivEventoBitacora',null,-250,-250); $('#DivEventoBitacora').show(1000); ")
|
||||
If Request("Opt") IsNot Nothing AndAlso IsNumeric(Request("Opt")) Then Tab.ActiveTabIndex = Request("Opt").ToEntero - 1
|
||||
|
||||
'Inicia Permisos
|
||||
If UsuarioActual.TienePermisoProceso(228) Then
|
||||
GVAsistencia.Columns(10).Visible = True
|
||||
End If
|
||||
'Fin Permisos
|
||||
HlEvento.Visible = True
|
||||
HlEvento.NavigateUrl = "/OI/PopUpAgenda.aspx?CveTipoEvento=2&CvePersonal=" & CvePersonal & "&TB_iframe=true&height=370&width=600;"
|
||||
|
||||
CargaViaticosPersonal()
|
||||
|
||||
divBitacora.Visible = True
|
||||
CargaGvBitacora()
|
||||
Else
|
||||
|
||||
'Configuración de Modalidad Insert
|
||||
|
||||
ImgAddObs.Visible = False
|
||||
LblFechaCaptura.Text = Now.ToShortDateString()
|
||||
LblUsuarioCapturo.Text = UsuarioActual.Usuario
|
||||
ViewState("CvePersonal") = -1
|
||||
BtnEliminar.Visible = False
|
||||
CarcaConceptosNomina()
|
||||
For Each Gvr As GridViewRow In GVConceptos.Rows
|
||||
If CBool(Gvr.DataKey("Obligatorio")) Then
|
||||
Gvr.FCCheckBox("ChkAplica").Checked = True
|
||||
Else
|
||||
Gvr.Visible = False
|
||||
End If
|
||||
Next
|
||||
'Inicia Permisos
|
||||
'Fin Permisos
|
||||
End If
|
||||
CargaCuentasBancarias()
|
||||
|
||||
If UsuarioActual.Empresa.Funcionalidad(568) = "1" Then
|
||||
|
||||
CrearEstructuraFamiliares()
|
||||
CargaFamiliares()
|
||||
|
||||
LIFamiliaresAcciones.Visible = True
|
||||
DivFamiliares.Visible = True
|
||||
DivPadres.Visible = False
|
||||
|
||||
|
||||
If Not IsPostBack Then
|
||||
If UsuarioActual.CveEmpresa = 72 OrElse UsuarioActual.CveEmpresa = 80 Then
|
||||
pnlSalarioIMSS.Visible = False
|
||||
End If
|
||||
|
||||
ViewState("Orden") = ""
|
||||
ViewState("Orden1") = ""
|
||||
Session("FileUpload") = ""
|
||||
ViewState("Archivo") = ""
|
||||
DTConsumos = Nothing
|
||||
|
||||
If UsuarioActual.CveRol = 1 Or UsuarioActual.CveEmpresa = 74 Then
|
||||
TabGES.Visible = True
|
||||
End If
|
||||
|
||||
SetValues()
|
||||
'SetPermisos()
|
||||
|
||||
CargaEscolaridad()
|
||||
CargaEstadoCivil()
|
||||
CargaDepartamento()
|
||||
CargaPuestos()
|
||||
CargaEstatusPersonal()
|
||||
CargaGenero()
|
||||
CargaMotivoBaja()
|
||||
CargaRuta()
|
||||
CargaTiposContrato()
|
||||
CargaTipoPeriodo()
|
||||
CargaTurno()
|
||||
CargaJornadas()
|
||||
CargaProyecto()
|
||||
CargaTiposAsistencia()
|
||||
'CargaMotivoHoraExtra()
|
||||
CargaMotivosHorasExtras()
|
||||
CargaSupervisores()
|
||||
CargaMetodosPago()
|
||||
CargaTipoRegimen()
|
||||
CargaRiesgoPuesto()
|
||||
CargaBancos()
|
||||
CargaSubProyectosZona()
|
||||
CargaEstados(1)
|
||||
CargaMonedas()
|
||||
CargaSuperioresOrganigrama()
|
||||
CargaUsuariosNomina()
|
||||
CargaComboUniformes()
|
||||
CargaPermisos()
|
||||
CargaCombosBuzon()
|
||||
CargaPermisosReemplazos()
|
||||
|
||||
|
||||
If Request("CvePersonal") IsNot Nothing AndAlso IsNumeric(Request("CvePersonal")) AndAlso Request("CvePersonal").ToEntero > 0 Then
|
||||
ViewState("CvePersonal") = Request("CvePersonal")
|
||||
'CvePersonal = ViewState("CvePersonal").ToString.ToEntero
|
||||
CargaDatos()
|
||||
CargaDocumentacionFirmaDecontratos()
|
||||
'LnkAddLicencias.Visible = True
|
||||
'TabLicencias.Visible = True
|
||||
'Configuración de Modalidad Update
|
||||
BtnGuardar.Text = "Guardar Cambios"
|
||||
LtlTitulo.Text = "Consulta de Personal:"
|
||||
If UsuarioActual.CveRol = 1 Then
|
||||
'ImgImprimir.Visible = True
|
||||
ImgImprimirExpediente.Visible = True
|
||||
End If
|
||||
|
||||
'ImgAddObs.Attributes.Add("onclick", "javascript: PosicionaObjeto(this.id,'DivEventoBitacora',null,-250,-250); $('#DivEventoBitacora').show(1000); ")
|
||||
If Request("Opt") IsNot Nothing AndAlso IsNumeric(Request("Opt")) Then Tab.ActiveTabIndex = Request("Opt").ToEntero - 1
|
||||
|
||||
'Inicia Permisos
|
||||
If UsuarioActual.TienePermisoProceso(228) Then
|
||||
GVAsistencia.Columns(10).Visible = True
|
||||
End If
|
||||
'Fin Permisos
|
||||
HlEvento.Visible = True
|
||||
HlEvento.NavigateUrl = "/OI/PopUpAgenda.aspx?CveTipoEvento=2&CvePersonal=" & CvePersonal & "&TB_iframe=true&height=370&width=600;"
|
||||
|
||||
CargaViaticosPersonal()
|
||||
|
||||
divBitacora.Visible = True
|
||||
CargaGvBitacora()
|
||||
Else
|
||||
|
||||
'Configuración de Modalidad Insert
|
||||
|
||||
ImgAddObs.Visible = False
|
||||
LblFechaCaptura.Text = Now.ToShortDateString()
|
||||
LblUsuarioCapturo.Text = UsuarioActual.Usuario
|
||||
ViewState("CvePersonal") = -1
|
||||
BtnEliminar.Visible = False
|
||||
CarcaConceptosNomina()
|
||||
For Each Gvr As GridViewRow In GVConceptos.Rows
|
||||
If CBool(Gvr.DataKey("Obligatorio")) Then
|
||||
Gvr.FCCheckBox("ChkAplica").Checked = True
|
||||
Else
|
||||
Gvr.Visible = False
|
||||
End If
|
||||
Next
|
||||
'Inicia Permisos
|
||||
'Fin Permisos
|
||||
End If
|
||||
CargaCuentasBancarias()
|
||||
|
||||
If UsuarioActual.Empresa.Funcionalidad(568) = "1" Then
|
||||
|
||||
CrearEstructuraFamiliares()
|
||||
CargaFamiliares()
|
||||
|
||||
LIFamiliaresAcciones.Visible = True
|
||||
DivFamiliares.Visible = True
|
||||
DivPadres.Visible = False
|
||||
|
||||
|
||||
End If
|
||||
|
||||
|
||||
|
||||
'If UsuarioActual.TienePermisoProceso(84) Then 'abonar pago
|
||||
' HplAbonarMasivo.Visible = True
|
||||
' GvGxC.Columns(7).Visible = True
|
||||
'End If
|
||||
|
||||
'If UsuarioActual.TienePermisoProceso(84) Then 'abonar pago
|
||||
' HplAbonarMasivo.Visible = True
|
||||
' GvGxC.Columns(7).Visible = True
|
||||
'End If
|
||||
|
||||
|
||||
If Not CvePersonal > 0 Then
|
||||
DivSuperiorInmediato.Visible = False
|
||||
End If
|
||||
|
||||
'09/05/2018 - Si el Personal tiene consumos, muestra boton para generar reporte
|
||||
If DTConsumos IsNot Nothing Then
|
||||
If DTConsumos.Rows.Count > 0 Then
|
||||
UpDescargaConsumos.Visible = True
|
||||
End If
|
||||
End If
|
||||
CargaLicencias()
|
||||
|
||||
End If
|
||||
AgregarEventosAsincronosGvVacaciones()
|
||||
If Not CvePersonal > 0 Then
|
||||
DivSuperiorInmediato.Visible = False
|
||||
End If
|
||||
|
||||
'09/05/2018 - Si el Personal tiene consumos, muestra boton para generar reporte
|
||||
If DTConsumos IsNot Nothing Then
|
||||
If DTConsumos.Rows.Count > 0 Then
|
||||
UpDescargaConsumos.Visible = True
|
||||
End If
|
||||
End If
|
||||
CargaLicencias()
|
||||
|
||||
End If
|
||||
AgregarEventosAsincronosGvVacaciones()
|
||||
End Sub
|
||||
|
||||
Private Sub CargaCuentasContables()
|
||||
@@ -1089,22 +1093,9 @@ Partial Class RH_Personal
|
||||
End Sub
|
||||
|
||||
Protected Sub GVAsistencia_RowDataBound(sender As Object, e As System.Web.UI.WebControls.GridViewRowEventArgs) Handles GVAsistencia.RowDataBound
|
||||
If e.Row.RowType = DataControlRowType.DataRow Then
|
||||
|
||||
If e.Row.RowIndex = 0 Then
|
||||
e.Row.Cells(0).Width = Unit.Pixel(120)
|
||||
e.Row.Cells(1).Width = Unit.Pixel(180)
|
||||
e.Row.Cells(2).Width = Unit.Pixel(110)
|
||||
e.Row.Cells(3).Width = Unit.Pixel(110)
|
||||
e.Row.Cells(4).Width = Unit.Pixel(70)
|
||||
e.Row.Cells(5).Width = Unit.Pixel(50)
|
||||
e.Row.Cells(6).Width = Unit.Pixel(56)
|
||||
e.Row.Cells(7).Width = Unit.Pixel(56)
|
||||
e.Row.Cells(8).Width = Unit.Pixel(110)
|
||||
e.Row.Cells(9).Width = Unit.Pixel(90)
|
||||
e.Row.Cells(10).Width = Unit.Pixel(60)
|
||||
End If
|
||||
|
||||
If e.Row.RowType = DataControlRowType.DataRow Then
|
||||
|
||||
|
||||
e.Row.Cells(1).HorizontalAlign = HorizontalAlign.Left
|
||||
e.Row.Cells(2).HorizontalAlign = HorizontalAlign.Left
|
||||
e.Row.Cells(3).HorizontalAlign = HorizontalAlign.Left
|
||||
@@ -1441,6 +1432,9 @@ Partial Class RH_Personal
|
||||
End If
|
||||
End If
|
||||
|
||||
If UsuarioActual.CveEmpresa = 72 OrElse UsuarioActual.CveEmpresa = 80 Then
|
||||
TxtSalarioCotizado.Text = TxtSDI.Text
|
||||
End If
|
||||
|
||||
If CvePersonal = -1 Then
|
||||
URL = ""
|
||||
@@ -2183,32 +2177,46 @@ Partial Class RH_Personal
|
||||
e.Row.FCDropDownList("DdlTipoAplicacion").Visible = False : e.Row.Cells(3).Text = "Calculado"
|
||||
e.Row.FCDropDownList("DdlTipoAplicacion").Visible = False : e.Row.Cells(4).Text = "Permanente"
|
||||
Else
|
||||
If e.Row.DBCampo("TipoAplicacion").ToEntero > 5 Then
|
||||
e.Row.FCDropDownList("DdlTipoAplicacion").SelectedValue = "2600"
|
||||
Else
|
||||
e.Row.FCDropDownList("DdlTipoAplicacion").SelectedValue = e.Row.DBCampo("TipoAplicacion")
|
||||
End If
|
||||
Dim TipoAplicacion As String = e.Row.DBCampo("TipoAplicacion").ToString()
|
||||
e.Row.FCDropDownList("DdlTipoAplicacion").Items.Clear()
|
||||
e.Row.FCDropDownList("DdlTipoAplicacion").Items.Add(New ListItem("Seleccione", "-1"))
|
||||
If (e.Row.DBCampo("CveSistema").ToString() = "3") Then
|
||||
e.Row.FCDropDownList("DdlTipoAplicacion").Items.Add(New ListItem("Infonavit(Movto Permanente)", "5000"))
|
||||
e.Row.FCDropDownList("DdlTipoAplicacion").Items.Add(New ListItem("Infonavit(Porcentaje)", "5001"))
|
||||
e.Row.FCDropDownList("DdlTipoAplicacion").Items.Add(New ListItem("Infonavit(Factor Descuento)", "5002"))
|
||||
e.Row.FCDropDownList("DdlTipoAplicacion").Items.Add(New ListItem("Infonavit(Cuota Fija)", "5003"))
|
||||
Else
|
||||
e.Row.FCDropDownList("DdlTipoAplicacion").Items.Add(New ListItem("Saldo", "1"))
|
||||
e.Row.FCDropDownList("DdlTipoAplicacion").Items.Add(New ListItem("No. Pagos", "2"))
|
||||
e.Row.FCDropDownList("DdlTipoAplicacion").Items.Add(New ListItem("Permanente", "2600"))
|
||||
End If
|
||||
|
||||
|
||||
If e.Row.DBCampo("TipoAplicacion").ToEntero > 5 Then
|
||||
TipoAplicacion = "2600"
|
||||
End If
|
||||
e.Row.FCDropDownList("DdlTipoAplicacion").SelectedValueExist(TipoAplicacion)
|
||||
End If
|
||||
|
||||
'If e.Row.DBCampo("TipoCalculo") = "False" Then
|
||||
' e.Row.FCTextBox("TxtImporte").Visible = False
|
||||
' e.Row.FCDropDownList("DdlTipoAplicacion").Visible = False
|
||||
'Else
|
||||
' Select Case e.Row.DBCampo("TipoAplicacion").ToEntero
|
||||
' Case 1
|
||||
' 'Saldo
|
||||
' e.Row.FCLiteral("LtlSaldo").Visible = True
|
||||
' e.Row.FCTextBox("TxtSaldoIni").Visible = True
|
||||
' Case 2
|
||||
' 'Numero de Pagos
|
||||
' e.Row.FCLiteral("LtlNoPago").Visible = True
|
||||
' e.Row.FCTextBox("TxtNoPagos").Visible = True
|
||||
' Case 2600
|
||||
' 'Permanente
|
||||
' End Select
|
||||
'End If
|
||||
|
||||
End If
|
||||
|
||||
'If e.Row.DBCampo("TipoCalculo") = "False" Then
|
||||
' e.Row.FCTextBox("TxtImporte").Visible = False
|
||||
' e.Row.FCDropDownList("DdlTipoAplicacion").Visible = False
|
||||
'Else
|
||||
' Select Case e.Row.DBCampo("TipoAplicacion").ToEntero
|
||||
' Case 1
|
||||
' 'Saldo
|
||||
' e.Row.FCLiteral("LtlSaldo").Visible = True
|
||||
' e.Row.FCTextBox("TxtSaldoIni").Visible = True
|
||||
' Case 2
|
||||
' 'Numero de Pagos
|
||||
' e.Row.FCLiteral("LtlNoPago").Visible = True
|
||||
' e.Row.FCTextBox("TxtNoPagos").Visible = True
|
||||
' Case 2600
|
||||
' 'Permanente
|
||||
' End Select
|
||||
'End If
|
||||
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Protected Sub BtnGuardarInfornavit_Click(sender As Object, e As EventArgs)
|
||||
@@ -5874,4 +5882,11 @@ Partial Class RH_Personal
|
||||
#End Region
|
||||
|
||||
|
||||
Protected Sub DdlTipoAsistencias_SelectedIndexChanged(sender As Object, e As EventArgs)
|
||||
Dim ddl As DropDownList = DirectCast(sender, DropDownList)
|
||||
Dim gvrow As GridViewRow = DirectCast(ddl.NamingContainer, GridViewRow)
|
||||
If ddl.SelectedItem.Text = "Retardo" Then
|
||||
gvrow.FCTextBox("TxtPorPago").Text = "87.5"
|
||||
End If
|
||||
End Sub
|
||||
End Class
|
||||
|
||||
@@ -1697,6 +1697,32 @@ function loadsortadscroll() {
|
||||
});
|
||||
}
|
||||
|
||||
var listaADScroller = [];
|
||||
|
||||
function saveposicionADScroller() {
|
||||
$('.ADScroller-body>table').each(function () {
|
||||
let _this = $(this);
|
||||
let id = _this.attr("id");
|
||||
let scrollleft = $(_this.parent()).scrollLeft();
|
||||
let scrolltop = $(_this.parent()).scrollTop();
|
||||
listaADScroller.push({ id: id, scrollleft: scrollleft, scrolltop: scrolltop })
|
||||
});
|
||||
}
|
||||
function setposicionADScroller() {
|
||||
|
||||
setTimeout(
|
||||
function () {
|
||||
listaADScroller.forEach(function (_this) {
|
||||
let id = _this.id;
|
||||
let scrollleft = _this.scrollleft;
|
||||
let scrolltop = _this.scrolltop;
|
||||
$($('#' + id).parent()).scrollLeft(scrollleft);
|
||||
$($('#' + id).parent().parent()).find('> .ADScroller-header').scrollLeft(scrollleft);
|
||||
$($('#' + id).parent()).scrollTop(scrolltop);
|
||||
});
|
||||
}, 99);
|
||||
}
|
||||
|
||||
function loaderinit() {
|
||||
|
||||
setTimeout(
|
||||
@@ -1727,7 +1753,6 @@ jQuery(document).ready(function () {
|
||||
setTimeout(loadadscroll, 10)
|
||||
});
|
||||
|
||||
|
||||
loadsortadscroll();
|
||||
QuickSidebar.init();
|
||||
|
||||
@@ -1804,6 +1829,8 @@ jQuery(document).ready(function () {
|
||||
prm.add_initializeRequest(function (s, e) {
|
||||
objscollapse = $('.portlet-title .collapse').closest('.portlet[id]');
|
||||
objsexpand = $('.portlet-title .expand').closest('.portlet[id]');
|
||||
|
||||
saveposicionADScroller();
|
||||
loaderinit();
|
||||
});
|
||||
prm.add_endRequest(function (s, e) {
|
||||
@@ -1816,6 +1843,7 @@ jQuery(document).ready(function () {
|
||||
Metronic.initAjax();
|
||||
loadjquerys();
|
||||
loaderEnd();
|
||||
setposicionADScroller();
|
||||
error = false;
|
||||
});
|
||||
ADSSignalR();
|
||||
|
||||
@@ -14944,6 +14944,7 @@ Partial Class Ventas
|
||||
|
||||
Else
|
||||
OcurrioError = True
|
||||
Alert("Error traspaso almacen(sin Movtos. Detalle). Por favor comuniquese con atención SIG.", TipoMensaje.ToastError)
|
||||
End If
|
||||
|
||||
MovDetalle.Dispose()
|
||||
@@ -15085,6 +15086,7 @@ Partial Class Ventas
|
||||
Dim CveVentaDetalle = If(ConceptoEntrada = 3, TmpDT.FiltroPrimeroValor("CveVentaDetalle", $"Consec={Consec}").ToEntero, MovDet("CveVentaDetalle").ToString.ToEntero)
|
||||
'CUANDO LA VENTADETALLE NO TENGA VALOR DEBE MARCAR ERROR, NUEVA RESTRICCION DE ALMACEN
|
||||
If CveVentaDetalle < 0 Then
|
||||
Alert("no se encontro la venta detalle. Por favor comuniquese con atención SIG.", TipoMensaje.ToastError)
|
||||
OcurrioError = True
|
||||
Exit For
|
||||
End If
|
||||
@@ -15143,6 +15145,7 @@ Partial Class Ventas
|
||||
'End If
|
||||
Catch ex As Exception
|
||||
OcurrioError = True
|
||||
Alert("Error inesperado (15147). Por favor comuniquese con atención SIG.", TipoMensaje.ToastError)
|
||||
End Try
|
||||
Cont += 1
|
||||
Next
|
||||
|
||||
Reference in New Issue
Block a user