This commit is contained in:
Hector
2021-08-05 10:14:38 -07:00
32 changed files with 2510 additions and 1160 deletions

View File

@@ -1345,7 +1345,7 @@ Public Class ClsContratos
With SqlAdapter.SelectCommand.Parameters
.Add("@CveContrato", SqlDbType.Int).Value = CveContrato
.Add("@CveContratoDetalle", SqlDbType.Int).Value = CveContratoDetalle
.Add("@Cantidad", SqlDbType.Int).Value = Cantidad
.Add("@Cantidad", SqlDbType.Decimal).Value = Cantidad
.Add("@Fecha", SqlDbType.Date).Value = Fecha
.Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa

View File

@@ -621,10 +621,14 @@ Public Class ClsNominas
Return Retorno
End Function
Public Function AddNom_NominasDetalles(CveNomina As Integer, CvePeriodo As Integer, CvePersonal As Integer, CveConcepto As Integer, Importe As Decimal, ImporteGravado As Decimal, ImporteExento As Decimal) As Boolean
Public Function AddUPNom_NominasDetalles(CveNomina As Integer, CvePeriodo As Integer, CvePersonal As Integer, CveConcepto As Integer,
Importe As Decimal, ImporteGravado As Decimal, ImporteExento As Decimal, ImporteValor As Decimal,
CveUsuario As Integer, IsEdited As Boolean,
chkImporte As Integer, chkImporteGravado As Integer, chkImporteValor As Integer
) As Boolean
Dim Retorno As Boolean = False
DataAdapter("PA_Nom_NominasDetallesAdd")
DataAdapter("PA_Nom_NominasDetallesAddUP")
With SqlAdapter.SelectCommand.Parameters
.Add("CveNomina", SqlDbType.Int).Value = CveNomina
@@ -634,6 +638,12 @@ Public Class ClsNominas
.Add("Importe", SqlDbType.Float).Value = Importe
.Add("ImporteGravado", SqlDbType.Float).Value = ImporteGravado
.Add("ImporteExento", SqlDbType.Float).Value = ImporteExento
.Add("ImporteValor", SqlDbType.Float).Value = ImporteValor
.Add("CveUsuario", SqlDbType.Int).Value = CveUsuario
.Add("IsEdited", SqlDbType.Bit).Value = IsEdited
.Add("chkImporteValor", SqlDbType.Int).Value = chkImporteValor
.Add("chkImporte", SqlDbType.Int).Value = chkImporte
.Add("chkImporteGravado", SqlDbType.Int).Value = chkImporteGravado
End With
Try
@@ -646,31 +656,56 @@ Public Class ClsNominas
Return Retorno
End Function
Public Function UpdateNom_NominasDetalles(CveNominaDetalle As Integer, Importe As Decimal, ImporteExento As Decimal, ImporteGravado As Decimal) As Boolean
Dim Retorno As Boolean = False
DataAdapter("PA_Nom_NominasDetallesUpdate")
'Public Function AddNom_NominasDetalles(CveNomina As Integer, CvePeriodo As Integer, CvePersonal As Integer, CveConcepto As Integer, Importe As Decimal, ImporteGravado As Decimal, ImporteExento As Decimal) As Boolean
' Dim Retorno As Boolean = False
With SqlAdapter.SelectCommand.Parameters
.Add("CveNominaDetalle", SqlDbType.Int).Value = CveNominaDetalle
.Add("Importe", SqlDbType.Float).Value = Importe
.Add("ImporteExento", SqlDbType.Float).Value = ImporteExento
.Add("ImporteGravado", SqlDbType.Float).Value = ImporteGravado
End With
' DataAdapter("PA_Nom_NominasDetallesAdd")
Try
SqlAdapter.Fill(Data)
Retorno = True
'
Catch sqlex As SqlException
If sqlex.Message.Contains("x5010") Then
Me.OnError("Ocurrió un error al eliminar el Movimiento de Nomina(Timbrada).", sqlex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
Else
Me.OnError("Ocurrió un error al eliminar el Movimiento de Nomina.", sqlex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
End If
End Try
' With SqlAdapter.SelectCommand.Parameters
' .Add("CveNomina", SqlDbType.Int).Value = CveNomina
' .Add("CvePeriodo", SqlDbType.Int).Value = CvePeriodo
' .Add("CvePersonal", SqlDbType.Int).Value = CvePersonal
' .Add("CveConcepto", SqlDbType.Int).Value = CveConcepto
' .Add("Importe", SqlDbType.Float).Value = Importe
' .Add("ImporteGravado", SqlDbType.Float).Value = ImporteGravado
' .Add("ImporteExento", SqlDbType.Float).Value = ImporteExento
' End With
Return Retorno
End Function
' Try
' SqlAdapter.Fill(Data)
' Retorno = True
' Catch Ex1 As SqlException
' Me.OnError("Ocurrió un error al Guardar el Movimiento de Nomina.", Ex1, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
' End Try
' Return Retorno
'End Function
'Public Function UpdateNom_NominasDetalles(CveNominaDetalle As Integer, Importe As Decimal, ImporteExento As Decimal, ImporteGravado As Decimal) As Boolean
' Dim Retorno As Boolean = False
' DataAdapter("PA_Nom_NominasDetallesUpdate")
' With SqlAdapter.SelectCommand.Parameters
' .Add("CveNominaDetalle", SqlDbType.Int).Value = CveNominaDetalle
' .Add("Importe", SqlDbType.Float).Value = Importe
' .Add("ImporteExento", SqlDbType.Float).Value = ImporteExento
' .Add("ImporteGravado", SqlDbType.Float).Value = ImporteGravado
' End With
' Try
' SqlAdapter.Fill(Data)
' Retorno = True
' '
' Catch sqlex As SqlException
' If sqlex.Message.Contains("x5010") Then
' Me.OnError("Ocurrió un error al eliminar el Movimiento de Nomina(Timbrada).", sqlex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
' Else
' Me.OnError("Ocurrió un error al eliminar el Movimiento de Nomina.", sqlex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
' End If
' End Try
' Return Retorno
'End Function
Public Function DeleteNom_NominasDetalles(CveConcepto As Integer, CvePersonal As Integer, CvePeriodo As Integer) As Boolean
Dim Retorno As Boolean = False
@@ -1770,7 +1805,7 @@ Public Class ClsNominas
End Function
#End Region
#Region ""
#Region "Periodos"
Public Function GetPeriodos(CveTipoPeriodo As Integer, CveEmpresa As Integer, Ejercicio As Integer, Mes As Integer, CvePeriodo As Integer, Optional CveEstatus As Integer = -1) As Boolean
Dim Retorno As Boolean = False
@@ -2172,34 +2207,6 @@ Public Class ClsNominas
End Try
Return Retorno
End Function
Public Function AddUPNom_NominasDetalles(CveNomina As Integer, CvePeriodo As Integer, CvePersonal As Integer, CveConcepto As Integer, Importe As Decimal, ImporteGravado As Decimal, ImporteExento As Decimal, ImporteValor As Decimal, CveUsuario As Integer, Optional IsEdited As Boolean = False) As Boolean
Dim Retorno As Boolean = False
DataAdapter("PA_Nom_NominasDetallesAddUP")
With SqlAdapter.SelectCommand.Parameters
.Add("CveNomina", SqlDbType.Int).Value = CveNomina
.Add("CvePeriodo", SqlDbType.Int).Value = CvePeriodo
.Add("CvePersonal", SqlDbType.Int).Value = CvePersonal
.Add("CveConcepto", SqlDbType.Int).Value = CveConcepto
.Add("Importe", SqlDbType.Float).Value = Importe
.Add("ImporteGravado", SqlDbType.Float).Value = ImporteGravado
.Add("ImporteExento", SqlDbType.Float).Value = ImporteExento
.Add("ImporteValor", SqlDbType.Float).Value = ImporteValor
.Add("CveUsuario", SqlDbType.Int).Value = CveUsuario
.Add("IsEdited", SqlDbType.Bit).Value = IsEdited
End With
Try
SqlAdapter.Fill(Data)
Retorno = True
Catch Ex1 As SqlException
Me.OnError("Ocurrió un error al Guardar el Movimiento de Nomina.", Ex1, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
End Try
Return Retorno
End Function
Public Function ProcesarSUA(txtSUA As String, cveEmpresa As Int32) As Boolean
Dim retorno As Boolean = False
DTSet = New DataSet()
@@ -2298,7 +2305,7 @@ Public Class ClsNominas
Dim retorno As Boolean = False
Try
DTSet = New DataSet()
DataAdapter("PA_Nom_NominaEmpleado", CommandType.StoredProcedure)
DataAdapter("PA_Nom_NominaEmpleadoV2", CommandType.StoredProcedure)
With SqlAdapter.SelectCommand.Parameters
.Add("@CveProyecto", SqlDbType.Int).Value = CveProyecto
.Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto

View File

@@ -6788,7 +6788,7 @@ Public Class ClsPaginas
params.Add(New ReportParameter("ClienteTelefono", Vta.ClienteSucursal.TelefonoSucursal))
ElseIf Vta.CveCliente.ToEntero > 0 Then
params.Add(New ReportParameter("ClienteContactoMail", Vta.Cliente.MailCotizacion))
params.Add(New ReportParameter("ClienteTelefono", If(Vta.TipoDocto.Contiene("Ing", "Rem") AndAlso Vta.Cliente.Telefono.Length > 6, Vta.Cliente.Telefono, Vta.TelefonoGenerico)))
params.Add(New ReportParameter("ClienteTelefono", If(Vta.TelefonoGenerico <> "", Vta.TelefonoGenerico, Vta.Cliente.Telefono)))
End If
If UsuarioActual.CveEmpresa.Contiene(17) Then
@@ -7925,7 +7925,7 @@ Public Class ClsPaginas
Dim DTDeducciones As Data.DataTable
Dim DTDeducciones2 As New Data.DataTable
Dim Ruta As String = RutaEmpresa
Dim Ruta As String = UsuarioActual.Empresa.Ruta
Dim PathXML As String = $"{Ruta}XML\Nomina\{ObjNomina.Serie }{If(indemnizacion, "F", "")}-{ObjNomina.Folio}.xml"
Dim FechaEmision, FechaCertificacion As DateTime
Dim FolioFiscal, NoSerieCertificado, NoSerieCertificadoContribuyente, SelloCFDi, SelloSAT As String

View File

@@ -523,7 +523,7 @@
</span>
</div>
<ajax:MaskedEditExtender ID="MEEFecha" runat="server" TargetControlID="TxtFechaDocumento" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
<ajax:CalendarExtender ID="Calendario" runat="server" TargetControlID="TxtFechaDocumento" PopupButtonID="ImgCalendario" PopupPosition="Left" Enabled="True"></ajax:CalendarExtender>
<ajax:CalendarExtender ID="Calendario" runat="server" TargetControlID="TxtFechaDocumento" PopupButtonID="ImgCalendario" PopupPosition="TopLeft" Enabled="True"></ajax:CalendarExtender>
<asp:RequiredFieldValidator ID="RFVFechaDocumento" runat="server" ControlToValidate="TxtFechaDocumento" Display="None" ErrorMessage="El campo <b>''FechaDocumento''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="CVFechaDocumento" runat="server" ControlToValidate="TxtFechaDocumento" Display="None" ErrorMessage="El campo <b>''FechaDocumento''</b> no tienes el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="GrpGuardar"></asp:CompareValidator>
<ajax:ValidatorCalloutExtender ID="VCOFechaDocumento1" runat="server" HighlightCssClass="vco" TargetControlID="RFVFechaDocumento" Width="350px"></ajax:ValidatorCalloutExtender>

View File

@@ -2562,7 +2562,7 @@ Partial Class Bancos_PopIECompras
If ObjMov.GetRetCuenta(ConceptoContable, UsuarioActual.CveEmpresa) And Not IdCtaContable > 0 Then
If ObjMov.DtResultados.Rows.Count > 0 Then
IdCtaContable = ObjMov.DtResultados.Rows(0)("IdCtaContable").ToString.ToEntero
IdCtaContable = ObjMov.DtResultados.Rows(0)("IdCuentaIVAxAcreditar").ToString.ToEntero
End If
End If
@@ -2703,7 +2703,7 @@ Partial Class Bancos_PopIECompras
If ObjMov.GetRetCuenta(ConceptoContable, UsuarioActual.CveEmpresa) And Not IdCtaContable > 0 Then
If ObjMov.DtResultados.Rows.Count > 0 Then
IdCtaContable = ObjMov.DtResultados.Rows(0)("IdCtaContable").ToString.ToEntero
IdCtaContable = ObjMov.DtResultados.Rows(0)("IdCuentaIVAAcreditable").ToString.ToEntero
End If
End If

View File

@@ -1109,6 +1109,8 @@ Partial Class Compras_Compras
End Set
End Property
Protected Sub Page_Load(sender As Object, e As System.EventArgs) Handles Me.Load
If Not IsPostBack Then
'ImgBtnBuscarOC.Attributes.Add("data-toggle", "tooltip")
@@ -1548,8 +1550,8 @@ Partial Class Compras_Compras
End If
'SE OCUPAN AFUERA DEL POSTBACK ??
cargaddlVinculacionServcios()
'SE OCUPAN AFUERA DEL POSTBACK ??
cargaddlVinculacionServcios()
If UsuarioActual.TienePermisoProceso(117) Then
HplAddClasificacion.Visible = False
@@ -4088,11 +4090,15 @@ Partial Class Compras_Compras
'DF - 10/04/2017
If UsuarioActual.TienePermisoProceso(187) Then
If TxtSerie.Text <> SerieVieja Then
Dim SerieNueva As String = GlobalDTProveedorSucursales(CveProveedor, UsuarioActual.CveEmpresa).FiltroPrimeroValor("Serie", $"Serie = '{TxtSerie.Text}'").ToString
If SerieNueva = "" Then
Alert("La Serie no es válida, por favor revise que se encuentre dentro de la lista de las sucursales del proveedor.", TipoMensaje.MsgAdvertencia)
Exit Sub
Dim dtt As DataTable = GlobalDTProveedorSucursales(CveProveedor, UsuarioActual.CveEmpresa)
If dtt IsNot Nothing AndAlso dtt.Rows.Count > 0 Then
Dim SerieNueva As String = dtt.FiltroPrimeroValor("Serie", $"Serie = '{TxtSerie.Text}'").ToString
If SerieNueva = "" Then
Alert("La Serie no es válida, por favor revise que se encuentre dentro de la lista de las sucursales del proveedor.", TipoMensaje.MsgAdvertencia)
Exit Sub
End If
End If
End If
End If
@@ -4385,6 +4391,8 @@ Partial Class Compras_Compras
Exit Sub
End If
'------------------TERMINA VALIDACIONES------------------
'si hay necesidad de actualizar el globaldtps
@@ -4633,20 +4641,7 @@ Partial Class Compras_Compras
If RBLPago.SelectedValue.ToEntero = 4 And EstatusCredito.Contiene(1, 101) Then
CveEstatusFactura = 6
End If
'hay amortización directa como descuento. RMF Temporal
If UsuarioActual.CveEmpresa = 119 Then
'If LblAmortizacion.Text.ToDouble > 0 AndAlso TxtDescuento.Text.ToDouble = 0 Then
' TxtDescuento.Text = LblAmortizacion.Text
' LblAmortizacion.Text = "0.00"
'End If
'o si el descuento es igual a la amortizacion
'If LblAmortizacion.Text.ToDouble = TxtDescuento.Text.ToDouble Then
' TxtDescuento.Text = LblAmortizacion.Text
' LblAmortizacion.Text = "0.00"
'End If
End If
'Compra
Dim CveFactura As Integer = -1
@@ -6698,7 +6693,7 @@ Partial Class Compras_Compras
CveMovimientoAlmacen = ObjOC.DtResultados.FiltroPrimeroValor("CveMovimientoAlmacen").ToEntero
Dim TCAjuste As Decimal = ObjOC.DtResultados.FiltroPrimeroValor("TipoCambioAjuste").ToDecimal
'RMF. falta verificar el costo indirecto de la OC
If DdlMoneda.SelectedValue.ToEntero <> 1 And UsuarioActual.CveEmpresa.Contiene(119) Then
If DdlMoneda.SelectedValue.ToEntero <> 1 Then
TCO = TxtTC.Text.ToDecimal
ImporteCI176 = ObjOC.DtResultados.FiltroPrimeroValor("ImporteCI228").ToDecimal
CostoIndirectoAcum176 += ImporteCI176
@@ -6884,7 +6879,7 @@ Partial Class Compras_Compras
Next
If ContienePSNeteoBonif Then
importeMovimiento = TmpDT.SUM(If(ListaDocumentos IsNot Nothing AndAlso ListaDocumentos.Count > 0 AndAlso ArrAnticipos IsNot Nothing AndAlso ArrAnticipos.Count > 0 AndAlso TxtTotal.Text.ToDecimal = 0, "ImporteSinImpuestos", "Total"), $"ISNULL(TipoAF,0) <> 2 And ISNULL(CveAlmacen,0) = 0 And ISNULL(AplicaCostoIndirecto,0) <> 1 ").ToString.ToDecimal
importeMovimiento = TmpDT.SUM(If(ListaDocumentos IsNot Nothing AndAlso ListaDocumentos.Count > 0 AndAlso ArrAnticipos IsNot Nothing AndAlso ArrAnticipos.Count > 0 AndAlso TxtTotal.Text.ToDecimal = 0, "ImporteSinImpuestos", "Total"), $"ISNULL(TipoAF,0) <> 2 And ISNULL(CveAlmacen,0) = 0 And ISNULL(AplicaCostoIndirecto,0) <> 1 AND CveClasificacion = 20319 ").ToString.ToDecimal
importeMN = importeMovimiento * tipoCambioActual * Multiplicador
Dim IdCtaContableDescCompra As Integer = UsuarioActual.Empresa.Funcionalidad(405).ToEntero
@@ -6905,8 +6900,6 @@ Partial Class Compras_Compras
End If
' adfasdasd
'ChkNCInvNC
If Not RegistroCuentaPuente AndAlso Not ChkNCInvNC.Checked Then
@@ -6968,9 +6961,11 @@ Partial Class Compras_Compras
DTDistinct.Clear()
End If
Dim tTipoMovimiento As Boolean = TipoMovimiento
If DTDistinct.Rows.Count > 0 Then
For Each Row2 As DataRow In DTDistinct.Rows
tTipoMovimiento = TipoMovimiento
'DETERMINA IMPORTE
If UsuarioActual.Empresa.Funcionalidad(126) = "1" Then
importeMovimiento = DT.SUM(If(ListaDocumentos IsNot Nothing AndAlso ListaDocumentos.Count > 0 AndAlso ArrAnticipos IsNot Nothing AndAlso ArrAnticipos.Count > 0 AndAlso TxtTotal.Text.ToDecimal = 0, "ImporteSinImpuestos", "Total"), String.Format("ISNULL(TipoAF,0) <> 2 And CveClasificacion = {0} And CveSubProyecto = {1} And ISNULL(CveTipoGasto,0) = {2}", Row2("CveClasificacion").ToString.ToEntero, Row2("CveSubProyecto").ToString.ToEntero, Row2("CveTipoGasto").ToString.ToEntero)).ToString.ToDecimal
@@ -6995,8 +6990,6 @@ Partial Class Compras_Compras
End If
'SEGMENTO DE NEGOCIO
Dim IdSegmentoNegocio As Integer = -1
Dim drT As DataRow = GlobalDTSubProyectos(-1, CveSubProyecto:=Row2("CveSubProyecto").ToString.ToEntero).FiltroPrimero(String.Format("CveSubProyecto = {0} ", Row2("CveSubProyecto").ToString.ToEntero))
@@ -7006,12 +6999,6 @@ Partial Class Compras_Compras
'AGREGA MOVIMIENTO
If importeMovimiento.RoundSQL <> 0 Then
'Conta ContPAQ
' If IdCtaContable = 0 Then
' CuentasContablesInvalidas.Append("<br>" & GlobalDTContaConceptosContables(-1).FiltroPrimero(String.Format("CveConceptoContable = {0}", 6))("ConceptoContable").ToString)
' idCuentaContabilizacion = 0
'End If
Dim tcvecon As Integer = 6
Dim tidctacon As Integer = 6
@@ -7027,17 +7014,23 @@ Partial Class Compras_Compras
tcvecon = 259
tidctacon = UsuarioActual.Empresa.Funcionalidad(405).ToEntero
ElseIf UsuarioActual.CveEmpresa = 119 AndAlso Row2("CveClasificacion").ToString = "20473" Then
'CODIGO FIJO, SI ES LA CLASIFICACION DE "SEGURO/SERVICIO COSTO", SE ABONARÁ
tTipoMovimiento = True
importeMovimiento = -importeMovimiento
importeMN = -importeMN
End If
Dim usacomplementariaProveedor As Boolean = False
usacomplementariaProveedor = If(tipoCambioActual > 1 AndAlso UsuarioActual.CveEmpresa.Contiene(1, 119, 158), True, False)
usacomplementariaProveedor = If(tipoCambioActual > 1, True, False)
If usacomplementariaProveedor AndAlso DdlTipoComprobante.SelectedValue = "Ant" Then
'importeMovimiento
Concepto = $"{NombreProveedor} {TxtSerie.Text} - {TxtFolio.Text}"
importeMN = tipoCambioActual * importeMovimiento - importeMovimiento
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, importeMovimiento, Referencia, 266, Concepto, FechaMovimiento, tidctacon, IdSegmentoNegocio, CveCompra:=CveCompra, CveProveedor:=CveProveedorConcepto, CveAcreedor:=CveAcreedor, CveIE:=CveIE, CveColectiva:=CveColectiva, CveCreditoDetalle:=CveCreditoDetalle, CveClasificacion:=Row2("CveClasificacion").ToString.ToEntero, CveSubProyecto:=Row2("CveSubProyecto").ToString.ToEntero, ImporteMX:=importeMN, ImporteME:=importeMovimiento, CveTipoGasto:=Row2("CveTipoGasto").ToString.ToEntero, TipoCambio:=tipoCambioActual, Contabilizable:=SeContabiliza) Then
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, tTipoMovimiento, importeMovimiento, Referencia, 266, Concepto, FechaMovimiento, tidctacon, IdSegmentoNegocio, CveCompra:=CveCompra, CveProveedor:=CveProveedorConcepto, CveAcreedor:=CveAcreedor, CveIE:=CveIE, CveColectiva:=CveColectiva, CveCreditoDetalle:=CveCreditoDetalle, CveClasificacion:=Row2("CveClasificacion").ToString.ToEntero, CveSubProyecto:=Row2("CveSubProyecto").ToString.ToEntero, ImporteMX:=importeMN, ImporteME:=importeMovimiento, CveTipoGasto:=Row2("CveTipoGasto").ToString.ToEntero, TipoCambio:=tipoCambioActual, Contabilizable:=SeContabiliza) Then
ErrorPrepoliza = True
End If
importeMN = importeMovimiento
@@ -7047,7 +7040,7 @@ Partial Class Compras_Compras
If Not Insertado205 Then
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, importeMovimiento, Referencia, tcvecon, Concepto, FechaMovimiento, tidctacon, IdSegmentoNegocio, CveCompra:=CveCompra, CveProveedor:=CveProveedorConcepto, CveAcreedor:=CveAcreedor, CveIE:=CveIE, CveColectiva:=CveColectiva, CveCreditoDetalle:=CveCreditoDetalle, CveClasificacion:=Row2("CveClasificacion").ToString.ToEntero, CveSubProyecto:=Row2("CveSubProyecto").ToString.ToEntero, ImporteMX:=importeMN, ImporteME:=If(tipoCambioActual = 1, 0, importeMovimiento), CveTipoGasto:=Row2("CveTipoGasto").ToString.ToEntero, TipoCambio:=tipoCambioActual, Contabilizable:=SeContabiliza) Then
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, tTipoMovimiento, importeMovimiento, Referencia, tcvecon, Concepto, FechaMovimiento, tidctacon, IdSegmentoNegocio, CveCompra:=CveCompra, CveProveedor:=CveProveedorConcepto, CveAcreedor:=CveAcreedor, CveIE:=CveIE, CveColectiva:=CveColectiva, CveCreditoDetalle:=CveCreditoDetalle, CveClasificacion:=Row2("CveClasificacion").ToString.ToEntero, CveSubProyecto:=Row2("CveSubProyecto").ToString.ToEntero, ImporteMX:=importeMN, ImporteME:=If(tipoCambioActual = 1, 0, importeMovimiento), CveTipoGasto:=Row2("CveTipoGasto").ToString.ToEntero, TipoCambio:=tipoCambioActual, Contabilizable:=SeContabiliza) Then
ErrorPrepoliza = True
End If
@@ -7068,7 +7061,7 @@ Partial Class Compras_Compras
End If
Case 5 'Proveedores
If CveTipoConcepto = 2 Then ConceptoContable = 305 'cuando es acreedor
Dim UsaComplementaria As Boolean = UsuarioActual.CveEmpresa.Contiene(119, 158)
Dim UsaComplementaria As Boolean = True
If tipoCambioActual <> 1 Then
Select Case ConceptoContable
Case 5
@@ -7374,7 +7367,7 @@ Partial Class Compras_Compras
End If
'AMORTIZACIÓN NC ESPECIAL COMPLEMENTARIA
If ConceptoContableAnticipo.Contiene(60) And DdlMoneda.SelectedValue.ToEntero <> 1 And UsuarioActual.CveEmpresa.Contiene(119) Then
If ConceptoContableAnticipo.Contiene(60) And DdlMoneda.SelectedValue.ToEntero <> 1 Then
Dim importeMovimientoNC = Ant.Importe
Dim importeMNNC = 0.0D
Dim TipoCambioNC = Ant.TCCompra
@@ -7435,7 +7428,7 @@ Partial Class Compras_Compras
End If
End If
ElseIf ConceptoContableAnticipo.Contiene(265) And DdlMoneda.SelectedValue.ToEntero <> 1 And UsuarioActual.CveEmpresa.Contiene(119) Then
ElseIf ConceptoContableAnticipo.Contiene(265) And DdlMoneda.SelectedValue.ToEntero <> 1 Then
Dim importeMovimientoNC = Ant.Importe
Dim importeMNNC = 0.0D
Dim TipoCambioNC = Ant.TCCompra
@@ -7530,7 +7523,7 @@ Partial Class Compras_Compras
Dim usacomplementariaAnticipo As Boolean = False
usacomplementariaAnticipo = If(Ant.TCCompra > 1 AndAlso UsuarioActual.CveEmpresa.Contiene(1, 119), True, False)
usacomplementariaAnticipo = If(Ant.TCCompra > 1, True, False)
Dim TipoCambioAnt As Decimal = Ant.TCCompra
@@ -7560,7 +7553,7 @@ Partial Class Compras_Compras
If CveTipoConcepto = 2 Then CveConceptoContableComplementaria = 307
Dim IdCtaContablePago As Integer = CtaProveedor
Dim usacomplementariaProveedor As Boolean = False
usacomplementariaProveedor = If(tipoCambioActual > 1 AndAlso UsuarioActual.CveEmpresa.Contiene(1, 119), True, False)
usacomplementariaProveedor = If(tipoCambioActual > 1, True, False)
If usacomplementariaProveedor Then
Concepto = $"{NombreProveedor} {TxtSerie.Text} - {TxtFolio.Text}"
importeMN = tipoCambioActual * importeMovimiento - importeMovimiento
@@ -8633,7 +8626,7 @@ Partial Class Compras_Compras
If Respuesta Then
Dim IEPSPSDetalles As Decimal = TmpDT.SUM("IEPSPS", " IEPSPS > 0 ").ToDecimal
Dim IEPSPSDetalles As Decimal = TmpDT.SUMD("IEPSPS", " IEPSPS > 0 ")
Dim DiferenciaIEPSPS As Decimal = TxtIEPS.Text.ToDecimal - IEPSPSDetalles
Dim DTConsultaIEPSPS As New DataTable
@@ -8652,7 +8645,7 @@ Partial Class Compras_Compras
IndiceContador = IndiceContador + 1
Next
If DiferenciaIEPSPS <> 0 Then
If DiferenciaIEPSPS.RoundAD(2) <> 0 Then
If DTConsultaIEPSPS.Rows.Count > 0 Then
'Ajusta IPES en primer registro que aplique IEPS
@@ -8660,7 +8653,7 @@ Partial Class Compras_Compras
TmpDT.AcceptChanges()
Else
Respuesta = False
Alert("Los productos especificados en el lisado no tienen asigando impuesto IEPS, favor de realizar la correción en el producto que aplique el impúesto.", TipoMensaje.MsgAdvertencia)
Alert(String.Format("Los productos especificados en el listado no tienen asigando impuesto IEPS, favor de realizar la corrección en el producto que aplique el impuesto. ({0}-{1})", IEPSPSDetalles, TxtIEPS.Text.ToDecimal), TipoMensaje.MsgAdvertencia)
End If
End If
@@ -8921,13 +8914,13 @@ Partial Class Compras_Compras
If DdlMoneda.SelectedValue.ToEntero <> 1 Then
IdCtaContable = CtaProveedorAnticiposExtranjera
If ObjConta.AddPrePolizasDetalle(CvePrePolizaNueva, TipoMovimiento, ImporteMovimiento, "", ConceptoContable, "", Fecha, IdCtaContable, -1, CveCompra:=CveCompraNC, CveProveedor:=CveProveedor, CveIE:=CveIE, ImporteMX:=ImporteMovimiento, CvePrePolizaOriginal:=CvePrePoliza, ImporteME:=ImporteMovimiento, TipoCambio:=tipoCambioNC, CveCompraAmortizacion:=CveCompra) Then
If UsuarioActual.CveEmpresa.Contiene(119) Then
IdCtaContable = CtaProveedorAnticiposComplementaria
If Not ObjConta.AddPrePolizasDetalle(CvePrePolizaNueva, TipoMovimiento, importeMN - ImporteMovimiento, "", 266, "", Fecha, IdCtaContable, -1, CveCompra:=CveCompraNC, CveProveedor:=CveProveedor, CveIE:=CveIE, ImporteMX:=importeMN - ImporteMovimiento, CvePrePolizaOriginal:=CvePrePoliza, ImporteME:=ImporteMovimiento, TipoCambio:=tipoCambioNC, CveCompraAmortizacion:=CveCompra) Then
ErrorMovtosCxP = 1
Exit Select
End If
IdCtaContable = CtaProveedorAnticiposComplementaria
If Not ObjConta.AddPrePolizasDetalle(CvePrePolizaNueva, TipoMovimiento, importeMN - ImporteMovimiento, "", 266, "", Fecha, IdCtaContable, -1, CveCompra:=CveCompraNC, CveProveedor:=CveProveedor, CveIE:=CveIE, ImporteMX:=importeMN - ImporteMovimiento, CvePrePolizaOriginal:=CvePrePoliza, ImporteME:=ImporteMovimiento, TipoCambio:=tipoCambioNC, CveCompraAmortizacion:=CveCompra) Then
ErrorMovtosCxP = 1
Exit Select
End If
Else
ErrorMovtosCxP = 1
Exit Select
@@ -8958,7 +8951,7 @@ Partial Class Compras_Compras
ImporteMovimiento = ImporteMovimiento / gvr.DataKey("TCCompra").ToDecimal
End If
If DdlMoneda.SelectedValue.ToEntero <> 1 And UsuarioActual.CveEmpresa.Contiene(119) Then
If DdlMoneda.SelectedValue.ToEntero <> 1 Then
IdCtaContable = CtaProveedorExtranjera
If ObjConta.AddPrePolizasDetalle(CvePrePolizaNueva, TipoMovimiento, ImporteMovimiento, ConceptoPartida, ConceptoContable, ConceptoPartida, Fecha, IdCtaContable, -1, CveCompra:=CveCompraNC, CveProveedor:=CveProveedor, CveIE:=CveIE, ImporteMX:=ImporteMovimiento, CvePrePolizaOriginal:=CvePrePoliza, ImporteME:=ImporteMovimiento, TipoCambio:=tipoCambioNC, CveCompraAmortizacion:=CveCompra) Then
IdCtaContable = CtaProveedorComplementaria
@@ -9004,7 +8997,7 @@ Partial Class Compras_Compras
Dim TipoCambioAnt = gvr.DataKey("TCCompra").ToDecimal
Dim usacomplementariaAnticipo As Boolean = False
usacomplementariaAnticipo = If(TipoCambioAnt > 1 AndAlso UsuarioActual.CveEmpresa.Contiene(1, 119), True, False)
usacomplementariaAnticipo = If(TipoCambioAnt > 1, True, False)
Dim ImporteAnt As Decimal = ImporteMovimiento
@@ -9103,7 +9096,7 @@ Partial Class Compras_Compras
ImporteMovimiento = sumaAmortizacion
importeMN = ImporteMovimiento * TipoCambio17
If DdlMoneda.SelectedValue.ToEntero <> 1 And UsuarioActual.CveEmpresa.Contiene(119) Then
If DdlMoneda.SelectedValue.ToEntero <> 1 Then
IdCtaContable = CtaProveedorExtranjera
If ObjConta.AddPrePolizasDetalle(CvePrePolizaNueva, TipoMovimiento, ImporteMovimiento, Concepto, ConceptoContable, Concepto, Fecha, IdCtaContable, -1, CveCompra:=CveCompra, CveCompraAmortizacion:=CveCompraNC, CveProveedor:=CveProveedor, CveIE:=CveIE, ImporteMX:=ImporteMovimiento, CvePrePolizaOriginal:=CvePrePoliza, ImporteME:=ImporteMovimiento, TipoCambio:=TipoCambio17) Then
@@ -11037,18 +11030,6 @@ Partial Class Compras_Compras
If Not (e.Row.RowState = DataControlRowState.Edit OrElse e.Row.RowState = 5) Then
If e.Row.RowIndex = 0 Then
'e.Row.Cells(0).Width = Unit.Pixel(15)
'e.Row.Cells(1).Width = Unit.Pixel(45)
'e.Row.Cells(2).Width = Unit.Pixel(70)
'e.Row.Cells(3).Width = Unit.Pixel(230)
'e.Row.Cells(4).Width = Unit.Pixel(202)
'e.Row.Cells(5).Width = Unit.Pixel(155)
'e.Row.Cells(6).Width = Unit.Pixel(155)
'e.Row.Cells(7).Width = Unit.Pixel(50)
'e.Row.Cells(8).Width = Unit.Pixel(80)
'e.Row.Cells(9).Width = Unit.Pixel(80)
'e.Row.Cells(10).Width = Unit.Pixel(43)
'e.Row.Cells(11).Width = Unit.Pixel(43)
If UsuarioActual.Empresa.UsaAC Then 'AndAlso (CveFactura > 0 Or CveCompra > 0)
e.Row.Cells(13).Width = Unit.Pixel(150)
@@ -11239,10 +11220,6 @@ Partial Class Compras_Compras
GvPS.DataSource = TmpDT
GvPS.DataBind()
'GVAF.DataSource = TmpDT
'GVAF.DataBind()
''UpnAF.Update()
CalculaTotales(True)
CargaGvInv()
CargaGVsAF()
@@ -11274,17 +11251,7 @@ Partial Class Compras_Compras
Private Sub GeneraGlobalDT(data As Object)
GlobalDTPSSimplificado(UsuarioActual.CveEmpresa) = Nothing
GlobalDTProductosServiciosEquivalencias(-1, -1, UsuarioActual.CveEmpresa) = Nothing
'Dim ObjPS As New ClsProductosServicios
'If (ObjPS.GetPSSimplificado(-1)) Then
' Application("GlobalDTPSSimplificado") = ObjPS.DtResultados.AsEnumerable
'End If
'If ObjPS.GetPSEquivalencias(-1, -1) Then
' GlobalDTProductosServiciosEquivalencias(-1, -1, UsuarioActual.CveEmpresa) = ObjPS.DtResultados
'End If
'ObjPS.Dispose()
End Sub
Private Function notienepresupuesto() As Boolean
Dim notienerecursos = False
@@ -11357,21 +11324,7 @@ Partial Class Compras_Compras
DTConceptos.Columns.Add("Total", GetType(Double))
DTConceptos.Columns.Add("Amortizacion", GetType(Double))
End Sub
'Private Sub AddPS(Cantidad As Double, UM As String, PS As String, PU As Double, IVA As Double, Descuento As Double, Optional Total As Double = 0)
' Dim Row As DataRow = Nothing
' Row = DTConceptos.NewRow()
' Row("Consec") = DTConceptos.Rows.Count + 1
' Row("Cantidad") = Cantidad
' Row("UM") = UM
' Row("CveClasificacion") = -1
' Row("PS") = PS
' Row("PU") = PU
' Row("IVA") = IVA
' Row("Total") = If(Total > 0, Total, Cantidad * PU)
' Row("Descuento") = Descuento
' DTConceptos.Rows.Add(Row)
'End Sub
Private Sub CreaDTCompras()
TmpDT = New DataTable
@@ -11599,26 +11552,6 @@ Partial Class Compras_Compras
End Sub
'Private Sub AddDTEnvio(Cantidad As Double, UM As String, CveUM As Integer, CvePS As Integer, PS As String, PU As Double, CveAlmacen As Integer, CveEq As Integer)
' Dim dr As DataRow = DtInv.NewRow
' dr("Cantidad") = Cantidad
' dr("UM") = UM
' dr("CveUM") = CveUM
' dr("CvePS") = CvePS
' dr("PS") = PS
' dr("PU") = PU
' dr("CveAlmacen") = CveAlmacen
' dr("CveEq") = CveEq
' DtInv.Rows.InsertAt(dr, hdnIndexInv.Value.ToEntero + 1)
' GvInv.DataSource = DtInv
' GvInv.DataBind()
'End Sub
Protected Sub RecargaMaximum_Click(sender As Object, e As System.EventArgs)
@@ -11719,62 +11652,6 @@ Partial Class Compras_Compras
#End Region
#Region " ALGO DE AF QUE NUNCA SE USABA "
'Protected Sub GVAF_RowCreated(sender As Object, e As System.Web.UI.WebControls.GridViewRowEventArgs) Handles GVAF.RowCreated
' If e.Row.RowType = DataControlRowType.DataRow AndAlso (e.Row.RowState = DataControlRowState.Alternate OrElse e.Row.RowState = DataControlRowState.Normal) Then
' e.Row.FCDropDownList("DdlTipoActivoFijo").DataSource = TmpDTTiposAF
' e.Row.FCDropDownList("DdlTipoActivoFijo").DataBind()
' e.Row.FCDropDownList("DdlSubTipoActivoFijo").DataSource = Nothing
' e.Row.FCDropDownList("DdlSubTipoActivoFijo").DataBind()
' e.Row.FCDropDownList("DdlSubTipoActivoFijo").Items.Insert(0, New ListItem("Seleccione", "-1"))
' e.Row.FCDropDownList("DdlAF").DataSource = Nothing
' e.Row.FCDropDownList("DdlAF").DataBind()
' e.Row.FCDropDownList("DdlAF").Items.Insert(0, New ListItem("Seleccione", "-1"))
' End If
'End Sub
'Protected Sub GVAF_RowDataBound(sender As Object, e As System.Web.UI.WebControls.GridViewRowEventArgs) Handles GVAF.RowDataBound
' If e.Row.RowType = DataControlRowType.DataRow Then
' If e.Row.RowIndex = 0 Then
' e.Row.Cells(0).Width = Unit.Pixel(20)
' e.Row.Cells(1).Width = Unit.Pixel(140)
' e.Row.Cells(2).Width = Unit.Pixel(250)
' End If
' e.Row.Cells(0).HorizontalAlign = HorizontalAlign.Right
' e.Row.Cells(1).HorizontalAlign = HorizontalAlign.Left
' e.Row.Cells(2).HorizontalAlign = HorizontalAlign.Left
' End If
'End Sub
'Protected Sub DdlTipoActivoFijo_SelectedIndexChanged(sender As Object, e As System.EventArgs)
' Dim Array() As String = Nothing
' Dim DdlGVSubTipoAF As DropDownList = Nothing
' Array = DirectCast(sender, DropDownList).ClientID.Split("_"c)
' If Array.Length > 0 Then
' DdlGVSubTipoAF = DirectCast(GVAF.Rows(Array(3).ToEntero).Controls(4).Controls(1), DropDownList)
' End If
' If DdlGVSubTipoAF IsNot Nothing Then CargaSubTipoAF(DirectCast(sender, DropDownList), DdlGVSubTipoAF)
'End Sub
'Protected Sub GvOCC2_RowDataBound(sender As Object, e As GridViewRowEventArgs) Handles GvOCC2.RowDataBound
' If e.Row.RowType = DataControlRowType.DataRow Then
' e.Row.Cells(0).Text = (e.Row.RowIndex + 1).ToString
' End If
'End Sub
'Protected Sub chkFuncionariosEmpleados_CheckedChanged(sender As Object, e As EventArgs) Handles chkFuncionariosEmpleados.CheckedChanged
' PnlPagoContado.Visible = Not chkFuncionariosEmpleados.Checked
' PnlFuncionarioEmpleado.Visible = chkFuncionariosEmpleados.Checked
' UPCondicionesPago.Update()
'End Sub
Protected Sub BtnOCAceptar_Click(sender As Object, e As EventArgs) Handles BtnOCAceptar.Click
'carga la OC
Dim CveOC As Integer = -1
@@ -11804,13 +11681,6 @@ Partial Class Compras_Compras
OC.Dispose()
End If
'GvOCC.DataSource = TmpDT
'GvOCC.DataBind()
'GvOCC2.DataSource = dt
'GvOCC2.DataBind()
'UpnAF.Update()
End Sub
#End Region
@@ -12877,12 +12747,6 @@ Partial Class Compras_Compras
Dim dr As DataRow
dr = DtAcreedores.FiltroPrimero(String.Format("CveProveedor = {0}", DdlAcreedor.SelectedValue))
'If EmpresaPrueba Then
' dr = DtAcreedores.FiltroPrimero(String.Format("CveProveedor = {0}", DdlAcreedor.SelectedValue))
'Else
' dr = DtAcreedores.FiltroPrimero(String.Format("CveProveedor = {0}", DdlDeudor.SelectedValue))
'End If
If dr IsNot Nothing Then
Dim tSaldo As Double = dr("Saldo").ToString.ToDouble
@@ -12972,12 +12836,6 @@ Partial Class Compras_Compras
UpTabs.Update()
'DdlProveedor.Attributes.Add("onclick", "CargaProveedores();")
End Sub
Protected Sub DdlCuenta_SelectedIndexChanged(sender As Object, e As EventArgs) Handles DdlCuenta.SelectedIndexChanged
Dim Folio As Long
@@ -13528,12 +13386,6 @@ Partial Class Compras_Compras
For Each gvr As GridViewRow In GvPS.Rows
dr = TmpDT.Rows(gvr.RowIndex)
'DtDetalle.Rows(gvr.RowIndex)("CveClasificacionOG") = gvr.FCDropDownList("DdlAC5").SelectedValue.ToEntero
'DtDetalle.Rows(gvr.RowIndex)("CveProgramaOperativo") = gvr.FCDropDownList("DdlAC1").SelectedValue.ToEntero
'DtDetalle.Rows(gvr.RowIndex)("CveUnidadAdministrativa") = gvr.FCDropDownList("DdlAC2").SelectedValue.ToEntero
'DtDetalle.Rows(gvr.RowIndex)("CveFuenteFinanciamiento") = gvr.FCDropDownList("DdlAC3").SelectedValue.ToEntero
'DtDetalle.Rows(gvr.RowIndex)("CveTipoGasto") = gvr.FCDropDownList("DdlAC4").SelectedValue.ToEntero
dr("CveProgramaOperativo") = gvr.FCDropDownList("DdlAC1").SelectedValue.ToEntero
dr("CveUnidadAdministrativa") = gvr.FCDropDownList("DdlAC2").SelectedValue.ToEntero
dr("CveFuenteFinanciamiento") = gvr.FCDropDownList("DdlAC3").SelectedValue.ToEntero
@@ -18080,6 +17932,12 @@ Partial Class Compras_Compras
TxtRetISRModal.Text = FormatoNumero(ViewState("RetISR").ToString().ToDouble * 100, 0)
If (CveFactura > 0 Or CveCompra > 0) And TxtIEPS.Text.ToDecimal = 0 And PS("IEPSPorcentaje").ToString.ToDecimal > 0 Then
TxtIEPSModal.Text = "0"
Alert("El producto seleccionado contiene IEPS, pero el acumulado de la factura no contiene IEPS, por lo que no se agregara el impuesto.", TipoMensaje.MsgAdvertencia)
End If
UpIVA.Update()
If PS("CveClasificacion").ToString IsNot Nothing Then
@@ -18473,6 +18331,13 @@ Partial Class Compras_Compras
End If
'Esta parte es para validar cuando la factura tenga ieps en o se asignara el ieps como una partida ya no se considere
If (CveFactura > 0 Or CveCompra > 0) And TxtIEPS.Text.ToDecimal = 0 Then
Row("IEPSPS") = 0
Row("IEPSPSPorcentaje") = 0
End If
TmpDT.Rows.Add(Row)
TmpDT.Rows.IndexOf(Row)
@@ -18603,6 +18468,13 @@ Partial Class Compras_Compras
DrPS("IEPSPSIVAPorcentaje") = IEPSPSIVA
'Esta parte es para validar cuando la factura tenga ieps en o se asignara el ieps como una partida ya no se considere
If (CveFactura > 0 Or CveCompra > 0) And TxtIEPS.Text.ToDecimal = 0 Then
DrPS("IEPSPS") = 0
DrPS("IEPSPSPorcentaje") = 0
End If
AplicaCalculaTotales = True
'End If
@@ -19813,6 +19685,7 @@ Partial Class Compras_Compras
Dim CvePS As Integer = DdlConceptoIEPS.SelectedValue.ToEntero
' If CvePS = -1 Then CvePS = UsuarioActual.Empresa.Funcionalidad(112).ToString.ToEntero
AgregarConceptoIEPS(TrasladoIEPS, CvePS)
TrasladoIEPS = 0
TxtIEPS.Text = 0.ToString.FormatoNumero
TrIEPS.Visible = False
@@ -19827,6 +19700,7 @@ Partial Class Compras_Compras
Dim CvePS As Integer = DdlConceptoOI.SelectedValue.ToEntero
'If CvePS = -1 Then CvePS = UsuarioActual.Empresa.Funcionalidad(305).ToString.ToEntero
AgregarConceptoIEPS(OtrosImpuestos, CvePS)
OtrosImpuestos = 0
TxtOtrosImpuestos.Text = 0.ToString.FormatoNumero
TrOtrosImpuestos.Visible = False
@@ -19841,7 +19715,7 @@ Partial Class Compras_Compras
MostrarOcultarColumnaIEPS()
AddPS2()
End Sub
#End Region

