Merge pull request #363 from moritz-tr/fix/create-document-from-template
fix: docx generation from template
This commit is contained in:
@ -10,6 +10,7 @@ export class Footer extends InitializableXmlComponent {
|
||||
constructor(referenceNumber: number, initContent?: XmlComponent) {
|
||||
super("w:ftr", initContent);
|
||||
this.refId = referenceNumber;
|
||||
if (!initContent) {
|
||||
this.root.push(
|
||||
new FooterAttributes({
|
||||
wpc: "http://schemas.microsoft.com/office/word/2010/wordprocessingCanvas",
|
||||
@ -31,6 +32,7 @@ export class Footer extends InitializableXmlComponent {
|
||||
}),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
public get ReferenceId(): number {
|
||||
return this.refId;
|
||||
|
@ -11,7 +11,7 @@ export class Header extends InitializableXmlComponent {
|
||||
super("w:hdr", initContent);
|
||||
|
||||
this.refId = referenceNumber;
|
||||
|
||||
if (!initContent) {
|
||||
this.root.push(
|
||||
new HeaderAttributes({
|
||||
wpc: "http://schemas.microsoft.com/office/word/2010/wordprocessingCanvas",
|
||||
@ -44,6 +44,7 @@ export class Header extends InitializableXmlComponent {
|
||||
}),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
public get ReferenceId(): number {
|
||||
return this.refId;
|
||||
|
Reference in New Issue
Block a user