-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Import/Export functions #54
Conversation
can you please fix the ci errors. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. But I think we should add a unique key (maybe the version of the server and unique identifier for vocascan) in the export json to be able to check later when importing if this is really a vocab file.
This is a good idea. When we add the server version as a validation for imports, we can also check if some exportes json files are out of date when some structure will be changing in the future |
The version key and the type are now built in. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. We'll merge that PR when the corresponding PR (vocascan/vocascan-desktop#75) is approved.
Description
Serverside implementation of the import/export function, which allows to add and store vocabs from a package or group from/in a JSON file.
To do:
GET /api/languagePackage/:languagePackageIdexport?queryStatus=false
Response
GET /api/group/:groupId/export
Response
POST /api/import?active=true&activate=false&queryStatus=false (PACKAGE)
Body (without imported query status)
Body (with imported query status)
when drawerId is not specified the "activate" property will be used to store the vocab card
POST /api/import?languagePackageId&active&activate (GROUP)
Body
Motivation and Context
We wanted to have import and export functions to share vocabs among each other, or simply transfer them to another server, by exporting them with their current query status
Screenshots / GIFs (if appropriate):
Checklist
Resolves