Hi
I tried to integrate Apexchart inside RAP.
Now it looks so
if anyone is interested, I can post it to the public
Project is small, without comments. and js files is magic for me till now
Dmitry
ApexLine chart = new ApexLine(parent, "line_stg");
LocalDateTime from = ShopRwt.getLocalDateMin(dateFrom).minusHours(1);
LocalDateTime till = ShopRwt.getLocalDateMax(dateTill).plusHours(25);
TResult rs = domain.equalsIgnoreCase("any") ? Global.appDB.getStatOccAll(objServer.getInt("ID"), MyShop.getEpochTime(from), MyShop.getEpochTime(till)) : Global.appDB.getStatOccDomain(objServer.getInt("ID"), domain, MyShop.getEpochTime(from), MyShop.getEpochTime(till));
LinkedHashMap<Long, Double> series = new LinkedHashMap<>();
for (TObject obj : rs) {
try {
series.put(obj.getEpochTime("SERVERTIME"), obj.getDouble("REPORTING_MB", 2) * 1024 * 1024); /
} catch (DateTimeParseException ignored) {
}
}
chart.getJson().addTimeSeries(domain, series);
chart.getJson().setTitle("Domain: " + domain, "center");
chart.show();
[Updated on: Mon, 21 June 2021 17:41]
Report message to a moderator