}
#content {
- margin-top: 1em;
+ /*margin-top: 1em;*/
margin-bottom: 0em;
}
-#content, #content_header {
+#content {
position: relative;
margin-left: 2em;
margin-right: 2em;
}
-#content_header {
- top:-.45em; /*must be header.margin_bottom (0.9em)*/
-}
+
#content ul, #content ul ul, #content ol {
list-style: square;
#content li a {
padding: .1em 0;
}
-#content h3, #content_header h3 {
+#content h3 {
color: #6a0307;
font-weight: bold;
display: inline;
width: 90%;
padding: 0.3em 0.3em 0.3em 0.5em;
}
+#logo a, #logo a:hover { border: none; background: transparent; }
#header {
padding: 0.2em 0;
- margin-bottom: .9em;
background: url("/images/waves.png") 100% 0% no-repeat;
}
-#logo a, #logo a:hover { border: none; background: transparent; }
-
-#submenu {
- position: relative;
- margin: 5px 2em 0;
- /*height:3ex;*/ /*no longer used, and it also shifts up the bottom content*/
- z-index: 10;
+#content_header, #header{
+ margin-bottom: .8em;
}
-/*#submenu h3, #submenu div {
- min-height: 1.6em;
-}*/
-
-
-#submenu h3 {
- margin-right: 80px;
-}
-#submenu div {
- position: absolute;
- right: 0;
- top: 0;
+#content_header{
+ width:100%;
+ border-collapse:collapse;
}
-/*#submenu a {
- height: 1.6em;
- color: #4d508a;
- font-size: 0.9em;
- font-weight: bold;
-}*/
-#content_header table{
- width:100%;
+#content_header td{
+ vertical-align: top;
}
-#content_header table td{
- vertical-align: bottom;
+#content_header td.rightcol{
+ text-align:right;
+ white-space:nowrap; /**this implies to stretach righcol to accomodate all the width,
+ UNLESS there is a div.fixedWidthAsPlayer inside td.rightcol (see blow)*/
}
-
-#content_header td.rightcol a{
+#content_header td.rightcol div.fixedWidthAsPlayer{
+ width:374px; /*must be width+2*padding, see #rightcol below*/
+ float:right;
+ white-space:normal; /*to override no-wrap defined in #content_header td.rightcol*/
+}
+#content_header td.rightcol div.fixedWidthAsPlayer a{
display:inline-block;
margin-top:0.5ex;
}
-#content_header td.rightcol {
- width:374px; /*must be width+2*padding, see #rightcol below*/
-}
+
#rightcol {
width: 362px; /**if u change this, change also width #content_header td.rightcol, see above*/
padding: 6px; /**if u change this, change also width #content_header td.rightcol, see above*/
.button, .button:visited, .button:hover{
font-weight: bold;
border: 1px solid #e1e1e1;
-
+ white-space:nowrap;
/* border-top: 1px solid #e1e1e1 !important;
border-left: 1px solid #e1e1e1 !important;
border-right: 1px solid #e1e1e1 !important;
/* Min-width */\r
-#submenu h3, #submenu div {\r
+/*#submenu h3, #submenu div {\r
height: 1.6em;\r
-}\r
+}*/\r
return div;\r
},\r
className: 'component',\r
- divShadow: function(){\r
- var divShadow = this.jQuery('<div/>').css({ //this is _cfg_\r
- position: 'absolute',\r
- display: 'none',\r
- overflow:'visible',\r
- padding: '0 !important', //otherwise setting divShadow dimension is tricky\r
- backgroundColor:'#000 !important', //shadow must be black\r
- zIndex:999\r
- });\r
- if(this.className){\r
- divShadow.addClass(this.className);\r
- }\r
- return divShadow;\r
- },\r
+// divShadow: function(){\r
+// var divShadow = this.jQuery('<div/>').css({ //this is _cfg_\r
+// position: 'absolute',\r
+// display: 'none',\r
+// overflow:'visible',\r
+// padding: '0 !important', //otherwise setting divShadow dimension is tricky\r
+// backgroundColor:'#000 !important', //shadow must be black\r
+// zIndex:999\r
+// });\r
+// if(this.className){\r
+// divShadow.addClass(this.className);\r
+// }\r
+// return divShadow;\r
+// },\r
// mouseDownNamespace : "mousedown.popup__",\r
// keyDownNamespace : "keydown.popup__",\r
\r
var windowH = wdow.height();\r
var windowW = wdow.width();\r
var position = div.offset();\r
- var shadowOffset=2;\r
+ var shadowOffset=5;\r
var size = {\r
width:div.outerWidth(true)+shadowOffset,\r
height:div.outerHeight(true)+shadowOffset\r
}; //setting width on a div means the width(),\r
//but calculations here are made according to outerWidth(true), so we need this variable (se below)\r
\r
+ //the shadow in the background will be created according to the actual div size\r
+ //However, since we do not specify neither width nor height, the calculation of the div size\r
+ //works if maxWidth and maxHeight do set a width and height. In order to do so, they\r
+ //must be lower or equal to the actual div width and height. That's why the "min" here below:'\r
div.css({\r
- 'maxWidth': maxSize.width-divPadding.left,\r
- 'maxHeight': maxSize.height-divPadding.top\r
+ 'maxWidth': Math.min(div.width(), maxSize.width-divPadding.left),\r
+ 'maxHeight': Math.min(div.height(), maxSize.height-divPadding.top)\r
});\r
+\r
//last thing: if invoker element exist, set width at least invoker element width\r
if(invokerElement){\r
var iEw = invokerElement.outerWidth(); //no margins considered\r
});\r
}\r
}\r
- //var divShadow = this._cfg_.divShadow().insertAfter(div);\r
-\r
+ //now we can build the divShadow\r
var divShadow = div.clone(false,false).empty().css({'zIndex':999,'borderColor':'#000','display':'none','backgroundColor':'#000'}).insertAfter(div);\r
- \r
//store the divs to be removed\r
this._cfg_.divsToDelete = [div,divShadow];\r
//add a listener to the document. If one of the content children is clicked/keypressed,\r
this.cfg.player = new $N.Player(this.cfg.player);
}
this._setupPlayer();
- //setting the divmarkers
- //this.cfg.map.observe('add')
this.loadHTTP();
},
_setupPlayer: function() {
this.debug('_setupPlayer');
this.cfg.player
- //.setSoundProvider(this.cfg.soundProvider)
.setMarkerMap(this.cfg.map)
-// .observe('play', $N.attachFunction(this.cfg.soundProvider, this.cfg.soundProvider.play))
-// .observe('pause', $N.attachFunction(this.cfg.soundProvider, this.cfg.soundProvider.pause))
-// .observe('move', this.attach(this._onMove))
.observe('markeradd', this.attach(this._onMarkerAdd))
//player markermove listens for changes of ruler markermove which listens
//foir changes in each marker move
.observe('markermove', this.attach(this._onMarkerMove))
-
-// .draw();
._setupInterface();
- //this.loadHTTP();
this.cfg.map.observe('add',this.attach(this._onMarkerMapAdd));
this.cfg.map.observe('remove',this.attach(this._onMarkerMapRemove));
},
-
-// _onMove: function(e, data) {
-// this.cfg.soundProvider.seek(data.offset);
-// },
-
//called whenever a marker is moved in the ruler BUT NOT in the map
_onMarkerMove: function(e, data) {
if (this.cfg.map) {
}
util.setUpTabs.apply(util, [tabIndex]);
-// setTabs(tabIndex);
};
- //json(param, method, onSuccesFcn(data, textStatus, jqXHR), onErrorFcn(jqXHR, textStatus, errorThrown))
json([itemId],"telemeta.get_markers", onSuccess);
}
});
marker: marker,
index: idx
});
- //this.fireRefreshLabels(idx+1,this.markers.length);
- //this._reorder(marker.offset);
- //this.fireEditMode(marker);
return idx;
},
+
//argument is either an object loaded from server or a number specifying the marker offset
createMarker: function(argument){
var marker = null;
- if(typeof argument == 'string'){
+ if(typeof argument == 'string'){ //to be sure, it might be that we pass an offset in string format
argument = parseFloat(argument);
}
if(typeof argument == 'object'){
--- /dev/null
+{% extends "telemeta_default/mediaitem.html" %}
{% endblock %}
</div>
</div>
-<div id="submenu">
-{% block submenu %}{% endblock %}
-</div>
-<div id="content_header">
-{% block content_header %}{% endblock %}
-</div>
+
<div id="content">
+ <table id="content_header"><tr>
+ <td class="leftcol"><h3>{% block title %}{% endblock %}</h3></td>
+ <td class="rightcol">{% block title_buttons %}{% endblock %}</td>
+ </tr></table>
{% block content %}{% endblock %}
<div class="nett"></div>
</div>
{% load i18n %}
{% load telemeta_utils %}
-{% block submenu %}
- <div>
- {% block tools %}
- <a href="{% url telemeta-collections %}" class="component_icon button icon_cancel">{% trans "Cancel" %}</a>
- {% endblock tools %}
- </div>
+{% block title_buttons %}
+ <a href="{% url telemeta-collections %}" class="component_icon button icon_cancel">{% trans "Cancel" %}</a>
{% endblock %}
{% if collection %}
-{% block submenu %}
- <div>
- {% block tools %}
+{% block title %}
+ Collection: {{ collection }}
+{% endblock %}
+
+{% block title_buttons %}
<a href="{% url telemeta-collection-dublincore collection.public_id %}" class="component_icon button icon_dublin_core">Dublin Core</a>
{% if user.is_authenticated and perms.telemeta.change_mediacollection %}
<a href="{% url telemeta-collection-edit collection.public_id %}" class="component_icon button icon_edit">{% trans "Edit" %}</a>
{% if user.is_authenticated %}
<a href=# id ="_add_to_playlist" class="component_icon button icon_add">{% trans "Add to playlist" %}</a>
{% endif %}
- {% endblock tools %}
-
-
- </div>
{% endblock %}
{% block content %}
- <h3>Collection: {{ collection }}</h3>
+<!-- <h3>Collection: {{ collection }}</h3>-->
<div class="{% if collection.has_mediafile %}with-rightcol{% endif %}">
{% if collection.has_mediafile %}
<div id="rightcol">
{% block head_title %}{% trans "Collection" %}{{collection|prepend:': '}} - {{ block.super }}{% endblock %}
{% if collection %}
-{% block submenu %}
- <h3>Collection: {{ collection }}</h3>
- <div><a href="{% url telemeta-collection-detail collection.public_id %}">{% trans "Normal View" %}</a></div>
+{% block title %}
+ Collection: {{ collection }}
+{% endblock %}
+{% block title_buttons %}
+ <a class="component_icon button icon_previous" href="{% url telemeta-collection-detail collection.public_id %}">{% trans "Normal View" %}</a>
{% endblock %}
{% block content %}
{% load i18n %}
{% load telemeta_utils %}
-{% block tools %}
- <a href="{% url telemeta-collection-detail collection.public_id %}" class="component_icon button icon_cancel">{% trans "Cancel" %}</a>
-{% endblock %}
+<a href="{% url telemeta-collection-detail collection.public_id %}" class="component_icon button icon_cancel">{% trans "Cancel" %}</a>
{% block infos %}
<div class="infos">
{% block head_title %}{% trans "Media Collections" %} - {{ block.super }}{% endblock %}
-{% block submenu %}
- <div class="buttons">
+{% block title%}
+ {% trans "Media Collections" %}
+{% endblock %}
+{% block title_buttons %}
<a href="{% url telemeta-collections %}" class="component_icon button icon_search">{% trans "All" %}</a>
<a href="{% url telemeta-collections-novel %}" class="component_icon button icon_filter">{% trans "Novel" %}</a>
<a href="{% url telemeta-collections-published %}" class="component_icon button icon_filter">{% trans "Published" %}</a>
{% if user.is_authenticated and perms.telemeta.add_mediacollection %}
<a href="{% url telemeta-collection-add %}" class="component_icon button icon_add">{% trans "Add" %}</a>
{% endif %}
- </div>
{% endblock %}
{% block content %}
-<h3>{% trans "Media Collections" %}</h3>
-
{% with object_list as collections %}
<div class="fullpage">
{% include "telemeta/inc/collection_list.html" %}
{% endif %}
{% endblock %}
-{% block submenu %}
- <div>
+{% block title %}
+ {% trans "Geographic Navigator" %}
+{% endblock %}
+{% block title_buttons %}
{% if continents %}
<a href="#" onclick="resourceMap.toggle('map'); return false;" class="component button">{% trans "Map" %}</a> |
<a href="#" onclick="resourceMap.toggle('list'); return false;" class="component button">{% trans "List" %}</a>
{% endif %}
- </div>
{% endblock %}
{% block content %}
-<h3>{% trans "Geographic Navigator" %}</h3>
{% if continents %}
<ul class="continents">
{% for group in continents %}
--- /dev/null
+{% extends "telemeta/base.html" %}
+{% load telemeta_utils %}
+{% load i18n %}
+
+{% block head_title %}{% trans "Item" %}- {{ block.super }}{% endblock %}
+
+{% block stylesheets %}
+{{ block.super }}
+<link rel="stylesheet" type="text/css" href="{% url telemeta-timeside "css/timeside.css" %}" />
+ <link rel="stylesheet" type="text/css" href="{% url telemeta-timeside "skins/lab/style.css" %}" />
+ <link rel="stylesheet" type="text/css" href="{% url telemeta-css "player.css" %}" />
+ {% endblock %}
+
+ {% block extra_javascript %}
+ <!--<script src="{% url telemeta-js "wz_jsgraphics.js" %}" type="text/javascript"></script>-->
+<script src="{% url telemeta-js "soundmanager2.js" %}" type="text/javascript"></script>
+<script src="{% url telemeta-timeside "src/playlist.js" %}" type="text/javascript"></script>
+<script type="text/javascript">
+ soundManager.url = '{% url telemeta-swf "./" %}';
+ soundManager.flashVersion = 9;
+ soundManager.useMovieStar = true; // enable MP4/M4A/AAC
+ soundManager.debugMode = false;
+ soundManager.allowPolling = true;
+
+ var setupPlaylist = function(){
+ {% if user.is_authenticated %}
+ var p = playlistUtils;
+ {% for playlist in playlists %}
+ p.addPlaylist('{{ playlist.playlist.title }}','{{playlist.playlist.public_id}}');
+ {% endfor %}
+
+ {% endif %}
+ {% if item %}
+ var anchor = jQuery('#_add_to_playlist');
+ if(anchor.length){
+ anchor.click(function(evtObj_){
+ p.showPopupAddToPlaylist(evtObj_,'item','{{item.public_id}}','item added to selected playlist');return false;
+ });
+ }
+ {% endif %}
+ };
+
+ {% if item %}
+ var ITEM_PUBLIC_ID = '{{item.public_id}}';
+ {% endif %}
+
+ var scripts = ["{% url telemeta-js "wz_jsgraphics.js" %}",
+ //"{% url telemeta-timeside "src/playlist.js" %}",
+ "{% url telemeta-timeside "src/timeside.js" %}","{% url telemeta-js "playerUtils.js" %}"];
+
+ var _sound_manager_loaded=false;
+ var _jQuery_loaded = false;
+
+ jQuery(document).ready(function(){
+ _jQuery_loaded=true;
+ if(_sound_manager_loaded){
+ loadScripts(scripts, function(){loadPlayer('{% url telemeta-item-analyze-xml item.public_id %}',$('.ts-wave a').attr('href'));setupPlaylist()});
+ }
+ });
+ //$('.ts-wave a').attr('href')
+ soundManager.onready(function() {
+ _sound_manager_loaded=true;
+ if(_jQuery_loaded){
+ loadScripts(scripts, function(){loadPlayer('{% url telemeta-item-analyze-xml item.public_id %}',$('.ts-wave a').attr('href'));setupPlaylist()});
+ }
+ });
+
+</script>
+<!--item.approx_duration-->
+
+{% endblock %}
+
+
+{% if item %}
+
+{% block title %}
+{% endblock %}
+{% block title_buttons %}
+{% endblock %}
+
+{% block content %}
+<!--<div id="div_title" style="padding-bottom:2ex;padding-right:362px"><h3><img src="images/item.png" style="vertical-align:middle" /> Item : {{ item }}</h3></div>-->
+
+<div class="{% if item.file %}{% if item.public_access == 'full' or public_access or user.is_staff %}with-rightcol{% endif %}{% endif %}">
+ {% if item.file %}
+ {% if public_access or user.is_staff %}
+ <div id="player_maximized" class="ts-skin-lab">
+ <a href="#" class="toggle">Minimize</a>
+ <div class="wazing"></div>
+ </div>
+ <div id="rightcol">
+ <div id="player_minimized" class="ts-skin-lab">
+ <a href="#" class="toggle">Maximize</a>
+ <div class="wazing"></div>
+ <div id="player" class="ts-player">
+ <div class="ts-viewer">
+ <div class="ts-wave">
+ <div class="ts-image-container">
+ <a href="{% url telemeta-item-export item.public_id,"mp3" %}">
+ <img class="ts-image" src="{% url telemeta-item-visualize item.public_id,visualizer_id,360,130 %}"
+ alt="" /></a>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ <div class="item_visualization" id="item_visualization_id">
+ <form id="visualizer_id_form" method="get" action="#">
+ <img src="images/plots.png" style="vertical-align:middle" /> Visualization :
+ <select id="visualizer_id" name="visualizer_id">
+ {% for v in visualizers %}
+ <option value="{% url telemeta-item-visualize item.public_id,v.id,"WIDTH","HEIGHT" %}">
+ {{v.name}}</option>
+ {% endfor %}
+ </select>
+ <input style="visibility: hidden;" type="submit" value="Set" />
+ </form>
+
+ <!--
+ <form method="get" action="#">
+ <p> Vamp plugin analysis</p>
+ <select name="vamp_id">
+ {% for plugin in vamp_plugins %}
+ <option value="{{ plugin }}" {% ifequal plugin vamp_id %} selected="selected" {% endifequal %}>
+ {{ plugin }}</option>
+ {% endfor %}
+ </select>
+ <input type="submit" value="Get" />
+ </form>
+ -->
+ </div>
+
+ <div id="tabs_container">
+ <!-- this div will be hidden when everything is fully loaded-->
+ <span id="loading_span" href="#"><img style="vertical-align:middle" src="/images/wait.gif"/>
+ <span id="loading_span_text">Loading...</span></span>
+ <a id="tab_analysis" style="display:none" name ="analyzer_div_id" href="#">{% trans "Analysis" %}</a>
+ <a id="tab_markers" style="display:none" name="markers_div_id" href="#">{% trans "Markers" %}</a>
+ </div>
+
+ <div class="markers" id="markers_div_id"></div>
+
+ <div class="analyzer" id="analyzer_div_id">
+ <table width="100%">
+ <tr class="analyzer-title">
+ <td>{% trans "Property" %}</td>
+ <td>{% trans "Value" %}</td>
+ <td>{% trans "Unit" %}</td>
+ </tr>
+ <!-- {% for analyser in analysers %}
+ <tr class="analyzer-line">
+ <td>
+ {{ analyser.name }}
+ </td>
+ <td>
+ {{ analyser.value }}
+ </td>
+ <td>
+ {{ analyser.unit }}
+ </td>
+ </tr>
+ {% endfor %}-->
+ </table>
+ </div>
+ <!--</div>-->
+
+ {% if audio_export_enabled %}
+ <div class="exporter">
+ <p><img src="images/download.png" style="vertical-align:middle" /> {% trans "Download:" %}
+ {% for format in export_formats %}
+ <a href="{% url telemeta-item-export item.public_id,format.extension %}">
+ <img src="images/{{ format.extension }}.png" style="vertical-align:middle" alt="{{ format.extension }}" /></a>
+ {% endfor %}</p>
+ </div>
+ {% endif %}
+
+ </div>
+ {% endif %}
+ {% endif %}
+
+ {% block infos %}
+ <div class="infos">
+ {% block general_info %}
+ <dl class="listing">
+ {% dl_field item "title" %}
+ {% dl_field item "alt_title" %}
+ {% dl_field item "collector" %}
+ <dt>{% field_label item "collection" %}</dt>
+ <dd><a href="{% url telemeta-collection-detail item.collection.public_id %}">{{ item.collection }}</a></dd>
+ {% if item.recorded_from_date %}
+ <dt>{% trans "Recording date" %}</dt>
+ <dd>{{ item.recorded_from_date }} {{ item.recorded_to_date|prepend:" - " }}</dd>
+ {% endif %}
+ </dl>
+ {% endblock general_info %}
+ </div>
+ <div class="extraInfos">
+ {% block geoethnic_data %}
+ <div>
+ <h4><a href="#">{% trans "Geographic and cultural informations" %}</a></h4>
+ <dl class="listing">
+ {% if item.location %}
+ <dt>{% trans "Location" %}</dt>
+ <dd>{{ item.location.fullnames|join:"<br/>" }}</dd>
+ {% endif %}
+ {% dl_field item "location_comment" %}
+ {% dl_field item "cultural_area" %}
+ {% dl_field item "ethnic_group" %}
+ {% dl_field item "context_comment" %}
+ {% dl_field item "keywords" join with ", " %}
+ </dl>
+ </div>
+ {% endblock geoethnic_data %}
+ </div>
+ <div class="extraInfos">
+ {% block musical_data %}
+ <div>
+ <h4><a href="#">{% trans "Musical informations" %}</a></h4>
+ <dl class="listing">
+ {% dl_field item "vernacular_style" %}
+ {% dl_field item "generic_style" %}
+ {% dl_field item "author" %}
+ </dl>
+ {% if item.performances %}
+ <div class="instruments">
+ <table class="instruments">
+ <thead>
+ <tr>
+ <td>{% field_label "MediaItemPerformance" "instruments_num" %}</td>
+ <td>{% field_label "MediaItemPerformance" "instrument" %}</td>
+ <td>{% field_label "MediaItemPerformance" "alias" %}</td>
+ <td>{% field_label "MediaItemPerformance" "musicians" %}</td>
+ </tr>
+ </thead>
+ <tbody>
+ {% for performance in item.performances.all %}
+ <tr>
+ <td>{{ performance.instruments_num }}</td>
+ <td>{{ performance.instrument|default:"" }}</td>
+ <td>{{ performance.alias|default:"" }}</td>
+ <td>{{ performance.musicians }}</td>
+ </tr>
+ {% endfor %}
+ </tbody>
+ </table>
+ </div>
+ {% endif %}
+ </div>
+ {% endblock musical_data %}
+ </div>
+ <div class="extraInfos">
+ {% block general_data %}
+ <div>
+ <h4><a href="#">{% trans "General informations" %}</a></h4>
+ <dl class="listing">
+ {% dl_field item "comment" %}
+ {% dl_field item "collector_selection" %}
+ </dl>
+ </div>
+ {% endblock general_data %}
+ </div>
+ <div class="extraInfos">
+ {% block archive_data %}
+ <div>
+ <h4><a href="#">{% trans "Archiving data" %}</a></h4>
+ <dl class="listing">
+ {% dl_field item "code" %}
+ {% dl_field item "old_code" %}
+ {% dl_field item "track" %}
+ {% dl_field item "creator_reference" %}
+ {% dl_field item "external_references" %}
+ {% dl_field item "public_access_label" %}
+ </dl>
+ </div>
+ {% endblock archive_data %}
+ </div>
+ <div class="extraInfos">
+ {% block technical_data %}
+ <div>
+ <h4><a href="#">{% trans "Technical data" %}</a></h4>
+ <div>
+ <dl class="listing">
+ <dt>{% trans "Media type" %}</dt><dd>{% trans "Audio" %}</dd>
+ {% dl_field item "approx_duration" %}
+ </dl>
+ </div>
+ </div>
+ {% endblock technical_data %}
+ </div>
+ {% endblock infos %}
+</div> <!-- with-rightcol -->
+{% endblock %}
+{% else %}
+<p>No such item</p>
+{% endif %}
{% if item %}
-{% block submenu %}
-<div>
+{% block title %}
+ <img src="images/item.png" style="vertical-align:middle" /> Item : NEW
+{% endblock %}
+{% block title_buttons %}
{% if perms.telemeta.add_mediaitem %}
- {% block tools %}
<a href="{% url telemeta-items %}"
class="component_icon button icon_cancel">{% trans "Cancel" %}</a>
- {% endblock tools %}
-
{% endif %}
-</div>
{% endblock %}
{% block content %}
-<h3><img src="images/item.png" style="vertical-align:middle" /> Item : NEW</h3>
-
{% block infos %}
<div class="infos">
<form method="POST" id="_addItemForm" action="" enctype="multipart/form-data">{% csrf_token %}
-{% extends "telemeta/mediaitem_detail.html" %}
+{% extends "telemeta/mediaitem.html" %}
{% load telemeta_utils %}
{% load i18n %}
{% block extra_javascript %}
{% endblock %}
-{% block submenu %}
-<div>
+{% block title %}
+ <img src="images/item.png" style="vertical-align:middle" /> Item : {{ item }}
+{% endblock %}
+{% block title_buttons %}
{% if user.is_authenticated and perms.telemeta.add_mediaitem %}
- {% block tools %}
<a href="{% url telemeta-item-detail item.public_id %}" class="component_icon button icon_cancel">{% trans "Cancel" %}</a>
- {% endblock tools %}
{% endif %}
-</div>
{% endblock %}
{% block content %}
-<h3><img src="images/item.png" style="vertical-align:middle" /> Item : {{ item }}</h3>
-
{% block infos %}
<div class="infos">
<form enctype="multipart/form-data" id="_mediaItemCopyForm" method="POST" action="">{% csrf_token %}
-{% extends "telemeta/base.html" %}
+{% extends "telemeta/mediaitem.html" %}
{% load telemeta_utils %}
{% load i18n %}
-{% block head_title %}{% trans "Item" %}- {{ block.super }}{% endblock %}
-
-{% block stylesheets %}
-{{ block.super }}
-<link rel="stylesheet" type="text/css" href="{% url telemeta-timeside "css/timeside.css" %}" />
- <link rel="stylesheet" type="text/css" href="{% url telemeta-timeside "skins/lab/style.css" %}" />
- <link rel="stylesheet" type="text/css" href="{% url telemeta-css "player.css" %}" />
- {% endblock %}
-
- {% block extra_javascript %}
- <!--<script src="{% url telemeta-js "wz_jsgraphics.js" %}" type="text/javascript"></script>-->
-<script src="{% url telemeta-js "soundmanager2.js" %}" type="text/javascript"></script>
-<script src="{% url telemeta-timeside "src/playlist.js" %}" type="text/javascript"></script>
-<script type="text/javascript">
- soundManager.url = '{% url telemeta-swf "./" %}';
- soundManager.flashVersion = 9;
- soundManager.useMovieStar = true; // enable MP4/M4A/AAC
- soundManager.debugMode = false;
- soundManager.allowPolling = true;
-
- var setupPlaylist = function(){
- {% if user.is_authenticated %}
- var p = playlistUtils;
- {% for playlist in playlists %}
- p.addPlaylist('{{ playlist.playlist.title }}','{{playlist.playlist.public_id}}');
- {% endfor %}
-
- {% endif %}
- {% if item %}
- var anchor = jQuery('#_add_to_playlist');
- if(anchor.length){
- anchor.click(function(evtObj_){
- p.showPopupAddToPlaylist(evtObj_,'item','{{item.public_id}}','item added to selected playlist');return false;
- });
- }
- {% endif %}
- };
-
- {% if item %}
- var ITEM_PUBLIC_ID = '{{item.public_id}}';
- {% endif %}
-
- var scripts = ["{% url telemeta-js "wz_jsgraphics.js" %}",
- //"{% url telemeta-timeside "src/playlist.js" %}",
- "{% url telemeta-timeside "src/timeside.js" %}","{% url telemeta-js "playerUtils.js" %}"];
-
- var _sound_manager_loaded=false;
- var _jQuery_loaded = false;
-
- jQuery(document).ready(function(){
- _jQuery_loaded=true;
- if(_sound_manager_loaded){
- loadScripts(scripts, function(){loadPlayer('{% url telemeta-item-analyze-xml item.public_id %}',$('.ts-wave a').attr('href'));setupPlaylist()});
- }
- });
- //$('.ts-wave a').attr('href')
- soundManager.onready(function() {
- _sound_manager_loaded=true;
- if(_jQuery_loaded){
- loadScripts(scripts, function(){loadPlayer('{% url telemeta-item-analyze-xml item.public_id %}',$('.ts-wave a').attr('href'));setupPlaylist()});
- }
- });
-
-</script>
-<!--item.approx_duration-->
-
-{% endblock %}
-
-
-{% if item %}
-{% block submenu %}
+{% block title %}
+<img src="images/item.png" style="vertical-align:middle" /> Item : {{ item }}
{% endblock %}
-
-{% block content_header %}
-<table><tr><td>
- <h3><img src="images/item.png" style="vertical-align:middle" /> Item : {{ item }}</h3>
- </td><td class="rightcol">
- {% block tools %}
- {% if user.is_authenticated and perms.telemeta.change_mediaitem %}
+{% block title_buttons %}
+ <div class="fixedWidthAsPlayer">
+ {% if user.is_authenticated and perms.telemeta.change_mediaitem %}
<a href="{% url telemeta-item-edit item.public_id %}" class="component_icon button icon_edit">{% trans "Edit" %}</a>
<a href="{% url telemeta-item-copy item.public_id %}" class="component_icon button icon_copy">{% trans "Copy" %}</a>
- {% endif %}
- {% if user.is_authenticated %}
+ {% endif %}
+ {% if user.is_authenticated %}
<a id="_add_to_playlist" href='#' class="component_icon button icon_add">{% trans "Add to playlist" %}</a>
-
- {% endif %}
- <a href="{% url telemeta-item-detail previous %}" class="component_icon button icon_previous">{% trans "Previous" %}</a>
- <a href="{% url telemeta-item-detail next %}" class="component_icon button icon_next">{% trans "Next" %}</a>
- <a href="{% url telemeta-item-dublincore item.public_id %}" class="component_icon button icon_dublin_core">Dublin Core</a>
- {% endblock tools %}
- </td></tr></table>
-{% endblock %}
-
-{% block content %}
-<!--<div id="div_title" style="padding-bottom:2ex;padding-right:362px"><h3><img src="images/item.png" style="vertical-align:middle" /> Item : {{ item }}</h3></div>-->
-
-<div class="{% if item.file %}{% if item.public_access == 'full' or public_access or user.is_staff %}with-rightcol{% endif %}{% endif %}">
- {% if item.file %}
- {% if public_access or user.is_staff %}
- <div id="player_maximized" class="ts-skin-lab">
- <a href="#" class="toggle">Minimize</a>
- <div class="wazing"></div>
- </div>
- <div id="rightcol">
- <div id="player_minimized" class="ts-skin-lab">
- <a href="#" class="toggle">Maximize</a>
- <div class="wazing"></div>
- <div id="player" class="ts-player">
- <div class="ts-viewer">
- <div class="ts-wave">
- <div class="ts-image-container">
- <a href="{% url telemeta-item-export item.public_id,"mp3" %}">
- <img class="ts-image" src="{% url telemeta-item-visualize item.public_id,visualizer_id,360,130 %}"
- alt="" /></a>
- </div>
- </div>
- </div>
- </div>
- </div>
- <div class="item_visualization" id="item_visualization_id">
- <form id="visualizer_id_form" method="get" action="#">
- <img src="images/plots.png" style="vertical-align:middle" /> Visualization :
- <select id="visualizer_id" name="visualizer_id">
- {% for v in visualizers %}
- <option value="{% url telemeta-item-visualize item.public_id,v.id,"WIDTH","HEIGHT" %}">
- {{v.name}}</option>
- {% endfor %}
- </select>
- <input style="visibility: hidden;" type="submit" value="Set" />
- </form>
-
- <!--
- <form method="get" action="#">
- <p> Vamp plugin analysis</p>
- <select name="vamp_id">
- {% for plugin in vamp_plugins %}
- <option value="{{ plugin }}" {% ifequal plugin vamp_id %} selected="selected" {% endifequal %}>
- {{ plugin }}</option>
- {% endfor %}
- </select>
- <input type="submit" value="Get" />
- </form>
- -->
- </div>
-
- <div id="tabs_container">
- <!-- this div will be hidden when everything is fully loaded-->
- <span id="loading_span" href="#"><img style="vertical-align:middle" src="/images/wait.gif"/>
- <span id="loading_span_text">Loading...</span></span>
- <a id="tab_analysis" style="display:none" name ="analyzer_div_id" href="#">{% trans "Analysis" %}</a>
- <a id="tab_markers" style="display:none" name="markers_div_id" href="#">{% trans "Markers" %}</a>
- </div>
-
- <div class="markers" id="markers_div_id"></div>
-
- <div class="analyzer" id="analyzer_div_id">
- <table width="100%">
- <tr class="analyzer-title">
- <td>{% trans "Property" %}</td>
- <td>{% trans "Value" %}</td>
- <td>{% trans "Unit" %}</td>
- </tr>
- <!-- {% for analyser in analysers %}
- <tr class="analyzer-line">
- <td>
- {{ analyser.name }}
- </td>
- <td>
- {{ analyser.value }}
- </td>
- <td>
- {{ analyser.unit }}
- </td>
- </tr>
- {% endfor %}-->
- </table>
- </div>
- <!--</div>-->
-
- {% if audio_export_enabled %}
- <div class="exporter">
- <p><img src="images/download.png" style="vertical-align:middle" /> {% trans "Download:" %}
- {% for format in export_formats %}
- <a href="{% url telemeta-item-export item.public_id,format.extension %}">
- <img src="images/{{ format.extension }}.png" style="vertical-align:middle" alt="{{ format.extension }}" /></a>
- {% endfor %}</p>
- </div>
- {% endif %}
-
- </div>
- {% endif %}
- {% endif %}
-
- {% block infos %}
- <div class="infos">
- {% block general_info %}
- <dl class="listing">
- {% dl_field item "title" %}
- {% dl_field item "alt_title" %}
- {% dl_field item "collector" %}
- <dt>{% field_label item "collection" %}</dt>
- <dd><a href="{% url telemeta-collection-detail item.collection.public_id %}">{{ item.collection }}</a></dd>
- {% if item.recorded_from_date %}
- <dt>{% trans "Recording date" %}</dt>
- <dd>{{ item.recorded_from_date }} {{ item.recorded_to_date|prepend:" - " }}</dd>
- {% endif %}
- </dl>
- {% endblock general_info %}
- </div>
- <div class="extraInfos">
- {% block geoethnic_data %}
- <div>
- <h4><a href="#">{% trans "Geographic and cultural informations" %}</a></h4>
- <dl class="listing">
- {% if item.location %}
- <dt>{% trans "Location" %}</dt>
- <dd>{{ item.location.fullnames|join:"<br/>" }}</dd>
- {% endif %}
- {% dl_field item "location_comment" %}
- {% dl_field item "cultural_area" %}
- {% dl_field item "ethnic_group" %}
- {% dl_field item "context_comment" %}
- {% dl_field item "keywords" join with ", " %}
- </dl>
- </div>
- {% endblock geoethnic_data %}
- </div>
- <div class="extraInfos">
- {% block musical_data %}
- <div>
- <h4><a href="#">{% trans "Musical informations" %}</a></h4>
- <dl class="listing">
- {% dl_field item "vernacular_style" %}
- {% dl_field item "generic_style" %}
- {% dl_field item "author" %}
- </dl>
- {% if item.performances %}
- <div class="instruments">
- <table class="instruments">
- <thead>
- <tr>
- <td>{% field_label "MediaItemPerformance" "instruments_num" %}</td>
- <td>{% field_label "MediaItemPerformance" "instrument" %}</td>
- <td>{% field_label "MediaItemPerformance" "alias" %}</td>
- <td>{% field_label "MediaItemPerformance" "musicians" %}</td>
- </tr>
- </thead>
- <tbody>
- {% for performance in item.performances.all %}
- <tr>
- <td>{{ performance.instruments_num }}</td>
- <td>{{ performance.instrument|default:"" }}</td>
- <td>{{ performance.alias|default:"" }}</td>
- <td>{{ performance.musicians }}</td>
- </tr>
- {% endfor %}
- </tbody>
- </table>
- </div>
- {% endif %}
- </div>
- {% endblock musical_data %}
- </div>
- <div class="extraInfos">
- {% block general_data %}
- <div>
- <h4><a href="#">{% trans "General informations" %}</a></h4>
- <dl class="listing">
- {% dl_field item "comment" %}
- {% dl_field item "collector_selection" %}
- </dl>
- </div>
- {% endblock general_data %}
- </div>
- <div class="extraInfos">
- {% block archive_data %}
- <div>
- <h4><a href="#">{% trans "Archiving data" %}</a></h4>
- <dl class="listing">
- {% dl_field item "code" %}
- {% dl_field item "old_code" %}
- {% dl_field item "track" %}
- {% dl_field item "creator_reference" %}
- {% dl_field item "external_references" %}
- {% dl_field item "public_access_label" %}
- </dl>
- </div>
- {% endblock archive_data %}
- </div>
- <div class="extraInfos">
- {% block technical_data %}
- <div>
- <h4><a href="#">{% trans "Technical data" %}</a></h4>
- <div>
- <dl class="listing">
- <dt>{% trans "Media type" %}</dt><dd>{% trans "Audio" %}</dd>
- {% dl_field item "approx_duration" %}
- </dl>
- </div>
- </div>
- {% endblock technical_data %}
- </div>
- {% endblock infos %}
-</div> <!-- with-rightcol -->
+ {% endif %}
+ <a href="{% url telemeta-item-detail previous %}" class="component_icon button icon_previous">{% trans "Previous" %}</a>
+ <a href="{% url telemeta-item-detail next %}" class="component_icon button icon_next">{% trans "Next" %}</a>
+ <a href="{% url telemeta-item-dublincore item.public_id %}" class="component_icon button icon_dublin_core">Dublin Core</a>
+ </div>
{% endblock %}
-{% else %}
-<p>No such item</p>
-{% endif %}
-{% extends "telemeta/mediaitem_detail.html" %}\r
+{% extends "telemeta/mediaitem.html" %}\r
{% load telemeta_utils %}\r
{% load i18n %}\r
\r
{% if item %}\r
-{% block submenu %}\r
- <div><a href="{% url telemeta-item-detail item.public_id %}">{% trans "Normal View" %}</a></div>\r
+{% block title_buttons %}\r
+ <a class="component_icon button icon_previous" href="{% url telemeta-item-detail item.public_id %}">{% trans "Normal View" %}</a>\r
{% endblock %}\r
\r
{% block infos %}\r
-{% extends "telemeta/mediaitem_detail.html" %}
+{% extends "telemeta/mediaitem.html" %}
{% load i18n %}
{% load telemeta_utils %}
- {% block tools %}
+{% block title %}
+
+ {% endblock %}
+ {% block title_buttons %}
<a href="{% url telemeta-item-detail item.public_id %}" class="component_icon button icon_cancel">{% trans "Cancel" %}</a>
- {% endblock tools %}
+ {% endblock %}
{% block infos %}
<div class="infos">
{% block head_title %}{% trans "Media Items" %} - {{ block.super }}{% endblock %}
-
-{% block submenu %}
- <div class="buttons">
+{% block title %}
+ <img src="images/item.png" style="vertical-align:middle" /> {% trans "Media Items" %}
+{% endblock %}
+{% block title_buttons %}
{% if user.is_authenticated and perms.telemeta.add_mediaitem %}
<a href="{% url telemeta-item-add %}" class="component_icon button icon_add">{% trans "Add" %}</a>
{% endif %}
- </div>
{% endblock %}
{% block content %}
-<h3><img src="images/item.png" style="vertical-align:middle" /> {% trans "Media Items" %}</h3>
{% with object_list as items %}
<div class="fullpage">
{% include "telemeta/inc/mediaitem_list.html" %}
{% load i18n %}
{% load telemeta_utils %}
-{% block tools %}
- <a href="{% url telemeta-profile-detail usr.username %}" class="component_icon button icon_cancel">{% trans "Cancel" %}</a>
-{% endblock %}
+<a href="{% url telemeta-profile-detail usr.username %}" class="component_icon button icon_cancel">{% trans "Cancel" %}</a>
{% block content %}
<h3>{% trans "User profile" %} : {{ usr.username }}</h3>