Version: 1.0
Last Updated:14 January 2026
1. Introduction
The SMRP Automator is a Chrome Extension designed to streamline data entry for Dietetic modules within the Ministry of Health's SMRP Portal (MyHDW). It integrates directly with Google Sheets to eliminate manual double-entry, automates patient registration, and ensures data accuracy.
- Three-Way Integration: Supports Inpatient (
P.DALAM), Outpatient (P.LUAR), and Group Therapy (MNT BERKUMPULAN). - Smart Navigation: Automatically locates the correct patient visit row based on service type and date.
- Deep Observer: Intelligently waits (up to 32 seconds) for slow-loading forms to prevent errors.
- Registration Automation: Auto-generates sequential Registration Numbers (e.g.,
DT10001).
2. Installation Guide
- Download & Extract: Save the provided extension files (
manifest.json,content.js, etc.) into a folder namedSMRP_Automator. - Load into Chrome:
- Open
chrome://extensions/. - Toggle Developer mode (top right).
- Click Load unpacked and select your folder.
- Open
- Pin the Extension: Click the Puzzle Piece icon in the toolbar and pin SMRP Automator.
3. View Modes
You can customize how the extension appears on your screen.
Option A: Sidebar Mode (Recommended)
Best for continuous data entry. The panel stays open while you navigate.
- Right-click the SMRP Automator icon.
- Check "Open in Side Panel".
- Click the icon to open the persistent side panel.
Option B: Popup Mode
Best for quick, single-use actions.
- Right-click the extension icon.
- Uncheck "Open in Side Panel".
- Click the icon to open as a floating window.
4. Google Sheet Configuration
The automation reads columns based on the Sheet Name. Ensure your headers match these layouts.
A. Inpatient Layout (Sheet: P.DALAM)
| Col | Data Point | Purpose |
|---|---|---|
| C | Admission Date | Matches the specific visit date in the portal. |
| G | Age | Determines Patient Type (Dewasa/Kanak-Kanak). |
| H | Diagnosis | Fills "Main Diagnosis" field. |
| J | Diet Type | Selects the main Diet Type dropdown. |
| K | Specific Diet | Checks checkboxes (e.g., Diabetic, Low Salt). |
| L | Discipline | Selects the Discipline dropdown. |
| M | Nutrition Support | Selects Oral, ONS, or Tube. |
| O | Visit Type | Checks if the visit is a "Follow Up Case". |
B. Outpatient Layout (Sheet: P.LUAR)
| Col | Data Point | Purpose |
|---|---|---|
| B | Date | Sets Registration and Visit Date. |
| E | IC No. | Calculates Age to set Patient Type. |
| F | Diagnosis | Fills "Main Diagnosis" field. |
| G | Diet Type | Selects Diet Type dropdown. |
| H | Specific Diet | Checks specific diet checkboxes. |
| I | Referral (Int) | Sets Source to "Internal". |
| K | Referral (Ext) | If checked, sets Visit Type to "New Case". |
| N | Discipline | Selects Discipline dropdown. |
C. Group Therapy Layout (Sheet: MNT BERKUMPULAN)
| Col | Data Point | Purpose |
|---|---|---|
| B | Date | Sets Visit Date. |
| D | IC No. | Calculates Age/Patient Type. |
| E | Referral Source | Sets Internal vs External. |
| F | Diet Type | Selects Diet Type dropdown. |
| H | Discipline | Selects Discipline dropdown. |
5. Initial Setup
- Open Settings: Click the Gear Icon inside the extension.
- Link Spreadsheet: Paste your Spreadsheet ID from your Google Sheet URL (the string between /d/ and /edit) and select the Sheet Name.
- RN Configuration:
- RN Prefix: Default is
DT10. - Next RN Seq: e.g.,
001(The counter that increments after each registration). - Result:
DT10001.
- RN Prefix: Default is
- Authorize: Click Test Connection and sign in with Google.
6. Workflows
Workflow A: Outpatient Registration
Use for new P.LUAR cases needing an RN.
- Search Patient in SMRP > Visit Page.
- Set Extension to
P.LUARand Row Number to the patient's row in Google Sheet (e.g., 14).. - Check Next RN Seq.
- Click Start Outpatient Reg.
- Extension Action: Tool clicks "Add Clinical Support", fills Date (08:00 AM), fills RN, and Submits.
Workflow B: Clinical Data Entry
Scenario 1: Outpatient (Individual)
- Ensure you are on the Visit page.
- Set Extension to
P.LUARand Row Number to the patient's row in Google Sheet (e.g., 14).. - Click Fetch & Fill Clinical Data.
- Extension Action: Scans for "Sokongan Klinikal" & "SSDT" in RN, Finds the visit row matching your Sheet Date, and fills the clinical form.
Scenario 2: Inpatient (Ward)
- Ensure you are on the Visit page.
- Set Extension to
P.DALAMand Row Number to the patient's row in Google Sheet (e.g., 14).. - Click Fetch & Fill Clinical Data.
- Extension Action: Scans for "Pesakit Dalam" rows earlier than your admission date and fills the clinical form.
Scenario 3: Group Therapy
- Ensure you are on the Visit page.
- Set Extension to
MNT BERKUMPULANand Row Number to the patient's row in Google Sheet (e.g., 14).. - Click Fetch & Fill Clinical Data.
- Extension Action: Scans for "Sokongan Klinikal" & "SSDT" in RN, Finds the visit row matching your Sheet Date, auto-sets "Consultation Type" to Group Class and "Visit Type" to New Case and fills the clinical form.
7. Troubleshooting Guide
Navigation Errors
| Error / Symptom | Solution |
|---|---|
| Popup: " No matching earlier visit found..." |
1. Check Dates: Ensure Sheet date matches Portal. 2. Expand View: Scroll down in SMRP and change items per page to All or 20. |
| Automation stops (Silent) | The form loaded too slowly (>32s). Click the extension button again to retry. |
| Wrong Row Selected | Refresh the page to clear old menus. The tool needs a clean layout. |
Data & Connection Errors
| Error / Symptom | Solution |
|---|---|
| "Auth Failed" |
1. Close Google Chrome completely and restart it. 2. Click Test Connection again to refresh the security token. |
| "Registration Number already exists" | Change Next RN Seq in settings to a higher number (e.g., 50). |
| "Missing Data: IC No." | Fill column E in your Google Sheet. |