This commit is contained in:
2022-06-14 20:14:57 -07:00
13 changed files with 1486 additions and 896 deletions

View File

@@ -29,7 +29,7 @@ Public Class LogicNominas
ObjFactura.Folio = cfdi.Comprobante.Folio.ToEntero()
ObjFactura.Serie = cfdi.Comprobante.Serie
ObjFactura.Timbre = cfdi
If Not ObjTimbrado.TimbrarFactura(UsuarioActual, ObjFactura, CvePAC) Then
If Not ObjTimbrado.TimbrarFactura(UsuarioActual, ObjFactura, CvePAC, False) Then
Retorno = ObjTimbrado.MensajeErrorCFDI
End If
End If
@@ -139,6 +139,8 @@ Public Class LogicNominas
Dim ClaveEstado As String = ""
Dim MetodoPagoFijo As Boolean
Dim CodigoPostal As String = ""
Dim ObjIncapacidades As New List(Of CFDINominaIncapacidades)
'Conexiones a la Base de Datos
Dim cfdi As New CFDITimbre
@@ -175,7 +177,7 @@ Public Class LogicNominas
RFC = objPersonal.RFC
cfdi.Emisor.RegistroPatronal = objPersonal.DtResultados.Rows(0)("RegistroPatronal").ToString()
NombreCompleto = objPersonal.NombreCompleto
CodigoPostal = objPersonal.CP
Sindicalizado = objPersonal.DtResultados.Rows(0)("Sindicalizado").ToString().ToUpper().Contiene("TRUE", "1")
CURP = objPersonal.CURP
NumeroSS = objPersonal.NumeroSS
@@ -441,6 +443,10 @@ Public Class LogicNominas
cfdi.Comprobante.FormadePago = "99"
cfdi.Comprobante.LugarExpedicion = UsuarioActual.Empresa.CP.ToString() ' AHORITA SOLO SE REQUIERE ESPECIFICAR EL CODIGO POSTAL
cfdi.Comprobante.NumCuentaPago = "" 'objPersonal.BancoNumCuenta
'4.0
cfdi.Receptor.DomicilioFiscalReceptor = CodigoPostal
cfdi.Receptor.RegimenFiscalReceptor = "605"
cfdi.Nomina.Receptor.CURP = CURP
cfdi.Nomina.Receptor.NSS = NumeroSS

View File

@@ -1185,7 +1185,7 @@ Public Class Timbrado
Return Timbre
End Function
Public Function TimbrarFactura(UsuarioActual As Usuario, Ventas As Modelos.Factura, Optional CvePACEspecial As Integer = -1) As Boolean
Public Function TimbrarFactura(UsuarioActual As Usuario, Ventas As Modelos.Factura, Optional CvePACEspecial As Integer = -1, Optional NomUsaPac4 As Boolean = True) As Boolean
Dim Retorno As Boolean = False
Dim tCvePAC As Integer = UsuarioActual.Empresa.CvePAC
@@ -1221,7 +1221,7 @@ Public Class Timbrado
Retorno = If(Ret = "", True, False)
Case 3
If UsuarioActual.Empresa.Funcionalidad(350) = "1" Then
If UsuarioActual.Empresa.Funcionalidad(350) = "1" AndAlso NomUsaPac4 Then
Retorno = TimbrarFacturaProFactV40(UsuarioActual, Ventas)
Else
Retorno = TimbrarFacturaProFact(UsuarioActual, Ventas)
@@ -1229,7 +1229,7 @@ Public Class Timbrado
'Retorno = TimbrarFacturaProFact(UsuarioActual, Ventas, TmpDTConceptos, TmpDTImpuestos, TmpDTComplementos, Ruta, LstFordASN, FordGSDBM, ObjV)
Case 4
If UsuarioActual.Empresa.Funcionalidad(350) = "1" Then
If UsuarioActual.Empresa.Funcionalidad(350) = "1" AndAlso NomUsaPac4 Then
Dim Ret As String = TimbrarFacturaGoCFDIv40(Ventas, UsuarioActual, CvePACEspecial)
If Ret <> "" Then MensajeErrorCFDI = Ret
Retorno = If(Ret = "", True, False)
@@ -1241,7 +1241,7 @@ Public Class Timbrado
Case 5
If UsuarioActual.Empresa.Funcionalidad(350) = "1" Then
If UsuarioActual.Empresa.Funcionalidad(350) = "1" AndAlso NomUsaPac4 Then
Dim Ret As String = TimbrarFacturaPADEv40(Ventas, UsuarioActual, CvePACEspecial)
If Ret <> "" Then MensajeErrorCFDI = Ret
Retorno = If(Ret = "", True, False)

View File

@@ -63,6 +63,9 @@
<asp:LinkButton ID="lbDescargar" runat="server"><%--<img src="/Metronic/assets/global/img/portlet-reload-icon.png" />--%><i class="fa fa-download"></i>
Descarga Facturas SAT</asp:LinkButton>
</li>
<li>
<asp:LinkButton ID="LnkShowSolicitudes" OnClick="LnkShowSolicitudes_Click" runat="server">Solicitudes SAT</asp:LinkButton>
</li>
<li>
<asp:LinkButton ID="LnkBitacotaFacturas" runat="server" OnClick="LnkBitacotaFacturas_Click"><i class="fa fa-book" ></i> Bitácora Facturas</asp:LinkButton>
</li>
@@ -946,7 +949,199 @@
</ContentTemplate>
</asp:UpdatePanel>
</div>
<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">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal">&times;</button>
<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-yellow-gold"></i>
<span class="caption-subject font-yellow-gold 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>
</div>
<div class="portlet light xspadding bordered " id="PnlPendientes">
<div class="portlet-title">
<div class="caption ">
<i class="fa fa-bookmark font-yellow-gold"></i>
<span class="caption-subject font-yellow-gold 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-yellow-gold"></i>
<span class="caption-subject font-yellow-gold 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>
</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>
</contenttemplate>
</asp:UpdatePanel>
</div>
</asp:Content>
<asp:Content ID="Content7" ContentPlaceHolderID="JS" runat="Server">
<script type="text/javascript">

View File

