Added Pagebreak Error
This commit is contained in:
@@ -661,7 +661,7 @@ const findDocumentErrors = computed(() => {
|
|||||||
if (itemInfo.value.rows.length === 0) {
|
if (itemInfo.value.rows.length === 0) {
|
||||||
errors.push({message: "Es sind keine Positionen angegeben", type: "breaking"})
|
errors.push({message: "Es sind keine Positionen angegeben", type: "breaking"})
|
||||||
} else {
|
} else {
|
||||||
itemInfo.value.rows.forEach(row => {
|
itemInfo.value.rows.forEach((row,index) => {
|
||||||
|
|
||||||
if (itemInfo.value.type !== "quotes" && row.optional) {
|
if (itemInfo.value.type !== "quotes" && row.optional) {
|
||||||
errors.push({
|
errors.push({
|
||||||
@@ -717,6 +717,10 @@ const findDocumentErrors = computed(() => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (index === itemInfo.value.rows.length - 1 && row.mode === "pagebreak") {
|
||||||
|
errors.push({message: `Die letze Position darf kein Seitenumbruch sein`, type: "breaking"})
|
||||||
|
}
|
||||||
|
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user