diff --git a/.gitignore b/.gitignore index 7230489b4556..4ec39805fc83 100644 --- a/.gitignore +++ b/.gitignore @@ -12,6 +12,7 @@ mealie/temp/api.html mealie/data/backups/* mealie/data/debug/* mealie/data/img/* +mealie/data/migration/* !mealie/dist/* #Exception to keep folders @@ -19,6 +20,7 @@ mealie/data/img/* !mealie/data/backups/.gitkeep !mealie/data/backups/dev_sample_data* !mealie/data/debug/.gitkeep +!mealie/data/migration/.gitkeep !mealie/data/img/.gitkeep .DS_Store diff --git a/.vscode/settings.json b/.vscode/settings.json index 9c2025d7034e..0445b096ab37 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -11,6 +11,7 @@ "python.discoverTest": true, "python.testing.pytestEnabled": true, "cSpell.enableFiletypes": [ + "!javascript", "!python" ], "python.testing.pytestArgs": [ diff --git a/dev/non-working-links.txt b/dev/non-working-links.txt new file mode 100644 index 000000000000..7de14cfcb732 --- /dev/null +++ b/dev/non-working-links.txt @@ -0,0 +1 @@ +http://www.cookingforkeeps.com/2013/02/05/blue-cheese-stuffed-turkey-meatballs-with-raspberry-balsamic-glaze-2/ \ No newline at end of file diff --git a/docs/docs/api/api-usage.md b/docs/docs/api/api-usage.md index 911e11347462..95f288f97bac 100644 --- a/docs/docs/api/api-usage.md +++ b/docs/docs/api/api-usage.md @@ -6,7 +6,7 @@ Recipes extras are a key feature of the Mealie API. They allow you to create cus For example you could add `{"message": "Remember to thaw the chicken"}` to a recipe and use the webhooks built into mealie to send that message payload to a destination to be processed. -![api-extras-gif](/gifs/api-extras.gif) +![api-extras-gif](../gifs/api-extras.gif) ## Examples diff --git a/docs/docs/changelog.md b/docs/docs/changelog.md index 61e4afb60c4d..267eae44a3bf 100644 --- a/docs/docs/changelog.md +++ b/docs/docs/changelog.md @@ -6,8 +6,8 @@ A quality update with major props to [zackbcom](https://github.com/zackbcom) for - Fixed empty backup failure without markdown template - Fixed opacity issues with marked steps - [mtoohey31](https://github.com/mtoohey31) - Fixed hot-reloading development environment - [grssmnn](https://github.com/grssmnn) - - Fixed recipe not saving without image - - Fixed parsing error on image property null + - Fixed recipe not saving without image - Issue #7 + Issue #54 + - Fixed parsing error on image property null - Issue #43 ### General Improvements - Added Confirmation component to deleting recipes - [zackbcom](https://github.com/zackbcom) @@ -20,7 +20,7 @@ A quality update with major props to [zackbcom](https://github.com/zackbcom) for - Users can now add custom json key/value pairs to all recipes via the editor for access in 3rd part applications. For example users can add a "message" field in the extras that can be accessed on API calls to play a message over google home. - Improved image rendering (nearly x2 speed) - Improved documentation + API Documentation - - Improved recipe parsing + - Improved recipe parsing - Issue #51 - User feedback on backup importing ## v0.0.1 - Pre-release Patch diff --git a/frontend/src/api/migration.js b/frontend/src/api/migration.js index 7b8ba1610803..398aa9547ce6 100644 --- a/frontend/src/api/migration.js +++ b/frontend/src/api/migration.js @@ -5,7 +5,12 @@ import { store } from "../store/store"; const migrationBase = baseURL + "migration/"; const migrationURLs = { + upload: migrationBase + "upload/", + delete: (file) => `${migrationBase}${file}/delete/`, chowdownURL: migrationBase + "chowdown/repo/", + nextcloudAvaiable: migrationBase + "nextcloud/available/", + nextcloudImport: (selection) => + `${migrationBase}nextcloud/${selection}/import/`, }; export default { @@ -15,4 +20,24 @@ export default { store.dispatch("requestRecentRecipes"); return response.data; }, + async getNextcloudImports() { + let response = await apiReq.get(migrationURLs.nextcloudAvaiable); + return response.data; + }, + async importNextcloud(selected) { + let response = await apiReq.post(migrationURLs.nextcloudImport(selected)); + return response.data; + }, + async uploadFile(form_data) { + let response = await apiReq.post(migrationURLs.upload, form_data, { + headers: { + "Content-Type": "multipart/form-data", + }, + }); + return response.data; + }, + async delete(file_folder_name) { + let response = await apiReq.delete(migrationURLs.delete(file_folder_name)); + return response.data; + }, }; diff --git a/frontend/src/components/Settings/Migration/ChowdownCard.vue b/frontend/src/components/Settings/Migration/ChowdownCard.vue new file mode 100644 index 000000000000..716b398d06ae --- /dev/null +++ b/frontend/src/components/Settings/Migration/ChowdownCard.vue @@ -0,0 +1,73 @@ + + + + + \ No newline at end of file diff --git a/frontend/src/components/Settings/Migration/NextcloudCard.vue b/frontend/src/components/Settings/Migration/NextcloudCard.vue new file mode 100644 index 000000000000..ede045c09bca --- /dev/null +++ b/frontend/src/components/Settings/Migration/NextcloudCard.vue @@ -0,0 +1,103 @@ + + + + + \ No newline at end of file diff --git a/frontend/src/components/Settings/Migration/UploadMigrationButton.vue b/frontend/src/components/Settings/Migration/UploadMigrationButton.vue new file mode 100644 index 000000000000..5b8193a13ba4 --- /dev/null +++ b/frontend/src/components/Settings/Migration/UploadMigrationButton.vue @@ -0,0 +1,49 @@ + + + + + \ No newline at end of file diff --git a/frontend/src/components/Settings/Migration/index.vue b/frontend/src/components/Settings/Migration/index.vue index 19fa41653614..1100bd4cfdae 100644 --- a/frontend/src/components/Settings/Migration/index.vue +++ b/frontend/src/components/Settings/Migration/index.vue @@ -2,64 +2,42 @@ Recipe Migration - -

- Currently Chowdown via public Repo URL is the only supported type of - migration -

- - - - - - - - Migrate - - - - -

Failed Recipes

- - - {{ fail }} - - -
- -

Failed Images

- - - {{ fail }} - - -
-
+ + + Chowdown + Nextcloud Recipes + + + + + + + +
+