View File

@@ -4437,7 +4437,7 @@ Partial Class PopUpVerFactura
RepParams.Add(New ReportParameter("AsignadoA", pUsuarioEntregar))
RepParams.Add(New ReportParameter("UsuarioImprimio", UsuarioActual.Nombre))
ImprimirPDF($"Empresas/{UsuarioActual.CveEmpresa}/Formatos/EntregasPorRealizar.rdlc", DtPaqueteriasGuias, RepParams, "Entregas por realizar", "PDF", RDSName:="DsInventarios")
ImprimirPDF($"{UsuarioActual.Empresa.Ruta}Formatos\EntregasPorRealizar.rdlc", DtPaqueteriasGuias, RepParams, "Entregas por realizar", "PDF", RDSName:="DsInventarios")
End If
End Sub

View File

@@ -149,17 +149,21 @@ Partial Class Compras_RepProductosServiciosDetalle
'DdlCategoria.SelectedValueExist(Categoria)
DdlClasificacion.SelectedValueExist(Clasificacion)
If PS <> "-1" Then
If PS.ToEntero > 1 Then
DdlPS.SelectedValue = PS
DdlPS.SelectedText = GlobalDTPS(UsuarioActual.CveEmpresa, CvePS:=PS.ToEntero)(0)("PSCodigo").ToString
DdlPS.SelectedText = GlobalDTPS(UsuarioActual.CveEmpresa, CvePS:=PS.ToEntero).FiltroPrimeroValor("PSCodigo")
End If
'DdlSubProyecto.SelectedValueExist(SubProyecto)
DdlFamilia.SelectedValueExist(Familia)
DdlSubFamilia.SelectedValueExist(SubFamilia)
DdlProveedor.SelectedValue = Proveedor
If Proveedor.ToEntero > 0 Then
DdlProveedor.SelectedText = GlobalDTCompProveedores(UsuarioActual.CveEmpresa).FiltraParametros($"CveProveedor = {Proveedor}").Rows(0)("RazonSocial").ToString
Dim Dr As DataRow = GlobalDTCompProveedores(UsuarioActual.CveEmpresa, Proveedor.ToEntero).FiltroPrimero("")
If Dr IsNot Nothing Then
DdlProveedor.SelectedText = Dr("RazonSocial").ToString
DdlProveedor.SelectedValue = Proveedor
End If
Else
DdlProveedor.SelectedText = "Todos"
End If
@@ -200,8 +204,10 @@ Partial Class Compras_RepProductosServiciosDetalle
DdlClasificacion.DataBind()
'CargaProveedor
DdlProveedor.DataSource = GlobalDTCompProveedores(UsuarioActual.CveEmpresa)
DdlProveedor.DataBind()
DdlProveedor.setEsWebService(True)
DdlProveedor.Attributes.Add("data-metodo", "getproveedores")
DdlProveedor.SelectedText = "Todos"
DdlProveedor.SelectedValue = "-1"
'CargaUsuarios
DdlUsuario.DataSource = GlobalDTUsuarios.FiltraParametros("CveEmpresa = " & UsuarioActual.CveEmpresa)

