diff --git a/.gitignore b/.gitignore index eb398718..d757b816 100644 --- a/.gitignore +++ b/.gitignore @@ -29,6 +29,7 @@ cps/cache *.bak *.log.* .key +.venv settings.yaml gdrive_credentials diff --git a/cps/admin.py b/cps/admin.py index 022acc8e..91b2f7c8 100644 --- a/cps/admin.py +++ b/cps/admin.py @@ -1981,7 +1981,7 @@ def _handle_edit_user(to_save, content, languages, translations, kobo_support): return redirect(url_for('admin.admin')) val = [int(k[5:]) for k in to_save if k.startswith('show_')] - sidebar, __ = get_sidebar_config() + sidebar, __, __, __ = get_sidebar_config() for element in sidebar: value = element['visibility'] if value in val and not content.check_visibility(value): diff --git a/cps/static/css/caliBlur.css b/cps/static/css/caliBlur.css index cf743761..14dd3b8f 100644 --- a/cps/static/css/caliBlur.css +++ b/cps/static/css/caliBlur.css @@ -7944,3 +7944,27 @@ div.comments[data-readmore] { transition: height 300ms; overflow: hidden } + +div.col-sm-10 > h2.book_table, div.col-sm-10 > a.session { + padding-left: 40px; + padding-right: 10px; +} + +div.col-sm-10 > h2.book_table { + color: white; +} + +div.col-sm-10 > table.table { + margin-left: 40px; + width: calc(100% - 50px); +} + +div.col-sm-10 > div.custom_page { + padding-left: 40px; + padding-right: 10px; + color: white; +} + +div.col-sm-10 > div.custom_page > h2 { + color: white; +} \ No newline at end of file diff --git a/cps/templates/page.html b/cps/templates/page.html index 08629931..d8083bf0 100644 --- a/cps/templates/page.html +++ b/cps/templates/page.html @@ -1,4 +1,4 @@ {% extends "layout.html" %} {% block body %} -
{{body|safe}}
+
{{body|safe}}
{% endblock %} diff --git a/cps/templates/user_edit.html b/cps/templates/user_edit.html index 18b018e6..4afd3cd5 100644 --- a/cps/templates/user_edit.html +++ b/cps/templates/user_edit.html @@ -100,6 +100,10 @@ +
+ + +
diff --git a/cps/templates/user_table.html b/cps/templates/user_table.html index 3f998f95..baa6a08d 100644 --- a/cps/templates/user_table.html +++ b/cps/templates/user_table.html @@ -144,6 +144,7 @@ {{ user_checkbox_row("role", "passwd_role", _('Change Password'), visiblility, all_roles)}} {{ user_checkbox_row("role", "upload_role",_('Upload'), visiblility, all_roles)}} {{ user_checkbox_row("role", "download_role", _('Download'), visiblility, all_roles)}} + {{ user_checkbox_row("role", "send_to_ereader", _('Send to eReader'), visiblility, all_roles)}} {{ user_checkbox_row("role", "viewer_role", _('View'), visiblility, all_roles)}} {{ user_checkbox_row("role", "edit_role", _('Edit'), visiblility, all_roles)}} {{ user_checkbox_row("role", "delete_role", _('Delete'), visiblility, all_roles)}} diff --git a/cps/ub.py b/cps/ub.py index 1b002113..43382dbc 100644 --- a/cps/ub.py +++ b/cps/ub.py @@ -233,7 +233,7 @@ class User(UserBase, Base): id = Column(Integer, primary_key=True) name = Column(String(64), unique=True) email = Column(String(120), unique=True, default="") - role = Column(SmallInteger, default=constants.ROLE_USER) + role = Column(Integer, default=constants.ROLE_USER) password = Column(String) kindle_mail = Column(String(120), default="") shelf = relationship('Shelf', backref='user', lazy='dynamic', order_by='Shelf.name') @@ -745,7 +745,7 @@ def migrate_Database(_session): conn.execute(text("CREATE TABLE user_id (id INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT," "name VARCHAR(64)," "email VARCHAR(120)," - "role SMALLINT," + "role INTEGER," "password VARCHAR," "kindle_mail VARCHAR(120)," "locale VARCHAR(2),"