A medicine-inventory-based automatic coding management method and system
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-05-21
- Publication Date
- 2026-08-11
AI Technical Summary
[0004]针对现有技术的不足,本发明提供了一种基于药品入库的自动赋码管理方法及系统,解决了追溯码在入库过程中重复出现时易导致与入库单据关联不一致而引发入库差错的问题
1、本发明通过重复分型裁决并结合内部与外部轨迹核验回执校验,在追溯码重复出现时区分操作重复与业务冲突以及风险重复,对冲突或风险追溯码自动冻结并触发复核闭环,从而达到提升入库环节追溯码与单据绑定一致性、降低入库差错发生率并提高处置可控性的效果。
Smart Images

Figure CN122550197A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of inventory management technology, specifically to an automatic coding management method and system based on drug warehousing. Background Technology
[0002] Drug warehousing is a crucial step in pharmaceutical distribution and medical institution warehousing management. It typically requires the acceptance, registration, and creation of warehousing records for incoming drugs to ensure consistency between batch information, expiration date, and source of supply with inventory data. With the advancement of drug traceability systems, traceability codes are commonly attached to drug packaging. During warehousing operations, these codes are often collected by scanning and linked to warehousing documents to achieve traceability management of drugs from warehousing to distribution. Therefore, automatic coding management based on drug warehousing usually involves processes such as warehousing document data acquisition, traceability code collection, event logging, and associated storage. In existing technologies, traceability codes are often implemented in the warehousing process using a scan-and-bind method, meaning that the collected traceability code is directly written into the warehousing details and included in the quantity received during the receiving process.
[0003] However, in current technology, when traceability codes appear repeatedly due to repeated scanning, cross-document collection, or differences in information entry, only duplicate prompts or simple interception are provided. There is a lack of effective differentiation and consistency guarantee mechanisms for duplicate situations, which can easily lead to inconsistencies between traceability codes and inbound documents, resulting in inbound errors. Summary of the Invention
[0004] To address the shortcomings of existing technologies, this invention provides an automatic coding management method and system based on drug warehousing, which solves the problem that repeated appearance of traceability codes during the warehousing process can easily lead to inconsistencies in association with warehousing documents, resulting in warehousing errors.
[0005] To achieve the above objectives, the present invention provides the following technical solution: an automatic coding management method based on drug warehousing, comprising: S1. Obtain drug warehousing document data, which includes warehousing document number, warehousing document line number, drug identification information, batch number, expiration date, supplier identification, and institution identification information; S2. Collect traceability codes and generate code events during the drug warehousing process. The code event includes traceability codes, identification information for associating with the warehousing document data, collection time, and collection terminal identification. S3. Perform a duplicate classification decision on the code event, and classify the duplicate traceability code into operation duplicate and business conflict duplicate; S4. Perform trajectory verification on the traceability code that meets the preset verification conditions. The trajectory verification includes internal trajectory verification and external trajectory verification, and obtain internal verification receipt and external verification receipt. S5. Verify the internal verification receipt and the external verification receipt. The verification includes verifying the validity of the receipt based on the verification field in the receipt, and outputting the decision result based on the consistency of the verification results of the two and the preset credibility priority rules. S6. When the ruling result is repeated business conflict or repeated risk, the corresponding traceability code is set to a frozen state and the reason for freezing, as well as the internal verification receipt and the external verification receipt, are bound together, and the review process is triggered. Wherein, the risk repetition is a repetition situation determined based on the existence of a preset prohibited historical event in at least one of the indication traceability codes in the internal verification receipt and the external verification receipt; S7. Based on the review results of the review process, the status of the traceability code that is in a frozen state is changed to warehousing acceptance, rejection or invalidation to complete the closed-loop processing.
[0006] Preferably, step S3 specifically includes: querying the historical binding records corresponding to the traceability code to obtain historical field information; The consistency of the field information of the code event with the historical field information is compared. The field information includes the warehouse entry order number, batch number, expiration date, supplier identifier, and organization identifier. When the consistency comparison result is consistent, the duplicate traceability code is determined to be an operation duplicate; when the consistency comparison result is inconsistent, the duplicate traceability code is determined to be a business conflict duplicate.
[0007] Preferably, when the traceability code is repeated, the code event corresponding to the traceability code is merged so that the traceability code is counted only once in the warehouse entry document data, and the identification information of the repeated operation is recorded.
[0008] Preferably, the traceability codes that meet the preset verification conditions in S4 include: traceability codes that do not have historical binding records, traceability codes that are determined to be duplicates of business conflicts, and traceability codes that meet preset risk triggering conditions. The preset risk triggering conditions are related to the data collection time window, differences in data collection terminals, and differences in institutions.
[0009] Preferably, the internal trajectory verification includes: The traceability code is queried in the internal circulation record database to obtain the historical event information corresponding to the traceability code; An internal verification receipt is generated based on the historical event information; The internal verification receipt is associated with the traceability code and the code event and stored together. The internal verification receipt includes a query number, a receipt source identifier, a traceability code, historical event summary information, and a timestamp.
[0010] Preferably, the external trajectory verification includes: Initiate a verification request for the traceability code to an external traceability verification service; Receive external verification receipts and establish an associated storage of the external verification receipts, traceability codes, and code events; The external verification receipt includes a query number, a receipt source identifier, a traceability code, a verification result type, a verification result field, and a timestamp.
[0011] Preferably, S5 specifically includes: The internal verification receipt and the external verification receipt are validated for validity, and the validity validation includes validation based on the verification field of the receipt; When the verification results of the internal verification receipt and the external verification receipt are inconsistent, the target receipt for outputting the decision result is determined according to the preset credibility priority rule. The ruling result is output based on the verification result type of the target receipt.
[0012] Preferably, S6 specifically includes: Set the traceability codes for cases where the ruling indicates repeated business conflicts or repeated risks to a frozen state. When the traceability code is in a frozen state, it is prohibited to include the traceability code in the quantity of goods received and to proceed to the shelf confirmation process. After the review process is triggered, when the review process meets the preset review evidence conditions, the traceability code is allowed to move from the frozen state to the warehouse receipt state.
[0013] Preferably, when the traceability code is set to a frozen state, a freeze reason code is generated and a recommended action is output, including: Establish an association between the freeze reason code, the recommended action, and at least one of the internal verification receipt and the external verification receipt; The recommended action includes at least one of review, rejection, random inspection, and reporting, and the triggering basis corresponding to the freeze reason code is the verification result field of the internal verification receipt or the external verification receipt.
[0014] An automatic coding management system based on drug warehousing, the system comprising: The inbound task module retrieves drug inbound document data. The code event collection module collects traceability codes and generates code events during the drug warehousing process. The duplicate classification decision module is used to perform duplicate classification decision on the code event, and classify the duplicate trace code situation into operation duplicate and business conflict duplicate; The trajectory verification module performs trajectory verification on traceability codes that meet preset verification conditions. The trajectory verification includes internal trajectory verification and external trajectory verification to obtain internal verification receipts and external verification receipts. The receipt verification and adjudication module verifies the validity of the internal and external verification receipts and outputs the adjudication result based on the consistency of the verification results and the preset credibility priority rules. The frozen review closed-loop module sets the corresponding traceability code to a frozen state and triggers the review process when the adjudication result is repeated business conflict or repeated risk. In the frozen state, the traceability code is associated with the frozen reason code, the recommended handling action, and at least one of the internal verification receipt and external verification receipt. Based on the review result, the traceability code status is migrated to warehouse receipt, rejection or invalidation. The audit trail module records code events, verification receipts, adjudication results, and traceability code status migration information.
[0015] This invention provides an automatic coding management method and system based on drug warehousing. It has the following beneficial effects: 1. This invention distinguishes between repeated operation and business conflict and risk repetition when the traceability code appears repeatedly by combining repeated classification adjudication with internal and external trajectory verification receipts. It automatically freezes the conflicting or risky traceability codes and triggers a closed-loop review, thereby improving the consistency of traceability code binding with documents in the warehousing process, reducing the error rate of warehousing, and improving the controllability of handling.
[0016] 2. This invention generates a freeze reason code and recommended action during the freeze process, and links and stores them with the verification receipt and its verification result field to form an interpretable and traceable chain of evidence. At the same time, by auditing and tracking the recorded events, adjudication results and status transition information, it achieves the effects of improving audit efficiency, facilitating review and accountability, and increasing management transparency.
[0017] 3. This invention merges repeated operations, so that the traceability code is only counted once in the warehouse entry document, reducing the impact of repeated collection on quantity accuracy and consistency between accounts and actual goods. The verification and review process is only initiated for traceability codes that meet the verification conditions, thereby achieving the effect of reducing verification costs and improving warehouse entry efficiency while controlling risks. Attached Figure Description
[0018] Figure 1 This is a flowchart of an automatic coding management method based on drug warehousing according to the present invention; Figure 2 This is an architecture diagram of an automatic coding management system based on drug warehousing according to the present invention. Detailed Implementation
[0019] The technical solution of the present invention will now be clearly and completely described with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of the present invention, and not all of them. All other embodiments obtained by those skilled in the art based on the embodiments of the present invention without creative effort are within the scope of protection of the present invention.
[0020] Please see the appendix Figure 1 This invention provides an automatic coding management method based on drug warehousing, comprising: S1. Obtain drug warehousing document data, which includes warehousing document number, warehousing document line number, drug identification information, batch number, expiration date, supplier identification, and institution identification information; Specifically, when creating or receiving an inbound task, the system retrieves and caches drug inbound document data from the WMS / ERP or higher-level business system. This data includes the inbound document number, inbound line number, drug identification information (such as name / specification / dosage form / approval number, etc., used to uniquely identify the drug), batch number, expiration date, supplier identification, and institution identification. This information serves as the business benchmark for subsequent code event association, duplicate classification, and trajectory verification. For example, a warehouse receives inbound document number RK202 from supplier A. The first line of the entry details, "60123001", corresponds to drug X (10 boxes / carton), batch number B202601, and expiry date 2027-01-31. After obtaining and structuring the above fields, when a traceability code is collected at the entry site, the entry line to which it belongs can be quickly located based on this document. This avoids the inability to bind or the wrong binding of the traceability code due to missing document information. This provides a consistent data reference for distinguishing between repeated operations and repeated business conflicts, as well as for the closed-loop handling of freeze review when repeated occurrences occur.
[0021] S2. Collect traceability codes and generate code events during the drug warehousing process. The code event includes the traceability code, identification information used to associate warehousing document data, collection time, and collection terminal identification. Specifically, the warehousing operation uses a handheld terminal to scan the traceability code on the outer packaging of the medicine. After a successful scan, the data acquisition terminal binds the traceability code to the current warehousing task context and generates a code event record. The code event includes the traceability code, identification information used to associate the warehousing document data (such as the warehousing document number and warehousing line number, used to point to the corresponding warehousing details), the acquisition time, and the acquisition terminal identifier (such as the terminal ID or device serial number). The code event is written to the event storage for subsequent steps to query and call, so that the traceability code acquisition result can establish a definite association with the warehousing document data, avoiding misbinding or omission caused by the traceability code not being able to be collected to the corresponding warehousing line. For example, for the first line of warehousing document number RK20260123001 in S1, after the operation terminal scans and obtains the traceability code "TC123…789" in the interface of that line, it generates a code event and saves it as follows: ; If the traceability code is scanned again or enters the verification process later, the associated inbound document data can be located directly based on the identification information.
[0022] S3. Perform duplicate classification adjudication on code events, classifying duplicate traceability codes into operational duplicates and business conflict duplicates; Furthermore, S3 specifically includes: querying the historical binding records corresponding to the traceability code to obtain historical field information; The field information of the code event is compared with the historical field information. The field information includes the entry order number, batch number, expiration date, supplier identifier, and organization identifier. When the consistency comparison result is consistent, the duplicate traceability code is determined to be an operation duplicate; when the consistency comparison result is inconsistent, the duplicate traceability code is determined to be a business conflict duplicate.
[0023] Specifically, upon receiving a code event generated by S2, a search is initiated in the local binding library / event library for the traceability code in the code event to check whether the traceability code already has a historical binding record. If the search is successful, the historical field information associated with the traceability code (such as the warehouse entry number, batch number, expiration date, supplier identifier, and organization identifier corresponding to the historical record) is read and used to make subsequent consistency judgments with the field information of the current code event. This provides a benchmark for "duplicate classification adjudication" and avoids directly judging it as abnormal based solely on "whether it has occurred" and thus affecting normal operation efficiency.
[0024] Furthermore, in one embodiment, the field information of the code event is compared for consistency with historical field information. The field information includes the inbound order number, batch number, expiration date, supplier identifier, and organization identifier. This consistency comparison can be formally represented as: Let the code event field vector... Historical field vector The consistency indicator function is ; in , Indicates an indicator function; the symbol means: This is the entry order number. For batch number, Validity period For supplier identification, For organizational identification, and These represent code events and historical records in the fields, respectively. The value that can be taken on.
[0025] In one embodiment, when the consistency comparison result is consistent, the duplicate traceability code is determined to be an operation duplicate and is processed according to the subsequent merging strategy. When the consistency comparison result is inconsistent, the duplicate traceability code is determined to be a business conflict duplicate and enters the subsequent verification / freezing process.
[0026] Furthermore, in the case of duplicate traceability codes, when the operation is repeated, the code event corresponding to the traceability code is merged so that the traceability code is counted only once in the inbound document data, and the identification information of the repeated operation is recorded.
[0027] Specifically, when a duplicate traceability code is determined to be an operation duplicate, multiple barcode events generated by the same traceability code within the same inbound document association range are merged: the traceability code is used as the primary key to merge the barcode events, one of which is designated as the primary event and used for subsequent inbound binding and counting. Other duplicate barcode events are no longer included in the quantity accumulation, thus ensuring that the traceability code is counted only once in the inbound document data. At the same time, operation duplicate identification information (such as duplicate identifier, associated primary event identifier, and duplicate occurrence) is written to the merged duplicate barcode events. (Time, etc.) are used for subsequent auditing and traceability. For example, for the first line of the inbound order number RK20260123001, the traceability code TC123…789 was scanned consecutively by the same inbound task at 10:05:12 and 10:05:20, generating two code events. After determining that the operation is duplicated, the event corresponding to 10:05:12 is retained as the main event and counted once. The event corresponding to 10:05:20 is marked as a duplicate operation and associated with the main event, thereby avoiding duplicate counting from affecting the accuracy of the inbound quantity and retaining record evidence of duplicate occurrence.
[0028] S4. Perform trajectory verification on traceability codes that meet the preset verification conditions. Trajectory verification includes internal trajectory verification and external trajectory verification, and obtain internal verification receipts and external verification receipts. Furthermore, the traceability codes that meet the preset verification conditions in S4 include: traceability codes that do not have historical binding records, traceability codes that are determined to be duplicates due to business conflicts, and traceability codes that meet the preset risk triggering conditions. Among them, the preset risk triggering conditions are related to the data collection time window, differences in data collection terminals, and differences in institutions.
[0029] Specifically, after completing the S3 classification, it is determined whether the traceability code should be included in the trajectory verification. The traceability codes that meet the preset verification conditions include: traceability codes that cannot be found in the historical binding records, traceability codes that are judged as business conflict duplicates in S3, and traceability codes that meet the preset risk trigger conditions. Among them, the preset risk trigger conditions are related to the collection time window, the difference of collection terminal and the difference of institution. They are used to pre-screen abnormal collection patterns such as "multiple collections in a short period of time", "cross-terminal collection" and "cross-institutional occurrence" in the warehousing stage, so as to avoid the risk delay caused by relying solely on manual experience to discover anomalies. In one embodiment, for traceability codes that meet preset verification conditions, trajectory verification is performed. Trajectory verification includes internal trajectory verification and external trajectory verification: internal trajectory verification obtains the traceability code's summary of the unit or historical events by accessing the internal circulation record database and forms an internal verification receipt; external trajectory verification obtains the external status or key historical event information of the traceability code by calling the external traceability verification service interface and forms an external verification receipt. The two serve as the basis for subsequent S5 verification and adjudication, thereby improving the verification coverage and reliability by using "internal traceability" and "external receipt" at the warehousing stage. For example, if traceability code TC123…789 has no historical binding record in this system and is collected by terminals PDAX001 and PDAX007 within 2 minutes in the same warehousing operation, after triggering the preset risk trigger condition, it enters the trajectory verification: on the one hand, it queries the internal circulation record database and finds that there is no historical warehousing record for the traceability code and generates an internal verification receipt; on the other hand, it initiates a verification request to the external traceability verification service and receives an external verification receipt (e.g., returning "status unknown / requires verification" or returning a specific status code), thereby providing data basis for subsequent steps to make decisions based on receipt consistency and credibility priority, and to enter the freeze verification closed loop when necessary.
[0030] Furthermore, internal trajectory verification includes: The traceability code is queried in the internal circulation record database to obtain the historical event information corresponding to the traceability code; Generate internal verification receipts based on historical event information; The internal verification receipt is associated with and stored with the traceability code and code event. The internal verification receipt includes the query number, receipt source identifier, traceability code, historical event summary information and timestamp.
[0031] Specifically, in one embodiment, the internal trajectory verification first queries the traceability code in the internal circulation record database to obtain the historical event information corresponding to the traceability code. The historical event information may include a summary field of past inbound, outbound, return, and cancellation events, including the traceability code. An internal verification receipt is generated based on the historical event information, and the internal verification receipt is associated with the traceability code and the code event for storage, so as to facilitate subsequent adjudication, freezing reason tracing, and auditing. The internal verification receipt includes the traceability number, receipt source identifier, traceability code, historical event summary information, and timestamp. For example, for the traceability code TC123...789, the internal circulation record database query returns "no historical inbound / outbound events", an internal verification receipt is generated, and it is associated with and saved with the code event corresponding to the traceability code. If the external receipt returns a different conclusion, an adjudication can be output by combining the receipt validity and priority rules, and the internal receipt is retained as part of the adjudication basis.
[0032] Furthermore, external trajectory verification includes: Initiate a verification request for the traceability code to an external traceability verification service; Receive external verification receipts and associate and store them with traceability codes and code events; The external verification receipt includes the query number, receipt source identifier, traceability code, verification result type, verification result field, and timestamp.
[0033] Specifically, for the traceability code to be verified, a verification request is initiated to an external traceability verification service. The request parameters must include at least the traceability code and an organization identifier used for request routing and authorization. After the external traceability verification service returns an external verification receipt, the system receives the external verification receipt and associates it with the traceability code and code event for storage. This allows the external verification receipt to participate in validity verification, result consistency judgment, and credibility priority adjudication in subsequent verifications, together with the internal verification receipt. The external verification receipt includes a query number, receipt source identifier, traceability code, verification result type, verification result field, and timestamp. The verification result type is used to characterize the category of the external verification conclusion, and the verification result field is used to carry the key status information corresponding to that category. This allows the external verification result to participate in subsequent adjudication and freezing reason association in a structured manner. S5. Verify the internal verification receipt and the external verification receipt. The verification includes verifying the validity of the receipt based on the verification fields in the receipt, and outputting the decision result based on the consistency of the verification results of the two and the preset credibility priority rules. Furthermore, S5 specifically includes: Perform validity checks on internal and external verification receipts. The validity checks include verifying the verification fields based on the receipts. When the verification results of the internal verification receipt and the external verification receipt are inconsistent, the target receipt for outputting the adjudication result is determined according to the preset credibility priority rule. The decision result is output based on the verification result type of the target receipt.
[0034] Specifically, in one embodiment, while simultaneously obtaining the internal kernel receipt R in With external kernel receipt R out Next, both are first validated. Validation includes verifying the validation fields based on the receipt to rule out false positives caused by tampering with the receipt content or an untrustworthy source. For example, for any receipt R (which can be...) or ), and record its core content as The validation field is denoted as By verifying the function Validity determination obtained: ; in, This indicates that the receipt is valid. This indicates that the receipt is invalid. As an indicator function, through verification, it only participates in subsequent consistency judgment and decision output if the receipt is valid, thereby improving the credibility and stability of the data entry verification results; In one embodiment, for and The verification results are evaluated for consistency. If the two verification results are consistent, the consistent conclusion is directly adopted as the decision. If the two verification results are inconsistent, the target receipt for outputting the decision is determined according to the preset credibility priority rule. Credibility priority rules can be determined based on factors such as the validity of the receipt, the credibility level of the source of the receipt, and the timeliness of the receipt, and can be formalized as assigning credibility scores to receipts. And select the one with the higher score as the target reply: ; Where α, β, and γ are preset weights. Indicate whether the source of the receipt belongs to the trusted domain. Indicates whether the receipt timestamp falls within the preset valid time window; after determining the target receipt Subsequently, the decision result is output based on the verification result type of the target receipt, so that a definite output can still be given in the event of conflict between internal and external verification results, and a basis for subsequent freeze decisions can be provided. For example, for the traceability code TC123...789, obtain This indicates "No historical events found (NORMAL)" and the validation passed. This indicates the presence of a "forbidden historical event" and that the verification passed. When the preset credibility priority rule is set to "external receipts take precedence over internal receipts when verification passes and within the valid time window," the score selection is as follows: Based on this, the output decision is "repeated risk / requires freezing action", thus avoiding missed interception due to incomplete internal records alone, while retaining internal and external receipts and their verification results as the basis for decision to support subsequent audits and reviews.
[0035] S6. When the ruling result is that the business conflict is repeated or the risk is repeated, the corresponding traceability code will be frozen and the reason for freezing, as well as the internal verification receipt and the external verification receipt, will be bound, and the review process will be triggered. Among them, risk duplication is a duplication situation determined based on the existence of a preset prohibited historical event in at least one of the indication traceability codes in the internal verification receipt and the external verification receipt; Furthermore, S6 specifically includes: Set the traceability codes for cases where the ruling indicates repeated business conflicts or repeated risks to a frozen state. When the traceability code is frozen, it is prohibited to include the traceability code in the quantity of goods received and to proceed to the shelf confirmation process. After the review process is triggered, the traceability code is allowed to move from the frozen state to the warehouse receipt state only if the review process meets the preset review evidence conditions.
[0036] Specifically, when the ruling indicates duplicate business conflicts or duplicate risks, the corresponding traceability code will be frozen, and the reason for the freeze will be linked to the verification evidence and stored accordingly. The verification evidence includes internal verification receipts. External verification receipt This is to allow for direct retrieval of the evidence chain that triggered the freeze during subsequent review. The risk of duplicated events is defined as a duplicate situation determined by at least one indication traceability code in both internal and external verification receipts within a preset prohibited historical event. This can be formally represented by the prohibited event flag in the receipt result field: Let... Indicates whether the receipt R refers to a prohibited historical event, defined as follows. The risk of repeated judgment is then: ; in, For internal verification receipt, For external verification receipt, For indicator functions, This indicates that the risk is repeated; through this freeze trigger mechanism, traceability codes with prohibited historical events can be intercepted in advance during the warehousing stage, avoiding the risky traceability codes from entering the inventory and then being traced and dealt with. In one embodiment, traceability codes whose adjudication result is repeated business conflict or repeated risk are set to a frozen state, and the status field of the traceability code is entered into the system. Set as Simultaneously, a review process is triggered to request supplementary or verified evidence. Under frozen status, the system sets access control constraints on inbound business actions, preventing the traceability code from participating in the inbound quantity statistics and prohibiting it from entering the shelving confirmation process. The access control logic can be represented as follows: ; in, This indicates that the tracking number is prohibited from being recorded as part of the warehousing completion and shelving confirmation. After the review process is triggered, the tracking number is allowed to move from the frozen state to the warehousing receipt state only if the review process meets the preset review evidence conditions. To indicate whether the verification evidence meets the preset conditions, the access control system will be unfrozen. ; in, This indicates that migration to the inbound receiving status is permitted; For example, traceability code TC123...789 was deemed a duplicate risk due to external verification receipts. The result field indicates the existence of prohibited historical events (corresponding to...) ), and thus set its state to A freeze record is generated, which includes the freeze reason (e.g., "prohibited historical event triggered") and... , The index is used, but at this point, the traceability code is not counted in the completed inventory quantity and cannot be entered into the putaway confirmation process. It awaits the upload and verification of pre-set verification evidence (such as delivery documents, acceptance records, etc.) by the reviewer to ensure compliance. Only after this process is completed can the code be moved from a frozen state to an inbound receiving state, thereby ensuring inbound efficiency while achieving controlled handling and closed-loop management of conflict and risk traceability codes.
[0037] Furthermore, when the traceability code is set to a frozen state, a freeze reason code is generated and recommended actions are output, including: Establish an association between the freeze reason code, the recommended action, and at least one of the internal verification receipt and the external verification receipt; The recommended actions include at least one of the following: review, rejection, random inspection, and reporting. The triggering basis corresponding to the freeze reason code is the verification result field of the internal verification receipt or the external verification receipt.
[0038] Specifically, when a traceability code is frozen due to duplicate business conflicts or risks, a freeze reason code is generated simultaneously, and a recommended action is output to form an associated record of freeze, reason, evidence, and action suggestion. The freeze reason code is used to structurally identify the reason for the freeze, and the recommended action guides the handling path after the freeze. The recommended action may include at least one of review, rejection, random inspection, and reporting. The freeze reason code and recommended action are associated with at least one of internal and external verification receipts, and the triggering basis corresponding to the freeze reason code is recorded as the internal verification receipt. or external verification receipt The verification result field ensures that the reason for freezing can be traced back as evidence. For example, if the traceability code TC123…789 returns "verification result type is FORBIDDEN" in the external verification receipt and its verification result field contains a prohibited historical event flag, a freezing reason code Reason_01 is generated, and recommended actions for sampling and reporting are output. Reason_01, recommended actions, and the query number and verification result field summary of the external verification receipt are linked and saved. When reviewing the freezing traceability code, the reviewer can directly view the trigger basis corresponding to the freezing reason code and complete the sampling or reporting according to the recommended actions. Then, based on the review conclusion, the status transition of receiving, rejecting, or canceling is performed in the subsequent execution, thereby improving the interpretability and closed-loop efficiency of freezing disposal.
[0039] S7. Based on the review results of the review process, the status of the traceability code that is in a frozen state will be changed to warehousing receipt, rejection or invalidation to complete the closed-loop processing.
[0040] Specifically, after the traceability code is frozen and the review process is triggered, the review conclusion is received and the status transition is executed. If the review is passed and the preset review evidence conditions are met, the traceability code is transitioned from frozen to warehousing acceptance and subsequent warehousing completion and shelf confirmation are allowed. If the review confirms that there is a business conflict or risk, the traceability code is transitioned from frozen to rejected to prevent warehousing. If the review determines that the code was mistakenly collected, damaged and cannot be verified, the traceability code is transitioned from frozen to invalid and the reason and related evidence are recorded, thereby completing the closed-loop handling of the frozen traceability code.
[0041] Please see the appendix Figure 2 An automatic coding management system based on drug warehousing, the system includes: The inbound task module retrieves drug inbound document data. The code event collection module collects traceability codes and generates code events during the drug warehousing process. The duplicate classification adjudication module is used to perform duplicate classification adjudication on code events, classifying duplicate trace code situations into operational duplicates and business conflict duplicates; The trajectory verification module performs trajectory verification on traceability codes that meet preset verification conditions. Trajectory verification includes internal trajectory verification and external trajectory verification to obtain internal verification receipts and external verification receipts. The receipt verification and adjudication module verifies the validity of internal and external verification receipts and outputs adjudication results based on the consistency of verification results and preset credibility priority rules. The frozen review closed-loop module sets the corresponding traceability code to a frozen state and triggers the review process when the adjudication result is repeated business conflict or repeated risk. In the frozen state, the traceability code is associated with the frozen reason code, the recommended action, and at least one of the internal verification receipt and external verification receipt. Based on the review result, the traceability code status is migrated to warehousing acceptance, rejection, or invalidation. The audit trail module records code events, verification receipts, adjudication results, and traceability code status migration information.
[0042] Specifically, the warehousing task module acquires and structures the warehousing document data; the code event collection module collects traceability codes at the warehousing site, generates code events, and establishes a connection with the warehousing documents; the duplicate classification and adjudication module classifies duplicate collections based on historical binding records, distinguishing between operational duplicates and business conflict duplicates; for traceability codes that meet the verification conditions, the trajectory verification module performs internal and external trajectory verification to generate verification receipts; the receipt verification and adjudication module verifies the validity of the receipts and outputs adjudications based on the consistency and credibility priority rules; when the adjudication is a business conflict duplicate or a risk duplicate, the freeze review closed-loop module freezes the traceability code and generates a freeze reason code and recommended action, stores the corresponding verification receipts, and triggers the review process; after review, the traceability code status is transitioned to warehousing acceptance, rejection, or invalidation to complete the closed loop; and the audit traceability module records the code events, receipts, adjudications, and status transitions throughout the entire process for easy subsequent traceability and auditing.
[0043] Although embodiments of the invention have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the appended claims and their equivalents.
Claims
1. An automatic coding management method based on drug warehousing, characterized in that, include: S1. Obtain drug warehousing document data, which includes warehousing document number, warehousing document line number, drug identification information, batch number, expiration date, supplier identification, and institution identification information; S2. Collect traceability codes and generate code events during the drug warehousing process. The code event includes traceability codes, identification information for associating with the warehousing document data, collection time, and collection terminal identification. S3. Perform a duplicate classification decision on the code event, and classify the duplicate traceability code into operation duplicate and business conflict duplicate; S4. Perform trajectory verification on the traceability code that meets the preset verification conditions. The trajectory verification includes internal trajectory verification and external trajectory verification, and obtain internal verification receipt and external verification receipt. S5. Verify the internal verification receipt and the external verification receipt. The verification includes verifying the validity of the receipt based on the verification field in the receipt, and outputting the decision result based on the consistency of the verification results of the two and the preset credibility priority rules. S6. When the ruling result is repeated business conflict or repeated risk, the corresponding traceability code is set to a frozen state and the reason for freezing, as well as the internal verification receipt and the external verification receipt, are bound together, and the review process is triggered. Wherein, the risk repetition is a repetition situation determined based on the existence of a preset prohibited historical event in at least one of the indication traceability codes in the internal verification receipt and the external verification receipt; S7. Based on the review results of the review process, the status of the traceability code that is in a frozen state is changed to warehousing acceptance, rejection or invalidation to complete the closed-loop processing.
2. The automatic coding management method based on drug warehousing according to claim 1, characterized in that, S3 specifically includes: querying the historical binding records corresponding to the traceability code to obtain historical field information; The consistency of the field information of the code event with the historical field information is compared. The field information includes the warehouse entry order number, batch number, expiration date, supplier identifier, and organization identifier. When the consistency comparison result is consistent, the duplicate traceability code is determined to be an operation duplicate; when the consistency comparison result is inconsistent, the duplicate traceability code is determined to be a business conflict duplicate.
3. The automatic coding management method based on drug warehousing according to claim 2, characterized in that, When the traceability code is repeated, the code event corresponding to the traceability code is merged so that the traceability code is counted only once in the inbound document data, and the identification information of the repeated operation is recorded.
4. The automatic coding management method based on drug warehousing according to claim 1, characterized in that, The traceability codes that meet the preset verification conditions in S4 include: traceability codes that do not have historical binding records, traceability codes that are determined to be duplicates of business conflicts, and traceability codes that meet the preset risk triggering conditions. The preset risk triggering conditions are related to the data collection time window, differences in data collection terminals, and differences in institutions.
5. The automatic coding management method based on drug warehousing according to claim 1, characterized in that, The internal trajectory verification includes: The traceability code is queried in the internal circulation record database to obtain the historical event information corresponding to the traceability code; An internal verification receipt is generated based on the historical event information; The internal verification receipt is associated with the traceability code and the code event and stored together. The internal verification receipt includes a query number, a receipt source identifier, a traceability code, historical event summary information, and a timestamp.
6. The automatic coding management method based on drug warehousing according to claim 1, characterized in that, The external trajectory verification includes: Initiate a verification request for the traceability code to an external traceability verification service; Receive external verification receipts and establish an associated storage of the external verification receipts, traceability codes, and code events; The external verification receipt includes a query number, a receipt source identifier, a traceability code, a verification result type, a verification result field, and a timestamp.
7. The automatic coding management method based on drug warehousing according to claim 1, characterized in that, S5 specifically includes: The internal verification receipt and the external verification receipt are validated for validity, and the validity validation includes validation based on the verification field of the receipt; When the verification results of the internal verification receipt and the external verification receipt are inconsistent, the target receipt for outputting the decision result is determined according to the preset credibility priority rule. The ruling result is output based on the verification result type of the target receipt.
8. The automatic coding management method based on drug warehousing according to claim 1, characterized in that, S6 specifically includes: Set the traceability codes for cases where the ruling indicates repeated business conflicts or repeated risks to a frozen state. When the traceability code is in a frozen state, it is prohibited to include the traceability code in the quantity of goods received and to proceed to the shelf confirmation process. After the review process is triggered, when the review process meets the preset review evidence conditions, the traceability code is allowed to move from the frozen state to the warehouse receipt state.
9. The automatic coding management method based on drug warehousing according to claim 1, characterized in that, When the traceability code is set to a frozen state, a freeze reason code is generated and a recommended action is output, including: Establish an association between the freeze reason code, the recommended action, and at least one of the internal verification receipt and the external verification receipt; The recommended action includes at least one of review, rejection, random inspection, and reporting, and the triggering basis corresponding to the freeze reason code is the verification result field of the internal verification receipt or the external verification receipt.
10. An automatic coding management system based on drug warehousing, characterized in that, An automatic coding management method based on drug warehousing, as described in any one of claims 1-9, wherein the system comprises: The inbound task module retrieves drug inbound document data. The code event collection module collects traceability codes and generates code events during the drug warehousing process. The duplicate classification decision module is used to perform duplicate classification decision on the code event, and classify the duplicate trace code situation into operation duplicate and business conflict duplicate; The trajectory verification module performs trajectory verification on traceability codes that meet preset verification conditions. The trajectory verification includes internal trajectory verification and external trajectory verification to obtain internal verification receipts and external verification receipts. The receipt verification and adjudication module verifies the validity of the internal and external verification receipts and outputs the adjudication result based on the consistency of the verification results and the preset credibility priority rules. The frozen review closed-loop module sets the corresponding traceability code to a frozen state and triggers the review process when the adjudication result is repeated business conflict or repeated risk. In the frozen state, the traceability code is associated with the frozen reason code, the recommended handling action, and at least one of the internal verification receipt and external verification receipt. Based on the review result, the traceability code status is migrated to warehouse receipt, rejection or invalidation. The audit trail module records code events, verification receipts, adjudication results, and traceability code status migration information.