Merge branch 'export'

This commit is contained in:
2020-08-19 02:37:00 +02:00
parent 8ccd7f6058
commit 88b6eb56ae
19 changed files with 300 additions and 124 deletions
+5 -3
View File
@@ -2,6 +2,7 @@ package be.simplenotes.app.routes
import be.simplenotes.app.controllers.BaseController
import be.simplenotes.app.controllers.NoteController
import be.simplenotes.app.controllers.SettingsController
import be.simplenotes.app.controllers.UserController
import be.simplenotes.app.filters.ErrorFilter
import be.simplenotes.app.filters.ImmutableFilter
@@ -19,6 +20,7 @@ class Router(
private val baseController: BaseController,
private val userController: UserController,
private val noteController: NoteController,
private val settingsController: SettingsController,
private val requiredAuth: Filter,
private val optionalAuth: Filter,
private val contexts: RequestContexts,
@@ -42,9 +44,9 @@ class Router(
)
val protectedRoutes = routes(
"/settings" bind GET to { protected(it, userController::settings) },
"/settings" bind POST to { protected(it, userController::settings) },
"/export" bind POST to { TODO() },
"/settings" bind GET to { protected(it, settingsController::settings) },
"/settings" bind POST to { protected(it, settingsController::settings) },
"/export" bind POST to { protected(it, settingsController::export) },
"/notes" bind GET to { protected(it, noteController::list) },
"/notes/new" bind GET to { protected(it, noteController::new) },
"/notes/new" bind POST to { protected(it, noteController::new) },