From 1516547a3e4f8f7aa6362901dcdeb038b701f371 Mon Sep 17 00:00:00 2001 From: Martin Hamernik <445720@mail.muni.cz> Date: Wed, 8 Jul 2020 11:30:37 +0200 Subject: [PATCH] Remove dependency on kypo-common --- package-lock.json | 15 --------------- package.json | 1 - projects/kypo-sandbox-model/package.json | 3 +-- .../src/lib/pool-request/request.ts | 11 +---------- .../stage/networking-ansible-allocation-stage.ts | 1 - .../stage/user-ansible-allocation-stage.ts | 1 - 6 files changed, 2 insertions(+), 30 deletions(-) diff --git a/package-lock.json b/package-lock.json index 91c46d5..47f82e7 100644 --- a/package-lock.json +++ b/package-lock.json @@ -9092,21 +9092,6 @@ "integrity": "sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw==", "dev": true }, - "kypo-common": { - "version": "10.0.0", - "resolved": "https://nexus.csirt.muni.cz/repository/kypo-npm-group/kypo-common/-/kypo-common-10.0.0.tgz", - "integrity": "sha512-IpFj3GBFVgMaXZ2vvToT0xouaKwDKgkR2clL9NWralaU5QkarZtEy5N3GeMbRR5WUFvXF8Af0ycYI/TAM45/Pg==", - "requires": { - "tslib": "^2.0.0" - }, - "dependencies": { - "tslib": { - "version": "2.0.0", - "resolved": "https://nexus.csirt.muni.cz/repository/kypo-npm-group/tslib/-/tslib-2.0.0.tgz", - "integrity": "sha512-lTqkx847PI7xEDYJntxZH89L2/aXInsyF2luSafe/+0fHOMjlBNXdH6th7f70qxLDhul7KZK0zC8V5ZIyHl0/g==" - } - } - }, "latest-version": { "version": "5.1.0", "resolved": "http://kypo-storage.ics.muni.cz:8081/repository/npm-group/latest-version/-/latest-version-5.1.0.tgz", diff --git a/package.json b/package.json index af269c2..19fdb41 100644 --- a/package.json +++ b/package.json @@ -27,7 +27,6 @@ "@angular/platform-browser": "~10.0.0", "@angular/platform-browser-dynamic": "~10.0.0", "@angular/router": "~10.0.0", - "kypo-common": "~10.0.0", "rxjs": "~6.5.4", "tslib": "^2.0.0", "zone.js": "~0.10.2" diff --git a/projects/kypo-sandbox-model/package.json b/projects/kypo-sandbox-model/package.json index 08e6774..7d3ead4 100644 --- a/projects/kypo-sandbox-model/package.json +++ b/projects/kypo-sandbox-model/package.json @@ -3,8 +3,7 @@ "version": "10.1.0", "peerDependencies": { "@angular/common": "^10.0.0", - "@angular/core": "^10.0.0", - "kypo-common": "~10.0.0" + "@angular/core": "^10.0.0" }, "dependencies": { "tslib": "^2.0.0" diff --git a/projects/kypo-sandbox-model/src/lib/pool-request/request.ts b/projects/kypo-sandbox-model/src/lib/pool-request/request.ts index 7a42174..278c5ca 100644 --- a/projects/kypo-sandbox-model/src/lib/pool-request/request.ts +++ b/projects/kypo-sandbox-model/src/lib/pool-request/request.ts @@ -1,22 +1,13 @@ -import { KypoDateTimeFormatPipe } from 'kypo-common'; - /** * Class representing pool request */ export abstract class Request { id: number; allocationUnitId: number; - createdAtFormatted: string; + createdAt: Date; readonly type: string; - private _createdAt: Date; protected constructor(type: string) { this.type = type; } - - set createdAt(value: Date) { - this._createdAt = value; - const dateTimeFormatter = new KypoDateTimeFormatPipe('en-EN'); - this.createdAtFormatted = dateTimeFormatter.transform(value); - } } diff --git a/projects/kypo-sandbox-model/src/lib/pool-request/stage/networking-ansible-allocation-stage.ts b/projects/kypo-sandbox-model/src/lib/pool-request/stage/networking-ansible-allocation-stage.ts index cfe0247..d46bfcc 100644 --- a/projects/kypo-sandbox-model/src/lib/pool-request/stage/networking-ansible-allocation-stage.ts +++ b/projects/kypo-sandbox-model/src/lib/pool-request/stage/networking-ansible-allocation-stage.ts @@ -1,4 +1,3 @@ -import { KypoPaginatedResource } from 'kypo-common'; import { RequestStageType } from '../../enums/request-stage-type.enum'; import { AllocationRequestStage } from './allocation-request-stage'; diff --git a/projects/kypo-sandbox-model/src/lib/pool-request/stage/user-ansible-allocation-stage.ts b/projects/kypo-sandbox-model/src/lib/pool-request/stage/user-ansible-allocation-stage.ts index a3cb41e..55143b1 100644 --- a/projects/kypo-sandbox-model/src/lib/pool-request/stage/user-ansible-allocation-stage.ts +++ b/projects/kypo-sandbox-model/src/lib/pool-request/stage/user-ansible-allocation-stage.ts @@ -1,4 +1,3 @@ -import { KypoPaginatedResource } from 'kypo-common'; import { RequestStageType } from '../../enums/request-stage-type.enum'; import { AllocationRequestStage } from './allocation-request-stage'; -- GitLab