Merge branch 'master' of http://jperez@192.168.10.111:8383/SIG.git
This commit is contained in:
@@ -4747,7 +4747,9 @@ Public Class ClsContabilidad
|
|||||||
Public Function UpdateCuenta(CveCuenta As Integer, Nombre As String, Tipo As String, CtaMayor As Integer, CveMoneda As Integer, Optional DigAgrupador As Integer = -1,
|
Public Function UpdateCuenta(CveCuenta As Integer, Nombre As String, Tipo As String, CtaMayor As Integer, CveMoneda As Integer, Optional DigAgrupador As Integer = -1,
|
||||||
Optional CveAgrupadorSAT As Integer = -1, Optional NomIdioma As String = "", Optional CveConceptoAdmin As Integer = -1, Optional CveProveedor As Integer = -1,
|
Optional CveAgrupadorSAT As Integer = -1, Optional NomIdioma As String = "", Optional CveConceptoAdmin As Integer = -1, Optional CveProveedor As Integer = -1,
|
||||||
Optional CveCliente As Integer = -1, Optional CveClasificacion As Integer = -1, Optional PorcentajeImpuesto As Decimal = -1,
|
Optional CveCliente As Integer = -1, Optional CveClasificacion As Integer = -1, Optional PorcentajeImpuesto As Decimal = -1,
|
||||||
Optional CveBancoCuenta As Integer = -1, Optional CveAlmacen As Integer = -1, Optional Afectable As Integer = -1, Optional Codigo As String = "-1") As Boolean
|
Optional CveBancoCuenta As Integer = -1, Optional CveAlmacen As Integer = -1, Optional Afectable As Integer = -1, Optional Codigo As String = "-1",
|
||||||
|
Optional CvePadre As Integer = -1) As Boolean
|
||||||
|
|
||||||
Dim Retorno As Boolean = False
|
Dim Retorno As Boolean = False
|
||||||
|
|
||||||
DataAdapter("PA_Conta_UpdateCuentas")
|
DataAdapter("PA_Conta_UpdateCuentas")
|
||||||
@@ -4770,6 +4772,8 @@ Public Class ClsContabilidad
|
|||||||
.Add("@CveAlmacen", SqlDbType.Int).Value = CveAlmacen
|
.Add("@CveAlmacen", SqlDbType.Int).Value = CveAlmacen
|
||||||
.Add("@Afectable", SqlDbType.Int).Value = Afectable
|
.Add("@Afectable", SqlDbType.Int).Value = Afectable
|
||||||
.Add("@Codigo", SqlDbType.VarChar).Value = Codigo
|
.Add("@Codigo", SqlDbType.VarChar).Value = Codigo
|
||||||
|
.Add("@CvePadre", SqlDbType.Int).Value = CvePadre
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
End With
|
End With
|
||||||
|
|||||||
@@ -99,7 +99,7 @@ Partial Class Bancos_CuentasBancariasDetalle
|
|||||||
Private Sub CargaCuentasContables()
|
Private Sub CargaCuentasContables()
|
||||||
Dim dt As DataTable = Nothing
|
Dim dt As DataTable = Nothing
|
||||||
|
|
||||||
If UsuarioActual.Empresa.TipoContabilizacion = 1 Then
|
If UsuarioActual.Empresa.TipoContabilidad = 1 Then
|
||||||
Using ObjContabilidad As New ClsContabilidad
|
Using ObjContabilidad As New ClsContabilidad
|
||||||
'UsuarioActual.Empresa.Funcionalidad(208).ToEntero
|
'UsuarioActual.Empresa.Funcionalidad(208).ToEntero
|
||||||
If ObjContabilidad.GetCuentas(-1, "-1", 1, UsuarioActual.CveEmpresa) Then
|
If ObjContabilidad.GetCuentas(-1, "-1", 1, UsuarioActual.CveEmpresa) Then
|
||||||
@@ -122,7 +122,7 @@ Partial Class Bancos_CuentasBancariasDetalle
|
|||||||
trCuentaContableComplementaria.Visible = True
|
trCuentaContableComplementaria.Visible = True
|
||||||
|
|
||||||
Else
|
Else
|
||||||
If UsuarioActual.Empresa.UsaContabilidad Or UsuarioActual.Empresa.UsaAC Then
|
If UsuarioActual.Empresa.TipoContabilidad = 2 Or UsuarioActual.Empresa.UsaAC Then
|
||||||
Dim IdPadre As Integer
|
Dim IdPadre As Integer
|
||||||
Dim Conta As New ClsContPAQi(UsuarioActual.Empresa)
|
Dim Conta As New ClsContPAQi(UsuarioActual.Empresa)
|
||||||
|
|
||||||
@@ -212,36 +212,24 @@ Partial Class Bancos_CuentasBancariasDetalle
|
|||||||
End If
|
End If
|
||||||
Next
|
Next
|
||||||
|
|
||||||
|
|
||||||
If ExisteEnIntems Then
|
If ExisteEnIntems Then
|
||||||
DDlCuentaContable.SelectedValueExist(ObjCuentasBancariasDetalle.IdCtaContable.ToString)
|
DDlCuentaContable.SelectedValueExist(ObjCuentasBancariasDetalle.IdCtaContable.ToString)
|
||||||
Else
|
Else
|
||||||
|
If UsuarioActual.Empresa.TipoContabilidad = 2 Then
|
||||||
If UsuarioActual.Empresa.UsaContabilidad Then
|
|
||||||
Dim objCont As New ClsContPAQi(UsuarioActual.Empresa)
|
Dim objCont As New ClsContPAQi(UsuarioActual.Empresa)
|
||||||
|
|
||||||
|
|
||||||
If objCont.GetCuentas(ObjCuentasBancariasDetalle.IdCtaContable, "-1", -1) Then
|
If objCont.GetCuentas(ObjCuentasBancariasDetalle.IdCtaContable, "-1", -1) Then
|
||||||
If objCont.DtResultados.Rows.Count > 0 Then
|
If objCont.DtResultados.Rows.Count > 0 Then
|
||||||
|
|
||||||
DDlCuentaContable.Items.Add(New ListItem(objCont.DtResultados.Rows(0)("CtaCodigo").ToString, objCont.DtResultados.Rows(0)("id").ToString))
|
DDlCuentaContable.Items.Add(New ListItem(objCont.DtResultados.Rows(0)("CtaCodigo").ToString, objCont.DtResultados.Rows(0)("id").ToString))
|
||||||
DDlCuentaContable.SelectedValueExist(ObjCuentasBancariasDetalle.IdCtaContable.ToString)
|
DDlCuentaContable.SelectedValueExist(ObjCuentasBancariasDetalle.IdCtaContable.ToString)
|
||||||
|
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|
||||||
objCont.Dispose()
|
objCont.Dispose()
|
||||||
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|
||||||
DdlCuentaContableComplementaria.SelectedValueExist(ObjCuentasBancariasDetalle.IdCtaContableComplementaria.ToString)
|
DdlCuentaContableComplementaria.SelectedValueExist(ObjCuentasBancariasDetalle.IdCtaContableComplementaria.ToString)
|
||||||
|
|
||||||
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
Else
|
Else
|
||||||
|
|||||||
@@ -8372,6 +8372,8 @@ Partial Class Compras_Compras
|
|||||||
|
|
||||||
If CveCompra > 0 Then
|
If CveCompra > 0 Then
|
||||||
|
|
||||||
|
Dim ObjContaAC As ClsContPAQi = Nothing
|
||||||
|
|
||||||
'INICIALIZA OBJETOS
|
'INICIALIZA OBJETOS
|
||||||
If Not (ObjComprasParametro IsNot Nothing And ObjContaParametro IsNot Nothing) Then
|
If Not (ObjComprasParametro IsNot Nothing And ObjContaParametro IsNot Nothing) Then
|
||||||
ObjCompra = New ClsCompras
|
ObjCompra = New ClsCompras
|
||||||
@@ -8478,8 +8480,33 @@ Partial Class Compras_Compras
|
|||||||
|
|
||||||
Next
|
Next
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
If ErrorMovtosCxP = 0 And CvePrePolizaNueva > 0 Then
|
||||||
|
|
||||||
|
If (UsuarioActual.Empresa.UsaAC Or UsuarioActual.Empresa.Funcionalidad(200).ToString = "1") AndAlso IdPoliza > 0 AndAlso UsuarioActual.Empresa.TipoContabilidad = 2 Then
|
||||||
|
If ObjContaAC Is Nothing Then
|
||||||
|
ObjContaAC = New ClsContPAQi(UsuarioActual.Empresa)
|
||||||
|
ObjContaAC.IniciaTransacSQL()
|
||||||
|
End If
|
||||||
|
|
||||||
|
If Not ObjConta.ContabilizarPrePoliza(CvePrePolizaNueva, UsuarioActual.CveEmpresa, UsuarioActual.Empresa, MinFecha, "", ObjContaAC) Then
|
||||||
|
ErrorMovtosCxP = 3
|
||||||
|
End If
|
||||||
|
|
||||||
|
End If
|
||||||
|
|
||||||
|
End If
|
||||||
|
|
||||||
Select Case ErrorMovtosCxP
|
Select Case ErrorMovtosCxP
|
||||||
Case 0
|
Case 0
|
||||||
|
|
||||||
|
If (UsuarioActual.Empresa.UsaAC Or UsuarioActual.Empresa.Funcionalidad(200).ToString = "1") AndAlso IdPoliza > 0 AndAlso UsuarioActual.Empresa.TipoContabilidad = 2 Then
|
||||||
|
If ObjContaAC IsNot Nothing Then
|
||||||
|
ObjContaAC.Commit()
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
|
||||||
Alert("El movimiento se aplicó correctamente.", TipoMensaje.MsgInformacion)
|
Alert("El movimiento se aplicó correctamente.", TipoMensaje.MsgInformacion)
|
||||||
ObjCompra.Commit()
|
ObjCompra.Commit()
|
||||||
|
|
||||||
@@ -8501,18 +8528,40 @@ Partial Class Compras_Compras
|
|||||||
UpAnticipos.Update()
|
UpAnticipos.Update()
|
||||||
UpPS.Update()
|
UpPS.Update()
|
||||||
dtnc.Dispose()
|
dtnc.Dispose()
|
||||||
|
|
||||||
Case 1
|
Case 1
|
||||||
Alert("Ocurrió un error al amortizar la nota de crédito<br />Revise su factura y cualquier detalle comuníquese a Soporte Técnico", TipoMensaje.MsgAdvertencia)
|
Alert("Ocurrió un error al amortizar la nota de crédito<br />Revise su factura y cualquier detalle comuníquese a Soporte Técnico", TipoMensaje.MsgAdvertencia)
|
||||||
ObjCompra.RollBack()
|
ObjCompra.RollBack()
|
||||||
Case 2
|
Case 2
|
||||||
Alert("Ocurrió un error al amortizar la nota de crédito<br />Revise su factura y cualquier detalle comuníquese a Soporte Técnico", TipoMensaje.MsgAdvertencia)
|
Alert("Ocurrió un error al amortizar la nota de crédito<br />Revise su factura y cualquier detalle comuníquese a Soporte Técnico", TipoMensaje.MsgAdvertencia)
|
||||||
|
ObjCompra.RollBack()
|
||||||
|
Case 3
|
||||||
|
Alert("Ocurrió un error al contabilizar la la amortizacion del anticipo.", TipoMensaje.MsgAdvertencia)
|
||||||
|
|
||||||
|
If (UsuarioActual.Empresa.UsaAC Or UsuarioActual.Empresa.Funcionalidad(200).ToString = "1") AndAlso IdPoliza > 0 AndAlso UsuarioActual.Empresa.TipoContabilidad = 2 Then
|
||||||
|
If ObjContaAC IsNot Nothing Then
|
||||||
|
Try
|
||||||
|
ObjContaAC.RollBack()
|
||||||
|
Catch ex As Exception
|
||||||
|
|
||||||
|
End Try
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
|
||||||
ObjCompra.RollBack()
|
ObjCompra.RollBack()
|
||||||
End Select
|
End Select
|
||||||
|
|
||||||
Catch ex As Exception
|
Catch ex As Exception
|
||||||
ObjCompra.RollBack()
|
ObjCompra.RollBack()
|
||||||
End Try
|
End Try
|
||||||
|
|
||||||
|
|
||||||
|
If ObjContaAC IsNot Nothing Then
|
||||||
|
ObjContaAC.Dispose()
|
||||||
|
End If
|
||||||
|
|
||||||
ObjCompra.Dispose()
|
ObjCompra.Dispose()
|
||||||
|
|
||||||
Else
|
Else
|
||||||
'sino se ha guardado la compra, se registra temporal que anticpos van a cargarle
|
'sino se ha guardado la compra, se registra temporal que anticpos van a cargarle
|
||||||
|
|
||||||
@@ -14290,7 +14339,7 @@ Partial Class Compras_Compras
|
|||||||
|
|
||||||
'SI PUEDE RECIBIR POR OC Y COMPRA
|
'SI PUEDE RECIBIR POR OC Y COMPRA
|
||||||
' si usa almacen, si tiene activado que reciba por OC, y que si la compra tipo Proveedor. que lo muestre
|
' si usa almacen, si tiene activado que reciba por OC, y que si la compra tipo Proveedor. que lo muestre
|
||||||
If UsuarioActual.CveEmpresa = 119 AndAlso UsuarioActual.Empresa.UsaInventarios And UsuarioActual.Empresa.Funcionalidad(131).ToEntero > 0 AndAlso CveTipoConcepto = 1 Then
|
If UsuarioActual.Empresa.UsaInventarios And UsuarioActual.Empresa.Funcionalidad(131).ToEntero > 0 AndAlso CveTipoConcepto = 1 Then
|
||||||
DivOCVinculaInv.Visible = True
|
DivOCVinculaInv.Visible = True
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|||||||
@@ -4468,6 +4468,9 @@ Partial Class Compras_Proveedores
|
|||||||
|
|
||||||
Dim CuentaPadre = -1
|
Dim CuentaPadre = -1
|
||||||
|
|
||||||
|
Dim TipoCuenta As String = "D"
|
||||||
|
|
||||||
|
|
||||||
Select Case btn.CommandArgument.ToString
|
Select Case btn.CommandArgument.ToString
|
||||||
Case "Proveedores"
|
Case "Proveedores"
|
||||||
CuentaPadre = If(DdlCveTipoProveedor.SelectedValue = "2", UsuarioActual.Empresa.Funcionalidad(202).ToEntero, UsuarioActual.Empresa.Funcionalidad(201).ToEntero)
|
CuentaPadre = If(DdlCveTipoProveedor.SelectedValue = "2", UsuarioActual.Empresa.Funcionalidad(202).ToEntero, UsuarioActual.Empresa.Funcionalidad(201).ToEntero)
|
||||||
@@ -4477,6 +4480,7 @@ Partial Class Compras_Proveedores
|
|||||||
CuentaPadre = UsuarioActual.Empresa.Funcionalidad(203).ToEntero
|
CuentaPadre = UsuarioActual.Empresa.Funcionalidad(203).ToEntero
|
||||||
Case "Anticipos"
|
Case "Anticipos"
|
||||||
CuentaPadre = UsuarioActual.Empresa.Funcionalidad(204).ToEntero
|
CuentaPadre = UsuarioActual.Empresa.Funcionalidad(204).ToEntero
|
||||||
|
TipoCuenta = "A"
|
||||||
Case "Deudores"
|
Case "Deudores"
|
||||||
CuentaPadre = UsuarioActual.Empresa.Funcionalidad(205).ToEntero
|
CuentaPadre = UsuarioActual.Empresa.Funcionalidad(205).ToEntero
|
||||||
|
|
||||||
|
|||||||
@@ -257,7 +257,7 @@
|
|||||||
<br />
|
<br />
|
||||||
<asp:UpdatePanel ID="UPDatos" runat="server" UpdateMode="Conditional">
|
<asp:UpdatePanel ID="UPDatos" runat="server" UpdateMode="Conditional">
|
||||||
<ContentTemplate>
|
<ContentTemplate>
|
||||||
<asp:GridView ID="GvDatos" runat="server" data-sort="true" Width="99%" AutoGenerateColumns="False" EmptyDataText="No se encontraron Ventas con los filtros especificados" ToolTip="Listado de Ventas" CssClass="table table-striped table-advance table-hover Widthall ScrollAD" GridLines="None">
|
<asp:GridView ID="GvDatos" runat="server" data-sort="true" Width="99%" AutoGenerateColumns="False" EmptyDataText="No se encontraron compras con los filtros especificados" ToolTip="Listado de Ventas" CssClass="table table-striped table-advance table-hover Widthall ScrollAD" GridLines="None">
|
||||||
<Columns>
|
<Columns>
|
||||||
<asp:TemplateField>
|
<asp:TemplateField>
|
||||||
<HeaderTemplate>
|
<HeaderTemplate>
|
||||||
|
|||||||
@@ -406,7 +406,7 @@ Partial Class RepCxPDetalle
|
|||||||
TMP_DTDatos = ObjMovtos.DtResultados
|
TMP_DTDatos = ObjMovtos.DtResultados
|
||||||
TMP_DTDatos.Columns.Add("Cuenta")
|
TMP_DTDatos.Columns.Add("Cuenta")
|
||||||
|
|
||||||
If DdlGrupo.SelectedValue.ToEntero = 5 And UsuarioActual.Empresa.UsaContabilidad Then 'cuando es grupo por proveedor, se muestra la cuneta contable
|
If DdlGrupo.SelectedValue.ToEntero = 5 And UsuarioActual.Empresa.TipoContabilidad = 2 Then 'cuando es grupo por proveedor, se muestra la cuneta contable
|
||||||
TMP_DTDatos = CargaCuentasContables(TMP_DTDatos)
|
TMP_DTDatos = CargaCuentasContables(TMP_DTDatos)
|
||||||
GvDatos.Columns(13).Visible = True
|
GvDatos.Columns(13).Visible = True
|
||||||
Else
|
Else
|
||||||
|
|||||||
@@ -736,8 +736,8 @@ Partial Class ContabilidadC_RegPrePolizaS
|
|||||||
Private Sub CargaClientes()
|
Private Sub CargaClientes()
|
||||||
DdlClientes.setEsWebService(True)
|
DdlClientes.setEsWebService(True)
|
||||||
DdlClientes.Attributes.Add("data-metodo", "getcliente")
|
DdlClientes.Attributes.Add("data-metodo", "getcliente")
|
||||||
DdlClientes.DataSource = GlobalDTCliente(UsuarioActual.CveEmpresa)
|
'DdlClientes.DataSource = GlobalDTCliente(UsuarioActual.CveEmpresa)
|
||||||
DdlClientes.DataBind()
|
'DdlClientes.DataBind()
|
||||||
' DdlClientes.Items.Insert(0, New ListItem(" - ", "-1"))
|
' DdlClientes.Items.Insert(0, New ListItem(" - ", "-1"))
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
@@ -1359,16 +1359,17 @@ Partial Class ContabilidadC_RegPrePolizaS
|
|||||||
|
|
||||||
If CveCliente > 0 Then
|
If CveCliente > 0 Then
|
||||||
DvModalconceptoCliente.Visible = True
|
DvModalconceptoCliente.Visible = True
|
||||||
DdlClientesE.SelectedValue = CveCliente
|
|
||||||
DdlClientesE.SelectedText = GlobalDTCliente(UsuarioActual.CveEmpresa, CveCliente:=CveCliente).FiltroPrimeroValor("NombreComercial", "")
|
|
||||||
DdlClientesE_SelectedIndexChanged(DdlClientesE, e)
|
|
||||||
|
|
||||||
|
DdlClientesE.SelectedText = GlobalDTCliente(UsuarioActual.CveEmpresa, CveCliente:=CveCliente).FiltroPrimeroValor("NombreComercial", "")
|
||||||
|
DdlClientesE.ddl.Items.Insert(0, New ListItem(GlobalDTCliente(UsuarioActual.CveEmpresa, CveCliente:=CveCliente).FiltroPrimeroValor("NombreComercial", ""), CveCliente))
|
||||||
|
DdlClientesE.SelectedValue = CveCliente
|
||||||
|
|
||||||
|
CargaVentasE(CveCliente)
|
||||||
End If
|
End If
|
||||||
If CveVenta > 0 Then
|
If CveVenta > 0 Then
|
||||||
DdlVentasE.SelectedValueExist(CveVenta)
|
DdlVentasE.SelectedValueExist(CveVenta)
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|
||||||
If CveClasificacion > 0 Then
|
If CveClasificacion > 0 Then
|
||||||
DdlClasificacionesE.SelectedValue = CveClasificacion
|
DdlClasificacionesE.SelectedValue = CveClasificacion
|
||||||
End If
|
End If
|
||||||
@@ -1621,11 +1622,20 @@ Partial Class ContabilidadC_RegPrePolizaS
|
|||||||
DdlClientesE.setEsWebService(True)
|
DdlClientesE.setEsWebService(True)
|
||||||
|
|
||||||
DdlClientesE.Attributes.Add("data-metodo", "getcliente")
|
DdlClientesE.Attributes.Add("data-metodo", "getcliente")
|
||||||
'DdlClientesE.DataSource = GlobalDTCliente(UsuarioActual.CveEmpresa)
|
|
||||||
'DdlClientesE.DataBind()
|
|
||||||
' DdlClientes.Items.Insert(0, New ListItem(" - ", "-1"))
|
|
||||||
End Sub
|
End Sub
|
||||||
Private Sub CargaVentasE(CveCliente As Integer, Optional CveMoneda As Integer = -1)
|
Private Sub CargaVentasE(CveCliente As Integer)
|
||||||
|
If CveCliente <= 0 Then Exit Sub
|
||||||
|
|
||||||
|
If DrConceptoContable IsNot Nothing Then
|
||||||
|
Dim AplicaME = Boolean.Parse(DrConceptoContable("EsMonedaExtranjera").ToString)
|
||||||
|
Dim AplicaVenta = Boolean.Parse(DrConceptoContable("AplicaVenta").ToString)
|
||||||
|
If AplicaME Then
|
||||||
|
CveMoneda = 2
|
||||||
|
End If
|
||||||
|
If Not AplicaVenta Then Exit Sub
|
||||||
|
End If
|
||||||
|
|
||||||
DvModalconceptoVenta.Visible = True
|
DvModalconceptoVenta.Visible = True
|
||||||
DdlVentasE.DataSource = Nothing
|
DdlVentasE.DataSource = Nothing
|
||||||
DdlVentasE.ClearSelection()
|
DdlVentasE.ClearSelection()
|
||||||
@@ -1661,16 +1671,9 @@ Partial Class ContabilidadC_RegPrePolizaS
|
|||||||
CargaComprasE(DdlProveedoresE.SelectedValue.ToEntero)
|
CargaComprasE(DdlProveedoresE.SelectedValue.ToEntero)
|
||||||
End Sub
|
End Sub
|
||||||
Private Sub DdlClientesE_SelectedIndexChanged(sender As Object, e As EventArgs) Handles DdlClientesE.selectedindexchange
|
Private Sub DdlClientesE_SelectedIndexChanged(sender As Object, e As EventArgs) Handles DdlClientesE.selectedindexchange
|
||||||
Dim tCveMoneda As Integer = 1
|
|
||||||
|
|
||||||
If DrConceptoContable IsNot Nothing Then
|
If DdlClientesE.SelectedValue.ToEntero > 0 Then CargaVentasE(DdlClientesE.SelectedValue.ToEntero)
|
||||||
Dim AplicaME = Boolean.Parse(DrConceptoContable("EsMonedaExtranjera").ToString)
|
|
||||||
If AplicaME Then
|
|
||||||
tCveMoneda = 2
|
|
||||||
End If
|
|
||||||
End If
|
|
||||||
|
|
||||||
CargaVentasE(DdlClientesE.SelectedValue.ToEntero, tCveMoneda)
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Function CargaValidacionesConcepto() As Boolean
|
Private Function CargaValidacionesConcepto() As Boolean
|
||||||
@@ -1853,7 +1856,7 @@ Partial Class ContabilidadC_RegPrePolizaS
|
|||||||
TxtTotalAbonos.Text = DtMovimientos.SUMD("Abono").ToString.FormatoNumero
|
TxtTotalAbonos.Text = DtMovimientos.SUMD("Abono").ToString.FormatoNumero
|
||||||
UpTotalCargo.Update()
|
UpTotalCargo.Update()
|
||||||
UpTotalAbono.Update()
|
UpTotalAbono.Update()
|
||||||
DdlClientesE.SelectedValue = "-1"
|
DdlClientesE.ddl.Items.Clear()
|
||||||
DdlClientesE.SelectedText = ""
|
DdlClientesE.SelectedText = ""
|
||||||
|
|
||||||
End If
|
End If
|
||||||
|
|||||||
@@ -47,6 +47,11 @@
|
|||||||
font-size: 9px !important;
|
font-size: 9px !important;
|
||||||
content: "\f040";
|
content: "\f040";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#select2-C_DdlCuentaContable-results{
|
||||||
|
max-width:300px!important
|
||||||
|
}
|
||||||
|
|
||||||
</style>
|
</style>
|
||||||
</asp:Content>
|
</asp:Content>
|
||||||
<asp:Content ID="Content3" ContentPlaceHolderID="HB" runat="Server">
|
<asp:Content ID="Content3" ContentPlaceHolderID="HB" runat="Server">
|
||||||
@@ -110,6 +115,9 @@
|
|||||||
<div class="catcuentas left">Subcuenta de</div>
|
<div class="catcuentas left">Subcuenta de</div>
|
||||||
<div class="catcuentas right">
|
<div class="catcuentas right">
|
||||||
<asp:TextBox ID="Tsubcuenta" runat="server" Enabled="False" Width="140px" ClientIDMode="Static"></asp:TextBox>
|
<asp:TextBox ID="Tsubcuenta" runat="server" Enabled="False" Width="140px" ClientIDMode="Static"></asp:TextBox>
|
||||||
|
<asp:DropDownList ID="DdlCuentaContable" CssClass="form-control input-sm select2me" runat="server" AppendDataBoundItems="false" DataTextField="CtaCodigo" style="max-width:160px"
|
||||||
|
DataValueField="Id" Width="160px" Visible="false">
|
||||||
|
</asp:DropDownList>
|
||||||
<br />
|
<br />
|
||||||
<asp:Label ID="LblSubCuenta" runat="server" Text="" Font-Italic="True" Font-Size="7pt" ClientIDMode="Static"></asp:Label>
|
<asp:Label ID="LblSubCuenta" runat="server" Text="" Font-Italic="True" Font-Size="7pt" ClientIDMode="Static"></asp:Label>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -186,6 +186,10 @@ Partial Class Contabilidad2_CatCuentas
|
|||||||
End Function
|
End Function
|
||||||
Protected Sub agregar_Click(sender As Object, e As EventArgs) Handles ArbolCuentas.addclick
|
Protected Sub agregar_Click(sender As Object, e As EventArgs) Handles ArbolCuentas.addclick
|
||||||
LimpiarCampos()
|
LimpiarCampos()
|
||||||
|
|
||||||
|
Tsubcuenta.Visible = True
|
||||||
|
DdlCuentaContable.Visible = False
|
||||||
|
|
||||||
Dim dt As New DataTable
|
Dim dt As New DataTable
|
||||||
|
|
||||||
'IDSelected = HdnID.Value.ToEntero() "ul" + itempadre.Cve;
|
'IDSelected = HdnID.Value.ToEntero() "ul" + itempadre.Cve;
|
||||||
@@ -243,6 +247,11 @@ Partial Class Contabilidad2_CatCuentas
|
|||||||
Protected Sub editar_Click(sender As Object, e As EventArgs) Handles ArbolCuentas.editclick
|
Protected Sub editar_Click(sender As Object, e As EventArgs) Handles ArbolCuentas.editclick
|
||||||
LimpiarCampos()
|
LimpiarCampos()
|
||||||
limpiavalorescontables()
|
limpiavalorescontables()
|
||||||
|
CargaCuentasContables()
|
||||||
|
|
||||||
|
Tsubcuenta.Visible = False
|
||||||
|
DdlCuentaContable.Visible = True
|
||||||
|
|
||||||
Dim dt As DataTable
|
Dim dt As DataTable
|
||||||
Dim obj As ADServerControl.DragableItem = DirectCast(sender, ADServerControl.DragableItem)
|
Dim obj As ADServerControl.DragableItem = DirectCast(sender, ADServerControl.DragableItem)
|
||||||
IDSelected = obj.Cve
|
IDSelected = obj.Cve
|
||||||
@@ -301,6 +310,7 @@ Partial Class Contabilidad2_CatCuentas
|
|||||||
If dt.Rows.Count > 0 Then
|
If dt.Rows.Count > 0 Then
|
||||||
Dim drt As DataRow = dt.Rows(0)
|
Dim drt As DataRow = dt.Rows(0)
|
||||||
Tsubcuenta.Text = drt("Codigo").ToString
|
Tsubcuenta.Text = drt("Codigo").ToString
|
||||||
|
DdlCuentaContable.SelectedValueExist(drt("CveCuenta").ToString)
|
||||||
LblSubCuenta.Text = drt("Nombre").ToString
|
LblSubCuenta.Text = drt("Nombre").ToString
|
||||||
End If
|
End If
|
||||||
|
|
||||||
@@ -313,6 +323,25 @@ Partial Class Contabilidad2_CatCuentas
|
|||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
Private Sub CargaCuentasContables()
|
||||||
|
|
||||||
|
DdlCuentaContable.ClearSelection()
|
||||||
|
DdlCuentaContable.Items.Clear()
|
||||||
|
DdlCuentaContable.SelectedValue = Nothing
|
||||||
|
|
||||||
|
Dim ObjConta As New ClsContabilidad
|
||||||
|
|
||||||
|
If ObjConta.GetCuentas(-1, "-1", 1, UsuarioActual.CveEmpresa) Then
|
||||||
|
DdlCuentaContable.DataSource = ObjConta.DtResultados
|
||||||
|
End If
|
||||||
|
|
||||||
|
ObjConta.Dispose()
|
||||||
|
|
||||||
|
DdlCuentaContable.DataBind()
|
||||||
|
DdlCuentaContable.Items.Insert(0, New ListItem("-", "-1"))
|
||||||
|
DdlCuentaContable.SelectedValueExist("-1")
|
||||||
|
|
||||||
|
End Sub
|
||||||
Protected Sub Guardar_Click(sender As Object, e As EventArgs) Handles Guardar.Click
|
Protected Sub Guardar_Click(sender As Object, e As EventArgs) Handles Guardar.Click
|
||||||
|
|
||||||
If Tnombre.Text.Trim = "" Then Alert("Ingrese nombre de la cuenta", TipoMensaje.MsgError) : Exit Sub
|
If Tnombre.Text.Trim = "" Then Alert("Ingrese nombre de la cuenta", TipoMensaje.MsgError) : Exit Sub
|
||||||
@@ -328,11 +357,13 @@ Partial Class Contabilidad2_CatCuentas
|
|||||||
Dim CveBancoCuenta As Integer = ddlBancos.SelectedValue.ToEntero
|
Dim CveBancoCuenta As Integer = ddlBancos.SelectedValue.ToEntero
|
||||||
Dim CveAlmacen As Integer = DdlAlmacen.SelectedValue.ToEntero()
|
Dim CveAlmacen As Integer = DdlAlmacen.SelectedValue.ToEntero()
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
If DdlAgrupadorSAT.SelectedValue.ToEntero > 0 Then
|
If DdlAgrupadorSAT.SelectedValue.ToEntero > 0 Then
|
||||||
If ObjConta.UpdateCuenta(IDSelected.ToEntero, Tnombre.Text, DTcuenta.SelectedValue.ToString, DcuentaMayor.SelectedValue.ToString.ToEntero, DdlMoneda.SelectedValue.ToEntero,
|
If ObjConta.UpdateCuenta(IDSelected.ToEntero, Tnombre.Text, DTcuenta.SelectedValue.ToString, DcuentaMayor.SelectedValue.ToString.ToEntero, DdlMoneda.SelectedValue.ToEntero,
|
||||||
TxtDigAgrup.Text.ToString.ToEntero, DdlAgrupadorSAT.SelectedValue.ToEntero, TxtNomIngles.Text.ToString, CveConceptoAdmin:=CveConceptoAdmin,
|
TxtDigAgrup.Text.ToString.ToEntero, DdlAgrupadorSAT.SelectedValue.ToEntero, TxtNomIngles.Text.ToString, CveConceptoAdmin:=CveConceptoAdmin,
|
||||||
CveProveedor:=CveProveedor, CveCliente:=CveCliente, CveClasificacion:=CveClasificacion, PorcentajeImpuesto:=PorcentajeImpuesto,
|
CveProveedor:=CveProveedor, CveCliente:=CveCliente, CveClasificacion:=CveClasificacion, PorcentajeImpuesto:=PorcentajeImpuesto,
|
||||||
CveBancoCuenta:=CveBancoCuenta, CveAlmacen:=CveAlmacen, Codigo:=TxtCuenta.Text.Replace("-", "")) Then
|
CveBancoCuenta:=CveBancoCuenta, CveAlmacen:=CveAlmacen, Codigo:=TxtCuenta.Text.Replace("-", ""), CvePadre:=DdlCuentaContable.SelectedValue.ToEntero) Then
|
||||||
|
|
||||||
If UsuarioActual.Empresa.TipoContabilidad = 2 Then
|
If UsuarioActual.Empresa.TipoContabilidad = 2 Then
|
||||||
Dim ObjContaEmpresa As New ClsContPAQi(UsuarioActual.Empresa)
|
Dim ObjContaEmpresa As New ClsContPAQi(UsuarioActual.Empresa)
|
||||||
@@ -592,6 +623,9 @@ Partial Class Contabilidad2_CatCuentas
|
|||||||
nuevacuenta.Visible = False
|
nuevacuenta.Visible = False
|
||||||
TxtCuenta.Enabled = False
|
TxtCuenta.Enabled = False
|
||||||
'Tcuenta.Enabled = False
|
'Tcuenta.Enabled = False
|
||||||
|
DdlCuentaContable.SelectedValueExist(-1)
|
||||||
|
DdlCuentaContable.Visible = False
|
||||||
|
Tsubcuenta.Visible = True
|
||||||
BtnEliminar.Visible = False
|
BtnEliminar.Visible = False
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
|||||||
@@ -58,7 +58,7 @@
|
|||||||
</asp:DropDownList>
|
</asp:DropDownList>
|
||||||
</div>
|
</div>
|
||||||
<label class="col-md-2" style="width: 80px; display:none;">SubProyecto: </label>
|
<label class="col-md-2" style="width: 80px; display:none;">SubProyecto: </label>
|
||||||
<div class="col-md-2 ">
|
<div class="col-md-2" style=" display:none;">
|
||||||
<asp:DropDownList ID="DdlSubproyecto" runat="server" Width="150px" AppendDataBoundItems="true" DataTextField="SubProyecto" DataValueField="CveSubProyecto" CssClass="form-control input-sm select2me" >
|
<asp:DropDownList ID="DdlSubproyecto" runat="server" Width="150px" AppendDataBoundItems="true" DataTextField="SubProyecto" DataValueField="CveSubProyecto" CssClass="form-control input-sm select2me" >
|
||||||
<asp:ListItem Selected="True" Text="Todas" Value="-1"></asp:ListItem>
|
<asp:ListItem Selected="True" Text="Todas" Value="-1"></asp:ListItem>
|
||||||
</asp:DropDownList>
|
</asp:DropDownList>
|
||||||
|
|||||||
@@ -576,33 +576,36 @@ Partial Class General_SaldosIniciales
|
|||||||
Alert("El nombre de la primera columna debe ser 'CuentaBancaria'. Favor de corregirlo", TipoMensaje.MsgError)
|
Alert("El nombre de la primera columna debe ser 'CuentaBancaria'. Favor de corregirlo", TipoMensaje.MsgError)
|
||||||
Exit Sub
|
Exit Sub
|
||||||
End If
|
End If
|
||||||
|
If Not dt.Columns(1).ColumnName = "Banco" Then
|
||||||
If Not dt.Columns(1).ColumnName = "Importe" Then
|
Alert("El nombre de la primera columna debe ser 'Banco'. Favor de corregirlo", TipoMensaje.MsgError)
|
||||||
|
Exit Sub
|
||||||
|
End If
|
||||||
|
If Not dt.Columns(2).ColumnName = "Importe" Then
|
||||||
Alert("El nombre de la segunda columna debe ser 'Importe'. Favor de corregirlo", TipoMensaje.MsgError)
|
Alert("El nombre de la segunda columna debe ser 'Importe'. Favor de corregirlo", TipoMensaje.MsgError)
|
||||||
Exit Sub
|
Exit Sub
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If Not dt.Columns(2).ColumnName = "Moneda" Then
|
If Not dt.Columns(3).ColumnName = "Moneda" Then
|
||||||
Alert("El nombre de la segunda columna debe ser 'Moneda'. Favor de corregirlo", TipoMensaje.MsgError)
|
Alert("El nombre de la segunda columna debe ser 'Moneda'. Favor de corregirlo", TipoMensaje.MsgError)
|
||||||
Exit Sub
|
Exit Sub
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If Not dt.Columns(3).ColumnName = "TipoCambio" Then
|
If Not dt.Columns(4).ColumnName = "TipoCambio" Then
|
||||||
Alert("El nombre de la segunda columna debe ser 'TipoCambio'. Favor de corregirlo", TipoMensaje.MsgError)
|
Alert("El nombre de la segunda columna debe ser 'TipoCambio'. Favor de corregirlo", TipoMensaje.MsgError)
|
||||||
Exit Sub
|
Exit Sub
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If Not dt.Columns(4).ColumnName = "Fecha" Then
|
If Not dt.Columns(5).ColumnName = "Fecha" Then
|
||||||
Alert("El nombre de la cuarta columna debe ser 'Fecha'. Favor de corregirlo", TipoMensaje.MsgError)
|
Alert("El nombre de la cuarta columna debe ser 'Fecha'. Favor de corregirlo", TipoMensaje.MsgError)
|
||||||
Exit Sub
|
Exit Sub
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If Not dt.Columns(5).ColumnName = "Descripcion" Then
|
If Not dt.Columns(6).ColumnName = "Descripcion" Then
|
||||||
Alert("El nombre de la cuarta columna debe ser 'Descripcion'. Favor de corregirlo", TipoMensaje.MsgError)
|
Alert("El nombre de la cuarta columna debe ser 'Descripcion'. Favor de corregirlo", TipoMensaje.MsgError)
|
||||||
Exit Sub
|
Exit Sub
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If Not dt.Columns(6).ColumnName = "CuentaContable" Then
|
If Not dt.Columns(7).ColumnName = "CuentaContable" Then
|
||||||
Alert("El nombre de la tercera columna debe ser 'CuentaContable'. Favor de corregirlo", TipoMensaje.MsgError)
|
Alert("El nombre de la tercera columna debe ser 'CuentaContable'. Favor de corregirlo", TipoMensaje.MsgError)
|
||||||
Exit Sub
|
Exit Sub
|
||||||
End If
|
End If
|
||||||
@@ -1018,7 +1021,7 @@ Partial Class General_SaldosIniciales
|
|||||||
|
|
||||||
|
|
||||||
Dim CodigoRegimenFiscal As String = Row("Regimen Fiscal").ToString
|
Dim CodigoRegimenFiscal As String = Row("Regimen Fiscal").ToString
|
||||||
Dim Clasificacion As String = Row("Clasificación Proveedor").ToString
|
Dim ProveedorClasificacion As String = Row("Clasificación Proveedor").ToString
|
||||||
Dim Moneda As String = Row("Moneda Preferente").ToString
|
Dim Moneda As String = Row("Moneda Preferente").ToString
|
||||||
Dim DIOTTipoTercero As String = Row("Tipo Tercero").ToString.Trim.ToUpper
|
Dim DIOTTipoTercero As String = Row("Tipo Tercero").ToString.Trim.ToUpper
|
||||||
Dim DIOTipoOperacion As String = Row("Tipo Operación").ToString
|
Dim DIOTipoOperacion As String = Row("Tipo Operación").ToString
|
||||||
@@ -1100,10 +1103,10 @@ Partial Class General_SaldosIniciales
|
|||||||
End If
|
End If
|
||||||
|
|
||||||
|
|
||||||
If Clasificacion.Trim.Length > 0 Then
|
If ProveedorClasificacion.Trim.Length > 0 Then
|
||||||
CveProveedorClasificacion = DTClasificaciones.FiltroPrimeroValor("CveClasificacion", $"Clasificacion = '{Clasificacion}'").ToString.ToEntero
|
CveProveedorClasificacion = GlobalDTProveedorClasificacion(UsuarioActual.CveEmpresa).FiltroPrimeroValor("CveProveedorClasificacion", $"ProveedorClasificacion = '{ProveedorClasificacion}'").ToString.ToEntero
|
||||||
If Not CveProveedorClasificacion > 0 Then
|
If Not CveProveedorClasificacion > 0 Then
|
||||||
sbErrores.AppendLine($"Proveedor {RazonSocial} Clasificación {Clasificacion} invalida.<br>")
|
sbErrores.AppendLine($"Proveedor {RazonSocial} Proveedor Clasificacion {ProveedorClasificacion} invalida.<br>")
|
||||||
ErrorProv = True
|
ErrorProv = True
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
@@ -2019,10 +2022,10 @@ Partial Class General_SaldosIniciales
|
|||||||
|
|
||||||
|
|
||||||
For Each Row As DataRow In dt.Rows
|
For Each Row As DataRow In dt.Rows
|
||||||
Dim Cuenta As String = Row("Cuenta").ToString.Trim
|
Dim Cuenta As String = Row("Cuenta").ToString.Trim.Replace("-", "")
|
||||||
If Cuenta <> "" Then
|
If Cuenta <> "" Then
|
||||||
NombreCuenta = Row("NombreCuenta").ToString.Trim
|
NombreCuenta = Row("NombreCuenta").ToString.Trim
|
||||||
CuentaPadre = Row("CuentaPadre").ToString.Trim
|
CuentaPadre = Row("CuentaPadre").ToString.Trim.Replace("-", "")
|
||||||
|
|
||||||
Dim TipoCuenta As String = Row("TipoCuenta").ToString.Trim
|
Dim TipoCuenta As String = Row("TipoCuenta").ToString.Trim
|
||||||
Dim AgrupadorSAT As String = Row("AgrupadorSAT").ToString.Trim
|
Dim AgrupadorSAT As String = Row("AgrupadorSAT").ToString.Trim
|
||||||
@@ -2494,11 +2497,11 @@ Partial Class General_SaldosIniciales
|
|||||||
Dim Contador As Integer = 0
|
Dim Contador As Integer = 0
|
||||||
For Each dRow As DataRow In DTBancos.Rows
|
For Each dRow As DataRow In DTBancos.Rows
|
||||||
|
|
||||||
|
|
||||||
Dim Fecha As Date = dRow("Fecha").ToString.ToDate
|
Dim Fecha As Date = dRow("Fecha").ToString.ToDate
|
||||||
Dim Importe As Decimal = dRow("Importe").ToString.ToDecimal
|
Dim Importe As Decimal = dRow("Importe").ToString.ToDecimal
|
||||||
Dim Descripcion As String = dRow("Descripcion").ToString
|
Dim Descripcion As String = dRow("Descripcion").ToString
|
||||||
Dim NumCuenta As String = dRow("CuentaBancaria").ToString
|
Dim Banco As String = dRow("Banco").ToString
|
||||||
|
Dim NumCuenta As String = dRow("CuentaBancaria").ToString.Trim
|
||||||
Dim ImporteMX As Decimal = 0
|
Dim ImporteMX As Decimal = 0
|
||||||
Dim ImporteME As Decimal = 0
|
Dim ImporteME As Decimal = 0
|
||||||
|
|
||||||
@@ -2506,8 +2509,6 @@ Partial Class General_SaldosIniciales
|
|||||||
Dim CveMoneda As Integer
|
Dim CveMoneda As Integer
|
||||||
Dim TipoCambio As Decimal = dRow("TipoCambio").ToString.ToDecimal
|
Dim TipoCambio As Decimal = dRow("TipoCambio").ToString.ToDecimal
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
If Moneda.ToUpper.Contiene("PESOS", "PESO", "MXN") Then
|
If Moneda.ToUpper.Contiene("PESOS", "PESO", "MXN") Then
|
||||||
CveMoneda = 1
|
CveMoneda = 1
|
||||||
TipoCambio = 1
|
TipoCambio = 1
|
||||||
@@ -2536,16 +2537,32 @@ Partial Class General_SaldosIniciales
|
|||||||
End If
|
End If
|
||||||
|
|
||||||
|
|
||||||
|
Dim CveTipoTransaccion As Integer = 3 ' tipo transaccion, cheque recibido
|
||||||
Dim CveCuentaBancaria As Integer = GlobalDTBancosCuentas(-1, CveEmpresa:=UsuarioActual.CveEmpresa, Estatus:=1).FiltroPrimeroValor("CveCuenta", $" NumCuenta = '{NumCuenta}'").ToEntero
|
Dim CveCuentaBancaria As Integer = GlobalDTBancosCuentas(-1, CveEmpresa:=UsuarioActual.CveEmpresa, Estatus:=-1).FiltroPrimeroValor("CveCuenta", $" NumCuenta = '{NumCuenta}'").ToEntero
|
||||||
If Not CveCuentaBancaria > 0 Then
|
If Not CveCuentaBancaria > 0 Then
|
||||||
Alert($"No se detecto cuenta Bancaria {NumCuenta}", TipoMensaje.MsgAdvertencia)
|
|
||||||
ErrorProceso = True
|
' se registrará primero
|
||||||
Exit For
|
Dim CveBanco As Integer = GlobalDTBancos().FiltroPrimeroValor("CveBanco", String.Format("CveEmpresa = {0} AND Banco = '{1}'", UsuarioActual.CveEmpresa, Banco)).ToEntero
|
||||||
|
|
||||||
|
If CveBanco > 0 Then
|
||||||
|
Dim CveTipoCuenta As Integer = 2 'tipo de cheques
|
||||||
|
If NumCuenta.ToLower.Contains("caja chica") Then CveTipoCuenta = 1 ' cuando es caja chica
|
||||||
|
If ObjBancos.AddBancosCuentas(CveBanco, 2, NumCuenta, "", CveMoneda, 1, 1, 1, 9999999, 0, 0, 0, "", UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, "", False, False) Then
|
||||||
|
CveCuentaBancaria = ObjBancos.TCveCuenta
|
||||||
|
Else
|
||||||
|
Alert($"No se detecto cuenta Bancaria {NumCuenta}", TipoMensaje.MsgAdvertencia)
|
||||||
|
ErrorProceso = True : Exit For
|
||||||
|
End If
|
||||||
|
Else
|
||||||
|
Alert($"No se detecto cuenta Bancaria {NumCuenta}", TipoMensaje.MsgAdvertencia)
|
||||||
|
ErrorProceso = True : Exit For
|
||||||
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
If ImporteMX < 0 Then CveTipoTransaccion = 2 'salida de dinero, concepto de transferencia realizada
|
||||||
|
|
||||||
Dim FolioStr As String = ""
|
Dim FolioStr As String = ""
|
||||||
FolioStr = CStr(ObjBancos.GetNextFolio(CveCuentaBancaria, 3) + Contador)
|
FolioStr = CStr(ObjBancos.GetNextFolio(CveCuentaBancaria, CveTipoTransaccion))
|
||||||
|
|
||||||
Dim CveCuentaContable As Integer = 0
|
Dim CveCuentaContable As Integer = 0
|
||||||
Dim CuentaContable As String = dRow("CuentaContable").ToString.Trim.Replace("-", "").Replace(" ", "")
|
Dim CuentaContable As String = dRow("CuentaContable").ToString.Trim.Replace("-", "").Replace(" ", "")
|
||||||
@@ -2568,32 +2585,30 @@ Partial Class General_SaldosIniciales
|
|||||||
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
If CveCuentaContable > 0 AndAlso Not AsignacionCuenta(ObjConta, 30, CveCuentaContable, CveCuentaBancaria, -1, -1, -1, UsuarioActual.CveEmpresa, -1) Then
|
||||||
If Not AsignacionCuenta(ObjConta, 30, CveCuentaContable, CveCuentaBancaria, -1, -1, -1, UsuarioActual.CveEmpresa, -1) Then
|
|
||||||
ErrorProceso = True
|
ErrorProceso = True
|
||||||
Alert("Se presento un error al guardar en asignaciones", TipoMensaje.MsgAdvertencia)
|
Alert("Se presento un error al guardar en asignaciones", TipoMensaje.MsgAdvertencia)
|
||||||
Exit For
|
Exit For
|
||||||
End If
|
End If
|
||||||
|
|
||||||
Dim CvePrePoliza As Integer = ObjConta.AddPrePolizas("Bancos/SaldoInicial", 66, Importe, Importe, CveMoneda, Fecha, FolioStr, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa)
|
If Importe <> 0 Then
|
||||||
|
Dim CvePrePoliza As Integer = ObjConta.AddPrePolizas("Bancos/SaldoInicial", 66, Importe, Importe, CveMoneda, Fecha, FolioStr, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa)
|
||||||
|
|
||||||
|
If Not CvePrePoliza > 0 Then
|
||||||
|
ErrorProceso = True : Exit For
|
||||||
|
End If
|
||||||
|
|
||||||
|
Dim CveIE As Integer = ObjBancos.AddBancos_IE(CveCuentaBancaria, CveTipoTransaccion, Fecha, FolioStr.ToString, "", Importe, CveMoneda,
|
||||||
|
TipoCambio, Descripcion, "", False, False, -1, CvePrePoliza, "", UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa)
|
||||||
|
|
||||||
|
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, False, Importe, FolioStr.ToString, 30, FolioStr, Fecha, -1, -1, CveIE:=CveIE, Contabilizable:=False, ImporteMX:=ImporteMX, ImporteME:=ImporteME, TipoCambio:=TipoCambio) Then ErrorProceso = True : Exit For
|
||||||
|
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, True, Importe, FolioStr.ToString, 95, FolioStr, Fecha, -1, -1, CveIE:=CveIE, Contabilizable:=False, ImporteMX:=ImporteMX, ImporteME:=ImporteME, TipoCambio:=TipoCambio) Then ErrorProceso = True : Exit For
|
||||||
|
|
||||||
If Not CvePrePoliza > 0 Then
|
|
||||||
ErrorProceso = True
|
|
||||||
Exit For
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|
||||||
Dim CveIE As Integer = ObjBancos.AddBancos_IE(CveCuentaBancaria, 3, Fecha, FolioStr.ToString, "", Importe, CveMoneda,
|
|
||||||
TipoCambio, Descripcion, "", False, False, -1, CvePrePoliza, "", UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa)
|
|
||||||
|
|
||||||
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, False, Importe, FolioStr.ToString, 30, FolioStr, Fecha, -1, -1, CveIE:=CveIE, Contabilizable:=False, ImporteMX:=ImporteMX, ImporteME:=ImporteME, TipoCambio:=TipoCambio) Then ErrorProceso = True : Exit For
|
|
||||||
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, True, Importe, FolioStr.ToString, 95, FolioStr, Fecha, -1, -1, CveIE:=CveIE, Contabilizable:=False, ImporteMX:=ImporteMX, ImporteME:=ImporteME, TipoCambio:=TipoCambio) Then ErrorProceso = True : Exit For
|
|
||||||
|
|
||||||
Contador = Contador + 1
|
Contador = Contador + 1
|
||||||
Next
|
Next
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
If Not ErrorProceso Then
|
If Not ErrorProceso Then
|
||||||
Alert($"Se agregaron {Contador} Movimientos.")
|
Alert($"Se agregaron {Contador} Movimientos.")
|
||||||
ObjBancos.Commit()
|
ObjBancos.Commit()
|
||||||
|
|||||||
@@ -842,8 +842,7 @@ Partial Class Inventarios_RecepcionAlmacen
|
|||||||
Dim DtPendientes As New DataTable
|
Dim DtPendientes As New DataTable
|
||||||
|
|
||||||
If ObjInventarios.ComprasPendientesAlmacenGet(-1, TxtFechaPendientes.Text.ToDate, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa) Then
|
If ObjInventarios.ComprasPendientesAlmacenGet(-1, TxtFechaPendientes.Text.ToDate, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa) Then
|
||||||
Dim FiltroTemporal = If(UsuarioActual.CveEmpresa.Contiene(119, 140, 1, 72, 80, 153, 154), "AND TipoDocto IN ('Fac','NC','DEV')", "AND TipoDocto IN ('Fac')")
|
DtPendientes = ObjInventarios.DtResultados.FiltraParametros($"CantOC >= 0 AND TipoDocto IN ('Fac','NC','DEV') ")
|
||||||
DtPendientes = ObjInventarios.DtResultados.FiltraParametros($"CantOC >= 0 {FiltroTemporal}")
|
|
||||||
Else
|
Else
|
||||||
DtPendientes = Nothing
|
DtPendientes = Nothing
|
||||||
Alert("Ocurrió un error al obtener las Compras pendientes de recibir del proveedor. Por favor vuelva a intentar", TipoMensaje.MsgError)
|
Alert("Ocurrió un error al obtener las Compras pendientes de recibir del proveedor. Por favor vuelva a intentar", TipoMensaje.MsgError)
|
||||||
|
|||||||
@@ -1,12 +1,7 @@
|
|||||||
<%@ Page Title="" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="ProductosServicios.aspx.vb" Inherits="ProductosyServicios" %>
|
<%@ Page Title="" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="ProductosServicios.aspx.vb" Inherits="ProductosyServicios" %>
|
||||||
|
|
||||||
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>
|
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>
|
||||||
<script runat="server">
|
|
||||||
|
|
||||||
Protected Sub RBLCantidad_SelectedIndexChanged(sender As Object, e As EventArgs)
|
|
||||||
|
|
||||||
End Sub
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
|
<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
|
||||||
<link href="/Metronic/assets/global/plugins/cubeportfolio/css/cubeportfolio.css" rel="stylesheet" type="text/css" />
|
<link href="/Metronic/assets/global/plugins/cubeportfolio/css/cubeportfolio.css" rel="stylesheet" type="text/css" />
|
||||||
@@ -1907,9 +1902,6 @@
|
|||||||
<div>
|
<div>
|
||||||
<p>
|
<p>
|
||||||
El producto seleccionado en el recuadro de arriba sera unificado en el producto actual
|
El producto seleccionado en el recuadro de arriba sera unificado en el producto actual
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<b>
|
<b>
|
||||||
<asp:Literal Text="" ID="LtProductoUnificar" runat="server" /></b>
|
<asp:Literal Text="" ID="LtProductoUnificar" runat="server" /></b>
|
||||||
</p>
|
</p>
|
||||||
|
|||||||
@@ -1993,7 +1993,7 @@ Partial Class ProductosyServicios
|
|||||||
RegistraScript("$('#DivUnificar').modal();LimpiaModalUnificar()")
|
RegistraScript("$('#DivUnificar').modal();LimpiaModalUnificar()")
|
||||||
End Sub
|
End Sub
|
||||||
Public Sub CargaPSUnificar()
|
Public Sub CargaPSUnificar()
|
||||||
DdlPsUnificar.DataSource = GlobalDTPSSimplificado(UsuarioActual.CveEmpresa)
|
DdlPsUnificar.DataSource = GlobalDTPSSimplificado(UsuarioActual.CveEmpresa, Estatus:=-1)
|
||||||
DdlPsUnificar.DataBind()
|
DdlPsUnificar.DataBind()
|
||||||
'DdlPsUnificar.setEsWebService(True)
|
'DdlPsUnificar.setEsWebService(True)
|
||||||
'DdlPsUnificar.ddlWS.Attributes.Add("data-clear", "1")
|
'DdlPsUnificar.ddlWS.Attributes.Add("data-clear", "1")
|
||||||
|
|||||||
Reference in New Issue
Block a user