Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -270,12 +270,6 @@ public void setRelationships(final Collection<Relationship> newRelationships) {
return;
}

try {
getSource().verifyCanUpdate();
} catch (final IllegalStateException ise) {
throw new IllegalStateException("Cannot update the relationships for Connection", ise);
}

try {
this.relationships.set(new ArrayList<>(newRelationships));
getSource().updateConnection(this);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,9 @@
-->

<h2 mat-dialog-title>
{{ connectionReadonly || sourceReadonly || destinationReadonly ? 'Connection Details' : 'Edit Connection' }}
{{ connectionReadonly
|| sourceReadonly && destinationType != ComponentType.ProcessGroup && destinationType != ComponentType.RemoteProcessGroup
|| destinationReadonly ? 'Connection Details' : 'Edit Connection' }}
</h2>
<form class="edit-connection-form" [formGroup]="editConnectionForm">
<context-error-banner [context]="ErrorContextKey.CONNECTION"></context-error-banner>
Expand Down Expand Up @@ -252,7 +254,9 @@ <h2 mat-dialog-title>
</mat-tab-group>
@if ({ value: (saving$ | async)! }; as saving) {
<mat-dialog-actions align="end">
@if (connectionReadonly || sourceReadonly || destinationReadonly) {
@if (connectionReadonly
|| sourceReadonly && destinationType != ComponentType.ProcessGroup && destinationType != ComponentType.RemoteProcessGroup
|| destinationReadonly) {
<button mat-flat-button mat-dialog-close>Close</button>
} @else {
<button mat-button mat-dialog-close="CANCELLED">Cancel</button>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -302,7 +302,9 @@ export class EditConnectionComponent extends TabbedDialog {
}

updateControlValueAccessorsForReadOnly(): void {
const disabled = this.connectionReadonly || this.sourceReadonly || this.destinationReadonly;
const disabled = this.connectionReadonly
|| this.sourceReadonly && this.destinationType != ComponentType.ProcessGroup && this.destinationType != ComponentType.RemoteProcessGroup
|| this.destinationReadonly;

// sourceReadonly is used to update the readonly / disable state of the form controls, note that
// the source control for local and remote groups is always disabled (see above) in this edit
Expand Down