@@ -2517,7 +2517,59 @@ Partial Class Compras_eFacturas
DTConceptos.Columns.Add("Total", GetType(Double))
End Sub
#End Region
#Region "Sat descargamasiva"
Private Sub cargasolicitudes()
Using nom As ClsNominas = New ClsNominas()
If nom.SolicitudesGet(-1, UsuarioActual.CveEmpresa, 2) Then
GVSolicitudesPendientes.DataSource = nom.DtResultados.FiltraParametros("Estatus =0")
GVSolicitudesPendientes.DataBind()
GVSolicitudesNominas.DataSource = nom.DtResultados.FiltraParametros("Estatus =1")
GVSolicitudesNominas.DataBind()
End If
End Using
UPModalViewSolicitudes.Update()
End Sub
Protected Sub LnkShowSolicitudes_Click(ByVal sender As Object, ByVal e As EventArgs)
cargasolicitudes()
Me.RegistraScript("$('#ModalViewSolicitudes').modal();")
End Sub
Protected Sub LnkSolicitarSat_Click(ByVal sender As Object, ByVal e As EventArgs)
Dim idSolicitudCFDI As Integer = 0
Dim idSolicitudMetadata As Integer = 0
Dim estatus As Integer = 0
Dim observaciones As String = ""
Dim fechaInicio As DateTime = txtFechaIAdd.Text.ToDateTime()
Dim fechaFin As DateTime = txtFechaFAdd.Text.ToDateTime()
Dim cveUsuarioIng As Integer = UsuarioActual.CveUsuario
Dim cveEmpresa As Integer = UsuarioActual.CveEmpresa
Dim Continuar As Boolean = False
Using nom As ClsNominas = New ClsNominas()
Continuar = nom.SolicitudesAdd(idSolicitudCFDI, idSolicitudMetadata, estatus, observaciones, fechaInicio, fechaFin, cveUsuarioIng, cveEmpresa, 2)
'Dim api = New GeneralesAPI()
'api.GeneraSolicitud()
'api.VerificaSolicitudesNominas()
End Using
If Continuar Then
txtFechaIAdd.Text = ""
txtFechaFAdd.Text = ""
Me.RegistraScript("$('#DModalSolicitudesNominas').modal('hide');")
cargasolicitudes()
Me.Alert("se a envia la solicitud al sat, le enviaremos un correo en cuanto tengamos una respuesta", ModExtensiones.TipoMensaje.ToastInformacion)
End If
End Sub
Protected Sub LnkverificarSolicitudes_Click(ByVal sender As Object, ByVal e As EventArgs)
'Dim api = New GeneralesAPI()
'api.GeneraSolicitud()
'api.VerificaSolicitudesNominas()
cargasolicitudes()
End Sub
#End Region
#Region "D E S C A R G A R - F A C T U R A "
Protected Sub lbDescargar_Click(sender As Object, e As EventArgs) Handles lbDescargar.Click

View File

@@ -1440,11 +1440,42 @@
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Reg.fiscal: </Value>
<Style>
<FontFamily>Myriad Pro</FontFamily>
<FontSize>9pt</FontSize>
<FontWeight>SemiBold</FontWeight>
</Style>
</TextRun>
<TextRun>
<Value xml:space="preserve"> </Value>
<Style>
<FontFamily>Myriad Pro</FontFamily>
<FontSize>9pt</FontSize>
<FontWeight>Normal</FontWeight>
</Style>
</TextRun>
<TextRun>
<Value>=Parameters!RegimenFiscalCodigo.Value</Value>
<Style>
<FontFamily>Myriad Pro</FontFamily>
<FontSize>8pt</FontSize>
<FontWeight>Normal</FontWeight>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox2</rd:DefaultName>
<Top>0.00137in</Top>
<Left>4.38498cm</Left>
<Height>1.62208in</Height>
<Height>1.80958in</Height>
<Width>3.6362in</Width>
<ZIndex>10</ZIndex>
<Style>
@@ -2421,7 +2452,15 @@
<Paragraph>
<TextRuns>
<TextRun>
<Value>VERSION 3.3</Value>
<Value>VERSION </Value>
<Style>
<FontFamily>MYRiad Pro</FontFamily>
<FontSize>9.16pt</FontSize>
<FontWeight>Bold</FontWeight>
</Style>
</TextRun>
<TextRun>
<Value>=Parameters!CFDIVersion.Value</Value>
<Style>
<FontFamily>MYRiad Pro</FontFamily>
<FontSize>9.16pt</FontSize>
@@ -2622,7 +2661,6 @@
<rd:DataSourceID>c220a38d-e45b-4e04-917e-7dfd9cc3345f</rd:DataSourceID>
</DataSource>
</DataSources>
<DataSets>
<DataSet Name="DsOC">
<Query>
@@ -3425,6 +3463,18 @@
<AllowBlank>true</AllowBlank>
<Prompt>ReportParameter1</Prompt>
</ReportParameter>
<ReportParameter Name="CFDIVersion">
<DataType>String</DataType>
<Nullable>true</Nullable>
<AllowBlank>true</AllowBlank>
<Prompt>ReportParameter1</Prompt>
</ReportParameter>
<ReportParameter Name="RegimenFiscalCodigo">
<DataType>String</DataType>
<Nullable>true</Nullable>
<AllowBlank>true</AllowBlank>
<Prompt>ReportParameter1</Prompt>
</ReportParameter>
</ReportParameters>
<EmbeddedImages>
<EmbeddedImage Name="Logo119">

View File

@@ -1782,6 +1782,7 @@
<TextRun>
<Value>Remolque 1</Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>7pt</FontSize>
<FontWeight>Bold</FontWeight>
</Style>
@@ -1789,24 +1790,28 @@
<TextRun>
<Value> Placa: </Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>7pt</FontSize>
</Style>
</TextRun>
<TextRun>
<Value>=Parameters!RemolquePlaca1.Value</Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>7pt</FontSize>
</Style>
</TextRun>
<TextRun>
<Value> Tipo Rem: </Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>7pt</FontSize>
</Style>
</TextRun>
<TextRun>
<Value>=Parameters!RemolqueSubtimo1.Value</Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>7pt</FontSize>
</Style>
</TextRun>
@@ -1842,6 +1847,7 @@
<TextRun>
<Value>Remolque 2</Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>7pt</FontSize>
<FontWeight>Bold</FontWeight>
</Style>
@@ -1849,24 +1855,28 @@
<TextRun>
<Value> Placa: </Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>7pt</FontSize>
</Style>
</TextRun>
<TextRun>
<Value>=Parameters!RemolquePlaca2.Value</Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>7pt</FontSize>
</Style>
</TextRun>
<TextRun>
<Value> Tipo Rem: </Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>7pt</FontSize>
</Style>
</TextRun>
<TextRun>
<Value>=Parameters!RemolqueSubtimo2.Value</Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>7pt</FontSize>
</Style>
</TextRun>

View File

@@ -141,7 +141,7 @@
<Top>1.43777in</Top>
<Left>0.27639cm</Left>
<Height>0.17222in</Height>
<Width>0.81128in</Width>
<Width>0.57108in</Width>
<ZIndex>2</ZIndex>
<Style>
<Border>
@@ -180,9 +180,9 @@
</Paragraphs>
<rd:DefaultName>Textbox19</rd:DefaultName>
<Top>1.43777in</Top>
<Left>0.93398in</Left>
<Left>0.67989in</Left>
<Height>0.17222in</Height>
<Width>3.24868in</Width>
<Width>3.44722in</Width>
<ZIndex>3</ZIndex>
<Style>
<Border>
@@ -1703,7 +1703,7 @@
</Paragraphs>
<rd:DefaultName>Textbox19</rd:DefaultName>
<Top>1.43777in</Top>
<Left>10.65925cm</Left>
<Left>10.53225cm</Left>
<Height>0.1875in</Height>
<Width>0.36336in</Width>
<ZIndex>20</ZIndex>
@@ -1745,9 +1745,9 @@
</Paragraphs>
<rd:DefaultName>Textbox19</rd:DefaultName>
<Top>1.43916in</Top>
<Left>4.55379in</Left>
<Left>4.50379in</Left>
<Height>0.18472in</Height>
<Width>1.12758in</Width>
<Width>0.93723in</Width>
<ZIndex>21</ZIndex>
<Style>
<Border>
@@ -1778,6 +1778,7 @@
<TextRun>
<Value>Uso CFDI:</Value>
<Style>
<FontFamily>Calibri</FontFamily>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
</Style>
@@ -1788,9 +1789,9 @@
</Paragraphs>
<rd:DefaultName>Textbox19</rd:DefaultName>
<Top>1.43777in</Top>
<Left>14.44108cm</Left>
<Left>13.86958cm</Left>
<Height>0.17222in</Height>
<Width>0.63582in</Width>
<Width>0.51158in</Width>
<ZIndex>22</ZIndex>
<Style>
<Border>
@@ -1830,9 +1831,9 @@
</Paragraphs>
<rd:DefaultName>Textbox19</rd:DefaultName>
<Top>1.43916in</Top>
<Left>6.36573in</Left>
<Left>5.98593in</Left>
<Height>0.17083in</Height>
<Width>1.55925in</Width>
<Width>1.97686in</Width>
<ZIndex>23</ZIndex>
<Style>
<Border>
@@ -1875,8 +1876,8 @@
<rd:DefaultName>Textbox19</rd:DefaultName>
<Top>1.62527in</Top>
<Left>0.27639cm</Left>
<Height>0.15972in</Height>
<Width>0.81128in</Width>
<Height>0.17083in</Height>
<Width>0.57108in</Width>
<ZIndex>24</ZIndex>
<Style>
<Border>
@@ -1898,6 +1899,7 @@
</Style>
</Textbox>
<Textbox Name="Textbox74">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
@@ -1915,24 +1917,15 @@
</Paragraphs>
<rd:DefaultName>Textbox19</rd:DefaultName>
<Top>1.62527in</Top>
<Left>0.92009in</Left>
<Height>0.15972in</Height>
<Width>4.18029in</Width>
<Left>0.67989in</Left>
<Height>0.17083in</Height>
<Width>3.44722in</Width>
<ZIndex>25</ZIndex>
<Style>
<Border>
<Color>White</Color>
<Style>None</Style>
</Border>
<TopBorder>
<Style>None</Style>
</TopBorder>
<LeftBorder>
<Style>None</Style>
</LeftBorder>
<RightBorder>
<Style>None</Style>
</RightBorder>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
@@ -2396,7 +2389,14 @@
<Paragraph>
<TextRuns>
<TextRun>
<Value>Este documento es una representación impresa de un CFDI Version 3.3</Value>
<Value>Este documento es una representación impresa de un CFDI Version </Value>
<Style>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
</Style>
</TextRun>
<TextRun>
<Value>=IIf(Parameters!CFDIVersion.Value = "4.0","4.0","3.3")</Value>
<Style>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
@@ -3288,6 +3288,94 @@
</Border>
</Style>
</Rectangle>
<Textbox Name="Textbox80">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Regimen Fiscal:</Value>
<Style>
<FontFamily>Calibri</FontFamily>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox19</rd:DefaultName>
<Top>1.62527in</Top>
<Left>10.5005cm</Left>
<Height>0.17222in</Height>
<Width>0.82757in</Width>
<ZIndex>48</ZIndex>
<Style>
<Border>
<Color>#4f81bd</Color>
<Style>None</Style>
</Border>
<TopBorder>
<Style>None</Style>
</TopBorder>
<LeftBorder>
<Style>None</Style>
</LeftBorder>
<RightBorder>
<Style>None</Style>
</RightBorder>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<Textbox Name="Textbox81">
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>=Parameters!RegimenFiscalCodigo.Value</Value>
<Style>
<FontFamily>Calibri</FontFamily>
<FontSize>8pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style />
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox19</rd:DefaultName>
<Top>1.62527in</Top>
<Left>4.96163in</Left>
<Height>0.17083in</Height>
<Width>3.00857in</Width>
<ZIndex>49</ZIndex>
<Style>
<Border>
<Color>White</Color>
<Style>None</Style>
</Border>
<TopBorder>
<Style>None</Style>
</TopBorder>
<LeftBorder>
<Style>None</Style>
</LeftBorder>
<RightBorder>
<Style>None</Style>
</RightBorder>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
</ReportItems>
<Height>14.35534cm</Height>
<Style />

View File

@@ -33,6 +33,14 @@
<DataField>Etiqueta</DataField>
<rd:TypeName>System.String</rd:TypeName>
</Field>
<Field Name="ImpManifiesto">
<DataField>ImpManifiesto</DataField>
<rd:TypeName>System.String</rd:TypeName>
</Field>
<Field Name="TipoTarima">
<DataField>TipoTarima</DataField>
<rd:TypeName>System.String</rd:TypeName>
</Field>
<Field Name="Envase">
<DataField>Envase</DataField>
<rd:TypeName>System.String</rd:TypeName>
@@ -215,12 +223,16 @@
<Paragraph>
<TextRuns>
<TextRun>
<Value>Empaque </Value>
<Style />
<Value>EMPAQUE </Value>
<Style>
<FontSize>9pt</FontSize>
</Style>
</TextRun>
<TextRun>
<Value>=Parameters!SubProyecto.Value</Value>
<Style />
<Style>
<FontSize>9pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style />
@@ -515,7 +527,7 @@
<Top>0.3175cm</Top>
<Left>9.78675cm</Left>
<Height>3cm</Height>
<Width>9.55022cm</Width>
<Width>9.55023cm</Width>
<Style>
<Border>
<Style>None</Style>
@@ -7291,7 +7303,7 @@
<Paragraph>
<TextRuns>
<TextRun>
<Value />
<Value>=IIf(Fields!ImpManifiesto.Value.ToString() ="1",Fields!TipoTarima.Value.ToString() ,"")</Value>
<Style>
<FontSize>8pt</FontSize>
</Style>
@@ -7312,6 +7324,7 @@
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<rd:Selected>true</rd:Selected>
</CellContents>
</TablixCell>
<TablixCell>
@@ -7456,7 +7469,7 @@
<Paragraph>
<TextRuns>
<TextRun>
<Value>Campo </Value>
<Value>CAMPO </Value>
<Style>
<FontSize>8pt</FontSize>
</Style>

View File

@@ -215,6 +215,9 @@
<li>
<asp:LinkButton ID="LnkTimbrarTodos" Visible="false" OnClick="LnkTimbrarTodos_Click" runat="server"><i class="fa fa-bell"></i> Timbrar todos</asp:LinkButton>
</li>
<li>
<asp:LinkButton ID="LnkReenviarcorreo" Visible="false" OnClick="LnkReenviarcorreo_Click" runat="server"><i class="fa fa-bell"></i> Renviar correo</asp:LinkButton>
</li>
<li>
<asp:LinkButton ID="LnkRegistrarProvision" Visible="false" OnClick="LnkRegistrarProvision_Click" runat="server" data-toggle="confirmation" data-popout="true" data-original-title="¿Está seguro que desea registrar provisión?" data-btn-ok-label="si"><i class="fa fa-thumbs-up" aria-hidden="true" ></i>Registrar provisión</asp:LinkButton>
</li>

View File