View File

@@ -371,6 +371,7 @@ Partial Class ContabilidadC_RegPrePoliza
.Add("ContadoImporte", Type.GetType("System.Double"))
.Add("ContadoBeneficiario", Type.GetType("System.String"))
.Add("ContadoObservaciones", Type.GetType("System.String"))
.Add("FolioPoliza", Type.GetType("System.Int32"))
End With
End Sub

View File

@@ -4,28 +4,7 @@
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="Css" Runat="Server">
<style>
table.GVEstimacion{
width:100%;
}
.txtimporte{
/*background: transparent;*/
/*border: none;*/
}
.txtcant,.txtimporte,
table.GVEstimacion > tbody > tr > td,
table.GVEstimacion > tbody > tr > th{
text-align:right;
}
table.GVEstimacion > tbody > tr > th,
table.GVEstimacion > tbody > tr > td{
width:100px;
}
table.GVEstimacion > tbody > tr > th:nth-child(1),
table.GVEstimacion > tbody > tr > td:nth-child(1){
width:300px;
text-align:left;
}
.ddls {
max-width:220px;
}
@@ -85,8 +64,8 @@
Fecha:
</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: 120px !important; padding: 0px;">
<asp:TextBox ID="TxtFecha" runat="server" CssClass="form-control" CausesValidation="true" Style="width: 118px" MaxLength="10"></asp:TextBox>
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 90px !important; padding: 0px;">
<asp:TextBox ID="TxtFecha" runat="server" CssClass="form-control" CausesValidation="true" Style="width: 88px" MaxLength="10"></asp:TextBox>
<span class="input-group-btn ">
<asp:LinkButton ID="ImgFecha" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
</span>
@@ -113,18 +92,18 @@
<table class="table table-striped Widthall">
<tr>
<th style="width: 400px;"></th>
<th style="width: 100px;"></th>
<th style="width: 100px;"></th>
<th style="width: 100px;"></th>
<th style="width: 100px;"></th>
<th style="width: 100px;"></th>
<th style=""></th>
<th style="width: 100px;"></th>
<th style="width: 100px;"></th>
<th style="width: 100px;"></th>
<th style="width: 120px;"></th>
<th style="width: 120px;"></th>
<th style="width: 120px;"></th>
<th style="width: 50px;"></th>
<th style="width: 50px;"></th>
</tr>
<tr>
<th>Producto / Servicio</th>
<th>Concepto</th>
<th colspan="2">Avance</th>
<th colspan="2">Ultimo Avance</th>
<th colspan="2">Levantamiento</th>
@@ -138,7 +117,7 @@
<asp:GridView ID="Gv" runat="server" AutoGenerateColumns="false" EmptyDataText="No se encontraron partidas para levantar avance"
DataKeyNames="CveFamilias,CveSubFamilias,CveContratoDetalle,PS,Cantidad,Importe,Cantidad_Ultima,Importe_Ultima,PU,CantidadMax,Avance"
CssClass="table GVEstimacion table-advance table-hover mysmallbtn" GridLines="None">
CssClass="table table-advance table-hover mysmallbtn" GridLines="None">
<Columns>
<asp:TemplateField HeaderText="">
<ItemTemplate>
@@ -147,58 +126,53 @@
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Cantidad Total">
<ItemTemplate>
<asp:TemplateField HeaderText="Cant. Total" ItemStyle-Width="80px" ItemStyle-HorizontalAlign="Right">
<ItemTemplate >
<span><%# Eval("CantidadTotal", "{0:N2}")%></span>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="UM">
<asp:TemplateField HeaderText="UM" ItemStyle-Width="60px">
<ItemTemplate>
<span><%# Eval("Abreviatura")%></span>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Cantidad">
</asp:TemplateField>
<asp:TemplateField HeaderText="Cantidad" ItemStyle-Width="80px" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<span><%# Eval("Cantidad", "{0:N2}")%></span>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Importe">
<asp:TemplateField HeaderText="Importe" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<span><%# Eval("Importe", "{0:N2}")%></span>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Cantidad">
<asp:TemplateField HeaderText="Cantidad" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<span><%# Eval("Cantidad_Ultima", "{0:N2}")%></span>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Importe">
<asp:TemplateField HeaderText="Importe" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<span><%# Eval("Importe_Ultima", "{0:N2}")%></span>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Cantidad">
<asp:TemplateField HeaderText="Cantidad" ItemStyle-Width="70px" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:TextBox ID="TxtCantidad" Text="" CssClass="txtcant" type="number" step="any" data-cantidad='<%# Eval("CantidadMax")%>' data-pu='<%# Eval("PU")%>' data-cve='<%# Eval("CveContratoDetalle") %>' Width="90" runat="server"></asp:TextBox>
<asp:TextBox ID="TxtCantidad" Text="" CssClass="txtcant" type="number" step="any" data-cantidad='<%# Eval("CantidadMax")%>' data-pu='<%# Eval("PU")%>' data-cve='<%# Eval("CveContratoDetalle") %>' Width="70" runat="server"></asp:TextBox>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Importe">
<asp:TemplateField HeaderText="Importe" ItemStyle-Width="90px" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:TextBox ID="TxtImporte" Text="" CssClass="txtimporte" data-cve='<%# Eval("CveContratoDetalle") %>' type="number" step="any" Width="90" runat="server"></asp:TextBox>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Porcentaje">
<asp:TemplateField HeaderText="Porcentaje" ItemStyle-Width="50px">
<ItemTemplate>
<asp:TextBox ID="TxtPorcentaje" Text="" CssClass="txtporcentaje" data-cve='<%# Eval("CveContratoDetalle") %>' type="number" step="any" Width="90" runat="server"></asp:TextBox>
<asp:TextBox ID="TxtPorcentaje" Text="" CssClass="txtporcentaje" data-cve='<%# Eval("CveContratoDetalle") %>' type="number" step="any" Width="70" runat="server"></asp:TextBox>
</ItemTemplate>
</asp:TemplateField>
</asp:TemplateField>
<asp:TemplateField HeaderText=" ">
<ItemTemplate>
@@ -231,15 +205,11 @@
</div>
</div>
</div>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="">
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText=" ">
<ItemTemplate>
<asp:LinkButton ID="LnkGuardarAvance" Text="Guardar" CssClass="btn btn-primary" runat="server" OnClick="LnkGuardarAvance_Click" Visible="false" Height="30px" ValidationGroup="GrpGuardar"></asp:LinkButton>
<asp:LinkButton ID="LnkGuardarAvance" Text="" CssClass="btn btn-primary btn-sm" runat="server" OnClick="LnkGuardarAvance_Click" Visible="false" ValidationGroup="GrpGuardar" ToolTip="Guardar"><i class='fa fa-save'></i></asp:LinkButton>
</ItemTemplate>
</asp:TemplateField>
@@ -258,13 +228,7 @@
</ContentTemplate>
</asp:UpdatePanel>
<div class="modal fade " id="dropmodal">
<div class="modal-dialog">

