Merge pull request #5529 from tsiegleauq/export-dialog-supporter
Add "supporter" to motion export dialog
This commit is contained in:
commit
38af3d3b8a
@ -21,6 +21,7 @@ export const PERSONAL_NOTE_ID = -1;
|
||||
*/
|
||||
export type InfoToExport =
|
||||
| 'submitters'
|
||||
| 'supporters'
|
||||
| 'state'
|
||||
| 'recommendation'
|
||||
| 'category'
|
||||
@ -99,6 +100,7 @@ export enum MotionEditNotificationType {
|
||||
export const motionImportExportHeaderOrder: string[] = [
|
||||
'identifier',
|
||||
'submitters',
|
||||
'supporters',
|
||||
'title',
|
||||
'text',
|
||||
'reason',
|
||||
|
@ -247,8 +247,9 @@ export class MotionPdfService {
|
||||
}
|
||||
|
||||
// supporters
|
||||
if (!infoToExport || infoToExport.includes('supporters')) {
|
||||
const minSupporters = this.configService.instant<number>('motions_min_supporters');
|
||||
if (minSupporters && motion.supporters.length > 0) {
|
||||
if (!!minSupporters && motion.supporters.length > 0) {
|
||||
const supporters = motion.supporters
|
||||
.map(supporter => {
|
||||
return supporter.full_name;
|
||||
@ -265,6 +266,7 @@ export class MotionPdfService {
|
||||
}
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
||||
// state
|
||||
if (!infoToExport || infoToExport.includes('state')) {
|
||||
|
Loading…
Reference in New Issue
Block a user