Esempio n. 1
0
        protected void Pic_1_Click(object sender, ImageClickEventArgs e)
        {
            UserDownload     ud   = new UserDownload();
            UserDownload_Bll ud_b = new UserDownload_Bll();

            ud = ud_b.GetUserDownload(Convert.ToInt32(Session["ID"]), Convert.ToInt32(Session["c_id"]), Convert.ToInt32(Session["cd_id"]));
            if (ud.UD_ID < 1)
            {
                UserDownload     ud1   = new UserDownload();
                UserDownload_Bll ud_b1 = new UserDownload_Bll();
                ud1.C_ID      = Convert.ToInt32(Session["c_id"]);
                ud1.CD_ID     = Convert.ToInt32(Session["cd_id"]);
                ud1.U_ID      = Convert.ToInt32(Session["ID"]);
                ud1.CD_IsBei  = 1;
                ud1.UD_CUT    = 0;
                ud1.UD_STUDY  = DateTime.Now;
                ud1.UD_Review = DateTime.Now;
                ud1.UD_Data   = 0;
                ud1.UD_Status = 0;
                bool i = ud_b1.AddUserDownload(ud1);
                if (i)
                {
                    xx = ud1.CD_ID + 1;
                    Response.Redirect("Study_Words.aspx?xx=" + xx + "", false);
                }
            }
        }
Esempio n. 2
0
        protected void Pic_1_Click(object sender, ImageClickEventArgs e)
        {
            UserDownload_Bll ud_b = new UserDownload_Bll();
            UserDownload     ud   = new UserDownload();

            ud           = ud_b.GetUserDownload(2, cdid);
            ud.UD_Review = DateTime.Now;
            ud_b.ModifyUserDownload(ud);
            rank = rank + 1;
            Response.Redirect("Review_Words.aspx?rank=" + rank + "");
        }