Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
uw_fdsu_theme_resp
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_fdsu_theme_resp
Commits
843e6a14
Commit
843e6a14
authored
3 years ago
by
Eric Bremner
Committed by
Eric Bremner
3 years ago
Browse files
Options
Downloads
Patches
Plain Diff
ISTWCMS-4704: fixing undefined index errors on contacts
parent
e2a04381
No related branches found
No related tags found
1 merge request
!34
ISTWCMS-4847: adding preprocess to main content area to add classes for 404...
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
uw_fdsu_theme_resp.theme
+11
-6
11 additions, 6 deletions
uw_fdsu_theme_resp.theme
with
11 additions
and
6 deletions
uw_fdsu_theme_resp.theme
+
11
−
6
View file @
843e6a14
...
...
@@ -410,6 +410,15 @@ function uw_fdsu_theme_resp_preprocess_node(&$variables) {
// Get the additional info field.
$additional_info
=
$node
->
field_uw_ct_contact_info
->
getValue
();
// If there is additional info, setup render array.
if
(
$additional_info
)
{
$additional_info
=
[
'#type'
=>
'processed_text'
,
'#text'
=>
$additional_info
[
0
][
'value'
],
'#format'
=>
$additional_info
[
0
][
'format'
],
];
}
// Setup the variables for contact.
$variables
[
'contact'
]
=
[
'title'
=>
$node
->
getTitle
(),
...
...
@@ -422,17 +431,13 @@ function uw_fdsu_theme_resp_preprocess_node(&$variables) {
'uri'
=>
$profile
?
$profile
[
0
][
'uri'
]
:
NULL
,
'title'
=>
$profile
?
$profile
[
0
][
'title'
]
:
NULL
,
],
'contact_for'
=>
$node
->
field_uw_ct_contact_for
->
value
,
'contact_for'
=>
$node
->
field_uw_ct_contact_
contact_
for
->
value
,
'personal_website'
=>
[
'uri'
=>
$personal_website
?
$personal_website
[
0
][
'uri'
]
:
NULL
,
'title'
=>
$personal_website
?
$personal_website
[
0
][
'title'
]
:
NULL
,
],
'groups'
=>
$uwService
->
uwGetTermsFromEntityField
(
$node
->
field_uw_ct_contact_group
,
'tags'
),
'additional_info'
=>
[
'#type'
=>
'processed_text'
,
'#text'
=>
$additional_info
[
0
][
'value'
],
'#format'
=>
$additional_info
[
0
][
'format'
],
],
'additional_info'
=>
$additional_info
?
$additional_info
:
NULL
,
];
// Unset the content variable so that we do not
...
...
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