]> git.parisson.com Git - telemeta.git/commitdiff
Indexation of Corpus and Fonds for the search module
authorRaouf Benmansour <rbenmansour@iut.univ-paris8.fr>
Thu, 17 Dec 2015 13:18:54 +0000 (14:18 +0100)
committerRaouf Benmansour <rbenmansour@iut.univ-paris8.fr>
Thu, 17 Dec 2015 13:18:54 +0000 (14:18 +0100)
telemeta/templates/search/indexes/telemeta/mediacorpus_text.txt [new file with mode: 0644]
telemeta/templates/search/indexes/telemeta/mediafonds_text.txt [new file with mode: 0644]
telemeta/templates/search/mediacorpus_listhaystack.html [new file with mode: 0644]
telemeta/templates/search/mediafonds_listhaystack.html [new file with mode: 0644]

diff --git a/telemeta/templates/search/indexes/telemeta/mediacorpus_text.txt b/telemeta/templates/search/indexes/telemeta/mediacorpus_text.txt
new file mode 100644 (file)
index 0000000..3a702d7
--- /dev/null
@@ -0,0 +1,3 @@
+{{ object.title }}
+{{ object.description}}
+{{ object.body }}
\ No newline at end of file
diff --git a/telemeta/templates/search/indexes/telemeta/mediafonds_text.txt b/telemeta/templates/search/indexes/telemeta/mediafonds_text.txt
new file mode 100644 (file)
index 0000000..3a702d7
--- /dev/null
@@ -0,0 +1,3 @@
+{{ object.title }}
+{{ object.description}}
+{{ object.body }}
\ No newline at end of file
diff --git a/telemeta/templates/search/mediacorpus_listhaystack.html b/telemeta/templates/search/mediacorpus_listhaystack.html
new file mode 100644 (file)
index 0000000..bfc102f
--- /dev/null
@@ -0,0 +1,73 @@
+{% load telemeta_utils %}
+{% load i18n %}
+
+{% if page.object_list %}
+
+<table class="listing">
+<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>
+{% if user.is_authenticated %}
+    {% 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;"></span></center>
+          {% endif %}
+        </td>
+
+        <td>{{ result.object.description }}</td>
+        <td>
+            {{ result.object.code }}
+        </td>
+    </tr>
+    {% endfor %}
+{% 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;"></span></center>
+          {% endif %}
+        </td>
+
+        <td>{{ result.object.description }}</td>
+        <td>
+            {{ result.object.code }}
+        </td>
+    </tr>
+    {% endfor %}
+{% endif %}
+</table>
+{% else %}
+    <p>{% trans "No corpus" %}</p>
+{% endif %}
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/telemeta/templates/search/mediafonds_listhaystack.html b/telemeta/templates/search/mediafonds_listhaystack.html
new file mode 100644 (file)
index 0000000..53bef27
--- /dev/null
@@ -0,0 +1,73 @@
+{% load telemeta_utils %}
+{% load i18n %}
+
+{% if page.object_list %}
+
+<table class="listing">
+<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>
+{% if user.is_authenticated %}
+    {% 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;"></span></center>
+          {% endif %}
+        </td>
+
+        <td>{{ result.object.description }}</td>
+        <td>
+            {{ result.object.code }}
+        </td>
+    </tr>
+    {% endfor %}
+{% 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;"></span></center>
+          {% endif %}
+        </td>
+
+        <td>{{ result.object.description }}</td>
+        <td>
+            {{ result.object.code }}
+        </td>
+    </tr>
+    {% endfor %}
+{% endif %}
+</table>
+{% else %}
+    <p>{% trans "No fonds" %}</p>
+{% endif %}
+
+
+
+
+
+
+
+
+
+
+
+
+