@design.estate/dees-document 1.0.99 → 1.0.103

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/npmextra.json CHANGED
@@ -2,19 +2,40 @@
2
2
  "gitzone": {
3
3
  "projectType": "wcc",
4
4
  "module": {
5
- "githost": "gitlab.com",
5
+ "githost": "code.foss.global",
6
6
  "gitscope": "designestate/private",
7
7
  "gitrepo": "dedocument-catalog",
8
- "description": "a catalog for creating documents like invoices",
8
+ "description": "A comprehensive solution for generating documents like invoices, integrating elements, templates, and services to streamline document creation.",
9
9
  "npmPackagename": "@designestate_private/dedocument-catalog",
10
10
  "license": "MIT",
11
11
  "projectDomain": "design.estate",
12
- "shortDescription": "undefined variable"
12
+ "shortDescription": "undefined variable",
13
+ "keywords": [
14
+ "document generation",
15
+ "invoices",
16
+ "PDF creation",
17
+ "typescript",
18
+ "web components",
19
+ "custom elements",
20
+ "QR code",
21
+ "smart contracts",
22
+ "templating",
23
+ "dynamic rendering",
24
+ "responsive design",
25
+ "modular development",
26
+ "lightweight",
27
+ "efficient",
28
+ "finance",
29
+ "business"
30
+ ]
13
31
  }
14
32
  },
15
33
  "npmci": {
16
34
  "npmGlobalTools": [],
17
35
  "npmAccessLevel": "private",
18
36
  "npmRegistryUrl": "verdaccio2.lossless.one"
37
+ },
38
+ "tsdoc": {
39
+ "legal": "\n## License and Legal Information\n\nThis repository contains open-source code that is licensed under the MIT License. A copy of the MIT License can be found in the [license](license) file within this repository. \n\n**Please note:** The MIT License does not grant permission to use the trade names, trademarks, service marks, or product names of the project, except as required for reasonable and customary use in describing the origin of the work and reproducing the content of the NOTICE file.\n\n### Trademarks\n\nThis project is owned and maintained by Task Venture Capital GmbH. The names and logos associated with Task Venture Capital GmbH and any related products or services are trademarks of Task Venture Capital GmbH and are not included within the scope of the MIT license granted herein. Use of these trademarks must comply with Task Venture Capital GmbH's Trademark Guidelines, and any usage must be approved in writing by Task Venture Capital GmbH.\n\n### Company Information\n\nTask Venture Capital GmbH \nRegistered at District court Bremen HRB 35230 HB, Germany\n\nFor any legal inquiries or if you require further information, please contact us via email at hello@task.vc.\n\nBy using this repository, you acknowledge that you have read this section, agree to comply with its terms, and understand that the licensing of the code does not imply endorsement by Task Venture Capital GmbH of any derivative works.\n"
19
40
  }
20
41
  }
package/package.json CHANGED
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "name": "@design.estate/dees-document",
3
- "version": "1.0.99",
3
+ "version": "1.0.103",
4
4
  "private": false,
5
- "description": "a catalog for creating documents like invoices",
5
+ "description": "A comprehensive solution for generating documents like invoices, integrating elements, templates, and services to streamline document creation.",
6
6
  "main": "dist_ts_web/index.js",
7
7
  "typings": "dist_ts_web/index.d.ts",
