Ejemplo n.º 1
0
        /// <summary>
        /// 删除讨论版
        /// </summary>
        /// <param name="model">讨论版对象</param>
        /// <param name="strAccount">账号</param>
        /// <returns></returns>
        public DataSet BBS_Board_Delete(BoardModel model,string strAccount)
        {
            SqlParameter[] paras =
            {
               new SqlParameter("@BOARD_ID",SqlDbType.Int),
                new SqlParameter("@Account",SqlDbType.NVarChar,20)
            };

            paras[0].Value = model.BOARD_ID;
            paras[1].Value = strAccount;

            try
            {
              return  DbHelperSQL.RunProcedure("OA_BBS_Board_Delete", paras,"ds");
            }
            catch
            {
                return null;
            }
        }
Ejemplo n.º 2
0
        /// <summary>
        /// 新建讨论版
        /// </summary>
        /// <param name="model">讨论版对象</param>
        /// <returns></returns>
        public int BBS_Board_Insert(BoardModel model)
        {
            SqlParameter[] paras =
            {
                new SqlParameter("@BOARD_NO",SqlDbType.NVarChar,20),
                new SqlParameter("@BOARD_NAME",SqlDbType.NVarChar,100),
                new SqlParameter("@ANONYMITY_YN",SqlDbType.Bit),
                new SqlParameter("@WELCOME_TEXT",SqlDbType.NVarChar,200),
                new SqlParameter("@BOARD_HOSTER",SqlDbType.NVarChar),
                new SqlParameter("@USER_ID",SqlDbType.NVarChar),
                new SqlParameter("@BOARD_HOSTER_Name",SqlDbType.NVarChar),
                new SqlParameter("@User_Name",SqlDbType.NVarChar),
                new SqlParameter("@DEPT_ID",SqlDbType.NVarChar),
                new SqlParameter("@PRIV_ID",SqlDbType.NVarChar)
            };

            paras[0].Value = model.BOARD_NO;
            paras[1].Value = model.BOARD_NAME;
            paras[2].Value = model.ANONYMITY_YN;
            paras[3].Value = model.WELCOME_TEXT;
            paras[4].Value = model.BOARD_HOSTER;
            paras[5].Value = model.USER_ID;
            paras[6].Value = model.BOARD_HOSTER_Name;
            paras[7].Value = model.User_Name;
            paras[8].Value = model.DEPT_ID;
            paras[9].Value = model.PRIV_ID;

            try
            {
                int iReturn = -1;
                DbHelperSQL.RunProcedure("OA_BBS_Board_Insert", paras, out iReturn);
                return iReturn;
            }
            catch
            {
                return -1;
            }
        }
Ejemplo n.º 3
0
 /// <summary>
 /// 修改讨论版
 /// </summary>
 /// <param name="model">讨论版对象</param>
 /// <returns></returns>
 public int BBS_Board_Update(BoardModel model)
 {
     return boarddal.BBS_Board_Update(model);
 }
Ejemplo n.º 4
0
 /// <summary>
 /// 新建讨论版
 /// </summary>
 /// <param name="model">讨论版对象</param>
 /// <returns></returns>
 public int BBS_Board_Insert(BoardModel model)
 {
     return boarddal.BBS_Board_Insert(model);
 }
Ejemplo n.º 5
0
 /// <summary>
 /// 删除讨论版
 /// </summary>
 /// <param name="model">讨论版对象</param>
 /// <param name="strAccount">账号</param>
 /// <returns></returns>
 public DataSet BBS_Board_Delete(BoardModel model, string strAccount)
 {
     return boarddal.BBS_Board_Delete(model,strAccount);
 }