Altinn / altinn-studio

Next generation open source Altinn platform and applications.
https://docs.altinn.studio
BSD 3-Clause "New" or "Revised" License
115 stars 70 forks source link

ServiceName key in text resources is retained when changing app name in designer #7960

Closed jeevananthank closed 1 year ago

jeevananthank commented 2 years ago

Description

Changes are made to use appName as key for getting app names from the text resources. On apps with ServiceName key in text resources, when one changes app name from the about page of the app, the key and value of ServiceName is not deleted and both appName and ServiceName exists in the text resources.

issue 2

config.json is app root folder continues to have ServiceName (not sure what this is used for).

To Reproduce

  1. Open an old app with ServiceName key in the text resources
  2. Change the app name from the about page of the app.
  3. push the changes
  4. from the text resources json, it can be found that ServiceName key and value are not deleted.

Note: existence of ServiceName in addition to appName, is making trouble with platform receipt and the messagebox, where the value in ServiceName is displayed. receipt pdf generated has the value from ServiceName key.

Expected behavior

serviceName key and value should be removed from text resources.

Additional info

end: dev studio app: jeeva/app-2021

jeevananthank commented 2 years ago

when both of these are solved, priority of solving the issue with designer that it retains ServiceName key can be less prioritized.

ivarne commented 2 years ago

Not sure I understand the issue correctly, but it seems to me that the text resource ServiceName is deprecated in favor of appName, and that probably means the pdf filename should be updated to use appName first.

https://github.com/altinn/altinn-studio/blob/a43ac4f3b232965e20880eee57d5eb69c78ca8d7/src/Altinn.Apps/AppTemplates/AspNet/Altinn.App.PlatformServices/Implementation/AppBase.cs#L519

jeevananthank commented 2 years ago

@ivarne agree that name of the receipt pdf has to be changed so it uses appName for apps where the key exists. @lorang92 FYI

acn-sbuad commented 1 year ago

Not sure if this is still an issue, but assigning team/studio as this is an issue with designer

standeren commented 1 year ago

Not considered necessary to fix