refactor(jubilee): rename DocType "Jubilee Service Request" to "Jubilee Approval Request"#1196
Merged
av-dev2 merged 1 commit intoAakvatech-Limited:nurse-ot-modulefrom Apr 28, 2026
Conversation
…ee Approval Request"
## Summary
Renamed the Jubilee pre-authorization DocType and its two child tables
across the entire hms_tz Jubilee module. "Service Request" was
ambiguous; "Approval Request" accurately describes the workflow — a
pre-authorization request submitted to Jubilee Insurance for clinical
approval before rendering services to a patient.
## DocType Renames
jubilee_service_request → jubilee_approval_request
jubilee_service_request_disease → jubilee_approval_request_disease
jubilee_service_request_item → jubilee_approval_request_item
The child tables were renamed first to avoid broken field options on
the parent. All three renamed DocTypes retain full schema compatibility.
## Files Changed
### Directories / File renames (tracked by git as R)
- jubilee/doctype/jubilee_service_request/ → jubilee_approval_request/
- jubilee_service_request.json → jubilee_approval_request.json
- jubilee_service_request.py → jubilee_approval_request.py
- jubilee_service_request.js → jubilee_approval_request.js
- test_jubilee_service_request.py → test_jubilee_approval_request.py
- __init__.py → __init__.py (unchanged)
- jubilee/doctype/jubilee_service_request_disease/ → jubilee_approval_request_disease/
- jubilee_service_request_disease.json → jubilee_approval_request_disease.json
- jubilee_service_request_disease.py → jubilee_approval_request_disease.py
- jubilee/doctype/jubilee_service_request_item/ → jubilee_approval_request_item/
- jubilee_service_request_item.json → jubilee_approval_request_item.json
- jubilee_service_request_item.py → jubilee_approval_request_item.py
### jubilee_approval_request.json
- Updated "name" field from "Jubilee Service Request" to "Jubilee Approval Request"
- Updated Table field "options" for the diseases child table:
"Jubilee Service Request Disease" → "Jubilee Approval Request Disease"
- Updated Table field "options" for the items child table:
"Jubilee Service Request Item" → "Jubilee Approval Request Item"
- Updated Link field "options" on amended_from:
"Jubilee Service Request" → "Jubilee Approval Request"
- Updated naming series prefix:
"JSR-.YYYY.-.####" → "JAR-.YYYY.-.####"
### jubilee_approval_request_disease.json
- Updated "name": "Jubilee Service Request Disease" → "Jubilee Approval Request Disease"
### jubilee_approval_request_item.json
- Updated "name": "Jubilee Service Request Item" → "Jubilee Approval Request Item"
### jubilee_approval_request.py
- Renamed Python class: JubileeServiceRequest → JubileeApprovalRequest
(required so Frappe's get_controller() resolves the class correctly
without marking the DocType as orphaned during bench migrate)
- Updated frappe.db.get_value() doctype arg to "Jubilee Approval Request"
- Updated frappe.get_doc() doctype arg to "Jubilee Approval Request"
- Updated frappe.new_doc() doctype arg to "Jubilee Approval Request"
- Updated add_comment text reference from "Service Request" to "Approval Request"
- Updated docstring for create_preauthorization_doc()
### jubilee_approval_request_disease.py
- Renamed Python class: JubileeServiceRequestDisease → JubileeApprovalRequestDisease
### jubilee_approval_request_item.py
- Renamed Python class: JubileeServiceRequestItem → JubileeApprovalRequestItem
### jubilee_approval_request.js
- Updated frappe.ui.form.on() registration from
"Jubilee Service Request" → "Jubilee Approval Request"
### jubilee/api/api.py
- Replaced all 11 occurrences of "Jubilee Service Request" with
"Jubilee Approval Request" (frappe.get_doc calls, ref_doctype values,
frappe.db.set_value calls, and docstring references)
- Affected functions: get_preauthorization_status(),
get_inpatient_admission_status()
### nhif/api/patient_encounter.js
- Updated frappe.call() method path from:
hms_tz.jubilee.doctype.jubilee_service_request.jubilee_service_request.create_preauthorization_doc
to:
hms_tz.jubilee.doctype.jubilee_approval_request.jubilee_approval_request.create_preauthorization_doc
## Notes
- No database patch required; this is a development-phase change and
no production data exists under the old DocType name.
- Running bench migrate after this commit is required to register
the renamed DocTypes in the database.
Not up to standards ⛔
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Renamed the Jubilee pre-authorization DocType and its two child tables across the entire hms_tz Jubilee module. "Service Request" was ambiguous; "Approval Request" accurately describes the workflow — a pre-authorization request submitted to Jubilee Insurance for clinical approval before rendering services to a patient.
DocType Renames
jubilee_service_request → jubilee_approval_request
jubilee_service_request_disease → jubilee_approval_request_disease
jubilee_service_request_item → jubilee_approval_request_item
The child tables were renamed first to avoid broken field options on the parent. All three renamed DocTypes retain full schema compatibility.
Files Changed
Directories / File renames (tracked by git as R)
jubilee/doctype/jubilee_service_request/ → jubilee_approval_request/
jubilee/doctype/jubilee_service_request_disease/ → jubilee_approval_request_disease/
jubilee/doctype/jubilee_service_request_item/ → jubilee_approval_request_item/
jubilee_approval_request.json
jubilee_approval_request_disease.json
jubilee_approval_request_item.json
jubilee_approval_request.py
jubilee_approval_request_disease.py
jubilee_approval_request_item.py
jubilee_approval_request.js
jubilee/api/api.py
nhif/api/patient_encounter.js
Notes