From d0d0fb1fb107070bca5a395850ea622219cc2756 Mon Sep 17 00:00:00 2001 From: Pankaj Date: Sat, 29 Mar 2025 18:59:04 +0530 Subject: [PATCH 1/5] Create README.md --- onboarding-extension-requests/README.md | 1 + 1 file changed, 1 insertion(+) create mode 100644 onboarding-extension-requests/README.md diff --git a/onboarding-extension-requests/README.md b/onboarding-extension-requests/README.md new file mode 100644 index 0000000..8b13789 --- /dev/null +++ b/onboarding-extension-requests/README.md @@ -0,0 +1 @@ + From d6c619c5bf0d67c5733d96c20f889661e61306da Mon Sep 17 00:00:00 2001 From: Pankaj Date: Sat, 29 Mar 2025 19:34:40 +0530 Subject: [PATCH 2/5] add data model and examples of request --- onboarding-extension-requests/README.md | 99 +++++++++++++++++++++++++ 1 file changed, 99 insertions(+) diff --git a/onboarding-extension-requests/README.md b/onboarding-extension-requests/README.md index 8b13789..9d67038 100644 --- a/onboarding-extension-requests/README.md +++ b/onboarding-extension-requests/README.md @@ -1 +1,100 @@ +### Onboarding Extension Request Firestore collection model + +```json +{ + "id": "String", + "type": "String" + "userId": "String", + "state": "", + "oldEndsOn": "number", + "newEndsOn": "number", + "message": "String", + "createdAt": "Timestamp", + "updatedAt": "Timestamp", + "lastModifiedBy": "String", + "reason": "String", + "requestedBy": "String", + "requestedNumber": "number" +} +``` + +#### Fields + +| Field | Type | Description | +| ------------- | --------- | ------------------------------------------------------------------------| +| id | String | Unique identifier for the document. | +| userId | String | The id of the user who created the request. | +| state | String | The state of the request like APPROVED, REJECTED, PENDING. | +| oldEndsOn | number | Old deadline of the onboarding task in millisecond | +| newEndsOn | number | New deadline of the onboarding task in millisecond | +| message | String | The message provided by super user while approving or rejecting request.| +| createdAt | Timestamp | Unix timestamp for the creation time of the request. | +| updatedAt | Timestamp | Unix timestamp for the last update time of the request. | +| lastModifiedBy| String | The id of the superuser or request owner who processed the request | +| reason | String | The reason for the extension request. | +| requestedBy | String | The username of the user who created the request. | +| requestNumber | number | The current request number for onboarding task. | +| type | String | The type of request i.e. ONBOARDING. | + + + +### Example data + +#### Example for PENDING state + +```json +{ + "id": "VYSTHeIERJlEtQdpViWo", + "createdAt": 1741328586836, + "updatedAt": 1741328586836, + "type": "ONBOARDING", + "state": "PENDING", + "userId": "7bTCwaMgEnKSumhenkwj", + "requestedBy": "mridul-khandelwal-1", + "oldEndsOn": 1743683053755, + "newEndsOn": 1744115053755, + "reason": "testing", + "requestNumber": 1 +} +``` + +#### Example for APPROVED state + +```json +{ + "id": "Vv5IPkhghnNyjPYhw6Ws", + "createdAt": 1738686977925, + "type": "ONBOARDING", + "userId": "p86xesKNsxic6uFe6SZi", + "requestedBy": "mohit-ramani-1", + "oldEndsOn": 1740584089491, + "requestNumber": 1, + "reason": "test 2", + "newEndsOn": 1741132800000, + "lastModifiedBy": "65QiTlqudZfDk3i5W9WO", + "state": "APPROVED", + "message": "super-user message for testing", + "updatedAt": 1738830512066 +} +``` + +#### Example for REJECTED state + +```json +{ + "id": "Vv5IPkhghnNyjPYhw6Ws", + "createdAt": 1738686977925, + "type": "ONBOARDING", + "userId": "p86xesKNsxic6uFe6SZi", + "requestedBy": "mohit-ramani-1", + "oldEndsOn": 1740584089491, + "requestNumber": 1, + "reason": "test 2", + "newEndsOn": 1741132800000, + "lastModifiedBy": "65QiTlqudZfDk3i5W9WO", + "state": "REJECTED", + "message": "super-user message for testing", + "updatedAt": 1738830512066 +} +``` From 62bc78954622d1b54c3d530cdcaf5d60683acc27 Mon Sep 17 00:00:00 2001 From: Pankaj Date: Sat, 29 Mar 2025 20:03:42 +0530 Subject: [PATCH 3/5] fix: resolve nitpick comment --- onboarding-extension-requests/README.md | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/onboarding-extension-requests/README.md b/onboarding-extension-requests/README.md index 9d67038..5a93c3b 100644 --- a/onboarding-extension-requests/README.md +++ b/onboarding-extension-requests/README.md @@ -4,7 +4,7 @@ ```json { "id": "String", - "type": "String" + "type": "String", "userId": "String", "state": "", "oldEndsOn": "number", @@ -26,18 +26,16 @@ | id | String | Unique identifier for the document. | | userId | String | The id of the user who created the request. | | state | String | The state of the request like APPROVED, REJECTED, PENDING. | -| oldEndsOn | number | Old deadline of the onboarding task in millisecond | -| newEndsOn | number | New deadline of the onboarding task in millisecond | -| message | String | The message provided by super user while approving or rejecting request.| +| oldEndsOn | number | Old deadline of the onboarding task in millisecond. | +| newEndsOn | number | New deadline of the onboarding task in millisecond. | +| message | String | The message provided by superuser while approving or rejecting request. | | createdAt | Timestamp | Unix timestamp for the creation time of the request. | | updatedAt | Timestamp | Unix timestamp for the last update time of the request. | -| lastModifiedBy| String | The id of the superuser or request owner who processed the request | +| lastModifiedBy| String | The id of the superuser or request owner who processed the request. | | reason | String | The reason for the extension request. | | requestedBy | String | The username of the user who created the request. | -| requestNumber | number | The current request number for onboarding task. | -| type | String | The type of request i.e. ONBOARDING. | - - +| requestNumber | number | The current request number of onboarding extension request. | +| type | String | The type of request, i.e., ONBOARDING. | ### Example data From ed79944b94bfc97aeee35d7e4d9eee0e0d85e9ca Mon Sep 17 00:00:00 2001 From: Pankaj Date: Sat, 29 Mar 2025 20:45:50 +0530 Subject: [PATCH 4/5] fix: add onboarding-extension-requests folder path in README for navigation --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index a1b07fc..3dcca61 100644 --- a/README.md +++ b/README.md @@ -23,3 +23,4 @@ Firebase database table structure - [Wallets](/wallets) - [Applicants](/applicants) - [task-dependency](/task-dependency/) +- [onboarding-extension-requests](/onboarding-extension-requests) From 5b27857a4ec74d48f1c6ce4ea5392d9666127a7e Mon Sep 17 00:00:00 2001 From: Pankaj Date: Sat, 29 Mar 2025 21:26:23 +0530 Subject: [PATCH 5/5] fix: add string in type field --- onboarding-extension-requests/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/onboarding-extension-requests/README.md b/onboarding-extension-requests/README.md index 5a93c3b..cdea642 100644 --- a/onboarding-extension-requests/README.md +++ b/onboarding-extension-requests/README.md @@ -6,7 +6,7 @@ "id": "String", "type": "String", "userId": "String", - "state": "", + "state": "String", "oldEndsOn": "number", "newEndsOn": "number", "message": "String",