no message

This commit is contained in:
annabakouli 2017-12-22 16:30:15 +02:00
parent 5a79779335
commit 9af2be155b
3 changed files with 11 additions and 11 deletions

View File

@ -112,7 +112,7 @@ export class DatasetWizardComponent implements AfterViewInit {
formSubmit(): void {
//this.touchAllFormFields(this.formGroup);
if(this.isNew)return;
//if(this.isNew)return;
if (!this.isFormValid()) { return; }
this.onSubmit();
}

View File

@ -1,14 +1,14 @@
<div class="ui-g dynamic-formc full-width full-height">
<mat-sidenav-container contentClass="scrollableContent">
<mat-sidenav mode="push" position="right" [(opened)]="visibleSidebar">
<table-of-content class="toc-container full-height" [model]="dataModel"></table-of-content>
<table-of-content class="toc-container full-height" [model]="datasetProfileDefinitionModel"></table-of-content>
</mat-sidenav>
<mat-sidenav-content class="ui-g">
<button type="button" style="margin: 15px;" class="btn btn-primary" (click)="toggleSidebar()" icon="fa-arrow-left">Table Of Contents</button>
<button type="button" *ngIf="dataModel&&dataModel.status != 1" style="margin-top: 15px;margin-bottom: 15px;margin-right: 15px;"
<button type="button" *ngIf="datasetProfileDefinitionModel&&datasetProfileDefinitionModel.status != 1" style="margin-top: 15px;margin-bottom: 15px;margin-right: 15px;"
class="btn btn-primary" type="button" (click)="save();">Save</button>
<button type="button" *ngIf="dataModel&&dataModel?.status != 1" style="margin-top: 15px;margin-bottom: 15px;margin-right: 15px;"
<button type="button" *ngIf="datasetProfileDefinitionModel&&datasetProfileDefinitionModel?.status != 1" style="margin-top: 15px;margin-bottom: 15px;margin-right: 15px;"
class="btn btn-primary" (click)="submit();">Save and Finalize</button>
<div class="ui-g-12">
<div class="alignment-center">
@ -21,7 +21,7 @@
<div class="col-md-12 form-body-container" id="form-container">
<form *ngIf="form" novalidate [formGroup]="form" (ngSubmit)="onSubmit()">
<div *ngFor="let section of dataModel.sections; let i = index;">
<div *ngFor="let section of datasetProfileDefinitionModel.sections; let i = index;">
<df-section *ngIf='this.shouldDisplaySection(section)' [section]="section" [form]="form.get('sections').get(''+i)" [path]="i+1"
[pathName]="'sections.'+i"></df-section>
</div>

View File

@ -37,7 +37,7 @@ export class DynamicFormComponent implements OnInit {
pages: Array<number>;
activeStepperIndex: number = 1;
visibleSidebar: boolean = false;
datasetProfileDefinitionModel: DatasetProfileDefinitionModel
private progressbar: boolean = false;
private currentPageIndex: number = 0;
@ -56,13 +56,13 @@ export class DynamicFormComponent implements OnInit {
ngOnInit() {
let datasetProfileDefinitionModel: DatasetProfileDefinitionModel = this.dataModel.datasetProfileDefinition
this.pages = this.getPages(datasetProfileDefinitionModel);
this.datasetProfileDefinitionModel = this.dataModel.datasetProfileDefinition
this.pages = this.getPages(this.datasetProfileDefinitionModel);
this.createPagination();
this.form = datasetProfileDefinitionModel.buildForm();
this.form = this.datasetProfileDefinitionModel.buildForm();
this.visibilityRulesService.formGroup = this.form;
//let rules: Rule[] = new JsonSerializer<Rule>().fromJSONArray(response.rules, Rule);
//this.visibilityRulesService.buildVisibilityRules(rules)
let rules: Rule[] = new JsonSerializer<Rule>().fromJSONArray(this.datasetProfileDefinitionModel.rules, Rule);
this.visibilityRulesService.buildVisibilityRules(rules)
this.progressbar = true;
this.route.fragment.subscribe((fragment: string) => {