Skip to content

Commit

Permalink
ie8 javascript fixes around poll
Browse files Browse the repository at this point in the history
  • Loading branch information
mikhuang committed Jun 12, 2013
1 parent ea22066 commit 3465e36
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 4 deletions.
2 changes: 2 additions & 0 deletions deme_django/modules/poll/views.py
Expand Up @@ -125,6 +125,8 @@ def item_show_html(self):
if memberships:
self.permission_cache.filter_items('view Item.name', Item.objects.filter(pk__in=[x.item_id for x in memberships]))
self.context['responses'] = PropositionResponseApprove.objects.filter(poll=self.item)
if not self.item.eligibles:
return self.render_error('No eligibles chosen', "Please edit this poll and choose a group of eligible participants")
eligible_agent_memberships = self.item.eligibles.child_memberships
eligible_agent_memberships = eligible_agent_memberships.filter(active=True, item__active=True)
eligible_agent_memberships = self.permission_cache.filter_items('view Membership.item', eligible_agent_memberships)
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Expand Up @@ -32,7 +32,7 @@ $(function() {
cache[term] = normalized_data;
response(normalized_data);
});
},
}
});

// set up new button
Expand All @@ -43,7 +43,7 @@ $(function() {
var list_modal_url = hidden_input.attr('data-list-modal-url');

var random_num = Math.floor((Math.random()*1000000)+1);
window.open(list_modal_url, 'embedform-' + random_num, 'width=600,toolbar=1,resizable=1,scrollbars=yes,height=600,top=100,left=100');
window.open(list_modal_url, 'embedform' + random_num, 'width=600,toolbar=1,resizable=1,scrollbars=yes,height=600,top=100,left=100');
});

hidden_input.addClass('ajax-model-choice-widget-processed');
Expand Down
2 changes: 1 addition & 1 deletion deme_django/static/javascripts/deme/metabar_swap.js
Expand Up @@ -27,7 +27,7 @@ $(function(){

//New height and width
var winNewWidth = $(window).width(),
winNewHeight = $(window).height();
winNewHeight = $(window).height();

// compare the new height and width with old one
if(winWidth!=winNewWidth || winHeight!=winNewHeight)
Expand Down

0 comments on commit 3465e36

Please sign in to comment.