-
This commit is contained in:
@@ -1052,7 +1052,7 @@ Public Class ClsProductosServicios
|
||||
Return Retorno
|
||||
End Function
|
||||
|
||||
Public Function AddPSAdicionales(CvePS As Integer, CvePSAdicional As Integer, Cantidad As Decimal) As Boolean
|
||||
Public Function AddPSAdicionales(CvePS As Integer, CvePSAdicional As Integer, Cantidad As Decimal, Tipo As Integer) As Boolean
|
||||
Dim Retorno As Boolean = False
|
||||
|
||||
DataAdapter("PA_Gral_ProductosServiciosAdicionalesAdd")
|
||||
@@ -1061,7 +1061,7 @@ Public Class ClsProductosServicios
|
||||
.Add("@CvePS", SqlDbType.Int).Value = CvePS
|
||||
.Add("@CvePSAdicional", SqlDbType.Int).Value = CvePSAdicional
|
||||
.Add("@Cantidad", SqlDbType.Money).Value = Cantidad
|
||||
|
||||
.Add("@Tipo", SqlDbType.TinyInt).Value = Tipo
|
||||
End With
|
||||
|
||||
Try
|
||||
@@ -1081,7 +1081,7 @@ Public Class ClsProductosServicios
|
||||
Return Retorno
|
||||
End Function
|
||||
|
||||
Public Function UpdatePSAdicionales(CvePS As Integer, CvePSAdicional As Integer, CvePSAdicionalAnterior As Integer, Cantidad As Decimal) As Boolean
|
||||
Public Function UpdatePSAdicionales(CvePS As Integer, CvePSAdicional As Integer, CvePSAdicionalAnterior As Integer, Cantidad As Decimal, Tipo As Integer) As Boolean
|
||||
Dim Retorno As Boolean = False
|
||||
|
||||
DataAdapter("PA_Gral_ProductosServiciosAdicionalesUpdate")
|
||||
@@ -1091,7 +1091,7 @@ Public Class ClsProductosServicios
|
||||
.Add("@CvePSAdicional", SqlDbType.Int).Value = CvePSAdicional
|
||||
.Add("@CvePSAdicionalAnterior", SqlDbType.Int).Value = CvePSAdicionalAnterior
|
||||
.Add("@Cantidad", SqlDbType.Money).Value = Cantidad
|
||||
|
||||
.Add("@Tipo", SqlDbType.TinyInt).Value = Tipo
|
||||
End With
|
||||
|
||||
Try
|
||||
|
||||
@@ -17,19 +17,25 @@ Public Class ClsPuntoVenta
|
||||
Private SqlCommand As SqlCommand
|
||||
Private SqlTransacc As SqlTransaction
|
||||
Private Data As DataTable
|
||||
Private Dataset As DataSet
|
||||
|
||||
'Atributos de la clase
|
||||
Private disposedValue As Boolean = False ' Para detectar llamadas redundantes
|
||||
'PARA REGISTRAR CONEXION
|
||||
Private CveConexion As Integer = 0
|
||||
|
||||
Private CveConexion As Integer = 0
|
||||
|
||||
#End Region
|
||||
|
||||
|
||||
#Region "Propiedades"
|
||||
Public ReadOnly Property DtResultados() As DataTable
|
||||
Get
|
||||
DtResultados = Data
|
||||
End Get
|
||||
End Property
|
||||
Public ReadOnly Property DataSetResultados() As DataSet
|
||||
Get
|
||||
DataSetResultados = Dataset
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Public Property CveCorte As Integer
|
||||
@@ -222,6 +228,37 @@ Public Class ClsPuntoVenta
|
||||
Return Retorno
|
||||
End Function
|
||||
|
||||
''' <summary>
|
||||
''' Desglose del reporte de cortes, resumen e IVA
|
||||
''' </summary>
|
||||
''' <param name="CveCorte"></param>
|
||||
''' <param name="CveSubProyecto"></param>
|
||||
''' <param name="CveEmpresa"></param>
|
||||
''' <param name="Opcion"></param>
|
||||
''' <returns></returns>
|
||||
Public Function GetVta_ReporteCortesDetalle(CveCorte As Integer, CveSubProyecto As Integer, CveEmpresa As Integer, Opcion As Integer) As Boolean
|
||||
Dim Retorno As Boolean = False
|
||||
|
||||
DataAdapter("PA_Vta_ReporteCortesDetalleGet")
|
||||
|
||||
With SqlAdapter.SelectCommand.Parameters
|
||||
.Add("@CveCorte", SqlDbType.Int).Value = CveCorte
|
||||
.Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto
|
||||
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
||||
.Add("@Opcion", SqlDbType.Int).Value = Opcion
|
||||
End With
|
||||
|
||||
Try
|
||||
Dataset = New DataSet()
|
||||
SqlAdapter.Fill(Dataset)
|
||||
Retorno = True
|
||||
Catch ex As Exception
|
||||
OnError("Ocurrió un error al obtener los detalle de cortes", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
|
||||
End Try
|
||||
|
||||
Return Retorno
|
||||
End Function
|
||||
|
||||
'Public Function GetCortesPorCuenta(CveCuenta As Integer, CveEmpresa As Integer) As Boolean
|
||||
' Dim Retorno As Boolean = False
|
||||
|
||||
@@ -389,7 +426,8 @@ Public Class ClsPuntoVenta
|
||||
If Not Me.disposedValue Then
|
||||
If disposing Then
|
||||
' TODO: dispose managed state (managed objects).
|
||||
If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
|
||||
If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
|
||||
If Not Dataset Is Nothing Then Dataset.Dispose() : Dataset = Nothing
|
||||
If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
|
||||
If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
|
||||
If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
|
||||
|
||||
@@ -157,6 +157,11 @@ Partial Class Bancos_DepositosCaja
|
||||
|
||||
Private Sub BtnDepositar_Click(sender As Object, e As EventArgs) Handles BtnDepositar.Click
|
||||
|
||||
|
||||
If Not Validaciones() Then
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
Dim TotalImporte As Decimal = 0
|
||||
Dim TotalImportePrePoliza As Decimal
|
||||
Dim Comision As Decimal = TxtComision.Text.ToDecimal
|
||||
@@ -465,8 +470,58 @@ Partial Class Bancos_DepositosCaja
|
||||
lblValorTotalSeleccionado.Text = "0.0"
|
||||
CargaDatos()
|
||||
ObjConta.Dispose()
|
||||
End Sub
|
||||
|
||||
End Sub
|
||||
|
||||
Private Function Validaciones() As Boolean
|
||||
|
||||
Dim Respuesta As Boolean = True
|
||||
|
||||
If Not ValidaCobranza() Then
|
||||
Respuesta = False
|
||||
End If
|
||||
|
||||
Return Respuesta
|
||||
|
||||
End Function
|
||||
|
||||
|
||||
Private Function ValidaCobranza() As Boolean
|
||||
Dim Respuesta As Boolean = False
|
||||
|
||||
If UsuarioActual.CveEmpresa.Contiene(195) Then
|
||||
|
||||
Dim ObjMovtos As New ClsMovimientos()
|
||||
Dim FechaI, FechaF As Date
|
||||
FechaI = If(IsDate(txtFechaI.Text.Trim()), txtFechaI.Text.Trim().ToDate, MinFecha)
|
||||
FechaF = If(IsDate(txtFechaF.Text.Trim()), txtFechaF.Text.Trim().ToDate, MaxFecha).AddDays(1)
|
||||
|
||||
If ObjMovtos.GetRemisionesCobranza(UsuarioActual.CveEmpresa, DdlSubProyectos.SelectedValue.ToEntero, FechaI, FechaF) Then
|
||||
Dim dtt As DataTable = ObjMovtos.DtResultados.FiltraParametros($"CveVenta > 0 AND (CveUsuarioCobranza IS NULL OR CveUsuarioCobranza = {UsuarioActual.CveUsuario}) AND TipoDocto IN ('Ing','Rem')")
|
||||
'Dim Dtta As DataTable = dtt.FiltraParametros($"CveUsuarioCobranza = {UsuarioActual.CveUsuario} ")
|
||||
'If Dtta IsNot Nothing AndAlso Dtta.Rows.Count > 0 Then dtt = Dtta
|
||||
|
||||
If dtt.Rows.Count = 0 Then
|
||||
Respuesta = True
|
||||
Else
|
||||
Respuesta = False
|
||||
Alert("Se detectaron cobros pendientes.", TipoMensaje.MsgAdvertencia)
|
||||
End If
|
||||
|
||||
Else
|
||||
Alert("Error al consultarcobros pendientes.", TipoMensaje.MsgAdvertencia)
|
||||
Respuesta = False
|
||||
End If
|
||||
|
||||
ObjMovtos.Dispose()
|
||||
|
||||
Else
|
||||
Respuesta = True
|
||||
End If
|
||||
|
||||
Return Respuesta
|
||||
End Function
|
||||
|
||||
|
||||
Private Sub ObtenerTotalImporta()
|
||||
|
||||
Dim Total As Double = 0
|
||||
|
||||
@@ -110,7 +110,7 @@ Partial Class Bancos_RepCortes
|
||||
e.Row.CssClass = "SubTotales2"
|
||||
If DtCortes IsNot Nothing Then
|
||||
e.Row.FCLiteral("LtlImporteInicial").Text = DtCortes.SUMD("ImporteInicial").FormatoNumero(2)
|
||||
End If
|
||||
End If
|
||||
Else
|
||||
If UsuarioActual.CveRol = 1 Then
|
||||
If e.Row.DBCampo("VentasCorte").ToDecimal.RoundSQL <> e.Row.DBCampo("VentaTotalIngreso").ToDecimal + e.Row.DBCampo("VentaTotalRemision").ToDecimal.RoundSQL Then
|
||||
@@ -192,39 +192,62 @@ Partial Class Bancos_RepCortes
|
||||
CveCorte = gvr.DataKey("CveCorte").ToString.ToEntero
|
||||
Dim Finalizado As Integer = gvr.DataKey("Finalizado").ToString.ToEntero
|
||||
Fecha = gvr.DataKey("FechaInicial").ToString
|
||||
Nombre = gvr.DataKey("Nombre").ToString
|
||||
Nombre = gvr.DataKey("Nombre").ToString
|
||||
|
||||
Dim ObjVentas As New ClsVentas
|
||||
'If ObjPuntoVenta.GetCortesDetalleVentas(CveCorte, DdlSubProyectos.SelectedValue.ToEntero, UsuarioActual.CveEmpresa, 2) Then
|
||||
' DtCortesVentas = ObjPuntoVenta.DtResultados.Copy()
|
||||
' GvD.DataSource = DtCortesVentas
|
||||
|
||||
' divDetalle.Visible = True
|
||||
'End If
|
||||
|
||||
'If ObjVentas.GetCortesDetalleVentasResumen(CveCorte, DdlSubProyectos.SelectedValue.ToEntero, UsuarioActual.CveEmpresa) Then
|
||||
' GvP.DataSource = ObjVentas.DtResultados
|
||||
' DtCortesVentasResumen = ObjVentas.DtResultados
|
||||
'End If
|
||||
|
||||
'If UsuarioActual.CveEmpresa.Contiene(190, 192) Then
|
||||
' DivIVA.Visible = True
|
||||
' If ObjVentas.GetCortesDetalleVentasResumenIVA(CveCorte, DdlSubProyectos.SelectedValue.ToEntero, UsuarioActual.CveEmpresa) Then
|
||||
' GvPorIVA.DataSource = ObjVentas.DtResultados
|
||||
' End If
|
||||
'End If
|
||||
|
||||
Dim ObjPuntoVenta As New ClsPuntoVenta
|
||||
If ObjPuntoVenta.GetVta_ReporteCortesDetalle(CveCorte, DdlSubProyectos.SelectedValue.ToEntero, UsuarioActual.CveEmpresa, 2) Then
|
||||
Dim DsDatos = ObjPuntoVenta.DataSetResultados.Copy()
|
||||
If DsDatos IsNot Nothing Then
|
||||
'DESGLOSE
|
||||
DtCortesVentas = DsDatos.Tables(0)
|
||||
GvD.DataSource = DtCortesVentas
|
||||
|
||||
If ObjVentas.GetCortesDetalleVentasResumen(CveCorte, DdlSubProyectos.SelectedValue.ToEntero, UsuarioActual.CveEmpresa) Then
|
||||
GvP.DataSource = ObjVentas.DtResultados
|
||||
DtCortesVentasResumen = ObjVentas.DtResultados
|
||||
End If
|
||||
divDetalle.Visible = True
|
||||
'RESUMEN
|
||||
DtCortesVentasResumen = DsDatos.Tables(1)
|
||||
GvP.DataSource = DtCortesVentasResumen
|
||||
|
||||
If UsuarioActual.CveEmpresa.Contiene(190, 192) Then
|
||||
DivIVA.Visible = True
|
||||
If ObjVentas.GetCortesDetalleVentasResumenIVA(CveCorte, DdlSubProyectos.SelectedValue.ToEntero, UsuarioActual.CveEmpresa) Then
|
||||
GvPorIVA.DataSource = ObjVentas.DtResultados
|
||||
'RESUMEN - IVA
|
||||
If UsuarioActual.CveEmpresa.Contiene(190, 192) Then
|
||||
DivIVA.Visible = True
|
||||
GvPorIVA.DataSource = DsDatos.Tables(2)
|
||||
End If
|
||||
|
||||
End If
|
||||
End If
|
||||
|
||||
If ObjPuntoVenta.GetVta_MovimientosCajasReporte(CveCorte, -1) Then
|
||||
GvIngresosRetiros.DataSource = ObjPuntoVenta.DtResultados.Copy()
|
||||
End If
|
||||
ObjPuntoVenta.Dispose()
|
||||
|
||||
Dim ObjVentas As New ClsVentas
|
||||
If Not UsuarioActual.CveEmpresa.Contiene(140, 141) AndAlso ObjVentas.GetCortesDetalleDepositosCaja(CveCorte, DdlSubProyectos.SelectedValue.ToEntero, UsuarioActual.CveEmpresa) Then
|
||||
GvDep.DataSource = ObjVentas.DtResultados
|
||||
If ObjVentas.DtResultados.Rows.Count > 0 Then
|
||||
DivDep.Visible = True
|
||||
End If
|
||||
End If
|
||||
|
||||
If ObjVentas.GetCortesDetalleVentas(CveCorte, DdlSubProyectos.SelectedValue.ToEntero, UsuarioActual.CveEmpresa, 2) Then
|
||||
DtCortesVentas = ObjVentas.DtResultados.Copy()
|
||||
GvD.DataSource = DtCortesVentas
|
||||
|
||||
divDetalle.Visible = True
|
||||
End If
|
||||
|
||||
If ObjVentas.GetVta_MovimientosCajasReporte(CveCorte, -1) Then
|
||||
GvIngresosRetiros.DataSource = ObjVentas.DtResultados.Copy()
|
||||
End If
|
||||
ObjVentas.Dispose()
|
||||
|
||||
If (DtCortesVentasResumen IsNot Nothing AndAlso DtCortesVentasResumen.Rows.Count > 0) Or (DtCortesVentas IsNot Nothing AndAlso DtCortesVentas.Rows.Count > 0) Then
|
||||
HplDownPDF.Visible = True
|
||||
@@ -235,22 +258,13 @@ Partial Class Bancos_RepCortes
|
||||
HplDownPDF.Visible = False
|
||||
HplDownEXCEL.Visible = False
|
||||
End If
|
||||
ObjVentas.Dispose()
|
||||
|
||||
|
||||
|
||||
|
||||
GvD.DataBind()
|
||||
GvP.DataBind()
|
||||
GvDep.DataBind()
|
||||
GvPorIVA.DataBind()
|
||||
GvIngresosRetiros.DataBind()
|
||||
|
||||
|
||||
GvD.DataBind()
|
||||
GvP.DataBind()
|
||||
GvDep.DataBind()
|
||||
GvPorIVA.DataBind()
|
||||
|
||||
If UsuarioActual.CveEmpresa.Contiene(189, 193, 195, 196, 197) Then
|
||||
DivAnexo.Visible = True
|
||||
Dim CveCuenta As Integer = 0
|
||||
|
||||
@@ -9780,7 +9780,7 @@ Partial Class Compras_Compras
|
||||
|
||||
|
||||
|
||||
|
||||
Dim TCAnt As Decimal = If(DdlMoneda.SelectedValue = "1", 1, If(CveCompra > 0, LblTC.Text.ToDecimal, TxtTC.Text.ToDecimal))
|
||||
|
||||
|
||||
If UsuarioActual.Empresa.CveEmpresa.Contiene(13, 83) Then
|
||||
@@ -9792,7 +9792,7 @@ Partial Class Compras_Compras
|
||||
e.Row.DBCampo("CveMoneda"),
|
||||
e.Row.DBCampo("TCCompra").ToDouble,
|
||||
DdlMoneda.SelectedValue,
|
||||
IIf(DdlMoneda.SelectedValue = "1", 1, TxtTC.Text),
|
||||
TCAnt,
|
||||
e.Row.FCTextBox("TxtComision").ClientID
|
||||
)) 'SI ES UNA COMPRA NUEVA SE PONE EL TOTAL, SI NO EL SALDO
|
||||
|
||||
@@ -9824,7 +9824,7 @@ Partial Class Compras_Compras
|
||||
e.Row.DBCampo("CveMoneda"),
|
||||
e.Row.DBCampo("TCCompra").ToDouble,
|
||||
DdlMoneda.SelectedValue,
|
||||
IIf(DdlMoneda.SelectedValue = "1", 1, TxtTC.Text)
|
||||
TCAnt
|
||||
)) 'SI ES UNA COMPRA NUEVA SE PONE EL TOTAL, SI NO EL SALDO
|
||||
|
||||
e.Row.FCTextBox("TxtAnticipo").Attributes.Add("onKeyUp", String.Format("FnCambiaAnt({0},this,{1},{2},{3},{4},{5});",
|
||||
|
||||
@@ -1690,7 +1690,7 @@ Partial Class ContabilidadC_RegPrePolizaS
|
||||
End If
|
||||
|
||||
|
||||
If DdlPlantilla.SelectedValue.ToEntero <> 53 Then
|
||||
If DdlPlantilla.SelectedValue.ToEntero <> 53 And Not CvePrePoliza > 0 Then
|
||||
|
||||
Dim x As Integer = 0
|
||||
For Each gvRow As GridViewRow In GvMov.Rows
|
||||
@@ -1769,7 +1769,7 @@ Partial Class ContabilidadC_RegPrePolizaS
|
||||
|
||||
DtMovimientos.AcceptChanges()
|
||||
|
||||
If DdlPlantilla.SelectedValue.ToEntero <> 53 Then
|
||||
If DdlPlantilla.SelectedValue.ToEntero <> 53 And Not CvePrePoliza > 0 Then
|
||||
GvMov.DataSource = DtMovimientos
|
||||
GvMov.DataBind()
|
||||
GvPrePoliza.DataBind()
|
||||
|
||||
@@ -62,7 +62,7 @@ Partial Class RepContratosCalendario
|
||||
Private Sub CargaCronograma(Optional TipoVista As Integer = -1)
|
||||
If DtAvance IsNot Nothing Then
|
||||
|
||||
Dim DtUnidades As DataTable = GlobalDTActivoFijos(UsuarioActual.CveEmpresa).FiltraParametros("Codigo <> '' AND MedidaVehicular IN (2,3)", Orderby:=" SubTipoActivoFijo DESC, CodigoNumeroOrden ASC", DistinctColumns:={"Codigo", "CveActivoFijo"})
|
||||
Dim DtUnidades As DataTable = GlobalDTActivoFijos(UsuarioActual.CveEmpresa).FiltraParametros("Codigo <> '' AND MedidaVehicular IN (2,3)", Orderby:=" TipoActivoFijo ASC, CodigoNumeroOrden ASC", DistinctColumns:={"Codigo", "CveActivoFijo"})
|
||||
|
||||
'For Each Row As DataRow In DtAvance.Rows
|
||||
' If String.IsNullOrEmpty(Row("CodigoAF").ToString()) Then
|
||||
|
||||
@@ -295,7 +295,9 @@ Partial Class Ventas_PVCobranza
|
||||
'SI TIENE SALDO, QUE APLIQUE EL PAGO
|
||||
If e.Row.DBCampo("Saldo").ToDecimal() > 0 Then
|
||||
e.Row.FCLinkButton("BtnPagar").Visible = True
|
||||
e.Row.FCLinkButton("LnkImprimir").Visible = False
|
||||
If Not e.Row.DBCampo("TipoEntrega") = "2" Then
|
||||
e.Row.FCLinkButton("LnkImprimir").Visible = False
|
||||
End If
|
||||
Else
|
||||
e.Row.FCLinkButton("BtnPagar").Visible = False
|
||||
End If
|
||||
|
||||
@@ -80,9 +80,9 @@
|
||||
<li>
|
||||
<asp:LinkButton ID="LnkGenerarEtiqueta" runat="server" data-toggle="tooltip" data-placement="left" title="Generar Etiqueta" Visible="false" OnClick="LnkGenerarEtiqueta_Click" Text="<i class='fa fa-qrcode'></i> Imprimir Etiqueta"></asp:LinkButton>
|
||||
</li>
|
||||
<li>
|
||||
<asp:LinkButton ID="LnkEquivalenciaAdd" runat="server" data-toggle="tooltip" data-placement="left" title="Agregar Equivalencia" OnClick="LnkEquivalenciaAdd_Click" Text="<i class='fa fa-plus'></i> Agregar Equivalencia"></asp:LinkButton>
|
||||
</li>
|
||||
<li>
|
||||
<asp:LinkButton ID="LnkEquivalenciaAdd" runat="server" data-toggle="tooltip" data-placement="left" title="Agregar Equivalencia" OnClick="LnkEquivalenciaAdd_Click" Text="<i class='fa fa-plus'></i> Agregar Equivalencia"></asp:LinkButton>
|
||||
</li>
|
||||
</ContentTemplate>
|
||||
|
||||
</asp:UpdatePanel>
|
||||
@@ -358,7 +358,6 @@
|
||||
</div>
|
||||
<div class="actions">
|
||||
<div class="btn-group">
|
||||
a
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -482,7 +481,7 @@
|
||||
</div>
|
||||
<div class="portlet-body form">
|
||||
|
||||
<asp:GridView ID="GvPSAdicionales" runat="server" AutoGenerateColumns="False" DataKeyNames="CvePS, CvePSAdicional,Cantidad, PS,CodigoPS" EmptyDataText="No se encontraron Productos/Servicios Adicionales" CssClass="table table-striped table-hover Widthall ScrollAD mysmallbtn" GridLines="None">
|
||||
<asp:GridView ID="GvPSAdicionales" runat="server" AutoGenerateColumns="False" DataKeyNames="CvePS, CvePSAdicional,Cantidad, PS,CodigoPS,Tipo" EmptyDataText="No se encontraron Productos/Servicios Adicionales" CssClass="table table-striped table-hover Widthall ScrollAD mysmallbtn" GridLines="None">
|
||||
<Columns>
|
||||
<asp:TemplateField HeaderText="Producto/Servicio">
|
||||
<ItemTemplate>
|
||||
@@ -642,7 +641,7 @@
|
||||
</div>
|
||||
<div class="actions">
|
||||
<div class="btn-group">
|
||||
<asp:LinkButton ID="HyperLink1" CssClass="btn btn-success" data-toggle="modal" data-target="#Modalupfotos" runat="server" Style="cursor: pointer; float: right;height: 25px !important;" ToolTip="Observaciones"><i class="fa fa-upload"></i> Cargar Archivo</asp:LinkButton>
|
||||
<asp:LinkButton ID="HyperLink1" CssClass="btn btn-success" data-toggle="modal" data-target="#Modalupfotos" runat="server" Style="cursor: pointer; float: right; height: 25px !important;" ToolTip="Observaciones"><i class="fa fa-upload"></i> Cargar Archivo</asp:LinkButton>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -823,7 +822,7 @@
|
||||
</asp:DropDownList>
|
||||
<label for="<%= DdlIEPSPorcentaje.ClientID.ToString()%>">IEPS Porcentaje:</label>
|
||||
</div>
|
||||
<div style="display:none;" class="form-group form-md-line-input input-iconright" title="El precio no está determinado por el valor de la lista de precio, este es manual.">
|
||||
<div style="display: none;" class="form-group form-md-line-input input-iconright" title="El precio no está determinado por el valor de la lista de precio, este es manual.">
|
||||
<label>Precio Libre de Lista</label>
|
||||
<asp:CheckBox ID="ChkPrecioLibre" CssClass="make-switchsd" data-size="small" runat="server" Checked="False" />
|
||||
</div>
|
||||
@@ -1256,13 +1255,13 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<label class="col-md-4 truncate">Tipo Materia:</label>
|
||||
<div class="col-md-8">
|
||||
<asp:DropDownList ID="DdlTipoMateria" runat="server" CssStyle="width: 100%;" Width="200px" DataTextField="TipoMateriaClave" DataValueField="CveTipoMateria"
|
||||
CssClass="form-control input-sm select2me">
|
||||
</asp:DropDownList>
|
||||
</div>
|
||||
</div>
|
||||
<label class="col-md-4 truncate">Tipo Materia:</label>
|
||||
<div class="col-md-8">
|
||||
<asp:DropDownList ID="DdlTipoMateria" runat="server" CssStyle="width: 100%;" Width="200px" DataTextField="TipoMateriaClave" DataValueField="CveTipoMateria"
|
||||
CssClass="form-control input-sm select2me">
|
||||
</asp:DropDownList>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<hr />
|
||||
@@ -1421,7 +1420,7 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="row" runat="server" visible="false" id="DVPermisoImportacion">
|
||||
<label class="col-md-4 truncate">Permiso Importación:</label>
|
||||
<div class="col-md-8">
|
||||
@@ -1449,7 +1448,7 @@
|
||||
ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</ContentTemplate>
|
||||
@@ -2091,44 +2090,44 @@
|
||||
</div>
|
||||
|
||||
<div id="divEquivalenciaModal" class="modal ADS fade" role="dialog">
|
||||
<div class="modal-dialog">
|
||||
<asp:UpdatePanel ID="UPPEquiv" class="modal-content rowpadding" tabindex="-1" runat="server" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
|
||||
<span aria-hidden="true">×</span>
|
||||
</button>
|
||||
<h4 class="modal-title" id="H1" runat="server">Equivalencia</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:DropDownList ID="DdlEquivalenciaUM" CssClass="form-control input-sm select2me" runat="server" AppendDataBoundItems="true" CausesValidation="true" DataTextField="UnidadMedida" DataValueField="CveUnidadMedida" Width="206px">
|
||||
</asp:DropDownList>
|
||||
<label for="<%= DdlEquivalenciaUM.ClientID.ToString()%>">Unidad de Medida:</label>
|
||||
<asp:RequiredFieldValidator ID="RequiredFieldValidator4" runat="server" CssClass="help-block errorimput" ControlToValidate="DdlEquivalenciaUM" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Unidad de medida''</b> es necesario, por favor ingréselo." ValidationGroup="GrpAddEquiv"></asp:RequiredFieldValidator>
|
||||
<i></i>
|
||||
</div>
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:TextBox ID="TxtCantidadEquivalencia" runat="server" Width="60" CausesValidation="true" MaxLength="10"></asp:TextBox>
|
||||
<label for="<%= TxtCantidadEquivalencia.ClientID.ToString()%>">Cantidad:</label>
|
||||
<asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" CssClass="help-block errorimput" ControlToValidate="TxtCantidadEquivalencia" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Cantidad''</b> es necesario, por favor ingréselo." ValidationGroup="GrpAddEquiv"></asp:RequiredFieldValidator>
|
||||
<i></i>
|
||||
</div>
|
||||
|
||||
<div class="modal-footer">
|
||||
<asp:UpdatePanel ID="UpdatePanel5" runat="server" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
<asp:LinkButton ID="LnkAgregarEquivalencia" runat="server" CssClass="btn btn-primary" ValidationGroup="GrpAddEquiv" OnClick="LnkAgregarEquivalencia_Click"> Guardar</asp:LinkButton>
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">Cancelar</button>
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
<div class="modal-dialog">
|
||||
<asp:UpdatePanel ID="UPPEquiv" class="modal-content rowpadding" tabindex="-1" runat="server" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
|
||||
<span aria-hidden="true">×</span>
|
||||
</button>
|
||||
<h4 class="modal-title" id="H1" runat="server">Equivalencia</h4>
|
||||
</div>
|
||||
</div>
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
<div class="modal-body">
|
||||
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:DropDownList ID="DdlEquivalenciaUM" CssClass="form-control input-sm select2me" runat="server" AppendDataBoundItems="true" CausesValidation="true" DataTextField="UnidadMedida" DataValueField="CveUnidadMedida" Width="206px">
|
||||
</asp:DropDownList>
|
||||
<label for="<%= DdlEquivalenciaUM.ClientID.ToString()%>">Unidad de Medida:</label>
|
||||
<asp:RequiredFieldValidator ID="RequiredFieldValidator4" runat="server" CssClass="help-block errorimput" ControlToValidate="DdlEquivalenciaUM" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Unidad de medida''</b> es necesario, por favor ingréselo." ValidationGroup="GrpAddEquiv"></asp:RequiredFieldValidator>
|
||||
<i></i>
|
||||
</div>
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:TextBox ID="TxtCantidadEquivalencia" runat="server" Width="60" CausesValidation="true" MaxLength="10"></asp:TextBox>
|
||||
<label for="<%= TxtCantidadEquivalencia.ClientID.ToString()%>">Cantidad:</label>
|
||||
<asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" CssClass="help-block errorimput" ControlToValidate="TxtCantidadEquivalencia" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Cantidad''</b> es necesario, por favor ingréselo." ValidationGroup="GrpAddEquiv"></asp:RequiredFieldValidator>
|
||||
<i></i>
|
||||
</div>
|
||||
|
||||
<div class="modal-footer">
|
||||
<asp:UpdatePanel ID="UpdatePanel5" runat="server" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
<asp:LinkButton ID="LnkAgregarEquivalencia" runat="server" CssClass="btn btn-primary" ValidationGroup="GrpAddEquiv" OnClick="LnkAgregarEquivalencia_Click"> Guardar</asp:LinkButton>
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">Cancelar</button>
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
</div>
|
||||
</div>
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="ModalCodigoBarrasQR" class="modal ADS fade" role="dialog">
|
||||
<div class="modal-dialog">
|
||||
@@ -2334,34 +2333,44 @@
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
|
||||
<span aria-hidden="true">×</span>
|
||||
</button>
|
||||
<h4 class="modal-title" id="myModalLabel">Producto/Servicio Adicional</h4>
|
||||
<h4 class="modal-title">Producto/Servicio Adicional</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<asp:UpdatePanel ID="UpBodyDireccion" UpdateMode="Conditional" runat="server">
|
||||
<ContentTemplate>
|
||||
<div class="form-group form-md-line-input input-iconright" style="width: 170px!important">
|
||||
<asp:DropDownList ID="DdlPSAdicional" Width="50%" runat="server" CssClass="form-control select2me" DataValueField="CvePS" DataTextField="PS"></asp:DropDownList>
|
||||
<asp:RequiredFieldValidator ID="RFVPSAdicional" runat="server" ControlToValidate="DdlPSAdicional" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Producto/Servicio''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpObligatorio"></asp:RequiredFieldValidator>
|
||||
<label for="<%= DdlPSAdicional.ClientID.ToString()%>">Producto/Servicio:</label>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:DropDownList ID="DdlPSAdicional" Width="100%" runat="server" CssClass="form-control select2me" DataValueField="CvePS" DataTextField="PS"></asp:DropDownList>
|
||||
<asp:RequiredFieldValidator ID="RFVPSAdicional" runat="server" ControlToValidate="DdlPSAdicional" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Producto/Servicio''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpObligatorio"></asp:RequiredFieldValidator>
|
||||
<label for="<%= DdlPSAdicional.ClientID.ToString()%>">Producto/Servicio:</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6" id="DivTipoAdicional" runat="server" visible="false">
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<label style="top: 0;margin-bottom: 0; font-size: 13px; color: #888888;opacity: 1;">Tipo:</label>
|
||||
<asp:RadioButtonList ID="RblTipoAdicional" runat="server" RepeatDirection="Horizontal">
|
||||
<asp:ListItem Value="1" Selected="True">Complementario</asp:ListItem>
|
||||
<asp:ListItem Value="2">Similar</asp:ListItem>
|
||||
</asp:RadioButtonList>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<br />
|
||||
<div class="row">
|
||||
<div class="col-md-3">
|
||||
<div class="form-group form-md-line-input input-iconright" style="width: 200px!important;">
|
||||
<asp:UpdatePanel ID="UpdatePanel2" runat="server" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
<label style="width: 570px!important" for="<%= RBLCantidad.ClientID.ToString()%>">Cantidad:</label>
|
||||
<label style="top: 0;margin-bottom: 0; font-size: 13px; color: #888888;opacity: 1;">Cantidad:</label>
|
||||
<asp:RadioButtonList ID="RBLCantidad" runat="server" RepeatDirection="Horizontal" AutoPostBack="True" OnSelectedIndexChanged="RBLCantidad_SelectedIndexChanged1">
|
||||
<asp:ListItem Value="1" Selected="True">Depende del PS</asp:ListItem>
|
||||
<asp:ListItem Value="2">Fijo</asp:ListItem>
|
||||
</asp:RadioButtonList>
|
||||
<br />
|
||||
<br />
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
<div class="col-md-3">
|
||||
<div class="form-group form-md-line-input input-iconright" style="width: 100px!important; margin-top: 15px">
|
||||
<asp:UpdatePanel ID="UpCantidad" runat="server" UpdateMode="Conditional" Visible="false">
|
||||
<ContentTemplate>
|
||||
@@ -2372,6 +2381,7 @@
|
||||
</asp:UpdatePanel>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
@@ -2569,7 +2579,7 @@
|
||||
|
||||
//COMINEZA: ECOMMERCE
|
||||
|
||||
function clickgaleria() {
|
||||
function clickgaleria() {
|
||||
initcarusel();
|
||||
initcarusel2 = function () { };
|
||||
}
|
||||
|
||||
@@ -446,6 +446,11 @@ Partial Class ProductosyServicios
|
||||
CargaPanelLlantas()
|
||||
End If
|
||||
|
||||
If UsuarioActual.Empresa.Funcionalidad(382) = "1" Then
|
||||
DivPSAdicionales.Visible = True
|
||||
DivTipoAdicional.Visible = True
|
||||
End If
|
||||
|
||||
CvePSAdicional = -1
|
||||
|
||||
'Nueva funcionalidad MLopez: 18/11/2022 -- Empresa Citrícola
|
||||
@@ -1986,6 +1991,8 @@ Partial Class ProductosyServicios
|
||||
TxtCantidadPSAdicional.Text = ""
|
||||
UpCantidad.Visible = False
|
||||
RBLCantidad.SelectedValue = "1"
|
||||
RblTipoAdicional.SelectedValue = "1"
|
||||
|
||||
RegistraScript("$('#divAddPSAdicional').modal();")
|
||||
End Sub
|
||||
Private Sub BtnAgregarPSAdicional_Click(sender As Object, e As EventArgs) Handles BtnAgregarPSAdicional.Click
|
||||
@@ -1994,14 +2001,14 @@ Partial Class ProductosyServicios
|
||||
Dim TieneError As Boolean = False
|
||||
|
||||
If CvePSAdicional < 0 Then
|
||||
If Not ObjProductosServicios.AddPSAdicionales(CvePS, DdlPSAdicional.SelectedValue.ToEntero, If(TxtCantidadPSAdicional.Visible, TxtCantidadPSAdicional.Text.ToDecimal, 0)) Then
|
||||
If Not ObjProductosServicios.AddPSAdicionales(CvePS, DdlPSAdicional.SelectedValue.ToEntero, If(TxtCantidadPSAdicional.Visible, TxtCantidadPSAdicional.Text.ToDecimal, 0), Tipo:=RblTipoAdicional.SelectedValue.ToEntero()) Then
|
||||
TieneError = True
|
||||
Else
|
||||
TieneError = GuardarProductosEquivalenteEnFranquicia(ObjProductosServicios, True)
|
||||
End If
|
||||
Else
|
||||
|
||||
If Not ObjProductosServicios.UpdatePSAdicionales(CvePS, DdlPSAdicional.SelectedValue.ToEntero, CvePSAdicional, If(TxtCantidadPSAdicional.Visible, TxtCantidadPSAdicional.Text.ToDecimal, 0)) Then
|
||||
If Not ObjProductosServicios.UpdatePSAdicionales(CvePS, DdlPSAdicional.SelectedValue.ToEntero, CvePSAdicional, If(TxtCantidadPSAdicional.Visible, TxtCantidadPSAdicional.Text.ToDecimal, 0), Tipo:=RblTipoAdicional.SelectedValue.ToEntero()) Then
|
||||
TieneError = True
|
||||
Else
|
||||
TieneError = GuardarProductosEquivalenteEnFranquicia(ObjProductosServicios, False, PSAdicionalAnterior)
|
||||
@@ -2028,6 +2035,7 @@ Partial Class ProductosyServicios
|
||||
BtnAgregarPSAdicional.Text = "Guardar"
|
||||
TxtCantidadPSAdicional.Text = GvRow.DataKey("Cantidad")
|
||||
PSAdicionalAnterior = GvRow.DataKey("PS").ToString
|
||||
RblTipoAdicional.SelectedValue = GvRow.DataKey("Tipo").ToString
|
||||
|
||||
If TxtCantidadPSAdicional.Text.ToEntero = 0 Then
|
||||
UpCantidad.Visible = False
|
||||
@@ -3264,7 +3272,7 @@ Partial Class ProductosyServicios
|
||||
End If
|
||||
|
||||
If Agregar Then
|
||||
If Not ObjPS.AddPSAdicionales(CvePSPagina, CvePSAdicional, If(TxtCantidadPSAdicional.Visible, TxtCantidadPSAdicional.Text.ToDecimal, 0)) Then
|
||||
If Not ObjPS.AddPSAdicionales(CvePSPagina, CvePSAdicional, If(TxtCantidadPSAdicional.Visible, TxtCantidadPSAdicional.Text.ToDecimal, 0), Tipo:=RblTipoAdicional.SelectedValue.ToEntero()) Then
|
||||
Return True
|
||||
End If
|
||||
Else
|
||||
@@ -3273,7 +3281,7 @@ Partial Class ProductosyServicios
|
||||
If CvepsAdicionalAnt <= 0 Then
|
||||
Alert(String.Format("El producto adicional no existe en la franquicia: '{0}'", GlobalDTEmpresas(Franquicia).FiltroPrimeroValor("Empresa")), TipoMensaje.MsgAdvertencia)
|
||||
Else
|
||||
If Not ObjPS.UpdatePSAdicionales(CvePSPagina, CvePSAdicional, CvepsAdicionalAnt, If(TxtCantidadPSAdicional.Visible, TxtCantidadPSAdicional.Text.ToDecimal, 0)) Then
|
||||
If Not ObjPS.UpdatePSAdicionales(CvePSPagina, CvePSAdicional, CvepsAdicionalAnt, If(TxtCantidadPSAdicional.Visible, TxtCantidadPSAdicional.Text.ToDecimal, 0), Tipo:=RblTipoAdicional.SelectedValue.ToEntero()) Then
|
||||
Return True
|
||||
End If
|
||||
End If
|
||||
|
||||
Reference in New Issue
Block a user