Proper no žalobce handling

This commit is contained in:
Greenscreener 2021-01-23 11:20:45 +01:00
parent 212e17862f
commit 492a1924b2
2 changed files with 3 additions and 3 deletions

View File

@ -268,7 +268,7 @@ export default {
}
// TODO: proper validation
if (!this.hasZastoupeni) {
this.zaloba.zalobci[0].zastoupeni = null
this.zaloba.zalobci[0].zastoupen = null
}
this.zaloba.datum = this.zaloba.datum.toLocaleDateString('cs-CZ')
this.$emit("zalobaguideclose",this.zaloba)

View File

@ -207,7 +207,7 @@ export default {
text: `${e.sidlo.uliceacislopopisne}, ${e.sidlo.psc}, ${e.sidlo.mesto}`,
style: "zalobce"
},
...typeof e.zastoupen !== "undefined" ? [
...typeof e.zastoupen !== "undefined" && e.zastoupen !== null ? [
{
text: "zastoupen: ",
style: "zalobce"
@ -239,7 +239,7 @@ export default {
text: `${e.sidlo.uliceacislopopisne}, ${e.sidlo.psc}, ${e.sidlo.mesto}`,
style: "zalobce"
},
...typeof e.zastoupen !== "undefined" ? [
...typeof e.zastoupen !== "undefined" && e.zastoupen !== null ? [
{
text: "zastoupen: ",
style: "zalobce"