Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using Paneles.Entities;
- using Nuevo_Panel.Proxy;
- using Nuevo_Panel.Helpers;
- using System.Linq;
- using System.Web;
- using System.Web.Mvc;
- using Paneles.Entities.PanelSET;
- namespace Nuevo_Panel.Controllers
- {
- public class PanelSETController : Controller
- {
- // GET: PanelSET
- public ActionResult PanelControlSET()
- {
- ProxySET proxy = new ProxySET();
- String registro = HelperAplicacion.ObtenerUsuarioLogueado();
- Colaborador colaborador = proxy.RecuperarDatosColaboradorporRegistro(registro);
- List<Tienda> Tiendas = proxy.RecuperarDatosTienda(registro, "PANEL SET");
- ManejadorPanelSET manejador = new ManejadorPanelSET();
- manejador.Lista_Tienda = Tiendas;
- ViewBag.Title = "Panel SET";
- return View(manejador);
- }
- [HttpPost]
- public JsonResult RecuperarDetallePanel(String cod_tienda, String trimestre)
- {
- ProxySET proxy = new ProxySET();
- String registro = HelperAplicacion.ObtenerUsuarioLogueado();
- Colaborador colaborador = proxy.RecuperarDatosColaboradorporRegistro(registro);
- List<PanelPersonalDetalle> DetallesPanel = new List<PanelPersonalDetalle>();
- if (HelperAplicacion.perfil(colaborador.categoria) == 2)
- {
- DetallesPanel = proxy.RecuperarDatosPanelPersonalDetalle(cod_tienda, 8, trimestre, colaborador.registro_colaborador);
- DetallesPanel.AddRange(proxy.RecuperarDatosPanelPersonalDetalle(cod_tienda, 9, trimestre, colaborador.registro_colaborador));
- }
- else
- {
- DetallesPanel = proxy.RecuperarDatosPanelPersonalDetalle(cod_tienda, 8, trimestre, null);
- DetallesPanel.AddRange(proxy.RecuperarDatosPanelPersonalDetalle(cod_tienda, 9, trimestre, null));
- }
- return Json(new { detalle = DetallesPanel });
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement