Random quotes from Winnie the Pooh
A Pen by jordan rhea on CodePen.
Random quotes from Winnie the Pooh
A Pen by jordan rhea on CodePen.
var attendance = "<WHOEVER_TAKES_ATTENDANCE_FOR_YOU>"; | |
var bcc = "<YOUR_EMAIL ADDRESS_GOES_HERE>"; | |
var d = new Date(); | |
var bodyText = d.toDateString() + '\n' + d.toTimeString() + '\n\n\n'; | |
var className= $("header>div>div div").text().substr(0,2); | |
var subject = 'Absent Students from ' + className; | |
var late = $("img[src='/be0f7a34ef27e82a28e9005115e57754.png']").parent().parent().prev().children(); |
function shuffle(array) { | |
var currentIndex = array.length, temporaryValue, randomIndex ; | |
// While there remain elements to shuffle... | |
while (0 !== currentIndex) { | |
// Pick a remaining element... | |
randomIndex = Math.floor(Math.random() * currentIndex); | |
currentIndex -= 1; |
function onOpen(e) { | |
DocumentApp.getUi().createAddonMenu() | |
.addItem('Start', 'showWindow') | |
.addToUi(); | |
} | |
function onInstall(e) { | |
onOpen(e); | |
} |
function createGroups() { | |
//create a new document | |
var date = new Date(); | |
var document = DocumentApp.create("Seating Groups " + date.toDateString()).getBody(); | |
//declare the object classList filled with an array for each class | |
var classList = {}; | |
var newGroups = {}; |
/*Average of text fields */ | |
function AVGCOMPLETES(arr) { | |
//declare the array that will be used to get the average | |
//push 100 to the array if the field is 'complete' and 0 to the array if the field is 'incomplete' | |
var averageArray = []; | |
for(i = 0; i < arr[0].length; i++) { | |
if(typeof arr[0][i] === 'string') { | |
if(arr[0][i].toLowerCase() === 'complete') { | |
averageArray.push(100); | |
} else if(arr[0][i].toLowerCase() === 'incomplete') { |
function onEdit(event) { | |
if(event.value.toLowerCase() === "incomplete") { | |
event.range.setBackground("red"); | |
} else { | |
event.range.setBackground("white"); | |
} | |
} |
//get the name of the student on the selected row and add them to an Etut list(after school tutoring) | |
function setEtutList(selected) { | |
var fname = '2'; //where is the first name | |
var row = SpreadsheetApp.getActiveRange().getRow(); | |
var name = SpreadsheetApp.getActiveSheet().getRange(row, fname, 1, 2).getValues(); | |
var etutList = SpreadsheetApp.getActiveSpreadsheet().getSheetByName("Etut Lists"); | |
etutList.appendRow([getNextThurs().toDateString(), name[0][0] + ' ' + name[0][1]]); | |
} | |
function gradeBar() { | |
var gradeBar = HtmlService | |
.createHtmlOutputFromFile('sidebar') | |
.setSandboxMode(HtmlService.SandboxMode.IFRAME) | |
.setTitle('Grader'); | |
SpreadsheetApp.getUi().showSidebar(gradeBar); | |
} | |
function endColumn() { |
Thrown together based on a 30 second conversation I had with another teacher today. CSS card flipping is based on http://css3.bradshawenterprises.com/flip/ but I can't get it to look quite as cool.
A Pen by jordan rhea on CodePen.