From c2f6af69f4147adf2a0ab19b681566c81649257d Mon Sep 17 00:00:00 2001 From: riccardo Date: Wed, 6 Apr 2011 16:39:36 +0200 Subject: [PATCH] fixed old submenu div, now block title and title_buttons. The latter can stretch or have a fixed width according to the style added: telemeta/templates/telemeta/mediaitem.html telemeta/templates/telemeta_default/mediaitem.html modified: telemeta/htdocs/css/telemeta.css telemeta/htdocs/css/telemeta_ie6.css telemeta/htdocs/js/application.js telemeta/htdocs/timeside/src/controller.js telemeta/htdocs/timeside/src/markermap.js telemeta/templates/telemeta_default/base.html telemeta/templates/telemeta_default/collection_add.html telemeta/templates/telemeta_default/collection_detail.html telemeta/templates/telemeta_default/collection_detail_dc.html telemeta/templates/telemeta_default/collection_edit.html telemeta/templates/telemeta_default/collection_list.html telemeta/templates/telemeta_default/geo_continents.html telemeta/templates/telemeta_default/mediaitem_add.html telemeta/templates/telemeta_default/mediaitem_copy.html telemeta/templates/telemeta_default/mediaitem_detail.html telemeta/templates/telemeta_default/mediaitem_detail_dc.html telemeta/templates/telemeta_default/mediaitem_edit.html telemeta/templates/telemeta_default/mediaitem_list.html telemeta/templates/telemeta_default/profile_edit.html unknown: telemeta/htdocs/images/wait.gif telemeta/htdocs/timeside/skins/lab/img/empty.png telemeta/htdocs/timeside/src/marker.js.moved --- telemeta/htdocs/css/telemeta.css | 66 ++-- telemeta/htdocs/css/telemeta_ie6.css | 4 +- telemeta/htdocs/js/application.js | 43 +-- telemeta/htdocs/timeside/src/controller.js | 16 - telemeta/htdocs/timeside/src/markermap.js | 6 +- telemeta/templates/telemeta/mediaitem.html | 1 + telemeta/templates/telemeta_default/base.html | 11 +- .../telemeta_default/collection_add.html | 8 +- .../telemeta_default/collection_detail.html | 14 +- .../collection_detail_dc.html | 8 +- .../telemeta_default/collection_edit.html | 4 +- .../telemeta_default/collection_list.html | 9 +- .../telemeta_default/geo_continents.html | 8 +- .../templates/telemeta_default/mediaitem.html | 295 ++++++++++++++++ .../telemeta_default/mediaitem_add.html | 12 +- .../telemeta_default/mediaitem_copy.html | 13 +- .../telemeta_default/mediaitem_detail.html | 317 +----------------- .../telemeta_default/mediaitem_detail_dc.html | 6 +- .../telemeta_default/mediaitem_edit.html | 9 +- .../telemeta_default/mediaitem_list.html | 9 +- .../telemeta_default/profile_edit.html | 4 +- 21 files changed, 410 insertions(+), 453 deletions(-) create mode 100644 telemeta/templates/telemeta/mediaitem.html create mode 100644 telemeta/templates/telemeta_default/mediaitem.html diff --git a/telemeta/htdocs/css/telemeta.css b/telemeta/htdocs/css/telemeta.css index 3a95847a..c504d503 100644 --- a/telemeta/htdocs/css/telemeta.css +++ b/telemeta/htdocs/css/telemeta.css @@ -54,18 +54,16 @@ a img { border: none; } } #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; @@ -85,7 +83,7 @@ a img { border: none; } #content li a { padding: .1em 0; } -#content h3, #content_header h3 { +#content h3 { color: #6a0307; font-weight: bold; display: inline; @@ -97,56 +95,40 @@ a img { border: none; } 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*/ @@ -1056,7 +1038,7 @@ a.image-link { .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; diff --git a/telemeta/htdocs/css/telemeta_ie6.css b/telemeta/htdocs/css/telemeta_ie6.css index e546a4a8..4b3fb5f9 100644 --- a/telemeta/htdocs/css/telemeta_ie6.css +++ b/telemeta/htdocs/css/telemeta_ie6.css @@ -1,4 +1,4 @@ /* Min-width */ -#submenu h3, #submenu div { +/*#submenu h3, #submenu div { height: 1.6em; -} +}*/ diff --git a/telemeta/htdocs/js/application.js b/telemeta/htdocs/js/application.js index 918601ca..fbb40187 100644 --- a/telemeta/htdocs/js/application.js +++ b/telemeta/htdocs/js/application.js @@ -227,20 +227,20 @@ var popup={ return div; }, className: 'component', - divShadow: function(){ - var divShadow = this.jQuery('
').css({ //this is _cfg_ - position: 'absolute', - display: 'none', - overflow:'visible', - padding: '0 !important', //otherwise setting divShadow dimension is tricky - backgroundColor:'#000 !important', //shadow must be black - zIndex:999 - }); - if(this.className){ - divShadow.addClass(this.className); - } - return divShadow; - }, +// divShadow: function(){ +// var divShadow = this.jQuery('
').css({ //this is _cfg_ +// position: 'absolute', +// display: 'none', +// overflow:'visible', +// padding: '0 !important', //otherwise setting divShadow dimension is tricky +// backgroundColor:'#000 !important', //shadow must be black +// zIndex:999 +// }); +// if(this.className){ +// divShadow.addClass(this.className); +// } +// return divShadow; +// }, // mouseDownNamespace : "mousedown.popup__", // keyDownNamespace : "keydown.popup__", @@ -363,7 +363,7 @@ var popup={ var windowH = wdow.height(); var windowW = wdow.width(); var position = div.offset(); - var shadowOffset=2; + var shadowOffset=5; var size = { width:div.outerWidth(true)+shadowOffset, height:div.outerHeight(true)+shadowOffset @@ -397,10 +397,15 @@ var popup={ }; //setting width on a div means the width(), //but calculations here are made according to outerWidth(true), so we need this variable (se below) + //the shadow in the background will be created according to the actual div size + //However, since we do not specify neither width nor height, the calculation of the div size + //works if maxWidth and maxHeight do set a width and height. In order to do so, they + //must be lower or equal to the actual div width and height. That's why the "min" here below:' div.css({ - 'maxWidth': maxSize.width-divPadding.left, - 'maxHeight': maxSize.height-divPadding.top + 'maxWidth': Math.min(div.width(), maxSize.width-divPadding.left), + 'maxHeight': Math.min(div.height(), maxSize.height-divPadding.top) }); + //last thing: if invoker element exist, set width at least invoker element width if(invokerElement){ var iEw = invokerElement.outerWidth(); //no margins considered @@ -410,10 +415,8 @@ var popup={ }); } } - //var divShadow = this._cfg_.divShadow().insertAfter(div); - + //now we can build the divShadow var divShadow = div.clone(false,false).empty().css({'zIndex':999,'borderColor':'#000','display':'none','backgroundColor':'#000'}).insertAfter(div); - //store the divs to be removed this._cfg_.divsToDelete = [div,divShadow]; //add a listener to the document. If one of the content children is clicked/keypressed, diff --git a/telemeta/htdocs/timeside/src/controller.js b/telemeta/htdocs/timeside/src/controller.js index 706d1c91..0683a511 100644 --- a/telemeta/htdocs/timeside/src/controller.js +++ b/telemeta/htdocs/timeside/src/controller.js @@ -21,8 +21,6 @@ TimeSide(function($N) { this.cfg.player = new $N.Player(this.cfg.player); } this._setupPlayer(); - //setting the divmarkers - //this.cfg.map.observe('add') this.loadHTTP(); }, @@ -30,19 +28,12 @@ TimeSide(function($N) { _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)); @@ -50,11 +41,6 @@ TimeSide(function($N) { }, - -// _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) { @@ -168,9 +154,7 @@ TimeSide(function($N) { } util.setUpTabs.apply(util, [tabIndex]); -// setTabs(tabIndex); }; - //json(param, method, onSuccesFcn(data, textStatus, jqXHR), onErrorFcn(jqXHR, textStatus, errorThrown)) json([itemId],"telemeta.get_markers", onSuccess); } }); diff --git a/telemeta/htdocs/timeside/src/markermap.js b/telemeta/htdocs/timeside/src/markermap.js index 7ab4d0df..b7ecf7b1 100644 --- a/telemeta/htdocs/timeside/src/markermap.js +++ b/telemeta/htdocs/timeside/src/markermap.js @@ -38,15 +38,13 @@ TimeSide(function($N, $J) { 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'){ diff --git a/telemeta/templates/telemeta/mediaitem.html b/telemeta/templates/telemeta/mediaitem.html new file mode 100644 index 00000000..7665a03f --- /dev/null +++ b/telemeta/templates/telemeta/mediaitem.html @@ -0,0 +1 @@ +{% extends "telemeta_default/mediaitem.html" %} diff --git a/telemeta/templates/telemeta_default/base.html b/telemeta/templates/telemeta_default/base.html index c42e1de0..c05199f0 100644 --- a/telemeta/templates/telemeta_default/base.html +++ b/telemeta/templates/telemeta_default/base.html @@ -81,13 +81,12 @@ {% endblock %}
- -
-{% block content_header %}{% endblock %} -
+
+ + + +

