Skip to content

Commit

Permalink
add sante
Browse files Browse the repository at this point in the history
  • Loading branch information
thesam73 committed Aug 21, 2014
1 parent 0725ea3 commit 93c73ba
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 5 deletions.
7 changes: 6 additions & 1 deletion iou-meteor.css
Original file line number Diff line number Diff line change
Expand Up @@ -301,7 +301,9 @@ input#pass {
.class__car, .table__car .summary__progress__bar .progress-inner {
background-color: #34495e;
}

.class__sante, .table__sante .summary__progress__bar .progress-inner {
background-color: #E83F0C;
}
.table__rent {
color: #7f8c8d;
}
Expand All @@ -323,6 +325,9 @@ input#pass {
.table__car {
color: #34495e;
}
.table__sante {
color: #E83F0C;
}
button.remove {
background-color: rgba(231, 76, 60, 0);
background-image: none;
Expand Down
4 changes: 3 additions & 1 deletion iou-meteor.html
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@
<nav>
<ul>
<li id="btn__add" class="tab-current"><a class="btn__add icon-dialogue-add"><span>Add</span></a></li>
<li id="btn__current"><a class="icon-life-buoy"><span>Stats</span></a></li>
<li id="btn__current"><a class="icon-sinth"><span>Stats</span></a></li>
<li id="btn__stats"><a class="icon-graph"><span>Graphs</span></a></li>
<li id="btn__data"><a class="icon-todolist"><span>Data</span></a></li>
</ul>
Expand Down Expand Up @@ -117,6 +117,7 @@
<option value="shopping">Shopping</option>
<option value="activity">Activity</option>
<option value="car">Car</option>
<option value="sante">Sante</option>
</select>
<input class="input__date" type="date" id="timestamp">
</div>
Expand Down Expand Up @@ -192,6 +193,7 @@
<td class="class__shopping" style="width: {{shoppingMRatio}}%;"></td>
<td class="class__activity" style="width: {{activityMRatio}}%;"></td>
<td class="class__car" style="width: {{carMRatio}}%;"></td>
<td class="class__sante" style="width: {{santeMRatio}}%;"></td>
</tr></table>
</div>
<!-- <div class="chartdonut">
Expand Down
19 changes: 16 additions & 3 deletions iou-meteor.js
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,8 @@ function drawChartCurrent() {
{ Month: month, Category: "Supermarket", Amount: drawHelper('supermarket', month) },
{ Month: month, Category: "Shopping", Amount: drawHelper('shopping', month) },
{ Month: month, Category: "Activity", Amount: drawHelper('activity', month) },
{ Month: month, Category: "Car", Amount: drawHelper('car', month) });
{ Month: month, Category: "Car", Amount: drawHelper('car', month) },
{ Month: month, Category: "Sante", Amount: drawHelper('sante', month) });
}
var svg = dimple.newSvg("#chartContainer", 250, 500);
var myChart = new dimple.chart(svg, dataDimple);
Expand All @@ -102,7 +103,8 @@ function drawChartCurrent() {
new dimple.color("#00CCC1"),
new dimple.color("#9b59b6"),
new dimple.color("#e67e22"),
new dimple.color("#34495e")
new dimple.color("#34495e"),
new dimple.color("#E83F0C")
];
var x = myChart.addCategoryAxis("x", "Month");
x.addOrderRule("Month");
Expand Down Expand Up @@ -374,6 +376,13 @@ if (Meteor.isClient) {
category: "car",
ratio: monthlyCatRatio('car')
});
results.push({
icon: "icon-profile-remove",
table__name: "table__sante",
amount: monthlyCat('sante'),
category: "sante",
ratio: monthlyCatRatio('sante')
});
return results;
}
});
Expand All @@ -400,7 +409,9 @@ if (Meteor.isClient) {
Template.summary.carMRatio = function () {
return monthlyMratioCat('car');
}

Template.summary.carMRatio = function () {
return monthlyMratioCat('sante');
}


Template.navmenu.events = {
Expand Down Expand Up @@ -551,6 +562,7 @@ if (Meteor.isServer) {
shopping: anymonthmonthlytotalCat('shopping', month_start, month_end),
activity: anymonthmonthlytotalCat('activity', month_start, month_end),
car: anymonthmonthlytotalCat('car', month_start, month_end),
sante: anymonthmonthlytotalCat('sante', month_start, month_end),
total: anymonthmonthlytotal(month_start, month_end)
});
}
Expand All @@ -564,6 +576,7 @@ if (Meteor.isServer) {
shopping: anymonthmonthlytotalCat('shopping', month_start, month_end),
activity: anymonthmonthlytotalCat('activity', month_start, month_end),
car: anymonthmonthlytotalCat('car', month_start, month_end),
sante: anymonthmonthlytotalCat('sante', month_start, month_end),
total: anymonthmonthlytotal(month_start, month_end)
});
}
Expand Down

0 comments on commit 93c73ba

Please sign in to comment.