Ejemplo n.º 1
0
 public CartesianChartModel getLinearModel() {
   linearModel = new CartesianChartModel();
   LineChartSeries series = new LineChartSeries();
   series.setLabel("amount");
   List<AccountInfo> accountHistory = accountService.getFindLasts(100);
   int serieNo = 100;
   for (AccountInfo account : accountHistory) {
     series.set(serieNo--, account.getNetLiquidation());
   }
   linearModel.addSeries(series);
   BigDecimal net = accountService.getLastAccountInfo().getNetLiquidation();
   linearMax = net.add(new BigDecimal(500)).intValue();
   linearMin = net.subtract(new BigDecimal(500)).intValue();
   return linearModel;
 }
Ejemplo n.º 2
0
 public List<AccountInfo> getAccountData() {
   List<AccountInfo> accounts = accountService.getFindLasts(5);
   return accounts;
 }
Ejemplo n.º 3
0
 public MeterGaugeChartModel getMeterGaugeModel() {
   meterGaugeModel =
       (new MeterGaugeChartModel(
           "$", accountService.getLastAccountInfo().getNetLiquidation(), intervals));
   return meterGaugeModel;
 }
Ejemplo n.º 4
0
 public AccountInfo getAccountInfoLast() {
   if (accountInfoLast == null) {
     accountInfoLast = accountService.getLastAccountInfo();
   }
   return accountInfoLast;
 }