{% block title %}{% endblock %}

{% block title_buttons %}{% endblock %}
{% block content %}{% endblock %}
diff --git a/telemeta/templates/telemeta_default/collection_add.html b/telemeta/templates/telemeta_default/collection_add.html index 6d0c0bbf..c1d53e4e 100644 --- a/telemeta/templates/telemeta_default/collection_add.html +++ b/telemeta/templates/telemeta_default/collection_add.html @@ -2,12 +2,8 @@ {% load i18n %} {% load telemeta_utils %} -{% block submenu %} -
- {% block tools %} - {% trans "Cancel" %} - {% endblock tools %} -
+{% block title_buttons %} + {% trans "Cancel" %} {% endblock %} diff --git a/telemeta/templates/telemeta_default/collection_detail.html b/telemeta/templates/telemeta_default/collection_detail.html index 6c9ccc94..f852fd7b 100644 --- a/telemeta/templates/telemeta_default/collection_detail.html +++ b/telemeta/templates/telemeta_default/collection_detail.html @@ -33,9 +33,11 @@ {% if collection %} -{% block submenu %} -
- {% block tools %} +{% block title %} + Collection: {{ collection }} +{% endblock %} + +{% block title_buttons %} Dublin Core {% if user.is_authenticated and perms.telemeta.change_mediacollection %} {% trans "Edit" %} @@ -44,14 +46,10 @@ {% if user.is_authenticated %} {% trans "Add to playlist" %} {% endif %} - {% endblock tools %} - - -
{% endblock %} {% block content %} -

