forked from mirrors/homebox
feat: redirect to item on create (#121)
* redirect on create * change to text area
This commit is contained in:
parent
4a9d21d604
commit
c722495fdd
3 changed files with 7 additions and 3 deletions
|
@ -54,7 +54,7 @@
|
|||
const toast = useNotifier();
|
||||
|
||||
async function create() {
|
||||
const { error } = await api.labels.create(form);
|
||||
const { error, data } = await api.labels.create(form);
|
||||
if (error) {
|
||||
toast.error("Couldn't create label");
|
||||
return;
|
||||
|
@ -62,5 +62,6 @@
|
|||
|
||||
toast.success("Label created");
|
||||
reset();
|
||||
navigateTo(`/label/${data.id}`);
|
||||
}
|
||||
</script>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue