Пример #1
0
        public ContentResult PubInfo_API()
        {
            string action = GetParam("action");
            int    pubId  = DataConvert.CLng(GetParam("pubid"));
            string ids    = GetParam("ids");

            SafeSC.CheckIDSEx(ids);
            M_Pub pubMod = pubBll.SelReturnModel(pubId);

            if (pubMod == null)
            {
                throw new Exception("未指定互动模型");
            }
            switch (action)
            {
            case "del":
                DBCenter.DelByIDS(pubMod.PubTableName, "ID", ids);
                break;

            case "audit":
                DBCenter.UpdateSQL(pubMod.PubTableName, "PubStart=1", "ID IN (" + ids + ")");
                break;

            case "cancel":
                DBCenter.UpdateSQL(pubMod.PubTableName, "PubStart=0", "ID IN (" + ids + ")");
                break;
            }
            return(Content(Success.ToString()));
        }
Пример #2
0
 public bool RealDelByIDS(string ids, string items)
 {
     SafeSC.CheckDataEx(items);
     SafeSC.CheckIDSEx(ids);
     DBCenter.DelByIDS(TbName, PK, ids);
     DBCenter.DelByIDS("ZL_P_Shop", "ID", items);
     return(true);
 }
Пример #3
0
 public void DelByIDS(string ids)
 {
     if (string.IsNullOrEmpty(ids))
     {
         return;
     }
     SafeSC.CheckIDSEx(ids); DBCenter.DelByIDS(TbName, PK, ids);
 }
Пример #4
0
 public void Del(string ids)
 {
     if (string.IsNullOrEmpty(ids))
     {
         return;
     }
     DBCenter.DelByIDS(strTableName, PK, ids);
 }
Пример #5
0
 public bool DelByIDS(string ids)
 {
     if (string.IsNullOrEmpty(ids))
     {
         return(false);
     }
     SafeSC.CheckIDSEx(ids);
     return(DBCenter.DelByIDS(TbName, PK, ids));
 }
Пример #6
0
 public static bool DelQuestion(string ids)
 {
     if (string.IsNullOrEmpty(ids))
     {
         return(false);
     }
     SafeSC.CheckIDSEx(ids);
     return(DBCenter.DelByIDS("ZL_QUESTION", "QID", ids));
 }
Пример #7
0
        protected void BatDel_Btn_Click(object sender, EventArgs e)
        {
            string ids = Request.Form["idchk"];

            if (!string.IsNullOrEmpty(ids))
            {
                SafeSC.CheckIDSEx(ids);
                DBCenter.DelByIDS(pubMod.PubTableName, "ID", ids);
            }
            RPT.DataBind();
        }
Пример #8
0
 /// <summary>
 /// 删除贴子
 /// </summary>
 /// <param name="ids"></param>
 /// <param name="realdel">true:真正删除,false:更改状态</param>
 public void DelByIDS(string ids, bool realdel = false)
 {
     SafeSC.CheckIDSEx(ids);
     if (realdel)
     {
         DBCenter.DelByIDS(TbName, PK, ids);
     }
     else
     {
         DBCenter.UpdateSQL(TbName, "Status=" + (int)ConStatus.Recycle, "ID IN(" + ids + ")");
     }
 }
Пример #9
0
 /// <summary>
 /// true:真正删除
 /// </summary>
 public bool DelByIds(string ids, bool flag = false)
 {
     SafeSC.CheckIDSEx(ids);
     if (flag)
     {
         DBCenter.DelByIDS(TbName, PK, ids);
     }
     else
     {
         DBCenter.UpdateSQL(TbName, "Status=0", "ID IN (" + ids + ")");
     }
     return(true);
 }
Пример #10
0
 /// <summary>
 /// 吧主删贴
 /// </summary>
 public void DelByIDS(int cateid, string ids, bool realdeal = false)
 {
     if (string.IsNullOrEmpty(ids))
     {
         return;
     }
     SafeSC.CheckIDSEx(ids);
     if (realdeal)
     {
         DBCenter.DelByIDS(TbName, PK, ids);
     }
     else
     {
         DBCenter.UpdateSQL(TbName, "Status=" + (int)ConStatus.Recycle, "ID IN(" + ids + ") AND CateID=" + cateid);
     }
 }
Пример #11
0
 public void DelByIDS(string ids)
 {
     SafeSC.CheckIDSEx(ids);
     DBCenter.DelByIDS(TbName, PK, ids);
 }
Пример #12
0
 public bool Del(int ID)
 {
     return(DBCenter.DelByIDS(TbName, PK, ID.ToString()));
 }
Пример #13
0
 public bool DelByIDS(string ids)
 {
     SafeSC.CheckIDSEx(ids); return(DBCenter.DelByIDS(TbName, PK, ids));
 }
Пример #14
0
 public void DelByIDS(string ids, string pk = "id")
 {
     DBCenter.DelByIDS(TbName, pk, ids);
 }
Пример #15
0
 public bool DelByIDS(SType stype, string ids)
 {
     SafeSC.CheckIDSEx(ids);
     return(DBCenter.DelByIDS(GetTbName(stype), PK, ids));
 }
Пример #16
0
 public void DelByIDS(string ids)
 {
     DBCenter.DelByIDS(TbName, PK, ids);
 }