本文整理汇总了C#中ASC.Common.Data.Sql.Expressions.Exp类的典型用法代码示例。如果您正苦于以下问题:C# Exp类的具体用法?C# Exp怎么用?C# Exp使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
Exp类属于ASC.Common.Data.Sql.Expressions命名空间,在下文中一共展示了Exp类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。
示例1: Junction
private static Exp Junction(Exp exp1, Exp exp2, bool and)
{
if (exp1 == null && exp2 == null) return null;
if (exp1 == null) return exp2;
if (exp2 == null) return exp1;
return new JunctionExp(exp1, exp2, and);
}
开发者ID:vipwan,项目名称:CommunityServer,代码行数:7,代码来源:Exp.cs
示例2: GetFiles
private List<File> GetFiles(Exp where)
{
var q = Query("wiki_files")
.Select("filename", "uploadfilename", "version", "userid", "date", "filelocation", "filesize")
.Where(where)
.OrderBy("filename", true);
return db
.ExecuteList(q)
.ConvertAll(r => ToFile(r))
.GroupBy(f => f.FileName)
.Select(g => g.OrderByDescending(f => f.Version).First())
.ToList();
}
开发者ID:ridhouan,项目名称:teamlab.v6.5,代码行数:14,代码来源:FileDAO.cs
示例3: GetAccountQuery
private SqlQuery GetAccountQuery(Exp where)
{
SqlQuery sqlQuery = Query("sm_facebookaccounts")
.Select(
"access_token",
"user_id",
"associated_id",
"user_name"
);
if (where != null)
sqlQuery.Where(where);
return sqlQuery;
}
开发者ID:Inzaghi2012,项目名称:teamlab.v7.5,代码行数:15,代码来源:FacebookAccountInfoDao.cs
示例4: GetSqlQuery
private SqlQuery GetSqlQuery(Exp where)
{
var sqlQuery = new SqlQuery("crm_currency_info")
.Select("resource_key",
"abbreviation",
"symbol",
"culture_name",
"is_convertable",
"is_basic");
if (where != null)
sqlQuery.Where(where);
return sqlQuery;
}
开发者ID:vipwan,项目名称:CommunityServer,代码行数:15,代码来源:CurrencyInfoDao.cs
示例5: GetAccountQuery
private SqlQuery GetAccountQuery(Exp where)
{
SqlQuery sqlQuery = Query("sm_twitteraccounts")
.Select(
"access_token",
"access_token_secret",
"screen_name",
"user_id",
"associated_id",
"user_name"
);
if (where != null)
sqlQuery.Where(where);
return sqlQuery;
}
开发者ID:haoasqui,项目名称:ONLYOFFICE-Server,代码行数:17,代码来源:TwitterAccountInfoDao.cs
示例6: GetTenantQuotas
private IEnumerable<TenantQuota> GetTenantQuotas(Exp where)
{
var q = new SqlQuery(tenants_quota)
.Select("tenant", "name", "description", "max_file_size", "max_total_size", "active_users", "features", "price", "avangate_id")
.Where(where);
return ExecList(q)
.ConvertAll(r => new TenantQuota(Convert.ToInt32(r[0]))
{
Name = (string)r[1],
Desc = (string)r[2],
MaxFileSize = GetInBytes(Convert.ToInt64(r[3])),
MaxTotalSize = GetInBytes(Convert.ToInt64(r[4])),
ActiveUsers = Convert.ToInt32(r[5]) != 0 ? Convert.ToInt32(r[5]) : int.MaxValue,
Features = (string)r[6],
Price = Convert.ToDecimal(r[7]),
AvangateId = (string)r[8],
});
}
开发者ID:ridhouan,项目名称:teamlab.v6.5,代码行数:19,代码来源:DbQuotaService.cs
示例7: GetMailTags
private List<MailTag> GetMailTags(int id_tenant, string id_user, Exp exp)
{
using (var db = GetDb())
{
return GetMailTags(db, id_tenant, id_user, exp);
}
}
开发者ID:Inzaghi2012,项目名称:teamlab.v7.5,代码行数:7,代码来源:MailBoxManager.Tags.cs
示例8: GetListItemSqlQuery
private SqlQuery GetListItemSqlQuery(Exp where)
{
var result = Query("crm_list_item")
.Select(
"id",
"title",
"description",
"color",
"sort_order",
"additional_params",
"list_type"
);
if (where != null)
result.Where(where);
return result;
}
开发者ID:Inzaghi2012,项目名称:teamlab.v7.5,代码行数:19,代码来源:ListItemDao.cs
示例9: GetTaskQuery
private SqlQuery GetTaskQuery(Exp where)
{
return GetTaskQuery(where, String.Empty);
}
开发者ID:haoasqui,项目名称:ONLYOFFICE-Server,代码行数:5,代码来源:TaskDao.cs
示例10: GetInvoiceSqlQuery
private SqlQuery GetInvoiceSqlQuery(Exp where, String alias)
{
var sqlQuery = Query("crm_invoice");
if (!String.IsNullOrEmpty(alias))
{
sqlQuery = new SqlQuery(String.Concat("crm_invoice ", alias))
.Where(Exp.Eq(alias + ".tenant_id", TenantID));
sqlQuery.Select(GetInvoiceColumnsTable(alias));
}
else
{
sqlQuery.Select(GetInvoiceColumnsTable(String.Empty));
}
if (where != null)
sqlQuery.Where(where);
return sqlQuery;
}
开发者ID:haoasqui,项目名称:ONLYOFFICE-Server,代码行数:21,代码来源:InvoiceDao.cs
示例11: GetRelationshipEventQuery
private SqlQuery GetRelationshipEventQuery(Exp where)
{
SqlQuery sqlQuery = Query("crm_relationship_event")
.Select("id",
"contact_id",
"content",
"entity_id",
"entity_type",
"create_on",
"create_by",
"category_id"
);
if (where != null)
sqlQuery.Where(where);
return sqlQuery;
}
开发者ID:vipwan,项目名称:CommunityServer,代码行数:18,代码来源:RelationshipEventDao.cs
示例12: Or
public static Exp Or(Exp exp1, Exp exp2)
{
return Junction(exp1, exp2, false);
}
开发者ID:vipwan,项目名称:CommunityServer,代码行数:4,代码来源:Exp.cs
示例13: Where
public SqlUpdate Where(Exp where)
{
this.where = this.where & where;
return this;
}
开发者ID:Inzaghi2012,项目名称:teamlab.v7.5,代码行数:5,代码来源:SqlUpdate.cs
示例14: GetContactSqlQuery
private SqlQuery GetContactSqlQuery(Exp where)
{
return GetContactSqlQuery(where, String.Empty);
}
开发者ID:ridhouan,项目名称:teamlab.v6.5,代码行数:5,代码来源:ContactDao.cs
示例15: Where
public SqlDelete Where(Exp where)
{
this.where = this.where & where;
return this;
}
开发者ID:haoasqui,项目名称:ONLYOFFICE-Server,代码行数:5,代码来源:SqlDelete.cs
示例16: GetFieldDescriptionSqlQuery
private SqlQuery GetFieldDescriptionSqlQuery(Exp where)
{
var sqlQuery = Query("crm_field_description")
.Select("id",
"-1",
"label",
"' '",
"type",
"sort_order",
"mask",
"entity_type")
.OrderBy("sort_order", true);
if (where != null)
sqlQuery.Where(where);
return sqlQuery;
}
开发者ID:vlslavik,项目名称:teamlab.v7.5,代码行数:18,代码来源:CustomFieldDao.cs
示例17: GetFolderQuery
protected SqlQuery GetFolderQuery(Exp where)
{
return Query("files_folder f")
.Select("f.id")
.Select("f.parent_id")
.Select("f.title")
.Select("f.create_on")
.Select("f.create_by")
.Select("f.modified_on")
.Select("f.modified_by")
.Select("f.folder_type")
.Select("f.foldersCount")
.Select("f.filesCount")
.Select(GetRootFolderType("parent_id"))
.Select(Exp.Exists(GetSharedQuery(FileEntryType.Folder)))
.Where(@where);
}
开发者ID:vipwan,项目名称:CommunityServer,代码行数:17,代码来源:FolderDao.cs
示例18: GetCasesSqlQuery
private SqlQuery GetCasesSqlQuery(Exp where)
{
var sqlQuery = Query("crm_case")
.Select("id", "title", "create_by", "create_on", "is_closed");
if (where != null)
{
sqlQuery.Where(where);
}
return sqlQuery;
}
开发者ID:vipwan,项目名称:CommunityServer,代码行数:12,代码来源:CasesDao.cs
示例19: GetFeedCommentQuery
private SqlQuery GetFeedCommentQuery(Exp where)
{
return Query("events_comment").Select("Id", "Feed", "Comment", "Parent", "Date", "Creator", "Inactive").Where(where);
}
开发者ID:haoasqui,项目名称:ONLYOFFICE-Server,代码行数:4,代码来源:DbFeedStorage.cs
示例20: GetInvoiceLineSqlQuery
private SqlQuery GetInvoiceLineSqlQuery(Exp where)
{
var sqlQuery = Query("crm_invoice_line")
.Select(
"id",
"invoice_id",
"invoice_item_id",
"invoice_tax1_id",
"invoice_tax2_id",
"sort_order",
"description",
"quantity",
"price",
"discount");
if (where != null)
{
sqlQuery.Where(where);
}
return sqlQuery;
}
开发者ID:haoasqui,项目名称:ONLYOFFICE-Server,代码行数:22,代码来源:InvoiceLineDao.cs
注:本文中的ASC.Common.Data.Sql.Expressions.Exp类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论