Commit Graph

169 Commits

Author SHA1 Message Date
abdo
2081330c35
Compare field names in a case-insensitive manner (#242) 2021-03-13 16:10:58 -08:00
9a18ae0b11 Better compat with old versions of Anki 2021-03-06 21:16:19 -08:00
Quentin Harscoët
27a8678f88
added getNumCardsReviewedByDay action (#239)
* added getNumCardsReviewedByDay action

* added sample in statistics.md

* fix bad quotes and add basic test
2021-03-06 09:58:40 -08:00
Kirill Salnikov
b8a7151ed0
Fix handling of errors in several methods (#238)
* Fix error message in updateNoteFields method

* Fix error handling in cardsInfo, notesInfo methods

* Add more tests for updateNoteFields, notesInfo

* Fix error handling in several methods

Also fixed obvious bugs in replaceTags and replaceTagsInAllNotes
methods.

* Add more tests for cards methods

* Add more tests for notes methods

* Update documentation on cards methods
2021-03-04 20:06:25 -08:00
Tsung-Po Sun(Munehiro)
a4d723de3e
Add "forgetCards" and "relearnCards" (#234)
* Add "forgetCards" and "relearnCards"

* Add unit tests

Co-authored-by: Tsung-Po Sun <tsungpo.sun@smartnews.com>
2021-03-04 20:02:57 -08:00
Venkata Ramana
131a1c7cfc
Added findAndReplaceInModels (#228)
* added findAndReplaceInModels api call

* added documentation for findAndReplaceInModels

* added findAndReplaceInModels api call

* updatd findAndReplaceInModels function

* added unit test for findAndReplaceInModels in models

* updated findAndReplaceInModels

* added unit test for findAndReplaceInModels

* removed 'all_models' in findAndReplaceInModels
2021-02-26 21:17:51 -08:00
ripose-jp
aaf6b3a55b
Fixed bug where hash was calculated using the wrong variable (#235) 2021-02-26 21:16:39 -08:00
421ca35c09 Fix missing return 2021-02-22 19:25:12 -08:00
Alexander Ryzhikov
8b81267b0c
Add Access-Control-Allow-Headers * (#231) 2021-02-21 11:24:08 -08:00
David Sauerwein
7ef10e92da
Allow to add media to notes by file path or base64 encoded data (#230)
* Allow to add media to notes by file path or base64 encoded data

* Adjust Media Actions documentation

* Adjust Note Actions documentation
2021-02-20 10:04:25 -08:00
Kirill Salnikov
4d2ab991c2
Fix bug in loadProfile method (#229)
Bug: if sync is enabled for profile, then we have alot of recursive
calls to loadProfile method because main window is still active until
sync is ended. And this freezes Anki app.
2021-02-07 17:40:44 -08:00
6487abe206 Fix typo 2021-01-19 21:59:45 -08:00
a8273d0e38 Fix tests 2021-01-18 21:03:27 -08:00
322984be06 Cleanup 2021-01-18 20:18:57 -08:00
a575388392 Update quotes 2021-01-17 22:27:20 -08:00
c0cdc8e575 Update copyrights 2021-01-17 22:15:48 -08:00
431ee362fc Initial cleanup pass 2021-01-17 22:13:27 -08:00
Venkata Ramana
c55281d67a
added removeEmptyNotes (#221)
* clearUnusedTags and replaceTags are added

* added clearUnusedTags and replaceTags

* added clearUnusedTags and replaceTags

* removed whitespaces and indentations

* removed white spaces and indentations

* added removeEmptyNotes
2021-01-04 18:01:56 -08:00
Venkata Ramana
311cb7e192
replaceTags and clearUnusedTags are added (#219)
* clearUnusedTags and replaceTags are added

* added clearUnusedTags and replaceTags

* added clearUnusedTags and replaceTags

* removed whitespaces and indentations

* removed white spaces and indentations
2021-01-02 09:05:35 -08:00
kanjieater
5386364c8d
Server no longer hangs on client disconnects (#217)
* Server no longer hangs on client disconnects

* Changed timeout and am now catching errors explicitly

Co-authored-by: KanjiEater <kanjieat3r@gmail.com>
2020-12-28 13:57:22 -08:00
Ren Tatsumoto
9bbaf79575
Fixes 08f0d0c (#215) 2020-12-12 08:41:01 -08:00
Ling Wang
08f0d0cb7e
Add file parameter to storeMediaFile (#208) 2020-12-07 18:50:37 -08:00
grepmew
06dff21107
Add support for video and pictures when adding or updating a note. (#207)
- Sound and video share same [sound:..] tag. See 0c08ff5317/pylib/anki/sound.py (L33)
- Tested and verified picture is added and video is added when `addNote` API.
2020-12-05 21:24:50 -08:00
toasted-nutbread
b03414a8d3
Don't call note.dupeOrEmpty when mode is 'deck' (#204)
* Don't call note.dupeOrEmpty when mode is 'deck'

* Update return type to be consistent with latest note.duplicateOrEmpty

* Fix main deck ID not always being included
2020-12-05 21:23:03 -08:00
toasted-nutbread
ab1f518474
Duplicate scope options (#203)
* Add additional options to addNote's duplicateScope option

* Update documentation
2020-11-01 16:14:30 -08:00
Julian Müller
ce0cc7dce3
some additional actions (#185)
* implement needed actions

* add documentation and tests for cardInfo, updateCompleteDeck, reloadCollection, cardReviews, getLatestReviewID, insertReviews

Co-authored-by: Julian Müller <julian.mueller@stud-mail.uni-wuerzburg.de>
2020-07-12 12:53:31 -07:00
Spencer Sharp
84586cb352
Created getEaseFactors and setEaseFactors for Cards, along with documentation and tests for the functions (#181)
Co-authored-by: sherpa <spencersharp1999@gmail.com>
2020-06-10 16:21:58 -07:00
CRIMX
5438b19ba1
Remove localization for field names (#178)
Remove localization for field names as it creates agnostic output.
2020-06-02 20:27:33 -07:00
Ivan Volnov
aa38f68b5e
Fix for #174 (#175)
Co-authored-by: ivan-volnov <ivan-volnov@users.noreply.github.com>
2020-05-18 08:49:17 -07:00
Scott Noyes
80d830caed
Do not strip() during dupe check (#171) 2020-05-08 17:16:05 -07:00
Scott Noyes
2ca35712f3
collection stats - whole collection (#169)
* Add endpoint to retrieve collection stats report

* Create separate test for statistics

* Add test for collectionStats

* Fixed typo

* Change endpoint name to use a verb

* Change name to getCollectionStatsHTML

* Allow stats for whole collection

* Allow stats for whole collection
2020-05-07 18:49:48 -07:00
Scott Noyes
faba701251
Collection stats (#166)
* Add endpoint to retrieve collection stats report

* Create separate test for statistics

* Add test for collectionStats

* Fixed typo

* Change endpoint name to use a verb

* Change name to getCollectionStatsHTML
2020-05-03 12:06:43 -07:00
Alex Yatskov
457e76e720
Merge pull request #163 from snoyes/makeTagsOptional
Make tags optional when adding notes
2020-05-02 16:17:50 -07:00
Scott Noyes
0f9408730f Make tags optional when adding notes 2020-05-02 16:18:31 -05:00
Alex Yatskov
a779fa673f
Merge pull request #159 from snoyes/getProfiles
Add getProfiles action
2020-05-01 12:44:25 -07:00
Scott Noyes
32bf6559ed Add importPackage action 2020-05-01 11:19:47 -05:00
Scott Noyes
fdae44f1d3 Add getProfiles action 2020-05-01 09:24:51 -05:00
e01544a538 Update find actions for 2.1.24; fixes #145 2020-04-30 16:20:55 -07:00
toasted-nutbread
bda22a20a3 Add duplicateScope option for addNote 2020-04-23 19:39:11 -04:00
0f8b402d73 Update move export to misc, fix return 2020-04-21 18:22:10 -07:00
yakrider
f280a2b8f9 add api to get number of cards reviewed in the current day
partly addresses issue raised in #117
2020-04-19 01:38:03 -04:00
yekingyan
e0e0e57321 Add support for use '*' to allow CORS for all domains 2020-04-12 15:52:52 +08:00
Conor O'Kelly
22a58bb707
Use new hook for delete
In reference to issue #146 

Also added the `deleteMediaFile` when dealing with urls. 

The new functionality of `writeData` means that is there is a name conflict it will rename the file. This way the behavior of your api does not change.

Only potential issues I see with this is that the file is `trashed` but not deleted. So is only cleared up on the usual clear up.

Test locally using my own Anki install at `2.1.22` and POST man to create new media
2020-04-07 21:18:48 -07:00
Albert
da837b2d47 Complete 975c069 fixes 2020-04-05 01:28:37 +08:00
Markus Reil
9ba5c08c96
Support apkg export (#143)
Support apkg export
2020-03-16 22:29:49 -07:00
Alex Yatskov
955b749aac
Merge pull request #141 from mauamy/add-card-name-option-in-model-template
Add card name option in model template
2020-03-13 17:31:23 -07:00
Yannick Mau
5911710163 Add url download option to storeMediaFile 2020-03-14 00:36:17 +01:00
Yannick Mau
9b1fb83740 Add card name option to model template 2020-03-13 23:40:27 +01:00
dc8494f0fe Fix audio 2020-03-05 19:45:13 -08:00
c64e78addf cleanup 2020-03-05 19:33:27 -08:00
975c0699b7 Fixes for old version of Anki, cleanup script 2020-03-05 19:29:49 -08:00
Alex Yatskov
385ff2a43e
Merge pull request #136 from mauamy/add-multiple-cors-orgins-support
Add support for multiple cors origins
2020-03-01 16:53:30 -08:00
Alex Yatskov
7b6e80cd34
Merge pull request #138 from andreaskienle/multiple-audio-files
Accept multiple audio files in note creation and update
2020-03-01 16:52:24 -08:00
Yannick Mau
002b7cbf97 Deprecate field 'webCorsOrigin' but keep temporary support for it. 2020-02-28 01:17:53 +01:00
Andreas Kienle
d40a905f20 changes from review
single quotes
updated readme
2020-02-25 11:22:34 +01:00
Alex Yatskov
671444e1da
Merge pull request #134 from qwhex/fix_getQA
Replace Card._getQA() with the new answer() and question()
2020-02-23 11:28:19 -08:00
Andreas Kienle
eafd3c94dd Accept multiple audio files in note creation and update 2020-02-23 11:59:19 +01:00
Henrik Giesel
1824cd8c1c Fix return value of guiAddCards
* For the case where the current AddCards dialogue has to be closed first
2020-02-18 14:45:47 +01:00
Yannick Mau
413b27a21e Add support for multiple cors origins 2020-02-17 17:44:58 +01:00
Henrik Giesel
db602ebe9a Add return values 2020-02-17 13:57:16 +01:00
Mice Pápai
59c84b91db replace Card._getQA() with the new .answer() and .question() 2020-02-16 20:19:48 +01:00
toasted-nutbread
7ccfa7938e Ignore duplicates which are not in the target deck 2020-02-02 16:45:05 -05:00
7603f2b251 Fix error viewing AnkiConnect page 2020-01-05 17:49:41 -08:00
2767d2928e Add link script, fix plugin 2020-01-05 17:41:34 -08:00
4ec3a1ff61 Remove uncommon settings 2020-01-05 16:46:36 -08:00
98566ca8ba Cleanup 2020-01-05 16:24:20 -08:00
173e43700b Cleanup 2020-01-05 15:42:08 -08:00
6118d01de1 Remove support for Anki 2.0 and Python 2 2020-01-05 11:42:59 -08:00
bb62a1e93f Move plugin to its own directory 2020-01-05 11:35:02 -08:00