public HistoryBySCartVM() { NumberOfMounths = "5"; SeriesCollection = new SeriesCollection(); HistoryBySCartM = new HistoryBySCartM(); YFormatter = value => value.ToString("C"); NumOfMonthsList = new ObservableCollection <string>(new Tools.MonthsListTool().GetNumOfMonthsList()); updateGraph(); }
public void updateGraph() { if (SeriesCollection == null) { return; } SeriesCollection.Clear(); SeriesCollection.Add(new LineSeries { Title = "סל הקניות שלך", Values = new ChartValues <double>(HistoryBySCartM.GetHistoryBySCart(Labels)), PointGeometry = DefaultGeometries.Circle, PointGeometrySize = 15 }); }