mirror of
https://github.com/ankitects/anki.git
synced 2025-09-18 14:02:21 -04:00
add pep8 name for findReplace
This commit is contained in:
parent
29379a9a50
commit
05ca797ee6
2 changed files with 5 additions and 2 deletions
|
@ -586,7 +586,7 @@ select id from notes where id in %s and id not in (select nid from cards)"""
|
||||||
self.flush_all_changes()
|
self.flush_all_changes()
|
||||||
return self.backend.search_notes(query)
|
return self.backend.search_notes(query)
|
||||||
|
|
||||||
def findReplace(
|
def find_and_replace(
|
||||||
self,
|
self,
|
||||||
nids: List[int],
|
nids: List[int],
|
||||||
src: str,
|
src: str,
|
||||||
|
@ -602,6 +602,7 @@ select id from notes where id in %s and id not in (select nid from cards)"""
|
||||||
|
|
||||||
findCards = find_cards
|
findCards = find_cards
|
||||||
findNotes = find_notes
|
findNotes = find_notes
|
||||||
|
findReplace = find_and_replace
|
||||||
|
|
||||||
# Config
|
# Config
|
||||||
##########################################################################
|
##########################################################################
|
||||||
|
|
|
@ -1967,7 +1967,9 @@ update cards set usn=?, mod=?, did=? where id in """
|
||||||
self.model.beginReset()
|
self.model.beginReset()
|
||||||
|
|
||||||
def do_search():
|
def do_search():
|
||||||
return self.col.findReplace(nids, search, replace, regex, field, nocase)
|
return self.col.find_and_replace(
|
||||||
|
nids, search, replace, regex, field, nocase
|
||||||
|
)
|
||||||
|
|
||||||
def on_done(fut):
|
def on_done(fut):
|
||||||
self.search()
|
self.search()
|
||||||
|
|
Loading…
Reference in a new issue