-
Notifications
You must be signed in to change notification settings - Fork 153
Feature flag removed : user OOO approve reject #1110
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature flag removed : user OOO approve reject #1110
Conversation
|
Important Review skippedAuto incremental reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the WalkthroughThis PR removes dev mode feature flagging from user status components and consolidates the Out Of Office (OOO) workflow to exclusively use a dedicated Changes
Possibly related issues
Estimated code review effort🎯 2 (Simple) | ⏱️ ~12 minutes Poem
Pre-merge checks and finishing touches✅ Passed checks (3 passed)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
📜 Review details
Configuration used: Organization UI
Review profile: ASSERTIVE
Plan: Pro
📒 Files selected for processing (7)
app/components/user-status-modal.jsapp/components/user-status.hbsapp/components/user-status.jsapp/constants/apis.jsapp/templates/status.hbstests/integration/components/user-status-modal-test.jstests/integration/components/user-status-test.js
🧰 Additional context used
🧬 Code graph analysis (2)
tests/integration/components/user-status-modal-test.js (1)
tests/unit/controllers/status-test.js (6)
from(134-134)from(179-179)until(135-137)until(180-182)reason(138-138)reason(183-183)
app/components/user-status-modal.js (1)
app/constants/user-status.js (2)
USER_STATES(18-24)USER_STATES(18-24)
🔇 Additional comments (8)
app/components/user-status.js (1)
23-23: LGTM! UI text accurately reflects the new approval workflow.The message change from "Change your status to OOO" to "Request OOO Status" correctly communicates that OOO now requires approval rather than being an immediate status change.
tests/integration/components/user-status-test.js (1)
49-49: LGTM! Test expectation correctly updated.The test assertion correctly reflects the UI text change to "Request OOO Status".
app/components/user-status.hbs (1)
28-53: LGTM! Dev mode branching successfully removed.The conditional logic now consistently renders OOO-related options without dev mode checks:
- Shows "Cancel OOO" button when status is OOO
- Shows available status options (including "Request OOO Status") for other statuses
This correctly implements the migration away from feature-flagged dev mode.
app/components/user-status-modal.js (2)
57-57: LGTM! Simplified method signature.The removal of the
isDevModeparameter fromupdateStatusBasedOnModecorrectly reflects the elimination of dev mode branching logic.
107-117: LGTM! Logic correctly refactored from dev mode to status type.The method now branches based on
newStatustype rather than dev mode, which is the correct approach. For OOO status, it callscreateOOORequestwith the timestamp fields fromnewStateObj, and for other statuses, it callsupdateStatuswith the complete status object.tests/integration/components/user-status-modal-test.js (1)
56-73: LGTM! Test correctly validates the new createOOORequest API.The test properly validates the new OOO request flow:
- Handler signature matches
createOOORequest(from, until, reason)- Validates
reasonis passed correctly- Validates
fromanduntilare numeric timestamps- Component receives the
@createOOORequestpropAlso applies to: 81-81
app/templates/status.hbs (1)
9-9: The controller correctly implements thecreateOOORequestaction.The status controller implements
createOOORequestat line 70 with the expected signature(from, until, reason). The action properly converts date parameters, makes the API request toCREATE_OOO_REQUEST_URL, and handles responses with appropriate toast notifications. TheupdateStatusaction remains in place for non-OOO status flows.app/constants/apis.js (1)
38-38: The endpoint integration is properly implemented in the frontend; backend confirmation is needed separately.The
CREATE_OOO_REQUEST_URLendpoint is correctly configured without thedev=trueparameter and consistently used across the codebase. The POST request includes proper error handling and request validation. However, verification that the backend/requestsendpoint exists and properly handles OOO request creation requires confirmation from the backend service, which is outside the scope of code review.
|
c9f005b to
fc33967
Compare
app/components/user-status-modal.js
Outdated
| } else { | ||
| await this.args.updateStatus({ currentStatus: newStateObj }); | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
any other case where code would reach this else statement? we can only change status to OOO, is there any other status available?
|
1b82479 to
402536d
Compare
ed635d9 to
df9d744
Compare
0efc272 to
fe29f99
Compare
eeea17e to
a727041
Compare
* Feature flag removed : user OOO approve reject (#1110) * code changes OOO flow Migrated from users page to request flow * removed console log * changed assert.expect * fix: pass date strings instead of timestamps to createOOORequest * fixed errors * wrong commit fix * removed else * removed stateobj --------- Co-authored-by: Dhirenderchoudhary <dhirenderchoudhary0001@gmailcom> * fix: OOO migration date issues (#1112) * fixed date issues * fix lint --------- Co-authored-by: Dhirenderchoudhary <dhirenderchoudhary0001@gmailcom> * fix: Update OOO request button text (#1116) * message changed * message fix * lint fix --------- Co-authored-by: Dhirenderchoudhary <dhirenderchoudhary0001@gmailcom> --------- Co-authored-by: Dhirender Choudhary <[email protected]> Co-authored-by: Dhirenderchoudhary <dhirenderchoudhary0001@gmailcom>
Date:
25-12-2025Developer Name:
DhirenderIssue Ticket Number:-
#1109
Description:
The OOO feature is migrated from the user status page to the requests module by removing the
dev=truefeature flag. This change makes all OOO requests go through the approval workflow, ,so that no developer can change there OOO status by there own.Is Under Feature Flag
Database changes
Breaking changes
Is Development Tested?
Tested in staging?
Screenshot below