From 4465f06b7301382305008eb5d0113c485fd05af5 Mon Sep 17 00:00:00 2001 From: Sijisu Date: Sat, 23 Jan 2021 01:34:13 +0100 Subject: [PATCH] WIP --- form/res-judicata/src/components/edit/Hlava.vue | 17 +++++++++++++++++ form/res-judicata/src/views/Edit.vue | 9 +++++++-- 2 files changed, 24 insertions(+), 2 deletions(-) diff --git a/form/res-judicata/src/components/edit/Hlava.vue b/form/res-judicata/src/components/edit/Hlava.vue index cffafde..e79872b 100644 --- a/form/res-judicata/src/components/edit/Hlava.vue +++ b/form/res-judicata/src/components/edit/Hlava.vue @@ -15,6 +15,9 @@

+

+ a +

@@ -54,6 +57,20 @@ export default { } else { return this.text } + }, + textOut: function () { + return this.text + }, + titleOut: function () { + return this.title + } + }, + watch: { + titleOut: function (oldVal,newVal) { + this.$emit('update:title', newVal) + }, + textOut: function (oldVal,newVal) { + this.$emit('update:text', newVal) } } } diff --git a/form/res-judicata/src/views/Edit.vue b/form/res-judicata/src/views/Edit.vue index 918fd57..3f5e74e 100644 --- a/form/res-judicata/src/views/Edit.vue +++ b/form/res-judicata/src/views/Edit.vue @@ -48,9 +48,9 @@ {{ zaloba.title }}
- +
- + + + @@ -74,6 +74,11 @@ export default { NavBar, Hlava }, + methods: { + addHlava: function () { + this.zaloba.hlavy.push({"title":"","text":""}) + } + }, data: () => { return { zaloba: {