summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorShaabanEltanany <shaaban.eltanany.ext@orange.com>2020-09-14 11:22:29 +0200
committerShaabanEltanany <shaaban.eltanany.ext@orange.com>2020-09-14 11:22:29 +0200
commit7eaca1fd68638e301e12b565036f4ba76800e710 (patch)
tree6c7f63114dafef8ade2cfb26a3899383b8618be4
parented5ccd2c544eb0da85342bc64308363997b3747f (diff)
change beahvior of edit
enable editing in package version only Issue-ID: CCSDK-2336 Signed-off-by: ShaabanEltanany <shaaban.eltanany.ext@orange.com> Change-Id: I5878b463f08dc3575ea90cd65611389eacbb8b4f
-rw-r--r--cds-ui/designer-client/src/app/modules/feature-modules/packages/configuration-dashboard/configuration-dashboard.component.ts5
-rw-r--r--cds-ui/designer-client/src/app/modules/feature-modules/packages/package-creation/metadata-tab/metadata-tab.component.html2
-rw-r--r--cds-ui/designer-client/src/app/modules/feature-modules/packages/package-creation/metadata-tab/metadata-tab.component.ts3
-rw-r--r--cds-ui/designer-client/src/app/modules/feature-modules/packages/packages-dashboard/filter-by-tags/filter-by-tags.component.ts1
4 files changed, 7 insertions, 4 deletions
diff --git a/cds-ui/designer-client/src/app/modules/feature-modules/packages/configuration-dashboard/configuration-dashboard.component.ts b/cds-ui/designer-client/src/app/modules/feature-modules/packages/configuration-dashboard/configuration-dashboard.component.ts
index 09434bc17..42b7af9a5 100644
--- a/cds-ui/designer-client/src/app/modules/feature-modules/packages/configuration-dashboard/configuration-dashboard.component.ts
+++ b/cds-ui/designer-client/src/app/modules/feature-modules/packages/configuration-dashboard/configuration-dashboard.component.ts
@@ -169,10 +169,11 @@ export class ConfigurationDashboardComponent extends ComponentCanDeactivate impl
}
editBluePrint() {
- if (this.cbaPackage) {
+ this.configurationDashboardService.deletePackage(this.viewedPackage.id).subscribe(res => {
this.formTreeData();
this.saveBluePrintToDataBase();
- }
+
+ });
}
private formTreeData() {
diff --git a/cds-ui/designer-client/src/app/modules/feature-modules/packages/package-creation/metadata-tab/metadata-tab.component.html b/cds-ui/designer-client/src/app/modules/feature-modules/packages/package-creation/metadata-tab/metadata-tab.component.html
index 2c98d206a..16bf7fccd 100644
--- a/cds-ui/designer-client/src/app/modules/feature-modules/packages/package-creation/metadata-tab/metadata-tab.component.html
+++ b/cds-ui/designer-client/src/app/modules/feature-modules/packages/package-creation/metadata-tab/metadata-tab.component.html
@@ -33,7 +33,7 @@
<div class="single-line-model">
<label class="label-name">Name <span>*</span></label>
<div class="label-input">
- <input tourAnchor="mt-packageName" type="input" (change)="checkRequiredElements()"
+ <input tourAnchor="mt-packageName" type="input" [readOnly]="!isNameEditable" (change)="checkRequiredElements()"
[(ngModel)]="metaDataTab.name" placeholder="Package name">
</div>
<!--<div class="model-note-container error-message">
diff --git a/cds-ui/designer-client/src/app/modules/feature-modules/packages/package-creation/metadata-tab/metadata-tab.component.ts b/cds-ui/designer-client/src/app/modules/feature-modules/packages/package-creation/metadata-tab/metadata-tab.component.ts
index af5b875f7..0e809674a 100644
--- a/cds-ui/designer-client/src/app/modules/feature-modules/packages/package-creation/metadata-tab/metadata-tab.component.ts
+++ b/cds-ui/designer-client/src/app/modules/feature-modules/packages/package-creation/metadata-tab/metadata-tab.component.ts
@@ -23,6 +23,7 @@ export class MetadataTabComponent implements OnInit {
metaDataTab: MetaDataTabModel = new MetaDataTabModel();
errorMessage: string;
versionPattern = '^(\\d+\\.)?(\\d+\\.)?(\\*|\\d+)$';
+ isNameEditable = false;
constructor(
private route: ActivatedRoute,
@@ -36,7 +37,7 @@ export class MetadataTabComponent implements OnInit {
this.metaDataTab.templateTags = this.tags;
this.metaDataTab.mapOfCustomKey = this.customKeysMap;
this.metaDataTab.mode = this.modeType;
-
+ this.isNameEditable = this.route.snapshot.paramMap.get('id') == null;
this.packageCreationStore.state$.subscribe(element => {
if (element && element.metaData) {
diff --git a/cds-ui/designer-client/src/app/modules/feature-modules/packages/packages-dashboard/filter-by-tags/filter-by-tags.component.ts b/cds-ui/designer-client/src/app/modules/feature-modules/packages/packages-dashboard/filter-by-tags/filter-by-tags.component.ts
index 0555fd5ab..6f02bbab8 100644
--- a/cds-ui/designer-client/src/app/modules/feature-modules/packages/packages-dashboard/filter-by-tags/filter-by-tags.component.ts
+++ b/cds-ui/designer-client/src/app/modules/feature-modules/packages/packages-dashboard/filter-by-tags/filter-by-tags.component.ts
@@ -114,6 +114,7 @@ export class TagsFilteringComponent implements OnInit {
this.checkBoxTages = '';
this.checkboxes.forEach((element) => {
element.nativeElement.checked = false;
+ this.packagesStore.getAll();
});
}
}