Exemplo n.º 1
0
        public void Index()
        {
            IList <Registration> _registrationList = null;

            Employee _employee = Session["logonUser"] as Employee;

            if (_employee != null)
            {
                Registration _registration = new Registration();
                _registration.EmployeeID = _employee.ID;

                _registrationList = _registrationService.GetRegistration(_registration);
                foreach (Registration Registration in _registrationList)
                {
                    IDictionary _hash = new Hashtable();

                    _hash.Add("pageIndex", 1);
                    _hash.Add("pageSize", 100);
                    _hash.Add("JOIN", "INNER");
                    _hash.Add("EmployeeID", Registration.EmployeeID);

                    Registration.SyllabusList = _syllabusService.GetSyllabus(_hash);
                }

                PropertyBag["employee"]         = _employee;
                PropertyBag["RegistrationList"] = _registrationList;
            }
        }
Exemplo n.º 2
0
        /// <summary>
        /// 学生课程表
        /// </summary>
        /// <param name="userID">用户ID</param>
        public void SyllabusList(int userID)
        {
            IDictionary _hash = new Hashtable();

            _hash.Add("EmployeeID", userID);

            IList <Syllabus> _syllabusList = _syllabusService.GetSyllabus(_hash);

            _result.Code = 0;
            _result.Data = _syllabusList;
            string _jsonString = JsonConvert.SerializeObject(_result, Formatting.Indented);

            RenderText(_jsonString);
            CancelLayout();
        }