@@ -474,6 +474,7 @@ public partial class Nomina_Nomina2 : ClsPaginas
LnkCargaAsistenciaMasiva.Visible = (Estatus < 2);
LnkModalPlantillaNomina.Visible = true;
LnkTimbrarTodos.Visible = (Estatus > 2);
LnkReenviarcorreo.Visible = true;
LnkLayoutContable.Visible = (Estatus >= 2);
LnkProvisionNomina.Visible = CvePrePolizaProvision > 0;
@@ -1118,15 +1119,79 @@ public partial class Nomina_Nomina2 : ClsPaginas
}
#endregion
protected void LnkReenviarcorreo_Click(object sender, EventArgs e)
{
string msggral = "";
int CvePeriodo = 0;
ClsSisMail Mail = new ClsSisMail();
DataTable dtpersonal = new DataTable();
DataRow drow;
using (ClsRH objrh = new ClsRH())
{
objrh.GetPersonal(-1, UsuarioActual.CveEmpresa);
dtpersonal = objrh.DtResultados.FiltraParametros("", "", new string[] { "CvePersonal", "MaiReciboNomina", "NombreCompleto" });
}
foreach (GridViewRow gvRow in GvNominas.Rows)
{
CvePeriodo = gvRow.DataKey("CvePeriodo").ToEntero();
int CvePersonal = gvRow.DataKey("CvePersonal").ToEntero();
int CveNomina = gvRow.DataKey("CveNomina").ToEntero();
int SeTimbro = (gvRow.DataKey("SeTimbro").ToUpper()=="TRUE" ?1:gvRow.DataKey("SeTimbro").ToEntero());
LinkButton LnkTimbrar = gvRow.FCLinkButton("LnkTimbrar");
string MaiReciboNomina = string.Empty;
string NombreCompleto = string.Empty;
if (dtpersonal.Rows.Count > 0 && (drow = dtpersonal.FiltroPrimero(string.Format("CvePersonal = {0}", CvePersonal))) != null)
{
MaiReciboNomina = drow["MaiReciboNomina"].ToString();
NombreCompleto = drow["NombreCompleto"].ToString();
}
if (CvePersonal > 0 && SeTimbro==1)
{
if (MaiReciboNomina.Trim().Length > 0)
{
byte[] pdf = GeneraPDFNomina(CvePersonal, CvePeriodo, UsuarioActual.CveEmpresa, UsuarioActual.Empresa.Ruta);
if (pdf != null)
{
List<ClsSisMail.ArchivoMail> objarch = new List<ClsSisMail.ArchivoMail>();
objarch.Add(new ClsSisMail.ArchivoMail() { ArchivoBinario = pdf, NombreArchivo = "Nomina.pdf" });
Mail.SendMail(ClsPaginas.EmpresaNotificaciones, MaiReciboNomina.Trim(), string.Format("Empleado {0} Nomina del {1:dd/MM/yyyy} al {2:dd/MM/yyyy}", NombreCompleto, FechaInicioPeriodo, FechaFinPeriodo), "", "", objarch);
// Mail.SendMail(ClsPaginas.EmpresaNotificaciones, "caudillo.90d@gmail.com", string.Format("Empleado {0} Nomina del {1:dd/MM/yyyy} al {2:dd/MM/yyyy} ", NombreCompleto, FechaInicioPeriodo, FechaFinPeriodo), MaiReciboNomina.Trim(), "", objarch);
}
}
}
}
Alert("se reenviaron los recibos timbrados");
}
protected void LnkTimbrarTodos_Click(object sender, EventArgs e)
{
string msggral = "";
int CvePeriodo = 0;
ClsSisMail Mail = new ClsSisMail();
DataTable dtpersonal = new DataTable();
DataRow drow;
using (ClsRH objrh = new ClsRH())
{
objrh.GetPersonal(-1, UsuarioActual.CveEmpresa);
dtpersonal = objrh.DtResultados.FiltraParametros("", "", new string[] { "CvePersonal", "MaiReciboNomina", "NombreCompleto" });
}
foreach (GridViewRow gvRow in GvNominas.Rows)
{
int CvePeriodo = gvRow.DataKey("CvePeriodo").ToEntero();
CvePeriodo = gvRow.DataKey("CvePeriodo").ToEntero();
int CvePersonal = gvRow.DataKey("CvePersonal").ToEntero();
int CveNomina = gvRow.DataKey("CveNomina").ToEntero();
LinkButton LnkTimbrar = gvRow.FCLinkButton("LnkTimbrar");
string MaiReciboNomina = string.Empty;
string NombreCompleto = string.Empty;
if (dtpersonal.Rows.Count > 0 && (drow = dtpersonal.FiltroPrimero(string.Format("CvePersonal = {0}", CvePersonal))) != null)
{
MaiReciboNomina = drow["MaiReciboNomina"].ToString();
NombreCompleto = drow["NombreCompleto"].ToString();
}
if (CvePersonal > 0 && LnkTimbrar.Visible)
{
LogicNominas lognom = new LogicNominas();
@@ -1138,9 +1203,6 @@ public partial class Nomina_Nomina2 : ClsPaginas
}
else
{
ClsNominas ObjPeriodo = new ClsNominas();
ObjPeriodo.CambiaEstatusPeriodo(CvePeriodo, (int)enumNominasEstatus.Timbrada, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa);
ObjPeriodo.Dispose();
LnkTimbrar.Visible = false;
gvRow.CssClass = "success";
gvRow.FindControl("ImgDelete").Visible = false;
@@ -1149,6 +1211,21 @@ public partial class Nomina_Nomina2 : ClsPaginas
gvRow.FindControl("HypPDF").Visible = true;
gvRow.ForeColor = Color.Green;
if (MaiReciboNomina.Trim().Length > 0)
{
byte[] pdf = GeneraPDFNomina(CvePersonal, CvePeriodo, UsuarioActual.CveEmpresa, UsuarioActual.Empresa.Ruta);
if (pdf != null)
{
List<ClsSisMail.ArchivoMail> objarch = new List<ClsSisMail.ArchivoMail>();
objarch.Add(new ClsSisMail.ArchivoMail() { ArchivoBinario = pdf, NombreArchivo = "Nomina.pdf" });
Mail.SendMail(ClsPaginas.EmpresaNotificaciones, MaiReciboNomina.Trim(), string.Format("Empleado {0} Nomina del {1:dd/MM/yyyy} al {2:dd/MM/yyyy}", NombreCompleto, FechaInicioPeriodo, FechaFinPeriodo), "", "", objarch);
//Mail.SendMail(ClsPaginas.EmpresaNotificaciones, "caudillo.90d@gmail.com", string.Format("Empleado {0} Nomina del {1:dd/MM/yyyy} al {2:dd/MM/yyyy} ", NombreCompleto, FechaInicioPeriodo, FechaFinPeriodo), MaiReciboNomina.Trim(), "", objarch);
}
}
}
@@ -1159,6 +1236,14 @@ public partial class Nomina_Nomina2 : ClsPaginas
Alert(string.Format("Los siguientes empleados no se timbraron por las siguiente situaciones: <table class=\"table table-striped table-hover mysmallbtn\" ><tbody><tr><th>Código</th><th>Nombre</th><th>Mensaje SAT</th></tr>{0}</tbody></table>", msggral), TipoMensaje.MsgAdvertencia);
}
else
{
using (ClsNominas ObjPeriodo = new ClsNominas())
{
ObjPeriodo.CambiaEstatusPeriodo(CvePeriodo, (int)enumNominasEstatus.Timbrada, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa);
}
}
UpDatos.Update();
}
private void CreaObjetoEmpresa(ref Usuario UsuarioActual)
@@ -1192,6 +1277,24 @@ public partial class Nomina_Nomina2 : ClsPaginas
int CveNomina = gvRow.DataKey("CveNomina").ToEntero();
LogicNominas lognom = new LogicNominas();
Usuario UsuarioActual = null;
ClsSisMail Mail = new ClsSisMail();
DataTable dtpersonal = new DataTable();
DataRow drow;
string MaiReciboNomina = string.Empty;
string NombreCompleto = string.Empty;
if (dtpersonal.Rows.Count > 0 && (drow = dtpersonal.FiltroPrimero(string.Format("CvePersonal = {0}", CvePersonal))) != null)
{
MaiReciboNomina = drow["MaiReciboNomina"].ToString();
NombreCompleto = drow["NombreCompleto"].ToString();
}
using (ClsRH objrh = new ClsRH())
{
objrh.GetPersonal(-1, UsuarioActual.CveEmpresa);
dtpersonal = objrh.DtResultados.FiltraParametros("", "", new string[] { "CvePersonal", "MaiReciboNomina", "NombreCompleto" });
}
/*
if (EsProduccion == false)
{
@@ -1207,7 +1310,8 @@ public partial class Nomina_Nomina2 : ClsPaginas
else
{
UsuarioActual = this.UsuarioActual;
}
}*/
UsuarioActual = this.UsuarioActual;
string Msg = lognom.TimbrarNomina(CveNomina, CvePersonal, CvePeriodo, UsuarioActual);
if (Msg != null && Msg.Length > 0)
{ Alert(string.Format("El empleado no se pudo timbrar, el sat nos devolvio el siguiente mensaje:<br/>{0}", Msg), TipoMensaje.MsgAdvertencia); }
@@ -1216,6 +1320,18 @@ public partial class Nomina_Nomina2 : ClsPaginas
ClsNominas ObjPeriodo = new ClsNominas();
ObjPeriodo.CambiaEstatusPeriodo(CvePeriodo, (int)enumNominasEstatus.Timbrada, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa);
ObjPeriodo.Dispose();
if (MaiReciboNomina.Trim().Length > 0)
{
byte[] pdf = GeneraPDFNomina(CvePersonal, CvePeriodo, UsuarioActual.CveEmpresa, UsuarioActual.Empresa.Ruta);
if (pdf != null)
{
List<ClsSisMail.ArchivoMail> objarch = new List<ClsSisMail.ArchivoMail>();
objarch.Add(new ClsSisMail.ArchivoMail() { ArchivoBinario = pdf, NombreArchivo = "Nomina" });
Mail.SendMail(ClsPaginas.EmpresaNotificaciones, MaiReciboNomina.Trim(), string.Format("Empleado {0} Nomina del {1:dd/MM/yyyy} al {2:dd/MM/yyyy}", NombreCompleto, FechaInicioPeriodo, FechaFinPeriodo), "", "", objarch);
}
}
Alert("Se ha timbrado correctamente");
gvRow.FindControl("ImgDelete").Visible = false;
gvRow.FindControl("LnkCancelar").Visible = true;
@@ -3442,7 +3558,7 @@ public partial class Nomina_Nomina2 : ClsPaginas
urlfile = System.IO.Path.Combine(ModExtensiones.DirectorioBaseEmpresas, "Empresas/Grales/Formatos/SobreRecibo.rdlc");
}
ImprimirPDF(urlfile, lrds, parametros, "SobreRecibo", "PDF", null,Content_Disposition: "Inline");
ImprimirPDF(urlfile, lrds, parametros, "SobreRecibo", "PDF", null, Content_Disposition: "Inline");
}
protected void BtnGuardarInfornavit_Click(object sender, EventArgs e)
{
@@ -8110,8 +8226,8 @@ public partial class Nomina_Nomina2 : ClsPaginas
#region Layouts
enum Bancos
enum Bancos
{
SinSelccion,
Bancomer,
@@ -8121,29 +8237,33 @@ public partial class Nomina_Nomina2 : ClsPaginas
Bancos Banco
{
get {
get
{
if (ViewState["Banco"] == null)
{
ViewState["Banco"] = Bancos.SinSelccion;
}
return (Bancos) ViewState["Banco"];
return (Bancos)ViewState["Banco"];
}
set {
ViewState["Banco"] = (Bancos) value;
set
{
ViewState["Banco"] = (Bancos)value;
}
}
string ConvenioPagoElectronico
{
get {
get
{
if (ViewState["ConvenioPagoElectronico"] == null)
{
ViewState["ConvenioPagoElectronico"] = string.Empty;
}
return ViewState["ConvenioPagoElectronico"].ToString();
return ViewState["ConvenioPagoElectronico"].ToString();
}
set {
ViewState["ConvenioPagoElectronico"] = (string) value;
set
{
ViewState["ConvenioPagoElectronico"] = (string)value;
}
}
@@ -8153,7 +8273,7 @@ public partial class Nomina_Nomina2 : ClsPaginas
// RBLModalBancosLayout.SelectedValue = "1";
Banco = Bancos.SinSelccion;
CargaCuentas();
this.RegistraScript("$('#ModalLayoutBancos').modal('show');");
UpModalBancosLayout.Update();
}
@@ -8162,7 +8282,7 @@ public partial class Nomina_Nomina2 : ClsPaginas
{
DdlCuenta.Items.Clear();
DataTable DTCuentas = get_GlobalDTBancosCuentas(UsuarioActual.CveUsuario, CveEmpresa: UsuarioActual.CveEmpresa).FiltraParametros(" CveTipoCuenta <> 1 AND UsaLayout = 'True' AND LEN(ConvenioPagoElectronico) > 0 ");
DataTable DTCuentas = get_GlobalDTBancosCuentas(UsuarioActual.CveUsuario, CveEmpresa: UsuarioActual.CveEmpresa).FiltraParametros(" CveTipoCuenta <> 1 AND UsaLayout = 'True' AND LEN(ConvenioPagoElectronico) > 0 ");
DTCuentas.CaseSensitive = false;
DdlCuenta.DataSource = DTCuentas.FiltraParametros(" Banco IN('BANCOMER','BANORTE')");
DdlCuenta.DataBind();
@@ -8184,8 +8304,9 @@ public partial class Nomina_Nomina2 : ClsPaginas
if (DdlCuenta.SelectedItem.Text.ToUpper().Contains("BANCOMER"))
{
Banco = Bancos.Bancomer;
}else if (DdlCuenta.SelectedItem.Text.ToUpper().Contains("BANORTE"))
}
else if (DdlCuenta.SelectedItem.Text.ToUpper().Contains("BANORTE"))
{
Banco = Bancos.Banorte;
}
@@ -8200,14 +8321,14 @@ public partial class Nomina_Nomina2 : ClsPaginas
Banco = Bancos.SinSelccion;
}
}
protected void BtnModalBancosProcesar_Click(object sender, EventArgs e)
{
if (Banco == Bancos.Bancomer)
{
using (ClsNominas objnom = new ClsNominas())
@@ -8230,7 +8351,7 @@ public partial class Nomina_Nomina2 : ClsPaginas
}
}
}
@@ -8328,7 +8449,7 @@ public partial class Nomina_Nomina2 : ClsPaginas
Alert(SbErrores.ToString(), TipoMensaje.MsgAdvertencia);
}
private void CrearLayoutNominaBanorte(DataTable DTNomina, string Emisora, int Consecutivo )
private void CrearLayoutNominaBanorte(DataTable DTNomina, string Emisora, int Consecutivo)
{
StringBuilder sb = new StringBuilder();
StringBuilder SbErrores = new StringBuilder();
@@ -8436,7 +8557,7 @@ public partial class Nomina_Nomina2 : ClsPaginas
{
sb.AppendLine("");
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -2630,7 +2630,9 @@ Partial Class Ventas
If Request("CveEmbarqueManifiesto") IsNot Nothing AndAlso IsNumeric(Request("CveEmbarqueManifiesto")) AndAlso Request("CveEmbarqueManifiesto").ToEntero() > 0 Then
DdlMoneda.SelectedValueExist(2)
Using ObjVentas As New ClsNominas
If ObjVentas.EmbarqueManifiestoGet(-1, -1, -1, Request("CveEmbarqueManifiesto").ToString().ToEntero()) And ObjVentas.DtResultados.Rows.Count > 0 Then
DdlSubProyectoDatos.SelectedValueExist(ObjVentas.DtResultados.Rows(0)("CveSubProyecto").ToString())
End If
If ObjVentas.ManifiestoForVtaGet(UsuarioActual.CveEmpresa, UsuarioActual.CveUsuario, "", Request("CveEmbarqueManifiesto").ToEntero()) Then
TmpDT = ObjVentas.DtResultados
TmpDT.Columns.Add("EntregaDirecta", GetType(Integer))
@@ -31428,6 +31430,10 @@ Partial Class Ventas
DdlTipoRetencion.Visible = True
End If
If DivCartaPorte.Visible Then
HabilitarControlesCartaPorte(True)
End If
UpnTools.Update()
UpCliente.Update()
UpParametros.Update()
@@ -31441,7 +31447,7 @@ Partial Class Ventas
UpParametros.Update()
UpINV.Update()
UpFacturasRelacionadas.Update()
UpEmitirTransitorio.Update()
End Sub
#End Region
@@ -34065,12 +34071,12 @@ Partial Class Ventas
ValidaConfiguracionVehiculo()
End Sub
Public Sub CargaVentaCortePorte(CveVenta As Integer)
TxtFechaEntregaCP.Enabled = False
TxtFechaLlegadaCP.Enabled = False
Dim CveEntregaAlmacen As Integer = -1
Dim CveDireccionOrigen As Integer = -1
Dim CveDireccionDestino As Integer = -1
Dim CveCamionRemolque1 As Integer = -1
Dim CveCamionRemolque2 As Integer = -1
Dim CveConfigAutoTransporte As Integer = -1
Using ObjGral As New ClsGenerales
If ObjGral.GetGralTimbre(-1, "Ing", MinFecha, MaxFecha, 0, UsuarioActual.CveEmpresa, -1, CveVenta:=CveVenta) AndAlso ObjGral.DtResultados.Rows.Count > 0 Then
@@ -34079,20 +34085,24 @@ Partial Class Ventas
Me.CveTimbreCartaPorteVenta = RowCP("CveTimbre").ToString().ToEntero()
If CveTimbreCartaPorteVenta > 0 Then
ChkEmitirCartaPorte.Checked = True
ChkEmitirCartaPorte.Enabled = False
CveEntregaAlmacen = RowCP("CveEntregaAlmacen").ToString().ToEntero()
CveDireccionOrigen = RowCP("CveDireccionOrigen").ToString().ToEntero()
CveDireccionDestino = RowCP("CveDireccionDestino").ToString().ToEntero()
TxtFechaEntregaCP.Text = RowCP("FechaEntrega").ToString()
TxtFechaLlegadaCP.Text = RowCP("FechaLlegada").ToString()
TxtFechaEntregaCP.Text = RowCP("FechaEntrega").ToString().ToDateTime().ToString("dd/MM/yyyy HH:mm")
TxtFechaLlegadaCP.Text = RowCP("FechaLlegada").ToString().ToDateTime().ToString("dd/MM/yyyy HH:mm")
TxtDistancia.Text = RowCP("Distancia").ToString()
DdlChofer.SelectedValueExist(RowCP("CveChofer").ToString())
DdlUnidadCamion.SelectedValueExist(RowCP("CveCamion").ToString())
CveCamionRemolque1 = RowCP("CveCamionRemolque1").ToString().ToEntero()
CveCamionRemolque2 = RowCP("CveCamionRemolque2").ToString().ToEntero()
CveConfigAutoTransporte = RowCP("CveConfigAutoTransporte").ToString().ToEntero()
End If
End If
@@ -34101,7 +34111,6 @@ Partial Class Ventas
DtMercancias = ObjGral.DtResultados
End If
End Using
If ChkEmitirCartaPorte.Checked AndAlso CveCliente > 0 Then
@@ -34122,18 +34131,54 @@ Partial Class Ventas
GvMercanciasCP.DataSource = DtMercancias
GvMercanciasCP.DataBind()
If DdlUnidadCamion.SelectedValue.ToEntero() > 0 Then
If CveConfigAutoTransporte > 0 Then
DvRemolque1.Visible = False
DvRemolque2.Visible = False
DdlRemolque1.SelectedValueExist(-1)
DdlRemolque2.SelectedValueExist(-1)
DdlConfigAuto.SelectedValueExist(CveConfigAutoTransporte.ToString())
DdlConfigAuto_SelectedIndexChanged(DdlConfigAuto, EventArgs.Empty)
If CveCamionRemolque1 > 0 Then
DdlRemolque1.SelectedValueExist(CveCamionRemolque1.ToString())
DdlRemolque1_SelectedIndexChanged(DdlRemolque1, EventArgs.Empty)
If CveCamionRemolque2 > 0 Then
DdlRemolque2.SelectedValueExist(CveCamionRemolque2.ToString())
End If
End If
End If
End If
Else
TmpDTDireccionCP = Nothing
End If
DdlChofer.Enabled = False
DdlUnidadCamion.Enabled = False
DdlDireccionOrigen.Enabled = False
DdlDireccionDestino.Enabled = False
HabilitarControlesCartaPorte(False)
UpEmitirTransitorio.Update()
End Sub
Private Sub HabilitarControlesCartaPorte(Habilitar As Boolean)
ChkEmitirCartaPorte.Enabled = Habilitar
TxtFechaEntregaCP.Enabled = Habilitar
TxtFechaLlegadaCP.Enabled = Habilitar
DdlChofer.Enabled = Habilitar
DdlUnidadCamion.Enabled = Habilitar
DdlConfigAuto.Enabled = Habilitar
DdlRemolque1.Enabled = Habilitar
DdlRemolque2.Enabled = Habilitar
DdlDireccionOrigen.Enabled = Habilitar
DdlDireccionDestino.Enabled = Habilitar
TxtDistancia.Enabled = Habilitar
LnkAgregarMercancia.Enabled = Habilitar
GvMercanciasCP.Columns(3).Visible = Habilitar
End Sub
Private Sub ValidaConfiguracionVehiculo()
DvRemolque1.Visible = False
DvRemolque2.Visible = False
@@ -34291,93 +34336,93 @@ Partial Class Ventas
End Set
End Property
Property SucursalOrigenCP As Modelos.SucursalModel
Get
If ViewState("SucursalOrigenCP") Is Nothing Then
Return Nothing
End If
Return DirectCast(ViewState("SucursalOrigenCP"), Modelos.SucursalModel)
End Get
Set(value As Modelos.SucursalModel)
ViewState("SucursalOrigenCP") = value
End Set
End Property
Property SucursalDestinoCP As Modelos.SucursalModel
Get
If ViewState("SucursalDestinoCP") Is Nothing Then
Return Nothing
End If
Return DirectCast(ViewState("SucursalDestinoCP"), Modelos.SucursalModel)
End Get
Set(value As Modelos.SucursalModel)
ViewState("SucursalDestinoCP") = value
End Set
End Property
'Property SucursalOrigenCP As Modelos.SucursalModel
' Get
' If ViewState("SucursalOrigenCP") Is Nothing Then
' Return Nothing
' End If
' Return DirectCast(ViewState("SucursalOrigenCP"), Modelos.SucursalModel)
' End Get
' Set(value As Modelos.SucursalModel)
' ViewState("SucursalOrigenCP") = value
' End Set
'End Property
'Property SucursalDestinoCP As Modelos.SucursalModel
' Get
' If ViewState("SucursalDestinoCP") Is Nothing Then
' Return Nothing
' End If
' Return DirectCast(ViewState("SucursalDestinoCP"), Modelos.SucursalModel)
' End Get
' Set(value As Modelos.SucursalModel)
' ViewState("SucursalDestinoCP") = value
' End Set
'End Property
Private Sub CargaDireccionSucursalOrigen(Row As DataRow)
If SucursalOrigenCP Is Nothing Then
SucursalOrigenCP = New Modelos.SucursalModel
Else
SucursalOrigenCP = Nothing
SucursalOrigenCP = New Modelos.SucursalModel
End If
'Private Sub CargaDireccionSucursalOrigen(Row As DataRow)
' If SucursalOrigenCP Is Nothing Then
' SucursalOrigenCP = New Modelos.SucursalModel
' Else
' SucursalOrigenCP = Nothing
' SucursalOrigenCP = New Modelos.SucursalModel
' End If
Dim SBDomicilioSucursal As New StringBuilder()
Try
If Row IsNot Nothing Then
' Dim SBDomicilioSucursal As New StringBuilder()
' Try
' If Row IsNot Nothing Then
SucursalOrigenCP.Direccion = Row("Calle").ToString()
SucursalOrigenCP.NoExt = Row("NoExt").ToString()
SucursalOrigenCP.NoInt = Row("NoInt").ToString()
SucursalOrigenCP.Colonia = Row("Colonia").ToString()
SucursalOrigenCP.CP = Row("CP").ToString()
SucursalOrigenCP.Municipio = Row("Municipio").ToString()
SucursalOrigenCP.CveEstado = Row("CveEstado").ToString().ToEntero()
SucursalOrigenCP.Estado = Row("Estado").ToString()
SucursalOrigenCP.CvePais = Row("CvePais").ToString().ToEntero()
SucursalOrigenCP.Pais = Row("Pais").ToString()
' SucursalOrigenCP.Direccion = Row("Calle").ToString()
' SucursalOrigenCP.NoExt = Row("NoExt").ToString()
' SucursalOrigenCP.NoInt = Row("NoInt").ToString()
' SucursalOrigenCP.Colonia = Row("Colonia").ToString()
' SucursalOrigenCP.CP = Row("CP").ToString()
' SucursalOrigenCP.Municipio = Row("Municipio").ToString()
' SucursalOrigenCP.CveEstado = Row("CveEstado").ToString().ToEntero()
' SucursalOrigenCP.Estado = Row("Estado").ToString()
' SucursalOrigenCP.CvePais = Row("CvePais").ToString().ToEntero()
' SucursalOrigenCP.Pais = Row("Pais").ToString()
SBDomicilioSucursal.AppendFormat("{0}", Row("Calle").ToString())
' SBDomicilioSucursal.AppendFormat("{0}", Row("Calle").ToString())
If Row("NoInt").ToString().Length > 0 Then
SBDomicilioSucursal.AppendFormat(", No.Int: {0}", Row("NoInt").ToString())
End If
' If Row("NoInt").ToString().Length > 0 Then
' SBDomicilioSucursal.AppendFormat(", No.Int: {0}", Row("NoInt").ToString())
' End If
If Row("Colonia").ToString().Length > 0 Then
SBDomicilioSucursal.AppendFormat(", Col: {0}", Row("Colonia").ToString())
End If
' If Row("Colonia").ToString().Length > 0 Then
' SBDomicilioSucursal.AppendFormat(", Col: {0}", Row("Colonia").ToString())
' End If
If Row("CP").ToString().ToEntero > 0 Then
SBDomicilioSucursal.AppendFormat(", CP: {0}", Row("CP").ToString())
End If
' If Row("CP").ToString().ToEntero > 0 Then
' SBDomicilioSucursal.AppendFormat(", CP: {0}", Row("CP").ToString())
' End If
If Row("NoExt").ToString().Length > 0 Then
SBDomicilioSucursal.AppendFormat(" No.Ext: {0}", Row("NoExt").ToString())
End If
' If Row("NoExt").ToString().Length > 0 Then
' SBDomicilioSucursal.AppendFormat(" No.Ext: {0}", Row("NoExt").ToString())
' End If
Dim CiudadSucursal As String = String.Format("{0},{1}", Row("Municipio").ToString(), Row("Estado").ToString())
If CiudadSucursal.Length > 0 Then
SBDomicilioSucursal.AppendFormat(", {0}", CiudadSucursal)
End If
' Dim CiudadSucursal As String = String.Format("{0},{1}", Row("Municipio").ToString(), Row("Estado").ToString())
' If CiudadSucursal.Length > 0 Then
' SBDomicilioSucursal.AppendFormat(", {0}", CiudadSucursal)
' End If
If Row("Pais").ToString().Length > 0 Then
SBDomicilioSucursal.AppendFormat(", {0}", Row("Pais").ToString())
End If
' If Row("Pais").ToString().Length > 0 Then
' SBDomicilioSucursal.AppendFormat(", {0}", Row("Pais").ToString())
' End If
If Not String.IsNullOrEmpty(Row("Telefono").ToString()) Then
SucursalOrigenCP.TelefonoSucursal = Row("Telefono").ToString()
End If
End If
' If Not String.IsNullOrEmpty(Row("Telefono").ToString()) Then
' SucursalOrigenCP.TelefonoSucursal = Row("Telefono").ToString()
' End If
' End If
Catch ex As Exception
SBDomicilioSucursal.Clear()
GuardaLog(ex.ToString())
End Try
' Catch ex As Exception
' SBDomicilioSucursal.Clear()
' GuardaLog(ex.ToString())
' End Try
'TxtOrigenCP.Text = SBDomicilioSucursal.ToString
' 'TxtOrigenCP.Text = SBDomicilioSucursal.ToString
UpEmitirTransitorio.Update()
End Sub
' UpEmitirTransitorio.Update()
'End Sub
Protected Sub DdlDireccionEnvio_SelectedIndexChanged(sender As Object, e As EventArgs)
'If SucursalDestinoCP Is Nothing Then
@@ -34413,73 +34458,73 @@ Partial Class Ventas
UpEmitirTransitorio.Update()
End Sub
Protected Sub DdlDireccionOrigen_SelectedIndexChanged(sender As Object, e As EventArgs)
If SucursalOrigenCP Is Nothing Then
SucursalOrigenCP = New Modelos.SucursalModel
Else
SucursalOrigenCP = Nothing
SucursalOrigenCP = New Modelos.SucursalModel
End If
'Protected Sub DdlDireccionOrigen_SelectedIndexChanged(sender As Object, e As EventArgs)
' If SucursalOrigenCP Is Nothing Then
' SucursalOrigenCP = New Modelos.SucursalModel
' Else
' SucursalOrigenCP = Nothing
' SucursalOrigenCP = New Modelos.SucursalModel
' End If
If TmpDTDireccionCP IsNot Nothing AndAlso TmpDTDireccionCP.FiltraParametros(String.Format("CveDireccionEnvio = {0}", DdlDireccionOrigen.SelectedValue.ToEntero())).Rows.Count > 0 Then
' If TmpDTDireccionCP IsNot Nothing AndAlso TmpDTDireccionCP.FiltraParametros(String.Format("CveDireccionEnvio = {0}", DdlDireccionOrigen.SelectedValue.ToEntero())).Rows.Count > 0 Then
Dim Row As DataRow = TmpDTDireccionCP.FiltroPrimero(String.Format("CveDireccionEnvio = {0}", DdlDireccionOrigen.SelectedValue.ToEntero()))
If Row IsNot Nothing Then
' Dim Row As DataRow = TmpDTDireccionCP.FiltroPrimero(String.Format("CveDireccionEnvio = {0}", DdlDireccionOrigen.SelectedValue.ToEntero()))
' If Row IsNot Nothing Then
SucursalOrigenCP.Direccion = Row("EnvioDireccion").ToString()
SucursalOrigenCP.Colonia = Row("EnvioColonia").ToString()
SucursalOrigenCP.Municipio = Row("EnvioCiudad").ToString()
SucursalOrigenCP.CveEstado = Row("CveEstado").ToString().ToEntero()
SucursalOrigenCP.Estado = Row("EnvioEstado").ToString()
SucursalOrigenCP.CvePais = Row("CvePais").ToString().ToEntero()
SucursalOrigenCP.Pais = Row("Pais").ToString()
SucursalOrigenCP.CP = Row("EnvioCP").ToString()
' SucursalOrigenCP.Direccion = Row("EnvioDireccion").ToString()
' SucursalOrigenCP.Colonia = Row("EnvioColonia").ToString()
' SucursalOrigenCP.Municipio = Row("EnvioCiudad").ToString()
' SucursalOrigenCP.CveEstado = Row("CveEstado").ToString().ToEntero()
' SucursalOrigenCP.Estado = Row("EnvioEstado").ToString()
' SucursalOrigenCP.CvePais = Row("CvePais").ToString().ToEntero()
' SucursalOrigenCP.Pais = Row("Pais").ToString()
' SucursalOrigenCP.CP = Row("EnvioCP").ToString()
'TxtDestinoCP.Text = String.Format("{0} col. {1},CP:{2}, {3},{4},{5}", SucursalDestinoCP.Direccion, SucursalDestinoCP.Colonia, SucursalDestinoCP.CP, SucursalDestinoCP.Municipio, SucursalDestinoCP.Estado, SucursalDestinoCP.Pais)
Else
'TxtDestinoCP.Text = ""
End If
Else
'TxtDestinoCP.Text = ""
End If
' 'TxtDestinoCP.Text = String.Format("{0} col. {1},CP:{2}, {3},{4},{5}", SucursalDestinoCP.Direccion, SucursalDestinoCP.Colonia, SucursalDestinoCP.CP, SucursalDestinoCP.Municipio, SucursalDestinoCP.Estado, SucursalDestinoCP.Pais)
' Else
' 'TxtDestinoCP.Text = ""
' End If
' Else
' 'TxtDestinoCP.Text = ""
' End If
UpEmitirTransitorio.Update()
End Sub
' UpEmitirTransitorio.Update()
'End Sub
Protected Sub DdlDireccionDestino_SelectedIndexChanged(sender As Object, e As EventArgs)
If SucursalDestinoCP Is Nothing Then
SucursalDestinoCP = New Modelos.SucursalModel
Else
SucursalDestinoCP = Nothing
SucursalDestinoCP = New Modelos.SucursalModel
End If
'Protected Sub DdlDireccionDestino_SelectedIndexChanged(sender As Object, e As EventArgs)
' If SucursalDestinoCP Is Nothing Then
' SucursalDestinoCP = New Modelos.SucursalModel
' Else
' SucursalDestinoCP = Nothing
' SucursalDestinoCP = New Modelos.SucursalModel
' End If
If TmpDTDireccionCP IsNot Nothing AndAlso TmpDTDireccionCP.FiltraParametros(String.Format("CveDireccionEnvio = {0}", DdlDireccionDestino.SelectedValue.ToEntero())).Rows.Count > 0 Then
' If TmpDTDireccionCP IsNot Nothing AndAlso TmpDTDireccionCP.FiltraParametros(String.Format("CveDireccionEnvio = {0}", DdlDireccionDestino.SelectedValue.ToEntero())).Rows.Count > 0 Then
Dim Row As DataRow = TmpDTDireccionCP.FiltroPrimero(String.Format("CveDireccionEnvio = {0}", DdlDireccionDestino.SelectedValue.ToEntero()))
If Row IsNot Nothing Then
' Dim Row As DataRow = TmpDTDireccionCP.FiltroPrimero(String.Format("CveDireccionEnvio = {0}", DdlDireccionDestino.SelectedValue.ToEntero()))
' If Row IsNot Nothing Then
SucursalDestinoCP.Direccion = Row("EnvioDireccion").ToString()
SucursalDestinoCP.Colonia = Row("EnvioColonia").ToString()
SucursalDestinoCP.Municipio = Row("EnvioCiudad").ToString()
SucursalDestinoCP.CveEstado = Row("CveEstado").ToString().ToEntero()
SucursalDestinoCP.Estado = Row("EnvioEstado").ToString()
SucursalDestinoCP.CvePais = Row("CvePais").ToString().ToEntero()
SucursalDestinoCP.Pais = Row("Pais").ToString()
SucursalDestinoCP.CP = Row("EnvioCP").ToString()
' SucursalDestinoCP.Direccion = Row("EnvioDireccion").ToString()
' SucursalDestinoCP.Colonia = Row("EnvioColonia").ToString()
' SucursalDestinoCP.Municipio = Row("EnvioCiudad").ToString()
' SucursalDestinoCP.CveEstado = Row("CveEstado").ToString().ToEntero()
' SucursalDestinoCP.Estado = Row("EnvioEstado").ToString()
' SucursalDestinoCP.CvePais = Row("CvePais").ToString().ToEntero()
' SucursalDestinoCP.Pais = Row("Pais").ToString()
' SucursalDestinoCP.CP = Row("EnvioCP").ToString()
'TxtDestinoCP.Text = String.Format("{0} col. {1},CP:{2}, {3},{4},{5}", SucursalDestinoCP.Direccion, SucursalDestinoCP.Colonia, SucursalDestinoCP.CP, SucursalDestinoCP.Municipio, SucursalDestinoCP.Estado, SucursalDestinoCP.Pais)
Else
'TxtDestinoCP.Text = ""
End If
Else
'TxtDestinoCP.Text = ""
End If
' 'TxtDestinoCP.Text = String.Format("{0} col. {1},CP:{2}, {3},{4},{5}", SucursalDestinoCP.Direccion, SucursalDestinoCP.Colonia, SucursalDestinoCP.CP, SucursalDestinoCP.Municipio, SucursalDestinoCP.Estado, SucursalDestinoCP.Pais)
' Else
' 'TxtDestinoCP.Text = ""
' End If
' Else
' 'TxtDestinoCP.Text = ""
' End If
UpEmitirTransitorio.Update()
End Sub
' UpEmitirTransitorio.Update()
'End Sub
Protected Sub LnkAgregarMercancia_Click(sender As Object, e As EventArgs)
TxtCantidadMercancia.Text = ""
'DdlPSMercancia.SelectedValue = ""

View File

@@ -500,6 +500,10 @@