Merge branch 'master' of gitlab.eudat.eu:dmp/OpenAIRE-EUDAT-DMP-service-pilot

This commit is contained in:
annampak 2017-11-07 12:29:05 +02:00
commit da6c98cacd
3 changed files with 18 additions and 44 deletions

View File

@ -53,6 +53,7 @@ CREATE TABLE "DMP" (
"Status" smallint not null default 0,
"Created" timestamp not null default NOW(),
"Modified" timestamp not null default NOW(),
"Description" text,
"Profile" uuid
);
@ -118,6 +119,7 @@ CREATE TABLE "Dataset" (
"Status" smallint not null default 0,
"Created" timestamp not null default NOW(),
"Modified" timestamp not null default NOW(),
"Description" text,
"Profile" uuid
);
@ -139,6 +141,7 @@ CREATE TABLE "DatasetProfile" (
"Status" smallint not null default 0,
"Created" timestamp not null default NOW(),
"Modified" timestamp not null default NOW(),
"Description" text,
"Definition" xml NOT NULL
);
@ -216,6 +219,7 @@ CREATE TABLE "Project" (
"Modified" timestamp not null default NOW(),
"StartDate" timestamp,
"EndDate" timestamp,
"Description" text,
"Definition" xml
);

View File

@ -73,15 +73,7 @@ export class DatasetsComponent implements OnInit {
private route: ActivatedRoute,
private router: Router,
private ngZone: NgZone) {
this.dataset = {
id: null,
label: '',
reference: '',
uri: '',
properties: '',
profile: { "id": '' },
dmp: { "id": '' }
}
this.dataset = this.createEmptyDataset();
this.datasetProfileDropDown = new DropdownField();
this.datasetProfileDropDown.options = [];
@ -114,6 +106,17 @@ export class DatasetsComponent implements OnInit {
)
}
createEmptyDataset(){
return {
id: null,
label: '',
reference: '',
uri: '',
properties: '',
profile: { "id": '' },
dmp: { "id": '' }
}
}
SaveDataset(){
if(this.dataset.id ==null){
@ -180,10 +183,9 @@ export class DatasetsComponent implements OnInit {
}
newDataset() {
this.dataset.label = "";
this.dataset.uri = "";
this.dataset = this.createEmptyDataset();
this.dataset.dmp =this.dmpLabelforDatasets;
this.dataset.profile = "";
this.dataset.status = 0;
$("#newDatasetModal").modal("show");
}

View File

@ -1,32 +0,0 @@
/*
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { FormsModule } from '@angular/forms';
//import {DataTableModule } from 'angular-4-data-table-bootstrap-4';
import {DataTableModule} from 'angular2-datatable';
import { DmpComponent } from './dmp.component';
import { DmpTableFilterPipe } from '../pipes/dmp-table-filter.pipe';
import { DmpVersionFilterPipe } from '../pipes/dmp-version-filter.pipe';
import { DmpRoutingModule } from './dmp-routing.module';
import { DatasetsModule } from '../datasets/dataset.module';
@NgModule({
imports: [
CommonModule,
FormsModule,
DmpRoutingModule,
DataTableModule,
DatasetsModule
],
declarations: [
DmpTableFilterPipe,
DmpVersionFilterPipe,
DmpComponent
],
providers: [ ]
})
export class DmpModule {}
*/