Sat Solicitudes Ingreso

This commit is contained in:
rakcsle
2022-07-23 16:38:18 -07:00
parent 6d331920f1
commit 4a9125045b
6 changed files with 802 additions and 304 deletions

View File

@@ -214,7 +214,7 @@
</asp:Content>
<asp:Content ID="Content5" ContentPlaceHolderID="H" runat="Server">
<li>
<asp:LinkButton ID="LnkDownloadExcel" OnClick="LnkDownloadExcel_Click" runat="server"><i class="fa fa-download"></i>Descargar</asp:LinkButton>
<%-- <asp:LinkButton ID="LnkDownloadExcel" OnClick="LnkDownloadExcel_Click" runat="server"><i class="fa fa-download"></i>Descargar</asp:LinkButton>--%>
</li>
<asp:UpdatePanel ID="UpAcciones" runat="server" UpdateMode="Conditional">
<contenttemplate>
@@ -283,38 +283,192 @@
</div>
</div>
<div class="portlet light xspadding bordered " id="pnldl">
<div class="portlet-title">
<div class="caption ">
<i class="fa fa-bookmark font-blue"></i>
<span class="caption-subject font-blue bold uppercase">Información timbre fiscal </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 style="float: right;">
<asp:TextBox CssClass="TxtBusqueda form-control input-sm" runat="server" onkeyup="FiltrarTablaV2('.TxtBusqueda','.ADScroller-body .GVSolicitudTimbreNominaGral')" Style="display: inline-block; margin-right: -20px; width: 150px;"></asp:TextBox>
<a href="javascript:;" onclick="FiltrarTablaV2('.TxtBusqueda','.ADScroller-body .GVSolicitudTimbreNominaGral')" style="margin-top: -3px;" class="btn btn-circle btn-sm font-bold blue"><i class="icon-magnifier" style="font-weight: bold;"></i></a>
</div>
</div>
<div class='portlet-body nomarginleftright form-horizontal form-row-sepe formnombottom <%= clasegrid %>'>
<asp:GridView ID="GvSolicitudesIngreso" runat="server" GridLines="None" CssClass="table table-hover table-striped ScrollAD Widthall GVSolicitudTimbreNominaGral" AutoGenerateColumns="true">
<columns></columns>
</asp:GridView>
</div>
</div>
</contenttemplate>
</asp:UpdatePanel>
<div id="ModalViewSolicitudes" class="modal ADS fade" role="dialog">
<asp:UpdatePanel ID="UpDatos" runat="server" UpdateMode="Conditional">
<contenttemplate>
<div class="row">
<div class="col-md-12">
<asp:GridView ID="GvResumen" runat="server" GridLines="None" CssClass="table table-hover table-striped ScrollAD Widthall" AutoGenerateColumns="False" Width="600px" OnRowDataBound="GvResumen_RowDataBound"
ShowHeaderWhenEmpty="true" EmptyDataText="No se encontraron registros"
DataKeyNames="Mes" >
<Columns>
<asp:TemplateField HeaderText="Mes">
<ItemTemplate>
<asp:Label id="LblMes" runat="server" Text='<%# Eval("Mes")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="SIG" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Label ID="LblVTotal" runat="server" Text='<%# Eval("VTotal","{0:N2}")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="SAT" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Label ID="LblCBTTotal" runat="server" Text='<%# Eval("CBTTotal","{0:N2}")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Diferencia" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Label ID="LblDif" runat="server" Text='<%# Eval("Dif","{0:N2}")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</div>
</div>
<div class="row">
<div class="col-md-12">
<asp:GridView ID="GvDatos" runat="server" GridLines="None" CssClass="table table-hover table-striped ScrollAD Widthall" Visible ="false" AutoGenerateColumns="false" OnRowDataBound="GvDatos_RowDataBound"
ShowHeaderWhenEmpty="true" EmptyDataText="No se encontraron registros"
DataKeyNames="UUID,CountRegistros,VTotal,CBTTotal">
<Columns>
<asp:TemplateField HeaderText="Folio">
<ItemTemplate>
<asp:Label runat="server" ID="LblUUID" Text='<%# Eval("UUID")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="SIG">
<ItemTemplate>
<asp:Label runat="server" ID="LblEnSistema" Text='<%# Eval("Sistema")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="SAT" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Label runat="server" ID="LblCFDIData" Text='<%# Eval("CFDIData")%>' ></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Serie Folio" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Label runat="server" ID="LblVSerieFolio" Text='<%# Eval("VSerieFolio")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Total" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Label runat="server" ID="LblVTotal" Text='<%# Eval("VTotal","{0:N2}")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Sub Total" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Label runat="server" ID="LblVSubTotal" Text='<%# Eval("VSubTotal","{0:N2}")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="IVA" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Label runat="server" ID="LblVIVA" Text='<%# Eval("VIVA","{0:N2}")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="IEPS" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Label runat="server" ID="LblVIEPS" Text='<%# Eval("VIEPS","{0:N2}")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Ret. IVA" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Label runat="server" ID="LblVRetIVA" Text='<%# Eval("VRetIVA","{0:N2}")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Ret. ISR" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Label runat="server" ID="LblVRetISR" Text='<%# Eval("VRetISR","{0:N2}")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Total" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Label runat="server" ID="LblCBTTotal" Text='<%# Eval("CBTTotal","{0:N2}")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Sub Total" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Label runat="server" ID="LblCBTSubTotal" Text='<%# Eval("CBTSubTotal","{0:N2}")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="IVA" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Label runat="server" ID="LblImpIVA" Text='<%# Eval("ImpIVA","{0:N2}")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="IEPS" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Label runat="server" ID="LblImpIEPS" Text='<%# Eval("ImpIEPS","{0:N2}")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Ret. ISR" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Label runat="server" ID="LblImpRetISR" Text='<%# Eval("ImpRetISR","{0:N2}")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Ret. IVA" ItemStyle-HorizontalAlign="Right" >
<ItemTemplate>
<asp:Label runat="server" ID="LblImpRetIVA" Text='<%# Eval("ImpRetIVA","{0:N2}")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</div>
</div>
</contenttemplate>
</asp:UpdatePanel>
<div id="ModalViewSolicitudes" class="modal ADS fade" role="dialog">
<asp:UpdatePanel ID="UPModalViewSolicitudes" class="modal-dialog rowpadding" tabindex="-1" runat="server" UpdateMode="Conditional">
<contenttemplate>
<div class="modal-content">
@@ -323,192 +477,203 @@
<h4 class="modal-title">Solicitudes CFDI</h4>
</div>
<div class="modal-body">
<br />
<div class="portlet light xspadding bordered " id="PnlAgregar">
<div class="portlet-title">
<div class="caption ">
<i class="fa fa-bookmark font-blue"></i>
<span class="caption-subject font-blue bold uppercase">Solicitar información al sat</span>
</div>
<div class="tools">
<a href="javascript:;" class="expand" data-original-title="" title=""></a>
<a href="javascript:;" class="fullscreen" data-original-title="" title=""></a>
</div>
</div>
<div class="portlet-body nomarginleftright form-horizontal form-row-sepe formnombottom " style="display: none">
<div class="row">
<div class="col-md-4">
<asp:Label runat="server" Text="Fecha Inicio" AssociatedControlID="txtFechaIAdd"></asp:Label>
</div>
<div class="col-md-4">
<asp:Label runat="server" Text="Fecha Fin" AssociatedControlID="txtFechaFAdd"></asp:Label>
</div>
</div>
<div class="row">
<div class="col-md-4">
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 138px !important; padding: 0px; margin-bottom: -10px;">
<asp:TextBox ID="txtFechaIAdd" CssClass="form-control input-sm ADSMaskDate" Style="" runat="server"></asp:TextBox>
<span class="input-group-btn ">
<asp:LinkButton ID="LnkFechaIAdd" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
</span>
<ajax:maskededitextender id="MEEFechaIAdd" runat="server" targetcontrolid="txtFechaIAdd" mask="99/99/9999" masktype="Date" displaymoney="Left" acceptnegative="Left"></ajax:maskededitextender>
<ajax:calendarextender runat="server" id="CalendarExtender1" targetcontrolid="txtFechaIAdd" popupbuttonid="LnkFechaIAdd" popupposition="BottomRight" enabled="True"></ajax:calendarextender>
<asp:RequiredFieldValidator ID="rfvFechaIAdd" runat="server" ControlToValidate="txtFechaIAdd" Display="None" ErrorMessage="El campo <b>''Fecha Inicial''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="VGAdd"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="cvFechaIAdd" runat="server" ControlToValidate="txtFechaIAdd" 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="Valida"></asp:CompareValidator>
<ajax:validatorcalloutextender id="ValidatorCalloutExtender3" runat="server" highlightcssclass="vco" targetcontrolid="rfvFechaIAdd" width="350px"></ajax:validatorcalloutextender>
<ajax:validatorcalloutextender id="ValidatorCalloutExtender4" runat="server" highlightcssclass="vco" targetcontrolid="cvFechaIAdd" width="350px"></ajax:validatorcalloutextender>
</div>
</div>
<div class="col-md-4">
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 138px !important; padding: 0px; margin-bottom: -10px;">
<asp:TextBox ID="txtFechaFAdd" CssClass="form-control input-sm ADSMaskDate" Style="" runat="server"></asp:TextBox>
<span class="input-group-btn ">
<asp:LinkButton ID="LnkFechaFAdd" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
</span>
<ajax:maskededitextender id="MEEFechaFAdd" runat="server" targetcontrolid="txtFechaFAdd" mask="99/99/9999" masktype="Date" displaymoney="Left" acceptnegative="Left"></ajax:maskededitextender>
<ajax:calendarextender runat="server" id="CalendarExtender2" targetcontrolid="txtFechaFAdd" popupbuttonid="LnkFechaFAdd" popupposition="BottomRight" enabled="True"></ajax:calendarextender>
<asp:RequiredFieldValidator ID="rfvFechaFAdd" runat="server" ControlToValidate="txtFechaFAdd" Display="None" ErrorMessage="El campo <b>''Fecha Final''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="VGAdd"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="cvFechaFAdd" runat="server" ControlToValidate="txtFechaFAdd" 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="Valida"></asp:CompareValidator>
<ajax:validatorcalloutextender id="ValidatorCalloutExtender5" runat="server" highlightcssclass="vco" targetcontrolid="rfvFechaFAdd" width="350px"></ajax:validatorcalloutextender>
<ajax:validatorcalloutextender id="ValidatorCalloutExtender6" runat="server" highlightcssclass="vco" targetcontrolid="cvFechaFAdd" width="350px"></ajax:validatorcalloutextender>
</div>
</div>
<div class="col-md-4">
<div class="text-right">
<asp:LinkButton ID="LnkSolicitarSat" CssClass="btn btn-primary" OnClick="LnkSolicitarSat_Click" runat="server">Solicitar</asp:LinkButton>
</div>
</div>
</div>
<div class="row">
<div class="col-md-12" style="text-align:right">
<asp:LinkButton ID="LnkAgregarSolictud" runat="server" data-toggle="tooltip" data-placement="right" OnClick="LnkAgregarSolictud_Click" title="Agregar Solicitud." CssClass="btn btn-circle btn-default" Text="<i class='fa fa-plus'></i> Agregar Solicitud"></asp:LinkButton>
</div>
</div>
<div class="portlet light xspadding bordered " id="PnlPendientes">
<div class="portlet-title">
<div class="caption ">
<i class="fa fa-bookmark font-blue"></i>
<span class="caption-subject font-blue bold uppercase">Solicitudes pendientes de respuesta del SAT </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>
<div class="portlet-body nomarginleftright form-horizontal form-row-sepe formnombottom ">
<asp:GridView ID="GVSolicitudesPendientes" runat="server" GridLines="None" CssClass="table table-hover table-striped ScrollAD Widthall" AutoGenerateColumns="False"
ShowHeaderWhenEmpty="true" EmptyDataText="No se encontraron registros"
DataKeyNames="CveSolicitud,CveSolicitudCFDI,CveSolicitudMetadata,Estatus,Observaciones,FechaInicio,FechaFin,FechaIng,CveUsuarioIng,CveEmpresa">
<columns>
<asp:TemplateField HeaderText="Folio">
<itemtemplate>
<asp:Label runat="server" Text='<%# Eval("CveSolicitud")%>'></asp:Label>
</itemtemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Fecha Inicio">
<itemtemplate>
<asp:Label ID="lblfechaInicio" runat="server" Text='<%# Eval("FechaInicio","{0:dd/MM/yyyy}")%>'></asp:Label>
</itemtemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Fecha Fin">
<itemtemplate>
<asp:Label ID="lblfechaFin" runat="server" Text='<%# Eval("FechaFin","{0:dd/MM/yyyy}")%>'></asp:Label>
</itemtemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Estatus">
<itemtemplate>
<asp:Label ID="lblestatus" runat="server" Text='<%# Eval("EstatusText")%>'></asp:Label>
</itemtemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Observaciones">
<itemtemplate>
<asp:Label ID="lblobservaciones" runat="server" Text='<%# Eval("Observaciones")%>'></asp:Label>
</itemtemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Fecha solicitud">
<itemtemplate>
<asp:Label runat="server" Text='<%# Eval("FechaIng","{0:dd/MM/yyyy HH:mm}")%>'></asp:Label>
</itemtemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Solicitó">
<itemtemplate>
<asp:Label runat="server" Text='<%# Eval("UsuarioIng")%>'></asp:Label>
</itemtemplate>
</asp:TemplateField>
</columns>
</asp:GridView>
</div>
</div>
<div class="portlet light xspadding bordered " id="PnlTerminads">
<div class="portlet-title">
<div class="caption ">
<i class="fa fa-bookmark font-blue"></i>
<span class="caption-subject font-blue bold uppercase">solicitudes respondidas por el sat</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>
<div class="portlet-body nomarginleftright form-horizontal form-row-sepe formnombottom ">
<asp:GridView ID="GVSolicitudesNominas" runat="server" GridLines="None" CssClass="table table-hover table-striped ScrollAD Widthall" AutoGenerateColumns="False"
ShowHeaderWhenEmpty="true" EmptyDataText="No se encontraron registros"
DataKeyNames="CveSolicitud,idSolicitudCFDI,idSolicitudMetadata,Estatus,Observaciones,FechaInicio,FechaFin,FechaIng,CveUsuarioIng,CveEmpresa">
<columns>
<asp:TemplateField HeaderText="Folio">
<itemtemplate>
<asp:Label runat="server" Text='<%# Eval("CveSolicitud")%>'></asp:Label>
</itemtemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Fecha Inicio">
<itemtemplate>
<asp:Label ID="lblfechaInicio" runat="server" Text='<%# Eval("FechaInicio","{0:dd/MM/yyyy}")%>'></asp:Label>
</itemtemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Fecha Fin">
<itemtemplate>
<asp:Label ID="lblfechaFin" runat="server" Text='<%# Eval("FechaFin","{0:dd/MM/yyyy}")%>'></asp:Label>
</itemtemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="No CFDI">
<itemtemplate>
<asp:Label ID="lblobservaciones" runat="server" Text='<%# Eval("numeroCFDIs")%>'></asp:Label>
</itemtemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Observaciones">
<itemtemplate>
<asp:Label ID="lblobservaciones" runat="server" Text='<%# Eval("Observaciones")%>'></asp:Label>
</itemtemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Fecha solicitud">
<itemtemplate>
<asp:Label runat="server" Text='<%# Eval("FechaIng","{0:dd/MM/yyyy HH:mm}")%>'></asp:Label>
</itemtemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Solicitó">
<itemtemplate>
<asp:Label runat="server" Text='<%# Eval("UsuarioIng")%>'></asp:Label>
</itemtemplate>
</asp:TemplateField>
</columns>
</asp:GridView>
</div>
</div>
<ajax:TabContainer runat="server" ID="TabPanel" ActiveTabIndex="0">
<ajax:TabPanel runat="server" HeaderText="Pendientes" ID="TabPendientes">
<ContentTemplate>
<asp:GridView ID="GVSolicitudesPendientes" runat="server" GridLines="None" CssClass="table table-hover table-striped ScrollAD Widthall" AutoGenerateColumns="False"
ShowHeaderWhenEmpty="true" EmptyDataText="No se encontraron registros"
DataKeyNames="CveSolicitud,CveSolicitudCFDI,CveSolicitudMetadata,Estatus,Observaciones,FechaInicio,FechaFin,FechaIng,CveUsuarioIng,CveEmpresa">
<Columns>
<asp:TemplateField HeaderText="Folio">
<ItemTemplate>
<asp:Label runat="server" Text='<%# Eval("CveSolicitud")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Fecha Inicio">
<ItemTemplate>
<asp:Label ID="lblfechaInicio" runat="server" Text='<%# Eval("FechaInicio","{0:dd/MM/yyyy}")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Fecha Fin">
<ItemTemplate>
<asp:Label ID="lblfechaFin" runat="server" Text='<%# Eval("FechaFin","{0:dd/MM/yyyy}")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Estatus">
<ItemTemplate>
<asp:Label ID="lblestatus" runat="server" Text='<%# Eval("EstatusText")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Observaciones">
<ItemTemplate>
<asp:Label ID="lblobservaciones" runat="server" Text='<%# Eval("Observaciones")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Fecha solicitud">
<ItemTemplate>
<asp:Label runat="server" Text='<%# Eval("FechaIng","{0:dd/MM/yyyy HH:mm}")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Solicitó">
<ItemTemplate>
<asp:Label runat="server" Text='<%# Eval("UsuarioIng")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</ContentTemplate>
</ajax:TabPanel>
<ajax:TabPanel runat="server" HeaderText="Historial" ID="TabHistorial">
<ContentTemplate>
<asp:GridView ID="GVSolicitudesNominas" runat="server" GridLines="None" CssClass="table table-hover table-striped ScrollAD Widthall" AutoGenerateColumns="False"
ShowHeaderWhenEmpty="true" EmptyDataText="No se encontraron registros"
DataKeyNames="CveSolicitud,idSolicitudCFDI,idSolicitudMetadata,Estatus,Observaciones,FechaInicio,FechaFin,FechaIng,CveUsuarioIng,CveEmpresa">
<Columns>
<asp:TemplateField HeaderText="Folio">
<ItemTemplate>
<asp:Label runat="server" Text='<%# Eval("CveSolicitud")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Fecha Inicio">
<ItemTemplate>
<asp:Label ID="lblfechaInicio" runat="server" Text='<%# Eval("FechaInicio","{0:dd/MM/yyyy}")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Fecha Fin">
<ItemTemplate>
<asp:Label ID="lblfechaFin" runat="server" Text='<%# Eval("FechaFin","{0:dd/MM/yyyy}")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="No CFDI">
<ItemTemplate>
<asp:Label ID="lblobservaciones" runat="server" Text='<%# Eval("numeroCFDIs")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Observaciones">
<ItemTemplate>
<asp:Label ID="lblobservaciones" runat="server" Text='<%# Eval("Observaciones")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Fecha solicitud">
<ItemTemplate>
<asp:Label runat="server" Text='<%# Eval("FechaIng","{0:dd/MM/yyyy HH:mm}")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Solicitó">
<ItemTemplate>
<asp:Label runat="server" Text='<%# Eval("UsuarioIng")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</ContentTemplate>
</ajax:TabPanel>
</ajax:TabContainer>
</div>
<div class="modal-footer">
<asp:LinkButton ID="LnkverificarSolicitudes" CssClass="btn btn-primary" OnClick="LnkverificarSolicitudes_Click" runat="server">Verificar pendientes</asp:LinkButton>
<button type="button" class="btn btn-default" data-dismiss="modal">Cerrar</button>
</div>
</div>
</contenttemplate>
</asp:UpdatePanel>
</div>
<div id="ModalAgregarSolicitud" class="modal ADS fade" role="dialog">
<asp:UpdatePanel ID="UPModalViewSolicitudesAgregar" class="modal-dialog rowpadding" tabindex="-1" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal">&times;</button>
<h4 class="modal-title">Agregar Solicitud CFDI</h4>
</div>
<div class="modal-body">
<div class="row">
<div class="col-md-6">
<div class="form-group form-md-line-input input-iconright" style="width: 125px!important">
<asp:TextBox ID="txtFechaIAdd" CssClass="form-control" MaxLength="20" runat="server" Width="100px"></asp:TextBox>
<span class="input-group-btn " style="position: absolute; right: 41px; top: -5px;">
<asp:LinkButton ID="LnkFechaIAdd" class="btn default" Style="margin-top: 15px; margin-left: 6px" Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
</span>
<ajax:MaskedEditExtender ID="MEEFechaIAdd" runat="server" TargetControlID="txtFechaIAdd" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
<ajax:CalendarExtender runat="server" ID="CalendarExtender1" TargetControlID="txtFechaIAdd" PopupButtonID="LnkFechaIAdd" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
<asp:RequiredFieldValidator ID="rfvFechaIAdd" runat="server" ControlToValidate="txtFechaIAdd" Display="None" ErrorMessage="El campo <b>''Fecha Inicial''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="GrpAddSolicitud"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="cvFechaIAdd" runat="server" ControlToValidate="txtFechaIAdd" 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="GrpAddSolicitud"></asp:CompareValidator>
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender3" runat="server" HighlightCssClass="vco" TargetControlID="rfvFechaIAdd" Width="350px"></ajax:ValidatorCalloutExtender>
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender4" runat="server" HighlightCssClass="vco" TargetControlID="cvFechaIAdd" Width="350px"></ajax:ValidatorCalloutExtender>
<label for="<%= txtFechaIAdd.ClientID.ToString() %>" style="margin-top: -6px">Fecha Inicio:</label>
</div>
</div>
<div class="col-md-6">
<div class="form-group form-md-line-input input-iconright" style="width: 125px!important">
<asp:TextBox ID="txtFechaFAdd" CssClass="form-control" MaxLength="20" runat="server" Width="100px"></asp:TextBox>
<span class="input-group-btn " style="position: absolute; right: 41px; top: -5px;">
<asp:LinkButton ID="LnkFechaFAdd" class="btn default" Style="margin-top: 15px; margin-left: 6px" Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
</span>
<ajax:MaskedEditExtender ID="MEEFechaFAdd" runat="server" TargetControlID="txtFechaFAdd" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
<ajax:CalendarExtender runat="server" ID="CalendarExtender2" TargetControlID="txtFechaFAdd" PopupButtonID="LnkFechaFAdd" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
<asp:RequiredFieldValidator ID="rfvFechaFAdd" runat="server" ControlToValidate="txtFechaFAdd" Display="None" ErrorMessage="El campo <b>''Fecha Final''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="GrpAddSolicitud"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="cvFechaFAdd" runat="server" ControlToValidate="txtFechaFAdd" 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="GrpAddSolicitud"></asp:CompareValidator>
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender5" runat="server" HighlightCssClass="vco" TargetControlID="rfvFechaFAdd" Width="350px"></ajax:ValidatorCalloutExtender>
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender6" runat="server" HighlightCssClass="vco" TargetControlID="cvFechaFAdd" Width="350px"></ajax:ValidatorCalloutExtender>
<label for="<%= txtFechaFAdd.ClientID.ToString() %>" style="margin-top: -6px">Fecha Fin:</label>
</div>
</div>
</div>
</div>
<div class="modal-footer">
<asp:LinkButton ID="LnkSolicitarSat" CssClass="btn btn-primary" OnClick="LnkSolicitarSat_Click" runat="server" ValidationGroup="GrpAddSolicitud">Solicitar</asp:LinkButton>
<button type="button" class="btn btn-default" data-dismiss="modal">Cerrar</button>
</div>
</ContentTemplate>
</asp:UpdatePanel>
</div>
</asp:Content>
<asp:Content ID="Content8" ContentPlaceHolderID="JS" runat="Server">
</asp:Content>