View File

@@ -194,8 +194,6 @@ Partial Class Contratos_ContratoAvance
e.Row.FCTextBox("TxtPorcentaje").Visible = False
'txtimporte
e.Row.FCLinkButton("LnkAnexo").Visible = False
@@ -241,13 +239,7 @@ Partial Class Contratos_ContratoAvance
LnkGuardarAvance.Visible = False
End If
End If
End If
End Sub
Protected Sub GetAnexos(sender As Object, e As System.EventArgs)

View File

@@ -309,7 +309,7 @@
<ContentTemplate>
<div class="row">
<div class="col-md-6">
<div class="portlet smmallpadding light bordered">
<div class="portlet smallpadding light bordered">
<div class="portlet-title">
<div class="tools">
<a href="javascript;" data-idchekbox="C_chkexpand" class=" collapse" data-original-title="" title=""></a><span class="hidden">

View File

@@ -1115,9 +1115,7 @@ Partial Class Contratos_ContratoObra
Else
ObjContratos.Commit()
If ObjContratos.GetContratos(-1, -1) Then
Application("GlobalDTContratos") = ObjContratos.DtResultados
End If
GlobalDTContratos(UsuarioActual.CveEmpresa) = Nothing
Limpiar()
If Modificado Then
@@ -4387,7 +4385,7 @@ Partial Class Contratos_ContratoObra
DTCargaPresupuesto = CargaPresupuestoExcel("Presupuesto")
If DTCargaPresupuesto.Rows.Count > 0 Then
ProcesaDatosCargaPresupuesto(DTCargaPresupuesto, Nothing, Nothing, Nothing)
ProcesaDatosCargaPresupuesto(EnumTipoCargaPresupuesto.Ventas, DTCargaPresupuesto, Nothing, Nothing, Nothing)
Else
Alert("No se encintraron partidas en el documento", TipoMensaje.MsgAdvertencia)
End If
@@ -4399,7 +4397,7 @@ Partial Class Contratos_ContratoObra
DTCargaPresupuestoFlotillas = CargaPresupuestoExcel("Maquinaria")
DTCargaPresupuestoIndirectos = CargaPresupuestoExcel("Indirectos")
ProcesaDatosCargaPresupuesto(DTCargaPresupuesto, DTCargaPresupuestoManoObra, DTCargaPresupuestoFlotillas, DTCargaPresupuestoIndirectos)
ProcesaDatosCargaPresupuesto(EnumTipoCargaPresupuesto.Control, DTCargaPresupuesto, DTCargaPresupuestoManoObra, DTCargaPresupuestoFlotillas, DTCargaPresupuestoIndirectos)
End If
@@ -4476,7 +4474,7 @@ Partial Class Contratos_ContratoObra
End Function
Private Sub ProcesaDatosCargaPresupuesto(DTPresupuesto As DataTable, DTCargaPresupuestoManoObra As DataTable, DTCargaPresupuestoFlotillas As DataTable, DTCargaPresupuestoIndirectos As DataTable)
Private Sub ProcesaDatosCargaPresupuesto(TipoPresupuesto As EnumTipoCargaPresupuesto, DTPresupuesto As DataTable, DTCargaPresupuestoManoObra As DataTable, DTCargaPresupuestoFlotillas As DataTable, DTCargaPresupuestoIndirectos As DataTable)
If Not DTPresupuesto Is Nothing Then
@@ -4548,16 +4546,23 @@ Partial Class Contratos_ContratoObra
End If
End If
'si el presupuesto es de ventas. solo valida con el codigo del producto
'si es presupuesto es de control, valida por ambos
If CvePS = -1 Then
StrArray = GetPS("PS", DrowPS("Producto").ToString).Split("|"c)
If StrArray.Length > 0 Then
If CBool(StrArray(0)) = True Then
CvePS = StrArray(1).ToEntero
'si es presup ventas, busca por producto,
If TipoPresupuesto = EnumTipoCargaPresupuesto.Control Then
StrArray = GetPS("PS", DrowPS("Producto").ToString).Split("|"c)
If StrArray.Length > 0 Then
If CBool(StrArray(0)) = True Then
CvePS = StrArray(1).ToEntero
End If
End If
End If
If CvePS = -1 Then
Dim ObjPS As New ClsProductosServicios

