One of cleanup (#71)

* raw json obj validation, unreliable submit

* fix defaults not appearing in deployment extras

* version++

* disable testing when new rule or rule not valid

* update version

* support raw json object

* cleanup

* change from 'event' to 'test_specification'

* version++

* test suite fix

* new centrifuge prototype

* fix git ignore

* save changes

* working version

* working changes

* resolve conflicts

* move services, cleanup, oneOf working

* clean up effects, diff bug

* pr fixes

* remove package lock

* update gitignore
This commit is contained in:
Thomas Gilgan
2020-04-08 16:26:21 +01:00
committed by GitHub Enterprise
parent 6baf157993
commit e4cc7c8fd0
30 changed files with 1257 additions and 15490 deletions

View File

@@ -6,11 +6,11 @@ import { StatusCode } from '@app/commons';
import { FormGroup } from '@angular/forms';
import { AppConfigService } from '@app/config';
import { EditorService } from '@app/editor.service';
import { EditorService } from '@services/editor.service';
import { ConfigData, ConfigWrapper, Deployment } from '@app/model';
import { FormlyJsonschema } from '@app/ngx-formly/formly-json-schema.service';
import { Store } from '@ngrx/store';
import { FormlyFieldConfig, FormlyFormOptions } from '@ngx-formly/core';
import { FormlyJsonschema } from '@ngx-formly/core/json-schema';
import * as fromStore from 'app/store';
import { cloneDeep } from 'lodash';
import { Observable } from 'rxjs';
@@ -57,7 +57,7 @@ export class DeployDialogComponent {
if (this.uiMetadata.deployment.extras !== undefined) {
this.fields = [this.formlyJsonSchema.toFieldConfig(this.createDeploymentSchema(r))];
} else {
this.service.getLoader(this.serviceName).validateRelease(data).pipe(take(1))
this.service.configLoader.validateRelease(data).pipe(take(1))
.subscribe(s => {
if (s !== undefined) {
this.statusCode = s.status_code;
@@ -78,7 +78,7 @@ export class DeployDialogComponent {
}
private createDeploymentSchema(serviceName: string): string {
const depSchema = this.service.getLoader(serviceName).originalSchema;
const depSchema = this.service.configLoader.originalSchema;
depSchema.properties[this.uiMetadata.deployment.config_array] = {};
delete depSchema.properties[this.uiMetadata.deployment.config_array];
delete depSchema.properties[this.uiMetadata.deployment.version];
@@ -95,7 +95,7 @@ export class DeployDialogComponent {
onValidate() {
this.deployment = {...this.deployment, ...this.extrasData};
this.service.getLoader(this.serviceName)
this.service.configLoader
.validateRelease(this.deployment).pipe(take(1)).subscribe(s => {
if (s !== undefined) {
this.statusCode = s.status_code;