@platform-modules/civil-aviation-authority 1.0.20 → 1.0.21

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,8 +1,8 @@
1
1
  import { BaseModel } from './BaseModel';
2
2
  export declare class CAAServices extends BaseModel {
3
- code: string | null;
3
+ code: string;
4
4
  name: string;
5
5
  description: string;
6
6
  logo_url: string;
7
- constructor(name: string, description: string, logo_url: string, code?: string | null);
7
+ constructor(name: string, description: string, logo_url: string, code?: string);
8
8
  }
@@ -13,18 +13,18 @@ exports.CAAServices = void 0;
13
13
  const typeorm_1 = require("typeorm");
14
14
  const BaseModel_1 = require("./BaseModel");
15
15
  let CAAServices = class CAAServices extends BaseModel_1.BaseModel {
16
- constructor(name, description, logo_url, code = null) {
16
+ constructor(name, description, logo_url, code) {
17
17
  super();
18
18
  this.name = name;
19
19
  this.description = description;
20
20
  this.logo_url = logo_url;
21
- this.code = code;
21
+ this.code = code || '';
22
22
  }
23
23
  };
24
24
  exports.CAAServices = CAAServices;
25
25
  __decorate([
26
- (0, typeorm_1.Column)({ nullable: true, unique: true }),
27
- __metadata("design:type", Object)
26
+ (0, typeorm_1.Column)({ type: 'varchar', length: 64, nullable: false, unique: true }),
27
+ __metadata("design:type", String)
28
28
  ], CAAServices.prototype, "code", void 0);
29
29
  __decorate([
30
30
  (0, typeorm_1.Column)({ nullable: false }),
@@ -40,5 +40,5 @@ __decorate([
40
40
  ], CAAServices.prototype, "logo_url", void 0);
41
41
  exports.CAAServices = CAAServices = __decorate([
42
42
  (0, typeorm_1.Entity)({ name: 'caa_services' }),
43
- __metadata("design:paramtypes", [String, String, String, Object])
43
+ __metadata("design:paramtypes", [String, String, String, String])
44
44
  ], CAAServices);
@@ -24,7 +24,7 @@ let CAASubServices = class CAASubServices extends BaseModel_1.BaseModel {
24
24
  };
25
25
  exports.CAASubServices = CAASubServices;
26
26
  __decorate([
27
- (0, typeorm_1.Column)({ nullable: true, unique: true }),
27
+ (0, typeorm_1.Column)({ type: 'varchar', length: 64, nullable: true, unique: true }),
28
28
  __metadata("design:type", Object)
29
29
  ], CAASubServices.prototype, "code", void 0);
30
30
  __decorate([
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@platform-modules/civil-aviation-authority",
3
- "version": "1.0.20",
3
+ "version": "1.0.21",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "scripts": {
@@ -5,8 +5,8 @@ import { BaseModel } from './BaseModel';
5
5
  @Entity({ name: 'caa_services' })
6
6
  export class CAAServices extends BaseModel {
7
7
 
8
- @Column({ nullable: true, unique: true })
9
- code: string | null;
8
+ @Column({ type: 'varchar', length: 64, nullable: false, unique: true })
9
+ code: string;
10
10
 
11
11
  @Column({ nullable: false })
12
12
  name: string;
@@ -21,12 +21,12 @@ export class CAAServices extends BaseModel {
21
21
  name: string,
22
22
  description: string,
23
23
  logo_url: string,
24
- code: string | null = null
24
+ code?: string
25
25
  ) {
26
26
  super();
27
27
  this.name = name
28
28
  this.description = description
29
29
  this.logo_url = logo_url
30
- this.code = code
30
+ this.code = code || ''
31
31
  }
32
32
  }
@@ -5,7 +5,7 @@ import { BaseModel } from './BaseModel';
5
5
  @Entity({ name: 'caa_sub_services' })
6
6
  export class CAASubServices extends BaseModel {
7
7
 
8
- @Column({ nullable: true, unique: true })
8
+ @Column({ type: 'varchar', length: 64, nullable: true, unique: true })
9
9
  code: string | null;
10
10
 
11
11
  @Column({ nullable: false })