Ejemplo n.º 1
0
        public static bool RemoveTModel(务约束 entity)
        {
            bool isdeleteOk = true;

            try
            {
                serviceDirectoryDC.务约束.DeleteOnSubmit(GetTModelByMID(entity.约束编码));
                serviceDirectoryDC.SubmitChanges();
            }
            catch
            {
                isdeleteOk = false;
            }
            return(isdeleteOk);
        }
Ejemplo n.º 2
0
        public static Guid AddTModel(务约束 entity)
        {
            Guid MID = Guid.NewGuid();

            try
            {
                entity.约束编码 = MID;
                serviceDirectoryDC.务约束.InsertOnSubmit(entity);
                serviceDirectoryDC.SubmitChanges();
            }
            catch
            {
                MID = Guid.Empty;
            }
            return(MID);
        }
Ejemplo n.º 3
0
        public static bool UpdateTModel(务约束 entity)
        {
            bool isUpdateOk = true;

            try
            {
                var entities = serviceDirectoryDC.务约束.Where(p => p.约束编码 == entity.约束编码);
                entities.ToArray()[0].务地址编码 = entity.务地址编码;
                entities.ToArray()[0].示例    = entity.示例;
                entities.ToArray()[0].描述    = entity.描述;
                serviceDirectoryDC.SubmitChanges();
            }
            catch
            {
                isUpdateOk = false;
            }
            return(isUpdateOk);
        }
Ejemplo n.º 4
0
 partial void Delete服务约束(务约束 instance);
Ejemplo n.º 5
0
 partial void Update服务约束(务约束 instance);
Ejemplo n.º 6
0
 partial void Insert服务约束(务约束 instance);
Ejemplo n.º 7
0
 private void detach_服务约束(务约束 entity)
 {
     this.SendPropertyChanging();
     entity.务地址 = null;
 }
Ejemplo n.º 8
0
 private void attach_服务约束(务约束 entity)
 {
     this.SendPropertyChanging();
     entity.务地址 = this;
 }