Adds extended label to pdf-export

This commit is contained in:
GabrielMeyer 2019-06-17 13:55:42 +02:00
parent 295c69e3fb
commit f63838ff83
2 changed files with 3 additions and 5 deletions

View File

@ -128,7 +128,7 @@ export class MotionPdfCatalogService {
if (categories && categories.length) {
const catTocBody = [];
for (const category of categories) {
for (const category of categories.sort((a, b) => a.weight - b.weight)) {
// push the name of the category
// make a table for correct alignment
catTocBody.push({
@ -136,7 +136,7 @@ export class MotionPdfCatalogService {
body: [
[
{
text: category.prefix ? category.prefix + ' - ' + category.name : category.name,
text: category.prefixedNameWithParents,
style: 'tocCategoryTitle'
}
]

View File

@ -271,9 +271,7 @@ export class MotionPdfService {
style: 'boldText'
},
{
text: motion.category.prefix
? `${motion.category.prefix} - ${motion.category.name}`
: `${motion.category.name}`
text: motion.category.prefixedNameWithParents
}
]);
}