An outpatient and emergency multi-doctor collaborative medical record continuation method and system, an electronic device, and a storage medium
By adopting a technical solution of 'manually triggered continuation writing - delayed persistence - domain-based read and write - splicing display - undoable rollback' in multi-doctor collaborative emergency scenarios, the problems of medical record modification destroying the original appearance, data redundancy and lengthy operation are solved. This achieves the continuity of medical records, permission isolation and data traceability, and improves the efficiency of emergency collaborative diagnosis and treatment and the legal evidentiary value.
Patent Information
- Application Number
- CN202611389752.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-09-09
- Publication Date
- 2026-11-13
AI Technical Summary
Existing electronic medical record systems suffer from problems in multi-doctor collaborative emergency scenarios, such as altering medical records and destroying their original appearance, inability to distinguish the contribution of diagnosis and treatment, data redundancy, and lengthy operation links. These issues make it difficult to guarantee the continuity of medical records, the isolation of permissions, and the traceability of data.
The technical solution adopts the approach of 'manually triggered continuation writing - delayed persistence - domain-based read and write - splicing display - undoable rollback'. Through the collaborative operation of the server and the doctor's workstation, the system realizes domain-based storage and access control of medical records, ensuring the integrity and traceability of medical records.
Significantly reduces invalid medical records, ensures the legal evidentiary value of medical records, improves the efficiency of collaborative diagnosis and treatment in emergency departments, supports safe rollback operations, and achieves complete traceability of the medical process.
Smart Images

