本文整理汇总了C#中SO.SilList.Manager.DbContexts.MainDb类的典型用法代码示例。如果您正苦于以下问题:C# MainDb类的具体用法?C# MainDb怎么用?C# MainDb使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
MainDb类属于SO.SilList.Manager.DbContexts命名空间,在下文中一共展示了MainDb类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: count
public int count()
{
using (var db = new MainDb())
{
return db.images.Count();
}
}
示例2: count
public int count()
{
using (var db = new MainDb())
{
return db.propertyListingTypes.Count();
}
}
示例3: count
public int count()
{
using (var db = new MainDb())
{
return db.carModelTypes.Count();
}
}
示例4: count
public int count()
{
using (var db = new MainDb())
{
return db.businessServiceTypes.Count();
}
}
示例5: count
public int count()
{
using (var db = new MainDb())
{
return db.stateTypes.Count();
}
}
示例6: count
public int count()
{
using (var db = new MainDb())
{
return db.optionTypes.Count();
}
}
示例7: count
public int count()
{
using (var db = new MainDb())
{
return db.jobCategoryTypes.Count();
}
}
示例8: count
public int count()
{
using (var db = new MainDb())
{
return db.listingCategoryLookups.Count();
}
}
示例9: count
public int count()
{
using (var db = new MainDb())
{
return db.memberRoleLookups.Count();
}
}
示例10: count
public int count()
{
using (var db = new MainDb())
{
return db.listings.Count();
}
}
示例11: getFirst
/// <summary>
/// Get First Item
/// </summary>
public StateTypeVo getFirst()
{
using (var db = new MainDb())
{
var res = db.stateTypes
.FirstOrDefault();
return res;
}
}
示例12: getFirst
/// <summary>
/// Get First Item
/// </summary>
public MemberRoleLookupVo getFirst()
{
using (var db = new MainDb())
{
var res = db.memberRoleLookups
.FirstOrDefault();
return res;
}
}
示例13: get
/// <summary>
/// Find MemberRoleLookup matching the memberRoleLookupId (primary key)
/// </summary>
public MemberRoleLookupVo get(Guid memberRoleLookupId )
{
using (var db = new MainDb())
{
var res = db.memberRoleLookups
.FirstOrDefault(p => p.memberRoleLookupId == memberRoleLookupId);
return res;
}
}
示例14: delete
public bool delete(Guid memberRoleLookupId)
{
using (var db = new MainDb())
{
var res = db.memberRoleLookups
.Where(e => e.memberRoleLookupId == memberRoleLookupId)
.Delete();
return true;
}
}
示例15: get
/// <summary>
/// Find Member matching the memberId (primary key)
/// </summary>
public MemberVo get(int memberId )
{
using (var db = new MainDb())
{
var res = db.members
.FirstOrDefault(p => p.memberId == memberId);
return res;
}
}