View File

@@ -1,282 +1,277 @@
<%@ Page Title="" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="ContratoObraAutorizacion.aspx.vb" Inherits="Contratos_ContratoObraAutorizacion" %>
<asp:Content ID="Content1" ContentPlaceHolderID="CP" Runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="Css" Runat="Server">
<style>
table.GVEstimacion{
width:100%;
}
.txtimporte{
background: transparent;
border: none;
}
.txtcant,.txtimporte,
table.GVEstimacion > tbody > tr > td,
table.GVEstimacion > tbody > tr > th{
text-align:right;
}
table.GVEstimacion > tbody > tr > th,
table.GVEstimacion > tbody > tr > td{
width:100px;
}
table.GVEstimacion > tbody > tr > th:nth-child(1),
table.GVEstimacion > tbody > tr > td:nth-child(1){
width:300px;
text-align:left;
}
.ddls {
max-width:220px;
}
.linkfile input{
display:none
}
</style>
<link href="/Metronic/assets/global/plugins/dropzone/css/dropzone.css" rel="stylesheet"/>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="E" Runat="Server">
Autorización de Avance
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="HB" Runat="Server">
</asp:Content>
<asp:Content ID="Content5" ContentPlaceHolderID="H" Runat="Server">
</asp:Content>
<asp:Content ID="Content6" ContentPlaceHolderID="C" runat="Server">
<asp:UpdatePanel runat="server" ID="UpEstimaciones" UpdateMode="Conditional">
<ContentTemplate>
<%@ Page Title="" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="ContratoObraAutorizacion.aspx.vb" Inherits="Contratos_ContratoObraAutorizacion" %>
<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="Css" runat="Server">
<style>
table.GVEstimacion {
width: 100%;
}
.txtimporte {
background: transparent;
border: none;
}
.txtcant, .txtimporte,
table.GVEstimacion > tbody > tr > td,
table.GVEstimacion > tbody > tr > th {
text-align: right;
}
table.GVEstimacion > tbody > tr > th,
table.GVEstimacion > tbody > tr > td {
width: 100px;
}
table.GVEstimacion > tbody > tr > th:nth-child(1),
table.GVEstimacion > tbody > tr > td:nth-child(1) {
width: 300px;
text-align: left;
}
.ddls {
max-width: 220px;
}
.linkfile input {
display: none
}
</style>
<link href="/Metronic/assets/global/plugins/dropzone/css/dropzone.css" rel="stylesheet" />
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="E" runat="Server">
Autorización de Avance
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="HB" runat="Server">
</asp:Content>
<asp:Content ID="Content5" ContentPlaceHolderID="H" runat="Server">
</asp:Content>
<asp:Content ID="Content6" ContentPlaceHolderID="C" runat="Server">
<asp:UpdatePanel runat="server" ID="UpEstimaciones" UpdateMode="Conditional">
<ContentTemplate>
<div class="portlet solid grey-cascade portlet-filter">
<div class="portlet-title portlet-filterT smalltitle">
<div class="portlet solid grey-cascade portlet-filter">
<div class="portlet-title portlet-filterT smalltitle">
<div class="tools">
<asp:Button ID="BtnConsultarEstimaciones" runat="server" Text="Consultar" class="btn btn-default" />
<div class="tools">
<asp:Button ID="BtnConsultarEstimaciones" runat="server" Text="Consultar" class="btn btn-default" />
</div>
<div class="titlefiltros caption" style="position: relative;">
<asp:UpdatePanel class="row" ID="UpdatePanel2" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<label class="col-md-1 truncate">Contrato:</label>
<div class="col-md-6 col-lg-4">
<div class="ddls">
<asp:DropDownList ID="DDlContratosEstimaciones" runat="server" DataTextField="ContratoCompleto" DataValueField="CveContrato" Class=" form-control input-inline select2me" Width="100%">
</asp:DropDownList>
</div>
</div>
</ContentTemplate>
</asp:UpdatePanel>
</div>
</div>
</div>
<div class="row">
<div class="col-md-6" style="text-align: right!important">
</div>
<div class="titlefiltros caption" style="position: relative;">
<asp:UpdatePanel class="row" ID="UpdatePanel2" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<label class="col-md-1 truncate">Contrato:</label>
<div class="col-md-6 col-lg-4">
<div class="ddls">
<asp:DropDownList ID="DDlContratosEstimaciones" runat="server" DataTextField="ContratoCompleto" DataValueField="CveContrato" Class=" form-control input-inline select2me" Width="100%">
</asp:DropDownList>
<div class="col-md-6" style="text-align: right!important">
<div style="display: inline-block">
<input type="text" id="TxtBusqueda" class="form-control input-sm" onkeyup="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GvEstimaciones.ClientID) %>" style="display: inline-block; margin-right: -20px; width: 150px; height: 25px; border-color: #89C4F4;" />
<a href="javascript:;" onclick="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GvEstimaciones.ClientID) %>" class="btn btn-circle btn-sm label-info"><i class="icon-magnifier"></i></a>
</div>
</div>
</div>
<br />
<div class="row">
<div class="col-md-12">
<asp:GridView ID="GvEstimaciones" runat="server" AutoGenerateColumns="false" EmptyDataText="No se encontraron partidas para levantar avance"
DataKeyNames="CveContratoAvance,CveFamilias,CveSubFamilias,CveContratoDetalle,PS,Cantidad,Importe,Cantidad_Ultima,Importe_Ultima,PU,CantidadMax,Avance,Fecha,CveEstimacion"
CssClass="table GVEstimacion table-advance table-hover mysmallbtn" GridLines="None">
<Columns>
<asp:TemplateField HeaderText="" ItemStyle-Width="60%">
<ItemTemplate>
<asp:LinkButton ID="Producto" runat="server" CssClass="Texto" Text='<%# Eval("PS")%>' Visible="false"></asp:LinkButton>
<asp:Label ID="LinkButton1" runat="server" CssClass="Texto" Text='<%# Eval("PS")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Cantidad">
<ItemTemplate>
<span><%# Eval("Cantidad", "{0:N2}")%></span>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Importe">
<ItemTemplate>
<span><%# Eval("Importe", "{0:N2}")%></span>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Ult. Cantidad">
<ItemTemplate>
<span><%# Eval("Cantidad_Ultima", "{0:N2}")%></span>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Ult. Importe">
<ItemTemplate>
<span><%# Eval("Importe_Ultima", "{0:N2}")%></span>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Acciones">
<ItemTemplate>
<table style="width: 90px!important">
<tr>
<td>
<asp:LinkButton ID="LnkAnexo" runat="server" OnClick="GetAnexos" AlternateText="Agregar Anexo" CssClass="btn btn-circle btn-sm btn-success anexo" Text="<i class='fa fa-folder'></i>" Visible="false" />
</td>
<td>
<asp:LinkButton ID="LnkEliminarAvance" runat="server" OnClick="LnkEliminarAvance_Click" AlternateText="Agregar Anexo" Visible="false"
CssClass="btn btn-circle btn-sm red" Text="<i class='icon-trash'></i>" data-toggle="confirmation" data-popout="true" data-original-title="¿Eliminar avance?" data-btn-ok-label="si" />
</td>
</tr>
</table>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</div>
</div>
<div class="row">
<div class="col-md-12">
<div class="text-center">
<asp:Button ID="BtnAutoriza" CssClass="btn btn-primary" runat="server" Text="Autorizar" Visible="false" OnClick="BtnAutoriza_Click" />
<asp:Button ID="BtnGuardarEstimacion" CssClass="btn btn-primary" runat="server" Text="Generar Estimacion" Visible="false" />
<asp:Button ID="BtnDescargarGenerado" CssClass="btn btn-primary" runat="server" Text="Descarga Generador" Visible="false" />
</div>
</div>
</div>
</ContentTemplate>
<Triggers>
<asp:PostBackTrigger ControlID="BtnDescargarGenerado" />
</Triggers>
</asp:UpdatePanel>
<div class="modal fade " id="dropmodal">
<div class="modal-dialog">
<div class="modal-content ">
<div class="portlet light smmallpadding bordered ">
<div class="portlet-title">
<div class="caption font-green">
<i class="icon-pin font-green"></i>
<span class="caption-subject bold uppercase">Cargar Evidencia</span>
</div>
<div class="actions">
<div class="btn-group">
</div>
</div>
<div class="tools">
<a href="javascript:;" class="collapse"></a>
<a href="javascript:$('#dropmodal').modal('hide');" style="color: gray;"><i class="fa fa-remove"></i></a>
</div>
</div>
<div class="portlet-body ">
<div id="my-dropzone" class="">
</div>
</div>
<div style="text-align: center!important">
<br />
<button id="btnCerrarModal" runat="server" type="button" class="btn default" data-dismiss="modal">Cerrar</button>
<br />
</div>
</div>
</div>
</div>
</div>
<div id="ModalAnexos" class="modal ADS fade" role="dialog">
<div class="modal-dialog">
<asp:UpdatePanel ID="UpModalAnexos" UpdateMode="Conditional" runat="server">
<ContentTemplate>
<!-- Modal content-->
<div class="modal-content">
<div class="modal-header ">
<button type="button" class="close" data-dismiss="modal">&times;</button>
<h4 class="modal-title">
<asp:Label runat="server" ID="LblTituloModalAnexo"></asp:Label></h4>
</div>
<div class="modal-body">
<div class="row">
<div class="col-md-12" style="text-align: center!important; text-align: center!important">
<asp:GridView ID="GvAnexos" AutoGenerateColumns="false" runat="server" ShowHeaderWhenEmpty="true" EmptyDataText="No se encontraron archivos" Width="250px"
DataKeyNames="Archivo" CssClass="table GVEstimacion table-advance table-hover" GridLines="None">
<Columns>
<asp:TemplateField HeaderText="Anexos">
<ItemTemplate>
<asp:LinkButton ID="LnkArchivo" runat="server" OnClick="LnkArchivo_Click"></asp:LinkButton>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</div>
</div>
</div>
<div class="modal-footer">
<asp:UpdatePanel runat="server">
<ContentTemplate>
<button type="button" class="btn btn-default" data-dismiss="modal">Cerrar</button>
</ContentTemplate>
</asp:UpdatePanel>
</div>
</div>
</ContentTemplate>
</asp:UpdatePanel>
</div>
</div>
</ContentTemplate>
</asp:UpdatePanel>
</div>
<div class="row">
<div class="col-md-6" style="text-align: right!important">
</div>
<div class="col-md-6" style="text-align:right!important">
<div style="display: inline-block">
<input type="text" id="TxtBusqueda" class="form-control input-sm" onkeyup="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GvEstimaciones.ClientID) %>" style="display: inline-block; margin-right: -20px; width: 150px; height: 25px; border-color: #89C4F4;" />
<a href="javascript:;" onclick="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GvEstimaciones.ClientID) %>" class="btn btn-circle btn-sm label-info"><i class="icon-magnifier"></i></a>
</div>
</div>
</div>
<br />
<div class="row">
<div class="col-md-12">
<asp:GridView ID="GvEstimaciones" runat="server" AutoGenerateColumns="false" EmptyDataText="No se encontraron partidas para levantar avance"
DataKeyNames="CveContratoAvance,CveFamilias,CveSubFamilias,CveContratoDetalle,PS,Cantidad,Importe,Cantidad_Ultima,Importe_Ultima,PU,CantidadMax,Avance,Fecha,CveEstimacion"
CssClass="table GVEstimacion table-advance table-hover mysmallbtn" GridLines="None">
<Columns>
<asp:TemplateField HeaderText="" ItemStyle-Width="60%">
<ItemTemplate>
<asp:LinkButton ID="Producto" runat="server" CssClass="Texto" Text='<%# Eval("PS")%>' Visible="false"></asp:LinkButton>
<asp:Label ID="LinkButton1" runat="server" CssClass="Texto" Text='<%# Eval("PS")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Cantidad">
<ItemTemplate>
<span><%# Eval("Cantidad", "{0:N2}")%></span>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Importe">
<ItemTemplate>
<span><%# Eval("Importe", "{0:N2}")%></span>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Cantidad">
<ItemTemplate>
<span><%# Eval("Cantidad_Ultima", "{0:N2}")%></span>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Importe">
<ItemTemplate>
<span><%# Eval("Importe_Ultima", "{0:N2}")%></span>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Acciones">
<ItemTemplate>
<table style="width: 120px!important">
<tr>
<td>
<asp:LinkButton ID="LnkAnexo" runat="server" OnClick="GetAnexos" AlternateText="Agregar Anexo" CssClass="btn btn-circle btn-sm btn-success anexo" Text="<i class='fa fa-folder'></i>" Visible="false" />
</td>
<td>
<asp:LinkButton ID="LnkEliminarAvance" runat="server" OnClick="LnkEliminarAvance_Click" AlternateText="Agregar Anexo" Visible="false"
CssClass="btn btn-circle btn-sm red" Text="<i class='icon-trash'></i>" data-toggle="confirmation" data-popout="true" data-original-title="¿Confimra la elimiancion del avance?" data-btn-ok-label="si" />
</td>
</tr>
</table>
</ItemTemplate>
</asp:TemplateField>
</div>
</Columns>
</asp:GridView>
<script src="/Metronic/assets/global/plugins/dropzone/dropzone.js"></script>
</div>
</div>
<%--<script src="../Scripts/dropzone/dropzone.min.js"></script>--%>
</asp:Content>
<asp:Content ID="Content7" ContentPlaceHolderID="JS" runat="Server">
<div class="row">
<div class="col-md-12">
<div class="text-center">
<asp:Button ID="BtnAutoriza" CssClass="btn btn-primary" runat="server" Text="Autorizar" Visible="false" OnClick="BtnAutoriza_Click" />
<asp:Button ID="BtnGuardarEstimacion" CssClass="btn btn-primary" runat="server" Text="Generar Estimacion" Visible="false" />
<asp:Button ID="BtnDescargarGenerado" CssClass="btn btn-primary" runat="server" Text="Descarga Generador" Visible="false" />
</div>
</div>
</div>
</ContentTemplate>
<Triggers>
<asp:PostBackTrigger ControlID="BtnDescargarGenerado" />
</Triggers>
</asp:UpdatePanel>
<div class="modal fade " id="dropmodal">
<div class="modal-dialog">
<div class="modal-content ">
<div class="portlet light smmallpadding bordered ">
<div class="portlet-title">
<div class="caption font-green">
<i class="icon-pin font-green"></i>
<span class="caption-subject bold uppercase">Cargar Evidencia</span>
</div>
<div class="actions">
<div class="btn-group">
</div>
</div>
<div class="tools">
<a href="javascript:;" class="collapse"></a>
<a href="javascript:$('#dropmodal').modal('hide');" style="color:gray;" ><i class="fa fa-remove"></i></a>
</div>
</div>
<div class="portlet-body ">
<div id="my-dropzone" class="">
</div>
</div>
<div style="text-align: center!important">
<br />
<button id="btnCerrarModal" runat="server" type="button" class="btn default" data-dismiss="modal">Cerrar</button>
<br />
</div>
</div>
</div>
</div>
</div>
<div id="ModalAnexos" class="modal ADS fade" role="dialog">
<div class="modal-dialog">
<asp:UpdatePanel ID="UpModalAnexos" UpdateMode="Conditional" runat="server">
<ContentTemplate>
<!-- Modal content-->
<div class="modal-content">
<div class="modal-header ">
<button type="button" class="close" data-dismiss="modal">&times;</button>
<h4 class="modal-title">
<asp:Label runat="server" ID="LblTituloModalAnexo"></asp:Label></h4>
</div>
<div class="modal-body">
<div class="row">
<div class="col-md-12" style="text-align:center!important;text-align:center!important" >
<asp:GridView ID="GvAnexos" AutoGenerateColumns="false" runat="server" ShowHeaderWhenEmpty="true" EmptyDataText="No se encontraron archivos" Width="250px"
DataKeyNames="Archivo" CssClass="table GVEstimacion table-advance table-hover" GridLines ="None">
<Columns>
<asp:TemplateField HeaderText="Anexos">
<ItemTemplate>
<asp:LinkButton ID="LnkArchivo" runat="server" OnClick="LnkArchivo_Click"></asp:LinkButton>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</div>
</div>
</div>
<div class="modal-footer">
<asp:UpdatePanel runat="server">
<ContentTemplate>
<button type="button" class="btn btn-default" data-dismiss="modal">Cerrar</button>
</ContentTemplate>
</asp:UpdatePanel>
</div>
</div>
</ContentTemplate>
</asp:UpdatePanel>
</div>
</div>
<script src="/Metronic/assets/global/plugins/dropzone/dropzone.js"></script>
<%--<script src="../Scripts/dropzone/dropzone.min.js"></script>--%>
</asp:Content>
<asp:Content ID="Content7" ContentPlaceHolderID="JS" Runat="Server">
<script>
jQuery(document).ready(function () {
@@ -287,7 +282,7 @@
Sys.Application.add_load(function (s, e) {
$(".linkfile").click(function () {
showmodalFile($(this).find('input').attr('id'));
});
});
});
});
function showmodalFile(obj) {
@@ -296,7 +291,7 @@
$('#' + obj).data("urldown", '<%= url%>/Ashx/SIGWeb.ashx');
$('#' + obj).data("urlget", '<%= url %>/Temp/');
ADDropzone(obj);
$('#dropmodal').modal();
$('#dropmodal').modal();
}
function ValidateCant(variable) {
@@ -330,6 +325,6 @@
}
//);
</script>
</asp:Content>
</script>
</asp:Content>

