se agregó el campo tipo aplicación en las promociones

This commit is contained in:
Antonio Gonzalez
2020-01-22 15:34:29 -07:00
parent eb74aceac9
commit 094dc5abe3
3 changed files with 16 additions and 2 deletions

View File

@@ -1873,7 +1873,7 @@ Public Class ClsVentas
Return Retorno Return Retorno
End Function End Function
Public Function AddPromociones(Promocion As String, FechaInicio As Date, FechaFin As Date, CveVendedor As Integer, CveCliente As Integer, Estatus As Boolean, CveMoneda As Integer, CveUsuario As Integer, CveEmpresa As Integer, CveSubProyecto As Integer) As Integer Public Function AddPromociones(Promocion As String, FechaInicio As Date, FechaFin As Date, CveVendedor As Integer, CveCliente As Integer, Estatus As Boolean, CveMoneda As Integer, CveUsuario As Integer, CveEmpresa As Integer, CveSubProyecto As Integer, TipoAplicacion As String) As Integer
Dim Retorno = -1 Dim Retorno = -1
DataAdapter("PA_Vta_PromocionesAdd") DataAdapter("PA_Vta_PromocionesAdd")
@@ -1889,6 +1889,7 @@ Public Class ClsVentas
.Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario .Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
.Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto .Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto
.Add("@TipoAplicacion", SqlDbType.VarChar).Value = TipoAplicacion
.Add("@CvePromocion", SqlDbType.Int).Direction = ParameterDirection.Output .Add("@CvePromocion", SqlDbType.Int).Direction = ParameterDirection.Output
End With End With

View File

@@ -128,6 +128,17 @@
<asp:CheckBox ID="ChkEstatus" runat="server" /> <asp:CheckBox ID="ChkEstatus" runat="server" />
</div> </div>
</div> </div>
<div class="row">
<label class="col-md-2 truncate">Tipo Aplicacion:</label>
<div class="col-md-4">
<asp:DropDownList ID="DdlTipoAplicacion" DataTextField="Moneda" DataValueField="CveMoneda" CssClass="select2me" runat="server" Width="350px">
<asp:ListItem Value ="-1">Seleccione</asp:ListItem>
<asp:ListItem Value ="Descuento">Descuento</asp:ListItem>
<asp:ListItem Value ="PU">PU</asp:ListItem>
</asp:DropDownList>
</div>
</div>
</div> </div>
</div> </div>
</div> </div>

View File

@@ -380,7 +380,9 @@ Partial Class Ventas_Promociones
Dim ObjVentas As New ClsVentas Dim ObjVentas As New ClsVentas
Dim TieneError = False Dim TieneError = False
ObjVentas.IniciaTransacSQL() ObjVentas.IniciaTransacSQL()
CvePromocion = ObjVentas.AddPromociones(TxtPromocion.Text.Trim, If(IsDate(TxtFechaI.Text), TxtFechaI.Text.ToDate, MinFecha), If(IsDate(TxtFechaF.Text), TxtFechaF.Text.ToDate, MaxFecha), DdlVendedor.SelectedValue.ToEntero, DdlCliente.SelectedValue.ToEntero, ChkEstatus.Checked, DdlMoneda.SelectedValue.ToEntero, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, DdlSubProyecto.SelectedValue.ToEntero) CvePromocion = ObjVentas.AddPromociones(TxtPromocion.Text.Trim, If(IsDate(TxtFechaI.Text), TxtFechaI.Text.ToDate, MinFecha), If(IsDate(TxtFechaF.Text), TxtFechaF.Text.ToDate, MaxFecha),
DdlVendedor.SelectedValue.ToEntero, DdlCliente.SelectedValue.ToEntero, ChkEstatus.Checked, DdlMoneda.SelectedValue.ToEntero, UsuarioActual.CveUsuario,
UsuarioActual.CveEmpresa, DdlSubProyecto.SelectedValue.ToEntero, DdlTipoAplicacion.SelectedValue.ToString)
If CvePromocion > 0 Then If CvePromocion > 0 Then
For Each Dr As DataRow In TempDT.Rows For Each Dr As DataRow In TempDT.Rows