You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ofbiz.apache.org by "pandeypranay (via GitHub)" <gi...@apache.org> on 2026/10/08 10:05:34 UTC
[PR] Improved: Auto-generated indicator (Y/N) fields silently default to "Y" and overwrite a NULL value on unrelated form saves (OFBIZ-13503) [ofbiz-framework]
pandeypranay opened a new pull request, #2239:
URL: https://github.com/apache/ofbiz-framework/pull/2239
Auto-generated create/update forms rendered indicator (Y/N) fields as a drop-down with only "Y" and "N" options. For a nullable column holding NULL, the browser preselected "Y", so saving any unrelated field on the form silently persisted "Y" (e.g. ProductStore.allocateInventory). OFBIZ-12001 addressed this for allocateInventory only; this change applies to every auto-generated indicator field.
Changes:
- ModelFormFieldBuilder: indicator drop-downs on non-find forms now get a blank option when the entity field is nullable. Not-null fields keep only Y/N. Find forms already had the blank option and are unchanged.
- GenericEntity.set(): an empty string set on an indicator field is now stored as null, so selecting the blank option persists NULL rather than an empty string.
Side effects:
- Setting "" on a NOT NULL indicator field through GenericEntity.set() now results in null and the store fails, instead of saving an empty value. Auto-generated forms never submit a blank for such fields; only hand-written forms or services passing "" would be affected.
--
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: notifications-unsubscribe@ofbiz.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Improved: Auto-generated indicator (Y/N) fields silently default to "Y" and overwrite a NULL value on unrelated form saves (OFBIZ-13503) [ofbiz-framework]
Posted by "pandeypranay (via GitHub)" <gi...@apache.org>.
pandeypranay merged PR #2239:
URL: https://github.com/apache/ofbiz-framework/pull/2239
--
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: notifications-unsubscribe@ofbiz.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org