8
8
  "exports": {
@@ -12,26 +12,26 @@
12
12
  "author": "Lossless GmbH",
13
13
  "license": "MIT",
14
14
  "dependencies": {
15
- "@design.estate/dees-domtools": "^2.0.55",
16
- "@design.estate/dees-element": "^2.0.33",
17
- "@design.estate/dees-wcctools": "^1.0.85",
18
- "@git.zone/tsrun": "^1.2.46",
19
- "@push.rocks/smartfile": "^11.0.4",
20
- "@push.rocks/smartjson": "^5.0.10",
21
- "@push.rocks/smartpath": "^5.0.11",
22
- "@push.rocks/smartpdf": "^3.0.16",
23
- "@push.rocks/smarttime": "^4.0.6",
24
- "@tsclass/tsclass": "^4.0.46",
15
+ "@design.estate/dees-domtools": "^2.0.65",
16
+ "@design.estate/dees-element": "^2.0.39",
17
+ "@design.estate/dees-wcctools": "^1.0.90",
18
+ "@git.zone/tsrun": "^1.3.3",
19
+ "@push.rocks/smartfile": "^11.0.21",
20
+ "@push.rocks/smartjson": "^5.0.20",
21
+ "@push.rocks/smartpath": "^5.0.18",
22
+ "@push.rocks/smartpdf": "^3.1.7",
23
+ "@push.rocks/smarttime": "^4.0.8",
24
+ "@tsclass/tsclass": "^4.1.2",
25
25
  "@types/qrcode": "^1.5.5",
26
- "qrcode": "^1.5.3"
26
+ "qrcode": "^1.5.4"
27
27
  },
28
28
  "devDependencies": {
29
- "@git.zone/tsbuild": "^2.1.72",
30
- "@git.zone/tsbundle": "^2.0.15",
31
- "@git.zone/tstest": "^1.0.84",
32
- "@git.zone/tswatch": "^2.0.21",
29
+ "@git.zone/tsbuild": "^2.2.0",
30
+ "@git.zone/tsbundle": "^2.1.0",
31
+ "@git.zone/tstest": "^1.0.90",
32
+ "@git.zone/tswatch": "^2.0.25",
33
33
  "@push.rocks/projectinfo": "^5.0.2",
34
- "@push.rocks/tapbundle": "^5.0.15"
34
+ "@push.rocks/tapbundle": "^5.5.3"
35
35
  },
36
36
  "files": [
37
37
  "ts/**/*",
@@ -57,6 +57,24 @@
57
57
  "url": "https://gitlab.com/designestate/private/dedocument-catalog/issues"
58
58
  },
59
59
  "homepage": "https://gitlab.com/designestate/private/dedocument-catalog#readme",
60
+ "keywords": [
61
+ "document generation",
62
+ "invoices",
63
+ "PDF creation",
64
+ "typescript",
65
+ "web components",
66
+ "custom elements",
67
+ "QR code",
68
+ "smart contracts",
69
+ "templating",
70
+ "dynamic rendering",
71
+ "responsive design",
72
+ "modular development",
73
+ "lightweight",
74
+ "efficient",
75
+ "finance",
76
+ "business"
77
+ ],
60
78
  "scripts": {
61
79
  "test": "npm run build && tstest test/",
62
80
  "build": "tsbuild --allowimplicitany && tsbuild element --allowimplicitany && tsbundle element --production",
@@ -0,0 +1 @@
1
+
package/readme.md CHANGED
@@ -1,7 +1,144 @@
1
- # @design.estate/private/dedocument-catalog
1
+ # @design.estate/dees-document
2
2
  a catalog for creating documents like invoices
3
3
 
4
+ ## Install
5
+ To install `@design.estate/dees-document`, run the following command in your project directory:
6
+ ```shell
7
+ npm install @design.estate/dees-document --save
8
+ ```
9
+
10
+ This will add `@design.estate/dees-document` to your project's dependencies and ensure it's installed into your `node_modules` folder.
11
+
4
12
  ## Usage
13
+ The `@design.estate/dees-document` package is a comprehensive toolkit for creating various types of documents, such as invoices, with ease. It leverages modern ECMAScript (ES) modules and TypeScript for a type-safe, developer-friendly experience. Below, you'll find detailed examples covering how to utilize the package to its full potential.
14
+
15
+ ### Setting Up the Document Service
16
+ Before diving into creating documents, you first need to set up the document service. This involves importing the necessary modules and initializing the service instance.
17
+
18
+ ```typescript
19
+ import { PdfService, IPdfServiceConstructorOptions } from '@design.estate/dees-document';
20
+
21
+ async function setupPdfService() {
22
+ const options: IPdfServiceConstructorOptions = {
23
+ // Configuration options here
24
+ };
25
+
26
+ const pdfService = await PdfService.createAndStart(options);
27
+ console.log('PDF Service started successfully.');
28
+ return pdfService;
29
+ }
30
+ ```
31
+
32
+ In the example above, we import `PdfService` from the package and use its `createAndStart` method to initialize it with optional configuration settings. Replace `// Configuration options here` with any specific options your project may require.
33
+
34
+ ### Creating a Simple Invoice
35
+ After setting up the document service, you can proceed to create documents such as invoices. Here, we'll demonstrate how to create a basic invoice.
36
+
37
+ #### Define the Invoice Data Structure
38
+ First, define the basic structure of your invoice. This involves specifying details like the sender, recipient, items, and more.
39
+
40
+ ```typescript
41
+ import { ILetter } from '@design.estate/dees-document';
42
+
43
+ const invoiceData: ILetter = {
44
+ from: {
45
+ name: "Your Company Name",
46
+ address: {
47
+ streetName: "Your Street",
48
+ houseNumber: "123",
49
+ city: "Your City",
50
+ country: "Your Country",
51
+ postalCode: "12345",
52
+ },
53
+ email: "your-email@example.com",
54
+ phone: "123-456-7890",
55
+ },
56
+ to: {
57
+ name: "Recipient Company Name",
58
+ address: {
59
+ streetName: "Recipient Street",
60
+ houseNumber: "456",
61
+ city: "Recipient City",
62
+ country: "Recipient Country",
63
+ postalCode: "67890",
64
+ },
65
+ email: "recipient-email@example.com",
66
+ phone: "098-765-4321",
67
+ },
68
+ content: {
69
+ invoiceData: {
70
+ items: [
71
+ {
72
+ name: "Service or Product Name",
73
+ unitQuantity: 2,
74
+ unitNetPrice: 100.00,
75
+ unitType: 'service',
76
+ vatPercentage: 19,
77
+ currency: 'EUR',
78
+ }
79
+ ]
80
+ }
81
+ },
82
+ subject: "Invoice for Services Rendered",
83
+ date: new Date().getTime(),
84
+ versionInfo: {
85
+ type: "final",
86
+ version: "1.0.0"
87
+ },
88
+ };
89
+ ```
90
+
91
+ In this structure, `invoiceData` outlines essential details for an invoice document, using the `ILetter` interface. It includes information about both the sender (`from`) and the recipient (`to`), as well as the invoiced items under `content.invoiceData.items`.
92
+
93
+ #### Generate the Invoice PDF
94
+ With the invoice data ready, you can now generate the PDF using the `PdfService` instance.
95
+
96
+ ```typescript
97
+ async function generateInvoice(pdfService: PdfService, invoiceData: ILetter) {
98
+ const pdfBuffer = await pdfService.createPdfFromLetterObject(invoiceData);
99
+ console.log('Invoice PDF generated successfully.');
100
+
101
+ // Here, you can save the PDF to a file, send it over a network, etc.
102
+ }
103
+ ```
104
+
105
+ The method `createPdfFromLetterObject` receives the invoice data and returns a `Buffer` containing the PDF. You can then save this PDF to the filesystem, send it over email, or perform any other required actions.
106
+
107
+ #### Complete Example Integration
108
+ Combining everything, your complete script to set up the service, define invoice data, and generate a PDF invoice might look something like this:
109
+
110
+ ```typescript
111
+ async function main() {
112
+ const pdfService = await setupPdfService();
113
+ await generateInvoice(pdfService, invoiceData);
114
+ }
115
+
116
+ main().then(() => console.log('Invoice generation process completed.'));
117
+ ```
118
+
119
+ ### Beyond Invoices
120
+ The `@design.estate/dees-document` package is not limited to invoices alone. It's designed to handle a wide range of document types. The modular architecture allows for the customizable construction of documents, enabling you to tailor the output to meet precise requirements.
121
+
122
+ For instance, you can create contracts, reports, and other document types using a similar approach—by defining the content structure and utilizing the PDF service to generate the document. The package's flexibility and extensibility make it an invaluable tool in any document generation workflow.
123
+
124
+ ### Advanced Usage
125
+ For more advanced scenarios, such as custom styling, embedding images, and handling more complex document structures, refer to the package's documentation. It provides comprehensive details and examples to help you fully leverage the capabilities of `@design.estate/dees-document`.
126
+
127
+ ## License and Legal Information
128
+
129
+ This repository contains open-source code that is licensed under the MIT License. A copy of the MIT License can be found in the [license](license) file within this repository.
130
+
131
+ **Please note:** The MIT License does not grant permission to use the trade names, trademarks, service marks, or product names of the project, except as required for reasonable and customary use in describing the origin of the work and reproducing the content of the NOTICE file.
132
+
133
+ ### Trademarks
134
+
135
+ This project is owned and maintained by Task Venture Capital GmbH. The names and logos associated with Task Venture Capital GmbH and any related products or services are trademarks of Task Venture Capital GmbH and are not included within the scope of the MIT license granted herein. Use of these trademarks must comply with Task Venture Capital GmbH's Trademark Guidelines, and any usage must be approved in writing by Task Venture Capital GmbH.
136
+
137
+ ### Company Information
138
+
139
+ Task Venture Capital GmbH
140
+ Registered at District court Bremen HRB 35230 HB, Germany
141
+
142
+ For any legal inquiries or if you require further information, please contact us via email at hello@task.vc.
5
143
 
6
- Use TypeScript for best in class intellisense
7
- For further information read the linked docs at the top of this readme.
144
+ By using this repository, you acknowledge that you have read this section, agree to comply with its terms, and understand that the licensing of the code does not imply endorsement by Task Venture Capital GmbH of any derivative works.
@@ -1,8 +1,8 @@
1
1
  /**
2
- * autocreated commitinfo by @pushrocks/commitinfo
2
+ * autocreated commitinfo by @push.rocks/commitinfo
3
3
  */
4
4
  export const commitinfo = {
5
5
  name: '@design.estate/dees-document',
6
- version: '1.0.99',
7
- description: 'a catalog for creating documents like invoices'
6
+ version: '1.0.103',
7
+ description: 'A comprehensive solution for generating documents like invoices, integrating elements, templates, and services to streamline document creation.'
8
8
  }
@@ -1,8 +1,8 @@
1
1
  /**
2
- * autocreated commitinfo by @pushrocks/commitinfo
2
+ * autocreated commitinfo by @push.rocks/commitinfo
3
3
  */
4
4
  export const commitinfo = {
5
5
  name: '@design.estate/dees-document',
6
- version: '1.0.99',
7
- description: 'a catalog for creating documents like invoices'
6
+ version: '1.0.103',
7
+ description: 'A comprehensive solution for generating documents like invoices, integrating elements, templates, and services to streamline document creation.'
8
8
  }
@@ -292,9 +292,9 @@ export class DeContentInvoice extends DeesElement {
292
292
  <div class="lineItem">${invoiceItem.name}</div>
293
293
  <div class="lineItem">${invoiceItem.unitQuantity}</div>
294
294
  <div class="lineItem">${invoiceItem.unitType}</div>
295
- <div class="lineItem">${invoiceItem.unitNetPrice} ${invoiceItem.currency}</div>
295
+ <div class="lineItem">${invoiceItem.unitNetPrice} ${this.letterData?.content.invoiceData.currency}</div>
296
296
  <div class="lineItem">
297
- ${invoiceItem.unitQuantity * invoiceItem.unitNetPrice} ${invoiceItem.currency}
297
+ ${invoiceItem.unitQuantity * invoiceItem.unitNetPrice} ${this.letterData?.content.invoiceData.currency}
298
298
  </div>
299
299
  </div>
300
300
  `
@@ -343,7 +343,7 @@ export class DeContentInvoice extends DeesElement {
343
343
  IBAN: ${this.letterData?.from?.sepaConnection?.iban}<br />
344
344
  BIC: ${this.letterData?.from?.sepaConnection?.bic}<br />
345
345
  Description: ${this.letterData?.content.invoiceData?.id}<br />
346
- Amount: ${this.getTotalGross()} ${this.letterData?.content.invoiceData.items[0].currency}
346
+ Amount: ${this.getTotalGross()} ${this.letterData?.content.invoiceData.currency}
347
347
  </div>
348
348
  ${this.letterData?.content?.contractData?.contractDate
349
349
  ? html`
@@ -32,21 +32,25 @@ export class DeDocument extends DeesElement {
32
32
 
33
33
  @property({
34
34
  type: String,
35
+ reflect: true,
35
36
  })
36
37
  public format: 'a4' = 'a4';
37
38
 
38
39
  @property({
39
40
  type: Number,
41
+ reflect: true,
40
42
  })
41
43
  public viewWidth: number = null;
42
44
 
43
45
  @property({
44
46
  type: Number,
47
+ reflect: true,
45
48
  })
46
49
  public viewHeight: number = null;
47
50
 
48
51
  @property({
49
52
  type: Boolean,
53
+ reflect: true,
50
54
  })
51
55
  printMode = false;
52
56
 
@@ -60,7 +64,6 @@ export class DeDocument extends DeesElement {
60
64
  return valueArg;
61
65
  }
62
66
  },
63
-
64
67
  })
65
68
  public letterData: plugins.tsclass.business.ILetter;
66
69
 
@@ -114,20 +117,27 @@ export class DeDocument extends DeesElement {
114
117
  const response = await fetch(this.letterDataUrl);
115
118
  this.letterData = await response.json();
116
119
  }
117
- this.renderDocument();
118
120
  }
119
121
 
122
+ public latestRenderedLetterData: plugins.tsclass.business.ILetter = null;
123
+
124
+
120
125
  public async renderDocument() {
121
126
  const domtools = await this.domtoolsPromise;
122
- const documentContainer = this.shadowRoot.querySelector('.documentContainer');
127
+
128
+
129
+ const documentBuildContainer = document.createElement('div');
130
+ document.body.appendChild(documentBuildContainer);
131
+
123
132
  let pages: DePage[] = [];
124
133
  let pageCounter = 0;
125
134
  let complete = false;
126
- const content: DeContentInvoice = document.createElement(
127
- 'dedocument-contentinvoice'
128
- ) as DeContentInvoice;
135
+
136
+ // lets append the content
137
+ const content: DeContentInvoice = new DeContentInvoice();
129
138
  content.letterData = this.letterData;
130
139
  document.body.appendChild(content);
140
+
131
141
  await domtools.convenience.smartdelay.delayFor(0);
132
142
  let overallContentOffset: number = 0;
133
143
  let currentContentOffset: number;
@@ -142,13 +152,8 @@ export class DeDocument extends DeesElement {
142
152
  newPage.pageNumber = pageCounter;
143
153
  newPage.append(currentContent);
144
154
  newPage.pageTotalNumber = pageCounter;
145
- documentContainer.append(newPage);
146
- // betweenPagesSpacer
147
- if (!this.printMode) {
148
- const betweenPagesSpacerDiv = document.createElement('div');
149
- betweenPagesSpacerDiv.classList.add('betweenPagesSpacer');
150
- documentContainer.append(betweenPagesSpacerDiv);
151
- }
155
+ documentBuildContainer.append(newPage);
156
+
152
157
  await currentContent.elementDomReady;
153
158
  await currentContent.trimStartToOffset(overallContentOffset);
154
159
  let newPageOverflows = await newPage.checkOverflow();
@@ -167,15 +172,34 @@ export class DeDocument extends DeesElement {
167
172
  console.log(currentContentOffset);
168
173
  }
169
174
  document.body.removeChild(content);
175
+ document.body.removeChild(documentBuildContainer);
170
176
 
177
+ const documentContainer = this.shadowRoot.querySelector('.documentContainer');
178
+ if (documentContainer) {
179
+ const children = Array.from(documentContainer.children);
180
+ children.forEach((child) => documentContainer.removeChild(child));
181
+ }
171
182
  for (const page of pages) {
172
183
  page.pageTotalNumber = pageCounter;
184
+ documentContainer.append(page);
185
+ // betweenPagesSpacer
186
+ if (!this.printMode) {
187
+ const betweenPagesSpacerDiv = document.createElement('div');
188
+ betweenPagesSpacerDiv.classList.add('betweenPagesSpacer');
189
+ documentContainer.appendChild(betweenPagesSpacerDiv);
190
+ }
173
191
  }
174
192
  this.adjustDePageScaling();
193
+ this.latestRenderedLetterData = this.letterData;
175
194
  }
176
195
 
177
- updated(changedProperties: Map<string | number | symbol, unknown>): void {
196
+ async updated(changedProperties: Map<string | number | symbol, unknown>): Promise<void> {
178
197
  super.updated(changedProperties);
198
+ const domtools = await this.domtoolsPromise;
199
+ const renderedDocIsUpToDate = domtools.convenience.smartjson.deepEqualObjects(this.letterData, this.latestRenderedLetterData);
200
+ if (!renderedDocIsUpToDate) {
201
+ this.renderDocument();
202
+ }
179
203
 
180
204
  if (changedProperties.has('viewHeight') || changedProperties.has('viewWidth')) {
181
205
  this.adjustDePageScaling();
@@ -65,8 +65,6 @@ export class DePage extends DeesElement {
65
65
  css`
66
66
  :host {
67
67
  display: block;
68
- max-height: ${shared.a4Height}px;
69
- max-width: ${shared.a4Width}px;
70
68
  }
71
69
 
72
70
  #scaleWrapper {
@@ -59,31 +59,33 @@ export const demoLetter: tsclass.business.ILetter = {
59
59
  deliveryDate: new Date().getTime(),
60
60
  periodOfPerformance: null,
61
61
  printResult: null,
62
-
62
+ currency: 'EUR',
63
+ notes: [],
64
+ type: 'debitnote',
63
65
  items: [
64
66
  {
65
67
  name: 'Item with 19% VAT',
66
- unitQuantity: 1,
68
+ unitQuantity: 2,
67
69
  unitNetPrice: 100,
68
70
  unitType: 'hours',
69
71
  vatPercentage: 19,
70
- currency: 'EUR',
72
+ position: 0,
71
73
  },
72
74
  {
73
75
  name: 'Item with 7% VAT',
74
- unitQuantity: 1,
76
+ unitQuantity: 4,
75
77
  unitNetPrice: 100,
76
78
  unitType: 'hours',
77
79
  vatPercentage: 7,
78
- currency: 'EUR',
80
+ position: 1,
79
81
  },
80
82
  {
81
83
  name: 'Item with 7% VAT',
82
- unitQuantity: 1,
84
+ unitQuantity: 3,
83
85
  unitNetPrice: 230,
84
86
  unitType: 'hours',
85
87
  vatPercentage: 7,
86
- currency: 'EUR',
88
+ position: 2,
87
89
  },
88
90
  {
89
91
  name: 'Item with 21% VAT',
@@ -91,7 +93,94 @@ export const demoLetter: tsclass.business.ILetter = {
91
93
  unitNetPrice: 230,
92
94
  unitType: 'hours',
93
95
  vatPercentage: 21,
94
- currency: 'EUR',
96
+ position: 3,
97
+ },
98
+ {
99
+ name: 'Item with 0% VAT',
100
+ unitQuantity: 6,
101
+ unitNetPrice: 230,
102
+ unitType: 'hours',
103
+ vatPercentage: 0,
104
+ position: 4,
105
+ },{
106
+ name: 'Item with 19% VAT',
107
+ unitQuantity: 8,
108
+ unitNetPrice: 100,
109
+ unitType: 'hours',
110
+ vatPercentage: 19,
111
+ position: 5,
112
+ },
113
+ {
114
+ name: 'Item with 7% VAT',
115
+ unitQuantity: 9,
116
+ unitNetPrice: 100,
117
+ unitType: 'hours',
118
+ vatPercentage: 7,
119
+ position: 6,
120
+ },
121
+ {
122
+ name: 'Item with 7% VAT',
123
+ unitQuantity: 4,
124
+ unitNetPrice: 230,
125
+ unitType: 'hours',
126
+ vatPercentage: 7,
127
+ position: 8,
128
+ },
129
+ {
130
+ name: 'Item with 21% VAT',
131
+ unitQuantity: 3,
132
+ unitNetPrice: 230,
133
+ unitType: 'hours',
134
+ vatPercentage: 21,
135
+ position: 9,
136
+ },
137
+ {
138
+ name: 'Item with 0% VAT',
139
+ unitQuantity: 1,
140
+ unitNetPrice: 230,
141
+ unitType: 'hours',
142
+ vatPercentage: 0,
143
+ position: 10,
144
+ },
145
+ {
146
+ name: 'Item with 0% VAT',
147
+ unitQuantity: 1,
148
+ unitNetPrice: 230,
149
+ unitType: 'hours',
150
+ vatPercentage: 0,
151
+ position: 10,
152
+ },
153
+ {
154
+ name: 'Item with 0% VAT',
155
+ unitQuantity: 1,
156
+ unitNetPrice: 230,
157
+ unitType: 'hours',
158
+ vatPercentage: 0,
159
+ position: 10,
160
+ },
161
+ {
162
+ name: 'Item with 0% VAT',
163
+ unitQuantity: 1,
164
+ unitNetPrice: 230,
165
+ unitType: 'hours',
166
+ vatPercentage: 0,
167
+ position: 10,
168
+ },
169
+ {
170
+ name: 'Item with 0% VAT',
171
+ unitQuantity: 1,
172
+ unitNetPrice: 230,
173
+ unitType: 'hours',
174
+ vatPercentage: 0,
175
+ position: 10,
176
+ },
177
+ {
178
+ name: 'Item with 0% VAT',
179
+ unitQuantity: 1,
180
+ unitNetPrice: 230,
181
+ unitType: 'hours',
182
+ vatPercentage: 0,
183
+ position: 10,
95
184
  },
96
185
  {
97
186
  name: 'Item with 0% VAT',
@@ -99,7 +188,7 @@ export const demoLetter: tsclass.business.ILetter = {
99
188
  unitNetPrice: 230,
100
189
  unitType: 'hours',
101
190
  vatPercentage: 0,
102
- currency: 'EUR',
191
+ position: 10,
103
192
  },
104
193
  ],
105
194
  }