本文整理汇总了C#中OpenEnvironment.App_Logic.DataAccessLayer.OpenEnvironmentEntities.DeleteObject方法的典型用法代码示例。如果您正苦于以下问题:C# OpenEnvironmentEntities.DeleteObject方法的具体用法?C# OpenEnvironmentEntities.DeleteObject怎么用?C# OpenEnvironmentEntities.DeleteObject使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类OpenEnvironment.App_Logic.DataAccessLayer.OpenEnvironmentEntities
的用法示例。
在下文中一共展示了OpenEnvironmentEntities.DeleteObject方法的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: DeleteT_OE_ColumnConfig
public static int DeleteT_OE_ColumnConfig(int columnConfig_IDX)
{
using (OpenEnvironmentEntities ctx = new OpenEnvironmentEntities())
{
try
{
T_OE_COLUMNCONFIG r = new T_OE_COLUMNCONFIG();
r = (from c in ctx.T_OE_COLUMNCONFIG where c.COLUMNCONFIG_IDX == columnConfig_IDX select c).FirstOrDefault();
ctx.DeleteObject(r);
ctx.SaveChanges();
return 1;
}
catch
{
return 0;
}
}
}
示例2: DeleteT_WQX_IMPORT_LOG
public static int DeleteT_WQX_IMPORT_LOG(int iMPORT_ID)
{
using (OpenEnvironmentEntities ctx = new OpenEnvironmentEntities())
{
try
{
T_WQX_IMPORT_LOG r = new T_WQX_IMPORT_LOG();
r = (from c in ctx.T_WQX_IMPORT_LOG
where c.IMPORT_ID == iMPORT_ID select c).FirstOrDefault();
ctx.DeleteObject(r);
ctx.SaveChanges();
return 1;
}
catch
{
return 0;
}
}
}
示例3: DeleteT_ATTAINS_ASSESS
public static int DeleteT_ATTAINS_ASSESS(int aSSESS_IDX)
{
using (OpenEnvironmentEntities ctx = new OpenEnvironmentEntities())
{
try
{
T_ATTAINS_ASSESS r = (from c in ctx.T_ATTAINS_ASSESS
where c.ATTAINS_ASSESS_IDX == aSSESS_IDX
select c).FirstOrDefault();
ctx.DeleteObject(r);
ctx.SaveChanges();
return 1;
}
catch
{
return 0;
}
}
}
示例4: DeleteT_WQX_REF_TAXA_ORG
public static int DeleteT_WQX_REF_TAXA_ORG(string orgName, string charName)
{
using (OpenEnvironmentEntities ctx = new OpenEnvironmentEntities())
{
try
{
T_WQX_REF_TAXA_ORG r = new T_WQX_REF_TAXA_ORG();
r = (from c in ctx.T_WQX_REF_TAXA_ORG
where c.ORG_ID == orgName
&& c.BIO_SUBJECT_TAXONOMY == charName
select c).FirstOrDefault();
ctx.DeleteObject(r);
ctx.SaveChanges();
return 1;
}
catch
{
return 0;
}
}
}
示例5: DeleteT_ATTAINS_REPORT
public static int DeleteT_ATTAINS_REPORT(int aTTAINS_REPORT_IDX)
{
using (OpenEnvironmentEntities ctx = new OpenEnvironmentEntities())
{
try
{
T_ATTAINS_REPORT r = (from c in ctx.T_ATTAINS_REPORT
where c.ATTAINS_REPORT_IDX == aTTAINS_REPORT_IDX
select c).FirstOrDefault();
if (r.ATTAINS_SUBMIT_STATUS == "Y" || r.ATTAINS_SUBMIT_STATUS == "U")
return -1;
ctx.DeleteObject(r);
ctx.SaveChanges();
return 1;
}
catch
{
return 0;
}
}
}
示例6: DeleteT_WQX_USER_ORGS
public static int DeleteT_WQX_USER_ORGS(global::System.String oRG_ID, global::System.Int32 uSER_IDX)
{
using (OpenEnvironmentEntities ctx = new OpenEnvironmentEntities())
{
try
{
T_WQX_USER_ORGS r = new T_WQX_USER_ORGS();
r = (from c in ctx.T_WQX_USER_ORGS where c.USER_IDX == uSER_IDX && c.ORG_ID == oRG_ID select c).FirstOrDefault();
ctx.DeleteObject(r);
ctx.SaveChanges();
return 1;
}
catch
{
return 0;
}
}
}
示例7: DeleteT_WQX_RESULT
public static int DeleteT_WQX_RESULT(int ResultIDX)
{
using (OpenEnvironmentEntities ctx = new OpenEnvironmentEntities())
{
try
{
T_WQX_RESULT r = new T_WQX_RESULT();
r = (from c in ctx.T_WQX_RESULT where c.RESULT_IDX == ResultIDX select c).FirstOrDefault();
ctx.DeleteObject(r);
ctx.SaveChanges();
return 1;
}
catch
{
return 0;
}
}
}
示例8: DeleteT_OE_USERS
public static int DeleteT_OE_USERS(int idx)
{
using (OpenEnvironmentEntities ctx = new OpenEnvironmentEntities())
{
try
{
T_OE_USERS row = new T_OE_USERS();
row = (from c in ctx.T_OE_USERS where c.USER_IDX == idx select c).First();
ctx.DeleteObject(row);
ctx.SaveChanges();
return 1;
}
catch (Exception ex)
{
return 0;
}
}
}
示例9: DeleteT_VCCB_USER_ROLE
public static int DeleteT_VCCB_USER_ROLE(int UserIDX, int RoleIDX)
{
using (OpenEnvironmentEntities ctx = new OpenEnvironmentEntities())
{
try
{
T_OE_USER_ROLES row = new T_OE_USER_ROLES();
row = (from c in ctx.T_OE_USER_ROLES
where c.ROLE_IDX == RoleIDX && c.USER_IDX == UserIDX
select c).FirstOrDefault();
ctx.DeleteObject(row);
ctx.SaveChanges();
return 1;
}
catch (Exception ex)
{
return 0;
}
}
}