mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
String changes
This commit is contained in:
parent
b121e7d4f5
commit
b3b6272e49
@ -257,7 +257,7 @@ class ChooseLibrary(Dialog): # {{{
|
||||
|
||||
def browse(self):
|
||||
d = choose_dir(self, 'choose_library_for_copy',
|
||||
_('Choose Library'))
|
||||
_('Choose library'))
|
||||
if d:
|
||||
self.le.setText(d)
|
||||
|
||||
|
@ -758,14 +758,20 @@ class User(QWidget):
|
||||
username, user_data = self.username, self.user_data
|
||||
r = user_data[username]['restriction']
|
||||
if r['allowed_library_names']:
|
||||
m = _(
|
||||
'{} is currently only allowed to access the libraries named: {}'
|
||||
).format(username, ', '.join(r['allowed_library_names']))
|
||||
libs = r['allowed_library_names']
|
||||
m = ngettext(
|
||||
'{} is currently only allowed to access the library named: {}',
|
||||
'{} is currently only allowed to access the libraries named: {}',
|
||||
len(libs)
|
||||
).format(username, ', '.join(libs))
|
||||
b = _('Change the allowed libraries')
|
||||
elif r['blocked_library_names']:
|
||||
m = _(
|
||||
'{} is currently not allowed to access the libraries named: {}'
|
||||
).format(username, ', '.join(r['blocked_library_names']))
|
||||
libs = r['blocked_library_names']
|
||||
m = ngettext(
|
||||
'{} is currently not allowed to access the library named: {}',
|
||||
'{} is currently not allowed to access the libraries named: {}',
|
||||
len(libs)
|
||||
).format(username, ', '.join(libs))
|
||||
b = _('Change the blocked libraries')
|
||||
else:
|
||||
m = _('{} is currently allowed access to all libraries')
|
||||
|
@ -133,13 +133,19 @@ def manage_users_cli(path=None):
|
||||
if r is None:
|
||||
raise SystemExit('The user {} does not exist'.format(username))
|
||||
if r['allowed_library_names']:
|
||||
libs = r['allowed_library_names']
|
||||
prints(
|
||||
_('{} is currently only allowed to access the libraries named: {}')
|
||||
.format(username, ', '.join(r['allowed_library_names'])))
|
||||
ngettext(
|
||||
'{} is currently only allowed to access the library named: {}',
|
||||
'{} is currently only allowed to access the libraries named: {}',
|
||||
len(libs)).format(username, ', '.join(libs)))
|
||||
if r['blocked_library_names']:
|
||||
libs = r['blocked_library_names']
|
||||
prints(
|
||||
_('{} is currently not allowed to access the libraries named: {}')
|
||||
.format(username, ', '.join(r['blocked_library_names'])))
|
||||
ngettext(
|
||||
'{} is currently not allowed to access the library named: {}',
|
||||
'{} is currently not allowed to access the libraries named: {}',
|
||||
len(libs)).format(username, ', '.join(libs)))
|
||||
if r['library_restrictions']:
|
||||
prints(
|
||||
_('{} has the following additional per-library restrictions:')
|
||||
|
Loading…
x
Reference in New Issue
Block a user