This commit is contained in:
2022-02-05 12:07:52 -07:00
34 changed files with 302 additions and 181 deletions

View File

@@ -133,7 +133,7 @@
</asp:TemplateField>
<asp:TemplateField ItemStyle-HorizontalAlign="Center" ItemStyle-Width="5%" HeaderText="Eliminar">
<ItemTemplate>
<asp:LinkButton ID="LnkEliminar" OnClick="LnkEliminar_Click" runat="server" CssClass="btn btn-circle btn-sm red" Text="<i class='icon-trash'></i>" data-toggle="confirmation" data-popout="true" data-original-title="¿Está seguro que desea eliminar el limite?" data-btn-ok-label="si" />
<asp:LinkButton ID="LnkEliminar" OnClick="LnkEliminar_Click" Visible='<%# Eval("CveEstatus").ToString = "0" OrElse Eval("CveEstatus").ToString = "1" %>' runat="server" CssClass="btn btn-circle btn-sm red" Text="<i class='icon-trash'></i>" data-toggle="confirmation" data-popout="true" data-original-title="¿Está seguro que desea eliminar el limite?" data-btn-ok-label="si" />
</ItemTemplate>
</asp:TemplateField>
</Columns>

View File

@@ -623,11 +623,9 @@ Partial Class Ventas_ClientesAbonar
If RblTipoPago.SelectedValue = "1" Then
Dim ValFechaDocumento As Boolean = False
Dim FoliosFechasValFechaDocumento As New StringBuilder
FoliosFechasValFechaDocumento.AppendLine("Se seleccionaron facturas con fecha de mes superior al mes del pago: <br/>")
Dim FoliosFechasValFechaDocumento As New StringBuilder
FoliosFechasValFechaDocumento.AppendLine("Se seleccionaron facturas con fecha de mes superior al mes del pago: <br/>")
For Each gvRowVal As GridViewRow In GvCxC.Rows
@@ -813,26 +811,12 @@ Partial Class Ventas_ClientesAbonar
Dim UltimaFluctuacion As MTipoCambioFluctuacion = GlobalTipoCambioUltimaFluctuacion(tFecha)
If UsuarioActual.Empresa.Funcionalidad(703) = "1" AndAlso UltimaFluctuacion IsNot Nothing Then
If UltimaFluctuacion.FechaFluctuacion < tFecha Then
If UltimaFluctuacion.FechaFluctuacion <= tFecha Then
FechaUltimaFluctuacion = UltimaFluctuacion.FechaFluctuacion
TipoCambioFluctuacion = UltimaFluctuacion.TCFluctuacion
End If
End If
'If ObjIE.GetFluctuacionesBitacora(UsuarioActual.CveEmpresa) Then
' If ObjIE.DtResultados.Rows.Count > 0 Then
' Dim tFecha As Date = TxtFechaDocumento.Text.ToDate
' Dim Fecha As String = String.Format("{0}/{1}/{2}", tFecha.Year, tFecha.Month, tFecha.Day)
' Dim drr As DataRow = ObjIE.DtResultados.FiltroPrimero("Fecha < #" & Fecha & "#", "Fecha DESC")
' If drr IsNot Nothing Then
' FechaUltimaFluctuacion = drr("Fecha").ToString.ToDate
' TipoCambioFluctuacion = drr("TipoCambio").ToString.ToDecimal
' End If
' End If
'End If
If ObjMov.GetPlantillaConceptos(UsuarioActual.CveEmpresa, CvePlantillaPoliza) Then
dtConceptos = ObjMov.DtResultados
End If
@@ -2586,7 +2570,7 @@ Partial Class Ventas_ClientesAbonar
Dim UltimaFluctuacion As MTipoCambioFluctuacion = GlobalTipoCambioUltimaFluctuacion(tFecha)
If UsuarioActual.Empresa.Funcionalidad(703) = "1" AndAlso UltimaFluctuacion IsNot Nothing Then
If UltimaFluctuacion.FechaFluctuacion < tFecha Then
If UltimaFluctuacion.FechaFluctuacion <= tFecha Then
FechaUltimaFluctuacion = UltimaFluctuacion.FechaFluctuacion
TipoCambioFluctuacion = UltimaFluctuacion.TCFluctuacion
End If

View File

@@ -1249,15 +1249,16 @@ Partial Class ProductosyServicios
End Sub
Protected Sub BtnGuardar_Click(sender As Object, e As System.EventArgs) Handles BtnGuardar.Click
If DdlSATPS.txtValue.Value.ToEntero > 0 Then
ValidaMaterialPeligroso(DdlSATPS.txtValue.Value.ToEntero)
If Not ValidaMaterialPeligrosoMensaje Then
If UsuarioActual.Empresa.Funcionalidad(161) = "1" Then ' si tiene activada la carta porte
Exit Sub
ValidaMaterialPeligroso(DdlSATPS.txtValue.Value.ToEntero)
If Not ValidaMaterialPeligrosoMensaje Then
Exit Sub
End If
End If
End If
End If
If DdlSATPS.SelectedValue.Contiene("46920", "0", "-1") AndAlso UsuarioActual.CveEmpresa.Contiene(119, 158, 72, 80, 145) Then
Alert("El Producto Servicio SAT con clave '01010101' no es valido, por favor seleccione otro", TipoMensaje.MsgAdvertencia)
@@ -1283,10 +1284,6 @@ Partial Class ProductosyServicios
Exit Sub
End If
End If
'If DdlSubFamilia.SelectedValue = "-1" AndAlso UsuarioActual.TienePermisoProceso(138) Then
' Alert("Se debe especificar Familia y Subfamilia de Costos. Por favor rectifique y vuelva a intentar.", TipoMensaje.MsgAdvertencia)
' Exit Sub
'End If
If UsuarioActual.Empresa.Funcionalidad(265) = "1" And TxtCodigo.Text = "" Then
Alert("El código es requerido.", TipoMensaje.MsgAdvertencia)
@@ -1303,7 +1300,6 @@ Partial Class ProductosyServicios
Alert("La cantidad de venta mínima debe de ser especificada (mayor a cero)", TipoMensaje.MsgAdvertencia)
Return
End If
End If
Dim CveTamaño As Integer = DdlTamanio.SelectedValue.ToEntero
@@ -1329,7 +1325,6 @@ Partial Class ProductosyServicios
Alert($"Un producto/servicio con la clasificación '{Dr("Clasificacion")}' debe tener especificado un tamaño.", TipoMensaje.MsgAdvertencia)
Return
End If
End If
Dim ObjProductosServicios As New ClsProductosServicios()
@@ -3111,8 +3106,6 @@ Partial Class ProductosyServicios
Dim DTDatos As New DataTable
DTDatos = ObjGrales.DtResultados.FiltraParametros($" CveSATPS= {CveSATPS}")
'Es material Peligros
If DTDatos.Rows(0)("EsPeligroso").ToString.ToEntero = 1 Then

View File

