尝试在 Python/Django 中构建与 Evernote API 连接的应用程序。对于下面的代码,我收到以下错误消息:“'Store' object has no attribute 'NoteFilter'”来自http://dev.evernote.com/documentation/reference/NoteStore.html#Svc_NoteStore可以看到,NoteFilter 是NoteStore 的属性。
def list(request):
nbname="mihkel's notebook"
client = EvernoteClient(token=token, sandbox=False)
note_store = client.get_note_store()
notebooks = note_store.listNotebooks()
for nb in notebooks:
if nbname == nb.name:
nb = nb
filter = note_store.NoteFilter()
filter.notebookGuid = nb.guid
notelist = note_store.findNotes(token,filter,0,10)
break
return render_to_response('list.html', {'nb': nb, 'notelist':notelist})