View File

@@ -137,11 +137,6 @@ Partial Class Contratos_ContratoObraAutorizacion
DDlContratosEstimaciones.DataBind()
End Sub
Protected Sub GetAnexos(sender As Object, e As System.EventArgs)
Dim GvRow As GridViewRow = DirectCast((DirectCast(sender, LinkButton)).NamingContainer, GridViewRow)
@@ -219,11 +214,8 @@ Partial Class Contratos_ContratoObraAutorizacion
If DTEstimaciones.Rows.Count > 0 Then
CveEstimacionActual = DTEstimaciones.FiltroPrimeroValor("CveEstimacion", "CveEstimacion > 0").ToString.ToEntero
End If
End If
ObjContratos.Dispose()
@@ -263,9 +255,6 @@ Partial Class Contratos_ContratoObraAutorizacion
e.Row.CssClass = "SubTotales3"
End If
End If
If e.Row.DBCampo("CveContratoDetalle").ToString.ToEntero > 0 Then
@@ -638,7 +627,6 @@ Partial Class Contratos_ContratoObraAutorizacion
Dim ErrorProceso As Boolean = True
Dim ObjContrato As New ClsContratos
If ObjContrato.RemoveContratosAvance(CveContratoAvance, UsuarioActual.CveEmpresa) Then
@@ -650,7 +638,7 @@ Partial Class Contratos_ContratoObraAutorizacion
If Not ErrorProceso Then
CargaAvancesParaEstimar()
Alert("Avance elimiando correctamente.")
Alert("Avance eliminado correctamente.")
End If

View File

@@ -1245,25 +1245,7 @@
<Width>2pt</Width>
</Border>
</Style>
</Line>
<Image Name="Image9">
<Source>Embedded</Source>
<Value>VISTAPREVIA22</Value>
<Sizing>FitProportional</Sizing>
<Top>0.01389in</Top>
<Left>7.40306in</Left>
<Height>6.34944in</Height>
<Width>0.09753in</Width>
<ZIndex>20</ZIndex>
<Visibility>
<Hidden>=IIf(Parameters!CveVenta.Value &gt; 0, True,False)</Hidden>
</Visibility>
<Style>
<Border>
<Style>None</Style>
</Border>
</Style>
</Image>
</Line>
</ReportItems>
<Height>6.36333in</Height>
<Style />

View File

@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<Report xmlns="http://schemas.microsoft.com/sqlserver/reporting/2016/01/reportdefinition" xmlns:rd="http://schemas.microsoft.com/SQLServer/reporting/reportdesigner">
<Report xmlns="http://schemas.microsoft.com/sqlserver/reporting/2010/01/reportdefinition" xmlns:rd="http://schemas.microsoft.com/SQLServer/reporting/reportdesigner">
<AutoRefresh>0</AutoRefresh>
<DataSources>
<DataSource Name="DsOC">
@@ -4892,434 +4892,7 @@
<Prompt>ReportParameter1</Prompt>
</ReportParameter>
</ReportParameters>
<ReportParametersLayout>
<GridLayoutDefinition>
<NumberOfColumns>2</NumberOfColumns>
<NumberOfRows>42</NumberOfRows>
<CellDefinitions>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>0</RowIndex>
<ParameterName>ClienteCodigo</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>0</RowIndex>
<ParameterName>ClienteNombre</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>1</RowIndex>
<ParameterName>ClienteDireccion</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>1</RowIndex>
<ParameterName>ClienteLugar</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>2</RowIndex>
<ParameterName>ClienteTelefono</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>2</RowIndex>
<ParameterName>ClienteContacto</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>3</RowIndex>
<ParameterName>ClienteContactoMail</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>3</RowIndex>
<ParameterName>ClienteCalle</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>4</RowIndex>
<ParameterName>ClienteColonia</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>4</RowIndex>
<ParameterName>ClienteCiudad</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>5</RowIndex>
<ParameterName>ClienteMunicipio</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>5</RowIndex>
<ParameterName>ClienteEstado</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>6</RowIndex>
<ParameterName>ClienteCP</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>6</RowIndex>
<ParameterName>ClientePais</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>7</RowIndex>
<ParameterName>ClienteNoInt</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>7</RowIndex>
<ParameterName>ClienteNoExt</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>8</RowIndex>
<ParameterName>ClienteRFC</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>8</RowIndex>
<ParameterName>ImporteLetra</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>9</RowIndex>
<ParameterName>Observaciones</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>9</RowIndex>
<ParameterName>CveVendedor</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>10</RowIndex>
<ParameterName>Status</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>10</RowIndex>
<ParameterName>FechaSolicitud</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>11</RowIndex>
<ParameterName>Folio</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>11</RowIndex>
<ParameterName>Descuento</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>12</RowIndex>
<ParameterName>SubTotal</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>12</RowIndex>
<ParameterName>IVA</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>13</RowIndex>
<ParameterName>Total</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>13</RowIndex>
<ParameterName>Fecha</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>14</RowIndex>
<ParameterName>DomicilioSucursal</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>14</RowIndex>
<ParameterName>MetodoPago</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>15</RowIndex>
<ParameterName>Vencimiento</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>15</RowIndex>
<ParameterName>FolioFiscal</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>16</RowIndex>
<ParameterName>FechaCertificacion</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>16</RowIndex>
<ParameterName>SelloCFDI</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>17</RowIndex>
<ParameterName>CadenaSAT</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>17</RowIndex>
<ParameterName>SelloSAT</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>18</RowIndex>
<ParameterName>CiudadSucursal</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>18</RowIndex>
<ParameterName>Serie</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>19</RowIndex>
<ParameterName>QR</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>19</RowIndex>
<ParameterName>FormaPago</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>20</RowIndex>
<ParameterName>LogoPath</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>20</RowIndex>
<ParameterName>VendedorNombre</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>21</RowIndex>
<ParameterName>VendedorCelular</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>21</RowIndex>
<ParameterName>VendedorMail</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>22</RowIndex>
<ParameterName>VendedorTelefono</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>22</RowIndex>
<ParameterName>Moneda</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>23</RowIndex>
<ParameterName>TipoCambio</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>23</RowIndex>
<ParameterName>CondicionPago</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>24</RowIndex>
<ParameterName>CadenaOriginal</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>24</RowIndex>
<ParameterName>SerieCertificadoSAT</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>25</RowIndex>
<ParameterName>Tipo</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>25</RowIndex>
<ParameterName>NumCta</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>26</RowIndex>
<ParameterName>CertificadoContribuyente</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>26</RowIndex>
<ParameterName>Amortizacion</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>27</RowIndex>
<ParameterName>SubTotal2</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>27</RowIndex>
<ParameterName>RetIVA</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>28</RowIndex>
<ParameterName>RetISR</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>28</RowIndex>
<ParameterName>TipoDocumento</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>29</RowIndex>
<ParameterName>AplicaPagare</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>29</RowIndex>
<ParameterName>Ref</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>30</RowIndex>
<ParameterName>Sucursal</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>30</RowIndex>
<ParameterName>ClienteDiasCredito</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>31</RowIndex>
<ParameterName>OC</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>31</RowIndex>
<ParameterName>MonedaAbreviatura</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>32</RowIndex>
<ParameterName>UsuarioImprimio</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>32</RowIndex>
<ParameterName>FechaImpresion</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>33</RowIndex>
<ParameterName>EnvioDireccion</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>33</RowIndex>
<ParameterName>EnvioColonia</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>34</RowIndex>
<ParameterName>EnvioCiudad</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>34</RowIndex>
<ParameterName>EnvioEstado</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>35</RowIndex>
<ParameterName>EnvioCP</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>35</RowIndex>
<ParameterName>EnvioNoExt</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>36</RowIndex>
<ParameterName>EnvioNoInt</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>36</RowIndex>
<ParameterName>EnvioContacto</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>37</RowIndex>
<ParameterName>EnvioDepartamento</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>37</RowIndex>
<ParameterName>EstatusFactura</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>38</RowIndex>
<ParameterName>EstatusEntrega</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>38</RowIndex>
<ParameterName>PedidoContrato</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>39</RowIndex>
<ParameterName>DescripcionContrato</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>39</RowIndex>
<ParameterName>OrdenCompra</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>40</RowIndex>
<ParameterName>UsoCFDI</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>40</RowIndex>
<ParameterName>TipoRelacionTexto</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>0</ColumnIndex>
<RowIndex>41</RowIndex>
<ParameterName>FolioFiscalRelacionado</ParameterName>
</CellDefinition>
<CellDefinition>
<ColumnIndex>1</ColumnIndex>
<RowIndex>41</RowIndex>
<ParameterName>Contrato</ParameterName>
</CellDefinition>
</CellDefinitions>
</GridLayoutDefinition>
</ReportParametersLayout>
<EmbeddedImages>
<EmbeddedImage Name="Logo119">
<MIMEType>image/png</MIMEType>

View File

@@ -3198,6 +3198,12 @@
<AllowBlank>true</AllowBlank>
<Prompt>ReportParameter1</Prompt>
</ReportParameter>
<ReportParameter Name="LogoPath">
<DataType>String</DataType>
<Nullable>true</Nullable>
<AllowBlank>true</AllowBlank>
<Prompt>ReportParameter1</Prompt>
</ReportParameter>
</ReportParameters>
<EmbeddedImages>
<EmbeddedImage Name="compuproveedores">

View File

@@ -658,7 +658,7 @@ Partial Class Inventarios_InventarioFisicoDetalle
Private Sub LnkExcelUniverso_Click(sender As Object, e As EventArgs) Handles LnkExcelUniverso.Click
Dim IncluyePS, ExcluyePS, IncluyeClasificacion, ExcluyeClasificacion, IncluyeProveedor As New StringBuilder
Dim ObjInventario As New ClsInventarios
Dim DtPS As DataTable
Dim DtPS As DataTable = Nothing
If ObjInventario.GetInventarioFisicoUniversoProductos(CveInventarioFisico, UsuarioActual.CveEmpresa) Then
If ObjInventario.DtResultados.Rows.Count > 0 Then
DtPS = ObjInventario.DtResultados.FiltraParametros("", "", {"Codigo", "PS", "Clasificacion", "RazonSocial"})
@@ -666,6 +666,8 @@ Partial Class Inventarios_InventarioFisicoDetalle
Alert("Error al consultar la informacion")
End If
End If
ObjInventario.Dispose()
Dim NombreArchivo As String
SpreadsheetInfo.SetLicense(ModExtensiones.SerialGemBoxSpreadsheet)
Dim workbook As New ExcelFile()

View File

@@ -899,7 +899,7 @@ Partial Class Inventarios_TrasladoSolicitud
End If
If UsuarioActual.CveEmpresa = 72 Or UsuarioActual.CveEmpresa = 1 Then
ImprimirPDF(String.Format("Empresas\{0}\Formatos\RepTrasladoSolicitud.rdlc", UsuarioActual.CveEmpresa), dt, params, String.Format("Solicitud de Traslado - {0}", Now.ToDateTime.ToShortDateString), Formato:=Formato)
ImprimirPDF(String.Format("{0}Formatos\RepTrasladoSolicitud.rdlc", UsuarioActual.Empresa.Ruta), dt, params, String.Format("Solicitud de Traslado - {0}", Now.ToDateTime.ToShortDateString), Formato:=Formato)
Else
ImprimirPDF(RutaFormatoDefault, dt, params, String.Format("Solicitud de Traslado - {0}", Now.ToDateTime.ToShortDateString), Formato:=Formato)
End If

View File

@@ -217,7 +217,7 @@ public partial class Nomina_Aguinaldo : ClsPaginas
if (CveNomina > 0)
{
if (!objNomina.AddUPNom_NominasDetalles(objNomina.CveNomina, CvePeriodoSeleccionado, CvePersonal, CveConcepto, Importe, ImporteGravado, ImporteExento, ImporteValor, UsuarioActual.CveUsuario))
if (!objNomina.AddUPNom_NominasDetalles(objNomina.CveNomina, CvePeriodoSeleccionado, CvePersonal, CveConcepto, Importe, ImporteGravado, ImporteExento, ImporteValor, UsuarioActual.CveUsuario, false, 1, 1, 1))
{
continuar = false;
}

View File

@@ -1232,7 +1232,7 @@ public partial class Nomina_Finiquito : ClsPaginas
if (continuar)
{
if (!objNomina.AddUPNom_NominasDetalles(CveNomina, CvePeriodoSeleccionado, CvePersonal, CveConcepto, ImporteConcepto, ImporteGravadoConcepto, ImporteExentoConcepto, ImporteValor, UsuarioActual.CveUsuario))
if (!objNomina.AddUPNom_NominasDetalles(CveNomina, CvePeriodoSeleccionado, CvePersonal, CveConcepto, ImporteConcepto, ImporteGravadoConcepto, ImporteExentoConcepto, ImporteValor, UsuarioActual.CveUsuario, false, 1, 1, 1))
{
continuar = false;
}
@@ -1345,6 +1345,10 @@ public partial class Nomina_Finiquito : ClsPaginas
protected void BtnAceptarMC_Click(object sender, EventArgs e)
{
int chkImporte = 1;
int chkImporteGravado = 1;
int chkImporteValor = 1;
bool continuar = true;
int CveNomina = 0;
double Total = 0;
@@ -1395,7 +1399,7 @@ public partial class Nomina_Finiquito : ClsPaginas
if (continuar)
{
if (!objNomina.AddUPNom_NominasDetalles(CveNomina, CvePeriodoFiniquito, CvePersonal, CveConcepto, ImporteConcepto, ImporteGravadoConcepto, ImporteExentoConcepto, ImporteValor, UsuarioActual.CveUsuario, true))
if (!objNomina.AddUPNom_NominasDetalles(CveNomina, CvePeriodoFiniquito, CvePersonal, CveConcepto, ImporteConcepto, ImporteGravadoConcepto, ImporteExentoConcepto, ImporteValor, UsuarioActual.CveUsuario, true, chkImporte, chkImporteGravado, chkImporteValor))
{
continuar = false;
}

View File

@@ -130,8 +130,8 @@ public partial class Nomina_NomTimbrados : ClsPaginas
case "DESCUENTO": drow["DESCUENTO"] = xtr.Value; break;
case "TIPODECOMPROBANTE": drow["TIPODECOMPROBANTE"] = xtr.Value; break;
}
switch (xtr.Name.ToUpper())
{
//switch (xtr.Name.ToUpper())
//{
//case "XMLNS:CFDI": xmlCFDI.comprobante.xmlns_cfdi = xtr.Value; break;
//case "XMLNS:XSI": xmlCFDI.comprobante.xmlns_xsi = xtr.Value; break;
//case "XSI:SCHEMALOCATION": xmlCFDI.comprobante.xsi_schemaLocation = xtr.Value; break;
@@ -155,7 +155,7 @@ public partial class Nomina_NomTimbrados : ClsPaginas
//case "NOCERTIFICADO": xmlCFDI.comprobante.NoCertificado = xtr.Value; break;
//case "SELLO": xmlCFDI.comprobante.Sello = xtr.Value; break;
//case "CERTIFICADO": xmlCFDI.comprobante.Certificado = xtr.Value; break;
}
//}
cont = xtr.MoveToNextAttribute();
}
cont = xtr.MoveToFirstAttribute();
@@ -244,8 +244,8 @@ public partial class Nomina_NomTimbrados : ClsPaginas
cont = xtr.MoveToFirstAttribute();
while (cont)
{
switch (xtr.Name.ToUpper())
{
//switch (xtr.Name.ToUpper())
//{
//case "CLAVEPRODSERV": concepto.ClaveProdServ = xtr.Value; break;
//case "NOIDENTIFICACION": concepto.NoIdentificacion = xtr.Value; break;
//case "CANTIDAD": concepto.Cantidad = xtr.Value; break;
@@ -255,7 +255,7 @@ public partial class Nomina_NomTimbrados : ClsPaginas
//case "IMPORTE": decimal Importe = 0; decimal.TryParse(xtr.Value, out Importe); concepto.Importe = Importe; ; break;
//case "DESCUENTO": decimal DDescuento = 0; decimal.TryParse(xtr.Value, out DDescuento); concepto.Descuento = DDescuento; ; break;
//case "DESCRIPCION": concepto.Descripcion = xtr.Value; break;
}
//}
cont = xtr.MoveToNextAttribute();
}
xtr.MoveToFirstAttribute();
@@ -377,22 +377,22 @@ public partial class Nomina_NomTimbrados : ClsPaginas
while (conts)
{
decimal Base = 0;
switch (xtr.Name.ToUpper())
{
//case "FECHAPAGO": xmlCFDI.complemento.Pagos.FechaPago = xtr.Value; break;
//case "FORMADEPAGOP": xmlCFDI.complemento.Pagos.FormaDePagoP = xtr.Value; break;
//case "FORMADEPAGOPTEXT": xmlCFDI.complemento.Pagos.FormaDePagoPText = xtr.Value; break;
//case "MONEDAP": xmlCFDI.complemento.Pagos.MonedaP = xtr.Value; break;
//case "MONTO": decimal.TryParse(xtr.Value, out Base); xmlCFDI.complemento.Pagos.Monto = Base; break;
//case "TIPOCAMBIOP": decimal.TryParse(xtr.Value, out Base); xmlCFDI.complemento.Pagos.TipoCambioP = Base; break;
//case "NUMOPERACION": xmlCFDI.complemento.Pagos.NumOperacion = xtr.Value; break;
//case "NOMBANCOORDEXT": xmlCFDI.complemento.Pagos.NomBancoOrdExt = xtr.Value; break;
//case "RFCEMISORCTAORD": xmlCFDI.complemento.Pagos.RfcEmisorCtaOrd = xtr.Value; break;
//case "CTAORDENANTE": xmlCFDI.complemento.Pagos.CtaOrdenante = xtr.Value; break;
//case "RFCEMISORCTABEN": xmlCFDI.complemento.Pagos.RfcEmisorCtaBen = xtr.Value; break;
//case "CTABENEFICIARIO": xmlCFDI.complemento.Pagos.CtaBeneficiario = xtr.Value; break;
}
//decimal Base = 0;
//switch (xtr.Name.ToUpper())
//{
// case "FECHAPAGO": xmlCFDI.complemento.Pagos.FechaPago = xtr.Value; break;
// case "FORMADEPAGOP": xmlCFDI.complemento.Pagos.FormaDePagoP = xtr.Value; break;
// case "FORMADEPAGOPTEXT": xmlCFDI.complemento.Pagos.FormaDePagoPText = xtr.Value; break;
// case "MONEDAP": xmlCFDI.complemento.Pagos.MonedaP = xtr.Value; break;
// case "MONTO": decimal.TryParse(xtr.Value, out Base); xmlCFDI.complemento.Pagos.Monto = Base; break;
// case "TIPOCAMBIOP": decimal.TryParse(xtr.Value, out Base); xmlCFDI.complemento.Pagos.TipoCambioP = Base; break;
// case "NUMOPERACION": xmlCFDI.complemento.Pagos.NumOperacion = xtr.Value; break;
// case "NOMBANCOORDEXT": xmlCFDI.complemento.Pagos.NomBancoOrdExt = xtr.Value; break;
// case "RFCEMISORCTAORD": xmlCFDI.complemento.Pagos.RfcEmisorCtaOrd = xtr.Value; break;
// case "CTAORDENANTE": xmlCFDI.complemento.Pagos.CtaOrdenante = xtr.Value; break;
// case "RFCEMISORCTABEN": xmlCFDI.complemento.Pagos.RfcEmisorCtaBen = xtr.Value; break;
// case "CTABENEFICIARIO": xmlCFDI.complemento.Pagos.CtaBeneficiario = xtr.Value; break;
//}
conts = xtr.MoveToNextAttribute();
}
conts = xtr.MoveToFirstAttribute();
@@ -404,20 +404,20 @@ public partial class Nomina_NomTimbrados : ClsPaginas
while (conts)
{
decimal Basep = 0;
switch (xtr.Name.ToUpper())
{
//case "IDDOCUMENTO": objpago.IdDocumento = xtr.Value; break;
//case "SERIE": objpago.Serie = xtr.Value; break;
//case "FOLIO": objpago.Folio = xtr.Value; break;
//case "MONEDADR": objpago.MonedaDR = xtr.Value; break;
//case "METODODEPAGODR": objpago.MetodoDePagoDR = xtr.Value; break;
//case "NUMPARCIALIDAD": objpago.NumParcialidad = xtr.Value; break;
//case "IMPSALDOANT": decimal.TryParse(xtr.Value, out Basep); objpago.ImpSaldoAnt = Basep; break;
//case "IMPPAGADO": decimal.TryParse(xtr.Value, out Basep); objpago.ImpPagado = Basep; break;
//case "IMPSALDOINSOLUTO": decimal.TryParse(xtr.Value, out Basep); objpago.ImpSaldoInsoluto = Basep; break;
//decimal Basep = 0;
//switch (xtr.Name.ToUpper())
//{
// case "IDDOCUMENTO": objpago.IdDocumento = xtr.Value; break;
// case "SERIE": objpago.Serie = xtr.Value; break;
// case "FOLIO": objpago.Folio = xtr.Value; break;
// case "MONEDADR": objpago.MonedaDR = xtr.Value; break;
// case "METODODEPAGODR": objpago.MetodoDePagoDR = xtr.Value; break;
// case "NUMPARCIALIDAD": objpago.NumParcialidad = xtr.Value; break;
// case "IMPSALDOANT": decimal.TryParse(xtr.Value, out Basep); objpago.ImpSaldoAnt = Basep; break;
// case "IMPPAGADO": decimal.TryParse(xtr.Value, out Basep); objpago.ImpPagado = Basep; break;
// case "IMPSALDOINSOLUTO": decimal.TryParse(xtr.Value, out Basep); objpago.ImpSaldoInsoluto = Basep; break;
}
//}
conts = xtr.MoveToNextAttribute();
}
conts = xtr.MoveToFirstAttribute();

View File

@@ -1389,6 +1389,9 @@ public partial class Nomina_Nomina2 : ClsPaginas
protected void LnkCargarNomina_Click(object sender, EventArgs e)
{
int chkImporteValor = 1;
int chkImporte = 1;
int chkImporteGravado = 0;
List<Archivo> Filesgral = TxtArchivoNomina.getfiles().Archivos;
bool continuar = Filesgral.Count > 0;
string stringError = "";
@@ -1512,7 +1515,7 @@ public partial class Nomina_Nomina2 : ClsPaginas
{
if (!dontsaveconcepto)//el usuario definira si desea actualizar o no el concepto en el periodo
{
if (!objNomina.AddUPNom_NominasDetalles(objNomina.CveNomina, CvePeriodoSeleccionado, CvePersonal, CveConcepto, Importe, ImporteGravado, ImporteExento, ImporteValor, UsuarioActual.CveUsuario, true))
if (!objNomina.AddUPNom_NominasDetalles(objNomina.CveNomina, CvePeriodoSeleccionado, CvePersonal, CveConcepto, Importe, ImporteGravado, ImporteExento, ImporteValor, UsuarioActual.CveUsuario, true, chkImporte, chkImporteGravado, chkImporteValor))
{
rollback = true;
}
@@ -1841,6 +1844,9 @@ public partial class Nomina_Nomina2 : ClsPaginas
}
protected void BtnAceptarMC_Click(object sender, EventArgs e)
{
int chkImporte = 1;
int chkImporteGravado = 1;
int chkImporteValor = 1;
bool continuar = true;
int CveNomina = 0;
double Total = 0;
@@ -1896,7 +1902,7 @@ public partial class Nomina_Nomina2 : ClsPaginas
if (continuar)
{
if (!objNomina.AddUPNom_NominasDetalles(CveNomina, CvePeriodoSeleccionado, CvePersonal, CveConcepto, ImporteConcepto, ImporteGravadoConcepto, ImporteExentoConcepto, ImporteValor, UsuarioActual.CveUsuario, true))
if (!objNomina.AddUPNom_NominasDetalles(CveNomina, CvePeriodoSeleccionado, CvePersonal, CveConcepto, ImporteConcepto, ImporteGravadoConcepto, ImporteExentoConcepto, ImporteValor, UsuarioActual.CveUsuario, true, chkImporte, chkImporteGravado, chkImporteValor))
{
continuar = false;
}
@@ -4737,8 +4743,11 @@ public partial class Nomina_Nomina2 : ClsPaginas
private bool autorizarNomina(int FiltroCvePersonal)
{
bool continuar = true;
int chkImporte = 1;
int chkImporteGravado = 1;
int chkImporteValor = 1;
string[] getcolumnas = new string[] { "CvePersonal", "CveMetodoPago", "SumaPercepciones", "Total", "SalarioDiario", "SalarioDiarioIMSS", "SalarioDiarioIntegrado", "DiasLaborados", "DiasFaltados", "DiasVacaciones", "DiasIncapacidad" };
DataTable dtr = dtempleados.FiltraParametros(string.Format("(CvePersonal={0} OR {0}=-1) AND CvePersonal > 0 AND NomAutorizado =0", FiltroCvePersonal), "", getcolumnas);
@@ -4814,7 +4823,7 @@ public partial class Nomina_Nomina2 : ClsPaginas
if (continuar)
{
if (!objNomina.AddUPNom_NominasDetalles(CveNomina, CvePeriodoSeleccionado, CvePersonal, CveConcepto, ImporteConcepto, ImporteGravadoConcepto, ImporteExentoConcepto, ImporteValor, UsuarioActual.CveUsuario))
if (!objNomina.AddUPNom_NominasDetalles(CveNomina, CvePeriodoSeleccionado, CvePersonal, CveConcepto, ImporteConcepto, ImporteGravadoConcepto, ImporteExentoConcepto, ImporteValor, UsuarioActual.CveUsuario,false, chkImporte, chkImporteGravado, chkImporteValor))
{
continuar = false;
}
@@ -5846,7 +5855,7 @@ public partial class Nomina_Nomina2 : ClsPaginas
}
catch (Exception ex)
{
// OnError("Error al cargar Formato vacaciones", ex);
this.OnError("Error al cargar Formato vacaciones", ex);
}
}
if (Documento.Length > 0)

File diff suppressed because it is too large Load Diff

View File

@@ -9,6 +9,19 @@ Imports Microsoft.Reporting.WebForms
Partial Class RH_CatPersonal
Inherits ClsPaginas
Private Property ISChange As Boolean
Get
If ViewState("ISChange") Is Nothing Then
Return False
Else
Return DirectCast(ViewState("ISChange"), Boolean)
End If
End Get
Set(value As Boolean)
ViewState("ISChange") = value
End Set
End Property
Private Property DTDatos As DataTable
Get
@@ -24,8 +37,12 @@ Partial Class RH_CatPersonal
End Property
Protected Sub Page_Load(sender As Object, e As System.EventArgs) Handles Me.Load
If Not Page.IsPostBack Then
If UsuarioActual.CveEmpresa.Contiene(1, 119, 158) Then
HplAddVenta.Visible = False
End If
LnkAddPersonalSimplificado.Visible = Not HplAddVenta.Visible
TxtFechaIngreso.Text = String.Format("{0:dd/MM/yyyy}", DateTime.Now)
ViewState("Orden") = ""
CargaEscolaridad()
CargaEstadoCivil()
CargaDepartamento()
@@ -41,6 +58,12 @@ Partial Class RH_CatPersonal
CargaSupervisores()
CargaMetodosPago()
CargaDatos()
CargaTipoRegimen()
CargaJornada()
CargaEstados()
CargaSatRiesgoPuesto()
LoadDefaultValues()
End If
End Sub
@@ -135,6 +158,38 @@ Partial Class RH_CatPersonal
#Region " C O M B O S "
Private Sub LoadDefaultValues()
DdlDepartamentoAdd.SelectedIndex = 1
DdlRegimenContratacion.SelectedValueExist(1)
DdlMetodoPagoAdd.SelectedValueExist(1)
DdlTipoPeriodoAdd.SelectedValueExist(1)
DdlTipoContratoAdd.SelectedValueExist(2)
DdlJornada.SelectedValueExist(6)
DdlPuestoAdd.SelectedIndex = 1
DdlRiesgoPuesto.SelectedIndex = 1
End Sub
Private Sub CargaSatRiesgoPuesto()
DdlRiesgoPuesto.DataSource = GlobalDTNomSatRiesgoPuesto
DdlRiesgoPuesto.DataBind()
End Sub
Private Sub CargaJornada()
DdlJornada.DataSource = GlobalDTJornadas
DdlJornada.DataBind()
End Sub
Private Sub CargaEstados()
DdlEstados.DataSource = GlobalDTGralEstados(1)
DdlEstados.DataBind()
End Sub
Private Sub CargaTipoRegimen()
Dim dt As DataTable = GlobalDTNomSatRegimenContratacion.Copy()
For Each item As DataRow In dt.Rows
item("RegimenContratacion") = String.Format("{1}{0} {2}", item("CveSATRegimenContratacion"), If(item("CveSATRegimenContratacion").ToString().Length > 1, "", "0"), item("RegimenContratacion"))
Next
dt.AcceptChanges()
DdlRegimenContratacion.DataSource = dt.FiltraParametros("", "RegimenContratacion")
DdlRegimenContratacion.DataBind()
End Sub
Private Sub CargaEscolaridad()
DdlEscolaridad.DataSource = GlobalDTEscolaridad
DdlEscolaridad.DataBind()
@@ -142,7 +197,9 @@ Partial Class RH_CatPersonal
Private Sub CargaGenero()
DdlGenero.DataSource = GlobalDTGenero
DdlGeneroAdd.DataSource = GlobalDTGenero
DdlGenero.DataBind()
DdlGeneroAdd.DataBind()
End Sub
Private Sub CargaEstadoCivil()
@@ -153,11 +210,15 @@ Partial Class RH_CatPersonal
Private Sub CargaTipoPeriodo()
DdlTipoPeriodo.DataSource = GlobalDTTipoPeriodo
DdlTipoPeriodo.DataBind()
DdlTipoPeriodoAdd.DataSource = GlobalDTTipoPeriodo
DdlTipoPeriodoAdd.DataBind()
End Sub
Private Sub CargaTiposContrato()
DdlTipoContrato.DataSource = GlobalDTTiposContrato
DdlTipoContrato.DataBind()
DdlTipoContratoAdd.DataSource = GlobalDTTiposContrato
DdlTipoContratoAdd.DataBind()
End Sub
Private Sub CargaTurno()
@@ -167,12 +228,16 @@ Partial Class RH_CatPersonal
Private Sub CargaDepartamento()
DdlDepartamento.DataSource = GlobalDTDepartamentos.FiltraParametros("CveEmpresa = " & UsuarioActual.CveEmpresa)
DdlDepartamentoAdd.DataSource = DdlDepartamento.DataSource
DdlDepartamentoAdd.DataBind()
DdlDepartamento.DataBind()
End Sub
Private Sub CargaPuestos()
DdlPuesto.DataSource = GlobalDTRHPuestos(UsuarioActual.CveEmpresa)
DdlPuestoAdd.DataSource = DdlPuesto.DataSource
DdlPuesto.DataBind()
DdlPuestoAdd.DataBind()
End Sub
Private Sub CargaRuta()
@@ -214,6 +279,10 @@ Partial Class RH_CatPersonal
End Sub
Private Sub CargaTipoCentroCosto()
CargarCentrosDeCosto(DdlProyectoAsignadoAdd, DdlSubProyectoAsignadoAdd, LblProyectoAsignado, LblSubProyectoAsignado)
DivProyectosAsignado.Visible = LblProyectoAsignado.Visible
CargarCentrosDeCosto(DdlProyectoAsignado, DdlSubProyectoAsignado, LblProyecto, LblSubProyecto)
DivProyecto.Visible = LblProyecto.Visible
ChkSubProyecto.Text = LblSubProyecto.Text
@@ -228,6 +297,8 @@ Partial Class RH_CatPersonal
Private Sub CargaMetodosPago()
DdlMetodoPago.DataSource = GlobalDTMetodosPago
DdlMetodoPago.DataBind()
DdlMetodoPagoAdd.DataSource = GlobalDTMetodosPago
DdlMetodoPagoAdd.DataBind()
End Sub
#End Region
@@ -1041,4 +1112,74 @@ Partial Class RH_CatPersonal
' End If
'End Using
End Sub
Protected Sub LnkGuardar_Click(sender As Object, e As EventArgs)
DdlTurno.SelectedIndex = 1
Dim CveEtadoCivil = 1
Dim CveEstatusPersonal = 1
Dim CveEscolaridad As Integer = 0
Dim isSindicalizado As Boolean = (DDlSindicalizado.SelectedValue = "1")
Dim CvePuesto As Integer = DdlPuestoAdd.SelectedValue.ToEntero()
Dim CveSATRiesgoPuesto As Integer = DdlRiesgoPuesto.SelectedValue.ToEntero()
Dim continuar As Boolean = False
Dim CvePersonal As Integer = 0
Using ObjPersonal As New ClsRH()
If ObjPersonal.AddPersonal("-1", TxtAPaterno.Text.Trim, TxtAMaterno.Text.Trim, TxtNombres.Text.Trim, "", TxtFechaIngreso.Text.ToDate,
DdlTipoPeriodoAdd.SelectedValue.ToEntero, TxtNumeroSS.Text.Trim, ChkSeInscribioSS.Checked, 0,
0, 0, 0, 0, 15, 25, DdlMetodoPagoAdd.SelectedValue.ToEntero, TxtFechaIngreso.Text.Trim.ToDate, "-1",
DdlTipoContratoAdd.SelectedValue.ToEntero, "",
DdlTurno.SelectedValue.ToEntero, CvePuesto,
DdlDepartamentoAdd.SelectedValue.ToEntero,
-1, CveEscolaridad,
CveEtadoCivil, DdlGeneroAdd.SelectedValue.ToEntero(),
-1, "-1", CveEstatusPersonal, TxtFechaNacimiento.Text.ToDate,
"", "", "", "", "", "", "",
DdlEstados.SelectedValue.ToEntero, "", "", TxtRFC.Text.Trim,
TxtCURP.Text.Trim, "", "", -1, CveSATRiesgoPuesto, DdlRegimenContratacion.SelectedValue.ToEntero,
-1, DdlSubProyectoAsignadoAdd.SelectedValue.ToEntero, "",
DdlSupervisor.SelectedValue.ToEntero, "", "", DdlJornada.SelectedValue.ToEntero, -1, "-1",
0, "Seleccione", UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, -1, -1, CveUniforme:=-1,
TelefonoExtension:="", CelularPersonal:="", TelefonoMarcadoRapido:="", ContactoAlterno:="", CveTipodeSalario:=DDlTipoSalario.SelectedValue.ToEntero(), Sindicalizado:=isSindicalizado, CvePais:=151) Then
Alert(String.Format("El empleado a sido agregado satisfactoriamente <a href=""/RH/Personal.aspx?CvePersonal={0}"">Ver empleado</a>", ObjPersonal.CvePersonal), TipoMensaje.ToastInformacion, "", 0)
continuar = True
ISChange = True
Else
'Alert("El empleado a sido agregado satisfactoriamente", TipoMensaje.ToastInformacion, "", 0)
End If
End Using
DdlTurno.SelectedValueExist(-1)
If continuar Then
LimpiarCampos()
If chkcontinuarAgregando.Checked Then
Else
RegistraScript("$('#DmodalAddPersonal').modal('hide');")
End If
End If
End Sub
Protected Sub LimpiarCampos()
TxtAPaterno.Text = ""
TxtAMaterno.Text = ""
TxtNombres.Text = ""
TxtFechaNacimiento.Text = ""
TxtNumeroSS.Text = ""
TxtCURP.Text = ""
TxtRFC.Text = ""
End Sub
Protected Sub LnkAddPersonalSimplificado_Click(sender As Object, e As EventArgs)
ISChange = False
UpAddPerSimplificado.Update()
LimpiarCampos()
RegistraScript("$('#DmodalAddPersonal').modal();")
End Sub
Protected Sub ClickOnHideModal_Click(sender As Object, e As EventArgs)
If ISChange Then
CargaDatos()
End If
End Sub
End Class

View File

@@ -876,7 +876,7 @@ Partial Class RH_Personal
divBitacora.Visible = True
CargaGvBitacora()
Else
LoadDefaultValues()
'Configuración de Modalidad Insert
ImgAddObs.Visible = False
@@ -935,6 +935,20 @@ Partial Class RH_Personal
AgregarEventosAsincronosGvVacaciones()
End Sub
Private Sub LoadDefaultValues()
DdlDepartamento.SelectedIndex = 1
DdlRegimenContratacion.SelectedValueExist(1)
DdlMetodoPago.SelectedValueExist(1)
DdlTipoPeriodo.SelectedValueExist(1)
DdlTipoContrato.SelectedValueExist(2)
DdlJornada.SelectedValueExist(6)
DdlPuesto.SelectedIndex = 1
DdlTurno.SelectedIndex = 1
DdlEstatusPersonal.SelectedValue = "1"
DdlRiesgoPuesto.SelectedIndex = 1
End Sub
Private Sub CargaCuentasContables()
Dim ObjContabilidad As New ClsContPAQi(UsuarioActual.Empresa)
If ObjContabilidad.GetCuentas(-1, "-1", -1) Then

View File

@@ -10,7 +10,7 @@
padding: 0px 5px;
}
.nolineheight TxtNombreCliente line-height: 1;
.nolineheight {line-height: 1;
}
.claseesconder {

View File

@@ -17073,12 +17073,14 @@ Partial Class Ventas
End If
End If
'verifica si tiene ventaminima
If Cantidad > 0 AndAlso DrPS("VentaMinima").ToString().ToDecimal > 0 Then
'verifico que la cantidad sea multiplo de venta minima, es decir ventaminima =5, solo puede vender 5,10,15...
If Cantidad Mod DrPS("VentaMinima").ToString().ToDecimal <> 0 Then
Alert(String.Format("El producto se vende solo en cantidades de {0}", DrPS("VentaMinima").ToString()))
Return False
'SI NO ES REFACTURACION verifica si tiene ventaminima
If NuevaFactura <> 1 Then
If Cantidad > 0 AndAlso DrPS("VentaMinima").ToString().ToDecimal > 0 Then
'verifico que la cantidad sea multiplo de venta minima, es decir ventaminima =5, solo puede vender 5,10,15...
If Cantidad Mod DrPS("VentaMinima").ToString().ToDecimal <> 0 Then
Alert(String.Format("El producto se vende solo en cantidades de {0}", DrPS("VentaMinima").ToString()))
Return False
End If
End If
End If

View File

@@ -280,6 +280,14 @@