@@ -215,7 +215,7 @@
<asp:DropDownList ID="DdlVendedor" runat="server" AppendDataBoundItems="true" DataTextField="Vendedor" DataValueField="CveVendedor" Class="table-group-action-input form-control input-inline input-small input-sm select2me" Style="width: 100%">
<asp:ListItem Selected="True" Text="Todos" Value="-1"></asp:ListItem>
</asp:DropDownList>
</div>
</div>
</div>
<div class="row">
<label class="col-md-1 ">Estatus:</label>
@@ -289,6 +289,14 @@
<label title="Clasificación Cliente" data-toggle="tooltip" data-placement="top" class="col-md-1 ">Clasif. Cli.:</label>
<div class="col-md-2">
<asp:DropDownList ID="DdlClienteClasificacion" AutoPostBack="true" OnSelectedIndexChanged="DdlClienteClasificacion_SelectedIndexChanged" runat="server" AppendDataBoundItems="true" CssClass="table-group-action-input form-control input-inline input-small input-sm select2me" DataTextField="ClienteClasificacion" DataValueField="CveClienteClasificacion"></asp:DropDownList>
</div>
<label title="Tipo Cliente" data-toggle="tooltip" data-placement="top" class="col-md-1 ">Tipo Cliente:</label>
<div class="col-md-2">
<asp:DropDownList ID="DdlTipoCliente" runat="server" AppendDataBoundItems="true" Class="table-group-action-input form-control input-inline input-small input-sm select2me">
<asp:ListItem Selected="True" Text="Todos" Value="-1"></asp:ListItem>
<asp:ListItem Text="Frecuente" Value="1"></asp:ListItem>
<asp:ListItem Text="Venta Mostrador" Value="2"></asp:ListItem>
</asp:DropDownList>
</div>
<label title="Proveedor" data-toggle="tooltip" data-placement="top" class="col-md-1 ">Proveedor:</label>
<div class="col-md-2">
@@ -298,27 +306,21 @@
<div runat="server" id="DivMarca" class="col-md-2" visible="false">
<asp:DropDownList ID="DdlMarcaPSDes" CssClass="select2me" runat="server" DataTextField="Marca" DataValueField="CveMarca" Style="width: 100%" Height="22px"></asp:DropDownList>
</div>
<label runat="server" id="LblLitraje" title="Mostrar Litraje" data-toggle="tooltip" data-placement="top" class="col-md-1" visible="false">Litraje:</label>
<div runat="server" id="DvLitraje" class="col-md-2" visible="false">
<asp:CheckBox runat="server" ID="ChkLitraje" CssClass="mkcheck" />
</div>
</div>
<div class="row">
<label title="Tipo Cliente" data-toggle="tooltip" data-placement="top" class="col-md-1 ">Tipo Cliente:</label>
<label title="Condiciones de Pago" data-toggle="tooltip" class="col-md-1 truncate">Condiciones Pago:</label>
<div class="col-md-2">
<asp:DropDownList ID="DdlTipoCliente" runat="server" AppendDataBoundItems="true" Class="table-group-action-input form-control input-inline input-small input-sm select2me">
<asp:DropDownList ID="DdlCondicionesPago" runat="server" AppendDataBoundItems="true" Class="table-group-action-input form-control input-inline input-small input-sm select2me">
<asp:ListItem Selected="True" Text="Todos" Value="-1"></asp:ListItem>
<asp:ListItem Text="Frecuente" Value="1"></asp:ListItem>
<asp:ListItem Text="Venta Mostrador" Value="2"></asp:ListItem>
<asp:ListItem Text="Crédito" Value="1"></asp:ListItem>
<asp:ListItem Text="Contado" Value="0"></asp:ListItem>
</asp:DropDownList>
</div>
<div class="col-md-1 truncate" id="divgarantia1" runat="server" visible="false">
Garantía?:
</div>
@@ -329,11 +331,26 @@
<asp:ListItem Text="No" Value="0"></asp:ListItem>
</asp:Dropdownlist>
</div>
<label class="col-md-1 truncate">Lectura administrativa:</label>
<label title="Distr" data-toggle="tooltip" class="col-md-1 truncate" id="divdistribuidor1" runat="server" visible="false">Distribuidor:</label>
<div class="col-md-2" id="divdistribuidor2" runat="server" visible="false">
<asp:DropDownList ID="DdlDistribuidor" runat="server" AppendDataBoundItems="true" Class="table-group-action-input form-control input-inline input-small input-sm select2me">
<asp:ListItem Selected="True" Text="Todos" Value="-1"></asp:ListItem>
<asp:ListItem Text="Distribuidor" Value="1"></asp:ListItem>
<asp:ListItem Text="No Distribuidor" Value="0"></asp:ListItem>
</asp:DropDownList>
</div>
<div runat="server" id="DvLitraje" class="col-md-1" visible="false">
<asp:CheckBox runat="server" ID="ChkLitraje" CssClass="mkcheck" Text ="Litraje:&nbsp;&nbsp;&nbsp;" TextAlign="Left" />
</div>
</div>
<div class="row">
<label class="col-md-1 truncate">Lectura administrativa:</label>
<div class="col-md-2">
<asp:CheckBox ID="ChkLecturaAdmin" runat="server" Checked="false" CssClass="input-sm" />
</div>
</div>
</div>
</div>

View File

