Merge pull request #69 from ksjdragon/AravTest

Aravtest
This commit is contained in:
Arav-Agarwal 2016-08-31 01:55:33 -04:00 committed by GitHub
commit cfef70b87f
5 changed files with 21 additions and 11 deletions

View File

@ -124,7 +124,7 @@ p.text {
}
.login-button {
display: none !important;
}
#github {

View File

@ -892,4 +892,5 @@ input, textarea {
#markDone:hover, #markConfirm:hover, #markReport:hover {
box-shadow: inset 0 0 0 99999px rgba(0,0,0,0.15);
}
}

View File

@ -177,11 +177,12 @@
</div>
<div id="markConfirm" style="color:{{work 'userConfirm'}}">
<i class="fa fa-thumbs-up" aria-hidden="true"></i>
<p>{{work 'confirmations'}}</p>
<p>{{work 'confirmationLength'}}</p>
</div>
<div id="markReport" style="color:{{work 'userReport'}}">
<i class="fa fa-thumbs-down" aria-hidden="true"></i>
<p>{{work 'reports'}}</p>
<p>{{work 'reportLength'}}</p>
</div>
</div>
</div>
@ -234,7 +235,13 @@
<div class="cWorkCont">
<p class="cWorkName">{{name}}</p>
<span class="cWorkDate" style="font-weight:{{cardDate}}">{{dueDate}}</span>
</div>
<div style="float:right">
<i class="fa fa-thumbs-up" aria-hidden="true"></i>
<span>{{confirmationLength}} </span>
<i class="fa fa-thumbs-down" aria-hidden="true"></i>
<span>{{reportLength}} </span>
</div>
</div>
</div>
</template>

View File

@ -93,7 +93,7 @@ Template.registerHelper('myClasses', () => { // Gets all classes and respective
array[i].thisClassWork = [];
continue;
}
for(var j = 0; j < thisWork.length; j++) { // For each work in class.
if(hide !== 0) { // Time to hide isn't never.
var due = (moment(thisWork[j].dueDate))["_d"];
@ -109,6 +109,7 @@ Template.registerHelper('myClasses', () => { // Gets all classes and respective
j = 0;
}
}
}
while(thisWork.indexOf("no") !== -1) thisWork.splice(thisWork.indexOf("no"),1); // Splice all filtered works.
@ -130,6 +131,9 @@ Template.registerHelper('myClasses', () => { // Gets all classes and respective
}
thisWork[j].typeColor = workColors[thisWork[j].type];
thisWork[j].confirmationLength = thisWork[j].confirmations.length // Counts the number of confiramtions and reportsfor a particular work
thisWork[j].reportLength = thisWork[j].reports.length
var hoverHighlight = Session.get("classDispHover"); // Highlight/scale related class works on hover.
if(hoverHighlight !== null && hoverHighlight === found._id) {
thisWork[j].scale = "-ms-transform: scale(1.12)-webkit-transform: scale(1.12);transform: scale(1.12)";
@ -564,7 +568,6 @@ Template.main.events({
input.style.width = "70%";
input.style.padding = "0.1%";
input.id = ele.id + "a";
input.setAttribute("opc", ele.getAttribute("opc"));
ele.parentNode.appendChild(input);
if (ele.getAttribute("re") == "readonly") {
input.readOnly = true;
@ -895,7 +898,7 @@ function formReadable(input) { // Makes work information readable by users.
}
if(input.confirmations.indexOf(Meteor.userId()) !== -1) { // If user confirmed.
input.userConfirm = "#27A127";
input.userConfirm = "#27A127";
} else {
input.userConfirm = "";
}
@ -906,8 +909,6 @@ function formReadable(input) { // Makes work information readable by users.
input.userReport = "";
}
input.confirmations = input.confirmations.length;
input.reports = input.reports.length;
var comments = input.comments;
var resort = [];

View File

@ -10,7 +10,8 @@ import {
var superadmins = [
"ybq987@gmail.com",
"ksjdragon@gmail.com"
"ksjdragon@gmail.com",
"aravagarwal3073@gmail.com"
];
var worktype = ["test", "quiz", "project", "normal", "other"];