You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@nifi.apache.org by "mcgilman (via GitHub)" <gi...@apache.org> on 2024/05/03 13:22:08 UTC
[PR] NIFI-13136: Allowing users to unset optional property values [nifi]
mcgilman opened a new pull request, #8734:
URL: https://github.com/apache/nifi/pull/8734
NIFI-13136:
- Allowing users to unset optional property values.
- Only selecting value and applying focus if it is not read only.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@nifi.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] NIFI-13136: Allowing users to unset optional property values [nifi]
Posted by "rfellows (via GitHub)" <gi...@apache.org>.
rfellows commented on PR #8734:
URL: https://github.com/apache/nifi/pull/8734#issuecomment-2093097636
reviewing...
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@nifi.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] NIFI-13136: Allowing users to unset optional property values [nifi]
Posted by "rfellows (via GitHub)" <gi...@apache.org>.
rfellows commented on code in PR #8734:
URL: https://github.com/apache/nifi/pull/8734#discussion_r1589291907
##########
nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-frontend/src/main/nifi/src/app/ui/common/property-table/editors/nf-editor/nf-editor.component.ts:
##########
@@ -207,8 +218,18 @@ export class NfEditor implements OnDestroy {
okClicked(): void {
const valueControl: AbstractControl | null = this.nfEditorForm.get('value');
- if (valueControl) {
- this.ok.next(valueControl.value);
+ const emptyStringChecked: AbstractControl | null = this.nfEditorForm.get('setEmptyString');
+ if (valueControl && emptyStringChecked) {
+ const value = valueControl.value;
+ if (value === '') {
+ if (emptyStringChecked.value) {
+ this.ok.next('');
+ } else {
+ this.ok.next(null);
+ }
+ } else {
+ this.ok.next(value);
+ }
Review Comment:
Not sure where else to leave this comment, but we need to prevent `Enter` from submitting the okClicked action if the form is invalid (required value not entered)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@nifi.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] NIFI-13136: Allowing users to unset optional property values [nifi]
Posted by "rfellows (via GitHub)" <gi...@apache.org>.
rfellows merged PR #8734:
URL: https://github.com/apache/nifi/pull/8734
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@nifi.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org