This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
initialize: function(){ | |
_.bindAll(this, 'render', 'onImgLoad'); | |
this.mainImg = new Image(); | |
this.mainImg.src = this.model.get('img'); | |
this.userImg = new Image(); | |
this.userImg.src = this.model.get('admin').img; | |
this.mainImg.onload = this.onImgLoad; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
importSchedule.startHourOptions = this._buildOptions(_.chain(_.range(0, 24)).map(function(hour){ | |
return {text: '00'.substring(0, '00'.length - hour.toString().length) + hour.toString(), value: hour}; | |
}).value(), importSchedule.start_hour); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function coinify(cents){ | |
var count = parseInt(cents / 50), | |
leftOver = cents % 50, | |
coins = [25, 10, 5, 1], | |
iterator = 0; | |
while (leftOver > 0){ | |
count += parseInt( leftOver / coins[iterator] ); | |
leftOver = leftOver % coins[iterator]; | |
iterator ++; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<title>Tabs</title> | |
<style> | |
.nav .active a { color: red; } | |
.tab-pane { display: none; } | |
.tab-pane.active { display: block; } | |
</style> | |
</head> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'00'.length |
NewerOlder