Collection: {{ collection }}

+
{% if collection.has_mediafile %}
diff --git a/telemeta/templates/telemeta_default/collection_detail_dc.html b/telemeta/templates/telemeta_default/collection_detail_dc.html index f102c36e..e100ffde 100644 --- a/telemeta/templates/telemeta_default/collection_detail_dc.html +++ b/telemeta/templates/telemeta_default/collection_detail_dc.html @@ -5,9 +5,11 @@ {% block head_title %}{% trans "Collection" %}{{collection|prepend:': '}} - {{ block.super }}{% endblock %} {% if collection %} -{% block submenu %} -

Collection: {{ collection }}

-
{% trans "Normal View" %}
+{% block title %} + Collection: {{ collection }} +{% endblock %} +{% block title_buttons %} + {% trans "Normal View" %} {% endblock %} {% block content %} diff --git a/telemeta/templates/telemeta_default/collection_edit.html b/telemeta/templates/telemeta_default/collection_edit.html index fd7eeb89..75f13113 100644 --- a/telemeta/templates/telemeta_default/collection_edit.html +++ b/telemeta/templates/telemeta_default/collection_edit.html @@ -2,9 +2,7 @@ {% load i18n %} {% load telemeta_utils %} -{% block tools %} - {% trans "Cancel" %} -{% endblock %} +{% trans "Cancel" %} {% block infos %}
diff --git a/telemeta/templates/telemeta_default/collection_list.html b/telemeta/templates/telemeta_default/collection_list.html index a3386ca7..8e3a3f26 100644 --- a/telemeta/templates/telemeta_default/collection_list.html +++ b/telemeta/templates/telemeta_default/collection_list.html @@ -4,20 +4,19 @@ {% block head_title %}{% trans "Media Collections" %} - {{ block.super }}{% endblock %} -{% block submenu %} -
+{% block title%} + {% trans "Media Collections" %} +{% endblock %} +{% block title_buttons %} {% trans "All" %} {% trans "Novel" %} {% trans "Published" %} {% if user.is_authenticated and perms.telemeta.add_mediacollection %} {% trans "Add" %} {% endif %} -
{% endblock %} {% block content %} -

{% trans "Media Collections" %}