@@ -63,11 +63,12 @@ Partial Class Ventas_RepProductosServicios
SetValues()
If UsuarioActual.Empresa.Funcionalidad(531).ToEntero = 1 Then
LblLitraje.Visible = True
DvLitraje.Visible = True
'garantia
divgarantia1.Visible = True
divgarantia2.Visible = True
divdistribuidor1.Visible = True
divdistribuidor2.Visible = True
End If
End If
@@ -250,9 +251,11 @@ Partial Class Ventas_RepProductosServicios
DdlVendedor.SelectedValueExist(UsuarioActual.CveVendedor.ToString())
DdlVendedor.Attributes.Add("disabled", "disabled")
DdlVendedor.Enabled = False
End If
End If
txtFechaI.Text = Now.FirstDayOfMonth.ToShortDateString
txtFechaF.Text = Now.ToShortDateString
End Sub
#End Region
@@ -284,7 +287,8 @@ Partial Class Ventas_RepProductosServicios
DdlSubProyectoEjecucion.SelectedValue.ToEntero, DdlVendedor.SelectedValue.ToEntero, DdlUsuario.SelectedValue.ToEntero, DdlEstatus.SelectedValue.ToEntero, "-1",
UsuarioActual.CveEmpresa, DdlGrupo.SelectedValue.ToEntero, CveUsuarioConsulta:=UsuarioActual.CveUsuario, TipoDocto:=TipoComprobante,
CveClienteClasificacion:=DdlClienteClasificacion.SelectedValue.ToEntero, TipoCambio:=TipoCambio, TCEspecifico:=TCEspecifico, CveProveedorCompra:=CveProveedorCompra,
CveMarca:=DdlMarcaPSDes.SelectedValue.ToEntero, MostrarLitraje:=ChkLitraje.Checked, TipoCliente:=DdlTipoCliente.SelectedValue.ToEntero, EsGarantia:=DdlGarantia.SelectedValue.ToEntero, ModalidadContable:=ModalidadContable) Then
CveMarca:=DdlMarcaPSDes.SelectedValue.ToEntero, MostrarLitraje:=ChkLitraje.Checked, TipoCliente:=DdlTipoCliente.SelectedValue.ToEntero, EsGarantia:=DdlGarantia.SelectedValue.ToEntero, ModalidadContable:=ModalidadContable,
CveCondicionesPago:=DdlCondicionesPago.SelectedValue.ToEntero, EsDistribuidor:=DdlDistribuidor.SelectedValue.ToEntero) Then
GvDatos.DataSource = ObjVentas.DtResultados
DtVentas = ObjVentas.DtResultados
Else
@@ -364,11 +368,15 @@ Partial Class Ventas_RepProductosServicios
FechaIEjec = If(IsDate(TxtFechaIEjec.Text.Trim()), TxtFechaIEjec.Text.Trim(), "-1")
FechaFEjec = If(IsDate(TxtFechaFEjec.Text.Trim()), TxtFechaFEjec.Text.Trim(), "-1")
Dim Liga = String.Format("/Ventas/RepProductosServiciosDetalle.aspx?CveProyecto={0}&CveSubProyecto={1}&CveCategoria={2}&CveClasificacion={3}&CvePS={4}&CveCliente={5}&CveSubProyectoEjecucion={6}&CveVendedor={7}&CveUsuario={8}&CveEstatus={9}&Anio={10}&Mes={11}&AnioMes={12}&Fecha={13}&AnioEjec={14}&MesEjec={15}&AnioMesEjec={16}&FechaEjec={17}&FechaI={18}&FechaF={19}&FechaEI={20}&FechaEF={21}&TipoDocto={22}&Grupo={23}&CveMoneda={24}&TipoCambio={25}&TCEspecifico={26}&CveClienteClasificacion={27}&CveProveedorCompra={28}&CveMarca={29}&CveClasificacionDetalle={30}&TipoCliente={31}&ModalidadContable={32}",
e.Row.DBCampo("CveProyecto"), e.Row.DBCampo("CveSubProyecto"), e.Row.DBCampo("CveCategoria"), e.Row.DBCampo("CveClasificacion"), e.Row.DBCampo("CvePS"),
e.Row.DBCampo("CveCliente"), e.Row.DBCampo("CveSubProyectoEjecucion"), e.Row.DBCampo("Vendedor"), e.Row.DBCampo("CveUsuario"), e.Row.DBCampo("CveEstatusFactura"),
e.Row.DBCampo("Anio"), e.Row.DBCampo("Mes"), e.Row.DBCampo("AnioMes"), e.Row.DBCampo("Fecha"), e.Row.DBCampo("AnioEjec"), e.Row.DBCampo("MesEjec"), e.Row.DBCampo("AnioMesEjec"), e.Row.DBCampo("FechaEjec"),
FechaI, FechaF, FechaIEjec, FechaFEjec, e.Row.DBCampo("TipoDocto"), e.Row.DBCampo("CveGpo"), e.Row.DBCampo("CveMoneda"), e.Row.DBCampo("TipoCambio"), e.Row.DBCampo("TCEspecifico"), e.Row.DBCampo("CveClienteClasificacion"), e.Row.DBCampo("CveProveedorCompra"), cveMarca, CveClasificacionDetalle, If(DdlGrupo.SelectedValue.ToEntero = 23, e.Row.DBCampo("TipoCliente"), DdlTipoCliente.SelectedValue), If(Not ChkLecturaAdmin.Checked, 1, 0))
Dim Liga = String.Format("/Ventas/RepProductosServiciosDetalle.aspx?CveProyecto={0}&CveSubProyecto={1}&CveCategoria={2}&CveClasificacion={3}&CvePS={4}&CveCliente={5}&CveSubProyectoEjecucion={6}&CveVendedor={7}&CveUsuario={8}&CveEstatus={9}&Anio={10}&Mes={11}&AnioMes={12}&Fecha={13}&AnioEjec={14}&MesEjec={15}&AnioMesEjec={16}&FechaEjec={17}&FechaI={18}&FechaF={19}
&FechaEI={20}&FechaEF={21}&TipoDocto={22}&Grupo={23}&CveMoneda={24}&TipoCambio={25}&TCEspecifico={26}&CveClienteClasificacion={27}&CveProveedorCompra={28}&CveMarca={29}&CveClasificacionDetalle={30}
&TipoCliente={31}&ModalidadContable={32}&EsGarantia={33}&CveCondicionesPago={34}&MostrarLitraje={35}&EsDistribuidor={36}",
e.Row.DBCampo("CveProyecto"), e.Row.DBCampo("CveSubProyecto"), e.Row.DBCampo("CveCategoria"), e.Row.DBCampo("CveClasificacion"), e.Row.DBCampo("CvePS"),
e.Row.DBCampo("CveCliente"), e.Row.DBCampo("CveSubProyectoEjecucion"), e.Row.DBCampo("Vendedor"), e.Row.DBCampo("CveUsuario"), e.Row.DBCampo("CveEstatusFactura"),
e.Row.DBCampo("Anio"), e.Row.DBCampo("Mes"), e.Row.DBCampo("AnioMes"), e.Row.DBCampo("Fecha"), e.Row.DBCampo("AnioEjec"), e.Row.DBCampo("MesEjec"), e.Row.DBCampo("AnioMesEjec"), e.Row.DBCampo("FechaEjec"),
FechaI, FechaF, FechaIEjec, FechaFEjec, e.Row.DBCampo("TipoDocto"), e.Row.DBCampo("CveGpo"), e.Row.DBCampo("CveMoneda"), e.Row.DBCampo("TipoCambio"), e.Row.DBCampo("TCEspecifico"), e.Row.DBCampo("CveClienteClasificacion"), e.Row.DBCampo("CveProveedorCompra"), cveMarca,
CveClasificacionDetalle, If(DdlGrupo.SelectedValue.ToEntero = 23, e.Row.DBCampo("TipoCliente"), DdlTipoCliente.SelectedValue), If(Not ChkLecturaAdmin.Checked, 1, 0),
e.Row.DBCampo("EsGarantia"), e.Row.DBCampo("CveCondicionesPago"), IIf(e.Row.DBCampo("MostrarLitraje") = "True", 1, 0), e.Row.DBCampo("EsDistribuidor"))
e.Row.FCLiteral("LtlGrupo").Text = String.Format("<a target=""_blank"" Class=""{0}"" href=""{1}"">{2}</a>", Css, Liga, e.Row.DBCampo("Gpo"))

