Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ChannelForm: Render default values as element values #175

Merged
merged 1 commit into from May 24, 2024

Conversation

raviks789
Copy link
Contributor

Instead of rendering default values as placeholders, render them as element values.

@cla-bot cla-bot bot added the cla/signed CLA is signed by all contributors of a PR label Apr 11, 2024
@raviks789 raviks789 force-pushed the channel-form-render-defaults-as-values branch from 9fe27b7 to b7051ac Compare April 11, 2024 09:53
@raviks789 raviks789 self-assigned this Apr 11, 2024
@raviks789 raviks789 force-pushed the channel-form-render-defaults-as-values branch 2 times, most recently from c66c5b9 to 6fc00d4 Compare April 11, 2024 15:10
@nilmerg nilmerg linked an issue Apr 12, 2024 that may be closed by this pull request
@nilmerg nilmerg added the enhancement New feature or improvement label Apr 12, 2024
@nilmerg nilmerg added this to the Beta milestone Apr 12, 2024
@raviks789 raviks789 force-pushed the channel-form-render-defaults-as-values branch from 6fc00d4 to 4ae51ff Compare April 12, 2024 10:43
@raviks789 raviks789 requested a review from nilmerg April 12, 2024 10:45
application/forms/ChannelForm.php Outdated Show resolved Hide resolved
application/forms/ChannelForm.php Show resolved Hide resolved
@raviks789 raviks789 force-pushed the channel-form-render-defaults-as-values branch from 4ae51ff to 7efdd25 Compare April 12, 2024 13:19
@raviks789 raviks789 requested a review from nilmerg April 12, 2024 13:20
application/forms/ChannelForm.php Outdated Show resolved Hide resolved
application/forms/ChannelForm.php Outdated Show resolved Hide resolved
application/forms/ChannelForm.php Outdated Show resolved Hide resolved
@raviks789 raviks789 force-pushed the channel-form-render-defaults-as-values branch from 7efdd25 to 77275e3 Compare April 12, 2024 13:57
@raviks789 raviks789 force-pushed the channel-form-render-defaults-as-values branch from 77275e3 to bd94f9b Compare April 12, 2024 14:13
Copy link
Member

@nilmerg nilmerg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks fine now. But I don't like the handling of defaults for required elements: Icinga/icinga-notifications#172

@nilmerg nilmerg removed the request for review from sukhwinder33445 April 24, 2024 09:12
@raviks789 raviks789 force-pushed the channel-form-render-defaults-as-values branch 2 times, most recently from 37fcc1c to 98f4f36 Compare May 22, 2024 12:15
Copy link
Member

@nilmerg nilmerg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Default values, that are not adjusted by the user, must not be written to database.

Instead of rendering default values as placeholders, render them as form element values.
@raviks789 raviks789 force-pushed the channel-form-render-defaults-as-values branch from 98f4f36 to 31de5e1 Compare May 24, 2024 08:36
@raviks789 raviks789 requested a review from nilmerg May 24, 2024 08:37
@nilmerg nilmerg merged commit d1a0698 into main May 24, 2024
22 checks passed
@nilmerg nilmerg deleted the channel-form-render-defaults-as-values branch May 24, 2024 09:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla/signed CLA is signed by all contributors of a PR enhancement New feature or improvement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Channel Form: Unexpected default value behavior as placeholder
2 participants