aboutsummaryrefslogtreecommitdiffstats
path: root/97suifangqa/templates/search
diff options
context:
space:
mode:
Diffstat (limited to '97suifangqa/templates/search')
-rw-r--r--97suifangqa/templates/search/indexes/indicator/indicator_text.txt6
-rw-r--r--97suifangqa/templates/search/indexes/indicator/indicatorcategory_text.txt5
-rw-r--r--97suifangqa/templates/search/indexes/info/query_text.txt2
-rw-r--r--97suifangqa/templates/search/indexes/sciblog/blogannotation_text.txt5
-rw-r--r--97suifangqa/templates/search/indexes/sciblog/sciblog_text.txt30
-rw-r--r--97suifangqa/templates/search/query/index.html19
-rw-r--r--97suifangqa/templates/search/search.html39
7 files changed, 106 insertions, 0 deletions
diff --git a/97suifangqa/templates/search/indexes/indicator/indicator_text.txt b/97suifangqa/templates/search/indexes/indicator/indicator_text.txt
new file mode 100644
index 0000000..4ccb33e
--- /dev/null
+++ b/97suifangqa/templates/search/indexes/indicator/indicator_text.txt
@@ -0,0 +1,6 @@
+{{ object.name }}
+{{ object.pinyin }}
+{{ object.englishName }}
+{{ object.description }}
+{{ object.helpText }}
+
diff --git a/97suifangqa/templates/search/indexes/indicator/indicatorcategory_text.txt b/97suifangqa/templates/search/indexes/indicator/indicatorcategory_text.txt
new file mode 100644
index 0000000..df4ffac
--- /dev/null
+++ b/97suifangqa/templates/search/indexes/indicator/indicatorcategory_text.txt
@@ -0,0 +1,5 @@
+{{ object.name }}
+{{ object.pinyin }}
+{{ object.englishName }}
+{{ object.description }}
+
diff --git a/97suifangqa/templates/search/indexes/info/query_text.txt b/97suifangqa/templates/search/indexes/info/query_text.txt
new file mode 100644
index 0000000..1451635
--- /dev/null
+++ b/97suifangqa/templates/search/indexes/info/query_text.txt
@@ -0,0 +1,2 @@
+{{ object.content }}
+{{ object.user.get_full_name }}
diff --git a/97suifangqa/templates/search/indexes/sciblog/blogannotation_text.txt b/97suifangqa/templates/search/indexes/sciblog/blogannotation_text.txt
new file mode 100644
index 0000000..a347fc0
--- /dev/null
+++ b/97suifangqa/templates/search/indexes/sciblog/blogannotation_text.txt
@@ -0,0 +1,5 @@
+{{ object.brief_content }}
+{{ object.detail }}
+{% for keyword in object.keywords.all %}
+{{ keyword.content }}
+{% endfor %}
diff --git a/97suifangqa/templates/search/indexes/sciblog/sciblog_text.txt b/97suifangqa/templates/search/indexes/sciblog/sciblog_text.txt
new file mode 100644
index 0000000..edc145c
--- /dev/null
+++ b/97suifangqa/templates/search/indexes/sciblog/sciblog_text.txt
@@ -0,0 +1,30 @@
+{{ object.title }}
+{{ object.subhead }}
+{{ object.journal }}
+{{ object.entitle }}
+{{ object.authors }}
+{{ object.method }}
+{{ object.aim }}
+{{ object.abstract_result }}
+{{ object.abstractAE }}
+{{ object.treatment_content }}
+{{ object.endpoint_content }}
+{% for endpoint in object.endpoint_content.all %}
+{{ endpoint.content }}
+{% endfor %}
+
+{% for que in object.query.all %}
+{{ que.content }}
+{% endfor %}
+
+{{ object.conclusion }}
+
+{% for piece in object.konwledge_piece.all %}
+{{ piece.content }}
+{% endfor %}
+
+{{ object.detectionAssay }}
+
+{% for result in object.results.all %}
+{{ result.content }}
+{% endfor %}
diff --git a/97suifangqa/templates/search/query/index.html b/97suifangqa/templates/search/query/index.html
new file mode 100644
index 0000000..7e504fc
--- /dev/null
+++ b/97suifangqa/templates/search/query/index.html
@@ -0,0 +1,19 @@
+{% extends "base.html" %}
+
+{% block otherlinks %}
+ <link rel="stylesheet" href="//fonts.googleapis.com/css?family=Open+Sans:400,600">
+{% endblock %}
+
+{% block bodyclass %}bg{% endblock %}
+
+{% block body %}
+ {% include "profile/person-info.html" %}
+ <div class="body">
+ <form method="post" class="search" action="/blog/query">
+ {% csrf_token %}
+ <input type="text" name="q" placeholder="乙肝甲肝各种肝炎" class="queinput">
+ <input type="submit" value="提问" class="quebtn">
+ </form>
+ <div class="site_logo"></div>
+ </div>
+{% endblock %}
diff --git a/97suifangqa/templates/search/search.html b/97suifangqa/templates/search/search.html
new file mode 100644
index 0000000..7308de0
--- /dev/null
+++ b/97suifangqa/templates/search/search.html
@@ -0,0 +1,39 @@
+{% extends 'base.html' %}
+
+{% block page %}
+ <h2>Search</h2>
+
+ <form method="get" action=".">
+ <table>
+ {{ form.as_table }}
+ <tr>
+ <td>&nbsp;</td>
+ <td>
+ <input type="submit" value="Search" />
+ </td>
+ </tr>
+ </table>
+
+ {% if query %}
+ <h3>Results</h3>
+
+ {% for result in page.object_list %}
+ <p>
+ <a href="{{ result.object.get_absolute_url }}">{{ result.object.show }}</a>
+ </p>
+ {% empty %}
+ <p>No results found.</p>
+ {% endfor %}
+
+ {% if page.has_previous or page.has_next %}
+ <div>
+ {% if page.has_previous %}<a href="?q={{ query }}&amp;page={{ page.previous_page_number }}">{% endif %}&laquo; Previous{% if page.has_previous %}</a>{% endif %}
+ |
+ {% if page.has_next %}<a href="?q={{ query }}&amp;page={{ page.next_page_number }}">{% endif %}Next &raquo;{% if page.has_next %}</a>{% endif %}
+ </div>
+ {% endif %}
+ {% else %}
+ {# Show some example queries to run, maybe query syntax, something else? #}
+ {% endif %}
+ </form>
+{% endblock %}