View File

@@ -315,10 +315,41 @@
<asp:ListItem Text="Venta Mostrador" Value="2"></asp:ListItem>
</asp:DropDownList>
</div>
<label class="col-md-1 truncate">Lectura administrativa:</label>
<label title="Condiciones de Pago" data-toggle="tooltip" class="col-md-1 truncate">Condiciones Pago:</label>
<div class="col-md-2">
<asp:CheckBox ID="ChkLecturaAdmin" runat="server" Checked="false" CssClass="input-sm" />
<asp:DropDownList ID="DdlCondicionesPago" runat="server" AppendDataBoundItems="true" Class="table-group-action-input form-control input-inline input-small input-sm select2me">
<asp:ListItem Selected="True" Text="Todos" Value="-1"></asp:ListItem>
<asp:ListItem Text="Crédito" Value="1"></asp:ListItem>
<asp:ListItem Text="Contado" Value="0"></asp:ListItem>
</asp:DropDownList>
</div>
<div class="col-md-1 truncate" id="divgarantia1" runat="server" visible="false">
Garantía?:
</div>
<div class="col-md-1" id="divgarantia2" runat="server" visible="false">
<asp:Dropdownlist runat="server" ID="DdlGarantia" CssStyle="width: 100%;" CssClass="form-control input-small input-sm select2me" Width="100%">
<asp:ListItem Text="Todos" Value="-1" Selected="True"></asp:ListItem>
<asp:ListItem Text="Si" Value="1"></asp:ListItem>
<asp:ListItem Text="No" Value="0"></asp:ListItem>
</asp:Dropdownlist>
</div>
<label title="Distr" data-toggle="tooltip" class="col-md-1 truncate" id="divdistribuidor1" runat="server" visible="false">Distribuidor:</label>
<div class="col-md-2" id="divdistribuidor2" runat="server" visible="false">
<asp:DropDownList ID="DdlDistribuidor" runat="server" AppendDataBoundItems="true" Class="table-group-action-input form-control input-inline input-small input-sm select2me">
<asp:ListItem Selected="True" Text="Todos" Value="-1"></asp:ListItem>
<asp:ListItem Text="Distribuidor" Value="1"></asp:ListItem>
<asp:ListItem Text="No Distribuidor" Value="0"></asp:ListItem>
</asp:DropDownList>
</div>
<div runat="server" id="DvLitraje" class="col-md-1" visible="false">
<asp:CheckBox runat="server" ID="ChkLitraje" CssClass="mkcheck" Text ="Litraje:&nbsp;&nbsp;&nbsp;" TextAlign="Left" />
</div>
</div>
<div class="row">
<div class="col-md-2">
<asp:CheckBox ID="ChkLecturaAdmin" runat="server" Checked="false" CssClass="input-sm" Text="Lectura admiva:" TextAlign="Left" />
</div>
</div>
</div>
</div>

