public ActionResult Nuevo()
        {
            #region Validar Session
            if (string.IsNullOrEmpty(SessionFixed.IdTransaccionSession))
            {
                return(RedirectToAction("Login", new { Area = "", Controller = "Account" }));
            }
            SessionFixed.IdTransaccionSession       = (Convert.ToDecimal(SessionFixed.IdTransaccionSession) + 1).ToString();
            SessionFixed.IdTransaccionSessionActual = SessionFixed.IdTransaccionSession;
            #endregion

            var lst_empleados = bus_empleado.get_list_profesores(Convert.ToInt32(SessionFixed.IdEmpresa));
            empleado_info_list.set_list(lst_empleados, Convert.ToDecimal(SessionFixed.IdTransaccionSession));

            ro_HorasProfesores_Info model = new ro_HorasProfesores_Info
            {
                IdTransaccionSession = Convert.ToDecimal(SessionFixed.IdTransaccionSession),
                IdEmpresa            = Convert.ToInt32(SessionFixed.IdEmpresa),
                FechaCarga           = DateTime.Now,
                IdNomina             = 1,
                IdNominaTipo         = 2,
            };

            var lst_rubros = bus_rubro.get_list(Convert.ToInt32(SessionFixed.IdEmpresa), false);
            ro_rubro_tipo_Info_list.set_list(lst_rubros, model.IdTransaccionSession);

            model.detalle = new List <ro_HorasProfesores_det_Info>();
            detalle.set_list(model.detalle);
            cargar_combos();
            return(View(model));
        }
Example #2
0
        public ActionResult Index()
        {
            #region Validar Session
            if (string.IsNullOrEmpty(SessionFixed.IdTransaccionSession))
            {
                return(RedirectToAction("Login", new { Area = "", Controller = "Account" }));
            }
            SessionFixed.IdTransaccionSession       = (Convert.ToDecimal(SessionFixed.IdTransaccionSession) + 1).ToString();
            SessionFixed.IdTransaccionSessionActual = SessionFixed.IdTransaccionSession;
            #endregion

            ro_rubro_tipo_Info model = new ro_rubro_tipo_Info
            {
                IdEmpresa            = Convert.ToInt32(SessionFixed.IdEmpresa),
                IdTransaccionSession = Convert.ToDecimal(SessionFixed.IdTransaccionSession)
            };

            List <ro_rubro_tipo_Info> lista = bus_rubro.get_list(model.IdEmpresa, true);
            Lista_Rubro.set_list(lista, Convert.ToDecimal(SessionFixed.IdTransaccionSession));

            return(View(model));
        }
Example #3
0
        public ActionResult Nuevo()
        {
            var lst_rubros = bus_rubro.get_list(Convert.ToInt32(SessionFixed.IdEmpresa), false);

            ro_rubro_tipo_Info_list.set_list(lst_rubros);

            var lst_empleados = bus_empleado.get_list_profesores(Convert.ToInt32(SessionFixed.IdEmpresa));

            empleado_info_list.set_list(lst_empleados);

            ro_HorasProfesores_Info model = new ro_HorasProfesores_Info
            {
                IdEmpresa    = Convert.ToInt32(SessionFixed.IdEmpresa),
                FechaCarga   = DateTime.Now,
                IdNomina     = 1,
                IdNominaTipo = 2,
            };

            model.detalle = new List <ro_HorasProfesores_det_Info>();
            detalle.set_list(model.detalle);
            cargar_combos();
            return(View(model));
        }