diff --git a/AC/RegNomina.aspx.vb b/AC/RegNomina.aspx.vb index a85fa5425..7568b2c12 100644 --- a/AC/RegNomina.aspx.vb +++ b/AC/RegNomina.aspx.vb @@ -421,9 +421,6 @@ Partial Class AC_RegNomina End If End If - - Dim drt As DataRow - IDPoliza = objAC.AddPoliza(3, TxtConcepto.Text.Trim, 0, 0, UsuarioActual.CveUsuario, Fecha) If IDPoliza > 0 Then diff --git a/App_Code/ClsContabilidad.vb b/App_Code/ClsContabilidad.vb index fbf0a6182..dd6e58ab7 100644 --- a/App_Code/ClsContabilidad.vb +++ b/App_Code/ClsContabilidad.vb @@ -258,7 +258,7 @@ Public Class ClsContabilidad Public Function UpdatePrePolizasDetalle(CvePrePolizaDetalle As Integer, Concepto As String, CveSubProyecto As Integer, IdCtaContable As Integer, TipoMovto As Boolean, ImporteMN As Decimal, Optional CveTipoGasto As Integer = -1, Optional CveConceptoContable As Integer = -1, Optional CveProveedor As Integer = -1, Optional CveCompra As Integer = -1, Optional CvePersonal As Integer = -1, Optional CveCliente As Integer = -1, Optional CveVenta As Integer = -1, - Optional Referencia As String = "-1", Optional CveUsuarioModifico As Integer = -1, Optional CveCuenta As Integer = -1) As Boolean + Optional Referencia As String = "-1", Optional CveUsuarioModifico As Integer = -1, Optional CveCuenta As Integer = -1, Optional PorcentajeImpuesto As Decimal = -1) As Boolean Dim Retorno As Boolean = False @@ -279,6 +279,7 @@ Public Class ClsContabilidad .Add("@CvePersonal", SqlDbType.Int).Value = CvePersonal .Add("@CveCliente", SqlDbType.Int).Value = CveCliente .Add("@CveVenta", SqlDbType.Int).Value = CveVenta + .Add("@PorcentajeImpuesto", SqlDbType.Money).Value = PorcentajeImpuesto .Add("@CveUsuarioModifico", SqlDbType.Int).Value = CveUsuarioModifico .Add("@CveCuenta", SqlDbType.Int).Value = CveCuenta End With diff --git a/App_Code/modExtensiones.vb b/App_Code/modExtensiones.vb index 2f4fb03ae..95863dc34 100644 --- a/App_Code/modExtensiones.vb +++ b/App_Code/modExtensiones.vb @@ -3433,16 +3433,16 @@ Namespace Extensiones Public Class Archivo Public Sub New() filename = "" - patch = "Temp\" + path = "Temp\" descripcion = "" End Sub Public Property filename As String - Public Property patch As String + Public Property path As String Public Property descripcion As String - Public ReadOnly Property Extencion As String + Public ReadOnly Property Extension As String Get - Return IO.Path.GetExtension(String.Format("{0}{1}{2}", If(patch.Contains("Empresas"), ModExtensiones.DirectorioBaseEmpresas, AppDomain.CurrentDomain.BaseDirectory), patch, filename)).Replace(".", "") + Return IO.Path.GetExtension(String.Format("{0}{1}{2}", If(path.Contains("Empresas"), ModExtensiones.DirectorioBaseEmpresas, AppDomain.CurrentDomain.BaseDirectory), path, filename)).Replace(".", "") End Get End Property Public ReadOnly Property filenameO As String @@ -3452,7 +3452,7 @@ Namespace Extensiones End Property Public ReadOnly Property FileUrl As String Get - Return String.Format("{0}{1}{2}", If(patch.Contains("Empresas"), ModExtensiones.DirectorioBaseEmpresas, AppDomain.CurrentDomain.BaseDirectory), patch, filename) + Return String.Format("{0}{1}{2}", If(path.Contains("Empresas"), ModExtensiones.DirectorioBaseEmpresas, AppDomain.CurrentDomain.BaseDirectory), path, filename) End Get End Property End Class diff --git a/Ashx/E48.ashx b/Ashx/E48.ashx index a3d8a1d15..385fd6efe 100644 --- a/Ashx/E48.ashx +++ b/Ashx/E48.ashx @@ -445,7 +445,7 @@ Public Class E48 : Implements IHttpHandler, IRequiresSessionState Property GlobalDTAlmacen(CveEmpresa As Integer, Optional CveTipoAlmacen As Integer = -1, Optional CveEstatus As Integer = 1, Optional CveAlmacen As Integer = -1) As DataTable Get Dim AppNombre As String = String.Format("GlobalDTAlmacen-{0}", CveEmpresa) - Dim dttemp As DataTable + Dim dttemp As DataTable = Nothing 'sino existe, recarga los datos Dim ObjUsr As New ClsInventarios If ObjUsr.GetAlmacenes(-1, -1, CveEmpresa, -1) Then dttemp = ObjUsr.DtResultados diff --git a/Ashx/SIGFacturacionCiclica.ashx b/Ashx/SIGFacturacionCiclica.ashx index 35541349c..63fd22d9f 100644 --- a/Ashx/SIGFacturacionCiclica.ashx +++ b/Ashx/SIGFacturacionCiclica.ashx @@ -343,7 +343,7 @@ Public Class SIGFacturacionCiclica : Implements IHttpHandler, IRequiresSessionSt Dim DtDetalle As DataTable = Nothing Dim objContratos As New ClsContratos - If objContratos.GetContratosDetalle(DR("CveContrato").ToString.ToEntero) Then + If objContratos.GetContratosDetalle(DR("CveContrato").ToString.ToEntero, UsuarioActual.CveUsuario) Then DtDetalle = objContratos.DtResultados.FiltraParametros("CveTipoPresupuesto=2") Else DtDetalle = Nothing diff --git a/Bancos/CargarConciliacionesBancarias.aspx.vb b/Bancos/CargarConciliacionesBancarias.aspx.vb index 8fe358133..380ccb142 100644 --- a/Bancos/CargarConciliacionesBancarias.aspx.vb +++ b/Bancos/CargarConciliacionesBancarias.aspx.vb @@ -77,60 +77,14 @@ Partial Class Bancos_CargarConciliacionesBancarias Protected Sub BtnCargaExcel_Click(sender As Object, e As EventArgs) If TxtExcel.getfiles().Archivos.Count > 0 Then Dim file As Archivo = TxtExcel.getfiles().Archivos(0) - Dim Directorio As String = AppDomain.CurrentDomain.BaseDirectory & file.patch - Dim Tipo As String = If(file.Extencion.Contiene("xlsx", "xlsx", "xlsm", "xlsb"), "EXCEL", "CSV") + Dim Directorio As String = AppDomain.CurrentDomain.BaseDirectory & file.path + Dim Tipo As String = If(file.Extension.Contiene("xlsx", "xlsx", "xlsm", "xlsb"), "EXCEL", "CSV") CargaExcel(Directorio, file.filename, Tipo) Else Alert("No existe el archivo.Favor de subir un archivo csv o excel a la plataforma", TipoMensaje.MsgError) End If End Sub - Private Function ReadExcelFile(ByVal flatFilePath As String, ByVal firstRowHasHeaders As Boolean) As DataTable - SpreadsheetInfo.SetLicense(ModExtensiones.SerialGemBoxSpreadsheet) - Dim excelFile As ExcelFile = ExcelFile.Load(flatFilePath) - - Dim unnamed As Integer = 0 - Dim cols As Integer - Dim columns As String() - Dim curRow As Integer = 0 - Dim curCol As Integer = 0 - Dim dataTable As DataTable = New DataTable() - Dim worksheet As ExcelWorksheet = excelFile.Worksheets(0) - - For cols = 0 To worksheet.Rows(0).AllocatedCells.Count - 1 - - If firstRowHasHeaders Then - - If worksheet.Rows(0).Cells(cols).Value IsNot Nothing Then - dataTable.Columns.Add(worksheet.Rows(0).Cells(cols).Value.ToString()) - Else - dataTable.Columns.Add("Unnamed Column " & (System.Threading.Interlocked.Increment(unnamed))) - End If - - curRow = 1 - Else - dataTable.Columns.Add("Column " & (cols + 1)) - End If - Next - - While curRow < worksheet.Rows.Count - columns = New String(cols - 1) {} - - For curCol = 0 To cols - 1 - - If worksheet.Rows(curRow).Cells(curCol).Value Is Nothing Then - columns(curCol) = "" - Else - columns(curCol) = worksheet.Rows(curRow).Cells(curCol).Value.ToString() - End If - Next - - dataTable.Rows.Add(columns) - curRow += 1 - End While - - Return dataTable - End Function Private Sub CargaExcel(Ruta As String, FileName As String, Tipo As String) If Not DdlCuenta.SelectedValue.ToEntero > 0 Then diff --git a/Bancos/PopIEVentas.aspx.vb b/Bancos/PopIEVentas.aspx.vb index 9f38b7a6d..0865e5b69 100644 --- a/Bancos/PopIEVentas.aspx.vb +++ b/Bancos/PopIEVentas.aspx.vb @@ -690,7 +690,7 @@ Partial Class Bancos_PopIEVentas If Not UsuarioActual.Empresa.Funcionalidad(529) = "1" AndAlso dr("FolioFiscal").ToString() <> "" Then - Dim Valida As New ClsValidaCFDi(dr("FolioFiscal").ToString(), UsuarioActual.Empresa.RFC, dr("RFCReceptor").ToString, dr("Total").ToString.ToDecimal) + Dim Valida As New ClsValidaCFDi(dr("FolioFiscal").ToString(), UsuarioActual.Empresa.RFC, dr("RFCReceptor").ToString, dr("Total").ToString.ToDecimal.RoundAD(2)) If Valida.EsValida > 0 Then If Valida.EsValida = 2 Then diff --git a/CRM/CatEmpresasCRM.aspx.cs b/CRM/CatEmpresasCRM.aspx.cs index 729929056..89eff8ed4 100644 --- a/CRM/CatEmpresasCRM.aspx.cs +++ b/CRM/CatEmpresasCRM.aspx.cs @@ -152,7 +152,7 @@ public partial class CRM_CatEmpresasCRM : ClsPaginas if( TxtExcel.getfiles().Archivos.Count > 0 ) { Archivo file = TxtExcel.getfiles().Archivos[0]; - string Directorio = Server.MapPath("~") + file.patch; + string Directorio = Server.MapPath("~") + file.path; DataTable dt = ReadExcelFile(Directorio + file.filename, true); DataRowCollection Rows = dt.Rows; diff --git a/Compras/Compras.aspx b/Compras/Compras.aspx index 22040bb52..f25ecfa5d 100644 --- a/Compras/Compras.aspx +++ b/Compras/Compras.aspx @@ -4447,7 +4447,7 @@ <%-- --%> - +
@@ -5359,8 +5359,8 @@
--%> -