Skip to content

Commit

Permalink
Merge pull request #1425 from digitalgreenorg/code_optm
Browse files Browse the repository at this point in the history
participant update changed
  • Loading branch information
shruthi-monika authored Sep 23, 2024
2 parents 6ebd5b3 + c7a50b9 commit fedab3d
Showing 1 changed file with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -246,8 +246,14 @@ const ParticipantFormNew = (props) => {
? labels.en.roleNo.coStewarRoleNo
: labels.en.roleNo.participantsRoleNo
);
}
if (userType !== "guest") {
if (!isEditModeOn) {
bodyFormData.append("approval_status", true);
} else {
bodyFormData.append("approval_status", istrusted);
}
}
if (userType !== "guest") bodyFormData.append("approval_status", true);
let method = "POST";
let url = "";
if (userType == "guest") {
Expand All @@ -258,7 +264,6 @@ const ParticipantFormNew = (props) => {

if (isEditModeOn) {
bodyFormData.append("id", orgId);
bodyFormData.append("approval_status", istrusted);
method = "PUT";
url = UrlConstants.base_url + UrlConstants.participant + id + "/";
}
Expand Down

0 comments on commit fedab3d

Please sign in to comment.