Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
D
douban-api-proxy
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
captainwong
douban-api-proxy
Commits
5b2c18e7
Commit
5b2c18e7
authored
Jul 31, 2017
by
Carlos Clavero
Committed by
GitHub
Jul 31, 2017
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #5 from janeczku/master
Update fork
parents
1a11e5d6
fe52de6b
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
41 additions
and
39 deletions
+41
-39
detail.html
cps/templates/detail.html
+7
-7
discover.html
cps/templates/discover.html
+1
-1
index.html
cps/templates/index.html
+6
-6
layout.html
cps/templates/layout.html
+23
-21
search.html
cps/templates/search.html
+1
-1
search_form.html
cps/templates/search_form.html
+3
-3
No files found.
cps/templates/detail.html
View file @
5b2c18e7
...
...
@@ -5,9 +5,9 @@
<div
class=
"col-sm-3 col-lg-3 col-xs-5"
>
<div
class=
"cover"
>
{% if entry.has_cover %}
<img
src=
"{{ url_for('get_cover', cover_path=entry.path.replace('\\','/')) }}"
/>
<img
src=
"{{ url_for('get_cover', cover_path=entry.path.replace('\\','/')) }}"
alt=
"{{ entry.title }}"
/>
{% else %}
<img
src=
"{{ url_for('static', filename='generic_cover.jpg') }}"
/>
<img
src=
"{{ url_for('static', filename='generic_cover.jpg') }}"
alt=
"{{ entry.title }}"
/>
{% endif %}
</div>
</div>
...
...
@@ -17,7 +17,7 @@
{% if g.user.role_download() %}
<div
class=
"btn-group"
role=
"group"
>
{% if entry.data|length
<
3
%}
<
button
id=
"btnGroupDrop1"
type=
"button"
class=
"btn btn-primary"
>
<
button
type=
"button"
class=
"btn btn-primary"
>
{{_('Download')}} :
</button>
{% for format in entry.data %}
...
...
@@ -44,11 +44,11 @@
{% endif %}
{% if (g.user.role_download() and g.user.is_anonymous()) or g.user.is_authenticated %}
<div
class=
"btn-group"
role=
"group"
>
<button
id=
"
btnGroupDrop2
"
type=
"button"
class=
"btn btn-primary dropdown-toggle"
data-toggle=
"dropdown"
aria-haspopup=
"true"
aria-expanded=
"false"
>
<button
id=
"
read-in-browser
"
type=
"button"
class=
"btn btn-primary dropdown-toggle"
data-toggle=
"dropdown"
aria-haspopup=
"true"
aria-expanded=
"false"
>
<span
class=
"glyphicon glyphicon-eye-open"
></span>
{{_('Read in browser')}}
<span
class=
"caret"
></span>
</button>
<ul
class=
"dropdown-menu"
aria-labelledby=
"
btnGroupDrop2
"
>
<ul
class=
"dropdown-menu"
aria-labelledby=
"
read-in-browser
"
>
{% for format in entry.data %}
{%if format.format|lower == 'epub' or format.format|lower == 'txt' or format.format|lower == 'pdf' or format.format|lower == 'cbr' or format.format|lower == 'cbt' or format.format|lower == 'cbz' %}
<li><a
target=
"_blank"
href=
"{{ url_for('read_book', book_id=entry.id, book_format=format.format|lower) }}"
>
{{format.format}}
</a></li>
...
...
@@ -184,11 +184,11 @@
{% if g.user.shelf.all() or g.public_shelfes %}
<div
id=
"shelf-actions"
class=
"btn-toolbar"
role=
"toolbar"
>
<div
class=
"btn-group"
role=
"group"
aria-label=
"Add to shelves"
>
<button
id=
"
btnGroupDrop2
"
type=
"button"
class=
"btn btn-primary btn-sm dropdown-toggle"
data-toggle=
"dropdown"
aria-haspopup=
"true"
aria-expanded=
"false"
>
<button
id=
"
add-to-shelf
"
type=
"button"
class=
"btn btn-primary btn-sm dropdown-toggle"
data-toggle=
"dropdown"
aria-haspopup=
"true"
aria-expanded=
"false"
>
<span
class=
"glyphicon glyphicon-list"
></span>
{{_('Add to shelf')}}
<span
class=
"caret"
></span>
</button>
<ul
id=
"add-to-shelves"
class=
"dropdown-menu"
aria-labelledby=
"
btnGroupDrop2
"
>
<ul
id=
"add-to-shelves"
class=
"dropdown-menu"
aria-labelledby=
"
add-to-shelf
"
>
{% for shelf in g.user.shelf %}
{% if not shelf.id in books_shelfs and shelf.is_public != 1 %}
<li>
...
...
cps/templates/discover.html
View file @
5b2c18e7
...
...
@@ -9,7 +9,7 @@
<div
class=
"cover"
>
{% if entry.has_cover is defined %}
<a
href=
"{{ url_for('show_book', book_id=entry.id) }}"
data-toggle=
"modal"
data-target=
"#bookDetailsModal"
data-remote=
"false"
>
<img
src=
"{{ url_for('get_cover', cover_path=entry.path.replace('\\','/')) }}"
/>
<img
src=
"{{ url_for('get_cover', cover_path=entry.path.replace('\\','/')) }}"
alt=
"{{ entry.title }}"
/>
</a>
{% endif %}
</div>
...
...
cps/templates/index.html
View file @
5b2c18e7
...
...
@@ -6,13 +6,13 @@
<div
class=
"row"
>
{% for entry in random %}
<div
id=
"books_rand"
class=
"col-sm-3 col-lg-2 col-xs-6 book"
>
<div
class=
"col-sm-3 col-lg-2 col-xs-6 book"
>
<div
class=
"cover"
>
<a
href=
"{{ url_for('show_book', book_id=entry.id) }}"
data-toggle=
"modal"
data-target=
"#bookDetailsModal"
data-remote=
"false"
>
{% if entry.has_cover %}
<img
src=
"{{ url_for('get_cover', cover_path=entry.path.replace('\\','/')) }}"
/>
<img
src=
"{{ url_for('get_cover', cover_path=entry.path.replace('\\','/')) }}"
alt=
"{{ entry.title }}"
/>
{% else %}
<img
src=
"{{ url_for('static', filename='generic_cover.jpg') }}"
/>
<img
src=
"{{ url_for('static', filename='generic_cover.jpg') }}"
alt=
"{{ entry.title }}"
/>
{% endif %}
</a>
</div>
...
...
@@ -42,13 +42,13 @@
<div
class=
"row"
>
{% if entries[0] %}
{% for entry in entries %}
<div
id=
"books"
class=
"col-sm-3 col-lg-2 col-xs-6 book"
>
<div
class=
"col-sm-3 col-lg-2 col-xs-6 book"
>
<div
class=
"cover"
>
<a
href=
"{{ url_for('show_book', book_id=entry.id) }}"
data-toggle=
"modal"
data-target=
"#bookDetailsModal"
data-remote=
"false"
>
{% if entry.has_cover %}
<img
src=
"{{ url_for('get_cover', cover_path=entry.path.replace('\\','/')) }}"
/>
<img
src=
"{{ url_for('get_cover', cover_path=entry.path.replace('\\','/')) }}"
alt=
"{{ entry.title }}"
/>
{% else %}
<img
src=
"{{ url_for('static', filename='generic_cover.jpg') }}"
/>
<img
src=
"{{ url_for('static', filename='generic_cover.jpg') }}"
alt=
"{{ entry.title }}"
/>
{% endif %}
</a>
</div>
...
...
cps/templates/layout.html
View file @
5b2c18e7
<!DOCTYPE html>
<html>
<html
lang=
"{{ g.user.locale }}"
>
<head>
<title>
{{instance}} | {{title}}
</title>
<meta
charset=
"utf-8"
>
...
...
@@ -19,28 +19,9 @@
<script src="https://oss.maxcdn.com/libs/respond.js/1.3.0/respond.min.js"></script>
<![endif]-->
<!-- jQuery (necessary for Bootstrap's JavaScript plugins) -->
<!--script src="https://code.jquery.com/jquery.js"></script-->
<script
src=
"{{ url_for('static', filename='js/libs/jquery.min.js') }}"
></script>
<!-- Include all compiled plugins (below), or include individual files as needed -->
<script
src=
"{{ url_for('static', filename='js/libs/bootstrap.min.js') }}"
></script>
<script
src=
"{{ url_for('static', filename='js/libs/underscore-min.js') }}"
></script>
<script
src=
"{{ url_for('static', filename='js/libs/intention.min.js') }}"
></script>
<script
src=
"{{ url_for('static', filename='js/libs/context.min.js') }}"
></script>
<script
src=
"{{ url_for('static', filename='js/libs/plugins.js') }}"
></script>
<script
src=
"{{ url_for('static', filename='js/libs/jquery.form.js') }}"
></script>
<script
src=
"{{ url_for('static', filename='js/main.js') }}"
></script>
{% block header %}{% endblock %}
</head>
<body>
<script>
$
(
document
).
ready
(
function
(){
$
(
"#btn-upload"
).
change
(
function
()
{
$
(
"#form-upload"
).
submit
();
});
});
</script>
<!-- Static navbar -->
<div
class=
"navbar navbar-default navbar-static-top"
role=
"navigation"
>
<div
class=
"container-fluid"
>
...
...
@@ -56,7 +37,8 @@
{% if g.user.is_authenticated or g.user.is_anonymous() %}
<form
class=
"navbar-form navbar-left"
role=
"search"
action=
"{{url_for('search')}}"
method=
"GET"
>
<div
class=
"form-group input-group input-group-sm"
>
<input
type=
"text"
class=
"form-control"
name=
"query"
placeholder=
"{{_('Search')}}"
>
<label
for=
"query"
class=
"sr-only"
>
{{_('Search')}}
</label>
<input
type=
"text"
class=
"form-control"
id=
"query"
name=
"query"
placeholder=
"{{_('Search')}}"
>
<span
class=
"input-group-btn"
>
<button
type=
"submit"
class=
"btn btn-default"
>
{{_('Go!')}}
</button>
</span>
...
...
@@ -220,6 +202,26 @@
</div>
</div>
{% block modal %}{% endblock %}
<!-- jQuery (necessary for Bootstrap's JavaScript plugins) -->
<!--script src="https://code.jquery.com/jquery.js"></script-->
<script
src=
"{{ url_for('static', filename='js/libs/jquery.min.js') }}"
></script>
<!-- Include all compiled plugins (below), or include individual files as needed -->
<script
src=
"{{ url_for('static', filename='js/libs/bootstrap.min.js') }}"
></script>
<script
src=
"{{ url_for('static', filename='js/libs/underscore-min.js') }}"
></script>
<script
src=
"{{ url_for('static', filename='js/libs/intention.min.js') }}"
></script>
<script
src=
"{{ url_for('static', filename='js/libs/context.min.js') }}"
></script>
<script
src=
"{{ url_for('static', filename='js/libs/plugins.js') }}"
></script>
<script
src=
"{{ url_for('static', filename='js/libs/jquery.form.js') }}"
></script>
<script
src=
"{{ url_for('static', filename='js/main.js') }}"
></script>
<script
type=
"text/javascript"
>
$
(
function
()
{
$
(
"#btn-upload"
).
change
(
function
()
{
$
(
"#form-upload"
).
submit
();
});
});
</script>
{% block js %}{% endblock %}
</body>
</html>
cps/templates/search.html
View file @
5b2c18e7
...
...
@@ -16,7 +16,7 @@
<div
class=
"cover"
>
{% if entry.has_cover is defined %}
<a
href=
"{{ url_for('show_book', book_id=entry.id) }}"
data-toggle=
"modal"
data-target=
"#bookDetailsModal"
data-remote=
"false"
>
<img
src=
"{{ url_for('get_cover', cover_path=entry.path.replace('\\','/')) }}"
/>
<img
src=
"{{ url_for('get_cover', cover_path=entry.path.replace('\\','/')) }}"
alt=
"{{ entry.title }}"
/>
</a>
{% endif %}
</div>
...
...
cps/templates/search_form.html
View file @
5b2c18e7
...
...
@@ -28,7 +28,7 @@
<div
class=
"form-group"
>
<div
class=
"btn-toolbar btn-toolbar-lg"
data-toggle=
"buttons"
>
{% for tag in tags %}
<label
id=
"tag_{{tag.id}}"
class=
"btn btn-danger tags_click"
>
<label
id=
"
exclude_
tag_{{tag.id}}"
class=
"btn btn-danger tags_click"
>
<input
type=
"checkbox"
autocomplete=
"off"
name=
"exclude_tag"
id=
"exclude_tag"
value=
"{{tag.id}}"
>
{{tag.name}}
</input>
</label>
{% endfor %}
...
...
@@ -48,7 +48,7 @@
<div
class=
"form-group"
>
<div
class=
"btn-toolbar btn-toolbar-lg"
data-toggle=
"buttons"
>
{% for serie in series %}
<label
id=
"serie_{{serie.id}}"
class=
"btn btn-danger serie_click"
>
<label
id=
"
exclude_
serie_{{serie.id}}"
class=
"btn btn-danger serie_click"
>
<input
type=
"checkbox"
autocomplete=
"off"
name=
"exclude_serie"
id=
"exclude_serie"
value=
"{{serie.id}}"
>
{{serie.name}}
</input>
</label>
{% endfor %}
...
...
@@ -69,7 +69,7 @@
<div
class=
"form-group"
>
<div
class=
"btn-toolbar btn-toolbar-lg"
data-toggle=
"buttons"
>
{% for language in languages %}
<label
id=
"language_{{language.id}}"
class=
"btn btn-danger language_click"
>
<label
id=
"
exclude_
language_{{language.id}}"
class=
"btn btn-danger language_click"
>
<input
type=
"checkbox"
autocomplete=
"off"
name=
"exclude_language"
id=
"exclude_language"
value=
"{{language.id}}"
>
{{language.name}}
</input>
</label>
{% endfor %}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment