diff --git a/App_Code/ClsClientes.vb b/App_Code/ClsClientes.vb index 364a870bc..b7b8d93d5 100644 --- a/App_Code/ClsClientes.vb +++ b/App_Code/ClsClientes.vb @@ -128,7 +128,8 @@ Public Class ClsClientes Public Property CveFormaPago33 As Integer Public Property CveMetodoPago33 As Integer Public Property CveClienteCorporativo As String - Public Property DesglosaIEPS As Boolean + Public Property DesglosaIEPS As Boolean + Public Property NoDesglosaIVA As Boolean Public Property AplicaComercioExterior As Boolean Public Property CveTipoOperacion As Integer Public Property CvePedimento As Integer @@ -385,6 +386,7 @@ Public Class ClsClientes _CveClienteCorporativo = Data(0)("CveClienteCorporativo").ToString _DesglosaIEPS = CType(Data(0)("DesglosaIEPS"), Boolean) + _NoDesglosaIVA = CType(Data(0)("NoDesglosaIVA"), Boolean) _AplicaComercioExterior = CType(Data(0)("AplicaComercioExterior"), Boolean) _CveTipoOperacion = Data(0)("CveTipoOperacion").ToString.ToEntero @@ -513,18 +515,22 @@ Public Class ClsClientes 'SqlAdapter.Dispose() Return Retorno End Function - Public Function GetHistorialVentas(CveCliente As Integer, Optional SelectTop As Integer = -1, Optional CveClienteSucursal As Integer = -1, Optional TipoDocto As String = "-1", Optional CveEstatusFactura As Integer = -1, Optional FechaI As DateTime = ModExtensiones.MinFecha, Optional FechaF As DateTime = ModExtensiones.MaxFecha) As Boolean + Public Function GetHistorialVentas(CveCliente As Integer, CveEmpresa As Integer, Optional SelectTop As Integer = -1, Optional CveClienteSucursal As Integer = -1, Optional TipoDocto As String = "-1", Optional CveEstatusFactura As Integer = -1, Optional FechaI As DateTime = ModExtensiones.MinFecha, Optional FechaF As DateTime = ModExtensiones.MaxFecha) As Boolean Dim Retorno As Boolean = False DataAdapter("PA_ClienteHistorialVentas") - SqlAdapter.SelectCommand.Parameters.Add("@CveCliente", SqlDbType.Int).Value = CveCliente - SqlAdapter.SelectCommand.Parameters.Add("@SelectTop", SqlDbType.Int).Value = SelectTop - SqlAdapter.SelectCommand.Parameters.Add("@CveClienteSucursal", SqlDbType.Int).Value = CveClienteSucursal - SqlAdapter.SelectCommand.Parameters.Add("@TipoDocto", SqlDbType.VarChar).Value = TipoDocto - SqlAdapter.SelectCommand.Parameters.Add("@CveEstatusFactura", SqlDbType.Int).Value = CveEstatusFactura - SqlAdapter.SelectCommand.Parameters.Add("@FechaI", SqlDbType.DateTime).Value = FechaI - SqlAdapter.SelectCommand.Parameters.Add("@FechaF", SqlDbType.DateTime).Value = FechaF - + With SqlAdapter.SelectCommand.Parameters + .Add("@CveCliente", SqlDbType.Int).Value = CveCliente + .Add("@SelectTop", SqlDbType.Int).Value = SelectTop + .Add("@CveClienteSucursal", SqlDbType.Int).Value = CveClienteSucursal + .Add("@TipoDocto", SqlDbType.VarChar).Value = TipoDocto + .Add("@CveEstatusFactura", SqlDbType.Int).Value = CveEstatusFactura + .Add("@FechaI", SqlDbType.DateTime).Value = FechaI + .Add("@FechaF", SqlDbType.DateTime).Value = FechaF + .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa + End With + + Try SqlAdapter.Fill(Data) Retorno = True @@ -757,7 +763,7 @@ Public Class ClsClientes Optional CveMotivoTraslado As Integer = 0, Optional NumRegIdTrib As String = "-1", Optional ComExtEstado As String = "-1", Optional ComExtMunicipio As String = "-1", Optional ComExtColonia As String = "-1", Optional ApellidoPaternoPF As String = "-1", Optional ApellidoMaternoPF As String = "-1", Optional NombresPF As String = "-1", Optional RequiereOC As Boolean = False, Optional LT As String = "0", Optional LG As String = "0", Optional EsDistribuidor As Boolean = False, Optional TipoCliente As Integer = 1, Optional CargoUsado As Boolean = False, Optional BonificacionUsado As Boolean = False, Optional CveTipoRetencion As Integer = 0, Optional CorreoEntregaCompras As String = "-1", Optional CorreoEntregaAlmacen As String = "-1", - Optional CveSATEstado As Integer = -1, Optional CveAdminTrayecto As Integer = -1) As Boolean + Optional CveSATEstado As Integer = -1, Optional CveAdminTrayecto As Integer = -1, Optional NoDesglosaIVA As Boolean = False) As Boolean Dim Retorno As Boolean = False @@ -878,6 +884,7 @@ Public Class ClsClientes .Add("@CveClienteCorporativo", SqlDbType.Int).Value = CveClienteCorporativo .Add("@DesglosaIEPS", SqlDbType.Bit).Value = If(DesglosaIEPS, 1, 0) + .Add("@NoDesglosaIVA", SqlDbType.Bit).Value = If(NoDesglosaIVA, 1, 0) .Add("@AplicaComercioExterior", SqlDbType.Bit).Value = AplicaComercioExterior .Add("@CveTipoOperacion", SqlDbType.Int).Value = CveTipoOperacion diff --git a/App_Code/ClsCompras.vb b/App_Code/ClsCompras.vb index 4aa180e78..d52811978 100644 --- a/App_Code/ClsCompras.vb +++ b/App_Code/ClsCompras.vb @@ -438,12 +438,12 @@ Public Class ClsCompras End Function Public Function AddCompraDetalle(CveCompra As Integer, CveUM As Integer, CvePS As Integer, CveSubProyecto As Integer, CveCliente As Integer, CveActivoFijo As Integer, - Cantidad As Double, PU As Double, IVA As Double, Total As Double, Descuento As Double, Observaciones As String, CveOCDetalle As Integer, + Cantidad As Decimal, PU As Decimal, IVA As Decimal, Total As Decimal, Descuento As Decimal, Observaciones As String, CveOCDetalle As Integer, Optional TipoRecepcion As Integer = -1, Optional CveContrato As Integer = -1, Optional CvePresupuestoEgreso As Integer = -1, Optional AplicaCostoIndirecto As Integer = -1, Optional EstatusAlmacen As Integer = -1, Optional CvePersonal As Integer = -1, Optional CveTipoGasto As Integer = -1, Optional AF_Medida As Integer = -1, Optional AF_TipoMantenimiento As Integer = -1, Optional Referencia As String = "", Optional OtrosGastos As Decimal = 0, - Optional RetIVA As Double = 0, Optional RetISR As Double = 0, Optional IEPSPS As Double = 0, Optional IEPSPSIVA As Double = 0, - Optional IVAPorcentaje As Double = 0, Optional RetIVAPorcentaje As Double = 0, Optional RetISRPorcentaje As Double = 0, Optional IEPSPSPorcentaje As Double = 0, Optional IEPSPSIVAPorcentaje As Double = 0, + Optional RetIVA As Decimal = 0, Optional RetISR As Decimal = 0, Optional IEPSPS As Decimal = 0, Optional IEPSPSIVA As Decimal = 0, + Optional IVAPorcentaje As Decimal = 0, Optional RetIVAPorcentaje As Decimal = 0, Optional RetISRPorcentaje As Decimal = 0, Optional IEPSPSPorcentaje As Decimal = 0, Optional IEPSPSIVAPorcentaje As Decimal = 0, Optional NoDeducible As Boolean = False, Optional CveContratoDetalle As Integer = -1, Optional CveCultivoCuadroDetalle As Integer = -1) As Boolean Dim Retorno As Boolean = False @@ -457,12 +457,12 @@ Public Class ClsCompras .Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto .Add("@CveCliente", SqlDbType.Int).Value = CveCliente .Add("@CveActivoFijo", SqlDbType.Int).Value = CveActivoFijo - .Add("@Cantidad", SqlDbType.Float).Value = Cantidad - .Add("@PU", SqlDbType.Float).Value = PU - .Add("@IVA", SqlDbType.Float).Value = IVA - .Add("@Total", SqlDbType.Float).Value = Total - .Add("@Descuento", SqlDbType.Float).Value = Descuento - .Add("@OtrosGastos", SqlDbType.Float).Value = OtrosGastos + .Add("@Cantidad", SqlDbType.Decimal).Value = Cantidad + .Add("@PU", SqlDbType.Decimal).Value = PU + .Add("@IVA", SqlDbType.Decimal).Value = IVA + .Add("@Total", SqlDbType.Decimal).Value = Total + .Add("@Descuento", SqlDbType.Decimal).Value = Descuento + .Add("@OtrosGastos", SqlDbType.Decimal).Value = OtrosGastos .Add("@Observaciones", SqlDbType.VarChar).Value = Observaciones .Add("@CveOCDetalle", SqlDbType.Int).Value = CveOCDetalle .Add("@TipoRecepcion", SqlDbType.Int).Value = TipoRecepcion @@ -476,16 +476,16 @@ Public Class ClsCompras .Add("@AF_TipoMantenimiento", SqlDbType.Int).Value = AF_TipoMantenimiento .Add("@Referencia", SqlDbType.VarChar).Value = Referencia .Add("@CveCompraDetalle", SqlDbType.Int).Direction = ParameterDirection.Output - .Add("@RetIVA", SqlDbType.Float).Value = RetIVA - .Add("@RetISR", SqlDbType.Float).Value = RetISR - .Add("@IEPSPS", SqlDbType.Float).Value = IEPSPS - .Add("@IEPSPSIVA", SqlDbType.Float).Value = IEPSPSIVA + .Add("@RetIVA", SqlDbType.Decimal).Value = RetIVA + .Add("@RetISR", SqlDbType.Decimal).Value = RetISR + .Add("@IEPSPS", SqlDbType.Decimal).Value = IEPSPS + .Add("@IEPSPSIVA", SqlDbType.Decimal).Value = IEPSPSIVA - .Add("@IVAPorcentaje", SqlDbType.Float).Value = IVAPorcentaje - .Add("@RetIVAPorcentaje", SqlDbType.Float).Value = RetIVAPorcentaje - .Add("@RetISRPorcentaje", SqlDbType.Float).Value = RetISRPorcentaje - .Add("@IEPSPSPorcentaje", SqlDbType.Float).Value = IEPSPSPorcentaje - .Add("@IEPSPSIVAPorcentaje", SqlDbType.Float).Value = IEPSPSIVAPorcentaje + .Add("@IVAPorcentaje", SqlDbType.Decimal).Value = IVAPorcentaje + .Add("@RetIVAPorcentaje", SqlDbType.Decimal).Value = RetIVAPorcentaje + .Add("@RetISRPorcentaje", SqlDbType.Decimal).Value = RetISRPorcentaje + .Add("@IEPSPSPorcentaje", SqlDbType.Decimal).Value = IEPSPSPorcentaje + .Add("@IEPSPSIVAPorcentaje", SqlDbType.Decimal).Value = IEPSPSIVAPorcentaje .Add("@NoDeducible", SqlDbType.Bit).Value = NoDeducible .Add("@CveContratoDetalle", SqlDbType.Int).Value = CveContratoDetalle .Add("@CveCultivoCuadroDetalle", SqlDbType.Int).Value = CveCultivoCuadroDetalle diff --git a/App_Code/ClsGenerales.vb b/App_Code/ClsGenerales.vb index 0c36234e9..a84761df1 100644 --- a/App_Code/ClsGenerales.vb +++ b/App_Code/ClsGenerales.vb @@ -2527,7 +2527,7 @@ Public Class ClsGenerales CveEmpresa As Integer, Optional CveUsuario As Integer = -1, Optional CvePersonal As Integer = -1, Optional IdPoliza As Integer = -1, Optional CvePrePoliza As Integer = -1, Optional CvePeriodo As Integer = -1, Optional CveConceptoNomina As Integer = -1, Optional CvePromocion As Integer = -1, Optional CveAsistencia As Integer = -1, Optional CveAsistenciaDetalle As Integer = -1, Optional CveTipoBitacora As Integer = -1, - Optional FechaInicio As String = "", Optional FechaFin As String = "") As Boolean + Optional FechaInicio As String = "", Optional FechaFin As String = "", Optional Fecha As Date = MinFecha) As Boolean Dim Retorno As Boolean = False DataAdapter("PA_Gral_HistorialBitacoraGet") @@ -2554,6 +2554,8 @@ Public Class ClsGenerales .Add("@CveTipoBitacora", SqlDbType.Int).Value = CveTipoBitacora .Add("@FechaInicio", SqlDbType.VarChar).Value = FechaInicio .Add("@FechaFin", SqlDbType.VarChar).Value = FechaFin + .Add("@Fecha", SqlDbType.Date).Value = Fecha + End With 'SqlTypes.SqlDateTime.Null diff --git a/App_Code/ClsInventarios.vb b/App_Code/ClsInventarios.vb index 6cfd8a54b..03880cf97 100644 --- a/App_Code/ClsInventarios.vb +++ b/App_Code/ClsInventarios.vb @@ -131,8 +131,6 @@ Public Class ClsInventarios Public Property ResponsableCarga As String Public Property ResponsableRecibio As String Public Property Modulo As String - Public Property ConAplicacion As Boolean - @@ -2309,8 +2307,6 @@ Public Class ClsInventarios FechaI = dr("FechaInicio").ToString FechaF = dr("FechaFin").ToString Estatus = dr("Estatus").ToString - ConAplicacion = Convert.ToBoolean(dr("ConAplicacion").ToString) - Retorno = True End If diff --git a/App_Code/ClsNominas.vb b/App_Code/ClsNominas.vb index 9d1572a61..2dd6b5be7 100644 --- a/App_Code/ClsNominas.vb +++ b/App_Code/ClsNominas.vb @@ -2483,6 +2483,52 @@ Public Class ClsNominas End Try Return retorno End Function +#Region "Prorrateo" + + Public Function ProrrateosubproyectoGET(CveEmpresa As Integer) As Boolean + Dim Retorno As Boolean = False + DataAdapter("PA_Nom_Prorrateosubproyecto") + SqlAdapter.SelectCommand.Parameters.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa + Try + SqlAdapter.Fill(Data) + Retorno = True + Catch ex As Exception + Me.OnError("Ocurrió un error al obtener prorrateo.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo()) + End Try + + Return Retorno + End Function + Public Function ProrrateosubproyectoAdd(CvePersonal As Integer, CveSubProyecto As Integer, Porcentaje As Decimal) As Boolean + Dim Retorno As Boolean = False + DataAdapter("PA_Nom_ProrrateosubproyectoAdd") + SqlAdapter.SelectCommand.Parameters.Add("@CvePersonal", SqlDbType.Int).Value = CvePersonal + SqlAdapter.SelectCommand.Parameters.Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto + SqlAdapter.SelectCommand.Parameters.Add("@Porcentaje", SqlDbType.Decimal).Value = Porcentaje + Try + SqlAdapter.Fill(Data) + Retorno = True + Catch ex As Exception + Me.OnError("Ocurrió un error al obtener prorrateo.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo()) + End Try + + Return Retorno + End Function + Public Function ProrrateosubproyectoRemove(CvePersonal As Integer, CveSubProyecto As Integer) As Boolean + Dim Retorno As Boolean = False + DataAdapter("PA_Nom_ProrrateosubproyectoRemove") + SqlAdapter.SelectCommand.Parameters.Add("@CvePersonal", SqlDbType.Int).Value = CvePersonal + SqlAdapter.SelectCommand.Parameters.Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto + Try + SqlAdapter.Fill(Data) + Retorno = True + Catch ex As Exception + Me.OnError("Ocurrió un error al obtener prorrateo.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo()) + End Try + + Return Retorno + End Function + +#End Region #Region "CRUD_Nom_PersonalIncapacidad" Public Function PersonalIncapacidadGet(cvePersonalIncapacidad As Int32, cvePersonal As Int32, CveEmpresa As Int32) As Boolean diff --git a/App_Code/ClsPaginas.vb b/App_Code/ClsPaginas.vb index f772f0635..555f3d41d 100644 --- a/App_Code/ClsPaginas.vb +++ b/App_Code/ClsPaginas.vb @@ -1352,7 +1352,7 @@ Public Class ClsPaginas End Get End Property Public Property GlobalDTPSSimplificado(CveEmpresa As Integer, Optional CveClasificacion As Integer = -1, Optional PSCodigo As String = "-1", Optional Estatus As Integer = 1, - Optional AplicaParaVenta As Integer = -1, Optional CvePS As Integer = -1, Optional Codigo As String = "-1") As DataTable + Optional AplicaParaVenta As Integer = -1, Optional CvePS As Integer = -1, Optional Codigo As String = "-1", Optional CodigoSATPS As String = "-1") As DataTable Get Dim AppNombre As String = String.Format("GlobalDTPSSimplificado-{0}", CveEmpresa) If CveEmpresa <> -1 Then @@ -1367,7 +1367,7 @@ Public Class ClsPaginas Dim Cons = DirectCast(Application(AppNombre), EnumerableRowCollection(Of DataRow)) - Cons = Cons.Where((Function(a) Convert.ToInt32(a!CveEmpresa) = CveEmpresa)) + 'Cons = Cons.Where((Function(a) Convert.ToInt32(a!CveEmpresa) = CveEmpresa)) If CveClasificacion >= 0 Then Cons = Cons.Where((Function(a) Convert.ToInt32(a!CveClasificacion) = CveClasificacion)) If PSCodigo <> "-1" Then Cons = Cons.Where((Function(a) Convert.ToString(a!PSCodigo) = PSCodigo)) Codigo = Codigo.ToUpper().Trim() @@ -1375,6 +1375,7 @@ Public Class ClsPaginas If Estatus >= 0 Then Cons = Cons.Where((Function(a) Convert.ToInt32(a!CveEstado) = Estatus)) If AplicaParaVenta >= 0 Then Cons = Cons.Where((Function(a) Convert.ToInt32(a!AplicaParaVenta) = AplicaParaVenta)) If CvePS >= 0 Then Cons = Cons.Where((Function(a) Convert.ToInt32(a!CvePS) = CvePS)) + If CodigoSATPS <> "-1" Then Cons = Cons.Where((Function(a) Convert.ToString(a!SATClavePS) = CodigoSATPS)) Try GlobalDTPSSimplificado = Cons.OrderBy(Function(a) a!PSCodigo).CopyToDataTable diff --git a/App_Code/ClsRH.vb b/App_Code/ClsRH.vb index 9a643e6ef..a78a05d7c 100644 --- a/App_Code/ClsRH.vb +++ b/App_Code/ClsRH.vb @@ -2031,12 +2031,13 @@ chkAplicaVacacion As Boolean, chkAplicaIncapacidad As Boolean, chkAplicaRetardo Return Retorno End Function - Public Function UpdateSalariointegrado(CvePersonal As Integer, CveEmpresa As Integer, SDI As Double, SalarioDiario As Double) As Boolean + Public Function UpdateSalariointegrado(CvePersonal As Integer, CveUsuario As Integer, CveEmpresa As Integer, SDI As Double, SalarioDiario As Double) As Boolean Dim Retorno As Boolean = False SqlDataAdapter("PA_RH_PersonalUpdateSalarioIntegrado") With SqlAdapter.SelectCommand.Parameters .Add("@CvePersonal", SqlDbType.Int).Value = CvePersonal .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa + .Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario .Add("@SDI", SqlDbType.Money).Value = SDI .Add("@SalarioDiario", SqlDbType.Money).Value = SalarioDiario End With @@ -2048,13 +2049,14 @@ chkAplicaVacacion As Boolean, chkAplicaIncapacidad As Boolean, chkAplicaRetardo End Try Return Retorno End Function - Public Function UpdateSalarios(CvePersonal As Integer, Fecha As String, CveEmpresa As Integer, SalarioDiario As Double, SDI As Double, SalarioDiarioSS As Double, SalarioDiarioPago As Double, Optional CalcularSDI As Boolean = False) As Boolean + Public Function UpdateSalarios(CvePersonal As Integer, Fecha As String, CveUsuario As Integer, CveEmpresa As Integer, SalarioDiario As Double, SDI As Double, SalarioDiarioSS As Double, SalarioDiarioPago As Double, Optional CalcularSDI As Boolean = False) As Boolean Dim Retorno As Boolean = False SqlDataAdapter("PA_RH_PersonalUpdateSalarios") With SqlAdapter.SelectCommand.Parameters .Add("@CvePersonal", SqlDbType.Int).Value = CvePersonal .Add("@Fecha", SqlDbType.Date).Value = Fecha .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa + .Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario .Add("@SalarioDiarioPago", SqlDbType.Money).Value = SalarioDiarioPago .Add("@SalarioDiario", SqlDbType.Money).Value = SalarioDiario .Add("@SDI", SqlDbType.Money).Value = SDI @@ -2448,7 +2450,7 @@ chkAplicaVacacion As Boolean, chkAplicaIncapacidad As Boolean, chkAplicaRetardo Dim Retorno As Boolean = False Dim xmlProductos As System.Xml.Linq.XDocument = Nothing If registros IsNot Nothing AndAlso registros.Count > 0 Then - xmlProductos = New System.Xml.Linq.XDocument(New System.Xml.Linq.XElement("registros", From x In registros Select New System.Xml.Linq.XElement("registro", New System.Xml.Linq.XElement("CveAsistenciaDetalle", x.CveAsistenciaDetalle), New System.Xml.Linq.XElement("CvePersonal", x.CvePersonal), New System.Xml.Linq.XElement("CveAsistenciasInasistencias", x.CveAsistenciasInasistencias), New System.Xml.Linq.XElement("CveSubProyecto", x.CveSubProyecto), New System.Xml.Linq.XElement("Fecha", x.Fecha)))) + xmlProductos = New System.Xml.Linq.XDocument(New System.Xml.Linq.XElement("registros", From x In registros Select New System.Xml.Linq.XElement("registro", New System.Xml.Linq.XElement("CveAsistenciaDetalle", x.CveAsistenciaDetalle), New System.Xml.Linq.XElement("CvePersonal", x.CvePersonal), New System.Xml.Linq.XElement("CveAsistenciasInasistencias", x.CveAsistenciasInasistencias), New System.Xml.Linq.XElement("CveSubProyecto", x.CveSubProyecto), New System.Xml.Linq.XElement("Fecha", x.Fecha), New System.Xml.Linq.XElement("Motivo", x.Motivo)))) End If Data = New DataTable SqlDataAdapter("PA_RH_AsistenciaDetalleUP") diff --git a/Compras/PopUpBuscarFolioC.aspx b/Compras/PopUpBuscarFolioC.aspx index 041743b15..77b5be834 100644 --- a/Compras/PopUpBuscarFolioC.aspx +++ b/Compras/PopUpBuscarFolioC.aspx @@ -46,7 +46,7 @@ Proveedor: - + diff --git a/Compras/PopUpBuscarFolioC.aspx.vb b/Compras/PopUpBuscarFolioC.aspx.vb index de4e0e45b..3b95e36c9 100644 --- a/Compras/PopUpBuscarFolioC.aspx.vb +++ b/Compras/PopUpBuscarFolioC.aspx.vb @@ -31,9 +31,9 @@ Partial Class Compras_PopUpBuscarFolioC End Sub Protected Sub CargaProveedor() - DdlProveedor.DataSource = GlobalDTCompProveedores(UsuarioActual.CveEmpresa) - DdlProveedor.DataBind() - DdlProveedor.Items.Insert(0, New ListItem("Todos", "-1")) + 'DdlProveedor.DataSource = GlobalDTCompProveedores(UsuarioActual.CveEmpresa) + 'DdlProveedor.DataBind() + 'DdlProveedor.Items.Insert(0, New ListItem("Todos", "-1")) End Sub @@ -57,7 +57,7 @@ Partial Class Compras_PopUpBuscarFolioC If ValidarUnFiltroSeleccionado() Then Dim ObjCompras As New ClsCompras() If ObjCompras.GetCompras(UsuarioActual.CveEmpresa, DdlTipoDocto.SelectedValue, Folio, FolioFiscal, Codigo, Proveedor, FechaI, FechaF, Descripcion, Obs, - CveProveedor:=DdlProveedor.SelectedValue.ToEntero, TopSelect:=100) Then + CveProveedor:=DdlProveedores.SelectedValue.ToEntero, TopSelect:=100) Then If ObjCompras.DtResultados.Rows.Count > 0 Then LtlTotalRegistros.Text = ObjCompras.DtResultados.Rows.Count.ToString.FormatoNumero(0) GV.DataSource = ObjCompras.DtResultados @@ -112,7 +112,7 @@ Partial Class Compras_PopUpBuscarFolioC If TxtDescripcion.Text.Trim.Length > 0 Then Return True If TxtObservaciones.Text.Trim.Length > 0 Then Return True If DdlTipoDocto.SelectedValue <> "-1" Then Return True - If DdlProveedor.SelectedValue.ToEntero <> 0 Then Return True + If DdlProveedores.SelectedValue.ToEntero <> 0 Then Return True Return False End Function End Class diff --git a/Contabilidad2/CatCuentasAsignaciones.aspx.vb b/Contabilidad2/CatCuentasAsignaciones.aspx.vb index e281fdbab..747c43556 100644 --- a/Contabilidad2/CatCuentasAsignaciones.aspx.vb +++ b/Contabilidad2/CatCuentasAsignaciones.aspx.vb @@ -58,7 +58,7 @@ Partial Class Contabilidad2_CatCuentasAsignaciones Dim ObjConta As New ClsContabilidad If ObjConta.GetConta_ConceptosContables() Then - DdlCconceptosContables.DataSource = ObjConta.DtResultados + DdlCconceptosContables.DataSource = ObjConta.DtResultados.FiltraParametros("EsCuentaUnica = false AND EsSistema = True ") DdlConceptoGlobal.DataSource = ObjConta.DtResultados.FiltraParametros("EsCuentaUnica = false AND EsSistema = True AND EsGlobal = True") End If diff --git a/Contratos/RepContratosObraAvances.aspx b/Contratos/RepContratosObraAvances.aspx index 80af972f4..525fc4072 100644 --- a/Contratos/RepContratosObraAvances.aspx +++ b/Contratos/RepContratosObraAvances.aspx @@ -70,8 +70,8 @@
Cliente:
-
- +
+
diff --git a/Contratos/RepContratosObraAvances.aspx.vb b/Contratos/RepContratosObraAvances.aspx.vb index e3e4fc141..15f33d2b3 100644 --- a/Contratos/RepContratosObraAvances.aspx.vb +++ b/Contratos/RepContratosObraAvances.aspx.vb @@ -19,12 +19,15 @@ Partial Class RepContratosObraAvances Private Sub CargaDatos() + Dim CveCliente As Integer = -1 Dim Con As New ClsContratos - Dim DTDatos As New DataTable + If DdlCliente.SelectedValue.ToEntero > 0 Then CveCliente = DdlCliente.SelectedValue.ToEntero - If Con.GetContratosObraRepAvances(MinFecha, MaxFecha, DdlCliente.SelectedValue.ToEntero, DdlContrato.SelectedValue.ToEntero, UsuarioActual.CveEmpresa) Then + If Con.GetContratosObraRepAvances(MinFecha, MaxFecha, CveCliente, DdlContrato.SelectedValue.ToEntero, UsuarioActual.CveEmpresa) Then GVDatos.DataSource = Con.DtResultados - DTDatos = Con.DtResultados + If Con.DtResultados.Rows.Count > 0 Then + Indicadores(Con.DtResultados) + End If Else GVDatos.DataSource = Nothing End If @@ -35,9 +38,7 @@ Partial Class RepContratosObraAvances UpDatos.Update() - If DTDatos.Rows.Count > 0 Then - Indicadores(DTDatos) - End If + End Sub @@ -88,15 +89,15 @@ Partial Class RepContratosObraAvances End Sub Private Sub CargaClientes() - Dim dt As DataTable = Nothing - Dim Cli As New ClsClientes - If Cli.GetClientes(-1, "-1", "-1", "-1", "-1", "-1", "-1", -1, UsuarioActual.CveEmpresa) Then - dt = Cli.DtResultados - End If - Cli.Dispose() - DdlCliente.DataSource = dt - DdlCliente.DataBind() - DdlCliente.Items.Insert(0, New ListItem("Todos", "-1")) + 'Dim dt As DataTable = Nothing + 'Dim Cli As New ClsClientes + 'If Cli.GetClientes(-1, "-1", "-1", "-1", "-1", "-1", "-1", -1, UsuarioActual.CveEmpresa) Then + ' dt = Cli.DtResultados + 'End If + 'Cli.Dispose() + 'DdlCliente.DataSource = dt + 'DdlCliente.DataBind() + 'DdlCliente.Items.Insert(0, New ListItem("Todos", "-1")) End Sub #End Region diff --git a/General/ExcelToBD.aspx.cs b/General/ExcelToBD.aspx.cs index 4f00078ce..1c3d4a6d7 100644 --- a/General/ExcelToBD.aspx.cs +++ b/General/ExcelToBD.aspx.cs @@ -83,9 +83,10 @@ public partial class General_ExcelToBD : System.Web.UI.Page DdlWorkBooks.DataBind(); if (workBooks.Count > 0) { - DdlWorkBooks.SelectedIndex = 0; + DdlWorkBooks.SelectedIndex = 1; DdlWorkBooks_SelectedIndexChanged(null, null); } + LnkContinuar_Click(null, null); } protected void DdlWorkBooks_SelectedIndexChanged(object sender, EventArgs e) @@ -100,7 +101,7 @@ public partial class General_ExcelToBD : System.Web.UI.Page columnas = workSheet.LastRowUsed().CellCount(); TxtFilas.Text = Filas.ToString(); TxtInicia.Text = "2"; - TxtColumnas.Text = "62";// columnas.ToString(); + TxtColumnas.Text = "48";//"62";// columnas.ToString(); } } diff --git a/Inventarios/RecepcionAlmacen.aspx.vb b/Inventarios/RecepcionAlmacen.aspx.vb index 7c9e2fa5b..c8f5f2624 100644 --- a/Inventarios/RecepcionAlmacen.aspx.vb +++ b/Inventarios/RecepcionAlmacen.aspx.vb @@ -2229,6 +2229,14 @@ Partial Class Inventarios_RecepcionAlmacen Return False End If + If UsuarioActual.Empresa.Funcionalidad(594) = "1" AndAlso Not UsuarioActual.TienePermisoProceso(314) Then + Dim Filesgral As List(Of Archivo) = TxtDocumento.getfiles().Archivos + If Filesgral Is Nothing OrElse Filesgral.Count = 0 Then + Alert("Es necesario agregar un documento.", TipoMensaje.MsgAdvertencia) + Return False + End If + End If + 'VERIFICA EXISTENCIAS If TipoMovimiento > 1 Then Dim MensajeExistencias As New StringBuilder @@ -2263,14 +2271,6 @@ Partial Class Inventarios_RecepcionAlmacen End If - If UsuarioActual.Empresa.Funcionalidad(594) = "1" AndAlso Not UsuarioActual.TienePermisoProceso(314) Then - Dim Filesgral As List(Of Archivo) = TxtDocumento.getfiles().Archivos - If Filesgral Is Nothing OrElse Filesgral.Count = 0 Then - Alert("Es necesario agregar un documento.", TipoMensaje.MsgAdvertencia) - Return False - End If - End If - Return True End Function Protected Sub BtnGuardar_Click(sender As Object, e As EventArgs) Handles BtnGuardar.Click @@ -3883,6 +3883,14 @@ Partial Class Inventarios_RecepcionAlmacen End If End If + 'DOCUMENTOS RELACIONADOS AL MOVIMIENTO + If Not ErrorMovInv AndAlso UsuarioActual.Empresa.Funcionalidad(594) = "1" AndAlso Not UsuarioActual.TienePermisoProceso(314) Then + If Not ErrorMovInv AndAlso Not GuardaDocumentoBitacora(ObjBitacora, CveMovimiento) Then + ErrorMovInv = True + Alert("Ocurrió un error al guardar los datos adjuntos de la bitácora", TipoMensaje.MsgError) + End If + End If + Else ErrorMovInv = True diff --git a/Nomina/ChecadorAsistencia.aspx b/Nomina/ChecadorAsistencia.aspx index 8ae601114..8ad4fd876 100644 --- a/Nomina/ChecadorAsistencia.aspx +++ b/Nomina/ChecadorAsistencia.aspx @@ -4,6 +4,9 @@