View File

@@ -51,7 +51,7 @@ public partial class SAT_SolicitudesIngresoSat : ClsPaginas
{
TxtRpdFechaInicio.Text = string.Format("01/{0:MM/yyyy}", DateTime.Now.AddMonths(-1));
TxtRpdFechaFin.Text = string.Format("{0:dd/MM/yyyy}", DateTime.Now.AddMonths(-1).LastDayOfMonth());
//LnkConsultar_Click(null, null);
LnkConsultar_Click(null, null);
}
}
@@ -63,13 +63,13 @@ public partial class SAT_SolicitudesIngresoSat : ClsPaginas
nom.SATSolicitudTimbreNominaGral(DdlReporte.SelectedValue.ToString().ToEntero(), UsuarioActual.CveEmpresa, fechaInicio, fechaFin);
ClosedXML.Excel.XLWorkbook wb = new ClosedXML.Excel.XLWorkbook();
var libro = wb.AddWorksheet(nom.DtResultados , "Nomina");
var libro = wb.AddWorksheet(nom.DtResultados, "Nomina");
libro.ColumnsUsed().AdjustToContents();
libro.Range(1, 1, 1, nom.DtResultados.Columns.Count).Style.Fill.SetBackgroundColor(ClosedXML.Excel.XLColor.FromArgb(153, 153, 153));
switch (DdlReporte.SelectedValue.ToString().ToEntero())
{
case 1:
libro.Range(1, 2, 1, 2).Style.Fill.SetBackgroundColor(ClosedXML.Excel.XLColor.FromArgb(153,0,0));
libro.Range(1, 2, 1, 2).Style.Fill.SetBackgroundColor(ClosedXML.Excel.XLColor.FromArgb(153, 0, 0));
libro.Range(1, 3, 1, 5).Style.Fill.SetBackgroundColor(ClosedXML.Excel.XLColor.FromArgb(53, 152, 220));
break;
case 2:
@@ -108,7 +108,7 @@ public partial class SAT_SolicitudesIngresoSat : ClsPaginas
}
libro.Row(1).InsertRowsAbove(4);
libro.Range(1, 2, 1, 6).Merge().Value = UsuarioActual.Empresa.Empresa;
libro.Range(2, 2, 2, 6).Merge().Value = $"Reporte de {DdlReporte.SelectedItem.Text }";
libro.Range(2, 2, 2, 6).Merge().Value = $"Reporte de {DdlReporte.SelectedItem.Text}";
libro.Range(3, 2, 3, 6).Merge().Value = $"del {fechaInicio.ToDateTime():dd/MM/yyyy} al {fechaFin.ToDateTime():dd/MM/yyyy}";
libro.Range(2, 7, 2, 9).Merge().Value = $"Fecha:{DateTime.Now:dd/MM/yyyy}";
libro.Range(3, 7, 3, 9).Merge().Value = $"Hora:{DateTime.Now:HH:mm}";
@@ -135,41 +135,54 @@ public partial class SAT_SolicitudesIngresoSat : ClsPaginas
}
protected void LnkConsultar_Click(object sender, EventArgs e)
{
using (ClsNominas nom = new ClsNominas())
GvResumen.DataSource = null;
GvDatos.DataSource = null;
if (DdlReporte.SelectedValue.ToEntero() == 1)
{
fechaInicio = TxtRpdFechaInicio.Text.ToDateTime().ToString("yyyy/MM/dd");
fechaFin = TxtRpdFechaFin.Text.ToDateTime().ToString("yyyy/MM/dd");
nom.SATSolicitudTimbreNominaGral(0, UsuarioActual.CveEmpresa, fechaInicio, fechaFin);
if (nom.DtResultados.Rows.Count > 0)
{
DataRow drow = nom.DtResultados.Rows[0];
//LtlTimbreFiscalTotal.Text = string.Format("{0:N0}", drow["NOXml"]);
//LtlTimbreFiscalActivos.Text = string.Format("{0:N0}", drow["NOXmlActivos"]);
//LtlTimbreFiscalCancelados.Text = string.Format("{0:N0}", drow["NOXml"].ToString().ToEntero() - drow["NOXmlActivos"].ToString().ToEntero());
//LtlSobrerecibosTotal.Text = string.Format("{0:N0}", drow["NOXmlSig"]);
//LtlSobrerecibosTimbrados.Text = string.Format("{0:N0}", drow["Timbrados"]);
//LtlSobrerecibosSintimbrar.Text = string.Format("{0:N0}", drow["SinTimbrar"]);
}
nom.SATSolicitudTimbreNominaGral(DdlReporte.SelectedValue.ToString().ToEntero(), UsuarioActual.CveEmpresa, fechaInicio, fechaFin);
//GvSolicitudesIngreso.DataSource = nom.DtResultados;
//GvSolicitudesIngreso.DataBind();
clasegrid = string.Format("reporte{0}", DdlReporte.SelectedValue);
GvResumen.Visible = true;
GvDatos.Visible = false;
}
upDatosChec.Update();
//SATSolicitudTimbreNominaGral
else
{
GvResumen.Visible = false;
GvDatos.Visible = true;
}
using (ClsNominas ObjNom = new ClsNominas())
{
if (ObjNom.SATSolicitudTimbreIngresosRep(UsuarioActual.CveEmpresa, TxtRpdFechaInicio.Text.ToDate(), TxtRpdFechaFin.Text.ToDate(), DdlReporte.SelectedValue.ToEntero()))
{
if (DdlReporte.SelectedValue.ToEntero() == 1)
{
GvResumen.DataSource = ObjNom.DtResultados;
}
else
{
GvDatos.DataSource = ObjNom.DtResultados;
}
}
}
GvResumen.DataBind();
GvDatos.DataBind();
UpDatos.Update();
}
private void cargasolicitudes()
{
using (ClsNominas nom = new ClsNominas())
{
if (nom.SolicitudesGet(-1, UsuarioActual.CveEmpresa,CveTipoSolicitud:3))
if (nom.SolicitudesGet(-1, UsuarioActual.CveEmpresa, CveTipoSolicitud: 3))
{
GVSolicitudesPendientes.DataSource = nom.DtResultados.FiltraParametros("Estatus =0");
@@ -182,7 +195,9 @@ public partial class SAT_SolicitudesIngresoSat : ClsPaginas
}
protected void LnkShowSolicitudes_Click(object sender, EventArgs e)
{
TabPanel.ActiveTabIndex = 0;
cargasolicitudes();
this.RegistraScript("$('#ModalViewSolicitudes').modal();");
}
@@ -200,54 +215,75 @@ public partial class SAT_SolicitudesIngresoSat : ClsPaginas
bool Continuar = false;
using (ClsNominas nom = new ClsNominas())
{
Continuar = nom.SolicitudesAdd(idSolicitudCFDI, idSolicitudMetadata, estatus, observaciones, fechaInicio, fechaFin, cveUsuarioIng, cveEmpresa, CveTipoSolicitud:3);
Continuar = nom.SolicitudesAdd(idSolicitudCFDI, idSolicitudMetadata, estatus, observaciones, fechaInicio, fechaFin, cveUsuarioIng, cveEmpresa, CveTipoSolicitud: 3);
}
if (Continuar)
{
StringBuilder sbResultado = new StringBuilder();
var api = new GeneralesAPI();
JToken ObjApiSolicitud = (JToken) api.GeneraSolicitud(UsuarioActual.CveEmpresa, 3);
List<string> resultSolicitud = ObjApiSolicitud.Select(token => token.Values().Aggregate((i, j) => $"{i}|{j}").Value<string>()).ToList();
var api = new GeneralesAPII();
JToken ObjApiSolicitud = (JToken)api.GeneraSolicitud(UsuarioActual.CveEmpresa, 3);
List<string> resultSolicitud = new List<string>();
List<string> resultVerificacion = new List<string>();
var ResultadoSolicitudOK = bool.Parse(resultSolicitud[0]);
var ResultadoVerificaionOK = false;
var SeVerifico = false;
var TipoMensaje = ModExtensiones.TipoMensaje.MsgInformacion;
var ResultadoSolicitudOK = false;
if (ResultadoSolicitudOK)
if (!(ObjApiSolicitud == null))
{
JToken ObjApiVerificacion = (JToken) api.VerificaSolicitudesNominas(UsuarioActual.CveEmpresa, 3);
resultVerificacion = ObjApiVerificacion.Select(token => token.Values().Aggregate((i, j) => $"{i}|{j}").Value<string>()).ToList();
ResultadoVerificaionOK = bool.Parse(resultVerificacion[0]);
SeVerifico = true;
resultSolicitud = ObjApiSolicitud.Select(token => token.Values().Aggregate((i, j) => $"{i}|{j}").Value<string>()).ToList();
ResultadoSolicitudOK = bool.Parse(resultSolicitud[0]);
}
else
{
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia;
}
if (ResultadoSolicitudOK)
{
JToken ObjApiVerificacion = (JToken)api.VerificaSolicitudesNominas(UsuarioActual.CveEmpresa, 3);
if (!(ObjApiVerificacion == null))
{
resultVerificacion = ObjApiVerificacion.Select(token => token.Values().Aggregate((i, j) => $"{i}|{j}").Value<string>()).ToList();
ResultadoVerificaionOK = bool.Parse(resultVerificacion[0]);
SeVerifico = true;
}
else
{
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia;
}
}
if (resultSolicitud.Count == 4)
{
if (ResultadoSolicitudOK)
{
sbResultado.Append($"Solicitud Generada Correctamente <br/> {resultSolicitud[2]}");
if (resultSolicitud[1].ToString().Trim().Length > 0)
{
sbResultado.Append($"{resultSolicitud[1]}<br/>");
}
else
{
sbResultado.Append($"Solicitud Generada Correctamente");
sbResultado.Append($"Se presento un error al verificar las solicitudes <br/> {resultSolicitud[2]} <br>");
}
}
else
{
sbResultado.Append($"Se presento un error al generar la solicitud <br/> {resultSolicitud[2]}");
sbResultado.Append($"{resultSolicitud[2]}");
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia;
}
}
else
{
sbResultado.AppendLine("Se presento un error al generar la solicitud (API) <br/>");
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia;
}
@@ -255,30 +291,30 @@ public partial class SAT_SolicitudesIngresoSat : ClsPaginas
{
if (ResultadoVerificaionOK)
{
sbResultado.Append($"Verificación ejecutada correctamente <br/> {resultSolicitud[2]}");
sbResultado.Append($"{resultVerificacion[1]}<br>");
}
else
{
sbResultado.Append($"Se presento un error al verificar las solicitudes <br/> {resultSolicitud[2]}");
sbResultado.Append($"Se presento un error al verificar las solicitudes {resultVerificacion[1]}<br>");
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia;
}
}
else
{
sbResultado.AppendLine("Se presento un error al verificar las solicitudes (API) <br/>");
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia;
}
Alert(sbResultado.ToString());
Alert(sbResultado.ToString(), TipoMensaje);
}
if (Continuar)
{
txtFechaIAdd.Text = "";
txtFechaFAdd.Text = "";
this.RegistraScript("$('#DModalSolicitudesNominas').modal('hide');");
this.RegistraScript("$('#ModalAgregarSolicitud').modal('hide');");
cargasolicitudes();
this.Alert("se a envia la solicitud al sat, le enviaremos un correo en cuanto tengamos una respuesta", ModExtensiones.TipoMensaje.ToastInformacion);
}
}
@@ -292,45 +328,68 @@ public partial class SAT_SolicitudesIngresoSat : ClsPaginas
StringBuilder sbResultado = new StringBuilder();
var api = new GeneralesAPI();
var api = new GeneralesAPII();
JToken ObjApiSolicitud = (JToken)api.GeneraSolicitud(UsuarioActual.CveEmpresa, 3);
List<string> resultSolicitud = ObjApiSolicitud.Select(token => token.Values().Aggregate((i, j) => $"{i}|{j}").Value<string>()).ToList();
List<string> resultSolicitud = new List<string>();
List<string> resultVerificacion = new List<string>();
var ResultadoSolicitudOK = bool.Parse(resultSolicitud[0]);
var ResultadoVerificaionOK = false;
var SeVerifico = false;
var TipoMensaje = ModExtensiones.TipoMensaje.MsgInformacion;
var ResultadoSolicitudOK = false;
if (!(ObjApiSolicitud == null))
{
resultSolicitud = ObjApiSolicitud.Select(token => token.Values().Aggregate((i, j) => $"{i}|{j}").Value<string>()).ToList();
ResultadoSolicitudOK = bool.Parse(resultSolicitud[0]);
}
else
{
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia;
}
if (ResultadoSolicitudOK)
{
JToken ObjApiVerificacion = (JToken)api.VerificaSolicitudesNominas(UsuarioActual.CveEmpresa, 3);
resultVerificacion = ObjApiVerificacion.Select(token => token.Values().Aggregate((i, j) => $"{i}|{j}").Value<string>()).ToList();
ResultadoVerificaionOK = bool.Parse(resultVerificacion[0]);
SeVerifico = true;
if (!(ObjApiVerificacion == null))
{
resultVerificacion = ObjApiVerificacion.Select(token => token.Values().Aggregate((i, j) => $"{i}|{j}").Value<string>()).ToList();
ResultadoVerificaionOK = bool.Parse(resultVerificacion[0]);
SeVerifico = true;
}
else
{
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia;
}
}
if (resultSolicitud.Count == 4)
{
if (ResultadoSolicitudOK)
{
sbResultado.Append($"Solicitud Generada Correctamente <br/> {resultSolicitud[2]}");
if (resultSolicitud[2].ToString().Trim().Length > 0)
{
sbResultado.Append($"{resultSolicitud[2]}<br/>");
}
else
{
sbResultado.Append($"Solicitud Generada Correctamente");
sbResultado.Append($"Se presento un error al verificar las solicitudes <br/> {resultSolicitud[2]} <br>");
}
}
else
{
sbResultado.Append($"Se presento un error al generar la solicitud <br/> {resultSolicitud[2]}");
sbResultado.Append($"{resultSolicitud[2]}");
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia;
}
}
else
{
sbResultado.AppendLine("Se presento un error al generar la solicitud (API) <br/>");
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia;
}
@@ -338,37 +397,124 @@ public partial class SAT_SolicitudesIngresoSat : ClsPaginas
{
if (ResultadoVerificaionOK)
{
sbResultado.Append($"Verificación ejecutada correctamente <br/> {resultSolicitud[2]}");
sbResultado.Append($"{resultVerificacion[2]}<br>");
}
else
{
sbResultado.Append($"Se presento un error al verificar las solicitudes <br/> {resultSolicitud[2]}");
sbResultado.Append($"Se presento un error al verificar las solicitudes {resultVerificacion[2]}<br>");
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia;
}
}
else
{
sbResultado.AppendLine("Se presento un error al verificar las solicitudes (API) <br/>");
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia;
}
Alert(sbResultado.ToString());
Alert(sbResultado.ToString(), TipoMensaje);
cargasolicitudes();
}
protected void LnkAgregarSolictud_Click(object sender, EventArgs e)
{
txtFechaIAdd.Text = "";
txtFechaFAdd.Text = "";
UPModalViewSolicitudesAgregar.Update();
this.RegistraScript("$('#ModalAgregarSolicitud').modal('show');");
}
protected void GvResumen_RowDataBound(object sender, GridViewRowEventArgs e)
{
if(e.Row.RowType == DataControlRowType.DataRow)
{
if(e.Row.DataKey("Mes").ToString() == "")
{
e.Row.Cells[0].Text = "Total";
e.Row.Font.Bold = true;
}
}
}
protected void GvDatos_RowDataBound(object sender, GridViewRowEventArgs e)
{
if(e.Row.RowType == DataControlRowType.DataRow)
{
if (e.Row.DataKey("UUID") == "Totales")
{
e.Row.Font.Bold = true;
e.Row.Cells[1].Text = e.Row.DataKey("VTotal").ToDecimal().ToString("###,###,###.00");
e.Row.Cells[2].Text = e.Row.DataKey("CBTTotal").ToDecimal().ToString("###,###,###.00");
e.Row.Cells[3].Text = e.Row.DataKey("CountRegistros");
}
}
if (e.Row.RowType == DataControlRowType.Header)
{
e.Row.Cells[1].BackColor = System.Drawing.Color.FromName("#3598dc"); //Azul
e.Row.Cells[2].BackColor = System.Drawing.Color.FromName("#900"); //Rojo
e.Row.Cells[4].BackColor = System.Drawing.Color.FromName("#3598dc"); //Azul
e.Row.Cells[5].BackColor = System.Drawing.Color.FromName("#3598dc"); //Azul
e.Row.Cells[6].BackColor = System.Drawing.Color.FromName("#3598dc"); //Azul
e.Row.Cells[7].BackColor = System.Drawing.Color.FromName("#3598dc"); //Azul
e.Row.Cells[8].BackColor = System.Drawing.Color.FromName("#3598dc"); //Azul
e.Row.Cells[9].BackColor = System.Drawing.Color.FromName("#3598dc"); //Azul
e.Row.Cells[10].BackColor = System.Drawing.Color.FromName("#900"); //Rojo
e.Row.Cells[11].BackColor = System.Drawing.Color.FromName("#900"); //Rojo
e.Row.Cells[12].BackColor = System.Drawing.Color.FromName("#900"); //Rojo
e.Row.Cells[13].BackColor = System.Drawing.Color.FromName("#900"); //Rojo
e.Row.Cells[14].BackColor = System.Drawing.Color.FromName("#900"); //Rojo
e.Row.Cells[15].BackColor = System.Drawing.Color.FromName("#900"); //Rojo
e.Row.Cells[1].ForeColor = System.Drawing.Color.FromName("white");
e.Row.Cells[2].ForeColor = System.Drawing.Color.FromName("white");
e.Row.Cells[4].ForeColor = System.Drawing.Color.FromName("white");
e.Row.Cells[5].ForeColor = System.Drawing.Color.FromName("white");
e.Row.Cells[6].ForeColor = System.Drawing.Color.FromName("white");
e.Row.Cells[7].ForeColor = System.Drawing.Color.FromName("white");
e.Row.Cells[8].ForeColor = System.Drawing.Color.FromName("white");
e.Row.Cells[9].ForeColor = System.Drawing.Color.FromName("white");
e.Row.Cells[10].ForeColor = System.Drawing.Color.FromName("white");
e.Row.Cells[11].ForeColor = System.Drawing.Color.FromName("white");
e.Row.Cells[12].ForeColor = System.Drawing.Color.FromName("white");
e.Row.Cells[13].ForeColor = System.Drawing.Color.FromName("white");
e.Row.Cells[14].ForeColor = System.Drawing.Color.FromName("white");
e.Row.Cells[15].ForeColor = System.Drawing.Color.FromName("white");
}
}
}
public class GeneralesAPI : ADSNetLibraryzI.HelpersI.ConexionesI.SIGAPII.BaseSIGAPII
public class GeneralesAPII : ADSNetLibraryzI.HelpersI.ConexionesI.SIGAPII.BaseSIGAPII
{
public GeneralesAPI(string domainApi = "http://localhost:4001/", string token = "") : base(domainApi, token) { }
public GeneralesAPII(string domainApi = "http://localhost:4001/", string token = "") : base(domainApi, token) { }
public object GeneraSolicitud(int CveEmpresa, int CveTipoSolicitud)
{
return getData<object>($"GeneraSolicitud/{CveEmpresa}/{CveTipoSolicitud}", null, ADSNetLibraryzI.HelpersI.ConexionesI.SIGAPII.requestMethod.GET,false);
return getData<object>($"GeneraSolicitud/{CveEmpresa}/{CveTipoSolicitud}", null, ADSNetLibraryzI.HelpersI.ConexionesI.SIGAPII.requestMethod.GET, false);
}
public object VerificaSolicitudesNominas(int CveEmpresa, int CveTipoSolicitud)
{
@@ -377,7 +523,7 @@ public class GeneralesAPI : ADSNetLibraryzI.HelpersI.ConexionesI.SIGAPII.BaseSIG
}
namespace ADSNetLibraryzI.HelpersI.ConexionesI.SIGAPII
{
@@ -388,14 +534,15 @@ namespace ADSNetLibraryzI.HelpersI.ConexionesI.SIGAPII
}
public class BaseSIGAPII
{
private const string tituloLog = "ADSNetLibrary.Helpers.Conexiones.SIGAPI";
private const string tituloLog = " ADSNetLibraryzI.HelpersI.ConexionesI.SIGAPII";
public string domainApi;
public string authorization;
protected string RouteController = "";
protected string FullRoute = "";
public string GetRoutbyclass() {
string classname = this.GetType().Name;
return classname.Substring(0, classname.Length - 3);
public string GetRoutbyclass()
{
string classname = this.GetType().Name;
return classname.Substring(0, classname.Length - 4);
}
public string GetRoute(string path)
{
@@ -423,7 +570,7 @@ namespace ADSNetLibraryzI.HelpersI.ConexionesI.SIGAPII
this.domainApi = domainApi;
this.FullRoute = fullRoute;
}
/// <summary>
@@ -475,11 +622,13 @@ namespace ADSNetLibraryzI.HelpersI.ConexionesI.SIGAPII
};
objreturn = Newtonsoft.Json.JsonConvert.DeserializeObject<T>(jsondata, settings);
}
else {
else
{
//ModExtensiones.GuardaLog(string.Format("{0}{1}{2}{1}StatusCode:{3}{1}{4}{1}{5}{1}", tituloLog, ModVars.NewLine, route, response.StatusCode, response.RequestMessage, strjsonreq), ModVars.ADSNetLibraryLog);
}
}
catch (Exception e) {
catch (Exception e)
{
//ModExtensiones.GuardaLog(string.Format("{0}{1}{2}{1}{3}{1}{4}{1}", tituloLog, ModVars.NewLine, route, e, strjsonreq), ModVars.ADSNetLibraryLog);
}
@@ -495,7 +644,7 @@ namespace ADSNetLibraryzI.HelpersI.ConexionesI.SIGAPII
/// <param name="requestobject">request object.</param>
/// <returns>Lista de objetos.</returns>
//public T getData<T> (string path, object requestobject, requestMethod reqmet = requestMethod.POST, bool needauthorization = true, bool isfullpath = false) where T : class, new()
public T getData<T>(string path, object requestobject, requestMethod reqmet = requestMethod.POST, bool needauthorization = true, bool isfullpath = false) where T : class, new()
public T getData<T>(string path, object requestobject, requestMethod reqmet = requestMethod.POST, bool needauthorization = true, bool isfullpath = false) where T : class, new()
{
return AsyncHelper.RunSync<T>(() => getDataAsync<T>(path, requestobject, reqmet, needauthorization, isfullpath));
}