Skip to content

Commit

Permalink
let program detail display a clone of metadata
Browse files Browse the repository at this point in the history
  • Loading branch information
evelynhung committed Jul 23, 2014
1 parent c2600c7 commit dc5e4f8
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 10 deletions.
15 changes: 5 additions & 10 deletions theme/assets/js/page/program.js
Original file line number Diff line number Diff line change
Expand Up @@ -96,20 +96,15 @@ define(['jquery', 'context' , 'lib/bootstrap-scrollspy', './program-filter'], fu

$('#content').on('click', '.article .program', function() {
var id = $(this).data('id');
var $metadata = $(this).find('.metadata').clone();

function displayDetails(data) {
var program = data.program[id];

$('#program_detail').empty();
$('#program_detail')
.append($('<div class="metadata"></div>').addClass('track_tag colorTag-' + program.type)
.append($('<div></div>').addClass('head')
.append($('<div></div>').addClass('place').html(data.room[program.room]['zh-tw']))
.append($('<div></div>').addClass('timeinfo').html(getTime(program.from) + ' - ' + getTime(program.to)))
.append($('<div></div>').addClass('community').html(data.community[program.community])))
.append($('<div></div>').addClass('body')
.append($('<div></div>').addClass('topic').addClass(program.lang).html(program.name))
.append($('<div></div>').addClass('speaker').html(program.speaker))
.append($('<div></div>').addClass('speaker-title').html(program.speakerTitle))));
$('#program_detail').append($metadata);
$('<div></div>').addClass('timeinfo').html(getTime(program.from) + ' - ' + getTime(program.to))
.insertAfter($('#program_detail .place'));

$('#program_detail')
.append($('<div></div>').addClass('detail')
Expand Down
4 changes: 4 additions & 0 deletions theme/assets/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -757,6 +757,10 @@ h2.pro {
padding-right: 10px;
text-align: right;
}
#program_detail.program .ps {
bottom: auto;
left: auto;
}

#lock_background.show {
display: block;
Expand Down

0 comments on commit dc5e4f8

Please sign in to comment.