Beispiel #1
0
        public ActionResult SetScore(int id,FormCollection f)
        {
            int userID = UserID;
            bizBBSMain b = new bizBBSMain();
            BBSMain model = b.Get(id);
            int cha;
            if (model == null)
                return Redirect("/Home/AlertPage.html");
            if (!UserCommon.CheckBBSAdminRight(AdminType))
                return Redirect("/Home/AlertPage.html");

            bizUserScoreLog bu = new bizUserScoreLog();
            UserScoreLog modelUS = bu.Get(id, userID);
            List<UserScoreLog> listUS = bu.List(id);
            if (modelUS == null)
            {
                if (int.Parse(f["score"])!=0)
                    bu.Add(id, userID, UserName, int.Parse(f["score"]), f["remark"].Trim());
            }
            else
            {
                b.UserScoreCancel(id, userID);

            }
            TempData["Msg"]="�������óɹ�";
            return RedirectToAction("SetScore",new {id=id});
        }
Beispiel #2
0
        public ActionResult ScoreCancel(int id)
        {
            if (UserCommon.CheckBBSHighAdminRight(AdminType) == false)
            {
                return Redirect("/bbs/" + id + ".html");
            }

            int userid = int.Parse(Request.QueryString["userid"].ToString());
            bizBBSMain b = new bizBBSMain();
            b.UserScoreCancel(id, userid);
            return Redirect("/bbs/" + id + ".html");
        }