Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
U
uw_ct_service
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
WCMS
uw_ct_service
Commits
fd4a3d6b
Commit
fd4a3d6b
authored
1 year ago
by
Eric Bremner
Browse files
Options
Downloads
Patches
Plain Diff
ISTWCMS-5551: fixing hiding comments for service hours
parent
2a2b2197
No related branches found
No related tags found
2 merge requests
!60
ISTWCMS-6095 Update maxlength settings for title, text fields and link fields...
,
!33
ISTWCMS-5551 update office hours
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
uw_ct_service.module
+2
-2
2 additions, 2 deletions
uw_ct_service.module
with
2 additions
and
2 deletions
uw_ct_service.module
+
2
−
2
View file @
fd4a3d6b
...
...
@@ -97,12 +97,12 @@ function _uw_ct_service_get_location_options(): array {
function
uw_ct_service_form_node_uw_ct_service_form_alter
(
array
&
$form
,
FormStateInterface
$form_state
,
string
$form_id
):
void
{
// Unset the table header for comments in the regular days.
unset
(
$form
[
'field_uw_service_hours'
][
'widget'
][
'office_hours'
][
'value'
][
'#header'
][
'comment'
]);
unset
(
$form
[
'field_uw_service_hours'
][
'widget'
][
'office_hours'
][
0
][
'value'
][
'#header'
][
'comment'
]);
// Step through each of the regular days and remove the comments.
foreach
(
$form
[
'field_uw_service_hours'
][
'widget'
][
'office_hours'
][
0
][
'value'
]
as
$index
=>
$value
)
{
if
(
is_int
(
$index
))
{
$form
[
'field_uw_service_hours'
][
'widget'
][
'office_hours'
][
'value'
][
$index
][
'#field_settings'
][
'comment'
]
=
0
;
$form
[
'field_uw_service_hours'
][
'widget'
][
'office_hours'
][
0
][
'value'
][
$index
][
'#field_settings'
][
'comment'
]
=
0
;
}
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment