Merge branch 'master' of http://jperez@192.168.10.111:8383/SIG.git
This commit is contained in:
@@ -37,6 +37,9 @@
|
||||
</asp:Content>
|
||||
|
||||
<asp:Content ID="Content5" ContentPlaceHolderID="H" runat="Server">
|
||||
<li>
|
||||
<asp:HyperLink ID="HplImprimirPDF" runat="server" Target="_blank" Visible="true" ><i class="fa fa-file-pdf-o" style="color:#686868;"></i> Imprimir Poliza</asp:HyperLink>
|
||||
</li>
|
||||
<%-- <li>
|
||||
<asp:LinkButton ID="LnkImprimir" runat="server"><i class="fa fa-print"></i> Imprimir</asp:LinkButton>
|
||||
</li>--%>
|
||||
@@ -151,10 +154,14 @@
|
||||
</div>
|
||||
<div class="col-md-2" runat="server">
|
||||
<asp:DropDownList ID="DdlCuentaDeposito" CssClass="form-control input-sm select2me" runat="server" AppendDataBoundItems="true" DataTextField="NumCuentaMoneda" DataValueField="CveCuenta" Width="100%"></asp:DropDownList>
|
||||
<asp:RequiredFieldValidator ID="RfvDdlCuentaDeposito" runat="server" ControlToValidate="DdlCuentaDeposito" InitialValue="-1" CssClass="help-block errorimput" Display="None"
|
||||
ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Cuenta''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="Valida">
|
||||
</asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VCRfvDdlCuentaDeposito" runat="server" HighlightCssClass="vco" TargetControlID="RfvDdlCuentaDeposito" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
|
||||
<div class="col-md-1">
|
||||
<label style="width: 70px;">Fecha:</label>
|
||||
<label style="width: 50px;">Fecha:</label>
|
||||
</div>
|
||||
<div class="col-md-2" runat="server" style="text-align: left;">
|
||||
|
||||
@@ -172,16 +179,22 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-1" runat="server" id="divTipoPago1">
|
||||
<label style="width: 70px;">Forma:</label>
|
||||
<label style="width: 100px;">Forma de Pago:</label>
|
||||
</div>
|
||||
<div class="col-md-1" runat="server" id="divTipoPago" >
|
||||
<asp:DropDownList ID="DdlTipoDeposito" runat="server" Width="75px" AppendDataBoundItems="true" DataTextField="NumCuentaMoneda" AutoPostBack="true" DataValueField="CveCuenta" OnSelectedIndexChanged="DdlTipoPago_SelectedIndexChanged" Class="table-group-action-input form-control input-inline input-small input-sm select2me">
|
||||
<asp:ListItem Value="13" Text="Efectivo" Selected="True"></asp:ListItem>
|
||||
<asp:DropDownList ID="DdlTipoDeposito" runat="server" Width="100%" AppendDataBoundItems="true" DataTextField="NumCuentaMoneda" AutoPostBack="true" DataValueField="CveCuenta" OnSelectedIndexChanged="DdlTipoPago_SelectedIndexChanged" Class="table-group-action-input form-control input-inline input-small input-sm select2me" >
|
||||
<asp:ListItem Value="-1" Text="Seleccione" Selected="True"></asp:ListItem>
|
||||
<asp:ListItem Value="13" Text="Efectivo"></asp:ListItem>
|
||||
<asp:ListItem Value="3" Text="Cheque"></asp:ListItem>
|
||||
<asp:ListItem Value="11" Text="Tarjeta de Débito"></asp:ListItem>
|
||||
<asp:ListItem Value="12" Text="Tarjeta de Crédito"></asp:ListItem>
|
||||
<asp:ListItem Value="8" Text="Transferencia"></asp:ListItem>
|
||||
</asp:DropDownList>
|
||||
<asp:RequiredFieldValidator ID="RfvDdlTipoDeposito" runat="server" ControlToValidate="DdlTipoDeposito" InitialValue="-1" CssClass="help-block errorimput" Display="None"
|
||||
ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Forma de Pgo''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="Valida">
|
||||
</asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VCRfvDdlTipoDeposito" runat="server" HighlightCssClass="vco" TargetControlID="RfvDdlTipoDeposito" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
|
||||
</div>
|
||||
<div class="col-md-1" runat="server" id="divFolio" visible="false">
|
||||
<div class="row">
|
||||
|
||||
@@ -38,6 +38,9 @@ Partial Class Bancos_DepositosCaja
|
||||
BtnConsultar.Attributes.Add("onclick", "Consultar(this);")
|
||||
BtnDepositar.Attributes.Add("onclick", "Depositar(this);")
|
||||
|
||||
Dim StrEncriptPrueba As String = Encripta($"OP=DC&CveIE={2784391}&CuentaCaja={"TestCuantaCaja"}&CuentaDepo={"Test cuenta"}")
|
||||
HplImprimirPDF.NavigateUrl = $"/Compras/PopUpVerFactura.aspx?P={StrEncriptPrueba}"
|
||||
|
||||
End If
|
||||
End Sub
|
||||
|
||||
@@ -350,9 +353,9 @@ Partial Class Bancos_DepositosCaja
|
||||
If Not OcurrioError AndAlso ChkCuentaRetorno.Checked Then
|
||||
CveTransaccionBanco = 13
|
||||
FolioIE = ObjBancos.GetNextFolio(DdlCajaChica.SelectedValue.ToEntero, CveTransaccionBanco)
|
||||
CveIEOrigen = ObjBancos.AddBancos_IE(DdlCajaChica.SelectedValue.ToEntero, CveTransaccionBanco, Fecha, FolioIE.ToString, "Retorno Depósito Bancario", CuentaRetorno, CveMoneda, 1, TxtObservaciones.Text, "", False, False, -1, NuevaCvePrePoliza, "-1", UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa)
|
||||
Dim CveIEOrigenRetorno As Integer = ObjBancos.AddBancos_IE(DdlCajaChica.SelectedValue.ToEntero, CveTransaccionBanco, Fecha, FolioIE.ToString, "Retorno Depósito Bancario", CuentaRetorno, CveMoneda, 1, TxtObservaciones.Text, "", False, False, -1, NuevaCvePrePoliza, "-1", UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa)
|
||||
|
||||
If Not ObjConta.AddPrePolizasDetalle(NuevaCvePrePoliza, False, CuentaRetorno, CuentaRetorno * TipoCambio, 30, "", "Retorno", CveClasificacion:=CveClasificacionDescuento, CveSubProyecto:=CveSubProyecto, CveIE:=CveIEOrigen) Then
|
||||
If Not ObjConta.AddPrePolizasDetalle(NuevaCvePrePoliza, False, CuentaRetorno, CuentaRetorno * TipoCambio, 30, "", "Retorno", CveClasificacion:=CveClasificacionDescuento, CveSubProyecto:=CveSubProyecto, CveIE:=CveIEOrigenRetorno) Then
|
||||
OcurrioError = True
|
||||
End If
|
||||
End If
|
||||
@@ -403,6 +406,8 @@ Partial Class Bancos_DepositosCaja
|
||||
|
||||
documentos += String.Format("<a class=""Texto"" target='_blank' href=""/Compras/PopUpVerFactura.aspx?P={0}"">Imprimir {1}</a> <br/> ", StrEncript, "Depósito Bancario")
|
||||
|
||||
|
||||
|
||||
End If
|
||||
|
||||
If Not OcurrioError AndAlso ObjConta.ValidacionesPrePoliza(NuevaCvePrePoliza, UsuarioActual, Opcion:=1) Then
|
||||
|
||||
@@ -747,9 +747,7 @@ Partial Class Bancos_IE
|
||||
RBL.Items.Add(New ListItem("Acreedores Diversos", "AC"))
|
||||
End If
|
||||
|
||||
|
||||
|
||||
If TabCancelacion.Visible Then
|
||||
If TabCancelacion.Visible Or TxtFolio.Text.Contains("_C") Then
|
||||
LnkCancelar.Visible = False
|
||||
End If
|
||||
|
||||
@@ -775,11 +773,7 @@ Partial Class Bancos_IE
|
||||
|
||||
' LnkCancelarComplemento.Visible = False
|
||||
' LnkCancelarComplementoImporte.Visible = False
|
||||
|
||||
|
||||
' UppEliminarIE.Update()
|
||||
|
||||
|
||||
'End If
|
||||
|
||||
DdlMotivoCancelacion.DataSource = GlobalDTMotivosCancelacionEmpresa(UsuarioActual.CveEmpresa).FiltraParametros("CveSATMotivoCancelacion IN (2,3)")
|
||||
|
||||
@@ -1610,7 +1610,9 @@ Partial Class PopUpVerFactura
|
||||
If UsuarioActual.Empresa.Funcionalidad(109) = "1" Then
|
||||
DtMetodosPago = DtCortesVentasResumen.FiltraParametros("MetodoPago <> 'Crédito'")
|
||||
End If
|
||||
|
||||
Dim DirFormato As String = "Empresas/Grales/Formatos/RepCortes.rdlc"
|
||||
|
||||
If File.Exists(UsuarioActual.Empresa.Ruta + "\Formatos\RepCortes.rdlc") Then
|
||||
DirFormato = UsuarioActual.Empresa.Ruta + "\Formatos\RepCortes.rdlc"
|
||||
End If
|
||||
@@ -5380,6 +5382,15 @@ Partial Class PopUpVerFactura
|
||||
If ObjIE.GetBancosIEMovimientosDepositos(CveIE, UsuarioActual.CveEmpresa) Then
|
||||
Tabla = ObjIE.DtResultados.Copy()
|
||||
End If
|
||||
|
||||
Dim TipoTransaccion As String = ""
|
||||
Dim Observaciones As String = ""
|
||||
|
||||
If ObjIE.GetBancosIE(CveIE, UsuarioActual.CveEmpresa) Then
|
||||
TipoTransaccion = ObjIE.TipoTransaccion
|
||||
Observaciones = ObjIE.Observaciones
|
||||
End If
|
||||
|
||||
ObjIE.Dispose()
|
||||
|
||||
If Tabla IsNot Nothing AndAlso Tabla.Rows.Count > 0 Then
|
||||
@@ -5390,6 +5401,8 @@ Partial Class PopUpVerFactura
|
||||
params.Add(New ReportParameter("CuentaCaja", CuentaCaja))
|
||||
params.Add(New ReportParameter("CuentaDeposito", CuentaDeposito))
|
||||
params.Add(New ReportParameter("TipoPago", TipoPago))
|
||||
params.Add(New ReportParameter("TipoTransaccion", TipoTransaccion))
|
||||
params.Add(New ReportParameter("Observaciones", Observaciones))
|
||||
|
||||
If Archivo.Exists Then
|
||||
params.Add(New ReportParameter("UsuarioImprimio", UsuarioActual.Nombre))
|
||||
@@ -5760,7 +5773,7 @@ Partial Class PopUpVerFactura
|
||||
dtMovs = ObjIE.DtResultados.FiltraParametros("CveConceptoContable IN (17,2,308,309,312,292 )")
|
||||
|
||||
If dtMovs IsNot Nothing AndAlso dtMovs.Rows.Count > 0 Then
|
||||
CvePrePoliza = dtMovs.Rows(0)("CVePrePoliza").ToString.ToEntero
|
||||
CvePrePoliza = dtMovs.Rows(0)("CvePrePoliza").ToString.ToEntero
|
||||
|
||||
If Not UsuarioActual.CveEmpresa.Contiene(13, 83) Then
|
||||
'CONVIERTO A PESOS CUANDO SE PAGA CON PESOS FACTURAS DE DOLARES
|
||||
@@ -5805,7 +5818,7 @@ Partial Class PopUpVerFactura
|
||||
End With
|
||||
dtMovs.Dispose()
|
||||
|
||||
If UsuarioActual.Empresa.Funcionalidad(574).ToEntero = 1 And CvePrePoliza > 0 Then
|
||||
If (UsuarioActual.Empresa.Funcionalidad(574).ToEntero = 1 Or UsuarioActual.Empresa.Funcionalidad(382).ToEntero = 1) And CvePrePoliza > 0 Then
|
||||
|
||||
Dim ObjContabilidad As New ClsContabilidad
|
||||
|
||||
|
||||
@@ -288,7 +288,7 @@
|
||||
</div>
|
||||
|
||||
<input id="HdnCveCuenta" runat="server" type="hidden" value="-1" clientidmode="Static" />
|
||||
<div style="width: 100%; min-height: 200px; overflow-scrolling: auto;">
|
||||
<div style="width: 100%; min-height: 200px; -webkit-overflow-scrolling: auto;">
|
||||
|
||||
<div class="portlet light xspadding bordered " id="pnldl2" runat="server">
|
||||
<div class="portlet-title">
|
||||
@@ -310,6 +310,7 @@
|
||||
<a href="javascript:;" onclick="FiltrarTablaV2('.TxtBusqueda','.GvMov')" style="margin-top: -3px;" class="btn btn-circle btn-sm font-bold green"><i class="icon-magnifier" style="font-weight: bold;"></i></a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="portlet-body nomarginleftright form-horizontal form-row-sepe formnombottom ">
|
||||
<asp:GridView ID="GvMov" runat="server" AutoGenerateColumns="False" ShowHeader="True"
|
||||
DataKeyNames="IdMov,Cargo,Abono,TipoMovto,CveConceptoContable,CveProveedor,CvePersonal, CveCompra,CveClasificacion,CveCliente,CveVenta,CveCuenta, ContadoTipoTransaccion, ContadoCuenta, ContadoNumeroFolio, ContadoImporte, ContadoBeneficiario, ContadoObservaciones,EsComplementaria, EsMonedaExtranjera,ImporteME, PorcentajeImpuesto, TC"
|
||||
@@ -333,6 +334,7 @@
|
||||
<asp:TemplateField>
|
||||
<HeaderTemplate>Concepto</HeaderTemplate>
|
||||
<ItemTemplate>
|
||||
<%--<asp:Literal ID="LrlConcepto" runat="server" Text='<%# Eval("Concepto")%>'></asp:Literal>--%>
|
||||
<asp:TextBox ID="TxtConcepto" runat="server" Text='<%# Eval("Concepto")%>' Width="100%"></asp:TextBox>
|
||||
</ItemTemplate>
|
||||
<ItemStyle />
|
||||
|
||||
@@ -1,4 +1,7 @@
|
||||
Imports System.Data
|
||||
Imports System.Runtime.CompilerServices
|
||||
Imports System.Runtime.Remoting
|
||||
|
||||
'Imports DocumentFormat.OpenXml
|
||||
Imports Extensiones
|
||||
Imports GemBox.Spreadsheet
|
||||
@@ -409,6 +412,7 @@ Partial Class ContabilidadC_RegPrePolizaS
|
||||
.Add("EsMonedaExtranjera", Type.GetType("System.Boolean"))
|
||||
.Add("TC", Type.GetType("System.Decimal"))
|
||||
.Add("CvePrePoliza", Type.GetType("System.Int32"))
|
||||
.Add("CveMovimientoAlmacen", Type.GetType("System.Int32"))
|
||||
|
||||
End With
|
||||
|
||||
@@ -429,6 +433,7 @@ Partial Class ContabilidadC_RegPrePolizaS
|
||||
DtMovimientosEliminar.AcceptChanges()
|
||||
End Sub
|
||||
Private Function CargaPrePoliza(tCvePrePoliza As Integer) As Boolean
|
||||
HplImprimirPDF.Visible = False
|
||||
Dim retorno As Boolean = False
|
||||
Dim ObjContabilidad As New ClsContabilidad
|
||||
If ObjContabilidad.GetPrePoliza(tCvePrePoliza, UsuarioActual.CveEmpresa) Then
|
||||
@@ -453,8 +458,7 @@ Partial Class ContabilidadC_RegPrePolizaS
|
||||
TxtFechaelaboracion.ToolTip = dr("FechaIng").ToString.ToDate.ToString("HH:mm:ss")
|
||||
CvePlantillaPoliza = dr("CvePlantillaPoliza").ToString.ToEntero
|
||||
DdlPlantilla.SelectedValueExist(CvePlantillaPoliza)
|
||||
HplImprimirPDF.NavigateUrl = $"/Compras/PopUpVerFactura.aspx?P={Encripta($"OP=PREPO&CvePrePoliza={CvePrePoliza}")}"
|
||||
HplImprimirPDF.Visible = True
|
||||
|
||||
If UsuarioActual.CveRol = 1 Then TxtUsuarioElaboro.ToolTip = dr("Modulo").ToString
|
||||
|
||||
If UsuarioActual.CveRol = 1 OrElse UsuarioActual.TienePermisoProceso(221) Then
|
||||
@@ -528,6 +532,23 @@ Partial Class ContabilidadC_RegPrePolizaS
|
||||
RegistraScript("comparar();")
|
||||
|
||||
LnkExcel.Visible = False
|
||||
|
||||
Dim CveIE As Integer = DtMovimientos.FiltroPrimeroValor("CveIE", " CveIE > 0 ").ToEntero
|
||||
|
||||
If UsuarioActual.Empresa.Funcionalidad(382).ToEntero = 1 AndAlso CveIE > 0 Then
|
||||
|
||||
Dim StrEncript As String = Encripta($"OP=ImprimeMov&CveIE={CveIE}")
|
||||
'HplListaProveedores.NavigateUrl = String.Format($"/Compras/PopUpVerFactura.aspx?P={StrEncript}", )
|
||||
|
||||
HplImprimirPDF.NavigateUrl = $"/Compras/PopUpVerFactura.aspx?P={StrEncript}"
|
||||
HplImprimirPDF.Visible = True
|
||||
Else
|
||||
HplImprimirPDF.NavigateUrl = $"/Compras/PopUpVerFactura.aspx?P={Encripta($"OP=PREPO&CvePrePoliza={CvePrePoliza}")}"
|
||||
HplImprimirPDF.Visible = True
|
||||
End If
|
||||
|
||||
|
||||
|
||||
Else
|
||||
Alert("El documento solicitado no existe, favor de revisar su búsqueda.", TipoMensaje.MsgAdvertencia)
|
||||
BtnEliminar.Visible = False
|
||||
@@ -792,7 +813,7 @@ Partial Class ContabilidadC_RegPrePolizaS
|
||||
|
||||
GvMov.DataSource = DtMovimientos
|
||||
GvMov.DataBind()
|
||||
GvPrePoliza.DataBind() ''limpio el grid
|
||||
GvPrePoliza.DataBind()
|
||||
UpPrePoliza.Update()
|
||||
UPMovs.Update()
|
||||
|
||||
@@ -813,7 +834,7 @@ Partial Class ContabilidadC_RegPrePolizaS
|
||||
|
||||
e.Row.FCTextBox("TxtAbono").Text = If(e.Row.DBCampo("Abono") = "0", "", e.Row.DBCampo("Abono"))
|
||||
e.Row.FCTextBox("TxtCargo").Text = If(e.Row.DBCampo("Cargo") = "0", "", e.Row.DBCampo("Cargo"))
|
||||
e.Row.FCTextBox("TxtConcepto").Text = e.Row.DBCampo("Descripcion")
|
||||
e.Row.FCTextBox("TxtConcepto").Text = e.Row.DBCampo("Concepto")
|
||||
|
||||
If CvePeriodo > 0 Then
|
||||
e.Row.FCTextBox("TxtCargo").Enabled = False
|
||||
@@ -835,7 +856,8 @@ Partial Class ContabilidadC_RegPrePolizaS
|
||||
e.Row.FCDropDownList("DdlSubProyecto").Enabled = True
|
||||
e.Row.FCLinkButton("imgD").Visible = True
|
||||
Else
|
||||
e.Row.FCDropDownList("DdlSubProyecto").Enabled = False
|
||||
'
|
||||
'e.Row.FCDropDownList("DdlSubProyecto").Enabled = False
|
||||
End If
|
||||
|
||||
If e.Row.DBCampo("MultipleSubProyecto") = "True" Then
|
||||
@@ -1667,6 +1689,35 @@ Partial Class ContabilidadC_RegPrePolizaS
|
||||
End If
|
||||
End If
|
||||
|
||||
|
||||
If DdlPlantilla.SelectedValue.ToEntero <> 53 Then
|
||||
|
||||
Dim x As Integer = 0
|
||||
For Each gvRow As GridViewRow In GvMov.Rows
|
||||
|
||||
|
||||
DtMovimientos.Rows(x)("ContadoTipoTransaccion") = gvRow.DataKey("ContadoTipoTransaccion").ToEntero
|
||||
DtMovimientos.Rows(x)("ContadoCuenta") = gvRow.DataKey("ContadoCuenta").ToEntero
|
||||
DtMovimientos.Rows(x)("ContadoNumeroFolio") = gvRow.DataKey("ContadoNumeroFolio")
|
||||
DtMovimientos.Rows(x)("ContadoImporte") = gvRow.DataKey("ContadoImporte").ToDecimal
|
||||
DtMovimientos.Rows(x)("ContadoBeneficiario") = gvRow.DataKey("ContadoBeneficiario")
|
||||
DtMovimientos.Rows(x)("ContadoObservaciones") = gvRow.DataKey("ContadoObservaciones")
|
||||
|
||||
DtMovimientos.Rows(x)("Concepto") = gvRow.FCTextBox("TxtConcepto").Text
|
||||
DtMovimientos.Rows(x)("Cargo") = gvRow.FCTextBox("TxtCargo").Text.ToDecimal
|
||||
DtMovimientos.Rows(x)("Abono") = gvRow.FCTextBox("TxtAbono").Text.ToDecimal
|
||||
DtMovimientos.Rows(x)("TC") = gvRow.FCTextBox("TxtTC").Text.ToDecimal
|
||||
DtMovimientos.Rows(x)("ImporteME") = gvRow.FCTextBox("TxtAbonoME").Text.ToDecimal
|
||||
DtMovimientos.Rows(x)("CveSubProyecto") = gvRow.FCDropDownList("DdlSubProyecto").SelectedValue.ToEntero
|
||||
|
||||
x = x + 1
|
||||
Next
|
||||
DtMovimientos.AcceptChanges()
|
||||
|
||||
|
||||
End If
|
||||
|
||||
|
||||
dr("CveCuenta") = DdlCuentaContableE.SelectedValue
|
||||
dr("CodigoNombreCuenta") = DdlCuentaContableE.SelectedItem.Text
|
||||
dr("ConceptoContable") = DdlConceptosContablesE.SelectedItem.Text
|
||||
@@ -1717,11 +1768,22 @@ Partial Class ContabilidadC_RegPrePolizaS
|
||||
End If
|
||||
|
||||
DtMovimientos.AcceptChanges()
|
||||
GvPrePoliza.EditIndex = -1
|
||||
GvPrePoliza.DataSource = DtMovimientos
|
||||
GvPrePoliza.DataBind()
|
||||
UpPrePoliza.Update()
|
||||
GvPrePoliza.Visible = True
|
||||
|
||||
If DdlPlantilla.SelectedValue.ToEntero <> 53 Then
|
||||
GvMov.DataSource = DtMovimientos
|
||||
GvMov.DataBind()
|
||||
GvPrePoliza.DataBind()
|
||||
UpPrePoliza.Update()
|
||||
UPMovs.Update()
|
||||
Else
|
||||
GvPrePoliza.EditIndex = -1
|
||||
GvPrePoliza.DataSource = DtMovimientos
|
||||
GvPrePoliza.DataBind()
|
||||
UpPrePoliza.Update()
|
||||
GvPrePoliza.Visible = True
|
||||
End If
|
||||
|
||||
|
||||
|
||||
TxtTotalCargos.Text = DtMovimientos.SUMD("Cargo").ToString.FormatoNumero
|
||||
TxtTotalAbonos.Text = DtMovimientos.SUMD("Abono").ToString.FormatoNumero
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user