mirror of
https://github.com/ankitects/anki.git
synced 2025-09-24 08:46:37 -04:00
show the original deck too when a card is in a cram deck
This commit is contained in:
parent
b8ae9f06a8
commit
d79ca13dd7
1 changed files with 7 additions and 1 deletions
|
@ -227,6 +227,12 @@ class DataModel(QAbstractTableModel):
|
||||||
return _("(new)")
|
return _("(new)")
|
||||||
return "%d%%" % (c.factor/10)
|
return "%d%%" % (c.factor/10)
|
||||||
elif type == "deck":
|
elif type == "deck":
|
||||||
|
if c.odid:
|
||||||
|
# in a cram deck
|
||||||
|
return "%s (%s)" % (
|
||||||
|
self.browser.mw.col.decks.name(c.did),
|
||||||
|
self.browser.mw.col.decks.name(c.odid))
|
||||||
|
# normal deck
|
||||||
return self.browser.mw.col.decks.name(c.did)
|
return self.browser.mw.col.decks.name(c.did)
|
||||||
|
|
||||||
def question(self, c):
|
def question(self, c):
|
||||||
|
@ -518,7 +524,7 @@ class Browser(QMainWindow):
|
||||||
|
|
||||||
def onSortChanged(self, idx, ord):
|
def onSortChanged(self, idx, ord):
|
||||||
type = self.model.activeCols[idx]
|
type = self.model.activeCols[idx]
|
||||||
noSort = ("question", "answer", "template", "deck", "ndeck")
|
noSort = ("question", "answer", "template", "deck")
|
||||||
if type in noSort:
|
if type in noSort:
|
||||||
showInfo(_("Sorting on this column is not supported. Please "
|
showInfo(_("Sorting on this column is not supported. Please "
|
||||||
"choose another."))
|
"choose another."))
|
||||||
|
|
Loading…
Reference in a new issue