Display who's done, fixed #46
This commit is contained in:
parent
5f186e55fc
commit
202df284a3
@ -825,6 +825,25 @@ input, textarea {
|
|||||||
|
|
||||||
#done {
|
#done {
|
||||||
height: 60%;
|
height: 60%;
|
||||||
|
top: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.doneUser {
|
||||||
|
padding: 12%;
|
||||||
|
background-color: rgba(0,0,0,0.1);
|
||||||
|
|
||||||
|
-webkit-transition: background-color 0.4s ease;
|
||||||
|
-moz-transition: background-color 0.4s ease;
|
||||||
|
-ms-transition: background-color 0.4s ease;
|
||||||
|
transition: background-color 0.4s ease;
|
||||||
|
}
|
||||||
|
|
||||||
|
.doneUser:hover {
|
||||||
|
background-color: rgba(0,0,0,0.15);
|
||||||
|
}
|
||||||
|
|
||||||
|
.doneUser p {
|
||||||
|
margin: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
#toggleButtons {
|
#toggleButtons {
|
||||||
|
|||||||
@ -165,9 +165,12 @@
|
|||||||
</div>
|
</div>
|
||||||
<div id="workToggle">
|
<div id="workToggle">
|
||||||
<div id="done">
|
<div id="done">
|
||||||
|
{{#each work 'done'}}
|
||||||
|
{{> doneUsers}}
|
||||||
|
{{/each}}
|
||||||
</div>
|
</div>
|
||||||
<div id="toggleButtons">
|
<div id="toggleButtons">
|
||||||
<div id="markDone" style="background-color:{{work 'done'}}">
|
<div id="markDone" style="background-color:{{work 'doneCol'}}">
|
||||||
<i class="fa fa-check-square-o" aria-hidden="true"></i>
|
<i class="fa fa-check-square-o" aria-hidden="true"></i>
|
||||||
<p>{{work 'doneText'}}</p>
|
<p>{{work 'doneText'}}</p>
|
||||||
</div>
|
</div>
|
||||||
@ -240,3 +243,9 @@
|
|||||||
<span class="commentDate">{{date}}</span>
|
<span class="commentDate">{{date}}</span>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
<template name="doneUsers">
|
||||||
|
<div class="doneUser">
|
||||||
|
<p>{{user}}</p>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
@ -939,13 +939,17 @@ function formReadable(input) {
|
|||||||
input.type = input.type[0].toUpperCase() + input.type.slice(1);
|
input.type = input.type[0].toUpperCase() + input.type.slice(1);
|
||||||
|
|
||||||
if(input.done.indexOf(Meteor.userId()) !== -1) {
|
if(input.done.indexOf(Meteor.userId()) !== -1) {
|
||||||
input.done = "#27A127";
|
input.doneCol = "#27A127";
|
||||||
input.doneText = "Done!";
|
input.doneText = "Done!";
|
||||||
} else {
|
} else {
|
||||||
input.done = "";
|
input.doneCol = "";
|
||||||
input.doneText = "Mark done";
|
input.doneText = "Mark done";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
for(var i = 0; i < input.done.length; i++) {
|
||||||
|
input.done[i] = {"user":Meteor.users.findOne({_id:input.done[i]}).profile.name};
|
||||||
|
}
|
||||||
|
|
||||||
if(input.confirmations.indexOf(Meteor.userId()) !== -1) {
|
if(input.confirmations.indexOf(Meteor.userId()) !== -1) {
|
||||||
input.userConfirm = "#27A127";
|
input.userConfirm = "#27A127";
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user