mirror of https://github.com/apache/nifi.git
NIFI-4436:
- Minor tweak to when the max height for the options list is calculated per PR comments. - Resolving logic issue in two phase commit when updating variable registry. - Fixing variable visibility.
This commit is contained in:
parent
f702f808a7
commit
fa996cd418
|
@ -620,7 +620,7 @@ public class ProcessGroupResource extends ApplicationResource {
|
||||||
final VariableRegistryDTO requestRegistryDto = requestVariableRegistryEntity.getVariableRegistry();
|
final VariableRegistryDTO requestRegistryDto = requestVariableRegistryEntity.getVariableRegistry();
|
||||||
if (!groupId.equals(requestRegistryDto.getProcessGroupId())) {
|
if (!groupId.equals(requestRegistryDto.getProcessGroupId())) {
|
||||||
throw new IllegalArgumentException(String.format("The process group id (%s) in the request body does "
|
throw new IllegalArgumentException(String.format("The process group id (%s) in the request body does "
|
||||||
+ "not equal the process group id of the requested resource (%s).", registryDto.getProcessGroupId(), groupId));
|
+ "not equal the process group id of the requested resource (%s).", requestRegistryDto.getProcessGroupId(), groupId));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (isReplicateRequest()) {
|
if (isReplicateRequest()) {
|
||||||
|
|
|
@ -1590,12 +1590,12 @@ public class VersionsResource extends ApplicationResource {
|
||||||
|
|
||||||
|
|
||||||
private static class InitiateChangeFlowVersionRequestWrapper extends Entity {
|
private static class InitiateChangeFlowVersionRequestWrapper extends Entity {
|
||||||
final VersionControlInformationEntity versionControlInformationEntity;
|
private final VersionControlInformationEntity versionControlInformationEntity;
|
||||||
final ComponentLifecycle componentLifecycle;
|
private final ComponentLifecycle componentLifecycle;
|
||||||
final URI exampleUri;
|
private final URI exampleUri;
|
||||||
final Set<AffectedComponentEntity> affectedComponents;
|
private final Set<AffectedComponentEntity> affectedComponents;
|
||||||
final boolean replicateRequest;
|
private final boolean replicateRequest;
|
||||||
final VersionedFlowSnapshot flowSnapshot;
|
private final VersionedFlowSnapshot flowSnapshot;
|
||||||
|
|
||||||
public InitiateChangeFlowVersionRequestWrapper(final VersionControlInformationEntity versionControlInformationEntity, final ComponentLifecycle componentLifecycle,
|
public InitiateChangeFlowVersionRequestWrapper(final VersionControlInformationEntity versionControlInformationEntity, final ComponentLifecycle componentLifecycle,
|
||||||
final URI exampleUri, final Set<AffectedComponentEntity> affectedComponents, final boolean replicateRequest,
|
final URI exampleUri, final Set<AffectedComponentEntity> affectedComponents, final boolean replicateRequest,
|
||||||
|
|
|
@ -176,6 +176,10 @@
|
||||||
if (maxHeight > 0) {
|
if (maxHeight > 0) {
|
||||||
comboOptions.css('max-height', maxHeight + 'px');
|
comboOptions.css('max-height', maxHeight + 'px');
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
var windowHeight = $(window).height();
|
||||||
|
maxHeight = windowHeight - (position.top + Math.round(combo.outerHeight())) - 32;
|
||||||
|
comboOptions.css('max-height', maxHeight + 'px');
|
||||||
}
|
}
|
||||||
|
|
||||||
// create the list that will contain the options
|
// create the list that will contain the options
|
||||||
|
|
|
@ -214,14 +214,8 @@
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
// determine the max registry height
|
|
||||||
var windowHeight = $(window).height();
|
|
||||||
var registryOffset = $('#import-flow-version-registry-combo').offset();
|
|
||||||
var registryMaxHeight = windowHeight - registryOffset.top - 64;
|
|
||||||
|
|
||||||
// load the registries
|
// load the registries
|
||||||
registryCombo.combo({
|
registryCombo.combo({
|
||||||
maxHeight: registryMaxHeight,
|
|
||||||
options: registries,
|
options: registries,
|
||||||
select: function (selectedOption) {
|
select: function (selectedOption) {
|
||||||
selectRegistry(dialog, selectedOption, bucketCombo, flowCombo, selectBucket, bucketCheck)
|
selectRegistry(dialog, selectedOption, bucketCombo, flowCombo, selectBucket, bucketCheck)
|
||||||
|
@ -296,14 +290,8 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// determine the max bucket height
|
|
||||||
var windowHeight = $(window).height();
|
|
||||||
var bucketOffset = $('#import-flow-version-bucket-combo').offset();
|
|
||||||
var bucketMaxHeight = windowHeight - bucketOffset.top - 64;
|
|
||||||
|
|
||||||
// load the buckets
|
// load the buckets
|
||||||
bucketCombo.combo('destroy').combo({
|
bucketCombo.combo('destroy').combo({
|
||||||
maxHeight: bucketMaxHeight,
|
|
||||||
options: buckets,
|
options: buckets,
|
||||||
select: selectBucket
|
select: selectBucket
|
||||||
});
|
});
|
||||||
|
@ -902,14 +890,8 @@
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
// determine the max flow height
|
|
||||||
var windowHeight = $(window).height();
|
|
||||||
var flowOffset = $('#import-flow-version-name-combo').offset();
|
|
||||||
var flowMaxHeight = windowHeight - flowOffset.top - 64;
|
|
||||||
|
|
||||||
// load the buckets
|
// load the buckets
|
||||||
$('#import-flow-version-name-combo').combo('destroy').combo({
|
$('#import-flow-version-name-combo').combo('destroy').combo({
|
||||||
maxHeight: flowMaxHeight,
|
|
||||||
options: versionedFlows,
|
options: versionedFlows,
|
||||||
select: function (selectedFlow) {
|
select: function (selectedFlow) {
|
||||||
if (nfCommon.isDefinedAndNotNull(selectedFlow.value)) {
|
if (nfCommon.isDefinedAndNotNull(selectedFlow.value)) {
|
||||||
|
|
Loading…
Reference in New Issue