1 {% extends "base.html" %}
2 {% load url from future %}
5 <link rel="stylesheet" type="text/css" media="all" href="/static/css/note_course_pages.css">
8 {% block pagescripts %}
10 var view_note_pk = {{ note.id }};
11 var view_note_title = "{{ note.name }}";
12 var view_note_description = "{{ note.desc }}";
13 var editing_note = false;
15 function autoResize(id){
19 if(document.getElementById){
20 newheight = document.getElementById(id).contentWindow.document .body.scrollHeight;
21 newwidth = document.getElementById(id).contentWindow.document .body.scrollWidth;
24 document.getElementById(id).height = (newheight+ 10) + "px";
25 document.getElementById(id).width= (newwidth + 5) + "px";
26 //alert('height: ' + newheight);
33 <section id="note_content">
35 <div id="note_header" class="hero_gradient_bar">
37 <div id="note_back_to_course" class="twelve columns">
38 <a href="{{ note.course.get_absolute_url }}">
39 {# TODO: style this not like a link #}
40 <img src="/static/img/search_arrow_left.png" alt="search_arrow_left" width="5" height="10" /> back to {{ note.course.name }}
47 <div id="note_name" class="twelve columns">
49 </div><!-- /note_name -->
53 <!-- disabiling viewCount and liked count -->
55 <div id="note_status" class="twelve columns">
56 <div class="activity_details_status">
57 So far, <span class="activity_details_status_number">{{ note.numUpVotes }}</span> people have completely fallen in love with with these notes. <span class="activity_details_status_secondary_number">{{ note.viewCount }}</span> people have viewed them.
58 </div><!-- /activity_details_status -->
59 </div><!-- /note_status -->
66 <!-- uploaded by style -->
68 <div id="note_author" class="twelve columns">
73 {{ note.owner.get_profile.get_name }}
75 </div><!-- /note_author -->
80 <div id="note_actions" class="three columns centered">
81 {% if not owns_file %}
83 <div class="six column thank" {% if has_voted %} style="display:none" {% endif %} data-id={{ file.id }}>
84 <img src="/static/img/note_thank.png" alt="note_thank" width="34" height="34" />
86 <div class="six column flag" {% if has_voted %} style="display:none" {% endif %} data-id={{ file.id }}>
87 <img src="/static/img/note_flag.png" alt="note_flag" width="25" height="35" />
89 <div class="twelve column voted_message" data-id={{ file.id }} {% if not has_voted %} style="display:none" {% endif %}>
91 <span id="thanked_or_flagged">
94 {% elif not flaggable %}
100 <!-- disabling downloads for now -->
101 <div class="four column">
102 <img src="/static/img/note_download.png" alt="note_download" width="51" height="36" />
105 {% endif %} <!-- not owns_file -->
106 </div><!-- /note_actions -->
109 </div><!-- /note_header -->
112 <div id="note_container">
115 <div class="eight columns centered body_copy">
120 <p>{{ note.desc }}</p>
125 <div class="note-text">
126 <iframe style="border:none; width:100%;" id="noteframe" src="/raw/{{ note.id }}" onload="autoResize('noteframe')">
128 </div> <!-- .note-text -->
129 <div class="note-error" style="display:none">
130 This document's content is currently unavailable. It's likely the document is still being processed. Please try again later.
133 </div><!-- /body_copy -->
136 </div><!-- /note_container -->
139 </section><!--/note_content-->