Ejemplo n.º 1
0
        public void PrepareWebFields(AvrPivotSettings pivotSettings)
        {
            //fill lookups for pivot header
            pivotSettings.Intervals         = GroupIntervalHelper.GetGroupIntervalLookup();
            pivotSettings.AggregateFuncions = GetAggregateFunctionsView();
            foreach (WebPivotGridField webField in pivotSettings.Fields)
            {
                if (webField.IsHiddenFilterField)
                {
                    webField.Visible = true;
                    //We set webField.Tag = true for all hidden fields
                    //to override PivotGridField.CanShowInPrefilter property that operates correctly with original propertied only.
                    webField.Tag             = true;
                    webField.SearchFieldType = GetSearchFieldType(webField);
                    //SetLookupValues(webField);
                }

                if (webField.IsDateTimeField && webField.GroupInterval == PivotGroupInterval.Default)
                {
                    webField.DefaultGroupInterval = GroupIntervalHelper.GetGroupInterval(pivotSettings.DefaultGroupInterval);
                }

//                PivotSummaryType summaryType = webField.CustomSummaryType == CustomSummaryType.Count
//                   ? PivotSummaryType.Count
//                   : PivotSummaryType.Custom;
//                webField.SummaryType = summaryType;
            }
        }