Sort Navigation newest forms first

Signed-off-by: Jonas Rittershofer <jotoeri@users.noreply.github.com>
This commit is contained in:
Jonas Rittershofer 2020-05-20 12:19:01 +02:00
commit a06d02872e
2 changed files with 7 additions and 3 deletions

View file

@ -148,7 +148,7 @@ export default {
// Request a new empty form
const response = await axios.post(generateUrl('/apps/forms/api/v1/form'))
const newForm = response.data
this.forms.push(newForm)
this.forms.unshift(newForm)
this.$router.push({ name: 'edit', params: { hash: newForm.hash } })
} catch (error) {
showError(t('forms', 'Unable to create a new form'))