Creating a new App Page with the same name as another page causes PSU to replace the existing page

Creating a new App Page with the same name as another page causes PSU to replace the existing page

avatar

When creating pages within an app, if there is already a page existing with that name PSU will overwrite the existing page code with the standard new template page. The PSU also starts to freeze at this point until the service is restarted.

I believe PSU is replacing the .ps1 file in Repository\dashboards\[Appname]\pages[pagename].ps1
Where [pagename].ps1 is being replaced with a standard template.

Steps to reproduce:

  • Have an existing page with code that is different than the template. E.g: page name is Test
  • Click "Create App Page"
  • Enter "Test" as the name. URL can be anything
  • After creation, PSU has replaced test.ps1 with a template.
  • PSU is now freezing on the Pages tab of the App.


Suggested resolution:

-Check if .ps1 exists before replacing.

-Inform user that it already exists with a dialog and ask if they want to rename or if they want to continue to replace the .ps1 file / page.


All Comments (1)

avatar

@wutzanspm Thanks for the details. I've opened an issue to track it. I'll let you know if we need any more information.

Adam Driscoll
PowerShell Expert and Developer at Devolutions