using Castle.ActiveRecord; using System; using System.Text; namespace BizCom { [ActiveRecord("CE_ErpProfession")] public class CeErpProfession : ComBase { /// /// /// [PrimaryKey(PrimaryKeyType.Native)] public int ID { get; set; } private int _pID = 0; /// /// /// [Property] public int PID { get { return _pID; } set { _pID = value; } } private string _name = ""; /// /// /// [Property] public string Name { get { return _name; } set { _name = value; } } /// /// /// [Property] public DateTime? AddTime { get; set; } public static void Del(object id) { StringBuilder sql = new StringBuilder(); sql.AppendFormat("delete from CE_ErpProfession where id=" + id); ExecuteNonQuery(sql.ToString()); } } }