Aug 18 2022 07:14 AM - edited Aug 18 2022 07:59 AM
My company uses Project Online and I’ve been asked to change the name of the Owner field to Project Manager. I believe there is no way to change the actual column name (can anyone confirm?), so I’m attempting to change how it is displayed on pages using JavaScript. I’ve managed to accomplish this on the Project Details page using the following code placed in a Script Editor web part.
<script type="text/javascript">var xpath = "//h3[contains(text(),'Owner')]";var matchingElement = document.evaluate(xpath, document, null, XPathResult.FIRST_ORDERED_NODE_TYPE, null).singleNodeValue;matchingElement.innerText = matchingElement.innerText.replace("Owner","Project Manager");</script>
I'm attempting to do this on the Project Center page, and it works on initial page load, but if you change the view, of course, it does not update. I've been struggling to find a way to add an event listener, hopefully for an event on the grid when it changes, but I have yet to discover an event that can be used.
Has anyone attempted anything like this with Project Online or am I going about this the wrong way?
Aug 18 2022 07:42 AM
Aug 18 2022 08:00 AM - edited Aug 18 2022 08:00 AM
Thanks for the confirmation Dale. I assumed that was the case, which is why I'm attempting to modify how it appears on the page using JavaScript.
Aug 18 2022 02:45 PM
As you have found @mike-ott , custom JavaScript will be the solution on the PDP's. For the project center view you have an out of the box option using the Custom Labels on the view creation:
Repeat for all Project Center views.
Paul