Esempio n. 1
0
        /// <summary>
        /// 题目DDL
        /// </summary>
        /// <param name="dropDownList"></param>
        public static void TopicDLL(DropDownList dropDownList, string major_id = null)
        {
            dropDownList.Items.Clear();
            var bll   = new BLL.t_topic();
            var model = major_id == null?bll.GetModelList("topic_stat=5") : bll.GetModelList("topic_stat=5 AND topic_class_id='" + major_id + "'");

            foreach (var item in model)
            {
                dropDownList.Items.Add(new ListItem(item.topic_name, item.topic_id));
            }
        }
Esempio n. 2
0
        /// <summary>
        /// 保存审核结果
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        protected void btnSave_Click(object sender, EventArgs e)
        {
            var bll   = new BLL.t_topic();
            var model = bll.GetModel(Request["topic_id"]);

            model.topic_stat = int.Parse(ddlStat.SelectedValue);
            model.topic_note = txttopic_note.Text;

            /// 写入日志
            BLL.Utils.Log(this, "审核出题:" + Request["topic_id"]);
            BLL.Utils.ShowMessage(this, bll.Update(model)?"保存成功!":"发生错误!");
        }
Esempio n. 3
0
 protected void Page_Load(object sender, EventArgs e)
 {
     if (int.Parse(Session["role"].ToString()) < 3)
     {
         BLL.Utils.ShowMessage(this, "该功能仅教研室主任以上权限可用!");
         Response.End();
     }
     if (!IsPostBack)
     {
         initControl();
     }
     else
     {
         var bbl   = new BLL.t_topic();
         var model = bbl.GetModel(Request["topic_id"]);
         model.topic_stat = int.Parse(ddlStat.SelectedValue);
         model.topic_note = txttopic_note.Text;
     }
 }