示例#1
0
        private IDictionary <string, List <object> > GetColumnValues()
        {
            Dictionary <string, List <object> > dict = new Dictionary <string, List <object> >();

            dict.Add("Issues", TopGrid.Where(t => t.IsParent == 1).Select(t => t.Issues).Cast <object>().ToList());
            dict.Add("IssuesAmount", TopGrid.Where(t => t.IsParent == 1).Select(t => t.IssuesAmount).Cast <object>().ToList());
            return(dict);
        }
示例#2
0
        /// <summary>
        /// Initial chart
        /// </summary>
        /// <returns></returns>
        public ChartViewModel InitialChart(string reportName, string unit)
        {
            Chart = new ChartViewModel();
            Chart.StatisticalAspects = GetStatisticalAspects();
            Chart.ColumnValues       = GetColumnValues();
            Chart.ColumnName         = Resources.Global.BondIssue_Issue_Amt; // need to modify
            Chart.ReportId           = ID;
            Chart.DataCategories     = TopGrid.Select(t => t.TypeName == null ? Resources.Global.Tip_Other : t.TypeName).Cast <object>().ToList();

            Chart.IsTop            = true;
            Chart.ChartTypeOptions = new List <string>
            {
                Resources.Global.ChatType_Column,
                Resources.Global.ChatType_Bar,
                Resources.Global.ChatType_Pie
            };
            Chart.Unit  = unit;
            Chart.Title = reportName;
            return(Chart);
        }