devsofttech_hms_ci4/app/Views
DevSoftTech Server ddec3cec69 Fix editable complaint fields - attach handlers after section reload
BUGFIX: Event handlers were only attached on initial page load

PROBLEM: After implementing editable complaint fields, the inputs
wouldn't become editable when adding new complaints via the Smart
Complaints Picker. The event handlers were only attached once on
page load, not after the section was dynamically reloaded.

ROOT CAUSE: When clicking Add or AI Draft buttons, the form submits
and the section-complaints area is reloaded from server. The new
complaint rows had the input fields but no event handlers attached.

SOLUTION:
1. Moved event handler attachment logic into initComplaintTools()
   function as new attachComplaintFieldHandlers() helper
2. This function is automatically called after section reload
3. Clone-and-replace pattern to prevent duplicate event handlers
4. Fixed table name: ipd_discharge_complaint (not ipd_discharge_comp)

FLOW:
- Add complaint → section reloads → initComplaintTools() runs →
  attachComplaintFieldHandlers() attaches blur/keydown handlers →
  editable fields work

Now clicking on complaint name/remark inputs works for both:
- Existing complaints (on page load)
- Newly added complaints (after section reload)
2026-06-06 05:18:35 +05:30
..
abdm ABDM: enforce PDF-backed report submit and improve gateway tracking 2026-05-31 04:17:39 +05:30
abha feat: ABDM OPD Queue + ABHA Register flow + patient ABHA search fix 2026-05-16 04:21:31 +05:30
account Add dedicated Save Settings button for user preferences 2026-04-28 13:54:46 +05:30
auth Add dark border theme for better visibility on old LED screens 2026-06-05 16:10:38 +05:30
billing Fix editable complaint fields - attach handlers after section reload 2026-06-06 05:18:35 +05:30
dashboard Implement OPD template builder, doctor template selection, and OPD print integration fixes 2026-02-27 19:44:36 +05:30
diagnosis Improve radiology template workflow and editor stability 2026-05-30 18:01:20 +05:30
doctor_document Improve doctor document workflow and print performance 2026-05-06 02:06:18 +05:30
errors Implement OPD template builder, doctor template selection, and OPD print integration fixes 2026-02-27 19:44:36 +05:30
finance feat: ABDM OPD Queue + ABHA Register flow + patient ABHA search fix 2026-05-16 04:21:31 +05:30
Invoice Polish payment request alert wording 2026-04-10 04:20:14 +05:30
ipd_nursing refactor: set number input step to 1 across views 2026-04-10 21:16:25 +05:30
medical Restore legacy pharmacy reports and fix net/payment totals 2026-06-01 10:53:27 +05:30
org_packing Implement OPD template builder, doctor template selection, and OPD print integration fixes 2026-02-27 19:44:36 +05:30
partials feat(abdm): proper FHIR bundles for lab reports and IPD discharge 2026-05-23 04:41:59 +05:30
PathLab_Report Improve radiology template workflow and editor stability 2026-05-30 18:01:20 +05:30
report Implement medical store credit payout workflow and optimize payout pool DataTable grouping 2026-04-30 01:42:03 +05:30
Setting feat(discharge): add department and time placeholders 2026-06-05 11:05:00 +05:30
setup Fix: {{advice}} prints as-is (no Hindi/AI conversion); fix Schema Diff truncation 2026-04-16 12:31:42 +05:30
storestock Revert card/modal/container borders to original light colors 2026-06-05 16:20:21 +05:30
tools feat: OPD speech-to-text mic, medicine label enhancements & template search 2026-03-30 18:46:33 +05:30
welcome_message.php Add dark border theme for better visibility on old LED screens 2026-06-05 16:10:38 +05:30