Ejemplo n.º 1
0
        private void UpdateSectionInfo(PageGroupInfo groupInfo)
        {
            PageSectionInfo newpageSections = groupInfo as PageSectionInfo;

            if (newpageSections != null)
            {
                SectionFilterCollectionWrapper scFilterWrapper = new SectionFilterCollectionWrapper();

                scFilterWrapper.ReportScType = newpageSections.SectionFilterWrapper.ReportScType;

                foreach (SectionFilter scFilter in   newpageSections.SectionFilterWrapper.SectionFilters)
                {
                    if (scFilter == null)
                    {
                        scFilterWrapper.SectionFilters.Add(scFilter);
                    }
                    else
                    {
                        SectionFilter newScFilter = new SectionFilter();

                        newScFilter.Apply(scFilter);

                        scFilterWrapper.SectionFilters.Add(newScFilter);
                    }
                }

                (groupInfo as PageSectionInfo).SectionFilterWrapper = scFilterWrapper;
            }
        }
Ejemplo n.º 2
0
        public void CreateRepeatGroupInfo()
        {
            if (!this.RepeatedReport)
            {
                this._RepeatGroupInfo = new PageFieldInfo("");

                return;
            }
            else if (this._RepeatFields.Count > 0)
            {
                this._RepeatGroupInfo = new PageFieldInfo((string)this._RepeatFields[0]);

                PageGroupInfo group = _RepeatGroupInfo;

                for (int i = 1; i < _RepeatFields.Count; i++)
                {
                    PageGroupInfo subgroup = new PageFieldInfo((string)this._RepeatFields[i]);

                    group.SubPageGroupInfos.Clear();

                    group.SubPageGroupInfos.Add(subgroup);

                    group = subgroup;
                }
            }
            else
            {
                this._RepeatGroupInfo = new PageSectionInfo(this.RepeatSectionFiltersWrapper);
            }
        }
Ejemplo n.º 3
0
        public void CreatePageGroupInfo()
        {
            if (!this.OneValuePerPage)
            {
                _OneValueGroupInfo = new PageFieldInfo("");

                return;
            }
            else if (GroupByField != null && this.GroupByField != string.Empty)
            {
                this._OneValueGroupInfo = new PageFieldInfo(this.GroupByField);
            }
            else if (this.GroupByFields.Count > 0)
            {
                this._OneValueGroupInfo = new PageFieldInfo((string)this.GroupByFields[0]);

                PageGroupInfo group = _OneValueGroupInfo;

                for (int i = 1; i < GroupByFields.Count; i++)
                {
                    PageGroupInfo subgroup = new PageFieldInfo((string)this.GroupByFields[i]);

                    group.SubPageGroupInfos.Clear();

                    group.SubPageGroupInfos.Add(subgroup);

                    group = subgroup;
                }
            }
            else
            {
                this._OneValueGroupInfo = new PageSectionInfo(this.GroupBySectionFiltersWrapper);
            }
        }
Ejemplo n.º 4
0
        public virtual PageGroupInfo Copy()
        {
            PageGroupInfo thiscopy = new PageGroupInfo();

            thiscopy._SortingType   = this._SortingType;
            thiscopy._SortingByType = this._SortingByType;
            thiscopy._GroupTitle    = this._GroupTitle;
            thiscopy._TopCount      = this._TopCount;
            if (_SubPageGroupInfos != null)
            {
                thiscopy._SubPageGroupInfos = this._SubPageGroupInfos.Copy();
            }
            thiscopy._ReportScType   = this._ReportScType;
            thiscopy._Filter         = this.Filter.Copy();
            thiscopy._Repeat         = this._Repeat;
            thiscopy.RepeatTitle     = this.RepeatTitle;
            thiscopy.SkippedCount    = this.SkippedCount;
            thiscopy._PageValueCount = this._PageValueCount;
            return(thiscopy);
        }
Ejemplo n.º 5
0
 public int Add(PageGroupInfo groupInfo)
 {
     return(this.InnerList.Add(groupInfo));
 }