View File

@@ -316,6 +316,11 @@ Partial Class Ventas_RepProductosServiciosDetalle
CveMarca = If(Request("CveMarca") IsNot Nothing AndAlso Request("CveMarca").ToEntero() > 0, Request("CveMarca").ToEntero(), -1).ToString.ToEntero
CveClasificacionDetalle = If(Request("CveClasificacionDetalle") IsNot Nothing AndAlso Request("CveClasificacionDetalle").ToEntero() > 0, Request("CveClasificacionDetalle").ToEntero(), -1).ToString.ToEntero
DdlGarantia.SelectedValueExist(If(Request("EsGarantia") IsNot Nothing AndAlso Request("EsGarantia").ToEntero() > 0, Request("EsGarantia").ToEntero(), -1).ToString)
DdlCondicionesPago.SelectedValueExist(If(Request("CveCondicionesPago") IsNot Nothing AndAlso Request("CveCondicionesPago").ToEntero() > 0, Request("CveCondicionesPago").ToEntero(), -1).ToString)
DdlDistribuidor.SelectedValueExist(If(Request("EsDistribuidor") IsNot Nothing AndAlso Request("EsDistribuidor").ToEntero() > 0, Request("EsDistribuidor").ToEntero(), -1).ToString)
ChkLitraje.Checked = Request("MostrarLitraje") IsNot Nothing AndAlso Request("MostrarLitraje").ToEntero() > 0
TipoCliente = If(Request("TipoCliente") IsNot Nothing, Request("TipoCliente").ToString, "-1").ToString.ToEntero
DdlTipoCliente.SelectedValueExist(TipoCliente)
@@ -324,9 +329,11 @@ Partial Class Ventas_RepProductosServiciosDetalle
txtFechaI.Text = Fecha
txtFechaF.Text = Fecha
End If
If FechaI <> "-1" Then
txtFechaI.Text = FechaI
End If
If FechaF <> "-1" Then
txtFechaF.Text = FechaF
End If
@@ -357,7 +364,13 @@ Partial Class Ventas_RepProductosServiciosDetalle
End If
Else
txtFechaI.Text = If(AnioMes <> "-1", String.Format("01/{0}/{1}", AnioMes.Substring(5, 1).PadLeft(2, "0"c), AnioMes.Substring(0, 4)), txtFechaI.Text)
If FechaI = "-1" Then
txtFechaI.Text = If(AnioMes <> "-1", String.Format("01/{0}/{1}", AnioMes.Substring(5, 1).PadLeft(2, "0"c), AnioMes.Substring(0, 4)), txtFechaI.Text)
Else
txtFechaI.Text = FechaI
End If
FechaFtemporal = $"01/{AnioMes.Substring(5, 1).PadLeft(2, "0"c)}/{AnioMes.Substring(0, 4)}"
If FechaF = "-1" Then
@@ -380,6 +393,14 @@ Partial Class Ventas_RepProductosServiciosDetalle
txtFechaI.Text = If(Mes <> "-1", String.Format("01/{0}/0001", Mes), txtFechaI.Text)
If UsuarioActual.Empresa.Funcionalidad(531).ToEntero = 1 Then
DvLitraje.Visible = True
'garantia
divgarantia1.Visible = True
divgarantia2.Visible = True
divdistribuidor1.Visible = True
divdistribuidor2.Visible = True
End If
If FechaEjec <> "-1" Then
TxtFechaIEjec.Text = FechaEjec
@@ -464,7 +485,7 @@ Partial Class Ventas_RepProductosServiciosDetalle
UsuarioActual.CveEmpresa, CveUsuarioConsulta:=UsuarioActual.CveUsuario, TipoDocto:=TipoComprobante, GPO:=DdlGrupo.SelectedValue.ToEntero, CveMoneda:=CveMoneda,
TipoCambio:=TipoCambio, TCEspecifico:=TCEspecifico, CveClienteClasificacion:=DdlClienteClasificacion.SelectedValue.ToEntero, CveProveedorCompra:=CveProveedorCompra,
CveMarca:=DdlMarcaPSDes.SelectedValue.ToEntero, CveClasificacionDetalle:=DdlTipoPSDes.SelectedValue.ToEntero(), TipoCliente:=DdlTipoCliente.SelectedValue.ToEntero,
ModalidadContable:=Not ChkLecturaAdmin.Checked) Then
ModalidadContable:=Not ChkLecturaAdmin.Checked, MostrarLitraje:=ChkLitraje.Checked, EsGarantia:=DdlGarantia.SelectedValue.ToEntero, CveCondicionesPago:=DdlCondicionesPago.SelectedValue.ToEntero, EsDistribuidor:=DdlDistribuidor.SelectedValue.ToEntero) Then
GvDatos.DataSource = ObjVentas.DtResultados
TmpDT = ObjVentas.DtResultados
Else
@@ -616,8 +637,10 @@ Partial Class Ventas_RepProductosServiciosDetalle
Dim EsWS = If(UsuarioActual.Empresa.Funcionalidad(105) = "1" Or UsuarioActual.Empresa.Funcionalidad(141) = "1", True, False)
If EsWS Then
DdlClientes.setEsWebService(True)
DdlClientes.SelectedValue = CveCliente.ToString
DdlClientes.SelectedText = GlobalDTCliente(UsuarioActual.CveEmpresa, -1).FiltroPrimeroValor("Nombre", String.Format("CveCliente = {0}", CveCliente))
If CveCliente > 0 Then
DdlClientes.SelectedValue = CveCliente.ToString
DdlClientes.SelectedText = GlobalDTCliente(UsuarioActual.CveEmpresa, -1, CveCliente:=CveCliente).FiltroPrimeroValor("Nombre")
End If
Else
DdlClientes.setEsWebService(False)
DdlClientes.DataSource = GlobalDTCliente(UsuarioActual.CveEmpresa, -1).FiltraParametros($"CveClienteClasificacion = {DdlClienteClasificacion.SelectedValue.ToEntero} OR {DdlClienteClasificacion.SelectedValue.ToEntero} = -1")

View File

@@ -304,6 +304,14 @@
<div class="col-md-2">
<asp:CheckBox ID="ChkLecturaAdmin" runat="server" Checked="false" CssClass="input-sm" />
</div>
<label title="Distr" data-toggle="tooltip" class="col-md-1 truncate">Distribuidor:</label>
<div class="col-md-2">
<asp:DropDownList ID="DdlDistribuidor" runat="server" AppendDataBoundItems="true" Class="table-group-action-input form-control input-inline input-small input-sm select2me">
<asp:ListItem Selected="True" Text="Todos" Value="-1"></asp:ListItem>
<asp:ListItem Text="Distribuidor" Value="1"></asp:ListItem>
<asp:ListItem Text="No Distribuidor" Value="0"></asp:ListItem>
</asp:DropDownList>
</div>
</div>
</div>
</div>

View File

@@ -283,6 +283,9 @@ Partial Class Ventas_RepVentas
DdlClienteClasificacion.DataBind()
DdlClienteClasificacion.Items.Insert(0, New ListItem("Todos", "-1"))
txtFechaI.Text = Now.FirstDayOfMonth.ToShortDateString
txtFechaF.Text = Now.ToShortDateString
End Sub
@@ -330,7 +333,8 @@ Partial Class Ventas_RepVentas
If ObjVentas.GetRepVentas(FechaI, FechaF, FechaIEjec, FechaFEjec, CveCliente, DdlSubProyectoEjecucion.SelectedValue.ToEntero, Vendedores,
DdlUsuario.SelectedValue.ToEntero, Estatus, "-1", UsuarioActual.CveEmpresa, DdlGrupo.SelectedValue.ToEntero, TipoComprobante, DdlProyecto.SelectedValue.ToEntero, Sucursales, RblTipoCambio.SelectedValue.ToEntero, TCEspecifico, CveUsuarioConsulta:=UsuarioActual.CveUsuario,
CveClienteClasificacion:=DdlClienteClasificacion.SelectedValue.ToEntero, CveCondicionesPago:=DdlCondicionesPago.SelectedValue.ToEntero, TipoCliente:=DdlTipoCliente.SelectedValue.ToEntero, ModalidadContable:=ModalidadContable) Then
CveClienteClasificacion:=DdlClienteClasificacion.SelectedValue.ToEntero, CveCondicionesPago:=DdlCondicionesPago.SelectedValue.ToEntero, TipoCliente:=DdlTipoCliente.SelectedValue.ToEntero, ModalidadContable:=ModalidadContable,
EsDistribuidor:=DdlDistribuidor.selectedvalue.toentero) Then
GvDatos.DataSource = ObjVentas.DtResultados
DtVentas = ObjVentas.DtResultados
Else

View File

@@ -11072,7 +11072,7 @@ Partial Class Ventas
Timbre.CFDIRelacionados.TipoRelacionTexto = "03-Devolución aplicada a Ingreso"
Case 4
Timbre.CFDIRelacionados.TipoRelacion = "04"
Timbre.CFDIRelacionados.TipoRelacionTexto = "04-Refacturación de Ingreso"
Timbre.CFDIRelacionados.TipoRelacionTexto = "04-Sustitución de los CFDI Previos"
Case 7
Timbre.CFDIRelacionados.TipoRelacion = "07"
Timbre.CFDIRelacionados.TipoRelacionTexto = "07-CFDI por aplicación de anticipo"
@@ -14897,7 +14897,7 @@ Partial Class Ventas
Dim UltimaFluctuacion As MTipoCambioFluctuacion = GlobalTipoCambioUltimaFluctuacion(tFecha)
If UsuarioActual.Empresa.Funcionalidad(703) = "1" AndAlso UltimaFluctuacion IsNot Nothing Then
If UltimaFluctuacion.FechaFluctuacion < tFecha Then
If UltimaFluctuacion.FechaFluctuacion <= tFecha Then
FechaUltimaFluctuacion = UltimaFluctuacion.FechaFluctuacion
TipoCambioFluctuacion = UltimaFluctuacion.TCFluctuacion
End If
@@ -25462,7 +25462,7 @@ Partial Class Ventas
Dim UltimaFluctuacion As MTipoCambioFluctuacion = GlobalTipoCambioUltimaFluctuacion(tFecha)
If UsuarioActual.Empresa.Funcionalidad(703) = "1" AndAlso UltimaFluctuacion IsNot Nothing Then
If UltimaFluctuacion.FechaFluctuacion < tFecha Then
If UltimaFluctuacion.FechaFluctuacion <= tFecha Then
FechaUltimaFluctuacion = UltimaFluctuacion.FechaFluctuacion
TipoCambioFluctuacion = UltimaFluctuacion.TCFluctuacion
End If