Merge branch 'master' of https://github.com/ksjdragon/hourglass
@ -35,3 +35,5 @@ http@1.2.9
|
|||||||
underscore
|
underscore
|
||||||
houston:admin
|
houston:admin
|
||||||
ahref:dragula
|
ahref:dragula
|
||||||
|
harrison:papa-parse
|
||||||
|
pfafman:filesaver
|
||||||
|
|||||||
@ -42,6 +42,7 @@ fastclick@1.0.12
|
|||||||
fortawesome:fontawesome@4.5.0
|
fortawesome:fontawesome@4.5.0
|
||||||
geojson-utils@1.0.9
|
geojson-utils@1.0.9
|
||||||
google@1.1.14
|
google@1.1.14
|
||||||
|
harrison:papa-parse@1.1.1
|
||||||
hot-code-push@1.0.4
|
hot-code-push@1.0.4
|
||||||
houston:admin@2.0.7
|
houston:admin@2.0.7
|
||||||
html-tools@1.0.10
|
html-tools@1.0.10
|
||||||
@ -84,6 +85,7 @@ oauth2@1.1.10
|
|||||||
observe-sequence@1.0.12
|
observe-sequence@1.0.12
|
||||||
ongoworks:security@2.0.1
|
ongoworks:security@2.0.1
|
||||||
ordered-dict@1.0.8
|
ordered-dict@1.0.8
|
||||||
|
pfafman:filesaver@1.3.2
|
||||||
promise@0.8.4
|
promise@0.8.4
|
||||||
proyk:meteor-cookies@0.0.1
|
proyk:meteor-cookies@0.0.1
|
||||||
random@1.0.10
|
random@1.0.10
|
||||||
|
|||||||
@ -285,7 +285,7 @@ input, textarea {
|
|||||||
transition: box-shadow 0.2s ease;
|
transition: box-shadow 0.2s ease;
|
||||||
}
|
}
|
||||||
|
|
||||||
.fa-university, .fa-calendar {
|
.fa-university, .fa-calendar, .fa-download {
|
||||||
font-size: 175%;
|
font-size: 175%;
|
||||||
width: 12%;
|
width: 12%;
|
||||||
padding: 10%;
|
padding: 10%;
|
||||||
@ -302,6 +302,19 @@ input, textarea {
|
|||||||
filter: drop-shadow(2px 2px 5px #666);
|
filter: drop-shadow(2px 2px 5px #666);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#exportText {
|
||||||
|
display: inline;
|
||||||
|
}
|
||||||
|
|
||||||
|
.fa-download {
|
||||||
|
padding: 0%;
|
||||||
|
}
|
||||||
|
|
||||||
|
#exportDiv {
|
||||||
|
position: absolute;
|
||||||
|
bottom: 9%;
|
||||||
|
}
|
||||||
|
|
||||||
#functions {
|
#functions {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
margin-top: 7%;
|
margin-top: 7%;
|
||||||
|
|||||||
@ -54,9 +54,15 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
|
||||||
|
<div id="exportDiv" class="sideFilter">
|
||||||
|
<i id="export" class="fa fa-download" aria-hidden="true"></i>
|
||||||
|
<h4 id="exportText">Export</h4>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div id="optionsContainer" style="right:{{optionsStatus}};background-color:{{divColor 'sidebar'}}">
|
<div id="optionsContainer" style="right:{{optionsStatus}};background-color:{{divColor 'sidebar'}}">
|
||||||
<h3>Preferences</h3>
|
<h3>Preferences</h3>
|
||||||
|
|
||||||
<div id="prefCont">
|
<div id="prefCont">
|
||||||
<div>
|
<div>
|
||||||
<div class="inputRadioPref">
|
<div class="inputRadioPref">
|
||||||
|
|||||||
@ -769,6 +769,33 @@ Template.main.events({
|
|||||||
text.style.display = "initial";
|
text.style.display = "initial";
|
||||||
text.style.color = "#7E7E7E";
|
text.style.color = "#7E7E7E";
|
||||||
},
|
},
|
||||||
|
'click #exportDiv' (event) {
|
||||||
|
var events = [];
|
||||||
|
var userClasses = Session.get("calendarClasses");
|
||||||
|
|
||||||
|
for (var i = 0; i < userClasses.length; i++) {
|
||||||
|
var works = userClasses[i].thisClassWork;
|
||||||
|
for (var j = 0; j < works.length; j++) {
|
||||||
|
var work = works[j];
|
||||||
|
var workclass = classes.findOne({_id: work.class});
|
||||||
|
if (work.description == defaultWork.description) work.description = "";
|
||||||
|
if (work.dueDate == defaultWork.dueDate) continue;
|
||||||
|
if (work.name == defaultWork.name) work.name = "";
|
||||||
|
if (workclass === undefined) workclass = {name: "Personal"};
|
||||||
|
events.push([
|
||||||
|
workclass.name + ": " + work.name,
|
||||||
|
work.realDate.toLocaleDateString(),
|
||||||
|
work.description,
|
||||||
|
"True"
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
var JSONevents = JSON.stringify(events);
|
||||||
|
var CSVevents = Papa.unparse({fields: ["Subject", "Start Date", "Description", "All Day Event"], data: JSONevents});
|
||||||
|
var eventBlob = new Blob([CSVevents], {type: "data:text/csv;charset=utf-8"});
|
||||||
|
saveAs(eventBlob, "hourglass.csv");
|
||||||
|
},
|
||||||
'keydown input' (event) { // Enter to close input.
|
'keydown input' (event) { // Enter to close input.
|
||||||
var modifyingInput = Session.get("modifying");
|
var modifyingInput = Session.get("modifying");
|
||||||
if (event.keyCode == 13 && modifyingInput != "workDesc") {
|
if (event.keyCode == 13 && modifyingInput != "workDesc") {
|
||||||
|
|||||||
BIN
hourglass/public/icons/license/license.pdf
Normal file
BIN
hourglass/public/icons/png/animal.png
Normal file
|
After Width: | Height: | Size: 23 KiB |
BIN
hourglass/public/icons/png/avatar.png
Normal file
|
After Width: | Height: | Size: 10 KiB |
BIN
hourglass/public/icons/png/book-1.png
Normal file
|
After Width: | Height: | Size: 5.2 KiB |
BIN
hourglass/public/icons/png/book-2.png
Normal file
|
After Width: | Height: | Size: 11 KiB |
BIN
hourglass/public/icons/png/book-3.png
Normal file
|
After Width: | Height: | Size: 7.1 KiB |
BIN
hourglass/public/icons/png/book-4.png
Normal file
|
After Width: | Height: | Size: 4.8 KiB |
BIN
hourglass/public/icons/png/book-5.png
Normal file
|
After Width: | Height: | Size: 8.4 KiB |
BIN
hourglass/public/icons/png/book-6.png
Normal file
|
After Width: | Height: | Size: 5.3 KiB |
BIN
hourglass/public/icons/png/book-7.png
Normal file
|
After Width: | Height: | Size: 1.4 KiB |
BIN
hourglass/public/icons/png/book-8.png
Normal file
|
After Width: | Height: | Size: 7.8 KiB |
BIN
hourglass/public/icons/png/book.png
Normal file
|
After Width: | Height: | Size: 2.3 KiB |
BIN
hourglass/public/icons/png/chemistry.png
Normal file
|
After Width: | Height: | Size: 12 KiB |
BIN
hourglass/public/icons/png/comedy-1.png
Normal file
|
After Width: | Height: | Size: 11 KiB |
BIN
hourglass/public/icons/png/comedy.png
Normal file
|
After Width: | Height: | Size: 12 KiB |
BIN
hourglass/public/icons/png/construction-1.png
Normal file
|
After Width: | Height: | Size: 2.5 KiB |
BIN
hourglass/public/icons/png/construction.png
Normal file
|
After Width: | Height: | Size: 3.9 KiB |
BIN
hourglass/public/icons/png/cup.png
Normal file
|
After Width: | Height: | Size: 9.0 KiB |
BIN
hourglass/public/icons/png/diploma-1.png
Normal file
|
After Width: | Height: | Size: 4.0 KiB |
BIN
hourglass/public/icons/png/diploma.png
Normal file
|
After Width: | Height: | Size: 4.1 KiB |
BIN
hourglass/public/icons/png/draw.png
Normal file
|
After Width: | Height: | Size: 6.7 KiB |
BIN
hourglass/public/icons/png/earth-1.png
Normal file
|
After Width: | Height: | Size: 8.7 KiB |
BIN
hourglass/public/icons/png/earth.png
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
hourglass/public/icons/png/education-1.png
Normal file
|
After Width: | Height: | Size: 3.9 KiB |
BIN
hourglass/public/icons/png/education-2.png
Normal file
|
After Width: | Height: | Size: 4.0 KiB |
BIN
hourglass/public/icons/png/education.png
Normal file
|
After Width: | Height: | Size: 3.8 KiB |
BIN
hourglass/public/icons/png/energy.png
Normal file
|
After Width: | Height: | Size: 5.1 KiB |
BIN
hourglass/public/icons/png/file.png
Normal file
|
After Width: | Height: | Size: 5.1 KiB |
BIN
hourglass/public/icons/png/fruit.png
Normal file
|
After Width: | Height: | Size: 6.5 KiB |
BIN
hourglass/public/icons/png/graduate.png
Normal file
|
After Width: | Height: | Size: 12 KiB |
BIN
hourglass/public/icons/png/graduation.png
Normal file
|
After Width: | Height: | Size: 13 KiB |
BIN
hourglass/public/icons/png/greek.png
Normal file
|
After Width: | Height: | Size: 7.1 KiB |
BIN
hourglass/public/icons/png/interface-1.png
Normal file
|
After Width: | Height: | Size: 5.2 KiB |
BIN
hourglass/public/icons/png/interface-2.png
Normal file
|
After Width: | Height: | Size: 11 KiB |
BIN
hourglass/public/icons/png/interface.png
Normal file
|
After Width: | Height: | Size: 3.3 KiB |
BIN
hourglass/public/icons/png/magnet.png
Normal file
|
After Width: | Height: | Size: 5.7 KiB |
BIN
hourglass/public/icons/png/mark.png
Normal file
|
After Width: | Height: | Size: 8.7 KiB |
BIN
hourglass/public/icons/png/medical-1.png
Normal file
|
After Width: | Height: | Size: 12 KiB |
BIN
hourglass/public/icons/png/medical-2.png
Normal file
|
After Width: | Height: | Size: 5.5 KiB |
BIN
hourglass/public/icons/png/medical.png
Normal file
|
After Width: | Height: | Size: 6.3 KiB |
BIN
hourglass/public/icons/png/molecule.png
Normal file
|
After Width: | Height: | Size: 7.1 KiB |
BIN
hourglass/public/icons/png/monuments.png
Normal file
|
After Width: | Height: | Size: 6.7 KiB |
BIN
hourglass/public/icons/png/mouse.png
Normal file
|
After Width: | Height: | Size: 7.6 KiB |
BIN
hourglass/public/icons/png/people-1.png
Normal file
|
After Width: | Height: | Size: 10 KiB |
BIN
hourglass/public/icons/png/people.png
Normal file
|
After Width: | Height: | Size: 8.4 KiB |
BIN
hourglass/public/icons/png/planet.png
Normal file
|
After Width: | Height: | Size: 8.6 KiB |
BIN
hourglass/public/icons/png/potion.png
Normal file
|
After Width: | Height: | Size: 8.2 KiB |
BIN
hourglass/public/icons/png/reading.png
Normal file
|
After Width: | Height: | Size: 10 KiB |
BIN
hourglass/public/icons/png/research.png
Normal file
|
After Width: | Height: | Size: 7.9 KiB |
BIN
hourglass/public/icons/png/school.png
Normal file
|
After Width: | Height: | Size: 4.7 KiB |
BIN
hourglass/public/icons/png/science-1.png
Normal file
|
After Width: | Height: | Size: 3.1 KiB |
BIN
hourglass/public/icons/png/science-10.png
Normal file
|
After Width: | Height: | Size: 11 KiB |
BIN
hourglass/public/icons/png/science-2.png
Normal file
|
After Width: | Height: | Size: 9.7 KiB |
BIN
hourglass/public/icons/png/science-3.png
Normal file
|
After Width: | Height: | Size: 5.5 KiB |
BIN
hourglass/public/icons/png/science-4.png
Normal file
|
After Width: | Height: | Size: 14 KiB |
BIN
hourglass/public/icons/png/science-5.png
Normal file
|
After Width: | Height: | Size: 9.6 KiB |
BIN
hourglass/public/icons/png/science-6.png
Normal file
|
After Width: | Height: | Size: 4.5 KiB |
BIN
hourglass/public/icons/png/science-7.png
Normal file
|
After Width: | Height: | Size: 11 KiB |
BIN
hourglass/public/icons/png/science-8.png
Normal file
|
After Width: | Height: | Size: 6.9 KiB |
BIN
hourglass/public/icons/png/science-9.png
Normal file
|
After Width: | Height: | Size: 5.8 KiB |
BIN
hourglass/public/icons/png/science.png
Normal file
|
After Width: | Height: | Size: 10 KiB |
BIN
hourglass/public/icons/png/search.png
Normal file
|
After Width: | Height: | Size: 7.3 KiB |
BIN
hourglass/public/icons/png/shapes.png
Normal file
|
After Width: | Height: | Size: 6.2 KiB |
BIN
hourglass/public/icons/png/space.png
Normal file
|
After Width: | Height: | Size: 9.7 KiB |
BIN
hourglass/public/icons/png/speech-balloon-1.png
Normal file
|
After Width: | Height: | Size: 13 KiB |
BIN
hourglass/public/icons/png/speech-balloon.png
Normal file
|
After Width: | Height: | Size: 18 KiB |
BIN
hourglass/public/icons/png/sports.png
Normal file
|
After Width: | Height: | Size: 4.4 KiB |
BIN
hourglass/public/icons/png/stars-1.png
Normal file
|
After Width: | Height: | Size: 7.2 KiB |
BIN
hourglass/public/icons/png/stars.png
Normal file
|
After Width: | Height: | Size: 10 KiB |
BIN
hourglass/public/icons/png/technology.png
Normal file
|
After Width: | Height: | Size: 4.2 KiB |
BIN
hourglass/public/icons/png/tool.png
Normal file
|
After Width: | Height: | Size: 3.4 KiB |
BIN
hourglass/public/icons/png/transfer.png
Normal file
|
After Width: | Height: | Size: 5.1 KiB |
BIN
hourglass/public/icons/png/write-1.png
Normal file
|
After Width: | Height: | Size: 6.4 KiB |
BIN
hourglass/public/icons/png/write-2.png
Normal file
|
After Width: | Height: | Size: 7.4 KiB |
BIN
hourglass/public/icons/png/write.png
Normal file
|
After Width: | Height: | Size: 7.5 KiB |
BIN
hourglass/public/icons/png/writing.png
Normal file
|
After Width: | Height: | Size: 3.1 KiB |
@ -28,7 +28,9 @@ for (var i = 0; i < superadmins.length; i++) {
|
|||||||
});
|
});
|
||||||
if (superadmin !== undefined && !(Roles.userIsInRole(superadmin._id, 'superadmin'))) {
|
if (superadmin !== undefined && !(Roles.userIsInRole(superadmin._id, 'superadmin'))) {
|
||||||
Roles.addUsersToRoles(superadmin._id, 'superadmin');
|
Roles.addUsersToRoles(superadmin._id, 'superadmin');
|
||||||
Houston._admins.insert({user_id: superadmin._id});
|
Houston._admins.insert({
|
||||||
|
user_id: superadmin._id
|
||||||
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -441,7 +443,7 @@ Meteor.methods({
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
'deleteWork': function(workId) {
|
'deleteWork': function(workId) {
|
||||||
var currentwork = wokr.findOne({
|
var currentwork = work.findOne({
|
||||||
_id: workId
|
_id: workId
|
||||||
});
|
});
|
||||||
var currentclass = classes.findOne({
|
var currentclass = classes.findOne({
|
||||||
|
|||||||