ContentManage.cs 1.1 KB

123456789101112131415161718192021222324252627282930313233343536
  1. using Central.Control.Domain;
  2. using System;
  3. using System.Collections.Generic;
  4. using System.Data.SqlClient;
  5. using System.Linq;
  6. using System.Text;
  7. namespace MES.Production.Service.ServiceImp
  8. {
  9. /// <summary>
  10. /// 大数据字段Service实现类
  11. /// add 作者: 季健国 QQ:181589805 by 2016-10-14
  12. /// </summary>
  13. public class ContentManage : RepositoryBase<COM_CONTENT>, IService.IContentManage
  14. {
  15. /// <summary>
  16. /// 更新Isdel属性
  17. /// </summary>
  18. public bool UpdateSql(string Id, string tablename)
  19. {
  20. try
  21. {
  22. string sql = "update COM_CONTENT set isdel=1 where FK_RELATIONID=@FK_RELATIONID and FK_TABLE=@FK_TABLE";
  23. SqlParameter[] para = {
  24. new SqlParameter("@FK_RELATIONID",Id),
  25. new SqlParameter("@FK_TABLE",tablename)
  26. };
  27. return this.ExecuteSqlCommand(sql, para).ToString() != "0";
  28. }
  29. catch (Exception e)
  30. {
  31. throw e;
  32. }
  33. }
  34. }
  35. }