本文整理汇总了C#中SnCore.WebServices.ServiceQueryOptions类的典型用法代码示例。如果您正苦于以下问题:C# ServiceQueryOptions类的具体用法?C# ServiceQueryOptions怎么用?C# ServiceQueryOptions使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
ServiceQueryOptions类属于SnCore.WebServices命名空间,在下文中一共展示了ServiceQueryOptions类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: gridManage_OnGetDataSource
void gridManage_OnGetDataSource(object sender, EventArgs e)
{
ServiceQueryOptions options = new ServiceQueryOptions();
options.PageSize = gridManage.PageSize;
options.PageNumber = gridManage.CurrentPageIndex;
gridManage.DataSource = SessionManager.AccountService.GetAllAccountRedirects(SessionManager.Ticket, options);
}
示例2: GetPublicAccountGroups
public List<TransitAccountGroup> GetPublicAccountGroups(string ticket, ServiceQueryOptions options)
{
ICriterion[] expressions = { Expression.Eq("IsPrivate", false) };
Order[] orders = { Order.Desc("Created") };
return WebServiceImpl<TransitAccountGroup, ManagedAccountGroup, AccountGroup>.GetList(
ticket, options, expressions, orders);
}
示例3: gridManage_OnGetDataSource
void gridManage_OnGetDataSource(object sender, EventArgs e)
{
ServiceQueryOptions options = new ServiceQueryOptions();
options.PageNumber = gridManage.CurrentPageIndex;
options.PageSize = gridManage.PageSize;
gridManage.DataSource = SessionManager.MarketingService.GetCampaigns(SessionManager.Ticket, options);
}
示例4: GetServiceQueryOptions
public ServiceQueryOptions GetServiceQueryOptions()
{
ServiceQueryOptions options = new ServiceQueryOptions();
options.PageNumber = Grid.CurrentPageIndex;
options.PageSize = Grid.PageSize;
return options;
}
示例5: gridManage_OnGetDataSource
void gridManage_OnGetDataSource(object sender, EventArgs e)
{
ServiceQueryOptions serviceoptions = new ServiceQueryOptions(gridManage.PageSize, gridManage.CurrentPageIndex);
gridManage.DataSource = SessionManager.GetCollection<TransitAccountGroup>(
serviceoptions, SessionManager.GroupService.GetAccountGroups);
panelLinks.Update();
}
示例6: PlaceWebsites_OnGetDataSource
void PlaceWebsites_OnGetDataSource(object sender, EventArgs e)
{
ServiceQueryOptions options = new ServiceQueryOptions(PlaceWebsites.PageSize, PlaceWebsites.CurrentPageIndex);
PlaceWebsites.DataSource = SessionManager.GetCollection<TransitPlaceWebsite, int>(
PlaceId, options, SessionManager.PlaceService.GetPlaceWebsites);
panelGrid.Update();
}
示例7: queue_OnGetDataSource
void queue_OnGetDataSource(object sender, EventArgs e)
{
ServiceQueryOptions options = new ServiceQueryOptions();
options.PageNumber = queue.CurrentPageIndex;
options.PageSize = queue.PageSize;
queue.DataSource = SessionManager.PlaceService.GetPlaceQueueItems(SessionManager.Ticket, RequestId, options);
}
示例8: gridManageFavorites_OnGetDataSource
void gridManageFavorites_OnGetDataSource(object sender, EventArgs e)
{
ServiceQueryOptions serviceoptions = new ServiceQueryOptions(
gridManageFavorites.PageSize, gridManageFavorites.CurrentPageIndex);
gridManageFavorites.DataSource = SessionManager.GetCollection<TransitPlace>(
serviceoptions, SessionManager.PlaceService.GetFavoritePlaces);
}
示例9: accountWebsites_OnGetDataSource
void accountWebsites_OnGetDataSource(object sender, EventArgs e)
{
ServiceQueryOptions options = new ServiceQueryOptions(accountWebsites.PageSize, accountWebsites.CurrentPageIndex);
accountWebsites.DataSource = SessionManager.GetCollection<TransitAccountWebsite, int>(
AccountId, options, SessionManager.AccountService.GetAccountWebsites);
panelGrid.Update();
}
示例10: Page_Load
public void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
int pagenumber = int.Parse(Request["PageNumber"]);
int pagecount = int.Parse(Request["PageCount"]);
int pagesize = int.Parse(Request["PageSize"]);
ServiceQueryOptions serviceoptions = new ServiceQueryOptions();
serviceoptions.PageSize = pagesize;
serviceoptions.PageNumber = pagenumber;
TransitAccountFeedQueryOptions options = new TransitAccountFeedQueryOptions();
gridManage.DataSource = SessionManager.SyndicationService.GetAccountFeeds(
SessionManager.Ticket, options, serviceoptions);
gridManage.DataBind();
if (pagenumber > 0)
linkPrev.HRef = string.Format("AccountFeedsViewList.aspx?PageNumber={0}&PageSize={1}&PageCount={2}",
pagenumber - 1, pagesize, pagecount);
if (pagenumber < pagecount - 1)
linkNext.HRef = string.Format("AccountFeedsViewList.aspx?PageNumber={0}&PageSize={1}&PageCount={2}",
pagenumber + 1, pagesize, pagecount);
}
}
示例11: Page_Load
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
ServiceQueryOptions options = new ServiceQueryOptions();
options.PageNumber = 0;
options.PageSize = 10;
// get new members
rssRepeaterMembers.DataSource = SessionManager.GetCollection<TransitAccountGroupAccount, int>(
AccountGroupId, options, SessionManager.GroupService.GetAccountGroupAccounts);
rssRepeaterMembers.DataBind();
// get new places
rssRepeaterPlaces.DataSource = SessionManager.GetCollection<TransitAccountGroupPlace, int>(
AccountGroupId, options, SessionManager.GroupService.GetAccountGroupPlaces);
rssRepeaterPlaces.DataBind();
// get new discussion posts
discussionsRss.ObjectId = RequestId;
discussionsRss.Type = "AccountGroup";
// get new blog posts
if (AccountGroup.AccountBlogId > 0)
{
rssRepeaterBlogItems.DataSource = SessionManager.GetCollection<TransitAccountBlogPost, TransitAccountBlogPostQueryOptions>(
GetBlogPostsOptions(), options, SessionManager.BlogService.GetAccountBlogPosts);
rssRepeaterBlogItems.DataBind();
}
}
}
示例12: GetAccountBlogs
public List<TransitAccountBlog> GetAccountBlogs(string ticket, int id, ServiceQueryOptions options)
{
ICriterion[] expression = { Expression.Eq("Account.Id", id) };
Order[] orders = { Order.Desc("Created") };
return WebServiceImpl<TransitAccountBlog, ManagedAccountBlog, AccountBlog>.GetList(
ticket, options, expression, orders);
}
示例13: GetData
private void GetData()
{
ServiceQueryOptions serviceoptions = new ServiceQueryOptions();
serviceoptions.PageSize = accounts.RepeatColumns;
// accounts
accounts.DataSource = SessionManager.GetCollection<TransitFeature, string>(
"Account", serviceoptions, SessionManager.ObjectService.GetFeatures);
accounts.DataBind();
// places
places.DataSource = SessionManager.GetCollection<TransitFeature, string>(
"Place", serviceoptions, SessionManager.ObjectService.GetFeatures);
places.DataBind();
// feeds
accountfeeds.DataSource = SessionManager.GetCollection<TransitFeature, string>(
"AccountFeed", serviceoptions, SessionManager.ObjectService.GetFeatures);
accountfeeds.DataBind();
// events
TransitAccountEventInstanceQueryOptions eventoptions = new TransitAccountEventInstanceQueryOptions();
eventoptions.StartDateTime = DateTime.UtcNow;
eventoptions.EndDateTime = DateTime.MaxValue;
accountevents.DataSource = SessionManager.GetCollection<TransitAccountEventInstance, TransitAccountEventInstanceQueryOptions>(
eventoptions, serviceoptions, SessionManager.EventService.GetAccountEventInstances);
accountevents.DataBind();
}
示例14: placesList_OnGetDataSource
void placesList_OnGetDataSource(object sender, EventArgs e)
{
ServiceQueryOptions options = new ServiceQueryOptions(placesList.PageSize, placesList.CurrentPageIndex);
placesList.DataSource = SessionManager.GetCollection<TransitAccountPlace, int>(
AccountId, options, SessionManager.PlaceService.GetAccountPlaces);
panelGrid.Update();
}
示例15: GetReplies
public string GetReplies(int post_id, int thread_id)
{
StringBuilder result = new StringBuilder();
ServiceQueryOptions options = new ServiceQueryOptions();
options.PageNumber = 0;
options.PageSize = 3;
IList<TransitDiscussionPost> items = SessionManager.GetCollection<TransitDiscussionPost, int>(
thread_id, options, SessionManager.DiscussionService.GetDiscussionThreadPostsByOrder);
foreach (TransitDiscussionPost t_instance in items)
{
if (t_instance.Id == post_id)
continue;
result.Append(string.Format("<div>» <b>{0}</b> replied {1}</a></div>",
Renderer.Render(t_instance.AccountName),
SessionManager.ToAdjustedString(t_instance.Created)));
}
if (result.Length > 0)
{
result.Insert(0, "<div class=\"sncore_message_reply\">");
result.Append("</div>");
}
return result.ToString();
}