- {% with object_list as collections %}
{% include "telemeta/inc/collection_list.html" %} diff --git a/telemeta/templates/telemeta_default/geo_continents.html b/telemeta/templates/telemeta_default/geo_continents.html index 8bca2319..d20e8a4f 100644 --- a/telemeta/templates/telemeta_default/geo_continents.html +++ b/telemeta/templates/telemeta_default/geo_continents.html @@ -16,16 +16,16 @@ var resourceMap = new ResourceMap('.continents', { {% endif %} {% endblock %} -{% block submenu %} -
+{% block title %} + {% trans "Geographic Navigator" %} +{% endblock %} +{% block title_buttons %} {% if continents %} {% trans "Map" %} | {% trans "List" %} {% endif %} -
{% endblock %} {% block content %} -

{% trans "Geographic Navigator" %}

{% if continents %}
    {% for group in continents %} diff --git a/telemeta/templates/telemeta_default/mediaitem.html b/telemeta/templates/telemeta_default/mediaitem.html new file mode 100644 index 00000000..a13faeb9 --- /dev/null +++ b/telemeta/templates/telemeta_default/mediaitem.html @@ -0,0 +1,295 @@ +{% extends "telemeta/base.html" %} +{% load telemeta_utils %} +{% load i18n %} + +{% block head_title %}{% trans "Item" %}- {{ block.super }}{% endblock %} + +{% block stylesheets %} +{{ block.super }} + + + + {% endblock %} + + {% block extra_javascript %} + + + + + + +{% endblock %} + + +{% if item %} + +{% block title %} +{% endblock %} +{% block title_buttons %} +{% endblock %} + +{% block content %} + + +
    + {% if item.file %} + {% if public_access or user.is_staff %} +
    + Minimize +
    +
    +
    +
    + Maximize +
    +
    +
    +
    +
    + + +
    +
    +
    +
    +
    +
    +
    +  Visualization : + + +
    + + +
    + +
    + +   + Loading... + + +
    + +
    + +
    + + + + + + + +
    {% trans "Property" %}{% trans "Value" %}{% trans "Unit" %}
    +
    + + + {% if audio_export_enabled %} +
    +

    {% trans "Download:" %} + {% for format in export_formats %} + + {{ format.extension }} + {% endfor %}

    +
    + {% endif %} + +
    + {% endif %} + {% endif %} + + {% block infos %} +
    + {% block general_info %} +
    + {% dl_field item "title" %} + {% dl_field item "alt_title" %} + {% dl_field item "collector" %} +
    {% field_label item "collection" %}
    +
    {{ item.collection }}
    + {% if item.recorded_from_date %} +
    {% trans "Recording date" %}
    +
    {{ item.recorded_from_date }} {{ item.recorded_to_date|prepend:" - " }}
    + {% endif %} +
    + {% endblock general_info %} +
    +
    + {% block geoethnic_data %} +
    +

    {% trans "Geographic and cultural informations" %}

    +
    + {% if item.location %} +
    {% trans "Location" %}
    +
    {{ item.location.fullnames|join:"
    " }}
    + {% 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 ", " %} +
    +
    + {% endblock geoethnic_data %} +
    +
    + {% block musical_data %} +
    +

    {% trans "Musical informations" %}

    +
    + {% dl_field item "vernacular_style" %} + {% dl_field item "generic_style" %} + {% dl_field item "author" %} +
    + {% if item.performances %} +
    + + + + + + + + + + + {% for performance in item.performances.all %} + + + + + + + {% endfor %} + +
    {% field_label "MediaItemPerformance" "instruments_num" %}{% field_label "MediaItemPerformance" "instrument" %}{% field_label "MediaItemPerformance" "alias" %}{% field_label "MediaItemPerformance" "musicians" %}
    {{ performance.instruments_num }}{{ performance.instrument|default:"" }}{{ performance.alias|default:"" }}{{ performance.musicians }}
    +
    + {% endif %} +
    + {% endblock musical_data %} +
    +
    + {% block general_data %} +
    +

    {% trans "General informations" %}

    +
    + {% dl_field item "comment" %} + {% dl_field item "collector_selection" %} +
    +
    + {% endblock general_data %} +
    +
    + {% block archive_data %} +
    +

    {% trans "Archiving data" %}

    +
    + {% 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" %} +
    +
    + {% endblock archive_data %} +
    +
    + {% block technical_data %} +
    +

    {% trans "Technical data" %}

    +
    +
    +
    {% trans "Media type" %}
    {% trans "Audio" %}
    + {% dl_field item "approx_duration" %} +
    +
    +
    + {% endblock technical_data %} +
    + {% endblock infos %} +
    +{% endblock %} +{% else %} +

    No such item

    +{% endif %} diff --git a/telemeta/templates/telemeta_default/mediaitem_add.html b/telemeta/templates/telemeta_default/mediaitem_add.html index b85621be..70092706 100644 --- a/telemeta/templates/telemeta_default/mediaitem_add.html +++ b/telemeta/templates/telemeta_default/mediaitem_add.html @@ -6,21 +6,17 @@ {% if item %} -{% block submenu %} -
    +{% block title %} + Item : NEW +{% endblock %} +{% block title_buttons %} {% if perms.telemeta.add_mediaitem %} - {% block tools %} {% trans "Cancel" %} - {% endblock tools %} - {% endif %} -
    {% endblock %} {% block content %} -

    Item : NEW

    - {% block infos %}
    {% csrf_token %} diff --git a/telemeta/templates/telemeta_default/mediaitem_copy.html b/telemeta/templates/telemeta_default/mediaitem_copy.html index e4036188..ed03bef3 100644 --- a/telemeta/templates/telemeta_default/mediaitem_copy.html +++ b/telemeta/templates/telemeta_default/mediaitem_copy.html @@ -1,4 +1,4 @@ -{% extends "telemeta/mediaitem_detail.html" %} +{% extends "telemeta/mediaitem.html" %} {% load telemeta_utils %} {% load i18n %} @@ -7,19 +7,16 @@ {% block extra_javascript %} {% endblock %} -{% block submenu %} -
    +{% block title %} + Item : {{ item }} +{% endblock %} +{% block title_buttons %} {% if user.is_authenticated and perms.telemeta.add_mediaitem %} - {% block tools %} {% trans "Cancel" %} - {% endblock tools %} {% endif %} -
    {% endblock %} {% block content %} -

    Item : {{ item }}

    - {% block infos %}
    {% csrf_token %} diff --git a/telemeta/templates/telemeta_default/mediaitem_detail.html b/telemeta/templates/telemeta_default/mediaitem_detail.html index fb7d6e91..bd2cf46a 100644 --- a/telemeta/templates/telemeta_default/mediaitem_detail.html +++ b/telemeta/templates/telemeta_default/mediaitem_detail.html @@ -1,313 +1,22 @@ -{% 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 }} - - - - {% endblock %} - - {% block extra_javascript %} - - - - - - -{% endblock %} - - -{% if item %} -{% block submenu %} +{% block title %} + Item : {{ item }} {% endblock %} - -{% block content_header %} -
    -

    Item : {{ item }}

    -
    - {% block tools %} - {% if user.is_authenticated and perms.telemeta.change_mediaitem %} +{% block title_buttons %} +
    + {% if user.is_authenticated and perms.telemeta.change_mediaitem %} {% trans "Edit" %} {% trans "Copy" %} - {% endif %} - {% if user.is_authenticated %} + {% endif %} + {% if user.is_authenticated %} {% trans "Add to playlist" %} - - {% endif %} - {% trans "Previous" %} - {% trans "Next" %} - Dublin Core - {% endblock tools %} -
    -{% endblock %} - -{% block content %} - - -
    - {% if item.file %} - {% if public_access or user.is_staff %} -
    - Minimize -
    -
    -
    -
    - Maximize -
    -
    -
    -
    -
    - - -
    -
    -
    -
    -
    -
    - -  Visualization : - - - - - -
    - -
    - -   - Loading... - - -
    - -
    - -
    - - - - - - - -
    {% trans "Property" %}{% trans "Value" %}{% trans "Unit" %}
    -
    - - - {% if audio_export_enabled %} -
    -

    {% trans "Download:" %} - {% for format in export_formats %} - - {{ format.extension }} - {% endfor %}

    -
    - {% endif %} - -
    - {% endif %} - {% endif %} - - {% block infos %} -
    - {% block general_info %} -
    - {% dl_field item "title" %} - {% dl_field item "alt_title" %} - {% dl_field item "collector" %} -
    {% field_label item "collection" %}
    -
    {{ item.collection }}
    - {% if item.recorded_from_date %} -
    {% trans "Recording date" %}
    -
    {{ item.recorded_from_date }} {{ item.recorded_to_date|prepend:" - " }}
    - {% endif %} -
    - {% endblock general_info %} -
    -
    - {% block geoethnic_data %} -
    -

    {% trans "Geographic and cultural informations" %}

    -
    - {% if item.location %} -
    {% trans "Location" %}
    -
    {{ item.location.fullnames|join:"
    " }}
    - {% 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 ", " %} -
    -
    - {% endblock geoethnic_data %} -
    -
    - {% block musical_data %} -
    -

    {% trans "Musical informations" %}

    -
    - {% dl_field item "vernacular_style" %} - {% dl_field item "generic_style" %} - {% dl_field item "author" %} -
    - {% if item.performances %} -
    - - - - - - - - - - - {% for performance in item.performances.all %} - - - - - - - {% endfor %} - -
    {% field_label "MediaItemPerformance" "instruments_num" %}{% field_label "MediaItemPerformance" "instrument" %}{% field_label "MediaItemPerformance" "alias" %}{% field_label "MediaItemPerformance" "musicians" %}
    {{ performance.instruments_num }}{{ performance.instrument|default:"" }}{{ performance.alias|default:"" }}{{ performance.musicians }}
    -
    - {% endif %} -
    - {% endblock musical_data %} -
    -
    - {% block general_data %} -
    -

    {% trans "General informations" %}

    -
    - {% dl_field item "comment" %} - {% dl_field item "collector_selection" %} -
    -
    - {% endblock general_data %} -
    -
    - {% block archive_data %} -
    -

    {% trans "Archiving data" %}

    -
    - {% 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" %} -
    -
    - {% endblock archive_data %} -
    -
    - {% block technical_data %} -
    -

    {% trans "Technical data" %}

    -
    -
    -
    {% trans "Media type" %}
    {% trans "Audio" %}
    - {% dl_field item "approx_duration" %} -
    -
    -
    - {% endblock technical_data %} -
    - {% endblock infos %} -
    + {% endif %} + {% trans "Previous" %} + {% trans "Next" %} + Dublin Core +
    {% endblock %} -{% else %} -

    No such item

    -{% endif %} diff --git a/telemeta/templates/telemeta_default/mediaitem_detail_dc.html b/telemeta/templates/telemeta_default/mediaitem_detail_dc.html index 16a82f10..06166632 100644 --- a/telemeta/templates/telemeta_default/mediaitem_detail_dc.html +++ b/telemeta/templates/telemeta_default/mediaitem_detail_dc.html @@ -1,10 +1,10 @@ -{% extends "telemeta/mediaitem_detail.html" %} +{% extends "telemeta/mediaitem.html" %} {% load telemeta_utils %} {% load i18n %} {% if item %} -{% block submenu %} - +{% block title_buttons %} + {% trans "Normal View" %} {% endblock %} {% block infos %} diff --git a/telemeta/templates/telemeta_default/mediaitem_edit.html b/telemeta/templates/telemeta_default/mediaitem_edit.html index b53fe78c..0a3061b9 100644 --- a/telemeta/templates/telemeta_default/mediaitem_edit.html +++ b/telemeta/templates/telemeta_default/mediaitem_edit.html @@ -1,10 +1,13 @@ -{% extends "telemeta/mediaitem_detail.html" %} +{% extends "telemeta/mediaitem.html" %} {% load i18n %} {% load telemeta_utils %} - {% block tools %} +{% block title %} + + {% endblock %} + {% block title_buttons %} {% trans "Cancel" %} - {% endblock tools %} + {% endblock %} {% block infos %}
    diff --git a/telemeta/templates/telemeta_default/mediaitem_list.html b/telemeta/templates/telemeta_default/mediaitem_list.html index 40155f96..af97e0f1 100644 --- a/telemeta/templates/telemeta_default/mediaitem_list.html +++ b/telemeta/templates/telemeta_default/mediaitem_list.html @@ -4,17 +4,16 @@ {% block head_title %}{% trans "Media Items" %} - {{ block.super }}{% endblock %} - -{% block submenu %} -
    +{% block title %} + {% trans "Media Items" %} +{% endblock %} +{% block title_buttons %} {% if user.is_authenticated and perms.telemeta.add_mediaitem %} {% trans "Add" %} {% endif %} -
    {% endblock %} {% block content %} -

    {% trans "Media Items" %}

    {% with object_list as items %}
    {% include "telemeta/inc/mediaitem_list.html" %} diff --git a/telemeta/templates/telemeta_default/profile_edit.html b/telemeta/templates/telemeta_default/profile_edit.html index 936f03b2..fa96be2c 100644 --- a/telemeta/templates/telemeta_default/profile_edit.html +++ b/telemeta/templates/telemeta_default/profile_edit.html @@ -2,9 +2,7 @@ {% load i18n %} {% load telemeta_utils %} -{% block tools %} - {% trans "Cancel" %} -{% endblock %} +{% trans "Cancel" %} {% block content %}

    {% trans "User profile" %} : {{ usr.username }}

    -- 2.39.5