Practitioner Bulk Upload Spreadsheet - hmislk/hmis GitHub Wiki
Practitioner β Bulk Upload from Spreadsheet
Use the bulk-upload screens to create many doctor, consultant, or staff records in one operation from an Excel spreadsheet. Each upload screen is dedicated to one record type; they all follow the same two-step pattern: upload the file β review the preview β click Save.
Choosing the right uploader
| Spreadsheet purpose | Open⦠| Path |
|---|---|---|
| Doctors who are not channelling consultants | Manage Staff β (Setup) β Upload Doctors | /admin/staff/upload_doctors.xhtml |
| Channelling consultants | Manage Staff β (Setup) β Upload Consultants | /admin/staff/upload_consultants.xhtml |
| All other staff (nurses, technicians, admin, etc.) | Manage Staff β (Setup) β Upload Staff | /admin/staff/upload_staff.xhtml |
Privilege required: AdminStaff.
Pattern (all three uploaders work the same way)
- Click Choose File and pick an
.xlsxfile. - Click Upload (orange). The system parses the file and shows a preview table.
- Review the preview. If a row looks wrong, fix the spreadsheet, then re-upload.
- Click Save. The records are created.
The Upload step is non-destructive β it only loads the file into a preview list. Nothing is saved until you click Save.
Doctor upload β spreadsheet format
The file must have eight columns, in this order, starting at column A:
| Column | Field | Required? |
|---|---|---|
| A | Code | Optional β short internal code. Leave blank to let the system derive one. |
| B | Title | Required β Dr., Prof., Mr., Ms., etc. Must match a title HMIS recognises. |
| C | Name | Required β display name. |
| D | Registration Number | Optional β SLMC / regulatory ID. Free text. |
| E | Description | Optional β free text notes. |
| F | Sex | Required β M or F. |
| G | Mobile Number | Optional β used for SMS. |
| H | Speciality | Required β must match a speciality name in the All Specialities catalog (case-sensitive). |
If a Speciality value does not match any entry in the catalog, the row will appear in the preview without a speciality and the system will not save the row.
Consultant upload β spreadsheet format
The first eight columns are identical to the doctor upload. The screen header is "Upload Consultants" and the action button calls dataUploadController.uploadConsultants. The Speciality column must match a value in the Doctor Specialities catalog (this is the catalog used by channelling), not the All Specialities catalog.
| Column | Field | Required? |
|---|---|---|
| A | Code | Optional |
| B | Title | Required |
| C | Name | Required |
| D | Registration Number | Optional |
| E | Description | Optional |
| F | Sex | Required (M / F) |
| G | Mobile Number | Optional |
| H | Speciality | Required (Doctor Specialities catalog) |
The preview grid columns are: Code, Title, Name, Registration Number, Description, Sex, Mobile Number, Speciality.
Staff upload β spreadsheet format
The Staff upload has fifteen columns. Use it for nurses, technicians, cashiers, and other non-doctor staff.
| Column | Field | Required? |
|---|---|---|
| A | Code | Optional β short internal code. |
| B | EPF No | Required β payroll EPF number. |
| C | Title | Required β Mr., Ms., etc. |
| D | Name | Required β display name. |
| E | Full Name | Required β full legal name. |
| F | Name with Initials | Required β X. Y. Surname form. |
| G | Address | Required. |
| H | Sex | Required β M / F. |
| I | NIC No | Required β national identity card number. |
| J | DOB | Required β date of birth. |
| K | Date of Retired | Optional. |
| L | Department | Optional. |
| M | Branch | Optional. |
| N | Account No | Optional β salary account number. |
| O | Bank | Optional β bank name (must match an institution of type Bank). |
The Staff upload uses a polling background process: the screen shows a status dialog and refreshes the preview every 10 seconds while the file is being parsed. This is normal for larger Staff uploads.
Preview before saving
After Upload (and after the polling completes for the Staff upload), a paginated grid appears at the bottom of the screen showing the parsed rows. The grid columns mirror the spreadsheet columns. Use this preview to spot:
- Rows with a missing required field β they will appear blank in the corresponding column.
- Speciality mismatches β the Speciality column will be empty if the name did not match the catalog.
- Title mismatches β the Title column will be empty if the value did not match a recognised title.
If you spot issues, fix the spreadsheet and re-upload. The preview replaces, not appends.
Saving the upload
Click the Save button below the preview grid. The system iterates the rows and creates one Doctor, Consultant, or Staff record per row.
If the same name was already in the system, a new record is created β there is no automatic duplicate check. If you re-upload an existing roster, you will end up with duplicates that must be retired manually (Practitioner β Deactivate and Bulk Delete).
Practical advice
- Always do a small test upload first. Create a spreadsheet with two or three rows and run through Upload β Save end-to-end on a non-production environment before importing a full roster.
- Pre-create the catalog entries. Make sure every Speciality value, Department, Bank, etc., already exists in HMIS before you upload. The uploader does not auto-create catalog entries.
- Save the spreadsheet that produced an upload. The system does not retain the source file.
- Stagger Staff uploads. Large Staff files (hundreds of rows) take several minutes; let the polling complete before you click Save.
Limitations
- No duplicate detection.
- No mid-file failure recovery β if a row fails, you will see it missing in the preview but no error report is exported. Examine the preview carefully.
- The Doctor upload always creates plain
Doctorrecords; you cannot promote one to a consultant through the upload. Use the Consultant uploader, or register manually afterwards. - The Date of Birth and Date of Retired columns must use a date format Excel and the system both recognise. Avoid free-text dates.
Related articles
- Practitioner Module Overview
- Admin β Practitioner Bulk Upload Format β administrator-side reference for required catalogs and validation behaviour.
- Admin β Specialities Catalog
- Admin β Doctor Specialities Catalog