Skip to content

fix(duplicate): projectManager not populated in projectPayloadData on duplicate project page#1560

Open
sujalkalauni wants to merge 10 commits intoeclipse-sw360:mainfrom
sujalkalauni:patch-1
Open

fix(duplicate): projectManager not populated in projectPayloadData on duplicate project page#1560
sujalkalauni wants to merge 10 commits intoeclipse-sw360:mainfrom
sujalkalauni:patch-1

Conversation

@sujalkalauni
Copy link
Copy Markdown

@sujalkalauni sujalkalauni commented Mar 29, 2026

Summary

In DuplicateProject.tsx, the projectManager field was correctly fetched
from the API and stored in local state, but was never assigned in
projectPayloadData — the object actually sent to create the duplicate project.

This meant every duplicated project silently lost its Project Manager.

Fix

Added the missing assignment alongside the existing projectOwner and
leadArchitect fields:

projectManager: project._embedded?.projectManager?.email ?? '',

Related

Fixes #1559

@sujalkalauni sujalkalauni changed the title Update DuplicateProject.tsx fix(duplicate): projectManager not populated in projectPayloadData on duplicate project page Mar 29, 2026
@amritkv
Copy link
Copy Markdown
Member

amritkv commented Mar 30, 2026

Hey @sujalkalauni !
This change doesn't seem to be working.
There are 2 keys for the same field, i.e. ProjectResponsible and ProjectManager. Please check and use the correct one here.

@sujalkalauni
Copy link
Copy Markdown
Author

Thanks for the review @amritkv. I can see both projectResponsible (top-level string) and projectManager (User object in _embedded) in the Project type. I followed the same pattern as leadArchitect and projectOwner which also use _embedded.
Could you help me understand which one maps to the Project Manager field in the UI? Should I use project.projectResponsible instead?

sujalkalauni and others added 6 commits March 30, 2026 16:57
Signed-off-by: Sujal Kalauni <sujal1kalauni@gmail.com>
Signed-off-by: Sujal Kalauni <sujal1kalauni@gmail.com>
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.34.1 to 4.35.1.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](github/codeql-action@3869755...c10b806)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.35.1
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Signed-off-by: Nikesh Kumar <kumar.nikesh@siemens.com>
Signed-off-by: rudra-superrr <prabhuchopra@gmail.com>
@amritkv
Copy link
Copy Markdown
Member

amritkv commented Apr 2, 2026

Hey @sujalkalauni !
Please have a quick look at Add Project and Edit Project files for the clarifications and how the field is handled.

@sujalkalauni
Copy link
Copy Markdown
Author

Thanks @amritkv, checked both AddProject and EditProject. EditProject made it clear that the UI state is named projectManager but the actual API payload key is projectResponsible. Updated the initial state and payload accordingly and cleaned up a duplicate line and a typo that crept in during editing. Please have another look.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix(duplicate): projectManager not populated in projectPayloadData on duplicate project page

5 participants