Modify interlude for OpenFest 2016

This commit is contained in:
Vencislav Atanasov 2016-11-04 16:51:20 +02:00
parent e8f8632530
commit c355c4c655
3 changed files with 14 additions and 24 deletions

View File

@ -1,6 +1,6 @@
<html> <html>
<head> <head>
<title>The IT Tour</title> <title>OpenFest</title>
<meta charset="utf-8"> <meta charset="utf-8">
@ -97,7 +97,7 @@
<script id="slides_template" type="text/ractive"> <script id="slides_template" type="text/ractive">
<section data-state="update-safe"> <section data-state="update-safe">
<img src="http://varnaconf.com/system/uploads/event/logo/15/main_image.png"> <img src="logo.png">
</section> </section>
{{#eventCount}} {{#eventCount}}
@ -122,16 +122,9 @@
</section> </section>
{{/eventCount}} {{/eventCount}}
<!-- <section> -->
<!-- <h1>Обратна връзка</h1> -->
<!-- <h2>http://bit.ly/varnaconf-2015-feedback</h2> -->
<!-- </section> -->
<section> <section>
<h1>#VarnaConf</h1> <h1>#OpenFest2016</h1>
<h2>В Twitter и IRC на irc.it-tour.bg</h2> <h2>в Twitter</h2>
<!-- <a class="twitter-timeline" href="https://twitter.com/search?q=%23VarnaConf" data-widget-id="466029214940925952">Tweets about "#VarnaConf"</a> -->
<!-- <script src="https://platform.twitter.com/widgets.js" id="twitter-wjs"></script> -->
</section> </section>
</script> </script>

BIN
logo.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 77 KiB

After

Width:  |  Height:  |  Size: 37 KiB

View File

@ -1,22 +1,19 @@
function Schedule(hallId) { function Schedule(hallId, date) {
var events = []; var events = [];
this.update = function() { this.update = function() {
$.getJSON("http://varnaconf.com/schedules/2015.json", function(data) { $.getJSON('http://www.openfest.org/2016/wp-content/themes/initfest/schedule/interlude.php', function(data) {
var scheduleEvents = $.map(data[hallId], function(event) { var scheduleEvents = $.map(data[hallId], function(event) {
event['startTime'] = moment(event['startTime']); event['startTime'] = moment(event['starts_at'] * 1000);
event['endTime'] = moment(event['ends_at'] * 1000);
console.log(event['startTime'].date());
if (event['startTime'].date() !== date) {
return null;
}
return event; return event;
}); });
$.each(scheduleEvents, function(index, event) {
var nextEvent = scheduleEvents[index + 1];
if (typeof(nextEvent) != 'undefined') {
event['endTime'] = moment(nextEvent['startTime']).subtract(10, 'minutes');
} else {
event['endTime'] = moment(event['startTime']).add(40, 'minutes');
}
});
events = scheduleEvents; events = scheduleEvents;
}); });
} }
@ -65,4 +62,4 @@ $.urlParam = function(name){
} }
} }
var schedule = new Schedule(parseInt($.urlParam('roomId'))); var schedule = new Schedule(parseInt($.urlParam('roomId')), parseInt($.urlParam('date')));