Figure CN123095231A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of medical information technology, specifically to the processing of medical record continuation in a multi-doctor collaborative diagnosis and treatment scenario in an electronic medical record system, and particularly to a method, system, electronic device, and storage medium for multi-doctor collaborative medical record continuation in outpatient and emergency departments. Background Technology
[0002] With the advancement of hospital informatization, electronic medical record (EMR) systems have been widely used in outpatient and emergency departments. Emergency departments experience high patient volume and rapid changes in patient conditions. The same patient is often seen by multiple doctors in a single registration cycle (initial assessment, specialist consultation, shift handover, etc.), requiring subsequent doctors to continue writing medical records and issuing treatment instructions based on a complete understanding of the patient's medical history.
[0003] Existing electronic medical record systems typically adopt a "one registration, one visit, one medical record" model, which presents the following problems in multi-doctor collaborative emergency scenarios: Issue 1: Directly modifying the initial doctor's medical record destroys the original appearance of the initial consultation record, makes it impossible to distinguish the contributions of each doctor in diagnosis and treatment, and poses a risk of proving medical disputes.
[0004] Question 2: Opening a patient's medical record automatically creates a continuation record, making it impossible for doctors to independently determine whether a continuation is necessary, resulting in a large number of empty medical records and contaminating the medical data.
[0005] Question 3: After copying the entire historical medical record and then editing it, the boundary between historical content and newly added content is unclear, resulting in redundant storage and difficulty in tracing it from the doctor's perspective.
[0006] Question 4: It is difficult to safely undo accidental continuation of writing, or it requires the cooperation of the doctor who will continue writing to cancel, making the operation process lengthy.
[0007] Therefore, how to balance the continuity of medical records, the isolation of permissions, and the traceability of data in multi-doctor collaborative scenarios is a technical problem that urgently needs to be solved in this field. Summary of the Invention
[0008] To address the aforementioned problems in the existing technology, this invention provides a method, system, electronic device, and storage medium for collaborative medical record continuation in outpatient and emergency departments, proposing a technical solution of "manually triggered continuation—delayed persistence—domain-based read and write—semblage display—undotable rollback".
[0009] In a first aspect, the present invention provides a method for collaborative medical record continuation by multiple doctors in outpatient and emergency departments, executed by a medical information system server and a doctor's workstation, comprising: The server receives the doctor's selection of a target patient from the patient list; the server queries the set of medical records that the target patient has in the current registration period based on the registration serial number REGISTER_SN, and each medical record is associated with a unique medical serial number OPID and the identifier of the attending doctor; The server determines the current logged-in doctor's role as a patient: when the set of medical records is empty, the current logged-in doctor is identified as the first-visit doctor; when the set of medical records is not empty and there is no record in it with a patient identifier equal to the current logged-in doctor, the current logged-in doctor is identified as a follow-up doctor; when there is a record in the set of medical records with a patient identifier equal to the current logged-in doctor, the current logged-in doctor is identified as a doctor who has already seen patients, and the patient is taken to the consultation page by the doctor's most recent medical record number. In response to the doctor clicking the "Continue" button in the patient list, the server creates a temporary OPID bound to the currently logged-in doctor, and the doctor's workstation opens the medical record continuation editing interface; the temporary OPID remains in a temporary state until the doctor saves any medical data, and is automatically discarded when the page is closed or the patient is switched, and is not written to the medical record table; In the medical record continuation editing interface, the server queries all historical medical record texts under the current registration number except for the current OPID; the doctor's workstation initializes the electronic medical record editor with the first historical medical record, and then inserts subsequent historical medical records into the end of the editor to form a complete medical history view; the historical area is set to read-only permission, and the continuation area is set to edit permission; When a doctor continues a consultation and saves at least one of the diagnostic information, medical order information, or continued medical record content, the server persistently writes the temporary OPID into the consultation record table and updates the latest consultation serial number pointer LAST_OPID in the registration table. When saving a continued medical record, the doctor's workstation only extracts the medical record content under the continued editing node for storage and does not overwrite the medical record content corresponding to the historical OPID. In response to a doctor clicking the "Cancel Renewal" button, the server checks whether there are any uncleared diagnoses, invalidated or unrefunded medical orders, medical documents, treatment orders, or pathology requests under the current OPID. If they exist, cancellation is prevented and a prompt to clean them up is displayed. If they do not exist, the server deletes the medical record corresponding to the current OPID, queries the remaining medical records under the same registration serial number in reverse order of the medical record time, and writes the OPID of the latest record back to the LAST_OPID field of the registration table. Among all medical records queried by registration serial number, the OPID corresponding to the first record with the earliest consultation time is the initial consultation OPID, and the initial consultation OPID does not support cancellation of renewal.
[0010] In a second aspect, the present invention provides a multi-doctor collaborative medical record continuation system for outpatient and emergency departments, including a configuration management module, a patient list module, a continuation judgment module, a medical record management module, a medical record editing module, and a cancellation continuation verification module, for executing the method described in the first aspect above.
[0011] Thirdly, the present invention provides an electronic device including a processor and a memory, wherein the memory stores a computer program, and the processor executes the computer program to implement the method described in the first aspect above.
[0012] Fourthly, the present invention provides a computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the method described in the first aspect above.
[0013] Compared with the prior art, the beneficial effects of the present invention include: (1) Avoid invalid medical data: Existing solutions automatically create continuation records when doctors open patient information, generating a large number of empty OPIDs; the present invention only persists OPIDs after doctors actually save medical data, and "only viewing and not writing" does not generate medical records, significantly reducing data pollution.
[0014] (2) Guarantee the legal validity of medical records: This invention stores the written content of each doctor independently according to OPID, displays the historical area in read-only splicing mode, saves the continuation area independently, and clarifies the boundaries of responsibility, thus meeting the requirements for evidence in medical disputes.
[0015] (3) Improve the efficiency of emergency collaborative diagnosis and treatment: Doctors do not need to manually copy and paste historical medical records. They can view the complete medical history and write the follow-up diagnosis content directly by entering the follow-up writing interface, reducing operation steps and adapting to the high-frequency handover scenario in the emergency department.
[0016] (4) Support for safe rollback of continuation operation: Before cancellation, the present invention verifies the associated data such as diagnosis and medical orders. After the verification is passed, the OPID is automatically deleted and the LAST_OPID is rolled back. Doctors who continue the diagnosis can independently cancel the wrong operation.
[0017] (5) Complete and traceable medical history: Through the three-layer structure of “registration serial number - multiple OPID - LAST_OPID pointer”, the medical history of multiple doctors within a registration cycle is completely recorded, and the history of consultation can be traced back by doctor and by number of visits.
[0018] (6) Flexible and configurable deployment: Through the configuration of the main switch and related departments, it can meet the differentiated hospital needs of only the emergency department to enable the continuation and not the general outpatient department. Attached Figure Description
[0019] Figure 1 This is an overall flowchart of the outpatient and emergency department multi-doctor collaborative medical record continuation method provided in an embodiment of the present invention; Figure 2 This is a schematic diagram illustrating the relationship between registration serial numbers and multiple medical visit serial numbers provided in an embodiment of the present invention; Figure 3 This is a schematic diagram of the continuation medical record splicing and domain permission control provided in an embodiment of the present invention, showing the partitioning relationship where the document node doc is read-only, the continuation editing node JZ_OTHER_BATLE is editable, and only the content of the JZ_OTHER_BATLE node is extracted when saving; Figure 4 This is a flowchart of the cancellation of continuation verification and rollback provided in an embodiment of the present invention; Figure 5 This is a schematic diagram of the system module structure provided in an embodiment of the present invention. Detailed Implementation
[0020] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the invention.
[0021] Terminology conventions: REGISTER_SN (Registration Serial Number) is the anchor point for a single registration cycle; OPID (Outpatient ID) is the isolated unit for each doctor's patient data; LAST_OPID (Latest Outpatient ID) is a pointer in the registration table to the latest patient record; EMR (Electronic Medical Record) refers to an electronic medical record. Further conventions: First-visit doctor refers to the doctor who received the patient when the set of patient records under the current registration serial number is empty; Follow-up doctor refers to a doctor whose set of patient records is not empty and does not contain a record with a doctor ID equal to their own; Doctor who has already received patients refers to a doctor whose set of patient records contains a record with a doctor ID equal to their own. The above abbreviations and definitions will be used consistently throughout the following text.
[0022] like Figure 2As shown, the data model in this embodiment includes three core tables: the registration table (OUT_REGISTER), the consultation record table (OUTPATIENT), and the medical record table (OUTPATIENT_CASE). The registration table uses REGISTER_SN as the primary key and includes fields such as LAST_OPID, LAST_DOCTOR_ID (latest attending physician), and LAST_TREAT_DATE_TIME (latest consultation time). The consultation record table uses OPID as the primary key and REGISTER_SN as the foreign key, including fields such as TREAT_DOCTOR_ID (attending physician identifier) and TREAT_DATE_TIME (consultation time). The medical record table stores medical record content (TEXT_CONT) in association with OPID. The registration table and the consultation record table have a one-to-many relationship, while the consultation record table and the medical record table have a one-to-one relationship.
[0023] In one specific implementation, field constraints can be set as follows: OUT_REGISTER.REGISTER_SN primary key NOT NULL; LAST_OPID can be null and indexed; OUTPATIENT.OPID primary key NOT NULL, REGISTER_SN foreign key NOT NULL and indexed, TREAT_DOCTOR_ID and TREAT_DATE_TIME NOT NULL; OUTPATIENT_CASE is associated with OPID. When deleting and continuing OPID, associated records such as the destination are deleted simultaneously; medical records can be retained according to a trailing strategy, without mandatory cascading physical deletion.
[0024] like Figure 1 As shown, this embodiment provides a method for collaborative medical record continuation by multiple doctors in outpatient and emergency departments. The execution entities are a medical information system server and a doctor's workstation, and it includes the following steps: Step 1 (Configuration Loading): The system reads the configuration of the medical record continuation function switch and the associated department configuration; when the associated department configuration is empty, the continuation function is enabled for all departments; when the associated department configuration is not empty, the continuation function is enabled only for departments in the configured department list (such as the emergency department).
[0025] Step 2 (Patient Selection and Medical Record Query): The server receives the doctor's selection of the target patient from the patient list; the server queries the set of medical records that exist for the patient in the current registration period based on the registration serial number REGISTER_SN. Each medical record is associated with a unique medical serial number OPID and the attending physician identifier TREAT_DOCTOR_ID.
[0026] Step 3 (Continuing Doctor Determination): The server determines the current logged-in doctor's role in receiving patients—if the collection of medical records is empty, it is determined to be the initial doctor; if the collection of medical records is not empty and there is no record in it with the receiving doctor's identifier equal to that of the currently logged-in doctor, it is determined to be the continuing doctor (isContinueCaseDoctor=Y); if there is a record in the collection of medical records with the receiving doctor's identifier equal to that of the currently logged-in doctor, it is determined to be the doctor who has already received patients (login by the doctor's most recent OPID).
[0027] Step 4 (Patient Reception Entry Route): If the current doctor is the first-visit doctor, the outpatient / emergency department first-visit medical record template will be opened by default; if the current doctor is the follow-up doctor, the outpatient / emergency department follow-up medical record template will be opened by default; if the current doctor has already received a patient, the patient reception page corresponding to the doctor's most recent OPID will be opened by default.
[0028] Step 5 (Manually Triggered Continuation): In response to the doctor clicking the "Continue" button in the patient list, the server creates a temporary OPID bound to the currently logged-in doctor, and the doctor's workstation opens the emergency and outpatient medical record continuation editing interface; this temporary OPID remains in a temporary state until the doctor saves any medical data, and is automatically discarded when the page is closed or the patient is switched, and is not written to the medical record table.
[0029] Step 6 (Historical Medical Record Assembly and Domain-Based Access Control): In the outpatient and emergency department's continuation medical record editing interface, the server queries all historical medical record texts under the current registration serial number, excluding the current OPID; the doctor's workstation initializes the electronic medical record editor with the first historical medical record, and then sequentially inserts subsequent historical medical record documents at the end of the editor to form a complete medical history view; identifiers are reassigned to historical structured nodes (such as the diagnosis node DIAGNOSES) to avoid conflicts; the continuation medical record template of the current continuing doctor is inserted at the end, first setting the document node doc to read-only permission, and then setting the continuation editing node JZ_OTHER_BATLE to edit permission. Figure 3 As shown, the editor interface fully displays the complete medical history after splicing, while the historical area and the continuation area are separated and isolated in the storage.
[0030] In one specific implementation, the medical record splicing algorithm includes: (1) historical medical records are arranged in ascending order of consultation time; (2) the document tree is initialized by calling initEditor with the TEXT_CONT of the first historical medical record as tplData; (3) subsequent entries are appended as document fragments in the manner of insertDocument(TEXT_CONT, {atLast: true}), rather than string splicing; (4) randomId operation is performed on nodes such as DIAGNOSES and doc: traverse the nodes of this type, generate a globally unique new identifier and maintain the parent-child hierarchy; (5) insert a continuation template at the end, first set the document node doc permission to read-only, and then set the continuation editing node JZ_OTHER_BATLE permission to edit; (6) when saving, getContToHtml is used to extract only the content of the JZ_OTHER_BATLE node.
[0031] Step 7 (Delayed Persistence): When the doctor renewing the consultation saves at least one of the diagnostic information, medical order information, or continues the medical record content, the server persists the temporary OPID to the outpatient record table and updates the latest outpatient serial number pointer LAST_OPID and the latest attending doctor, department, time, and other fields in the outregister table.
[0032] Step 8 (Save Continued Content in Split): When a doctor saves a continued medical record, the doctor's workstation only extracts the medical record content (getContToHtml) under the continued editing node JZ_OTHER_BATLE for storage, without overwriting the medical record content corresponding to the historical OPID, thus achieving complete interface display and storage domain isolation.
[0033] Step 9 (Cancel continuation verification and rollback): For example... Figure 4 As shown, when a doctor clicks the "Cancel Renewal" button for a follow-up appointment, the server checks if there are any uncleared diagnoses, uncancelled / unrefunded medical orders, medical documents, treatment orders, or pathology requests associated with the current OPID. If so, cancellation is prevented and a prompt to clear the data is displayed. If not, the corresponding appointment record for the current OPID is deleted, and the remaining appointment records under the same registration number are queried in reverse chronological order by appointment time. The latest OPID is written back to the LAST_OPID field of the registration table, and the doctor's workstation clears the renewal editing area and resets the button status. Cancellation of renewal is not supported for initial appointment OPIDs.
[0034] In one specific implementation, the logic for determining whether to cancel the continuation of a medical order is as follows: if there is at least one record in the diagnosis table with the current OPID as the association key, the diagnosis has not been cleared; if the medical order status is neither invalid (INVALID) nor refunded (REFUND), it is a medical order that has neither been invalidated nor refunded; if there is at least one associated record in the medical document, TCM treatment order, treatment order, or pathology application corresponding tables, it cannot be canceled. If any of these conditions are met, cancellation will be prevented and a message will be displayed: "Please delete the relevant content before canceling the continuation." The rules for distinguishing the initial visit OPID are as follows: query all medical records by REGISTER_SN, sort by TREAT_DATE_TIME in ascending order, and the OPID of the first record is determined to be the initial visit OPID (cancellation is not supported, the button is grayed out); the rest are continuation visit OPIDs. Alternatively, if there is only one medical record and the attending physician is the current physician, it is determined to be an initial visit.
[0035] Step 10 (Historical Patient Navigation): In response to a doctor who has already received a patient clicking the "Historical Patient" button, the server queries all historical patient records of the current doctor for the current registration number and displays them in a table; after the doctor selects a record and clicks "Enter", the patient page corresponding to that OPID is opened, and the medical record interface displays the latest assembled complete medical record content. The modification permissions for diagnosis, medical orders, and medical records are limited to the selected OPID.
[0036] like Figure 5 As shown, this embodiment also provides a multi-doctor collaborative medical record continuation system for outpatient and emergency departments, deployed on the hospital intranet, including a server and doctor workstations, which communicate via HTTP / HTTPS interfaces. The system includes the following functional modules and their connections: (1) Configuration Management Module: Connects to the system parameter database, stores and reads parameters such as the main switch for medical record continuation and the configuration of related departments, and the sub-switch for diagnosis continuation (diagContinueModule, which displays diagnoses by registration serial number after being turned on), and provides a basis for other modules to make function activation judgments.
[0037] (2) Patient list module: It is connected to the registration table and the medical record table to display the list of patients to be treated; it filters the currently active medical records according to LAST_OPID; it provides "Continue" and "Historical Treatment" buttons in the operation column; and it transmits the doctor's operation request to the continuation judgment module and the medical record management module.
[0038] (3) Continued visit determination module: Receives the registration serial number and current doctor identifier from the patient list module, queries the medical record set, outputs the continued visit doctor determination result (isContinueCaseDoctor) and the historical medical record list (continuePatientCaseListJsonArray), and passes them to the patient list module (controls the button status) and the medical record editing module (drives the splicing logic) respectively.
[0039] (4) Medical record management module: It is connected to the registration table (OutRegister) and the medical record table (Outpatient). It is responsible for creating temporary OPIDs, persisting medical records, deleting and rewriting medical records, maintaining LAST_OPID pointers and related fields, and providing data support for the entry route and patient list filtering.
[0040] (5) Medical record editing module: It connects with the electronic medical record editor component (htEmrEditor), receives historical medical record data provided by the continuation judgment module, performs medical record splicing, node permission setting, and extraction and saving of continuation content; and works with the medical record management module to complete the delayed persistence trigger.
[0041] (6) Cancel continuation verification module: It is connected to the diagnosis form, medical order form, medical document form, treatment request form and pathology request form. Before canceling continuation, it performs a verification of the existence of related data. After the verification is passed, it calls the medical record management module to perform deletion and rollback operations.
[0042] Each module uses the registration serial number REGISTER_SN as the anchor point for a registration cycle and the medical visit serial number OPID as the isolation unit for each doctor's medical visit data. The consistency of the latest medical visit status within the registration cycle is maintained through the LAST_OPID pointer.
[0043] In one specific implementation, the system is also configured with a diagnostic continuation sub-switch (diagContinueModule), which is a sub-switch under the main switch for medical record continuation. When the diagnostic continuation sub-switch is turned on, diagnostic information is queried and displayed by the registration serial number REGISTER_SN, that is, all diagnoses associated within the current registration cycle are displayed, rather than just displayed by the current visit serial number OPID. The continuation column must be configured synchronously in the diagnostic column configuration. When the diagnostic continuation sub-switch is not turned on, diagnoses are still queried by the current OPID. Diagnostic data is still stored according to their respective OPIDs, without affecting the isolation of medical record domain permissions.
[0044] In a specific implementation, the main interfaces between the modules of the system are defined as follows: (1) Patient list query interface, the input parameters are REGISTER_SN, department, doctor, and the output parameter is the patient list filtered by LAST_OPID; (2) Continued consultation determination interface, the input parameters are REGISTER_SN, doctor, and the output parameters are isContinueCaseDoctor and historical medical record list; (3) Trigger continuation interface, the input parameters are REGISTER_SN, doctor, and the output parameters are temporary OPID and template identifier; (4) Medical record saving interface, the input parameters are OPID, continuation content, diagnosis and medical order flag, and the output parameters are persistent result and LAST_OPID; (5) Cancel continuation interface, the input parameters are OPID and REGISTER_SN, and the output parameters are verification result, prompt information and rollback LAST_OPID; (6) Historical consultation query interface, the input parameters are REGISTER_SN and doctor, and the output parameter is historical OPID list.
[0045] Example 1 (Emergency Shift Handover Scenario): After day shift doctor A sees a patient for the first time, the system generates a first-visit OPID and writes it to the patient record table. Night shift doctor B logs in, selects the patient, and the server determines that B is the doctor continuing the consultation and opens the emergency department's continuation medical record template by default. Doctor B clicks the "Continue" button, and the system creates a temporary OPID. If doctor B only views the medical history without writing anything and then closes the page, the temporary OPID is automatically discarded, and no consultation record is generated. Doctor B views the complete medical history after it has been pieced together (the part written by doctor A is read-only) in the continuation interface, writes the progress notes for this shift in the continuation area at the end, and saves it. The system persists the temporary OPID and updates the LAST_OPID, and the continuation content is stored independently under the new OPID. The next day, doctor A can view and access their own first-visit record through the "Historical Consultations" button, and modification permissions are limited to the scope of the first-visit OPID.
[0046] Example 2 (Specialist Consultation Continued Reading Scenario): Emergency patients require specialist consultation after being seen by the initial attending physician. The consulting physician selects the patient and is designated as the continuing physician. After clicking "Continue," the physician views the complete medical history and writes consultation opinions on the continued reading interface, saving the record to create an independent consultation OPID. If the consulting physician accidentally triggers continued reading before any diagnosis, medical orders, or medical record content is generated, they can directly click "Cancel Continued Reading." The system will verify that there is no associated data under the current OPID, delete the visit record, and roll back the LAST_OPID. If consultation opinions have already been written, the relevant content must be cleared before cancellation.
[0047] This embodiment also provides an electronic device, including a processor and a memory. The memory stores a computer program, and when the processor executes the computer program, it implements the method described in any of the above-described method embodiments. The electronic device can be a server for a medical information system or a doctor's workstation.
[0048] This embodiment also provides a computer-readable storage medium storing a computer program thereon, which, when executed by a processor, implements the method described in any of the above method embodiments. The computer-readable storage medium includes, but is not limited to, disk storage, read-only memory (ROM), random access memory (RAM), flash memory, etc.
[0049] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included within the protection scope of the present invention.
Claims
1. A method for collaborative medical record continuation in outpatient and emergency departments by multiple doctors, characterized in that, Performed by the medical information system server and doctor workstations, including: The server receives the doctor's selection of a target patient from the patient list; the server queries the set of medical records that the target patient has in the current registration period based on the registration serial number REGISTER_SN, and each medical record is associated with a unique medical serial number OPID and the identifier of the attending doctor; The server determines the current logged-in doctor's role as a patient: when the set of medical records is empty, the current logged-in doctor is identified as the first-visit doctor; when the set of medical records is not empty and there is no record in it with a patient identifier equal to the current logged-in doctor, the current logged-in doctor is identified as a follow-up doctor; when there is a record in the set of medical records with a patient identifier equal to the current logged-in doctor, the current logged-in doctor is identified as a doctor who has already seen patients, and the patient is taken to the consultation page by the doctor's most recent medical record number. In response to the doctor clicking the "Continue" button in the patient list, the server creates a temporary OPID bound to the currently logged-in doctor, and the doctor's workstation opens the medical record continuation editing interface; the temporary OPID remains in a temporary state until the doctor saves any medical data, and is automatically discarded when the page is closed or the patient is switched, and is not written to the medical record table; In the medical record continuation editing interface, the server queries all historical medical record texts under the current registration number except for the current OPID; the doctor's workstation initializes the electronic medical record editor with the first historical medical record, and then inserts subsequent historical medical records into the end of the editor to form a complete medical history view; the historical area is set to read-only permission, and the continuation area is set to edit permission; When a doctor continues a consultation and saves at least one of the diagnostic information, medical order information, or continued medical record content, the server persistently writes the temporary OPID into the consultation record table and updates the latest consultation serial number pointer LAST_OPID in the registration table. When saving a continued medical record, the doctor's workstation only extracts the medical record content under the continued editing node for storage and does not overwrite the medical record content corresponding to the historical OPID. In response to a doctor clicking the "Cancel Renewal" button, the server checks whether there are any uncleared diagnoses, invalidated or unrefunded medical orders, medical documents, treatment orders, or pathology requests under the current OPID. If they exist, cancellation is prevented and a prompt to clean them up is displayed. If they do not exist, the server deletes the medical record corresponding to the current OPID, queries the remaining medical records under the same registration serial number in reverse order of the medical record time, and writes the OPID of the latest record back to the LAST_OPID field of the registration table. Among all medical records queried by registration serial number, the OPID corresponding to the first record with the earliest consultation time is the initial consultation OPID, and the initial consultation OPID does not support cancellation of renewal.
2. The method for collaborative medical record continuation in outpatient and emergency departments according to claim 1, characterized in that, Before receiving the doctor's selection operation, the system also includes: the configuration of the server's medical record continuation function switch and the configuration of associated departments; when the associated department configuration is empty, the continuation function is enabled for all departments; when the associated department configuration is not empty, the continuation function is enabled only for departments in the configured department list.
3. The method for collaborative medical record continuation in outpatient and emergency departments according to claim 1, characterized in that, It also includes the patient reception routing steps: if the current doctor is the first-visit doctor, the first-visit medical record template will be opened by default; If the current doctor is the doctor continuing the consultation, the medical record continuation template will be opened by default. If the current doctor is a doctor you have already seen, the default page will open the consultation page corresponding to the doctor's most recent consultation number.
4. The method for collaborative medical record continuation in outpatient and emergency departments according to claim 1, characterized in that, The process of forming a complete medical history view includes: arranging historical medical records in ascending order of visit time; initializing the document tree of the electronic medical record editor using the content of the first historical medical record as template data; appending subsequent historical medical records sequentially to the end of the editor as document fragments; reassigning globally unique identifiers to historical structured nodes while maintaining the parent-child hierarchy of nodes to avoid identifier conflicts; inserting the current continuing physician's continuation medical record template at the end of the editor; the historical area is implemented by setting read-only permissions for document nodes in the electronic medical record editor's document tree; the continuation area is the area corresponding to the continuation editing node in the document tree, set to edit permissions, and only extracting the medical record content under the continuation editing node when saving.
5. The method for collaborative medical record continuation in outpatient and emergency departments according to claim 1, characterized in that, The verification of whether there are any diagnoses that have not been cleared, medical orders that have not been cancelled or refunded, medical documents, treatment orders, or pathology applications under the current OPID includes: determining that there are diagnoses that have not been cleared when there is at least one record in the diagnosis table that is associated with the current OPID; determining that there are medical orders that have not been cancelled or refunded when the status of the medical order is neither cancelled nor refunded; determining that there is corresponding associated data when there is at least one record in the medical document table, treatment application form, or pathology application form that is associated with the current OPID.
6. The method for collaborative medical record continuation in outpatient and emergency departments according to claim 1, characterized in that, It also includes historical patient visit navigation steps: in response to the operation of a doctor who has already received a patient click the "historical patient visit" button, the server queries all historical patient visit records of the current doctor for the current registration number and displays them in a table; After a doctor selects a record and confirms entry, the consultation page corresponding to that OPID is opened. The medical record interface displays the latest assembled complete medical record content. Modification permissions for diagnoses, medical orders, and medical records are limited to the selected OPID.
7. The method for collaborative medical record continuation in outpatient and emergency departments according to claim 1, characterized in that, The update of the latest patient visit serial number pointer LAST_OPID in the registration table also includes updating the latest attending physician, latest attending department, and latest appointment time fields in the registration table; the patient list is filtered based on LAST_OPID to filter currently active patient visit records.
8. A multi-doctor collaborative medical record continuation system for outpatient and emergency departments, characterized in that, Deployed within the hospital's intranet, the system includes a server-side component and a doctor's workstation. The configuration management module connects to the system parameter database to store and read the medical record continuation function switch, associated department configuration, and diagnosis continuation sub-switch, providing a basis for other modules to determine function activation. The patient list module, connected to the registration table and the medical record table, is used to display the list of patients waiting to be seen, filter currently active medical records according to LAST_OPID, provide "Continue" and "Historical Treatment" buttons in the operation column, and pass the doctor's operation request to the continuation judgment module and the medical record management module. The continuation diagnosis module is used to receive the registration serial number and current doctor identifier from the patient list module, query the set of medical records, output the continuation diagnosis result and the list of historical medical records, and transmit them to the patient list module and the medical record editing module respectively. The medical record management module connects to the registration table and the medical record table. It is used to create temporary OPIDs, persist medical records, delete and rewrite medical records, and maintain LAST_OPID pointers and related fields. The medical record editing module, connected to the electronic medical record editor component, is used to receive historical medical record data provided by the continuation judgment module, perform medical record splicing, node permission setting and extraction and saving of continuation content, and work with the medical record management module to complete delayed persistence triggering. The cancellation continuation verification module is connected to the diagnosis form, medical order form, medical document form, treatment request form, and pathology request form. It is used to perform an existence verification of associated data before cancellation of continuation. After the verification is passed, the medical record management module is called to perform deletion and rollback operations. Each module uses the registration serial number REGISTER_SN as the anchor point for a registration cycle, the medical visit serial number OPID as the isolation unit for each doctor's medical visit data, and maintains the consistency of the latest medical visit status within the registration cycle through the LAST_OPID pointer.
9. An electronic device, characterized in that, The method includes a processor and a memory, wherein the memory stores a computer program, and the processor executes the computer program to implement the outpatient and emergency multi-doctor collaborative medical record continuation method as described in any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, implements the outpatient and emergency multi-doctor collaborative medical record continuation method as described in any one of claims 1 to 7.
