Ejemplo n.º 1
0
        /// <summary>
        ///  根据ID删除数据
        /// </summary>
        /// Author  : Napoleon
        /// Created : 2015-06-24 15:59:36
        public ActionResult Delete(string ids)
        {
            string status = "failue", msg = "删除失败!", json;

            try
            {
                int i = _newsContentsService.DeleteNewsContents(ids);
                if (i > 0)
                {
                    status = "success";
                    msg    = "删除成功!";
                }
            }
            catch (Exception exception)
            {
                msg = "删除出错!";
                Log4Dao.InsertLog4(exception.Message);
            }
            json = PublicFunc.ModelToJson(status, msg);
            return(Content(json));
        }