diff --git a/cps/helper.py b/cps/helper.py index f9251147..beee00c7 100755 --- a/cps/helper.py +++ b/cps/helper.py @@ -222,14 +222,14 @@ def get_valid_filename(value, replace_whitespace=True): if use_unidecode: value=(unidecode.unidecode(value)).strip() else: - value=value.replace('§','SS') - value=value.replace('ß','ss') + value=value.replace(u'§',u'SS') + value=value.replace(u'ß',u'ss') value = unicodedata.normalize('NFKD', value) re_slugify = re.compile('[\W\s-]', re.UNICODE) value = unicode(re_slugify.sub('', value).strip()) if replace_whitespace: #*+:\"/<>? werden durch _ ersetzt - value = re.sub('[\*\+:\\\"/<>\?]+', '_', value, flags=re.U) + value = re.sub('[\*\+:\\\"/<>\?]+', u'_', value, flags=re.U) value = value[:128] return value @@ -263,7 +263,7 @@ def update_dir_stucture(book_id, calibrepath): if authordir != new_authordir: new_author_path = os.path.join(os.path.join(calibrepath, new_authordir), os.path.basename(path)) - os.rename(path, new_author_path) + os.renames(path, new_author_path) book.path = new_authordir + '/' + book.path.split('/')[1] db.session.commit() diff --git a/cps/static/css/style.css b/cps/static/css/style.css index 071980b3..5e6ea314 100644 --- a/cps/static/css/style.css +++ b/cps/static/css/style.css @@ -36,6 +36,8 @@ span.glyphicon.glyphicon-tags {padding-right: 5px;color: #999;vertical-align: te -moz-box-shadow: 0 5px 8px -6px #777; box-shadow: 0 5px 8px -6px #777; } +.navbar-default .navbar-toggle .icon-bar {background-color: #000;} +.navbar-default .navbar-toggle {border-color: #000;} .btn-file {position: relative; overflow: hidden;} .btn-file input[type=file] {position: absolute; top: 0; right: 0; min-width: 100%; min-height: 100%; font-size: 100px; text-align: right; filter: alpha(opacity=0); opacity: 0; outline: none; background: white; cursor: inherit; display: block;} diff --git a/cps/templates/layout.html b/cps/templates/layout.html index 7e63b93b..71bd7941 100644 --- a/cps/templates/layout.html +++ b/cps/templates/layout.html @@ -52,17 +52,19 @@ Calibre Web + {% if g.user.is_authenticated or g.user.is_anonymous() %} + + {% endif %}