public ActionResult Add(User user, bool is_admin, int role_filter, string search, string search_option, string order)
        {
            string operation = "add";

            if (ModelState.IsValid)
            {
                int role_id;

                if (is_admin)
                {
                    role_id = ScmRoleProvider.GetRoleIdByName("社联");
                    user = new User
                    {
                        UserName = user.UserName,
                        Password = user.Password,
                        RoleId = role_id,
                        Name = "社联"
                    };
                }
                else
                {
                    role_id = ScmRoleProvider.GetRoleIdByName("学生");
                    user = new Student
                    {
                        UserName = user.UserName,
                        Password = user.Password,
                        RoleId = role_id,
                        Name = user.Name
                    };
                }

                ScmMembershipProvider.AddUser(user);

                string return_url = "List?role_filter=" + role_filter + "&search=" + search +
                "&search_option=" + search_option + "&order=" + order;

                return Json(new { success = true, msg = "添加成功", url = return_url, operation = operation });
            }

            return Json(new { success = false, msg = "参数错误", operation = operation });
        }
        public ActionResult Edit(Student student, int page_number, string order, string search, string search_option, int role_filter)
        {
            if (ModelState.IsValid)
            {
                db.Students.Update(student);
                string return_url = "List?role_filter=" + role_filter + "&search=" + search +
                "&search_option=" + search_option + "&order=" + order + "&page_number=" + page_number;

                return Json(new { success = true, msg = "修改成功", url = return_url });
            }

            return Json(new { success = false, msg = "修改失败" });
        }