mirror of
git://github.com/kovidgoyal/calibre.git
synced 2026-05-09 11:14:02 +02:00
calibredb: Allow setting fo title sort field
Fixes #1233711 [CalibreDB: title_sort is not a known field](https://bugs.launchpad.net/calibre/+bug/1233711)
This commit is contained in:
parent
0f5f38e746
commit
5ca115eab0
1 changed files with 3 additions and 0 deletions
|
|
@ -629,9 +629,12 @@ def verify_int(x):
|
|||
|
||||
if opts.field:
|
||||
fields = {k:v for k, v in fields()}
|
||||
fields['title_sort'] = fields['sort']
|
||||
vals = {}
|
||||
for x in opts.field:
|
||||
field, val = x.partition(':')[::2]
|
||||
if field == 'sort':
|
||||
field = 'title_sort'
|
||||
if field not in fields:
|
||||
print >>sys.stderr, _('%s is not a known field'%field)
|
||||
return 1
|
||||
|
|
|
|||
Loading…
Reference in a new issue