diff --git a/App_Code/ClsInventarios.vb b/App_Code/ClsInventarios.vb
index b792e8c86..0f779f97c 100644
--- a/App_Code/ClsInventarios.vb
+++ b/App_Code/ClsInventarios.vb
@@ -5029,6 +5029,92 @@ Public Class ClsInventarios
#End Region
+#Region "Almacen Clasificacion Secciones"
+ Public Function AddAlmacenClasificacionSecciones(CveAlmacen As Integer, CveClasificacion As Integer, CveClasificacionDetalle As Integer, CveMarca As Integer,
+ CveSeccionAlmacen As Integer) As Boolean
+ Dim Retorno As Boolean = False
+ DataAdapter("PA_Inv_AlmacenClasificacionesSeccionesAdd")
+
+ With SqlAdapter.SelectCommand.Parameters
+ .Add("@CveAlmacen", SqlDbType.Int).Value = CveAlmacen
+ .Add("@CveClasificacion", SqlDbType.Int).Value = CveClasificacion
+ .Add("@CveClasificacionDetalle", SqlDbType.Int).Value = CveClasificacionDetalle
+ .Add("@CveMarca", SqlDbType.Int).Value = CveMarca
+ .Add("@CveSeccionAlmacen", SqlDbType.Int).Value = CveSeccionAlmacen
+ End With
+
+ Try
+ SqlAdapter.Fill(Data)
+ Retorno = True
+ Catch ex As Exception
+ OnError("Ocurrió un error al agregar la relación Almacén Clasificación Sección.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
+ End Try
+
+ Return Retorno
+ End Function
+
+ Public Function GetAlmacenClasificacionSecciones(CveSeccionClasificacion As Integer, CveEmpresa As Integer) As Boolean
+ Dim Retorno As Boolean = False
+ DataAdapter("PA_Inv_AlmacenClasificacionesSeccionesGet")
+
+ With SqlAdapter.SelectCommand.Parameters
+ .Add("@CveSeccionClasificacion", SqlDbType.Int).Value = CveSeccionClasificacion
+ .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
+ End With
+
+ Try
+ SqlAdapter.Fill(Data)
+ Retorno = True
+ Catch ex As Exception
+ OnError("Ocurrió un error al obtener el Almacén Clasificación Sección.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
+ End Try
+
+ Return Retorno
+ End Function
+
+ Public Function UpdateAlmacenClasificacionSecciones(CveSeccionClasificacion As Integer, CveAlmacen As Integer, CveClasificacion As Integer, CveClasificacionDetalle As Integer,
+ CveMarca As Integer, CveSeccionAlmacen As Integer) As Boolean
+ Dim Retorno As Boolean = False
+ DataAdapter("PA_Inv_AlmacenClasificacionesSeccionesUpdate")
+
+ With SqlAdapter.SelectCommand.Parameters
+ .Add("@CveSeccionClasificacion", SqlDbType.Int).Value = CveSeccionClasificacion
+ .Add("@CveAlmacen", SqlDbType.Int).Value = CveAlmacen
+ .Add("@CveClasificacion", SqlDbType.Int).Value = CveClasificacion
+ .Add("@CveClasificacionDetalle", SqlDbType.Int).Value = CveClasificacionDetalle
+ .Add("@CveMarca", SqlDbType.Int).Value = CveMarca
+ .Add("@CveSeccionAlmacen", SqlDbType.Int).Value = CveSeccionAlmacen
+ End With
+
+ Try
+ SqlAdapter.Fill(Data)
+ Retorno = True
+ Catch ex As Exception
+ OnError("Ocurrió un error al obtener el Almacén Clasificación Sección.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
+ End Try
+
+ Return Retorno
+ End Function
+
+ Public Function RemoveAlmacenClasificacionSecciones(CveSeccionClasificacion As Integer) As Boolean
+ Dim Retorno As Boolean = False
+ DataAdapter("PA_Inv_AlmacenClasificacionesSeccionesDelete")
+
+ With SqlAdapter.SelectCommand.Parameters
+ .Add("@CveSeccionClasificacion", SqlDbType.Int).Value = CveSeccionClasificacion
+ End With
+
+ Try
+ SqlAdapter.Fill(Data)
+ Retorno = True
+ Catch ex As Exception
+ OnError("Ocurrió un error al eliminar el Almacén Clasificación Sección.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
+ End Try
+
+ Return Retorno
+ End Function
+#End Region
+
#Region " IDisposable Support "
' IDisposable
Protected Overridable Sub Dispose(ByVal disposing As Boolean)
diff --git a/App_Code/ClsPaginas.vb b/App_Code/ClsPaginas.vb
index 67aade701..4d7d3b574 100644
--- a/App_Code/ClsPaginas.vb
+++ b/App_Code/ClsPaginas.vb
@@ -4482,6 +4482,7 @@ Public Class ClsPaginas
PaginaDict.Add("/Inventarios/AjustesSeccionAlmacen.aspx".ToUpper(), 892)
PaginaDict.Add("/Inventarios/RepTraspasoAlmacen.aspx".ToUpper(), 688)
PaginaDict.Add("/Inventarios/EntregasPorRealizar.aspx".ToUpper(), 728)
+ PaginaDict.Add("/Inventarios/CatAlmacenClasificacionSecciones.aspx".ToUpper(), 764)
#End Region
#Region "MF"
diff --git a/Inventarios/CatAlmacenClasificacionSecciones.aspx b/Inventarios/CatAlmacenClasificacionSecciones.aspx
new file mode 100644
index 000000000..20e77d5e7
--- /dev/null
+++ b/Inventarios/CatAlmacenClasificacionSecciones.aspx
@@ -0,0 +1,91 @@
+<%@ Page Title="Inventarios - Catálogo almacén clasificación secciones" Language="C#" MasterPageFile="~/Site.master" AutoEventWireup="true" CodeFile="CatAlmacenClasificacionSecciones.aspx.cs" Inherits="Inventarios_CatAlmacenClasificacionSecciones" %>
+
+<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>
+
+
+
+
+
+
+
+ Catálogo de Almacén Clasificacion Secciones
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Inventarios/CatAlmacenClasificacionSecciones.aspx.cs b/Inventarios/CatAlmacenClasificacionSecciones.aspx.cs
new file mode 100644
index 000000000..8e44d3ef3
--- /dev/null
+++ b/Inventarios/CatAlmacenClasificacionSecciones.aspx.cs
@@ -0,0 +1,153 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+using System.Data;
+using Extensiones;
+
+public partial class Inventarios_CatAlmacenClasificacionSecciones : ClsPaginas
+{
+ private int CveSeccionClasificacion
+ {
+ get
+ {
+ return ViewState["CveSeccionClasificacion"].ToString().ToEntero();
+ }
+
+ set
+ {
+ ViewState["CveSeccionClasificacion"] = value;
+ }
+ }
+
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (!Page.IsPostBack)
+ {
+ CargarDatos();
+ CargarDropDowns();
+ }
+ }
+
+ private void CargarDatos()
+ {
+ ClsInventarios Objinv = new ClsInventarios();
+ if (Objinv.GetAlmacenClasificacionSecciones(-1,UsuarioActual.CveEmpresa))
+ {
+ GvDatos.DataSource = Objinv.DtResultados;
+ }
+ Objinv.Dispose();
+ GvDatos.DataBind();
+ }
+ private void CargarDropDowns()
+ {
+ DdlAlmacen.DataSource = get_GlobalDTAlmacen(UsuarioActual.CveEmpresa);
+ DdlAlmacen.DataBind();
+ DdlAlmacen.Items.Insert(0, new ListItem("Seleccione", "-1"));
+
+ DdlClasificacion.DataSource = get_GlobalDTClasificaciones(CveEmpresa:UsuarioActual.CveEmpresa);
+ DdlClasificacion.DataBind();
+ DdlClasificacion.Items.Insert(0, new ListItem("Seleccione", "-1"));
+
+ DdlTipo.DataSource = get_GlobalDTClasificacionesDetalle(UsuarioActual.CveEmpresa);
+ DdlTipo.DataBind();
+ DdlTipo.Items.Insert(0, new ListItem("Seleccione", "-1"));
+
+ ClsProductosServicios ObjMarcas = new ClsProductosServicios();
+ ObjMarcas.GetMarcas(UsuarioActual.CveEmpresa);
+ DdlMarca.DataSource = ObjMarcas.DtResultados;
+ ObjMarcas.Dispose();
+ DdlMarca.DataBind();
+ DdlMarca.Items.Insert(0, new ListItem("Seleccione", "-1"));
+
+ }
+
+ protected void DdlAlmacen_Change(object sender, EventArgs e)
+ {
+
+ int CveAlmacen = ((DropDownList)sender).SelectedValue.ToEntero();
+ CargarSeccionAlmacen(CveAlmacen);
+
+ }
+ private void CargarSeccionAlmacen(int CveAlmacen)
+ {
+ DdlSeccionAlmacen.DataSource = get_GlobalDTSeccionAlmacen(UsuarioActual.CveEmpresa, CveAlmacen);
+ DdlSeccionAlmacen.DataBind();
+ DdlSeccionAlmacen.Items.Insert(0, new ListItem("Seleccione", "-1"));
+ }
+
+ protected void BtnAgregarAlmacenClasificacionSeccion_Click(object sender, EventArgs e)
+ {
+ DdlAlmacen.SelectedValue = "-1";
+ DdlClasificacion.SelectedValue = "-1";
+ DdlTipo.SelectedValue = "-1";
+ DdlMarca.SelectedValue = "-1";
+ DdlSeccionAlmacen.Items.Clear();
+ UpModalTiposD.Update();
+ RegistraScript(String.Format("$('#{0}').modal();", "DivAgregarTiposD"));
+ }
+
+ protected void BtnAgregarACS_Click(object sender, EventArgs e)
+ {
+ ClsInventarios ObjInv = new ClsInventarios();
+
+ if (BtnAgregarACS.Text == "Agregar")
+ {
+ if (ObjInv.AddAlmacenClasificacionSecciones(DdlAlmacen.SelectedValue.ToEntero(),DdlClasificacion.SelectedValue.ToEntero(),DdlTipo.SelectedValue.ToEntero(),
+ DdlMarca.SelectedValue.ToEntero(),DdlSeccionAlmacen.SelectedValue.ToEntero()))
+ {
+ Alert("Se agregó correctamente Almacén Clasificación Sección");
+ }
+ }else
+ {
+ if (ObjInv.UpdateAlmacenClasificacionSecciones(CveSeccionClasificacion,DdlAlmacen.SelectedValue.ToEntero(), DdlClasificacion.SelectedValue.ToEntero(), DdlTipo.SelectedValue.ToEntero(),
+ DdlMarca.SelectedValue.ToEntero(), DdlSeccionAlmacen.SelectedValue.ToEntero()))
+ {
+ Alert("Se actualizó correctamente Almacén Clasificación Sección");
+ }
+ }
+
+ CargarDatos();
+ UpDatos.Update();
+
+ ObjInv.Dispose();
+ }
+
+ protected void LnkEditar_Click(object sender, EventArgs e)
+ {
+ GridViewRow GvRow = (GridViewRow)(((LinkButton)sender).NamingContainer);
+ string CveAlmacen = GvRow.DataKey("CveAlmacen");
+ string CveClasificacion = GvRow.DataKey("CveClasificacion");
+ string CveClasificacionDetalle = GvRow.DataKey("CveClasificacionDetalle");
+ string CveMarca = GvRow.DataKey("CveMarca");
+ string CveSeccionAlmacen = GvRow.DataKey("CveSeccionAlmacen");
+ BtnAgregarACS.Text = "Actualizar";
+
+ CveSeccionClasificacion = GvRow.DataKey("CveSeccionClasificacion").ToEntero();
+
+ DdlAlmacen.SelectedValue = CveAlmacen;
+ CargarSeccionAlmacen(CveAlmacen.ToEntero());
+ DdlClasificacion.SelectedValue = CveClasificacion;
+ DdlTipo.SelectedValue = CveClasificacionDetalle;
+ DdlMarca.SelectedValue = CveMarca;
+ DdlSeccionAlmacen.SelectedValueExist(CveSeccionAlmacen);
+ UpModalTiposD.Update();
+ RegistraScript(String.Format("$('#{0}').modal();", "DivAgregarTiposD"));
+ }
+
+ protected void LnkEliminar_Click(object sender,EventArgs e)
+ {
+ GridViewRow GvRow = (GridViewRow)(((LinkButton)sender).NamingContainer);
+ int CveSeccionClasificacion = GvRow.DataKey("CveSeccionClasificacion").ToEntero();
+ ClsInventarios ObjInv = new ClsInventarios();
+ if (ObjInv.RemoveAlmacenClasificacionSecciones(CveSeccionClasificacion))
+ {
+ CargarDatos();
+ UpDatos.Update();
+ Alert("Se eliminó correctamente Almacén Clasificación Sección");
+ }
+ ObjInv.Dispose();
+ }
+}
\ No newline at end of file