Enhance Feedback and Tender Approval Services with Toggle Functionality
- Updated the ToggleFeedback method in the feedback service to change the FeedbackType to "unlike" or "undislike" based on the current state, improving user interaction with feedback. - Modified the ToggleTenderApproval method in the tender approval service to update the Status to "unapproved" or "unrejected" depending on the current approval state, streamlining tender approval management. - These enhancements improve the overall functionality and user experience of the tender management system.
This commit is contained in:
@@ -65,6 +65,12 @@ func (s *feedbackService) ToggleFeedback(ctx context.Context, req ToggleFeedback
|
||||
return nil, err
|
||||
}
|
||||
|
||||
if req.FeedbackType == FeedbackTypeLike {
|
||||
existing.FeedbackType = "unlike"
|
||||
} else {
|
||||
existing.FeedbackType = "undislike"
|
||||
}
|
||||
|
||||
return existing.ToResponse(), nil
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user