'soundmanager#V2.97a.20150601',
'https://github.com/Parisson/loaders.git',
'https://github.com/Parisson/ui.git',
- 'jquery-ui#1.12.1',
+ 'jquery-ui#1.11.4',
'tablesorter',
'video.js',
'sass-bootstrap-glyphicons',
-
)
app:
build: .
volumes:
- - ./app/:/srv/app
- - ./telemeta/:/srv/src/telemeta/telemeta
- - ./lib/TimeSide/:/srv/src/timeside
+ - ./app:/srv/app
+ - ./telemeta:/srv/src/telemeta/telemeta
+ # - ./lib/TimeSide:/srv/src/timeside
+ # - ./lib/plugins:/srv/src/plugins
volumes_from:
- data
env_file:
+++ /dev/null
-{% extends 'telemeta/base.html' %}
-{% load telemeta_tags %}
-{% load i18n %}
-
-{% block title %}
-{% trans "Add to playlist" %}
-{% endblock %}
-{% block extra_stylesheets %}
- <link rel="stylesheet" type="text/css" href="{{ STATIC_URL }}telemeta/css/jquery-ui.css" />
- <link rel="stylesheet" type="text/css" href="{{ STATIC_URL }}telemeta/css/search.css" />
-{% endblock %}
-{% block content %}
-
- <form method="POST" action="{%url "add_confirmation" type %}">{% csrf_token %}
- <div class="row">
- <div class="col-md-4">
- <table class="listing" style="width:100%">
- <thead>
- <tr><th>{% trans "Selected items : "%}</th>
-
- </tr>
- </thead><tbody>
- {% ifequal type "item" %}
- {% for item in selected_items_list %}
- <tr>
-
- <td><a href="#">
- {{item}}</a></td>
- </tr>
- {% endfor %}
- {% else %}
- {% for item in selected_items_list %}
- <tr>
-
- <td><a href="#">
- {{item.title}}</a></td>
- </tr>
- {% endfor %}
- {% endifequal %}
- </tbody>
- </table>
- </div>
- <div class="col-md-4 col-md-offset-3">
- <label for="selection">select your playlist : </label>
- <select name="playlist_id" style="width:100%;" id="selection">
- {% for playlist in existing_playlists %}
- <option value="{{playlist.id}}">{{playlist.title}}</option>
- {% endfor %}
- </select>
- </div>
- </div>
- {% for item in selected_items_list %}
- <input type="hidden" name="item_id" value="{{item.id}}"/>
- {% endfor %}
- {% if lastquerypath %}
- <input type="hidden" name="lastquerypath" value="{{lastquerypath}}"/>
- {% endif %}
- <div class="row">
- {% if lastquerypath %}
- <div class="col-md-4"><a style="margin-top:10px;width:100%" href="{{lastquerypath}}" id="btn" class="btn btn-default">return to search results</a></div>
- <div class="col-md-4 col-md-offset-3"><button style="margin-top:10px;width:100%" type="submit" id="btn" class="btn btn-default">{% trans "Add to Playlist" %}</button></div>
- {% else %}
- <div class="col-md-4 col-md-offset-7"><button style="margin-top:10px;width:100%" type="submit" id="btn" class="btn btn-default">{% trans "Add to Playlist" %}</button></div>
-
- {% endif %}
- </div>
- </form>
-{% endblock %}
-{% block extra_javascript %}
- <script src="{{ STATIC_URL }}jquery-ui/jquery-ui.min.js" type="text/javascript"></script>
- <script>
- $(document).ready(function() {
- $("#selection").selectmenu({
- icons : {button: "ui-icon-carat-2-n-s"}
- }).selectmenu("menuWidget").addClass("overflow");
- });
- </script>
-{% endblock %}
+++ /dev/null
-{% extends 'telemeta/base.html' %}
-{% load telemeta_tags %}
-{% load i18n %}
-{% load bootstrap_pagination %}
-
-
-{% block title %}
-{% trans "Search" %}
-{% endblock %}
-{% block extra_stylesheets %}
- <link rel="stylesheet" type="text/css" href="{{ STATIC_URL }}telemeta/css/jquery-ui.css" />
- <link rel="stylesheet" type="text/css" href="{{ STATIC_URL }}telemeta/css/search.css" />
- <link rel="stylesheet" type="text/css" href="{{ STATIC_URL }}telemeta/css/lists_sorttable.css" media="print, projection, screen"/>
-{% endblock %}
-{% block content %}
- <form method="get" action=".">
- <div class="row">
- <div class="col-md-5" id="left-form">
- <div class="fieldWrapper">
- {{form.q.errors}}
- {{ form.q.label_tag }}</br>
- {{form.q}}
- </div>
- <div class="fieldWrapper">
- {{form.collectors.errors}}
- {% trans form.collectors.label_tag %}</br>
- {{form.collectors}}
- </div>
- <div class="fieldWrapper">
- {{form.location.errors}}
- {% trans form.location.label_tag %}</br>
- {{form.location}}
- </div>
- <div class="fieldWrapper">
- {{form.ethnic_group.errors}}
- {% trans form.ethnic_group.label_tag %}</br>
- {{form.ethnic_group}}
- </div>
- <div class="fieldWrapper">
- {{form.instruments.errors}}
- {% trans form.instruments.label_tag %}
- {{form.instruments}}
- {% comment %}<a href="#" id="btn" class="col-md-5 btn btn-default" style="width: 100%; margin-top: 1%">{% trans "Instruments : Boolean Search" %}</a>{% endcomment %}
- </div>
-
- <div class="fieldWrapper">
- {{form.media_type.errors}}
- <label>{% trans "media type" %} :</label></br>
- <ul id="id_media_type" style="margin-left:-40px">
- {%ifequal query.media_type 'audio'%}
- <li><label for="id_media_type_0">{% trans "no preference" %}</label><input id="id_media_type_0" type="radio" value="1" name="media_type"></input></li>
- <li><label for="id_media_type_1">{% trans "audio" %}</label><input id="id_media_type_1" type="radio" value="audio" name="media_type" checked="checked"></input></li>
- <li><label for="id_media_type_2">{% trans "video" %}</label><input id="id_media_type_2" type="radio" value="video" name="media_type"></input></li>
- {%else%}
- {%ifequal query.media_type 'video'%}
- <li><label for="id_media_type_0">{% trans "no preference" %}</label><input id="id_media_type_0" type="radio" value="1" name="media_type"></input></li>
- <li><label for="id_media_type_1">{% trans "audio" %}</label><input id="id_media_type_1" type="radio" value="audio" name="media_type"></input></li>
- <li><label for="id_media_type_2">{% trans "video" %}</label><input id="id_media_type_2" type="radio" value="video" name="media_type" checked="checked"></input></li>
- {%else%}
- <li><label for="id_media_type_0">{% trans "no preference" %}</label><input id="id_media_type_0" type="radio" value="1" name="media_type" checked="checked"></input></li>
- <li><label for="id_media_type_1">{% trans "audio" %}</label><input id="id_media_type_1" type="radio" value="audio" name="media_type"></input></li>
- <li><label for="id_media_type_2">{% trans "video" %}</label><input id="id_media_type_2" type="radio" value="video" name="media_type"></input></li>
- {%endifequal%}
- {%endifequal%}
- </ul>
-
- </div>
- <div class="fieldWrapper">
- {{form.viewable_errors}}
- <label>{% trans "Available for consultation media" %} : </label></br>
- <ul id="id_viewable" style="margin-left:-40px">
- {%ifequal query.viewable '2'%}
- <li><label for="id_viewable_0">{% trans "no preference" %}</label><input id="id_viewable_0" type="radio" value="1" name="viewable"></input></li>
- <li><label for="id_viewable_1">{% trans "online and public" %}</label><input id="id_viewable_1" type="radio" value="2" name="viewable" checked="checked"></input></li>
- <li><label for="id_viewable_2">{% trans "online (account required)" %}</label><input id="id_viewable_2" type="radio" value="3" name="viewable"></input></li>
- {%else%}
- {%ifequal query.viewable '3'%}
- <li><label for="id_viewable_0">{% trans "no preference" %}</label><input id="id_viewable_0" type="radio" value="1" name="viewable"></input></li>
- <li><label for="id_viewable_1">{% trans "online and public" %}</label><input id="id_viewable_1" type="radio" value="2" name="viewable"></input></li>
- <li><label for="id_viewable_2">{% trans "online (account required)" %}</label><input id="id_viewable_2" type="radio" value="3" name="viewable" checked="checked"></input></li>
- {%else%}
- <li><label for="id_viewable_0">{% trans "no preference" %}</label><input id="id_viewable_0" type="radio" value="1" name="viewable" checked="checked"></input></li>
- <li><label for="id_viewable_1">{% trans "online and public" %}</label><input id="id_viewable_1" type="radio" value="2" name="viewable"></input></li>
- <li><label for="id_viewable_2">{% trans "online (account required)" %} </label><input id="id_viewable_2" type="radio" value="3" name="viewable"></input></li>
- {%endifequal%}
- {%endifequal%}
- </ul>
- </div>
- </div>
- <div class="col-md-5" id="right-form" style="margin-left:13%">
- <div class="fieldWrapper">
- {{form.recorded_from_date.errors}} {{form.recorded_to_date.errors}}
- <label>{% trans "Recording date" %}:</label></br>
- {{form.recorded_from_date}} <span style="font-size:3em" aria-hidden="true">-</span> {{form.recorded_to_date}}
- </div>
- <div class="fieldWrapper">
- {{form.item_status_errors}}
- <label>{% trans "Document status" %} : </label></br>
- <ul id="id_item_status" style="margin-left:-40px">
- {%ifequal query.item_status 'pub'%}
- <li><label for="id_item_status_0">{% trans "no preference" %}</label><input id="id_item_status_0" type="radio" value="1" name="item_status"></input></li>
- <li><label for="id_item_status_1">{% trans "Published" %}</label><input id="id_item_status_1" type="radio" value="pub" name="item_status" checked="checked"></input></li>
- <li><label for="id_item_status_2">{% trans "Unpublished" %}</label><input id="id_item_status_2" type="radio" value="unpub" name="item_status"></input></li>
- {%else%}
- {%ifequal query.item_status 'unpub'%}
- <li><label for="id_item_status_0">{% trans "no preference" %}</label><input id="id_item_status_0" type="radio" value="1" name="item_status"></input></li>
- <li><label for="id_item_status_1">{% trans "Published" %}</label><input id="id_item_status_1" type="radio" value="pub" name="item_status"></input></li>
- <li><label for="id_item_status_2">{% trans "Unpublished" %}</label><input id="id_item_status_2" type="radio" value="unpub" name="item_status" checked="checked"></input></li>
- {%else%}
- <li><label for="id_item_status_0">{% trans "no preference" %}</label><input id="id_item_status_0" type="radio" value="1" name="item_status" checked="checked"></input></li>
- <li><label for="id_item_status_1">{% trans "Published" %}</label><input id="id_item_status_1" type="radio" value="pub" name="item_status"></input></li>
- <li><label for="id_item_status_2">{% trans "Unpublished" %}</label><input id="id_item_status_2" type="radio" value="unpub" name="item_status"></input></li>
- {%endifequal%}
- {%endifequal%}
- </ul>
- </div>
- <div class="fieldWrapper">
- {{form.year_published_from.errors}} {{form.year_published_to.errors}}
- <label> {% trans "year published" %} :</label></br>
- {{form.year_published_from}} <span style="font-size:3em" aria-hidden="true">-</span> {{form.year_published_to}}
- </div>
- <div class="fieldWrapper">
- {{form.recording_context.errors}}
- {{ form.recording_context.label_tag }}</br>
- {{form.recording_context}}
- </div>
- <div class="fieldWrapper">
- {{form.physical_format.errors}}
- {% trans form.physical_format.label_tag %}</br>
- {{form.physical_format}}
- </div>
- <div class="fieldWrapper">
- {{form.code.errors}}
- {% trans form.code.label_tag %}</br>
- {{form.code}}
- </div>
- </div>
- </div></br>
- <button id="btn" class="btn btn-default col-md-3 col-md-offset-4" type="submit" style="height:45px;font-size:1.2em;align:center"><span class="glyphicon glyphicon-search" aria-hidden="true"></span> {% trans "Search" %}</button></br></br>
- </form>
- <div id="anchor"></br></div>
- {% if query %}
-
- <div class="row" >
- <div class="col-md-3" >
- <img src="{{ STATIC_URL }}telemeta/images/search_red.png" alt="search-results" style="vertical-align:middle" /> <h1>{% trans "Search Results" %}</h1>
- </div>
- <div class="col-md-6" >
- <center>{% bootstrap_paginate page range=10 show_first_last="True" %}</center>
- </div>
- <div class="col-md-0"> </div>
- </div>
- <div class="row" style="margin-left:-15px">
- <div class="col-md-4">
- {% ifequal type 'item' %}
- <p><b>Items ({{item_count}}) | <a href="{% url "haystack_advance_search_type" "collection" %}?{{request_url}}">Collections ({{collection_count}})</a> | <a href="{% url "haystack_advance_search_type" "corpus" %}?{{request_url}}">Corpus ({{corpus_count}})</a> | <a href="{% url "haystack_advance_search_type" "fonds" %}?{{request_url}}">Fonds ({{fonds_count}})</a></b></p>
- {% else %}
- {% ifequal type 'corpus' %}
- <p><b><a href="{% url "haystack_advance_search_type" "item" %}?{{request_url}}">Items ({{item_count}}) </a>| <a href="{% url "haystack_advance_search_type" "collection" %}?{{request_url}}">Collections ({{collection_count}})</a> | Corpus ({{corpus_count}})</a> | <a href="{% url "haystack_advance_search_type" "fonds" %}?{{request_url}}">Fonds ({{fonds_count}})</a></b></p>
- {% else %}
- {% ifequal type 'fonds' %}
- <p><b><a href="{% url "haystack_advance_search_type" "item" %}?{{request_url}}">Items ({{item_count}}) </a>| <a href="{% url "haystack_advance_search_type" "collection" %}?{{request_url}}">Collections ({{collection_count}})</a> | <a href="{% url "haystack_advance_search_type" "corpus" %}?{{request_url}}">Corpus ({{corpus_count}})</a> | Fonds ({{fonds_count}})</b></p>
- {% else %}
- {% ifequal type 'collection'%}
- <p><b><a href="{% url "haystack_advance_search_type" "item" %}?{{request_url}}">Items ({{item_count}}) </a>| Collections ({{collection_count}}) | <a href="{% url "haystack_advance_search_type" "corpus" %}?{{request_url}}">Corpus ({{corpus_count}})</a> | <a href="{% url "haystack_advance_search_type" "fonds" %}?{{request_url}}">Fonds ({{fonds_count}})</a></b></p>
- {% endifequal %}
- {% endifequal %}
- {% endifequal %}
- {% endifequal %}
- </div>
- <div class="col-md-4 col-md-offset-4" >
- <div class="pull-right"">
- <label style="display:inline-block;vertical-align:middle">{% trans "results per page"%}:</label>
- <div style="display:inline-block;vertical-align:middle">
- <select id="results-per-page" name="results_page">
- <option {% ifequal results_page 20 %}selected{% endifequal %} value="20">20</option>
- <option {% ifequal results_page 50 %}selected{% endifequal %} value="50">50</option>
- <option {% ifequal results_page 100 %}selected{% endifequal %} value="100">100</option>
- <option {% ifequal results_page 250 %}selected{% endifequal %} value="250">250</option>
- <option {% ifequal results_page 500 %}selected{% endifequal %} value="500">500</option>
- <option {% ifequal results_page 1000 %}selected{% endifequal %} value="1000">1000</option>
- <option {% ifequal results_page 10000 %}selected{% endifequal %} value="10000">10000</option>
- </select>
- </div>
- </div>
- </div>
- </div>
- <form method="POST" action="{% url "haystack_playlist" type%} ">{% csrf_token %}
- {% with object_list as items %}
- <div class="fullpage" style="display:none">
- {% ifequal type 'item' %}
- {% include "search/mediaitem_listhaystack.html" %}
- {% else %}
- {% ifequal type 'corpus' %}
- {% include "search/mediaresource_listhaystack.html" %}
- {% else %}
- {% ifequal type 'fonds' %}
- {% include "search/mediaresource_listhaystack.html" %}
- {% else %}
- {% ifequal type 'collection' %}
- {% include "search/mediacollection_listhaystack.html" %}
- {%endifequal%}
- {%endifequal%}
- {%endifequal%}
- {%endifequal%}
- </div>
- <noscript>
- <div class="fullpage">
- {% ifequal type 'item' %}
- {% include "search/mediaitem_listhaystack.html" %}
- {% else %}
- {% ifequal type 'corpus' %}
- {% include "search/mediaresource_listhaystack.html" %}
- {% else %}
- {% ifequal type 'fonds' %}
- {% include "search/mediaresource_listhaystack.html" %}
- {% else %}
- {% ifequal type 'collection' %}
- {% include "search/mediacollection_listhaystack.html" %}
- {%endifequal%}
- {%endifequal%}
- {%endifequal%}
- {%endifequal%}
- </div>
- </noscript>
-
-
- {% endwith %}
- {% if user.is_authenticated %}
- <input type="hidden" name="lastquerypath" value="{{request.get_full_path}}"/>
- <button style="margin-top:10px" type="submit" id="btn" class="btn btn-default">{% trans "Add to playlist" %}</button>
- {% endif %}
- </form>
- {% else %}
- <div id="results"></div>{# Show some example queries to run, maybe query syntax, something else? #}
- {% endif %}
-
- {% comment %}
-
- <div id="dialog" title="{% trans "Instruments : Boolean Search" %}">
-
- <form>
-
- {{ booleanForm.management_form}}
- {% for form in booleanForm %}
- {% if forloop.counter0 == 0 %}
- <span style="margin-left: 13.5%">{{ form.start_bracket }}</span>
- {{ form.text_field }}
- {{ form.end_bracket }}
- {% else %}
- {% if forloop.counter0 == 1 %}
- <div id="copy">
- {% endif %}
- {{ form.as_p }}
- {% if forloop.counter0 == 1 %}
- </div>
- {% endif %}
- {% endif %}
-
- {% endfor %}
- <a class="btn btn-default" id="add" href="#">{% trans "Add field" %}</a>
- <br/><input type="submit" value="{% trans "Validate the query" %}">
-
-
- </form>
-
- <p id="res"></p>
-
- </div>
-
- {% endcomment %}
-
-{% endblock %}
-{% block extra_javascript %}
- <script src="{{ STATIC_URL }}jquery-ui/jquery-ui.min.js" type="text/javascript"></script>
- <script src="{{ STATIC_URL }}tablesorter/jquery.tablesorter.min.js" type="text/javascript"></script>
- <script src="{{ STATIC_URL }}telemeta/js/advanceSearch.js" type="text/javascript"></script>
-
- <script>
- $(function(){
- $("#results-per-page").selectmenu({
- icons : {button: "ui-icon-carat-2-n-s"},
- change : function(){
- window.location = '?q={{request.GET.q}}&location={{request.GET.location}}ðnic_group={{request.GET.ethnic_group}}&instruments={{request.GET.instruments}}&year_published_from={{request.GET.year_published_from}}&year_published_to={{request.GET.year_published_to}}&media_type={{request.GET.media_type}}&viewable={{request.GET.viewable}}&collectors={{request.GET.collectors}}&recorded_from_date={{request.GET.recorded_from_date}}&recorded_to_date={{request.GET.recorded_to_date}}&item_status={{request.GET.item_status}}&recording_context={{request.GET.recording_context}}&physical_format={{request.GET.physical_format}}&code={{ request.GET.code }}&page=1&results_page='+$(this).val();
- }
- }).selectmenu("menuWidget").addClass("overflow");
-
- });
-
-</script>
-{% endblock %}
+++ /dev/null
-{% extends 'telemeta/base.html' %}
-{% load telemeta_tags %}
-{% load i18n %}
-
-{% block title %}
-{% trans "Playlist Confirmation" %}
-{% endblock %}
-{% block content %}
- <table class="listing" style="width:100%">
- <thead>
- <tr><th>{% trans "Added to playlist : "%}</th>
-
- </tr>
- </thead><tbody>
- {% ifequal type "item" %}
- {% for item in selected_items_list %}
- <tr>
-
- <td><a href="#">
- {{item}}</a></td>
- </tr>
- {% endfor %}
- {% else %}
- {% for item in selected_items_list %}
- <tr>
-
- <td><a href="#">
- {{item.title}}</a></td>
- </tr>
- {% endfor %}
- {% endifequal %}
- </tbody>
- </table></br>
- {% if lastquerypath %}
- <a style="margin-top:10px" href="{{lastquerypath}}" id="btn" class="btn btn-default">return to search results</a>
- {% endif %}
-{% endblock %}
\ No newline at end of file
+++ /dev/null
-{% load telemeta_tags %}
-{% load i18n %}
-
-<div id="accordeon" style="margin-bottom:20px">
- <div><a href="#">{% trans "Filters" %}</a></div>
- <div>
- <table class="table" style="font-size:0.9em">
- <tr>
- {% if facets.fields.item_status %}
- <td>{% trans "Item Status" %}</td>
- {% for item_status in facets.fields.item_status %}
- <td><a href="{{ request.get_full_path }}&selected_facets=item_status_exact:{{ item_status.0|urlencode }}">{% trans item_status.0 %}</a> <span style="background-color:#6a0307" class="badge">{{ item_status.1 }}</span></td>
- {% endfor %}
- {% if Published_count == 0 %}
- <td> {% trans "Published" %} <span class="badge">0</span></td><td></td>
- {% endif %}
- {% if Unpublished_count == 0 %}
- <td> {% trans "Unpublished" %} <span class="badge">0</span></td><td></td>
- {% endif %}
- {% else %}
- <td>{% trans "Item Status" %}</td>
- <td>{% trans "None" %}</td>
- {% endif %}
- </tr>
- <tr>
- {% if facets.fields.digitized %}
- <td>{% trans "Player Status" %}</td>
- {% for digitized in facets.fields.digitized %}
- {% ifequal digitized.0 'T' %}
- <td><a href="{{ request.get_full_path }}&selected_facets=digitized_exact:{{ digitized.0|urlencode }}">Sound</a> <span style="background-color:#6a0307" class="badge">{{ digitized.1 }}</span></td><td></td>
- {% endifequal %}
- {% endfor %}
- {% if digitized_count == 0 %}
- <td> {% trans "Sound" %} <span class="badge">0</span></td><td></td>
- {% endif %}
- {% else %}
- <td>{% trans "Player Status" %}</td>
- <td>{% trans "None" %}</td>
- {% endif %}
- </tr>
- <tr>
- {% if facets.fields.item_acces %}
- <td>{% trans "Access Right" %}</td>
- {% if viewable_count != 0 %}
- <td><a href="{{ request.get_full_path }}&selected_facets=item_acces_exact:{{ 'viewable'|urlencode }}">viewable</a> <span style="background-color:#6a0307" class="badge">{{viewable_count}}</span></td><td></td>
- {% endif %}
- {% if viewable_count == 0 %}
- <td>{% trans "viewable" %} <span class="badge">{{viewable_count}}</span></td><td></td>
- {% endif %}
- {% comment %}
- {% for item_acces in facets.fields.item_acces %}
- {# Faire un booleen dans la vue, le passer en contexte puis verifier si il est a true ou a false pour l'affichage' #}
- {% ifequal item_acces.0 'none' %}
- <td><a href="{{ request.get_full_path }}&selected_facets=item_acces_exact:{{ item_acces.0|urlencode }}">{{ item_acces.0 }}</a> <span class="badge">{{ item_acces.1 }}</span></td>
- {% endifequal %}
- {% endfor %}
- {%endcomment%}
- {% else %}
- <td>{% trans "Access Right" %}</td>
- <td>{% trans "None" %}</td>
- {% endif %}
- </tr>
- </table>
- </div>
-
- <div><a href="#">{% trans "Other Filters" %}</a></div>
- <div>
- <table class="table" style="font-size:0.9em">
- <tr>
- {% if facets.fields.media_type %}
- <td>{% trans "Media Type" %}</td>
- {% for media_type in facets.fields.media_type %}
- {% ifequal media_type.0 'Audio'%}
- <td><a href="{{ request.get_full_path }}&selected_facets=media_type_exact:{{ media_type.0|urlencode }}">{{ media_type.0 }}</a> <span style="background-color:#6a0307" class="badge">{{ media_type.1 }}</span></td>
- {% endifequal %}
- {% ifequal media_type.0 'Video'%}
- <td><a href="{{ request.get_full_path }}&selected_facets=media_type_exact:{{ media_type.0|urlencode }}">{{ media_type.0 }}</a> <span style="background-color:#6a0307" class="badge">{{ media_type.1 }}</span></td>
- {% endifequal %}
- {% endfor %}
- {% if Video_count == 0 %}
- <td> {% trans "Video" %} <span class="badge">0</span></td><td></td>
- {% endif %}
- {% if Audio_count == 0 %}
- <td> {% trans "Audio" %} <span class="badge">0</span></td><td></td>
- {% endif %}
- {% endif %}
- </tr>
- <tr>
- <tr>
- {% if facets.fields.recording_context %}
- <td>{% trans "Recording Context" %}</td>
- {% for recording_context in facets.fields.recording_context %}
- {% ifequal recording_context.0 'Studio'%}
- <td><a href="{{ request.get_full_path }}&selected_facets=recording_context_exact:{{ recording_context.0|urlencode }}">{{ recording_context.0 }}</a> <span style="background-color:#6a0307" class="badge">{{ recording_context.1 }}</span></td>
- {% endifequal %}
- {% ifequal recording_context.0 'Radio'%}
- <td><a href="{{ request.get_full_path }}&selected_facets=recording_context_exact:{{ recording_context.0|urlencode }}">{{ recording_context.0 }}</a> <span style="background-color:#6a0307" class="badge">{{ recording_context.1 }}</span></td>
- {% endifequal %}
- {% ifequal recording_context.0 'Terrain'%}
- <td><a href="{{ request.get_full_path }}&selected_facets=recording_context_exact:{{ recording_context.0|urlencode }}">{{ recording_context.0 }}</a> <span style="background-color:#6a0307" class="badge">{{ recording_context.1 }}</span></td>
- {% endifequal %}
- {% endfor %}
- {% if Terrain_count == 0 %}
- <td> {% trans "Terrain" %} <span class="badge">0</span></td><td></td>
- {% endif %}
- {% if Radio_count == 0 %}
- <td> {% trans "Radio" %} <span class="badge">0</span></td><td></td>
- {% endif %}
- {% if Studio_count == 0 %}
- <td> {% trans "Studio" %} <span class="badge">0</span></td><td></td>
- {% endif %}
- {% endif %}
- </tr>
- <tr>
- {% if facets.fields.physical_format %}
- <td>{% trans "Physical Format" %}</td>
- {% for physical_format in facets.fields.physical_format %}
- {% ifequal physical_format.0 'CDR'%}
- <td><a href="{{ request.get_full_path }}&selected_facets=physical_format_exact:{{ physical_format.0|urlencode }}">{{ physical_format.0 }}</a> <span style="background-color:#6a0307" class="badge">{{ physical_format.1 }}</span></td>
- {% endifequal %}
- {% ifequal physical_format.0 'Disque'%}
- <td><a href="{{ request.get_full_path }}&selected_facets=physical_format_exact:{{ physical_format.0|urlencode }}">{{ physical_format.0 }}</a> <span style="background-color:#6a0307" class="badge">{{ physical_format.1 }}</span></td>
- {% endifequal %}
- {% ifequal physical_format.0 'Cylindre'%}
- <td><a href="{{ request.get_full_path }}&selected_facets=physical_format_exact:{{ physical_format.0|urlencode }}">{{ physical_format.0 }}</a> <span style="background-color:#6a0307" class="badge">{{ physical_format.1 }}</span></td>
- {% endifequal %}
- {% endfor %}
- {% if CDR_count == 0 %}
- <td> {% trans "CDR" %} <span class="badge">0</span></td><td></td>
- {% endif %}
- {% if Disque_count == 0 %}
- <td> {% trans "Disque" %} <span class="badge">0</span></td><td></td>
- {% endif %}
- {% if Cylindre_count == 0 %}
- <td> {% trans "Cylindre" %} <span class="badge">0</span></a></td><td></td>
- {% endif %}
- {% endif %}
- </tr>
- </table>
- </div>
-
-</div>
-
-{% if selected_facets %}
- <p> <span class="glyphicon glyphicon-filter"> selected filters :
- {{selected_facets|join:" + "}}</b></span><a class="pull-right" href="{% url "haystack_search_type" "type" %}?q={{ query }}&page=1">» Remove All Filters</a></p>
- {% endif %}
-
-
-
-
+++ /dev/null
-{{ object.name|safe }}
\ No newline at end of file
+++ /dev/null
-{{ object.name|safe }}
\ No newline at end of file
+++ /dev/null
-{{ object.name|safe }}
\ No newline at end of file
+++ /dev/null
-{{ object.alias|safe }}
\ No newline at end of file
+++ /dev/null
-{{ object.title }}
-{{ object.alt_title }}
-{{ object.creator }}
-{{ object.recorded_from_year }}
-{{ object.recorded_to_year }}
-{{ object.description }}
-{{ object.collector }}
-{{ object.publisher_id }}
-{{ object.publisher_collection_id }}
-{{ object.publisher_serial }}
-{{ object.booklet_author }}
-{{ object.external_references }}
-{{ object.cnrs_contributor }}
-{{ object.booklet_description }}
-{{ object.alt_copies }}
-{{ object.comment }}
-{{ object.archiver_notes }}
-{{ object.items_done }}
-{{ object.conservation_site }}
-{% for item in object.items.all %}
-{{ item.location }}
-{{ item.location.current_location }}
-{% for anc in item.location.ancestor_relations.all %}
-{{ anc.ancestor_location }}
-{% endfor %}
-{% for alias in item.location.aliases.all %}
-{{ alias }}
-{% endfor %}
-{% endfor %}
-{{ object.code }}
-{{ object.countries }}
-{{ object.ethnic_groups }}
-{{ object.body }}
+++ /dev/null
-{{ object.title }}
-{{ object.descriptions}}
-{{ object.body }}
\ No newline at end of file
+++ /dev/null
-{{ object.title }}
-{{ object.descriptions}}
-{{ object.body }}
\ No newline at end of file
+++ /dev/null
-{{ object.title }}
-{{ object.alt_title }}
-{{ object.collector }}
-{{ object.recorded_from_date }}
-{{ object.recorded_to_date }}
-{{ object.code }}
-{{ object.old_code }}
-{{ object.location }}
-{{ object.location.current_location }}
-{% for anc in object.location.ancestor_relations.all %}
-{{ anc.ancestor_location }}
-{% endfor %}
-{% for alias in object.location.aliases.all %}
-{{ alias }}
-{% endfor %}
-{{ object.comment }}
-{{ object.external_references }}
-{{ object.location_comment }}
-{{ object.cultural_area }}
-{{ object.language }}
-{{ object.language_iso_id }}
-{{ object.ethnic_group_id }}
-{{ object.context_comment }}
-{{ object.moda_execut }}
-{{ object.vernacular_style_id }}
-{{ object.generic_style_id }}
-#{{ object.instrument_vernacular_names }}
-{{ object.body }}
\ No newline at end of file
+++ /dev/null
-{% load telemeta_tags %}
-{% load i18n %}
-
-{% if page.object_list %}
-
-<table class="listing" id="searchtable">
-<thead>
-<tr>
- {% if user.is_authenticated %}
- <th class="highlight"><input id="selectAll" type="checkbox"/> select all </th>
- <th>{% trans "title" %}</th>
- {% else %}
- <th class="highlight">{% trans "title" %}</th>
- {% endif %}
- <th>{% trans "Digitized" %}</th>
- <th>{% field_label "MediaCollection" "creator" %}</th>
- <th>{% trans "Recordist" %}</th>
- <th>{% trans "Recording period" %}</th>
- <th>{% trans "Code" %}</th>
-</tr>
-</thead>
-{% if user.is_authenticated %}
-<tbody>
- {% for result in page.object_list %}
- <tr {% if not forloop.counter0|divisibleby:"2" %}class="odd"{% endif %}>
- <td class="highlight"><input type="checkbox" class="check1" name="selected_items_list" value="{{ result.object.id }}"/></td>
- <td>
- <a href="{% url "telemeta-collection-detail" result.object.public_id %}">{{ result.object.title }}</a>
- </td>
- <td>
- {% if result.object.has_mediafile %}
- <center><span class="glyphicon glyphicon-volume-up" style="font-size: 1.3em;"><p style="opacity:0;font-size:0">d</p></span></center>
- {% endif %}
- </td>
-
- <td>{{ result.object.creator }}</td>
- <td>{{ result.object.collector }}</td>
- <td>
- {% if result.object.recorded_from_year %}
- {{ result.object.recorded_from_year }}
- {% if result.object.recorded_to_year and not result.object.recorded_to_year|equals:result.object.recorded_from_year %}
- - {{ result.object.recorded_to_year }}
- {% endif %}
- {% endif %}
- </td>
- <td>
- {{ result.object.code|default:result.object.old_code }}
- </td>
- </tr>
- {% endfor %}
- </tbody>
-{% else %}
- {% for result in page.object_list %}
- <tr {% if not forloop.counter0|divisibleby:"2" %}class="odd"{% endif %}>
- <td class="highlight">
- <a href="{% url "telemeta-collection-detail" result.object.public_id %}">{{ result.object.title }}</a>
- </td>
- <td>
- {% if result.object.has_mediafile %}
- <center><span class="glyphicon glyphicon-volume-up" style="font-size: 1.3em;"><p style="opacity:0;font-size:0">d</p></span></center>
- {% endif %}
- </td>
-
- <td>{{ result.object.creator }}</td>
- <td>{{ result.object.apparent_collector }}</td>
- <td>
- {% if result.object.recorded_from_year %}
- {{ result.object.recorded_from_year }}
- {% if result.object.recorded_to_year and not result.object.recorded_to_year|equals:result.object.recorded_from_year %}
- - {{ result.object.recorded_to_year }}
- {% endif %}
- {% endif %}
- </td>
- <td>
- {{ result.object.code|default:result.object.old_code }}
- </td>
- </tr>
- {% endfor %}
-{% endif %}
-</table>
-{% else %}
- <p>{% trans "No collection" %}</p>
-{% endif %}
+++ /dev/null
-{% load telemeta_tags %}
-{% load i18n %}
-
-{% if page.object_list %}
-
-<table class="listing" id="searchtable">
-<thead>
-<tr>
- {% if user.is_authenticated %}
- <th class="highlight"><input id="selectAll" type="checkbox"/> select all </th>
- <th>{% trans "title" %}</th>
- {% else %}
- <th class="highlight">{% trans "title" %}</th>
- {% endif %}
- <th>{% trans "Digitized" %}</th>
- <th>{% trans "Recordist" %}</th>
- {% if location_name %}
- <th>{% trans "Location" %}</th>
- {% else %}
- <th>{% trans "Country/Continent" %}</th>
- {% endif %}
- <th>{% trans "Year of recording" %}</th>
- <th>{% trans "Code" %}</th>
-</tr>
-</thead>
-{% if user.is_authenticated %}
-<tbody>
- {% for result in page.object_list %}
- <tr {% if not forloop.counter0|divisibleby:"2" %}class="odd"{% endif %}>
- <td class="highlight"><input type="checkbox" class="check1" name="selected_items_list" value="{{ result.object.id }}"/></td>
- <td>
- <a href="{% url "telemeta-item-detail" result.object.public_id %}">{{ result.object }}</a></br>
- </td>
- <td align="center">
- {% if result.object.file %}
- <a href="{% url "telemeta-item-detail" result.object.public_id %}">
- <center><span class="glyphicon glyphicon-volume-up" style="font-size: 1.3em;"><p style="opacity:0;font-size:0">d</p></span></center>
- {% endif %}
- </td>
-
- <td>{{ result.object.collector }}</td>
- <td>{{ result.object.location.name }}</td>
- <td>
- {% if result.object.recorded_from_date %}
- {{ result.object.recorded_from_date.year }}
- {% if result.object.recorded_to_date and not result.object.recorded_to_date.year|equals:result.object.recorded_from_date.year %}
- - {{ result.object.recorded_to_date.year }}
- {% endif %}
- {% endif %}
- </td>
- <td>
- {{ result.object.code|default:result.object.old_code }}
- </td>
- </tr>
- {% endfor %}
- </tbody>
-{% else %}
- {% for result in page.object_list %}
- <tr {% if not forloop.counter0|divisibleby:"2" %}class="odd"{% endif %}>
- <td class="highlight">
- <a href="{% url "telemeta-item-detail" result.object.public_id %}">{{ result.object }}</a></br>
- </td>
- <td align="center">
- {% if result.object.file %}
- <a href="{% url "telemeta-item-detail" result.object.public_id %}">
- <center><span class="glyphicon glyphicon-volume-up" style="font-size: 1.3em;"><p style="opacity:0;font-size:0">d</p></span></center>
- {% endif %}
- </td>
-
- <td>{{ result.object.collector }}</td>
- <td>{{ result.object.location.name }}</td>
- <td>
- {% if result.object.recorded_from_date %}
- {{ result.object.recorded_from_date.year }}
- {% if result.object.recorded_to_date and not result.object.recorded_to_date.year|equals:result.object.recorded_from_date.year %}
- - {{ result.object.recorded_to_date.year }}
- {% endif %}
- {% endif %}
- </td>
- <td>
- {{ result.object.code|default:result.object.old_code }}
- </td>
- </tr>
- {% endfor %}
-{% endif %}
-
-</table>
-{% else %}
- <p>{% trans "No results found" %}</p>
-{% endif %}
-
-
+++ /dev/null
-{% load telemeta_tags %}
-{% load i18n %}
-
-{% if page.object_list %}
-
-<table class="listing" id="searchtable">
-<thead>
-<tr>
- {% if user.is_authenticated %}
- <th class="highlight"><input id="selectAll" type="checkbox"/> select all </th>
- <th>{% trans "title" %}</th>
- {% else %}
- <th class="highlight">{% trans "title" %}</th>
- {% endif %}
- <th>{% trans "Digitized" %}</th>
- <th>{% trans "Description" %}</th>
- <th>{% trans "Code" %}</th>
-</tr>
-</thead>
-{% if user.is_authenticated %}
-<tbody>
- {% for result in page.object_list %}
- <tr {% if not forloop.counter0|divisibleby:"2" %}class="odd"{% endif %}>
- <td class="highlight"><input type="checkbox" class="check1" name="selected_items_list" value="{{ result.object.id }}"/></td>
- <td>
- <a href="{% url "telemeta-resource-detail" type result.object.public_id %}">{{ result.object.title }}</a>
- </td>
- <td>
- {% if result.object.has_mediafile %}
- <center><span class="glyphicon glyphicon-volume-up" style="font-size: 1.3em;"><p style="opacity:0;font-size:0">d</p></span></center>
- {% endif %}
- </td>
-
- <td>{{ result.object.descriptions }}</td>
- <td>
- {{ result.object.code }}
- </td>
- </tr>
- {% endfor %}
- </tbody>
-{% else %}
- {% for result in page.object_list %}
- <tr {% if not forloop.counter0|divisibleby:"2" %}class="odd"{% endif %}>
- <td class="highlight"><input type="checkbox" class="check1" name="selected_items_list" value="{{ result.object.id }}"/></td>
- <td>
- <a href="{% url "telemeta-resource-detail" type result.object.public_id %}">{{ result.object.title }}</a>
- </td>
- <td>
- {% if result.object.has_mediafile %}
- <center><span class="glyphicon glyphicon-volume-up" style="font-size: 1.3em;"><p style="opacity:0;font-size:0">d</p></span></center>
- {% endif %}
- </td>
-
- <td>{{ result.object.descriptions }}</td>
- <td>
- {{ result.object.code }}
- </td>
- </tr>
- {% endfor %}
-{% endif %}
-</table>
-{% else %}
- <p>{% trans "No " %}{{ type }} </p>
-{% endif %}
+++ /dev/null
-{% extends 'telemeta/base.html' %}
-{% load telemeta_tags %}
-{% load i18n %}
-{% load bootstrap_pagination %}
-
-{% block title %}
-{% endblock %}
-{% block extra_stylesheets %}
- <link rel="stylesheet" type="text/css" href="{{ STATIC_URL }}telemeta/css/jquery-ui.css" />
- <link rel="stylesheet" type="text/css" href="{{ STATIC_URL }}telemeta/css/lists_sorttable.css" media="print, projection, screen"/>
-{% endblock %}
-{% block content %}
- {% if query %}
- <div class='row'>
- <div class="col-md-3">
- <img src="{{ STATIC_URL }}telemeta/images/search_red.png" alt="search-results" style="vertical-align:middle" /> <h1>{% trans "Search Results" %}</h1>
- </div>
- <div class="col-md-6" >
- <center>{% bootstrap_paginate page range=10 show_first_last="True" %}</center>
- </div>
- <div class="col-md-0"> </div>
- </div>
- <div class="row" style="margin-left:15px">
- <div class="col-md-4">
- {% ifequal type 'collection'%}
- <p><b><a href="{% url "haystack_search_type" "item" %}?{{request.GET.urlencode}}">Items ({{item_count}}) </a>| Collections ({{collection_count}}) | <a href="{% url "haystack_search_type" "corpus" %}?{{request.GET.urlencode}}">Corpus ({{corpus_count}})</a> | <a href="{% url "haystack_search_type" "fonds" %}?{{request.GET.urlencode}}">Fonds ({{fonds_count}})</a></b></p>
- {% else %}
- {% ifequal type 'corpus'%}
- <p><b><a href="{% url "haystack_search_type" "item" %}?{{request.GET.urlencode}}">Items ({{item_count}}) </a>| <a href="{% url "haystack_search_type" "collection" %}?{{request.GET.urlencode}}">Collections ({{collection_count}})</a> | Corpus ({{corpus_count}}) | <a href="{% url "haystack_search_type" "fonds" %}?{{request.GET.urlencode}}">Fonds ({{fonds_count}})</a></b></p>
- {% else %}
- {% ifequal type 'fonds'%}
- <p><b><a href="{% url "haystack_search_type" "item" %}?{{request.GET.urlencode}}">Items ({{item_count}}) </a>| <a href="{% url "haystack_search_type" "collection" %}?{{request.GET.urlencode}}">Collections ({{collection_count}})</a> | <a href="{% url "haystack_search_type" "corpus" %}?{{request.GET.urlencode}}">Corpus ({{corpus_count}})</a> | Fonds ({{fonds_count}})</b></p>
- {% else %}
- {% ifequal type 'item' %}
- <p><b>Items ({{item_count}}) | <a href="{% url "haystack_search_type" "collection" %}?{{request.GET.urlencode}}">Collections ({{collection_count}})</a> | <a href="{% url "haystack_search_type" "corpus" %}?{{request.GET.urlencode}}">Corpus ({{corpus_count}})</a> | <a href="{% url "haystack_search_type" "fonds" %}?{{request.GET.urlencode}}">Fonds ({{fonds_count}})</a></b></p>
- {% endifequal %}
- {% endifequal %}
- {% endifequal %}
- {% endifequal %}
- </div>
- <div class="col-md-4 col-md-offset-4" >
- <div class="pull-right"">
- <label style="display:inline-block;vertical-align:middle">{% trans "results per page"%}:</label>
- <div style="display:inline-block;vertical-align:middle">
- <select id="results-per-page" name="results_page">
- <option {% ifequal results_page 20 %}selected{% endifequal %} value="20">20</option>
- <option {% ifequal results_page 50 %}selected{% endifequal %} value="50">50</option>
- <option {% ifequal results_page 100 %}selected{% endifequal %} value="100">100</option>
- <option {% ifequal results_page 250 %}selected{% endifequal %} value="250">250</option>
- <option {% ifequal results_page 500 %}selected{% endifequal %} value="500">500</option>
- <option {% ifequal results_page 1000 %}selected{% endifequal %} value="1000">1000</option>
- <option {% ifequal results_page 10000 %}selected{% endifequal %} value="10000">10000</option>
- </select>
- </div>
- </div>
- </div>
- </div>
- {% include "search/filters.html" %}
-
- <form method="POST" action="{% url "haystack_playlist" type %} ">{% csrf_token %}
- {% with object_list as items %}
- <div class="fullpage" style="display:none">
- {% ifequal type 'item' %}
- {% include "search/mediaitem_listhaystack.html" %}
- {% else %}
- {% ifequal type 'collection' %}
- {% include "search/mediacollection_listhaystack.html" %}
- {% else %}
- {% ifequal type 'corpus' %}
- {% include "search/mediaresource_listhaystack.html" %}
- {% else %}
- {% ifequal type 'fonds' %}
- {% include "search/mediaresource_listhaystack.html" %}
- {%endifequal%}
- {%endifequal%}
- {%endifequal%}
- {%endifequal%}
- </div>
- <noscript>
- <div class="fullpage">
- {% ifequal type 'item' %}
- {% include "search/mediaitem_listhaystack.html" %}
- {% else %}
- {% ifequal type 'collection' %}
- {% include "search/mediacollection_listhaystack.html" %}
- {% else %}
- {% ifequal type 'corpus' %}
- {% include "search/mediaresource_listhaystack.html" %}
- {% else %}
- {% ifequal type 'fonds' %}
- {% include "search/mediaresource_listhaystack.html" %}
- {%endifequal%}
- {%endifequal%}
- {%endifequal%}
- {%endifequal%}
- </div>
- </noscript>
- {% endwith %}
-
- {% if user.is_authenticated %}
- <input type="hidden" name="lastquerypath" value="{{request.get_full_path}}"/>
- <button style="margin-top:10px" type="submit" id="btn" class="btn btn-default">{% trans "Add to playlist" %}</button>
- {% endif %}
- </form>
- {% else %}
- <meta http-equiv="REFRESH" content="0;url={% url "haystack_search" %}?q=+">
- {% endif %}
- </form>
-{% endblock %}
-{% block extra_javascript %}
- <script src="{{ STATIC_URL }}jquery-ui/jquery-ui.min.js" type="text/javascript"></script>
- <script src="{{ STATIC_URL }}telemeta/js/search.js" type="text/javascript"></script>
- <script src="{{ STATIC_URL }}tablesorter/jquery.tablesorter.min.js" type="text/javascript"></script>
- <script>
-
-
- $(function(){
- $("#results-per-page").selectmenu({
- icons : {button: "ui-icon-carat-2-n-s"},
- change : function(){
- window.location = '?q={{ query }}&page=1&selected_facets={{selected_facets_url|join:'&selected_facets='}}&results_page='+$(this).val();
- }
- }).selectmenu("menuWidget").addClass("overflow");
-
- });
- </script>
-{% endblock %}
--- /dev/null
+{% load i18n %}
+{% load telemeta_tags %}
+{% load bootstrap3 %}
+
+ {# spaces between li and a elements breaks layout #}
+
+ <ul id="nav">
+ {% if user.is_authenticated %}
+ <li><a href="{% url "telemeta-desk-lists" %}" class="blue">{% trans "Desk" %}</a></li>
+ {% else %}
+ <li><a href="{% url "telemeta-home" %}" class="blue">{% trans "Home" %}</a></li>
+ {% endif %}
+
+ <li><a href="#archives#" class="green">{% trans "Archives" %}</a>
+ <ul>
+ <li><a href="{% url "telemeta-resource-list" "fonds" %}">{% trans "Fonds" %}</a></li>
+ <li><a href="{% url "telemeta-resource-list" "corpus" %}">{% trans "Corpus" %}</a></li>
+ <li><a href="{% url "telemeta-collections" %}">{% trans "Collections" %}</a></li>
+ <li><a href="{% url "telemeta-items" %}">{% trans "Items" %}</a></li>
+ </ul>
+ </li>
+
+ <li><a href="{% url "telemeta-geo-continents" %}"
+ class="yellow">{% trans "Geo Navigator" %}</a></li>
+
+ <li><a href="{% url "haystack_advance_search" %}"
+ class="orange">{% trans "Advanced search" %}</a></li>
+
+ {% if user.is_authenticated and user.is_staff %}
+ <li><a href="#vocabulary#" class="red">{% trans "Terminology" %}</a>
+ {% if perms.telemeta.change_physicalformat %}
+ <ul>
+ <li><a href="{% url "telemeta-admin-enumerations" %}">{% trans "Enumerations" %}</a></li>
+ <li><a href="{% url "telemeta-instrument-edit" %}">{% trans "Instruments" %}</a></li>
+ <li><a href="{% url "telemeta-instrument-alias-edit" %}">{% trans "Instrument (vernaculare)" %}</a></li>
+ </ul>
+ {% else %}
+ <ul>
+ <li><a href="{% url "telemeta-instruments" %}">{% trans "Instruments" %}</a>
+ <li><a href="{% url "telemeta-instrument-alias" %}">{% trans "Instruments (vernaculare)" %}</a></li>
+ {% for enu in menu %}
+ <li>
+ <a href="{% url "telemeta-enumeration" enu.id %}">{{ enu.name |capfirst }}</a>
+ </li>
+ {% endfor %}
+ </ul>
+ {% endif %}
+ </li>
+ {% endif %}
+
+ {% if user.is_authenticated and user.is_staff %}
+ <li><a href="{% url "telemeta-home" %}admin/django/" class="violet">{% trans "Admin" %}</a>
+ </li>
+ {% endif %}
+
+ </ul>
--- /dev/null
+{% extends 'telemeta/base.html' %}
+{% load telemeta_tags %}
+{% load i18n %}
+
+{% block title %}
+{% trans "Add to playlist" %}
+{% endblock %}
+{% block extra_stylesheets %}
+ <link rel="stylesheet" type="text/css" href="{{ STATIC_URL }}telemeta/css/jquery-ui.css" />
+ <link rel="stylesheet" type="text/css" href="{{ STATIC_URL }}telemeta/css/search.css" />
+{% endblock %}
+{% block content %}
+
+ <form method="POST" action="{%url "add_confirmation" type %}">{% csrf_token %}
+ <div class="row">
+ <div class="col-md-4">
+ <table class="listing" style="width:100%">
+ <thead>
+ <tr><th>{% trans "Selected items : "%}</th>
+
+ </tr>
+ </thead><tbody>
+ {% ifequal type "item" %}
+ {% for item in selected_items_list %}
+ <tr>
+
+ <td><a href="#">
+ {{item}}</a></td>
+ </tr>
+ {% endfor %}
+ {% else %}
+ {% for item in selected_items_list %}
+ <tr>
+
+ <td><a href="#">
+ {{item.title}}</a></td>
+ </tr>
+ {% endfor %}
+ {% endifequal %}
+ </tbody>
+ </table>
+ </div>
+ <div class="col-md-4 col-md-offset-3">
+ <label for="selection">select your playlist : </label>
+ <select name="playlist_id" style="width:100%;" id="selection">
+ {% for playlist in existing_playlists %}
+ <option value="{{playlist.id}}">{{playlist.title}}</option>
+ {% endfor %}
+ </select>
+ </div>
+ </div>
+ {% for item in selected_items_list %}
+ <input type="hidden" name="item_id" value="{{item.id}}"/>
+ {% endfor %}
+ {% if lastquerypath %}
+ <input type="hidden" name="lastquerypath" value="{{lastquerypath}}"/>
+ {% endif %}
+ <div class="row">
+ {% if lastquerypath %}
+ <div class="col-md-4"><a style="margin-top:10px;width:100%" href="{{lastquerypath}}" id="btn" class="btn btn-default">return to search results</a></div>
+ <div class="col-md-4 col-md-offset-3"><button style="margin-top:10px;width:100%" type="submit" id="btn" class="btn btn-default">{% trans "Add to Playlist" %}</button></div>
+ {% else %}
+ <div class="col-md-4 col-md-offset-7"><button style="margin-top:10px;width:100%" type="submit" id="btn" class="btn btn-default">{% trans "Add to Playlist" %}</button></div>
+
+ {% endif %}
+ </div>
+ </form>
+{% endblock %}
+{% block extra_javascript %}
+ <script src="{{ STATIC_URL }}jquery-ui/jquery-ui.min.js" type="text/javascript"></script>
+ <script>
+ $(document).ready(function() {
+ $("#selection").selectmenu({
+ icons : {button: "ui-icon-carat-2-n-s"}
+ }).selectmenu("menuWidget").addClass("overflow");
+ });
+ </script>
+{% endblock %}
--- /dev/null
+{% extends 'telemeta/base.html' %}
+{% load telemeta_tags %}
+{% load i18n %}
+
+{% block title %}
+{% trans "Playlist Confirmation" %}
+{% endblock %}
+{% block content %}
+ <table class="listing" style="width:100%">
+ <thead>
+ <tr><th>{% trans "Added to playlist : "%}</th>
+
+ </tr>
+ </thead><tbody>
+ {% ifequal type "item" %}
+ {% for item in selected_items_list %}
+ <tr>
+
+ <td><a href="#">
+ {{item}}</a></td>
+ </tr>
+ {% endfor %}
+ {% else %}
+ {% for item in selected_items_list %}
+ <tr>
+
+ <td><a href="#">
+ {{item.title}}</a></td>
+ </tr>
+ {% endfor %}
+ {% endifequal %}
+ </tbody>
+ </table></br>
+ {% if lastquerypath %}
+ <a style="margin-top:10px" href="{{lastquerypath}}" id="btn" class="btn btn-default">return to search results</a>
+ {% endif %}
+{% endblock %}
\ No newline at end of file
--- /dev/null
+{% load telemeta_tags %}
+{% load i18n %}
+
+<div id="accordeon" style="margin-bottom:20px">
+ <div><a href="#">{% trans "Filters" %}</a></div>
+ <div>
+ <table class="table" style="font-size:0.9em">
+ <tr>
+ {% if facets.fields.item_status %}
+ <td>{% trans "Item Status" %}</td>
+ {% for item_status in facets.fields.item_status %}
+ <td><a href="{{ request.get_full_path }}&selected_facets=item_status_exact:{{ item_status.0|urlencode }}">{% trans item_status.0 %}</a> <span style="background-color:#6a0307" class="badge">{{ item_status.1 }}</span></td>
+ {% endfor %}
+ {% if Published_count == 0 %}
+ <td> {% trans "Published" %} <span class="badge">0</span></td><td></td>
+ {% endif %}
+ {% if Unpublished_count == 0 %}
+ <td> {% trans "Unpublished" %} <span class="badge">0</span></td><td></td>
+ {% endif %}
+ {% else %}
+ <td>{% trans "Item Status" %}</td>
+ <td>{% trans "None" %}</td>
+ {% endif %}
+ </tr>
+ <tr>
+ {% if facets.fields.digitized %}
+ <td>{% trans "Player Status" %}</td>
+ {% for digitized in facets.fields.digitized %}
+ {% ifequal digitized.0 'T' %}
+ <td><a href="{{ request.get_full_path }}&selected_facets=digitized_exact:{{ digitized.0|urlencode }}">Sound</a> <span style="background-color:#6a0307" class="badge">{{ digitized.1 }}</span></td><td></td>
+ {% endifequal %}
+ {% endfor %}
+ {% if digitized_count == 0 %}
+ <td> {% trans "Sound" %} <span class="badge">0</span></td><td></td>
+ {% endif %}
+ {% else %}
+ <td>{% trans "Player Status" %}</td>
+ <td>{% trans "None" %}</td>
+ {% endif %}
+ </tr>
+ <tr>
+ {% if facets.fields.item_acces %}
+ <td>{% trans "Access Right" %}</td>
+ {% if viewable_count != 0 %}
+ <td><a href="{{ request.get_full_path }}&selected_facets=item_acces_exact:{{ 'viewable'|urlencode }}">viewable</a> <span style="background-color:#6a0307" class="badge">{{viewable_count}}</span></td><td></td>
+ {% endif %}
+ {% if viewable_count == 0 %}
+ <td>{% trans "viewable" %} <span class="badge">{{viewable_count}}</span></td><td></td>
+ {% endif %}
+ {% comment %}
+ {% for item_acces in facets.fields.item_acces %}
+ {# Faire un booleen dans la vue, le passer en contexte puis verifier si il est a true ou a false pour l'affichage' #}
+ {% ifequal item_acces.0 'none' %}
+ <td><a href="{{ request.get_full_path }}&selected_facets=item_acces_exact:{{ item_acces.0|urlencode }}">{{ item_acces.0 }}</a> <span class="badge">{{ item_acces.1 }}</span></td>
+ {% endifequal %}
+ {% endfor %}
+ {%endcomment%}
+ {% else %}
+ <td>{% trans "Access Right" %}</td>
+ <td>{% trans "None" %}</td>
+ {% endif %}
+ </tr>
+ </table>
+ </div>
+
+ <div><a href="#">{% trans "Other Filters" %}</a></div>
+ <div>
+ <table class="table" style="font-size:0.9em">
+ <tr>
+ {% if facets.fields.media_type %}
+ <td>{% trans "Media Type" %}</td>
+ {% for media_type in facets.fields.media_type %}
+ {% ifequal media_type.0 'Audio'%}
+ <td><a href="{{ request.get_full_path }}&selected_facets=media_type_exact:{{ media_type.0|urlencode }}">{{ media_type.0 }}</a> <span style="background-color:#6a0307" class="badge">{{ media_type.1 }}</span></td>
+ {% endifequal %}
+ {% ifequal media_type.0 'Video'%}
+ <td><a href="{{ request.get_full_path }}&selected_facets=media_type_exact:{{ media_type.0|urlencode }}">{{ media_type.0 }}</a> <span style="background-color:#6a0307" class="badge">{{ media_type.1 }}</span></td>
+ {% endifequal %}
+ {% endfor %}
+ {% if Video_count == 0 %}
+ <td> {% trans "Video" %} <span class="badge">0</span></td><td></td>
+ {% endif %}
+ {% if Audio_count == 0 %}
+ <td> {% trans "Audio" %} <span class="badge">0</span></td><td></td>
+ {% endif %}
+ {% endif %}
+ </tr>
+ <tr>
+ <tr>
+ {% if facets.fields.recording_context %}
+ <td>{% trans "Recording Context" %}</td>
+ {% for recording_context in facets.fields.recording_context %}
+ {% ifequal recording_context.0 'Studio'%}
+ <td><a href="{{ request.get_full_path }}&selected_facets=recording_context_exact:{{ recording_context.0|urlencode }}">{{ recording_context.0 }}</a> <span style="background-color:#6a0307" class="badge">{{ recording_context.1 }}</span></td>
+ {% endifequal %}
+ {% ifequal recording_context.0 'Radio'%}
+ <td><a href="{{ request.get_full_path }}&selected_facets=recording_context_exact:{{ recording_context.0|urlencode }}">{{ recording_context.0 }}</a> <span style="background-color:#6a0307" class="badge">{{ recording_context.1 }}</span></td>
+ {% endifequal %}
+ {% ifequal recording_context.0 'Terrain'%}
+ <td><a href="{{ request.get_full_path }}&selected_facets=recording_context_exact:{{ recording_context.0|urlencode }}">{{ recording_context.0 }}</a> <span style="background-color:#6a0307" class="badge">{{ recording_context.1 }}</span></td>
+ {% endifequal %}
+ {% endfor %}
+ {% if Terrain_count == 0 %}
+ <td> {% trans "Terrain" %} <span class="badge">0</span></td><td></td>
+ {% endif %}
+ {% if Radio_count == 0 %}
+ <td> {% trans "Radio" %} <span class="badge">0</span></td><td></td>
+ {% endif %}
+ {% if Studio_count == 0 %}
+ <td> {% trans "Studio" %} <span class="badge">0</span></td><td></td>
+ {% endif %}
+ {% endif %}
+ </tr>
+ <tr>
+ {% if facets.fields.physical_format %}
+ <td>{% trans "Physical Format" %}</td>
+ {% for physical_format in facets.fields.physical_format %}
+ {% ifequal physical_format.0 'CDR'%}
+ <td><a href="{{ request.get_full_path }}&selected_facets=physical_format_exact:{{ physical_format.0|urlencode }}">{{ physical_format.0 }}</a> <span style="background-color:#6a0307" class="badge">{{ physical_format.1 }}</span></td>
+ {% endifequal %}
+ {% ifequal physical_format.0 'Disque'%}
+ <td><a href="{{ request.get_full_path }}&selected_facets=physical_format_exact:{{ physical_format.0|urlencode }}">{{ physical_format.0 }}</a> <span style="background-color:#6a0307" class="badge">{{ physical_format.1 }}</span></td>
+ {% endifequal %}
+ {% ifequal physical_format.0 'Cylindre'%}
+ <td><a href="{{ request.get_full_path }}&selected_facets=physical_format_exact:{{ physical_format.0|urlencode }}">{{ physical_format.0 }}</a> <span style="background-color:#6a0307" class="badge">{{ physical_format.1 }}</span></td>
+ {% endifequal %}
+ {% endfor %}
+ {% if CDR_count == 0 %}
+ <td> {% trans "CDR" %} <span class="badge">0</span></td><td></td>
+ {% endif %}
+ {% if Disque_count == 0 %}
+ <td> {% trans "Disque" %} <span class="badge">0</span></td><td></td>
+ {% endif %}
+ {% if Cylindre_count == 0 %}
+ <td> {% trans "Cylindre" %} <span class="badge">0</span></a></td><td></td>
+ {% endif %}
+ {% endif %}
+ </tr>
+ </table>
+ </div>
+
+</div>
+
+{% if selected_facets %}
+ <p> <span class="glyphicon glyphicon-filter"> selected filters :
+ {{selected_facets|join:" + "}}</b></span><a class="pull-right" href="{% url "haystack_search_type" "type" %}?q={{ query }}&page=1">» Remove All Filters</a></p>
+ {% endif %}
+
+
+
+
--- /dev/null
+{{ object.name|safe }}
\ No newline at end of file
--- /dev/null
+{{ object.name|safe }}
\ No newline at end of file
--- /dev/null
+{{ object.name|safe }}
\ No newline at end of file
--- /dev/null
+{{ object.alias|safe }}
\ No newline at end of file
--- /dev/null
+{{ object.title }}
+{{ object.alt_title }}
+{{ object.creator }}
+{{ object.recorded_from_year }}
+{{ object.recorded_to_year }}
+{{ object.description }}
+{{ object.collector }}
+{{ object.publisher_id }}
+{{ object.publisher_collection_id }}
+{{ object.publisher_serial }}
+{{ object.booklet_author }}
+{{ object.external_references }}
+{{ object.cnrs_contributor }}
+{{ object.booklet_description }}
+{{ object.alt_copies }}
+{{ object.comment }}
+{{ object.archiver_notes }}
+{{ object.items_done }}
+{{ object.conservation_site }}
+{% for item in object.items.all %}
+{{ item.location }}
+{{ item.location.current_location }}
+{% for anc in item.location.ancestor_relations.all %}
+{{ anc.ancestor_location }}
+{% endfor %}
+{% for alias in item.location.aliases.all %}
+{{ alias }}
+{% endfor %}
+{% endfor %}
+{{ object.code }}
+{{ object.countries }}
+{{ object.ethnic_groups }}
+{{ object.body }}
--- /dev/null
+{{ object.title }}
+{{ object.descriptions}}
+{{ object.body }}
\ No newline at end of file
--- /dev/null
+{{ object.title }}
+{{ object.descriptions}}
+{{ object.body }}
\ No newline at end of file
--- /dev/null
+{{ object.title }}
+{{ object.alt_title }}
+{{ object.collector }}
+{{ object.recorded_from_date }}
+{{ object.recorded_to_date }}
+{{ object.code }}
+{{ object.old_code }}
+{{ object.location }}
+{{ object.location.current_location }}
+{% for anc in object.location.ancestor_relations.all %}
+{{ anc.ancestor_location }}
+{% endfor %}
+{% for alias in object.location.aliases.all %}
+{{ alias }}
+{% endfor %}
+{{ object.comment }}
+{{ object.external_references }}
+{{ object.location_comment }}
+{{ object.cultural_area }}
+{{ object.language }}
+{{ object.language_iso_id }}
+{{ object.ethnic_group_id }}
+{{ object.context_comment }}
+{{ object.moda_execut }}
+{{ object.vernacular_style_id }}
+{{ object.generic_style_id }}
+#{{ object.instrument_vernacular_names }}
+{{ object.body }}
\ No newline at end of file
--- /dev/null
+{% load telemeta_tags %}
+{% load i18n %}
+
+{% if page.object_list %}
+
+<table class="listing" id="searchtable">
+<thead>
+<tr>
+ {% if user.is_authenticated %}
+ <th class="highlight"><input id="selectAll" type="checkbox"/> select all </th>
+ <th>{% trans "title" %}</th>
+ {% else %}
+ <th class="highlight">{% trans "title" %}</th>
+ {% endif %}
+ <th>{% trans "Digitized" %}</th>
+ <th>{% field_label "MediaCollection" "creator" %}</th>
+ <th>{% trans "Recordist" %}</th>
+ <th>{% trans "Recording period" %}</th>
+ <th>{% trans "Code" %}</th>
+</tr>
+</thead>
+{% if user.is_authenticated %}
+<tbody>
+ {% for result in page.object_list %}
+ <tr {% if not forloop.counter0|divisibleby:"2" %}class="odd"{% endif %}>
+ <td class="highlight"><input type="checkbox" class="check1" name="selected_items_list" value="{{ result.object.id }}"/></td>
+ <td>
+ <a href="{% url "telemeta-collection-detail" result.object.public_id %}">{{ result.object.title }}</a>
+ </td>
+ <td>
+ {% if result.object.has_mediafile %}
+ <center><span class="glyphicon glyphicon-volume-up" style="font-size: 1.3em;"><p style="opacity:0;font-size:0">d</p></span></center>
+ {% endif %}
+ </td>
+
+ <td>{{ result.object.creator }}</td>
+ <td>{{ result.object.collector }}</td>
+ <td>
+ {% if result.object.recorded_from_year %}
+ {{ result.object.recorded_from_year }}
+ {% if result.object.recorded_to_year and not result.object.recorded_to_year|equals:result.object.recorded_from_year %}
+ - {{ result.object.recorded_to_year }}
+ {% endif %}
+ {% endif %}
+ </td>
+ <td>
+ {{ result.object.code|default:result.object.old_code }}
+ </td>
+ </tr>
+ {% endfor %}
+ </tbody>
+{% else %}
+ {% for result in page.object_list %}
+ <tr {% if not forloop.counter0|divisibleby:"2" %}class="odd"{% endif %}>
+ <td class="highlight">
+ <a href="{% url "telemeta-collection-detail" result.object.public_id %}">{{ result.object.title }}</a>
+ </td>
+ <td>
+ {% if result.object.has_mediafile %}
+ <center><span class="glyphicon glyphicon-volume-up" style="font-size: 1.3em;"><p style="opacity:0;font-size:0">d</p></span></center>
+ {% endif %}
+ </td>
+
+ <td>{{ result.object.creator }}</td>
+ <td>{{ result.object.apparent_collector }}</td>
+ <td>
+ {% if result.object.recorded_from_year %}
+ {{ result.object.recorded_from_year }}
+ {% if result.object.recorded_to_year and not result.object.recorded_to_year|equals:result.object.recorded_from_year %}
+ - {{ result.object.recorded_to_year }}
+ {% endif %}
+ {% endif %}
+ </td>
+ <td>
+ {{ result.object.code|default:result.object.old_code }}
+ </td>
+ </tr>
+ {% endfor %}
+{% endif %}
+</table>
+{% else %}
+ <p>{% trans "No collection" %}</p>
+{% endif %}
--- /dev/null
+{% load telemeta_tags %}
+{% load i18n %}
+
+{% if page.object_list %}
+
+<table class="listing" id="searchtable">
+<thead>
+<tr>
+ {% if user.is_authenticated %}
+ <th class="highlight"><input id="selectAll" type="checkbox"/> select all </th>
+ <th>{% trans "title" %}</th>
+ {% else %}
+ <th class="highlight">{% trans "title" %}</th>
+ {% endif %}
+ <th>{% trans "Digitized" %}</th>
+ <th>{% trans "Recordist" %}</th>
+ {% if location_name %}
+ <th>{% trans "Location" %}</th>
+ {% else %}
+ <th>{% trans "Country/Continent" %}</th>
+ {% endif %}
+ <th>{% trans "Year of recording" %}</th>
+ <th>{% trans "Code" %}</th>
+</tr>
+</thead>
+{% if user.is_authenticated %}
+<tbody>
+ {% for result in page.object_list %}
+ <tr {% if not forloop.counter0|divisibleby:"2" %}class="odd"{% endif %}>
+ <td class="highlight"><input type="checkbox" class="check1" name="selected_items_list" value="{{ result.object.id }}"/></td>
+ <td>
+ <a href="{% url "telemeta-item-detail" result.object.public_id %}">{{ result.object }}</a></br>
+ </td>
+ <td align="center">
+ {% if result.object.file %}
+ <a href="{% url "telemeta-item-detail" result.object.public_id %}">
+ <center><span class="glyphicon glyphicon-volume-up" style="font-size: 1.3em;"><p style="opacity:0;font-size:0">d</p></span></center>
+ {% endif %}
+ </td>
+
+ <td>{{ result.object.collector }}</td>
+ <td>{{ result.object.location.name }}</td>
+ <td>
+ {% if result.object.recorded_from_date %}
+ {{ result.object.recorded_from_date.year }}
+ {% if result.object.recorded_to_date and not result.object.recorded_to_date.year|equals:result.object.recorded_from_date.year %}
+ - {{ result.object.recorded_to_date.year }}
+ {% endif %}
+ {% endif %}
+ </td>
+ <td>
+ {{ result.object.code|default:result.object.old_code }}
+ </td>
+ </tr>
+ {% endfor %}
+ </tbody>
+{% else %}
+ {% for result in page.object_list %}
+ <tr {% if not forloop.counter0|divisibleby:"2" %}class="odd"{% endif %}>
+ <td class="highlight">
+ <a href="{% url "telemeta-item-detail" result.object.public_id %}">{{ result.object }}</a></br>
+ </td>
+ <td align="center">
+ {% if result.object.file %}
+ <a href="{% url "telemeta-item-detail" result.object.public_id %}">
+ <center><span class="glyphicon glyphicon-volume-up" style="font-size: 1.3em;"><p style="opacity:0;font-size:0">d</p></span></center>
+ {% endif %}
+ </td>
+
+ <td>{{ result.object.collector }}</td>
+ <td>{{ result.object.location.name }}</td>
+ <td>
+ {% if result.object.recorded_from_date %}
+ {{ result.object.recorded_from_date.year }}
+ {% if result.object.recorded_to_date and not result.object.recorded_to_date.year|equals:result.object.recorded_from_date.year %}
+ - {{ result.object.recorded_to_date.year }}
+ {% endif %}
+ {% endif %}
+ </td>
+ <td>
+ {{ result.object.code|default:result.object.old_code }}
+ </td>
+ </tr>
+ {% endfor %}
+{% endif %}
+
+</table>
+{% else %}
+ <p>{% trans "No results found" %}</p>
+{% endif %}
+
+
--- /dev/null
+{% load telemeta_tags %}
+{% load i18n %}
+
+{% if page.object_list %}
+
+<table class="listing" id="searchtable">
+<thead>
+<tr>
+ {% if user.is_authenticated %}
+ <th class="highlight"><input id="selectAll" type="checkbox"/> select all </th>
+ <th>{% trans "title" %}</th>
+ {% else %}
+ <th class="highlight">{% trans "title" %}</th>
+ {% endif %}
+ <th>{% trans "Digitized" %}</th>
+ <th>{% trans "Description" %}</th>
+ <th>{% trans "Code" %}</th>
+</tr>
+</thead>
+{% if user.is_authenticated %}
+<tbody>
+ {% for result in page.object_list %}
+ <tr {% if not forloop.counter0|divisibleby:"2" %}class="odd"{% endif %}>
+ <td class="highlight"><input type="checkbox" class="check1" name="selected_items_list" value="{{ result.object.id }}"/></td>
+ <td>
+ <a href="{% url "telemeta-resource-detail" type result.object.public_id %}">{{ result.object.title }}</a>
+ </td>
+ <td>
+ {% if result.object.has_mediafile %}
+ <center><span class="glyphicon glyphicon-volume-up" style="font-size: 1.3em;"><p style="opacity:0;font-size:0">d</p></span></center>
+ {% endif %}
+ </td>
+
+ <td>{{ result.object.descriptions }}</td>
+ <td>
+ {{ result.object.code }}
+ </td>
+ </tr>
+ {% endfor %}
+ </tbody>
+{% else %}
+ {% for result in page.object_list %}
+ <tr {% if not forloop.counter0|divisibleby:"2" %}class="odd"{% endif %}>
+ <td class="highlight"><input type="checkbox" class="check1" name="selected_items_list" value="{{ result.object.id }}"/></td>
+ <td>
+ <a href="{% url "telemeta-resource-detail" type result.object.public_id %}">{{ result.object.title }}</a>
+ </td>
+ <td>
+ {% if result.object.has_mediafile %}
+ <center><span class="glyphicon glyphicon-volume-up" style="font-size: 1.3em;"><p style="opacity:0;font-size:0">d</p></span></center>
+ {% endif %}
+ </td>
+
+ <td>{{ result.object.descriptions }}</td>
+ <td>
+ {{ result.object.code }}
+ </td>
+ </tr>
+ {% endfor %}
+{% endif %}
+</table>
+{% else %}
+ <p>{% trans "No " %}{{ type }} </p>
+{% endif %}
--- /dev/null
+{% extends 'telemeta/base.html' %}
+{% load telemeta_tags %}
+{% load i18n %}
+{% load bootstrap_pagination %}
+
+{% block title %}
+{% endblock %}
+{% block extra_stylesheets %}
+ <link rel="stylesheet" type="text/css" href="{{ STATIC_URL }}telemeta/css/jquery-ui.css" />
+ <link rel="stylesheet" type="text/css" href="{{ STATIC_URL }}telemeta/css/lists_sorttable.css" media="print, projection, screen"/>
+{% endblock %}
+{% block content %}
+ {% if query %}
+ <div class='row'>
+ <div class="col-md-3">
+ <img src="{{ STATIC_URL }}telemeta/images/search_red.png" alt="search-results" style="vertical-align:middle" /> <h1>{% trans "Search Results" %}</h1>
+ </div>
+ <div class="col-md-6" >
+ <center>{% bootstrap_paginate page range=10 show_first_last="True" %}</center>
+ </div>
+ <div class="col-md-0"> </div>
+ </div>
+ <div class="row" style="margin-left:15px">
+ <div class="col-md-4">
+ {% ifequal type 'collection'%}
+ <p><b><a href="{% url "haystack_search_type" "item" %}?{{request.GET.urlencode}}">Items ({{item_count}}) </a>| Collections ({{collection_count}}) | <a href="{% url "haystack_search_type" "corpus" %}?{{request.GET.urlencode}}">Corpus ({{corpus_count}})</a> | <a href="{% url "haystack_search_type" "fonds" %}?{{request.GET.urlencode}}">Fonds ({{fonds_count}})</a></b></p>
+ {% else %}
+ {% ifequal type 'corpus'%}
+ <p><b><a href="{% url "haystack_search_type" "item" %}?{{request.GET.urlencode}}">Items ({{item_count}}) </a>| <a href="{% url "haystack_search_type" "collection" %}?{{request.GET.urlencode}}">Collections ({{collection_count}})</a> | Corpus ({{corpus_count}}) | <a href="{% url "haystack_search_type" "fonds" %}?{{request.GET.urlencode}}">Fonds ({{fonds_count}})</a></b></p>
+ {% else %}
+ {% ifequal type 'fonds'%}
+ <p><b><a href="{% url "haystack_search_type" "item" %}?{{request.GET.urlencode}}">Items ({{item_count}}) </a>| <a href="{% url "haystack_search_type" "collection" %}?{{request.GET.urlencode}}">Collections ({{collection_count}})</a> | <a href="{% url "haystack_search_type" "corpus" %}?{{request.GET.urlencode}}">Corpus ({{corpus_count}})</a> | Fonds ({{fonds_count}})</b></p>
+ {% else %}
+ {% ifequal type 'item' %}
+ <p><b>Items ({{item_count}}) | <a href="{% url "haystack_search_type" "collection" %}?{{request.GET.urlencode}}">Collections ({{collection_count}})</a> | <a href="{% url "haystack_search_type" "corpus" %}?{{request.GET.urlencode}}">Corpus ({{corpus_count}})</a> | <a href="{% url "haystack_search_type" "fonds" %}?{{request.GET.urlencode}}">Fonds ({{fonds_count}})</a></b></p>
+ {% endifequal %}
+ {% endifequal %}
+ {% endifequal %}
+ {% endifequal %}
+ </div>
+ <div class="col-md-4 col-md-offset-4" >
+ <div class="pull-right">
+ <label style="display:inline-block;vertical-align:middle">{% trans "results per page"%}:</label>
+ <div style="display:inline-block;vertical-align:middle">
+ <select id="results-per-page" name="results_page">
+ <option {% ifequal results_page 20 %}selected{% endifequal %} value="20">20</option>
+ <option {% ifequal results_page 50 %}selected{% endifequal %} value="50">50</option>
+ <option {% ifequal results_page 100 %}selected{% endifequal %} value="100">100</option>
+ <option {% ifequal results_page 250 %}selected{% endifequal %} value="250">250</option>
+ <option {% ifequal results_page 500 %}selected{% endifequal %} value="500">500</option>
+ <option {% ifequal results_page 1000 %}selected{% endifequal %} value="1000">1000</option>
+ <option {% ifequal results_page 10000 %}selected{% endifequal %} value="10000">10000</option>
+ </select>
+ </div>
+ </div>
+ </div>
+ </div>
+ {% include "telemeta/search/filters.html" %}
+
+ <form method="POST" action="{% url "haystack_playlist" type %} ">{% csrf_token %}
+ {% with object_list as items %}
+ <div class="fullpage" style="display:none">
+ {% ifequal type 'item' %}
+ {% include "telemeta/search/mediaitem_listhaystack.html" %}
+ {% else %}
+ {% ifequal type 'collection' %}
+ {% include "telemeta/search/mediacollection_listhaystack.html" %}
+ {% else %}
+ {% ifequal type 'corpus' %}
+ {% include "telemeta/search/mediaresource_listhaystack.html" %}
+ {% else %}
+ {% ifequal type 'fonds' %}
+ {% include "telemeta/search/mediaresource_listhaystack.html" %}
+ {%endifequal%}
+ {%endifequal%}
+ {%endifequal%}
+ {%endifequal%}
+ </div>
+ <noscript>
+ <div class="fullpage">
+ {% ifequal type 'item' %}
+ {% include "telemeta/search/mediaitem_listhaystack.html" %}
+ {% else %}
+ {% ifequal type 'collection' %}
+ {% include "telemeta/search/mediacollection_listhaystack.html" %}
+ {% else %}
+ {% ifequal type 'corpus' %}
+ {% include "telemeta/search/mediaresource_listhaystack.html" %}
+ {% else %}
+ {% ifequal type 'fonds' %}
+ {% include "telemeta/search/mediaresource_listhaystack.html" %}
+ {%endifequal%}
+ {%endifequal%}
+ {%endifequal%}
+ {%endifequal%}
+ </div>
+ </noscript>
+ {% endwith %}
+
+ {% if user.is_authenticated %}
+ <input type="hidden" name="lastquerypath" value="{{request.get_full_path}}"/>
+ <button style="margin-top:10px" type="submit" id="btn" class="btn btn-default">{% trans "Add to playlist" %}</button>
+ {% endif %}
+ </form>
+ {% else %}
+ <meta http-equiv="REFRESH" content="0;url={% url "haystack_search" %}?q=+">
+ {% endif %}
+ </form>
+{% endblock %}
+{% block extra_javascript %}
+ <script src="{{ STATIC_URL }}jquery-ui/jquery-ui.min.js" type="text/javascript"></script>
+ <script src="{{ STATIC_URL }}telemeta/js/search.js" type="text/javascript"></script>
+ <script src="{{ STATIC_URL }}tablesorter/jquery.tablesorter.min.js" type="text/javascript"></script>
+ <script>
+
+
+ $(function(){
+ $("#results-per-page").selectmenu({
+ icons : {button: "ui-icon-carat-2-n-s"},
+ change : function(){
+ window.location = '?q={{ query }}&page=1&selected_facets={{selected_facets_url|join:'&selected_facets='}}&results_page='+$(this).val();
+ }
+ }).selectmenu("menuWidget").addClass("overflow");
+
+ });
+ </script>
+{% endblock %}
--- /dev/null
+{% extends 'telemeta/base.html' %}
+{% load telemeta_tags %}
+{% load i18n %}
+{% load bootstrap_pagination %}
+
+{% block title %}
+{% trans "Search" %}
+{% endblock %}
+
+{% block extra_stylesheets %}
+ <link rel="stylesheet" type="text/css" href="{{ STATIC_URL }}telemeta/css/jquery-ui.css" />
+ <link rel="stylesheet" type="text/css" href="{{ STATIC_URL }}telemeta/css/search.css" />
+ <link rel="stylesheet" type="text/css" href="{{ STATIC_URL }}telemeta/css/lists_sorttable.css" media="print, projection, screen"/>
+{% endblock %}
+
+{% block extra_javascript %}
+ <script src="{{ STATIC_URL }}jquery-ui/jquery-ui.min.js" type="text/javascript"></script>
+ <script src="{{ STATIC_URL }}tablesorter/jquery.tablesorter.min.js" type="text/javascript"></script>
+ <script src="{{ STATIC_URL }}telemeta/js/advanceSearch.js" type="text/javascript"></script>
+ <script>
+ $(function(){
+ $("#results-per-page").selectmenu({
+ icons : {button: "ui-icon-carat-2-n-s"},
+ change : function(){
+ window.location = '?q={{request.GET.q}}&location={{request.GET.location}}ðnic_group={{request.GET.ethnic_group}}&instruments={{request.GET.instruments}}&year_published_from={{request.GET.year_published_from}}&year_published_to={{request.GET.year_published_to}}&media_type={{request.GET.media_type}}&viewable={{request.GET.viewable}}&collectors={{request.GET.collectors}}&recorded_from_date={{request.GET.recorded_from_date}}&recorded_to_date={{request.GET.recorded_to_date}}&item_status={{request.GET.item_status}}&recording_context={{request.GET.recording_context}}&physical_format={{request.GET.physical_format}}&code={{ request.GET.code }}&page=1&results_page='+$(this).val();
+ }
+ }).selectmenu("menuWidget").addClass("overflow");
+
+ });
+ </script>
+{% endblock %}
+
+{% block content %}
+ <form method="get" action=".">
+ <div class="row">
+ <div class="col-md-5" id="left-form">
+ <div class="fieldWrapper">
+ {{form.q.errors}}
+ {{ form.q.label_tag }}</br>
+ {{form.q}}
+ </div>
+ <div class="fieldWrapper">
+ {{form.collectors.errors}}
+ {% trans form.collectors.label_tag %}</br>
+ {{form.collectors}}
+ </div>
+ <div class="fieldWrapper">
+ {{form.location.errors}}
+ {% trans form.location.label_tag %}</br>
+ {{form.location}}
+ </div>
+ <div class="fieldWrapper">
+ {{form.ethnic_group.errors}}
+ {% trans form.ethnic_group.label_tag %}</br>
+ {{form.ethnic_group}}
+ </div>
+ <div class="fieldWrapper">
+ {{form.instruments.errors}}
+ {% trans form.instruments.label_tag %}
+ {{form.instruments}}
+ {% comment %}<a href="#" id="btn" class="col-md-5 btn btn-default" style="width: 100%; margin-top: 1%">{% trans "Instruments : Boolean Search" %}</a>{% endcomment %}
+ </div>
+
+ <div class="fieldWrapper">
+ {{form.media_type.errors}}
+ <label>{% trans "media type" %} :</label></br>
+ <ul id="id_media_type" style="margin-left:-40px">
+ {%ifequal query.media_type 'audio'%}
+ <li><label for="id_media_type_0">{% trans "no preference" %}</label><input id="id_media_type_0" type="radio" value="1" name="media_type"></input></li>
+ <li><label for="id_media_type_1">{% trans "audio" %}</label><input id="id_media_type_1" type="radio" value="audio" name="media_type" checked="checked"></input></li>
+ <li><label for="id_media_type_2">{% trans "video" %}</label><input id="id_media_type_2" type="radio" value="video" name="media_type"></input></li>
+ {%else%}
+ {%ifequal query.media_type 'video'%}
+ <li><label for="id_media_type_0">{% trans "no preference" %}</label><input id="id_media_type_0" type="radio" value="1" name="media_type"></input></li>
+ <li><label for="id_media_type_1">{% trans "audio" %}</label><input id="id_media_type_1" type="radio" value="audio" name="media_type"></input></li>
+ <li><label for="id_media_type_2">{% trans "video" %}</label><input id="id_media_type_2" type="radio" value="video" name="media_type" checked="checked"></input></li>
+ {%else%}
+ <li><label for="id_media_type_0">{% trans "no preference" %}</label><input id="id_media_type_0" type="radio" value="1" name="media_type" checked="checked"></input></li>
+ <li><label for="id_media_type_1">{% trans "audio" %}</label><input id="id_media_type_1" type="radio" value="audio" name="media_type"></input></li>
+ <li><label for="id_media_type_2">{% trans "video" %}</label><input id="id_media_type_2" type="radio" value="video" name="media_type"></input></li>
+ {%endifequal%}
+ {%endifequal%}
+ </ul>
+
+ </div>
+ <div class="fieldWrapper">
+ {{form.viewable_errors}}
+ <label>{% trans "Available for consultation media" %} : </label></br>
+ <ul id="id_viewable" style="margin-left:-40px">
+ {%ifequal query.viewable '2'%}
+ <li><label for="id_viewable_0">{% trans "no preference" %}</label><input id="id_viewable_0" type="radio" value="1" name="viewable"></input></li>
+ <li><label for="id_viewable_1">{% trans "online and public" %}</label><input id="id_viewable_1" type="radio" value="2" name="viewable" checked="checked"></input></li>
+ <li><label for="id_viewable_2">{% trans "online (account required)" %}</label><input id="id_viewable_2" type="radio" value="3" name="viewable"></input></li>
+ {%else%}
+ {%ifequal query.viewable '3'%}
+ <li><label for="id_viewable_0">{% trans "no preference" %}</label><input id="id_viewable_0" type="radio" value="1" name="viewable"></input></li>
+ <li><label for="id_viewable_1">{% trans "online and public" %}</label><input id="id_viewable_1" type="radio" value="2" name="viewable"></input></li>
+ <li><label for="id_viewable_2">{% trans "online (account required)" %}</label><input id="id_viewable_2" type="radio" value="3" name="viewable" checked="checked"></input></li>
+ {%else%}
+ <li><label for="id_viewable_0">{% trans "no preference" %}</label><input id="id_viewable_0" type="radio" value="1" name="viewable" checked="checked"></input></li>
+ <li><label for="id_viewable_1">{% trans "online and public" %}</label><input id="id_viewable_1" type="radio" value="2" name="viewable"></input></li>
+ <li><label for="id_viewable_2">{% trans "online (account required)" %} </label><input id="id_viewable_2" type="radio" value="3" name="viewable"></input></li>
+ {%endifequal%}
+ {%endifequal%}
+ </ul>
+ </div>
+ </div>
+ <div class="col-md-5" id="right-form" style="margin-left:13%">
+ <div class="fieldWrapper">
+ {{form.recorded_from_date.errors}} {{form.recorded_to_date.errors}}
+ <label>{% trans "Recording date" %}:</label></br>
+ {{form.recorded_from_date}} <span style="font-size:3em" aria-hidden="true">-</span> {{form.recorded_to_date}}
+ </div>
+ <div class="fieldWrapper">
+ {{form.item_status_errors}}
+ <label>{% trans "Document status" %} : </label></br>
+ <ul id="id_item_status" style="margin-left:-40px">
+ {%ifequal query.item_status 'pub'%}
+ <li><label for="id_item_status_0">{% trans "no preference" %}</label><input id="id_item_status_0" type="radio" value="1" name="item_status"></input></li>
+ <li><label for="id_item_status_1">{% trans "Published" %}</label><input id="id_item_status_1" type="radio" value="pub" name="item_status" checked="checked"></input></li>
+ <li><label for="id_item_status_2">{% trans "Unpublished" %}</label><input id="id_item_status_2" type="radio" value="unpub" name="item_status"></input></li>
+ {%else%}
+ {%ifequal query.item_status 'unpub'%}
+ <li><label for="id_item_status_0">{% trans "no preference" %}</label><input id="id_item_status_0" type="radio" value="1" name="item_status"></input></li>
+ <li><label for="id_item_status_1">{% trans "Published" %}</label><input id="id_item_status_1" type="radio" value="pub" name="item_status"></input></li>
+ <li><label for="id_item_status_2">{% trans "Unpublished" %}</label><input id="id_item_status_2" type="radio" value="unpub" name="item_status" checked="checked"></input></li>
+ {%else%}
+ <li><label for="id_item_status_0">{% trans "no preference" %}</label><input id="id_item_status_0" type="radio" value="1" name="item_status" checked="checked"></input></li>
+ <li><label for="id_item_status_1">{% trans "Published" %}</label><input id="id_item_status_1" type="radio" value="pub" name="item_status"></input></li>
+ <li><label for="id_item_status_2">{% trans "Unpublished" %}</label><input id="id_item_status_2" type="radio" value="unpub" name="item_status"></input></li>
+ {%endifequal%}
+ {%endifequal%}
+ </ul>
+ </div>
+ <div class="fieldWrapper">
+ {{form.year_published_from.errors}} {{form.year_published_to.errors}}
+ <label> {% trans "year published" %} :</label></br>
+ {{form.year_published_from}} <span style="font-size:3em" aria-hidden="true">-</span> {{form.year_published_to}}
+ </div>
+ <div class="fieldWrapper">
+ {{form.recording_context.errors}}
+ {{ form.recording_context.label_tag }}</br>
+ {{form.recording_context}}
+ </div>
+ <div class="fieldWrapper">
+ {{form.physical_format.errors}}
+ {% trans form.physical_format.label_tag %}</br>
+ {{form.physical_format}}
+ </div>
+ <div class="fieldWrapper">
+ {{form.code.errors}}
+ {% trans form.code.label_tag %}</br>
+ {{form.code}}
+ </div>
+ </div>
+ </div></br>
+ <button id="btn" class="btn btn-default col-md-3 col-md-offset-4" type="submit" style="height:45px;font-size:1.2em;align:center"><span class="glyphicon glyphicon-search" aria-hidden="true"></span> {% trans "Search" %}</button></br></br>
+ </form>
+ <div id="anchor"></br></div>
+ {% if query %}
+
+ <div class="row" >
+ <div class="col-md-3" >
+ <img src="{{ STATIC_URL }}telemeta/images/search_red.png" alt="search-results" style="vertical-align:middle" /> <h1>{% trans "Search Results" %}</h1>
+ </div>
+ <div class="col-md-6" >
+ <center>{% bootstrap_paginate page range=10 show_first_last="True" %}</center>
+ </div>
+ <div class="col-md-0"> </div>
+ </div>
+ <div class="row" style="margin-left:-15px">
+ <div class="col-md-4">
+ {% ifequal type 'item' %}
+ <p><b>Items ({{item_count}}) | <a href="{% url "haystack_advance_search_type" "collection" %}?{{request_url}}">Collections ({{collection_count}})</a> | <a href="{% url "haystack_advance_search_type" "corpus" %}?{{request_url}}">Corpus ({{corpus_count}})</a> | <a href="{% url "haystack_advance_search_type" "fonds" %}?{{request_url}}">Fonds ({{fonds_count}})</a></b></p>
+ {% else %}
+ {% ifequal type 'corpus' %}
+ <p><b><a href="{% url "haystack_advance_search_type" "item" %}?{{request_url}}">Items ({{item_count}}) </a>| <a href="{% url "haystack_advance_search_type" "collection" %}?{{request_url}}">Collections ({{collection_count}})</a> | Corpus ({{corpus_count}})</a> | <a href="{% url "haystack_advance_search_type" "fonds" %}?{{request_url}}">Fonds ({{fonds_count}})</a></b></p>
+ {% else %}
+ {% ifequal type 'fonds' %}
+ <p><b><a href="{% url "haystack_advance_search_type" "item" %}?{{request_url}}">Items ({{item_count}}) </a>| <a href="{% url "haystack_advance_search_type" "collection" %}?{{request_url}}">Collections ({{collection_count}})</a> | <a href="{% url "haystack_advance_search_type" "corpus" %}?{{request_url}}">Corpus ({{corpus_count}})</a> | Fonds ({{fonds_count}})</b></p>
+ {% else %}
+ {% ifequal type 'collection'%}
+ <p><b><a href="{% url "haystack_advance_search_type" "item" %}?{{request_url}}">Items ({{item_count}}) </a>| Collections ({{collection_count}}) | <a href="{% url "haystack_advance_search_type" "corpus" %}?{{request_url}}">Corpus ({{corpus_count}})</a> | <a href="{% url "haystack_advance_search_type" "fonds" %}?{{request_url}}">Fonds ({{fonds_count}})</a></b></p>
+ {% endifequal %}
+ {% endifequal %}
+ {% endifequal %}
+ {% endifequal %}
+ </div>
+ <div class="col-md-4 col-md-offset-4">
+ <div class="pull-right">
+ <label style="display:inline-block;vertical-align:middle">{% trans "results per page"%}:</label>
+ <div style="display:inline-block;vertical-align:middle">
+ <select id="results-per-page" name="results_page">
+ <option {% ifequal results_page 20 %}selected{% endifequal %} value="20">20</option>
+ <option {% ifequal results_page 50 %}selected{% endifequal %} value="50">50</option>
+ <option {% ifequal results_page 100 %}selected{% endifequal %} value="100">100</option>
+ <option {% ifequal results_page 250 %}selected{% endifequal %} value="250">250</option>
+ <option {% ifequal results_page 500 %}selected{% endifequal %} value="500">500</option>
+ <option {% ifequal results_page 1000 %}selected{% endifequal %} value="1000">1000</option>
+ <option {% ifequal results_page 10000 %}selected{% endifequal %} value="10000">10000</option>
+ </select>
+ </div>
+ </div>
+ </div>
+ </div>
+ <form method="POST" action="{% url "haystack_playlist" type%} ">{% csrf_token %}
+ {% with object_list as items %}
+ <div class="fullpage" style="display:none">
+ {% ifequal type 'item' %}
+ {% include "telemeta/search/mediaitem_listhaystack.html" %}
+ {% else %}
+ {% ifequal type 'corpus' %}
+ {% include "telemeta/search/mediaresource_listhaystack.html" %}
+ {% else %}
+ {% ifequal type 'fonds' %}
+ {% include "telemeta/search/mediaresource_listhaystack.html" %}
+ {% else %}
+ {% ifequal type 'collection' %}
+ {% include "telemeta/search/mediacollection_listhaystack.html" %}
+ {%endifequal%}
+ {%endifequal%}
+ {%endifequal%}
+ {%endifequal%}
+ </div>
+ <noscript>
+ <div class="fullpage">
+ {% ifequal type 'item' %}
+ {% include "telemeta/search/mediaitem_listhaystack.html" %}
+ {% else %}
+ {% ifequal type 'corpus' %}
+ {% include "telemeta/search/mediaresource_listhaystack.html" %}
+ {% else %}
+ {% ifequal type 'fonds' %}
+ {% include "telemeta/search/mediaresource_listhaystack.html" %}
+ {% else %}
+ {% ifequal type 'collection' %}
+ {% include "telemeta/search/mediacollection_listhaystack.html" %}
+ {%endifequal%}
+ {%endifequal%}
+ {%endifequal%}
+ {%endifequal%}
+ </div>
+ </noscript>
+
+
+ {% endwith %}
+ {% if user.is_authenticated %}
+ <input type="hidden" name="lastquerypath" value="{{request.get_full_path}}"/>
+ <button style="margin-top:10px" type="submit" id="btn" class="btn btn-default">{% trans "Add to playlist" %}</button>
+ {% endif %}
+ </form>
+ {% else %}
+ <div id="results"></div>{# Show some example queries to run, maybe query syntax, something else? #}
+ {% endif %}
+
+ {% comment %}
+
+ <div id="dialog" title="{% trans "Instruments : Boolean Search" %}">
+
+ <form>
+
+ {{ booleanForm.management_form}}
+ {% for form in booleanForm %}
+ {% if forloop.counter0 == 0 %}
+ <span style="margin-left: 13.5%">{{ form.start_bracket }}</span>
+ {{ form.text_field }}
+ {{ form.end_bracket }}
+ {% else %}
+ {% if forloop.counter0 == 1 %}
+ <div id="copy">
+ {% endif %}
+ {{ form.as_p }}
+ {% if forloop.counter0 == 1 %}
+ </div>
+ {% endif %}
+ {% endif %}
+
+ {% endfor %}
+ <a class="btn btn-default" id="add" href="#">{% trans "Add field" %}</a>
+ <br/><input type="submit" value="{% trans "Validate the query" %}">
+
+
+ </form>
+
+ <p id="res"></p>
+
+ </div>
+
+ {% endcomment %}
+
+{% endblock %}
--- /dev/null
+{% extends "telemeta/base.html" %}
+{% load telemeta_tags %}
+{% load i18n %}
+
+{% block head_title %}{% trans "Advanced Search" %} - {{ block.super }}{% endblock %}
+
+{% block stylesheets %}
+{{ block.super }}
+<link rel="stylesheet" type="text/css" href="{{ STATIC_URL }}telemeta/css/jquery.autocomplete.css" />
+{% endblock %}
+
+{% block extra_javascript %}
+<script src="{{ STATIC_URL }}telemeta/js/jquery.bgiframe.js" type="text/javascript"></script>
+<script src="{{ STATIC_URL }}telemeta/js/jquery.mb.browser.min.js" type="text/javascript"></script>
+<script src="{{ STATIC_URL }}telemeta/js/jquery.autocomplete.js" type="text/javascript"></script>
+
+
+<script type="text/javascript">
+
+$(function(){
+ var txt = ''
+ +'jQuery.browser.ua = '+jQuery.browser.ua+'<br>'
+ +'jQuery.browser.name = '+jQuery.browser.name+'<br>'
+ +'jQuery.browser.fullVersion = '+jQuery.browser.fullVersion+'<br>'
+ +'jQuery.browser.version = '+jQuery.browser.version+'<br><br><br>'
+ +'jQuery.browser.msie = '+jQuery.browser.msie+'<br>'
+ +'jQuery.browser.mozilla = '+jQuery.browser.mozilla+'<br>'
+ +'jQuery.browser.opera = '+jQuery.browser.opera+'<br>'
+ +'jQuery.browser.webkit = '+jQuery.browser.webkit+'<br>'
+ +'jQuery.browser.safari = '+jQuery.browser.safari+'<br>'
+ +'jQuery.browser.chrome = '+jQuery.browser.chrome+'<br>';
+ $("#result").html(txt);
+});
+
+
+function update_period(source, from_field, to_field) {
+ var from_year = $(from_field);
+ var to_year = $(to_field);
+
+ if (from_year.val() == "0") {
+ to_year.attr('disabled', '1');
+ to_year.val('0');
+ } else {
+ to_year.removeAttr('disabled');
+ if ($(source).is(to_field)) {
+ if (parseInt(from_year.val()) > parseInt(to_year.val()))
+ from_year.val(to_year.val());
+ } else if (parseInt(from_year.val()) > parseInt(to_year.val())) {
+ to_year.val(from_year.val());
+ }
+ }
+}
+
+$(document).ready(function () {
+ $('#location').autocomplete('{% url "telemeta-complete-location" %}', {
+ max: 20,
+ formatResult: function(data) {
+ return data[0].replace(/ *\([0-9]+.*\) *$/, '');
+ }
+ });
+ update_period('#rec_year_from', '#rec_year_to');
+ $('#rec_year_from, #rec_year_to').change(function () {
+ update_period(this, '#rec_year_from', '#rec_year_to');
+ });
+ update_period('#pub_year_from', '#pub_year_to');
+ $('#pub_year_from, #pub_year_to').change(function () {
+ update_period(this, '#pub_year_from', '#pub_year_to');
+ });
+});
+
+$(document).ready(function() {
+ $(this).keydown(function(e) {
+ if (e.keyCode == '13') {
+ $("#searchform").submit();
+ }
+ });
+});
+
+</script>
+{% endblock %}
+
+{% block title %}
+<div class='row'>
+ <div class="col-md-12">
+ <img src="{{ STATIC_URL }}telemeta/images/adv_search_red.png" alt="advanced-search" style="vertical-align:middle" /> {% trans "Advanced Search" %}
+ </div>
+</div>
+
+{% endblock %}
+
+{% block content %}
+<form action="{% url "telemeta-search" %}" id="searchform" method="get">
+<fieldset>
+
+ <p>
+ <label for="location">{% field_label "Location" %}</label>
+ <input type="text" name="location" id="location" value="{{ criteria.location }}" />
+ </p>
+
+ <p>
+ <label for="instrument">{% field_label "Instrument" %}</label>
+ <input type="text" name="instrument" id="instrument" />
+ </p>
+
+ <p>
+ <label for="ethnic_group">{% field_label "EthnicGroup" %}</label>
+ <select id="ethnic_group" name="ethnic_group">
+ <option value="">All ethnic groups</option>
+ {% for group in ethnic_groups %}
+ <option value="{{group.id}}" {% ifequal criteria.ethnic_group.id group.id %}selected {% endifequal %}>{{group|escape}}</option>
+ {% endfor %}
+ </select>
+ </p>
+
+ <p>
+ <label for="title">{% trans "Title" %}</label>
+ <input type="text" id="title" name="title" />
+ </p>
+
+ <p>
+ <label for="creator">{% field_label "MediaCollection" "creator" %}</label>
+ <input type="text" id="creator" name="creator" />
+ </p>
+
+ <p>
+ <label for="collector">{% field_label "MediaCollection" "collector" %}</label>
+ <input type="text" id="collector" name="collector" />
+ </p>
+
+ {% if rec_years %}
+ <p>
+ <label for="rec_date_from">{% trans "Year of recording" %}</label>
+ <select id="rec_year_from" name="rec_year_from" class="tiny">
+ <option value="0"></option>
+ {% for year in rec_years %}
+ <option value="{{ year }}" {% ifequal criteria.rec_year_from year %}selected {% endifequal %}>{{year}}</option>
+ {% endfor %}
+ </select>
+ {% trans "to" %}
+ <select id="rec_year_to" name="rec_year_to" class="tiny">
+ <option value="0"></option>
+ {% for year in rec_years %}
+ <option value="{{ year }}" {% ifequal criteria.rec_year_to year %}selected {% endifequal %}>{{year}}</option>
+ {% endfor %}
+ </select>
+ </p>
+ {% endif %}
+
+ {% if pub_years %}
+ <p>
+ <label for="pub_date_from">{% trans "Year of publication" %}</label>
+ <select id="pub_year_from" name="pub_year_from" class="tiny">
+ <option value="0"></option>
+ {% for year in pub_years %}
+ <option value="{{ year }}" {% ifequal criteria.pub_year_from year %}selected {% endifequal %}>{{year}}</option>
+ {% endfor %}
+ </select>
+ {% trans "to" %}
+ <select id="pub_year_to" name="pub_year_to" class="tiny">
+ <option value="0"></option>
+ {% for year in pub_years %}
+ <option value="{{ year }}" {% ifequal criteria.pub_year_to year %}selected {% endifequal %}>{{year}}</option>
+ {% endfor %}
+ </select>
+ </p>
+ {% endif %}
+
+ <p><label for="sound">{% trans "Digitized" %}</label>
+ <input type="checkbox" name="sound" value="True" align="left" />
+ </p>
+
+</fieldset>
+
+<p class="input">
+<a href="#" class="component_icon button icon_search"
+ onclick="document.getElementById('searchform').submit(); return false;">{% trans 'Search' %}</a>
+</p>
+
+</form>
+{% endblock %}
--- /dev/null
+{% extends "telemeta/base.html" %}
+{% load telemeta_tags %}
+{% load i18n %}
+{% load bootstrap_pagination %}
+
+{% block head_title %}{% trans "Search Results" %} - {{ block.super }}{% endblock %}
+
+{% block title %}
+<div class='row'>
+<div class="col-md-5">
+ <img src="{{ STATIC_URL }}telemeta/images/search_red.png" alt="search-results" style="vertical-align:middle" /> {% trans "Search Results" %} ({{ page_obj.start_index }} - {{ page_obj.end_index }} / {{ count }})
+</div>
+<div class="col-md-7">
+{% bootstrap_paginate page_obj range=10 show_first_last="True" %}
+</div>
+<div class="col-md-0"> </div>
+</div>
+{% endblock %}
+
+{% block title_buttons %}
+ <div class="btn-group">
+ {% ifequal type 'items' %}
+ <button type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown">
+ <span class="glyphicon glyphicon-filter"></span> {% trans "Filters" %} <span class="caret"></span>
+ </button>
+ <ul class="dropdown-menu" role="menu">
+ <li><a href="{% url "telemeta-search-type" "items" %}?{{criteria|with_no_sound|build_query_string}}" class="">{% trans "All" %}</a></li>
+ <li><a href="{% url "telemeta-search-type" "items" %}?{{criteria|with_sound|build_query_string}}">{% trans "Sounds" %}</a></li>
+ <li><a href="{% url "telemeta-search-published" "items" %}?{{criteria|with_no_sound|build_query_string}}">{% trans "Published" %}</a></li>
+ <li><a href="{% url "telemeta-search-unpublished" "items" %}?{{criteria|with_no_sound|build_query_string}}">{% trans "Unpublished" %}</a></li>
+ <li><a href="{% url "telemeta-search-full" "items" %}?{{criteria|with_no_sound|build_query_string}}">{% trans "Full" %}</a></li>
+ <li><a href="{% url "telemeta-search-none" "items" %}?{{criteria|with_no_sound|build_query_string}}">{% trans "None" %}</a></li>
+ </ul>
+ {% endifequal %}
+ {% ifequal type 'collections' %}
+ <button type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown">
+ <span class="glyphicon glyphicon-filter"></span> {% trans "Filters" %} <span class="caret"></span>
+ </button>
+ <ul class="dropdown-menu" role="menu">
+ <li><a href="{% url "telemeta-search-type" "collections" %}?{{criteria|with_no_sound|build_query_string}}" class="">{% trans "All" %}</a></li>
+ <li><a href="{% url "telemeta-search-type" "collections" %}?{{criteria|with_sound|build_query_string}}">{% trans "Sounds" %}</a></li>
+ <li><a href="{% url "telemeta-search-published" "collections" %}?{{criteria|with_no_sound|build_query_string}}">{% trans "Published" %}</a></li>
+ <li><a href="{% url "telemeta-search-unpublished" "collections" %}?{{criteria|with_no_sound|build_query_string}}">{% trans "Unpublished" %}</a></li>
+ <li><a href="{% url "telemeta-search-full" "collections" %}?{{criteria|with_no_sound|build_query_string}}">{% trans "Full" %}</a></li>
+ <li><a href="{% url "telemeta-search-none" "collections" %}?{{criteria|with_no_sound|build_query_string}}">{% trans "None" %}</a></li>
+ </ul>
+ {% endifequal %}
+ </div>
+{% endblock %}
+
+{% block content %}
+{% if criteria %}
+<ul>
+ {% if criteria.pattern %}
+ <li><b>{% trans "Search pattern" %}:</b> {{criteria.pattern}}</li>
+ {% endif %}
+ {% if criteria.location %}
+ <li><b>{% field_label "Location" %}:</b> {{criteria.location}}</li>
+ {% endif %}
+ {% if criteria.instrument %}
+ <li><b>{% field_label "Instrument" %}:</b> {{criteria.instrument}}</li>
+ {% endif %}
+ {% if criteria.ethnic_group %}
+ <li><b>{% field_label "EthnicGroup" %}:</b> {{criteria.ethnic_group}}</li>
+ {% endif %}
+ {% if criteria.creator %}
+ <li><b>{% field_label "MediaCollection" "creator" %}:</b> {{criteria.creator}}</li>
+ {% endif %}
+ {% if criteria.collector %}
+ <li><b>{% field_label "MediaCollection" "collector" %}:</b> {{criteria.collector}}</li>
+ {% endif %}
+ {% if criteria.title %}
+ <li><b>{% trans "Title" %}:</b> {{criteria.title}}</li>
+ {% endif %}
+ {% if criteria.rec_year_from %}
+ <li><b>{% trans "Year of recording" %}:</b> {{criteria.rec_year_from}}
+ {% ifnotequal criteria.rec_year_to criteria.rec_year_from %}
+ {% trans "to" %} {{criteria.rec_year_to}}
+ {% endifnotequal %}
+ </li>
+ {% endif %}
+ {% if criteria.pub_year_from %}
+ <li><b>{% trans "Year of publication" %}:</b> {{criteria.pub_year_from}}
+ {% ifnotequal criteria.pub_year_to criteria.pub_year_from %}
+ {% trans "to" %} {{criteria.pub_year_to}}
+ {% endifnotequal %}
+ </li>
+ {% endif %}
+ {% if criteria.sound %}
+ <li><b>{% trans "Sound" %}:</b> {{criteria.sound}}</li>
+ {% endif %}
+</ul>
+{% endif %}
+
+{% ifequal type 'items' %}
+ {% ifequal result_filter "published"%}
+ <p><b>Items ({{items_num}}) | <a href="{% url "telemeta-search-published" "collections" %}?{{criteria|build_query_string}}">Collections ({{collections_num}})</a> | <a href="{% url "telemeta-search-published" "corpus" %}?{{criteria|build_query_string}}">Corpus ({{corpus_num}})</a> | <a href="{% url "telemeta-search-published" "fonds" %}?{{criteria|build_query_string}}">Fonds ({{fonds_num}})</a></b></p>
+ {% with object_list as items %}
+ <div class="fullpage">
+ {% include "telemeta/inc/mediaitem_list.html" %}
+ </div>
+ {% endwith %}
+ {% else%}
+ {% ifequal result_filter "unpublished"%}
+ <p><b>Items ({{items_num}}) | <a href="{% url "telemeta-search-unpublished" "collections" %}?{{criteria|build_query_string}}">Collections ({{collections_num}})</a> | <a href="{% url "telemeta-search-unpublished" "corpus" %}?{{criteria|build_query_string}}">Corpus ({{corpus_num}})</a> | <a href="{% url "telemeta-search-unpublished" "fonds" %}?{{criteria|build_query_string}}">Fonds ({{fonds_num}})</a></b></p>
+ {% with object_list as items %}
+ <div class="fullpage">
+ {% include "telemeta/inc/mediaitem_list.html" %}
+ </div>
+ {% endwith %}
+ {% else%}
+ {% ifequal result_filter "full"%}
+ <p><b>Items ({{items_num}}) | <a href="{% url "telemeta-search-full" "collections" %}?{{criteria|build_query_string}}">Collections ({{collections_num}})</a> | <a href="{% url "telemeta-search-full" "corpus" %}?{{criteria|build_query_string}}">Corpus ({{corpus_num}})</a> | <a href="{% url "telemeta-search-full" "fonds" %}?{{criteria|build_query_string}}">Fonds ({{fonds_num}})</a></b></p>
+ {% with object_list as items %}
+ <div class="fullpage">
+ {% include "telemeta/inc/mediaitem_list.html" %}
+ </div>
+ {% endwith %}
+ {% else%}
+ {% ifequal result_filter "none"%}
+ <p><b>Items ({{items_num}}) | <a href="{% url "telemeta-search-none" "collections" %}?{{criteria|build_query_string}}">Collections ({{collections_num}})</a> | <a href="{% url "telemeta-search-none" "corpus" %}?{{criteria|build_query_string}}">Corpus ({{corpus_num}})</a> | <a href="{% url "telemeta-search-none" "fonds" %}?{{criteria|build_query_string}}">Fonds ({{fonds_num}})</a></b></p>
+ {% with object_list as items %}
+ <div class="fullpage">
+ {% include "telemeta/inc/mediaitem_list.html" %}
+ </div>
+ {% endwith %}
+ {% else%}
+ <p><b>Items ({{items_num}}) | <a href="{% url "telemeta-search-type" "collections" %}?{{criteria|build_query_string}}">Collections ({{collections_num}})</a> | <a href="{% url "telemeta-search-type" "corpus" %}?{{criteria|build_query_string}}">Corpus ({{corpus_num}})</a> | <a href="{% url "telemeta-search-type" "fonds" %}?{{criteria|build_query_string}}">Fonds ({{fonds_num}})</a></b></p>
+ {% with object_list as items %}
+ <div class="fullpage">
+ {% include "telemeta/inc/mediaitem_list.html" %}
+ </div>
+ {% endwith %}
+ {%endifequal%}
+ {%endifequal%}
+ {%endifequal%}
+ {% endifequal %}
+{% endifequal %}
+
+{% ifequal type 'collections' %}
+ {% ifequal result_filter "published"%}
+ <p><b><a href="{% url "telemeta-search-published" "items" %}?{{criteria|build_query_string}}">Items ({{items_num}})</a> | Collections ({{collections_num}}) | <a href="{% url "telemeta-search-published" "corpus" %}?{{criteria|build_query_string}}">Corpus ({{corpus_num}})</a> | <a href="{% url "telemeta-search-published" "fonds" %}?{{criteria|build_query_string}}">Fonds ({{fonds_num}})</a>
+ </b></p>
+ {% with object_list as collections %}
+ <div class="fullpage">
+ {% include "telemeta/inc/collection_list.html" %}
+ </div>
+ {% endwith %}
+ {% else %}
+ {%ifequal result_filter "unpublished"%}
+ <p><b><a href="{% url "telemeta-search-unpublished" "items" %}?{{criteria|build_query_string}}">Items ({{items_num}})</a> | Collections ({{collections_num}}) | <a href="{% url "telemeta-search-unpublished" "corpus" %}?{{criteria|build_query_string}}">Corpus ({{corpus_num}})</a> | <a href="{% url "telemeta-search-unpublished" "fonds" %}?{{criteria|build_query_string}}">Fonds ({{fonds_num}})</a>
+ </b></p>
+ {% with object_list as collections %}
+ <div class="fullpage">
+ {% include "telemeta/inc/collection_list.html" %}
+ </div>
+ {% endwith %}
+ {%else%}
+ {%ifequal result_filter "full"%}
+ <p><b><a href="{% url "telemeta-search-full" "items" %}?{{criteria|build_query_string}}">Items ({{items_num}})</a> | Collections ({{collections_num}}) | <a href="{% url "telemeta-search-full" "corpus" %}?{{criteria|build_query_string}}">Corpus ({{corpus_num}})</a> | <a href="{% url "telemeta-search-full" "fonds" %}?{{criteria|build_query_string}}">Fonds ({{fonds_num}})</a>
+ </b></p>
+ {% with object_list as collections %}
+ <div class="fullpage">
+ {% include "telemeta/inc/collection_list.html" %}
+ </div>
+ {% endwith %}
+ {%else%}
+ {%ifequal result_filter "none"%}
+ <p><b><a href="{% url "telemeta-search-none" "items" %}?{{criteria|build_query_string}}">Items ({{items_num}})</a> | Collections ({{collections_num}}) | <a href="{% url "telemeta-search-none" "corpus" %}?{{criteria|build_query_string}}">Corpus ({{corpus_num}})</a> | <a href="{% url "telemeta-search-none" "fonds" %}?{{criteria|build_query_string}}">Fonds ({{fonds_num}})</a>
+ </b></p>
+ {% with object_list as collections %}
+ <div class="fullpage">
+ {% include "telemeta/inc/collection_list.html" %}
+ </div>
+ {% endwith %}
+ {%else%}
+ <p><b><a href="{% url "telemeta-search-type" "items" %}?{{criteria|build_query_string}}">Items ({{items_num}})</a> | Collections ({{collections_num}}) | <a href="{% url "telemeta-search-type" "corpus" %}?{{criteria|build_query_string}}">Corpus ({{corpus_num}})</a> | <a href="{% url "telemeta-search-type" "fonds" %}?{{criteria|build_query_string}}">Fonds ({{fonds_num}})</a>
+ </b></p>
+ {% with object_list as collections %}
+ <div class="fullpage">
+ {% include "telemeta/inc/collection_list.html" %}
+ </div>
+ {% endwith %}
+ {%endifequal%}
+ {%endifequal%}
+ {%endifequal%}
+ {%endifequal%}
+{% endifequal %}
+
+{% if type == 'corpus' %}
+<p><b><a href="{% url "telemeta-search-type" "items" %}?{{criteria|build_query_string}}">Items ({{items_num}})</a> | <a href="{% url "telemeta-search-type" "collections" %}?{{criteria|build_query_string}}">Collections ({{collections_num}})</a> | Corpus ({{corpus_num}}) | <a href="{% url "telemeta-search-type" "fonds" %}?{{criteria|build_query_string}}">Fonds ({{fonds_num}})</a>
+</b></p>
+{% endif %}
+
+{% if type == 'fonds' %}
+<p><b><a href="{% url "telemeta-search-type" "items" %}?{{criteria|build_query_string}}">Items ({{items_num}})</a> | <a href="{% url "telemeta-search-type" "collections" %}?{{criteria|build_query_string}}">Collections ({{collections_num}})</a> | <a href="{% url "telemeta-search-type" "corpus" %}?{{criteria|build_query_string}}">Corpus ({{corpus_num}})</a> | Fonds ({{fonds_num}})
+</b></p>
+{% endif %}
+
+{% if type == 'corpus' or type == 'fonds' %}
+{% with object_list as resources and type as type %}
+<div class="fullpage">
+{% include "telemeta/inc/resource_list.html" %}
+</div>
+{% endwith %}
+{% endif %}
+
+
+{% endblock %}
+++ /dev/null
-{% extends "telemeta/base.html" %}
-{% load telemeta_tags %}
-{% load i18n %}
-
-{% block head_title %}{% trans "Advanced Search" %} - {{ block.super }}{% endblock %}
-
-{% block stylesheets %}
-{{ block.super }}
-<link rel="stylesheet" type="text/css" href="{{ STATIC_URL }}telemeta/css/jquery.autocomplete.css" />
-{% endblock %}
-
-{% block extra_javascript %}
-<script src="{{ STATIC_URL }}telemeta/js/jquery.bgiframe.js" type="text/javascript"></script>
-<script src="{{ STATIC_URL }}telemeta/js/jquery.mb.browser.min.js" type="text/javascript"></script>
-<script src="{{ STATIC_URL }}telemeta/js/jquery.autocomplete.js" type="text/javascript"></script>
-
-
-<script type="text/javascript">
-
-$(function(){
- var txt = ''
- +'jQuery.browser.ua = '+jQuery.browser.ua+'<br>'
- +'jQuery.browser.name = '+jQuery.browser.name+'<br>'
- +'jQuery.browser.fullVersion = '+jQuery.browser.fullVersion+'<br>'
- +'jQuery.browser.version = '+jQuery.browser.version+'<br><br><br>'
- +'jQuery.browser.msie = '+jQuery.browser.msie+'<br>'
- +'jQuery.browser.mozilla = '+jQuery.browser.mozilla+'<br>'
- +'jQuery.browser.opera = '+jQuery.browser.opera+'<br>'
- +'jQuery.browser.webkit = '+jQuery.browser.webkit+'<br>'
- +'jQuery.browser.safari = '+jQuery.browser.safari+'<br>'
- +'jQuery.browser.chrome = '+jQuery.browser.chrome+'<br>';
- $("#result").html(txt);
-});
-
-
-function update_period(source, from_field, to_field) {
- var from_year = $(from_field);
- var to_year = $(to_field);
-
- if (from_year.val() == "0") {
- to_year.attr('disabled', '1');
- to_year.val('0');
- } else {
- to_year.removeAttr('disabled');
- if ($(source).is(to_field)) {
- if (parseInt(from_year.val()) > parseInt(to_year.val()))
- from_year.val(to_year.val());
- } else if (parseInt(from_year.val()) > parseInt(to_year.val())) {
- to_year.val(from_year.val());
- }
- }
-}
-
-$(document).ready(function () {
- $('#location').autocomplete('{% url "telemeta-complete-location" %}', {
- max: 20,
- formatResult: function(data) {
- return data[0].replace(/ *\([0-9]+.*\) *$/, '');
- }
- });
- update_period('#rec_year_from', '#rec_year_to');
- $('#rec_year_from, #rec_year_to').change(function () {
- update_period(this, '#rec_year_from', '#rec_year_to');
- });
- update_period('#pub_year_from', '#pub_year_to');
- $('#pub_year_from, #pub_year_to').change(function () {
- update_period(this, '#pub_year_from', '#pub_year_to');
- });
-});
-
-$(document).ready(function() {
- $(this).keydown(function(e) {
- if (e.keyCode == '13') {
- $("#searchform").submit();
- }
- });
-});
-
-</script>
-{% endblock %}
-
-{% block title %}
-<div class='row'>
- <div class="col-md-12">
- <img src="{{ STATIC_URL }}telemeta/images/adv_search_red.png" alt="advanced-search" style="vertical-align:middle" /> {% trans "Advanced Search" %}
- </div>
-</div>
-
-{% endblock %}
-
-{% block content %}
-<form action="{% url "telemeta-search" %}" id="searchform" method="get">
-<fieldset>
-
- <p>
- <label for="location">{% field_label "Location" %}</label>
- <input type="text" name="location" id="location" value="{{ criteria.location }}" />
- </p>
-
- <p>
- <label for="instrument">{% field_label "Instrument" %}</label>
- <input type="text" name="instrument" id="instrument" />
- </p>
-
- <p>
- <label for="ethnic_group">{% field_label "EthnicGroup" %}</label>
- <select id="ethnic_group" name="ethnic_group">
- <option value="">All ethnic groups</option>
- {% for group in ethnic_groups %}
- <option value="{{group.id}}" {% ifequal criteria.ethnic_group.id group.id %}selected {% endifequal %}>{{group|escape}}</option>
- {% endfor %}
- </select>
- </p>
-
- <p>
- <label for="title">{% trans "Title" %}</label>
- <input type="text" id="title" name="title" />
- </p>
-
- <p>
- <label for="creator">{% field_label "MediaCollection" "creator" %}</label>
- <input type="text" id="creator" name="creator" />
- </p>
-
- <p>
- <label for="collector">{% field_label "MediaCollection" "collector" %}</label>
- <input type="text" id="collector" name="collector" />
- </p>
-
- {% if rec_years %}
- <p>
- <label for="rec_date_from">{% trans "Year of recording" %}</label>
- <select id="rec_year_from" name="rec_year_from" class="tiny">
- <option value="0"></option>
- {% for year in rec_years %}
- <option value="{{ year }}" {% ifequal criteria.rec_year_from year %}selected {% endifequal %}>{{year}}</option>
- {% endfor %}
- </select>
- {% trans "to" %}
- <select id="rec_year_to" name="rec_year_to" class="tiny">
- <option value="0"></option>
- {% for year in rec_years %}
- <option value="{{ year }}" {% ifequal criteria.rec_year_to year %}selected {% endifequal %}>{{year}}</option>
- {% endfor %}
- </select>
- </p>
- {% endif %}
-
- {% if pub_years %}
- <p>
- <label for="pub_date_from">{% trans "Year of publication" %}</label>
- <select id="pub_year_from" name="pub_year_from" class="tiny">
- <option value="0"></option>
- {% for year in pub_years %}
- <option value="{{ year }}" {% ifequal criteria.pub_year_from year %}selected {% endifequal %}>{{year}}</option>
- {% endfor %}
- </select>
- {% trans "to" %}
- <select id="pub_year_to" name="pub_year_to" class="tiny">
- <option value="0"></option>
- {% for year in pub_years %}
- <option value="{{ year }}" {% ifequal criteria.pub_year_to year %}selected {% endifequal %}>{{year}}</option>
- {% endfor %}
- </select>
- </p>
- {% endif %}
-
- <p><label for="sound">{% trans "Digitized" %}</label>
- <input type="checkbox" name="sound" value="True" align="left" />
- </p>
-
-</fieldset>
-
-<p class="input">
-<a href="#" class="component_icon button icon_search"
- onclick="document.getElementById('searchform').submit(); return false;">{% trans 'Search' %}</a>
-</p>
-
-</form>
-{% endblock %}
+++ /dev/null
-{% extends "telemeta/base.html" %}
-{% load telemeta_tags %}
-{% load i18n %}
-{% load bootstrap_pagination %}
-
-{% block head_title %}{% trans "Search Results" %} - {{ block.super }}{% endblock %}
-
-{% block title %}
-<div class='row'>
-<div class="col-md-5">
- <img src="{{ STATIC_URL }}telemeta/images/search_red.png" alt="search-results" style="vertical-align:middle" /> {% trans "Search Results" %} ({{ page_obj.start_index }} - {{ page_obj.end_index }} / {{ count }})
-</div>
-<div class="col-md-7">
-{% bootstrap_paginate page_obj range=10 show_first_last="True" %}
-</div>
-<div class="col-md-0"> </div>
-</div>
-{% endblock %}
-
-{% block title_buttons %}
- <div class="btn-group">
- {% ifequal type 'items' %}
- <button type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown">
- <span class="glyphicon glyphicon-filter"></span> {% trans "Filters" %} <span class="caret"></span>
- </button>
- <ul class="dropdown-menu" role="menu">
- <li><a href="{% url "telemeta-search-type" "items" %}?{{criteria|with_no_sound|build_query_string}}" class="">{% trans "All" %}</a></li>
- <li><a href="{% url "telemeta-search-type" "items" %}?{{criteria|with_sound|build_query_string}}">{% trans "Sounds" %}</a></li>
- <li><a href="{% url "telemeta-search-published" "items" %}?{{criteria|with_no_sound|build_query_string}}">{% trans "Published" %}</a></li>
- <li><a href="{% url "telemeta-search-unpublished" "items" %}?{{criteria|with_no_sound|build_query_string}}">{% trans "Unpublished" %}</a></li>
- <li><a href="{% url "telemeta-search-full" "items" %}?{{criteria|with_no_sound|build_query_string}}">{% trans "Full" %}</a></li>
- <li><a href="{% url "telemeta-search-none" "items" %}?{{criteria|with_no_sound|build_query_string}}">{% trans "None" %}</a></li>
- </ul>
- {% endifequal %}
- {% ifequal type 'collections' %}
- <button type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown">
- <span class="glyphicon glyphicon-filter"></span> {% trans "Filters" %} <span class="caret"></span>
- </button>
- <ul class="dropdown-menu" role="menu">
- <li><a href="{% url "telemeta-search-type" "collections" %}?{{criteria|with_no_sound|build_query_string}}" class="">{% trans "All" %}</a></li>
- <li><a href="{% url "telemeta-search-type" "collections" %}?{{criteria|with_sound|build_query_string}}">{% trans "Sounds" %}</a></li>
- <li><a href="{% url "telemeta-search-published" "collections" %}?{{criteria|with_no_sound|build_query_string}}">{% trans "Published" %}</a></li>
- <li><a href="{% url "telemeta-search-unpublished" "collections" %}?{{criteria|with_no_sound|build_query_string}}">{% trans "Unpublished" %}</a></li>
- <li><a href="{% url "telemeta-search-full" "collections" %}?{{criteria|with_no_sound|build_query_string}}">{% trans "Full" %}</a></li>
- <li><a href="{% url "telemeta-search-none" "collections" %}?{{criteria|with_no_sound|build_query_string}}">{% trans "None" %}</a></li>
- </ul>
- {% endifequal %}
- </div>
-{% endblock %}
-
-{% block content %}
-{% if criteria %}
-<ul>
- {% if criteria.pattern %}
- <li><b>{% trans "Search pattern" %}:</b> {{criteria.pattern}}</li>
- {% endif %}
- {% if criteria.location %}
- <li><b>{% field_label "Location" %}:</b> {{criteria.location}}</li>
- {% endif %}
- {% if criteria.instrument %}
- <li><b>{% field_label "Instrument" %}:</b> {{criteria.instrument}}</li>
- {% endif %}
- {% if criteria.ethnic_group %}
- <li><b>{% field_label "EthnicGroup" %}:</b> {{criteria.ethnic_group}}</li>
- {% endif %}
- {% if criteria.creator %}
- <li><b>{% field_label "MediaCollection" "creator" %}:</b> {{criteria.creator}}</li>
- {% endif %}
- {% if criteria.collector %}
- <li><b>{% field_label "MediaCollection" "collector" %}:</b> {{criteria.collector}}</li>
- {% endif %}
- {% if criteria.title %}
- <li><b>{% trans "Title" %}:</b> {{criteria.title}}</li>
- {% endif %}
- {% if criteria.rec_year_from %}
- <li><b>{% trans "Year of recording" %}:</b> {{criteria.rec_year_from}}
- {% ifnotequal criteria.rec_year_to criteria.rec_year_from %}
- {% trans "to" %} {{criteria.rec_year_to}}
- {% endifnotequal %}
- </li>
- {% endif %}
- {% if criteria.pub_year_from %}
- <li><b>{% trans "Year of publication" %}:</b> {{criteria.pub_year_from}}
- {% ifnotequal criteria.pub_year_to criteria.pub_year_from %}
- {% trans "to" %} {{criteria.pub_year_to}}
- {% endifnotequal %}
- </li>
- {% endif %}
- {% if criteria.sound %}
- <li><b>{% trans "Sound" %}:</b> {{criteria.sound}}</li>
- {% endif %}
-</ul>
-{% endif %}
-
-{% ifequal type 'items' %}
- {% ifequal result_filter "published"%}
- <p><b>Items ({{items_num}}) | <a href="{% url "telemeta-search-published" "collections" %}?{{criteria|build_query_string}}">Collections ({{collections_num}})</a> | <a href="{% url "telemeta-search-published" "corpus" %}?{{criteria|build_query_string}}">Corpus ({{corpus_num}})</a> | <a href="{% url "telemeta-search-published" "fonds" %}?{{criteria|build_query_string}}">Fonds ({{fonds_num}})</a></b></p>
- {% with object_list as items %}
- <div class="fullpage">
- {% include "telemeta/inc/mediaitem_list.html" %}
- </div>
- {% endwith %}
- {% else%}
- {% ifequal result_filter "unpublished"%}
- <p><b>Items ({{items_num}}) | <a href="{% url "telemeta-search-unpublished" "collections" %}?{{criteria|build_query_string}}">Collections ({{collections_num}})</a> | <a href="{% url "telemeta-search-unpublished" "corpus" %}?{{criteria|build_query_string}}">Corpus ({{corpus_num}})</a> | <a href="{% url "telemeta-search-unpublished" "fonds" %}?{{criteria|build_query_string}}">Fonds ({{fonds_num}})</a></b></p>
- {% with object_list as items %}
- <div class="fullpage">
- {% include "telemeta/inc/mediaitem_list.html" %}
- </div>
- {% endwith %}
- {% else%}
- {% ifequal result_filter "full"%}
- <p><b>Items ({{items_num}}) | <a href="{% url "telemeta-search-full" "collections" %}?{{criteria|build_query_string}}">Collections ({{collections_num}})</a> | <a href="{% url "telemeta-search-full" "corpus" %}?{{criteria|build_query_string}}">Corpus ({{corpus_num}})</a> | <a href="{% url "telemeta-search-full" "fonds" %}?{{criteria|build_query_string}}">Fonds ({{fonds_num}})</a></b></p>
- {% with object_list as items %}
- <div class="fullpage">
- {% include "telemeta/inc/mediaitem_list.html" %}
- </div>
- {% endwith %}
- {% else%}
- {% ifequal result_filter "none"%}
- <p><b>Items ({{items_num}}) | <a href="{% url "telemeta-search-none" "collections" %}?{{criteria|build_query_string}}">Collections ({{collections_num}})</a> | <a href="{% url "telemeta-search-none" "corpus" %}?{{criteria|build_query_string}}">Corpus ({{corpus_num}})</a> | <a href="{% url "telemeta-search-none" "fonds" %}?{{criteria|build_query_string}}">Fonds ({{fonds_num}})</a></b></p>
- {% with object_list as items %}
- <div class="fullpage">
- {% include "telemeta/inc/mediaitem_list.html" %}
- </div>
- {% endwith %}
- {% else%}
- <p><b>Items ({{items_num}}) | <a href="{% url "telemeta-search-type" "collections" %}?{{criteria|build_query_string}}">Collections ({{collections_num}})</a> | <a href="{% url "telemeta-search-type" "corpus" %}?{{criteria|build_query_string}}">Corpus ({{corpus_num}})</a> | <a href="{% url "telemeta-search-type" "fonds" %}?{{criteria|build_query_string}}">Fonds ({{fonds_num}})</a></b></p>
- {% with object_list as items %}
- <div class="fullpage">
- {% include "telemeta/inc/mediaitem_list.html" %}
- </div>
- {% endwith %}
- {%endifequal%}
- {%endifequal%}
- {%endifequal%}
- {% endifequal %}
-{% endifequal %}
-
-{% ifequal type 'collections' %}
- {% ifequal result_filter "published"%}
- <p><b><a href="{% url "telemeta-search-published" "items" %}?{{criteria|build_query_string}}">Items ({{items_num}})</a> | Collections ({{collections_num}}) | <a href="{% url "telemeta-search-published" "corpus" %}?{{criteria|build_query_string}}">Corpus ({{corpus_num}})</a> | <a href="{% url "telemeta-search-published" "fonds" %}?{{criteria|build_query_string}}">Fonds ({{fonds_num}})</a>
- </b></p>
- {% with object_list as collections %}
- <div class="fullpage">
- {% include "telemeta/inc/collection_list.html" %}
- </div>
- {% endwith %}
- {% else %}
- {%ifequal result_filter "unpublished"%}
- <p><b><a href="{% url "telemeta-search-unpublished" "items" %}?{{criteria|build_query_string}}">Items ({{items_num}})</a> | Collections ({{collections_num}}) | <a href="{% url "telemeta-search-unpublished" "corpus" %}?{{criteria|build_query_string}}">Corpus ({{corpus_num}})</a> | <a href="{% url "telemeta-search-unpublished" "fonds" %}?{{criteria|build_query_string}}">Fonds ({{fonds_num}})</a>
- </b></p>
- {% with object_list as collections %}
- <div class="fullpage">
- {% include "telemeta/inc/collection_list.html" %}
- </div>
- {% endwith %}
- {%else%}
- {%ifequal result_filter "full"%}
- <p><b><a href="{% url "telemeta-search-full" "items" %}?{{criteria|build_query_string}}">Items ({{items_num}})</a> | Collections ({{collections_num}}) | <a href="{% url "telemeta-search-full" "corpus" %}?{{criteria|build_query_string}}">Corpus ({{corpus_num}})</a> | <a href="{% url "telemeta-search-full" "fonds" %}?{{criteria|build_query_string}}">Fonds ({{fonds_num}})</a>
- </b></p>
- {% with object_list as collections %}
- <div class="fullpage">
- {% include "telemeta/inc/collection_list.html" %}
- </div>
- {% endwith %}
- {%else%}
- {%ifequal result_filter "none"%}
- <p><b><a href="{% url "telemeta-search-none" "items" %}?{{criteria|build_query_string}}">Items ({{items_num}})</a> | Collections ({{collections_num}}) | <a href="{% url "telemeta-search-none" "corpus" %}?{{criteria|build_query_string}}">Corpus ({{corpus_num}})</a> | <a href="{% url "telemeta-search-none" "fonds" %}?{{criteria|build_query_string}}">Fonds ({{fonds_num}})</a>
- </b></p>
- {% with object_list as collections %}
- <div class="fullpage">
- {% include "telemeta/inc/collection_list.html" %}
- </div>
- {% endwith %}
- {%else%}
- <p><b><a href="{% url "telemeta-search-type" "items" %}?{{criteria|build_query_string}}">Items ({{items_num}})</a> | Collections ({{collections_num}}) | <a href="{% url "telemeta-search-type" "corpus" %}?{{criteria|build_query_string}}">Corpus ({{corpus_num}})</a> | <a href="{% url "telemeta-search-type" "fonds" %}?{{criteria|build_query_string}}">Fonds ({{fonds_num}})</a>
- </b></p>
- {% with object_list as collections %}
- <div class="fullpage">
- {% include "telemeta/inc/collection_list.html" %}
- </div>
- {% endwith %}
- {%endifequal%}
- {%endifequal%}
- {%endifequal%}
- {%endifequal%}
-{% endifequal %}
-
-{% if type == 'corpus' %}
-<p><b><a href="{% url "telemeta-search-type" "items" %}?{{criteria|build_query_string}}">Items ({{items_num}})</a> | <a href="{% url "telemeta-search-type" "collections" %}?{{criteria|build_query_string}}">Collections ({{collections_num}})</a> | Corpus ({{corpus_num}}) | <a href="{% url "telemeta-search-type" "fonds" %}?{{criteria|build_query_string}}">Fonds ({{fonds_num}})</a>
-</b></p>
-{% endif %}
-
-{% if type == 'fonds' %}
-<p><b><a href="{% url "telemeta-search-type" "items" %}?{{criteria|build_query_string}}">Items ({{items_num}})</a> | <a href="{% url "telemeta-search-type" "collections" %}?{{criteria|build_query_string}}">Collections ({{collections_num}})</a> | <a href="{% url "telemeta-search-type" "corpus" %}?{{criteria|build_query_string}}">Corpus ({{corpus_num}})</a> | Fonds ({{fonds_num}})
-</b></p>
-{% endif %}
-
-{% if type == 'corpus' or type == 'fonds' %}
-{% with object_list as resources and type as type %}
-<div class="fullpage">
-{% include "telemeta/inc/resource_list.html" %}
-</div>
-{% endwith %}
-{% endif %}
-
-
-{% endblock %}
url(r'^archives/items/(?P<public_id>[A-Za-z0-9._-]+)/dc/xml/$', item_view.item_detail, {'format': 'dublin_core_xml'}, name="telemeta-item-dublincore-xml"),
url(r'^archives/items/download/(?P<public_id>[A-Za-z0-9._-]+)\.(?P<extension>' + export_extensions + ')$', item_view.item_export, name="telemeta-item-export"),
url(r'^archives/items/download/(?P<public_id>[A-Za-z0-9._-]+)\.(?P<extension>' + export_extensions + ')/isAvailable$', item_view.item_export_available, name="telemeta-item-export-available"),
-
+
url(r'^archives/items/(?P<public_id>[A-Za-z0-9._-]+)/visualize/(?P<grapher_id>[0-9a-z_]+)/(?P<width>[0-9A-Z]+)x(?P<height>[0-9A-Z]+)/$', item_view.item_visualize, name="telemeta-item-visualize"),
url(r'^archives/items/(?P<public_id>[A-Za-z0-9._-]+)/analyze/xml/$', item_view.item_analyze_xml, name="telemeta-item-analyze-xml"),
url(r'^archives/items/(?P<public_id>[A-Za-z0-9._-]+)/item_xspf.xml$', item_view.item_playlist, dict(template="telemeta/mediaitem_xspf.xml", mimetype="application/xspf+xml"), name="telemeta-item-xspf"),
url(r'^search/$', HaystackSearch(), name='haystack_search'),
url(r'^search/autocomplete/$', autocomplete),
url(r'^search/quick/(?P<type>[A-Za-z0-9._-]+)/$', HaystackSearch(), name='haystack_search_type'),
- url(r'^search/advance/$', HaystackAdvanceSearch(form_class=HayAdvanceForm, template='search/advanceSearch.html'), name='haystack_advance_search'),
- url(r'^search/advance/(?P<type>[A-Za-z0-9._-]+)/$', HaystackAdvanceSearch(form_class=HayAdvanceForm, template='search/advanceSearch.html'), name='haystack_advance_search_type'),
+ url(r'^search/advance/$', HaystackAdvanceSearch(form_class=HayAdvanceForm, template='telemeta/search/search_advanced.html'), name='haystack_advance_search'),
+ url(r'^search/advance/(?P<type>[A-Za-z0-9._-]+)/$', HaystackAdvanceSearch(form_class=HayAdvanceForm, template='telemeta/search/search_advanced.html'), name='haystack_advance_search_type'),
#url(r'^search/booleaninstru/$', boolean_view.get_boolean_query),
url(r'^search/playlist_add/(?P<type>[A-Za-z0-9._-]+)/$', NewPlaylistView().display, name='haystack_playlist'),
self.type=type
- template_name = loader.get_template('search/addplaylist.html')
+ template_name = loader.get_template('telemeta/search/addplaylist.html')
idlist = request.POST.getlist('selected_items_list')
itemlist = []
def addToPlaylist(self, request, type=None):
self.type=type
- template_name = loader.get_template('search/confirmation_add_playslist.html')
+ template_name = loader.get_template('telemeta/search/confirmation_add_playslist.html')
idlist = request.POST.getlist('item_id')
selected_playlist_id = request.POST.get('playlist_id')
'type':self.type,
'lastquerypath': request.POST.get('lastquerypath')})
return HttpResponse(template_name.render(context))
-
-