Ejemplo n.º 6
0
        public PageGroupInfo(System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context)
        {
            try
            {
                _PageValueCount = info.GetInt32("_PageValueCount");
            }
            catch
            {
                _PageValueCount = 1;
            }
            try
            {
                _SortingType = (Webb.Reports.SortTypes)info.GetValue("_SortingType", typeof(Webb.Reports.SortTypes));
            }
            catch
            {
            }
            try
            {
                _SortingByType = (Webb.Reports.SortByTypes)info.GetValue("_SortingByType", typeof(Webb.Reports.SortByTypes));
            }
            catch
            {
            }
            try
            {
                _GroupTitle = info.GetString("_GroupTitle");
            }
            catch
            {
                _GroupTitle = string.Empty;
            }
            try
            {
                _SkippedCount = info.GetInt32("_SkippedCount");
            }
            catch
            {
                _SkippedCount = 0;
            }
            try
            {
                _TopCount = info.GetInt32("_TopCount");
            }
            catch
            {
                _TopCount = 0;
            }
            try
            {
                _Repeat = info.GetBoolean("_Repeat");
            }
            catch
            {
                _Repeat = false;
            }
            try
            {
                _RepeatTitle = info.GetString("_RepeatTitle");
            }
            catch
            {
                _RepeatTitle = string.Empty;
            }
            try
            {
                _SubPageGroupInfos = (Webb.Reports.PageGroupCollection)info.GetValue("_SubPageGroupInfos", typeof(Webb.Reports.PageGroupCollection));
            }
            catch
            {
            }
            try
            {
                _ParentPageGroupInfo = (Webb.Reports.PageGroupInfo)info.GetValue("_ParentPageGroupInfo", typeof(Webb.Reports.PageGroupInfo));
            }
            catch
            {
            }
            try
            {
                _ReportScType = (Webb.Reports.ReportScType)info.GetValue("_ReportScType", typeof(Webb.Reports.ReportScType));
            }
            catch
            {
            }
            try
            {
                _Filter = (Webb.Data.DBFilter)info.GetValue("_Filter", typeof(Webb.Data.DBFilter));

                this._Filter = AdvFilterConvertor.GetAdvFilter(DataProvider.VideoPlayBackManager.AdvReportFilters, this._Filter);                  //2009-4-29 11:37:37@Simon Add UpdateAdvFilter
            }
            catch
            {
                _Filter = new DBFilter();
            }
        }
Ejemplo n.º 7
0
        public void Apply(WebbReportTemplate template)
        {
            this._SectionFilters = template.SectionFilters.Copy();

            this._GroupByField = template.GroupByField;

            this._ReportScType = template.ReportScType;

            this._TopCount = template.TopCount;

            this._OnePageReport = template._OnePageReport;

            this._RepeatedReport = template.RepeatedReport;

            this._RepeatedWidth = template.RepeatedWidth;

            this._RepeatedHeight = template.RepeatedHeight;

            this._RepeatedCount = template._RepeatedCount;

            this._RepeatedVerticalCount = template.RepeatedVerticalCount;

            this.Filter = template.Filter.Copy();

            this._DiagramScoutType = template.DiagramScoutType;

            this.GroupByFields.Clear();
            foreach (object o in template.GroupByFields)
            {
                this.GroupByFields.Add(o);
            }

            this._GroupBySectionFilters = template.GroupBySectionFilters.Copy();

            this.RepeatFields.Clear();

            foreach (object o in template.RepeatFields)
            {
                this.RepeatFields.Add(o);
            }

            this.RepeatSectionFilters = template.RepeatSectionFilters.Copy();

            this._RepeatTopCount = template.RepeatTopCount;

            this.SectionFiltersWrapper = template.SectionFiltersWrapper;               //Modified at 2009-1-15 9:12:52@Scott

            this.GroupBySectionFiltersWrapper = template.GroupBySectionFiltersWrapper; //Modified at 2009-1-15 9:12:55@Scott

            this.RepeatSectionFiltersWrapper = template.RepeatSectionFiltersWrapper;   //Modified at 2009-1-15 9:12:58@Scott

            this.Consecutive = template.Consecutive;                                   //Modified at 2009-2-2 14:00:01@Scott

            this.AutoLayOut = template.AutoLayOut;                                     //Add at 2009-2-25 14:05:11@Simon

            this._FieldsGroupStyle = template._FieldsGroupStyle;                       //2009-3-4 14:37:40@Simon

            this._OneValueGroupInfo = template._OneValueGroupInfo;                     //2009-3-5 15:14:09@Simon

            this.LicenseLevel = template.LicenseLevel.Copy();                          //2009-6-15 10:57:48@Simon Add this Code

            if (ReportWizardSetting != null)
            {
                this._ReportWizardSetting = template.ReportWizardSetting.Copy();
            }
        }