Migration Improvements (#47)
Make "migration" "import everywhere" Add checking for migration status before trying to migrate Add get status from migrations Co-authored-by: kolaente <k@knt.li> Reviewed-on: https://kolaente.dev/vikunja/frontend/pulls/47
This commit is contained in:
@ -3,15 +3,21 @@ import AbstractService from '../abstractService'
|
||||
// This service builds on top of the abstract service and basically just hides away method names.
|
||||
// It enables migration services to be created with minimal overhead and even better method names.
|
||||
export default class AbstractMigrationService extends AbstractService {
|
||||
serviceUrlKey = ''
|
||||
|
||||
constructor(serviceUrlKey) {
|
||||
super({
|
||||
update: '/migration/'+serviceUrlKey+'/migrate',
|
||||
get: '/migration/'+serviceUrlKey+'/auth',
|
||||
})
|
||||
this.serviceUrlKey = serviceUrlKey
|
||||
}
|
||||
|
||||
getAuthUrl() {
|
||||
return this.get({})
|
||||
return this.getM('/migration/'+this.serviceUrlKey+'/auth')
|
||||
}
|
||||
|
||||
getStatus() {
|
||||
return this.getM('/migration/'+this.serviceUrlKey+'/status')
|
||||
}
|
||||
|
||||
migrate(data) {
|
||||
|
Reference in New Issue
Block a user