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
2bd4eff5
Commit
2bd4eff5
authored
Jul 21, 2019
by
Ozzieisaacs
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'pwr/config_sql' into Develop
parents
929f3233
847dbfc0
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
3 additions
and
10 deletions
+3
-10
__init__.py
cps/__init__.py
+1
-3
constants.py
cps/constants.py
+0
-1
db.py
cps/db.py
+1
-2
editbooks.py
cps/editbooks.py
+1
-2
helper.py
cps/helper.py
+0
-1
worker.py
cps/worker.py
+0
-1
No files found.
cps/__init__.py
View file @
2bd4eff5
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# This file is part of the Calibre-Web (https://github.com/janeczku/calibre-web)
...
...
@@ -134,8 +133,7 @@ def get_locale():
@
babel
.
timezoneselector
def
get_timezone
():
user
=
getattr
(
g
,
'user'
,
None
)
if
user
is
not
None
:
return
user
.
timezone
return
user
.
timezone
if
user
else
None
from
.updater
import
Updater
updater_thread
=
Updater
()
...
...
cps/constants.py
View file @
2bd4eff5
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# This file is part of the Calibre-Web (https://github.com/janeczku/calibre-web)
...
...
cps/db.py
View file @
2bd4eff5
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# This file is part of the Calibre-Web (https://github.com/janeczku/calibre-web)
...
...
@@ -418,7 +417,7 @@ def dispose():
for
attr
in
list
(
Books
.
__dict__
.
keys
()):
if
attr
.
startswith
(
"custom_column_"
):
delattr
(
Books
,
attr
)
setattr
(
Books
,
attr
,
None
)
for
db_class
in
cc_classes
.
values
():
Base
.
metadata
.
remove
(
db_class
.
__table__
)
...
...
cps/editbooks.py
View file @
2bd4eff5
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# This file is part of the Calibre-Web (https://github.com/janeczku/calibre-web)
...
...
@@ -301,7 +300,7 @@ def edit_cc_data(book_id, book, to_save):
# remove old cc_val
del_cc
=
getattr
(
book
,
cc_string
)[
0
]
getattr
(
book
,
cc_string
)
.
remove
(
del_cc
)
if
len
(
del_cc
.
books
)
==
0
:
if
not
del_cc
.
books
or
len
(
del_cc
.
books
)
==
0
:
db
.
session
.
delete
(
del_cc
)
else
:
input_tags
=
to_save
[
cc_string
]
.
split
(
','
)
...
...
cps/helper.py
View file @
2bd4eff5
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# This file is part of the Calibre-Web (https://github.com/janeczku/calibre-web)
...
...
cps/worker.py
View file @
2bd4eff5
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# This file is part of the Calibre-Web (https://github.com/janeczku/calibre-web)
...
...
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