mirror of
https://github.com/ankitects/anki.git
synced 2025-09-25 01:06:35 -04:00
Revert "addded cumulative graph on main screen"
This reverts commit 1f1fa4824a052a9446dfce78485c456263242e2a.
This commit is contained in:
parent
d6275d94c5
commit
fb0a0d5bdb
1 changed files with 3 additions and 12 deletions
|
@ -94,11 +94,9 @@ $(function () {
|
||||||
var d = %(fcdata)s;
|
var d = %(fcdata)s;
|
||||||
if (d) {
|
if (d) {
|
||||||
$.plot($("#placeholder"), [
|
$.plot($("#placeholder"), [
|
||||||
{ data: d[0], bars: { show: true, barWidth: 0.8, align:"center" }, color: "#0c0"},
|
{ data: d, bars: { show: true, barWidth: 0.8 }, color: "#0c0" }
|
||||||
{ data: d[1], color: "#000", lines: { show: true }, yaxis: 2 }
|
|
||||||
], {
|
], {
|
||||||
xaxis: { ticks: [[0, "Today"], [6, "7 days"], [13, "14 days"]] },
|
xaxis: { ticks: [[0.4, "Today"]] }
|
||||||
yaxes: [{}, {position: "right"}]
|
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
$("#placeholder").hide();
|
$("#placeholder").hide();
|
||||||
|
@ -169,14 +167,7 @@ $(function () {
|
||||||
fc = self.mw.deck.sched.dueForecast(14)
|
fc = self.mw.deck.sched.dueForecast(14)
|
||||||
if not sum(fc):
|
if not sum(fc):
|
||||||
return "''"
|
return "''"
|
||||||
tot = 0
|
return simplejson.dumps(tuple(enumerate(fc)))
|
||||||
repd = []
|
|
||||||
totd = []
|
|
||||||
for (c, cnt) in enumerate(fc):
|
|
||||||
tot += cnt
|
|
||||||
repd.append((c, cnt))
|
|
||||||
totd.append((c, tot))
|
|
||||||
return simplejson.dumps([repd, totd])
|
|
||||||
|
|
||||||
# Toolbar
|
# Toolbar
|
||||||
##########################################################################
|
##########################################################################
|
||||||
|
|
Loading…
Reference in a new issue