示例#1
0
 public string GetEntryCountByFormId(string formHash, FilterBuilder filters)
 {
     string url = _baseUrl + "forms/{0}/entries/count.json".FormatWith(formHash);
     var param = new Dictionary<string, object>();
     foreach (var kvp in GetQueryParams(filters))
     {
         param[kvp.Key] = kvp.Value;
     }
     return GetData(url, param);
 }
示例#2
0
 public ReportEntryEnumerator(IWufooDataProvider provider, string reportHash, int pageSize, int pageStart, FilterBuilder filters, Sort sort)
     : base(provider, reportHash, pageSize, pageStart, filters, sort)
 {
 }
示例#3
0
 public string GetEntriesByReportId(string reportHash, int pageStart, int pageSize, FilterBuilder filters, Sort sort)
 {
     string url = _baseUrl + "reports/{0}/entries.json".FormatWith(reportHash);
     return GetEntries(url, pageStart, pageSize, filters, sort);
 }
示例#4
0
 private IEnumerable<KeyValuePair<string, object>> GetQueryParams(FilterBuilder filterBuilder)
 {
     Dictionary<string, object> param = new Dictionary<string, object>();
     var filters = (filterBuilder ?? new FilterBuilder()).GetFilters();
     for (int i = 0; i < filters.Length; i++)
     {
         param["Filter" + (i+1)] = filters[i].ToString();
     }
     return param;
 }
示例#5
0
 private string GetEntries(string url, int pageStart, int pageSize, FilterBuilder filters, Sort sort)
 {
     Dictionary<string, object> param = new Dictionary<string, object>() { { "pageStart", pageStart }, { "pageSize", pageSize } };
     foreach (var kvp in GetQueryParams(sort))
     {
         param[kvp.Key] = kvp.Value;
     }
     foreach (var kvp in GetQueryParams(filters))
     {
         param[kvp.Key] = kvp.Value;
     }
     return GetData(url, param);
 }
示例#6
0
 public EntryEnumerator(IWufooDataProvider provider, string formHash, int pageSize, int pageStart, FilterBuilder filters, Sort sort)
 {
     Provider   = provider;
     FormHash   = formHash;
     PageSize   = pageSize;
     _pageStart = pageStart;
     Filters    = filters;
     Sort       = sort;
 }
 public FormEntryEnumerator(IWufooDataProvider provider, string formHash, int pageSize, int pageStart, FilterBuilder filters, Sort sort)
     : base(provider, formHash, pageSize, pageStart, filters, sort)
 {
 }