@movalib/movalib-commons 1.0.38 → 1.0.39

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.
@@ -1,5 +1,6 @@
1
1
  import { DigitalPassportIndex } from '../helpers/Enums';
2
2
  import Document from './Document';
3
+ import VehicleTire from './VehicleTire';
3
4
  export default class Vehicle {
4
5
  id: number;
5
6
  ownerId: number;
@@ -18,6 +19,7 @@ export default class Vehicle {
18
19
  tireSpeedIndex: string;
19
20
  tireWidth: string;
20
21
  documents: Document[];
21
- constructor(id: number, ownerId: number, averageMileagePerYear: number, plate: string, brand: string, model: string, version: string, vin: string, currentMileage: number, digitalPassportIndex: DigitalPassportIndex, firstRegistrationDate: Date, ktype: string, tireDiameter: string, tireHeight: string, tireSpeedIndex: string, tireWidth: string, documents: Document[]);
22
+ tireSize: VehicleTire;
23
+ constructor(id: number, ownerId: number, averageMileagePerYear: number, plate: string, brand: string, model: string, version: string, vin: string, currentMileage: number, digitalPassportIndex: DigitalPassportIndex, firstRegistrationDate: Date, ktype: string, tireDiameter: string, tireHeight: string, tireSpeedIndex: string, tireWidth: string, documents: Document[], tireSize: VehicleTire);
22
24
  getVehicleLabel(): string;
23
25
  }
@@ -11,7 +11,7 @@ Carburant : Essence
11
11
  Cylindrée : 1984 cm3
12
12
  Puissance : 140 KW (190 HP) */
13
13
  var Vehicle = /** @class */ (function () {
14
- function Vehicle(id, ownerId, averageMileagePerYear, plate, brand, model, version, vin, currentMileage, digitalPassportIndex, firstRegistrationDate, ktype, tireDiameter, tireHeight, tireSpeedIndex, tireWidth, documents) {
14
+ function Vehicle(id, ownerId, averageMileagePerYear, plate, brand, model, version, vin, currentMileage, digitalPassportIndex, firstRegistrationDate, ktype, tireDiameter, tireHeight, tireSpeedIndex, tireWidth, documents, tireSize) {
15
15
  this.id = id;
16
16
  this.ownerId = ownerId;
17
17
  this.averageMileagePerYear = averageMileagePerYear;
@@ -29,6 +29,7 @@ var Vehicle = /** @class */ (function () {
29
29
  this.tireSpeedIndex = tireSpeedIndex;
30
30
  this.tireWidth = tireWidth;
31
31
  this.documents = documents;
32
+ this.tireSize = tireSize;
32
33
  }
33
34
  Vehicle.prototype.getVehicleLabel = function () {
34
35
  return "".concat(this.brand, " ").concat(this.model, " ").concat(this.version);
@@ -0,0 +1,7 @@
1
+ export default class VehicleTire {
2
+ tireWidth: string;
3
+ tireHeight: string;
4
+ tireDiameter: string;
5
+ tireSpeedIndex: string;
6
+ constructor(tireWidth: string, tireHeight: string, tireDiameter: string, tireSpeedIndex: string);
7
+ }
@@ -0,0 +1,12 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ var VehicleTire = /** @class */ (function () {
4
+ function VehicleTire(tireWidth, tireHeight, tireDiameter, tireSpeedIndex) {
5
+ this.tireWidth = tireWidth;
6
+ this.tireHeight = tireHeight;
7
+ this.tireDiameter = tireDiameter;
8
+ this.tireSpeedIndex = tireSpeedIndex;
9
+ }
10
+ return VehicleTire;
11
+ }());
12
+ exports.default = VehicleTire;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@movalib/movalib-commons",
3
- "version": "1.0.38",
3
+ "version": "1.0.39",
4
4
  "description": "Bibliothèque d'objets communs à l'ensemble des projets React de Movalib",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -1,5 +1,6 @@
1
1
  import { DigitalPassportIndex } from '../helpers/Enums';
2
2
  import Document from './Document';
3
+ import VehicleTire from './VehicleTire';
3
4
 
4
5
  /* AUDI A5 Sportback (F5A, F5F)
5
6
  Marque : AUDI
@@ -32,6 +33,7 @@ export default class Vehicle {
32
33
  tireSpeedIndex: string;
33
34
  tireWidth: string;
34
35
  documents : Document[];
36
+ tireSize: VehicleTire;
35
37
 
36
38
  constructor(
37
39
  id: number,
@@ -50,7 +52,8 @@ export default class Vehicle {
50
52
  tireHeight: string,
51
53
  tireSpeedIndex: string,
52
54
  tireWidth: string,
53
- documents: Document[]
55
+ documents: Document[],
56
+ tireSize: VehicleTire
54
57
  ) {
55
58
  this.id = id;
56
59
  this.ownerId = ownerId;
@@ -69,6 +72,7 @@ export default class Vehicle {
69
72
  this.tireSpeedIndex = tireSpeedIndex;
70
73
  this.tireWidth = tireWidth;
71
74
  this.documents = documents;
75
+ this.tireSize = tireSize;
72
76
  }
73
77
 
74
78
  getVehicleLabel() {
@@ -0,0 +1,22 @@
1
+ export default class VehicleTire {
2
+
3
+ tireWidth: string;
4
+ tireHeight: string;
5
+ tireDiameter: string;
6
+ tireSpeedIndex: string;
7
+
8
+ constructor(
9
+ tireWidth: string,
10
+ tireHeight: string,
11
+ tireDiameter: string,
12
+ tireSpeedIndex: string
13
+ ) {
14
+
15
+ this.tireWidth = tireWidth;
16
+ this.tireHeight = tireHeight;
17
+ this.tireDiameter = tireDiameter;
18
+ this.tireSpeedIndex = tireSpeedIndex;
19
+ }
20
+
21
+
22
+ }