Intelligent fire-fighting management method and system based on two-dimensional code
The QR code-based intelligent fire management system enables closed-loop management of fire hazards throughout the entire process, solving the problems of long rectification cycles, untraceable processes, and difficulty in assigning responsibility in existing technologies, thereby improving management efficiency and standardization.
Patent Information
- Application Number
- CN202611431759.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-09-15
- Publication Date
- 2026-11-24
AI Technical Summary
Current fire safety management relies on manual records and paper documents, lacking a closed-loop management system for the entire process of hazard mitigation and a multi-terminal collaboration mechanism. This results in long rectification cycles, untraceable processes, and difficulties in assigning responsibility.
The system adopts a QR code-based intelligent fire management method. The management terminal generates regional QR codes, and inspection personnel scan the codes to enter the inspection interface to report hazards. The backend service layer verifies permissions and realizes closed-loop management of the entire process, including hazard publicity, rectification reminders, and four-level permission control. Combined with Redis distributed caching and degradation protection mechanisms, the system is ensured to be highly efficient and available.
It has achieved closed-loop management of the entire process from discovery to rectification of fire hazards, improved the efficiency of hazard rectification and the level of management standardization, ensured that responsibilities are implemented, and the system has a fast response speed and high availability.
Smart Images

Figure CN123159689A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of information technology for fire safety management, and in particular to an intelligent fire management method and system based on QR codes. Background Technology
[0002] Fire safety management is a crucial component of ensuring public safety. Currently, fire safety management tasks in hospitals, schools, industrial parks, factories, and buildings, including daily inspections, hazard rectification, hot work permits, fire safety training and assessments, signing of fire safety responsibility agreements, and personnel attendance checks, primarily rely on manual records and paper documents. Specifically, upon arrival at the site, inspectors check off items on a paper checklist, fill out a paper hazard report upon discovering hazards, and escalate the report through multiple levels. Before hot work, personnel fill out a paper hot work permit form, which is then processed and approved by department heads and safety management departments. Fire safety responsibility agreements are distributed to departments in paper form, signed by the responsible personnel, and then collected and archived. Fire safety training is mainly conducted offline in-person, with training records and assessment results recorded in paper or electronic spreadsheets. While some locations have introduced information management systems, these are often limited to single-function software, only capable of registering and querying hazard information or managing a single task electronically. In terms of access control, existing systems generally use simple login authentication methods to achieve basic access restrictions; in terms of system architecture, existing information management methods are mainly based on PC-based management and lack effective collaboration with mobile terminals.
[0003] With the rapid development of the social economy and the acceleration of urbanization, fire hazards in various buildings are increasing, posing numerous challenges to fire safety management. The traditional management model relying on manual records and paper documents, along with the limited functionality of information systems, reveals the following prominent problems in practical application: First, management efficiency is low. Hazard information is not transmitted in a timely manner, hazard investigation lacks standardized inspection procedures and supervision mechanisms, and hazard management has not formed a complete closed-loop process of "reporting-acceptance-rectification-verification-feedback." The status of hazard rectification cannot be tracked in real time, and responsibility is not effectively implemented. Second, it is difficult to effectively confirm whether inspection personnel are actually on duty, the authenticity of inspection records is difficult to guarantee, and inspection work risks becoming a mere formality. Third, hot work permits still rely on paper documents, resulting in long approval cycles and a lack of electronic record-keeping; fire safety responsibility agreements are signed offline on paper, leading to low signing efficiency, easy document loss, difficulty in tracking signing status, and fire management data scattered across various paper ledgers, making effective statistical analysis difficult. Fourth, there is a lack of automatic reminder mechanisms for overdue hazards, relying on manual reminders, resulting in widespread delays in rectification. Fifth, existing systems generally lack collaboration between mobile and management terminals, preventing on-site inspectors from performing inspections, reporting, and rectification anytime, anywhere. Sixth, access control is coarse-grained, supporting only simple login authentication and lacking fine-grained access control at the interface, data, and menu levels, resulting in high data security risks. Seventh, in high-concurrency access scenarios, there is a lack of effective cache management and degradation protection mechanisms, leading to slow system response and insufficient availability. Eighth, fire safety training and education are inadequate, lacking a systematic knowledge learning and assessment mechanism, making it difficult to quantify and evaluate personnel's fire safety awareness and skills.
[0004] Therefore, there is an urgent need for an intelligent fire management method and system that can achieve refined, standardized, and intelligent fire management, covering a variety of integrated and collaborative business processes such as fire inspection, closed-loop handling of hidden dangers, approval of hot work operations, training and assessment, signing of responsibility agreements and attendance management. Summary of the Invention
[0005] The purpose of this invention is to provide a smart fire management method and system based on QR codes, which solves the problems in the existing technology that fire safety management relies on manual records and paper documents, lacks a closed-loop management of the entire process of hidden dangers and a multi-terminal collaboration mechanism, resulting in a long cycle from the discovery of hidden dangers to rectification, untraceable process, and difficulty in assigning responsibility.
[0006] To achieve the above objectives, the present invention provides a smart fire management method based on QR codes, comprising the following steps: On the management terminal, managers can establish a tree-shaped inspection area according to the hierarchy of building, floor, and department, set an area manager and the responsible department for each inspection area, and generate a unique area QR code that is bound to the area identifier for each inspection area. After arriving at the site, the inspection personnel scan the area QR code through the mini-program. The backend service layer verifies the inspection personnel's inspection permissions and the area information corresponding to the area QR code. After the verification is successful, the mini-program enters the inspection interface of the inspection area. The inspection personnel check each item one by one and fill in the hazard title and hazard description when they find a hazard, take and upload the hazard picture, set the rectification deadline, and submit the hazard report. After a potential hazard is reported and reviewed and confirmed by the management personnel, it is added to the hazard disclosure list for public display. The backend service layer sends a reminder SMS to the regional manager through a scheduled task component. The responsible department completes the rectification before the rectification deadline and uploads the rectification description and pictures. The management personnel verify the rectification results. Once the verification is passed, the hazard is closed in a closed loop, forming a complete closed loop of reporting, acceptance, rectification, verification, and feedback. For overdue potential problems that have not been rectified by the deadline, the backend service layer automatically sends reminder SMS messages to the regional manager through the scheduled task component to urge them to complete the rectification.
[0007] Upon arrival at the site, inspection personnel scan the area's QR code via a mini-program. The backend service layer verifies the inspection personnel's inspection permissions and the area information corresponding to the QR code. After successful verification, the mini-program accesses the inspection interface for the designated area, specifically including: The administrator creates a special inspection plan on the management terminal, setting the plan name, inspection cycle, inspection area and inspection personnel; During the effective period of the special inspection plan, when a user with special inspection authority scans the area QR code through the mini-program, the backend service layer determines that the current time is within the special inspection period and matches the user's special inspection authority, and the mini-program enters the special inspection page; Outside the effective period of the special inspection plan, when a user scans the area QR code through the mini-program, the mini-program will take them to the daily inspection page.
[0008] This also includes the entire process management steps for hot work operations: Workers can submit hot work applications through the aforementioned mini-program, filling in the work location, work time, work content, and safety measures. The management personnel approve the hot work application on the management terminal, and the approval result includes approval or rejection, and fill in the approval comments; On-site inspectors conduct on-site inspections of hot work operations and record the inspection results. After the operation is completed, an acceptance inspection is carried out. The status and attachments of each stage of application, approval, inspection, and acceptance are fully recorded and stored in the data storage layer.
[0009] This also includes the online signing process for the liability waiver: The administrator uploads the responsibility letter template document to the management terminal and maintains the document content, generates signing tasks and distributes them to departments or designated personnel. Users can preview the content of the responsibility letter template document on the mini-program and sign it by hand using the handwriting signature board. The backend service layer combines the signature and document, saves them, and updates the signing status. Department heads can view the signing statistics of their department on the management terminal.
[0010] This also includes learning and training procedures and online examination steps: The administrators manage the learning content by category on the management terminal and upload learning videos and graphic materials. The backend service layer records the user's learning behavior, learning progress, and learning duration. The question bank supports single-choice, multiple-choice, and true / false question types. The backend service layer provides an online examination function. After the examination, the score and correct answer are returned to the mini-program, and the questions that are answered incorrectly are automatically added to the wrong question set. The backend service layer generates statistical reports on the number of learners and learning duration, and displays them on the management terminal.
[0011] This also includes a check-in / check-out process: The administrator creates a sign-in sheet and generates a sign-in QR code on the management terminal. Personnel scan the sign-in QR code through the mini-program to complete the sign-in. The backend service layer records the sign-in personnel and the sign-in time.
[0012] The process includes, after a potential hazard is reported and reviewed and confirmed by the management personnel, it is added to the hazard disclosure list for public display. The backend service layer then sends a reminder SMS to the regional manager via a scheduled task component. Specifically, this includes: The backend service layer uses the scheduled task component to call the SMS service interface to send a reminder SMS to the mobile phone number of the person in charge of the region.
[0013] This also includes a four-level access control process: The backend service layer uses a four-level access control system to control user access: The first level is the URL level, where Spring Security filters control access to API interfaces based on the URL path; The second level is the method level, which uses the @PreAuthorize annotation to control access to service methods; The third level is the data level, which controls the visibility of departmental data according to user roles through data permission annotations. The fourth level is the menu level. The management terminal dynamically generates the front-end menu based on user permissions, and menus that users do not have permission to access will not be displayed. The system is configured with roles such as system administrator, security administrator, inspector, regular user, and guest user.
[0014] This also includes cache management and degradation protection steps: The backend service layer uses Redis distributed cache to cache user authentication information, hotspot statistics, system configuration, check-in data, and user learning progress; To address the different real-time requirements of data, write-through caching, invalidation caching, timed updates, and delayed double deletion strategies are employed for cache updates. When the backend service layer detects that the Redis distributed cache service is unavailable or the connection times out, it automatically degrades to the direct database query mode and records the degradation log. Once the Redis distributed cache service recovers, it automatically switches back to the cache mode.
[0015] A QR code-based intelligent fire management system includes a front-end layer, a back-end service layer, and a data storage layer; The front-end layer includes a management terminal and a mini-program terminal. The management terminal is used for management personnel to perform configuration management and statistical analysis, and the mini-program terminal is used for inspection personnel and ordinary employees to perform on-site operations. The front-end layer connects to the back-end service layer through a communication network, sends business requests to the back-end service layer, and receives the returned processing results. The backend service layer is connected to the data storage layer, and writes business data to the data storage layer, reads business data from the data storage layer, caches hot data in the data storage layer, and reads cached hot data from the data storage layer. The data storage layer is used to store business data, cache hot data, and store attachment files.
[0016] This invention discloses a QR code-based intelligent fire safety management method and system. It constructs a system architecture comprising a front-end layer (management terminal and mini-program terminal), a back-end service layer, and a data storage layer. On the management terminal, administrators establish a tree-shaped inspection area and generate a unique QR code for each area, binding it to an area identifier. Inspection personnel scan the QR code via the mini-program terminal, and after authorization verification by the back-end service layer, they enter the inspection interface to report hazards. After review and confirmation, reported hazards are added to a public list, and a text message notification is sent to the area manager. The responsible department is then given a deadline to rectify the hazards and upload supporting materials. Once the administrator verifies the report, a closed-loop process of reporting, acceptance, rectification, verification, and feedback is formed. Simultaneously, the back-end service layer automatically sends reminder text messages to the area manager for overdue hazards via scheduled tasks. This invention achieves closed-loop management and multi-terminal collaboration throughout the entire process of fire hazard discovery and rectification, solving the problems of long rectification cycles, lack of process traceability, and difficulty in assigning responsibility in existing technologies. It significantly improves the efficiency of fire hazard rectification and the level of management standardization. Attached Figure Description
[0017] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the accompanying drawings used in the description of the embodiments or the prior art will be briefly introduced below.
[0018] Figure 1 This is a flowchart of the steps of the intelligent fire management method based on QR codes of the present invention.
[0019] Figure 2 This is a schematic diagram of the QR code-based intelligent fire management system of the present invention.
[0020] Figure 3 This is a flowchart of the hazard reporting and closed-loop handling process of the present invention.
[0021] Figure 4 This is a flowchart of the liability agreement signing process for this invention.
[0022] Figure 5 This is a flowchart of the hot work inspection process of the present invention.
[0023] In the diagram: 201 - Front-end layer, 202 - Back-end service layer, 203 - Data storage layer. Detailed Implementation
[0024] The embodiments of the present invention are described in detail below. Examples of the embodiments are shown in the accompanying drawings. The embodiments described below with reference to the accompanying drawings are exemplary and intended to explain the present invention, but should not be construed as limiting the present invention.
[0025] First embodiment: Please refer to Figure 1 , Figure 3 , Figure 4 and Figure 5 This invention provides a smart fire management method based on QR codes, comprising the following steps: S101: On the management terminal, managers can establish a tree-shaped inspection area according to the hierarchy of building, floor, and department, set an area manager and the department to be responsible for each inspection area, and generate a unique area QR code that is bound to the area identifier for each inspection area. Specifically, administrators log into the management terminal and sequentially create building nodes, floor nodes, and department nodes in the inspection area management module, forming a tree-like hierarchical structure. For each level node, the administrator configures the area manager and the corresponding department. After configuration, the management terminal calls the QR code generation interface of the backend service layer 202 to transmit the area identifier to the backend service layer 202. The backend service layer 202 generates a unique code based on the area identifier, converts the unique code into a QR code image, and returns it to the management terminal. The administrator then exports and prints the area QR code and affixes it to the corresponding on-site location.
[0026] S102: After the inspection personnel arrive at the site, they scan the area QR code through the mini-program. The backend service layer 202 verifies the inspection personnel's inspection authority and the area information corresponding to the area QR code. After the verification is successful, the mini-program enters the inspection interface of the inspection area. The inspection personnel check each item one by one and fill in the hazard title and hazard description when they find a hazard, take and upload the hazard picture, set the rectification deadline, and submit the hazard report. Specifically, after arriving at the site, the inspection personnel open the mini-program and use its scanning function to scan the area QR code posted at the site location. The mini-program parses the area identifier from the area QR code, encapsulates the area identifier and the inspection personnel's user identifier into an authorization verification request, and sends it to the backend service layer 202 via the communication network. Upon receiving the authorization verification request, the backend service layer 202 queries the scope of inspection permissions granted to the inspection personnel based on the user identifier, and queries the area information corresponding to the area QR code based on the area identifier to determine whether the inspection personnel have the authority to perform inspections in the area. If the verification fails, the backend service layer 202 returns a "no permission" message to the mini-program; if the verification succeeds, the mini-program redirects to the inspection interface of the inspection area. The inspection personnel conduct inspections item by item according to the inspection interface. When a fire hazard is found, they fill in the hazard title and hazard description in the inspection interface, call the camera function of the mini-program to take and upload the hazard image, set the rectification deadline, and click the submit button. The mini-program sends the hazard reporting request to the backend service layer 202, and the backend service layer 202 saves the hazard information to the data storage layer 203.
[0027] S103: After the hidden danger is reported and reviewed and confirmed by the management personnel, it is entered into the hidden danger publicity list for publicity. The backend service layer 202 sends a reminder SMS to the regional person in charge through the scheduled task scheduling component. The department in charge completes the rectification before the rectification deadline and uploads the rectification description and rectification pictures. The management personnel verify the rectification results. After the verification is passed, the hidden danger is closed in a closed loop, forming a closed loop of the whole process of reporting, acceptance, rectification, verification and feedback. Specifically, after a hazard is successfully reported, the hazard information is displayed in the hazard review list on the management terminal. The administrator logs into the management terminal to view the hazard awaiting review, verifies the hazard information, and clicks the "Approval" button after confirming the hazard is genuine. The backend service layer 202 updates the hazard status to "Reviewed" and adds it to the hazard public list. The backend service layer 202 then uses the scheduled task component to call the SMS service interface to send a reminder SMS to the mobile phone number of the regional manager, notifying the regional manager that a hazard has been reported in their area.
[0028] S104: For overdue potential problems that have not been rectified by the deadline, the backend service layer 202 automatically sends a reminder SMS to the regional manager through the scheduled task component to urge them to complete the rectification.
[0029] Specifically, after receiving the reminder SMS, the regional manager organizes the relevant department to rectify the hazard. After rectification, personnel from the relevant department access the hazard rectification interface via the mini-program or the management terminal, fill in the rectification description, take and upload rectification photos, and submit the rectification results. The backend service layer 202 receives the rectification results and updates the hazard status to "Pending Verification." The administrator logs into the management terminal to view the hazard awaiting verification, verifies the rectification description and photos, and determines whether the rectification meets the requirements. If verification passes, the administrator clicks the "Verification Passed" button, and the backend service layer 202 updates the hazard status to "Closed," completing the closed-loop management of the entire process from reporting, acceptance, rectification, verification, and feedback. If verification fails, the administrator fills in a return request, and the backend service layer 202 returns the hazard to the relevant department for re-rectification.
[0030] The scheduled task component configured in the backend service layer 202 executes periodically according to a preset scanning cycle. Each execution queries the data storage layer 203 for all hazard records whose status is "Under Rectification" and whose current date exceeds the rectification deadline. For each overdue hazard record found, the scheduled task component calls the SMS service interface to send a reminder SMS to the mobile phone number of the corresponding regional manager, reminding the regional manager that rectification has been overdue.
[0031] Furthermore, step S102 also includes a special inspection dynamic routing step: the administrator creates a special inspection plan on the management terminal, setting the plan name, inspection cycle, inspection area, and inspection personnel; during the effective period of the special inspection plan, when a user with special inspection permissions scans the area QR code through the mini-program terminal, the backend service layer 202 determines that the current time is within the special inspection period and matches the user's special inspection permissions, and the mini-program terminal enters the special inspection page; outside the effective period of the special inspection plan, when a user scans the area QR code through the mini-program terminal, the mini-program terminal enters the daily inspection page. The implementation of dynamic routing for special inspections is as follows: The backend service layer 202 stores the special inspection plan in the data storage layer 203. When the mini-program scans the area QR code and submits a permission verification request, the backend service layer 202 queries whether the current time is within the effective time period of any special inspection plan. If so, it further determines whether the inspector is configured as an inspector for that special inspection plan. If so, it returns a special inspection mode identifier to the mini-program, and the mini-program renders the special inspection page based on the special inspection mode identifier. If not, it returns a daily inspection mode identifier, and the mini-program renders the daily inspection page. Through this method, the same area QR code can be mapped to different inspection modes at different time periods.
[0032] Furthermore, the method also includes a full-process management step for hot work operations: Operators submit hot work applications through the mini-program, filling in the work location, time, content, and safety measures; managers approve the applications on the management terminal, with approval or rejection results, and provide approval comments; on-site inspectors conduct on-site inspections and record the results; acceptance is performed after the work is completed; the status and attachments of each stage of application, approval, inspection, and acceptance are fully traced and stored in the data storage layer 203. Specifically, operators fill in the hot work application information and upload relevant attachments through the mini-program. The backend service layer 202 receives the information, generates a hot work application record, and saves it to the data storage layer 203, marking the status as pending approval. Managers view the pending applications on the management terminal, approve or reject them, and provide approval comments; the backend service layer 202 updates the application status. After approval, on-site inspectors enter the on-site inspection results through the mini-program or the management terminal. After the task is completed, the administrator performs acceptance testing and records the results through the management terminal. The backend service layer 202 saves the acceptance results to the data storage layer 203. Operation records, status changes, and attachments for each stage of application, approval, inspection, and acceptance are all stored in the data storage layer 203, achieving full traceability.
[0033] Furthermore, the method also includes an online signing step for the responsibility agreement: the administrator uploads the responsibility agreement template document and maintains the document content on the management terminal, generates a signing task, and distributes it to the department or designated personnel; the user previews the responsibility agreement template document content on the mini-program terminal and signs it by hand using the handwriting signature pad; the backend service layer 202 combines the signature with the document, saves it, and updates the signing status; the department head views the signing statistics of their department on the management terminal. Specifically, the administrator uploads the responsibility agreement template document to the data storage layer 203 on the management terminal and edits the content information of the responsibility agreement through the management terminal. The administrator creates a signing task, selects the responsibility agreement template document, and specifies the department or designated personnel to whom the signing task is distributed. After receiving the signing task, the backend service layer 202 saves it to the data storage layer 203 and sends a signing notification to the designated user. The designated user logs into the mini-program to view the tasks to be signed. After clicking the "Sign" button, they enter the signing page, preview the content of the responsibility agreement template document, and perform a handwritten signature operation in the handwriting signature area provided by the mini-program. The mini-program collects the handwritten signature trajectory data and sends it to the backend service layer 202. Upon receiving the data, the backend service layer 202 combines the handwritten signature with the responsibility agreement template document into a complete signed document, saves it to the data storage layer 203, and updates the user's signing status to "signed." The department head logs into the management terminal to view the signing statistics for their department. The backend service layer 202 calculates the number of signed and unsigned personnel based on the department, generating statistical data that is presented on the management terminal.
[0034] Furthermore, the method also includes learning and training steps and online examinations: the administrator manages learning content by category on the management terminal, supporting the uploading of learning videos and text / image materials; the backend service layer 202 records users' learning behavior, learning progress, and learning duration; the question bank supports single-choice, multiple-choice, and true / false question types; the backend service layer 202 provides an online examination function, returning scores and correct answers to the mini-program terminal after the examination, and automatically adding incorrectly answered questions to a wrong-answer set for review; the backend service layer 202 generates statistical reports on the number of learners and learning duration, and displays them on the management terminal. Specifically, the administrator creates learning content categories on the management terminal, uploads learning video files and text / image material files under each category, and uploads the files to the OSS object storage of the data storage layer 203. Users log in to the mini-program terminal, select learning content, and the mini-program terminal periodically reports learning progress and learning duration to the backend service layer 202 during the learning process, which the backend service layer 202 receives and saves to the data storage layer 203. The administrator enters test questions into the question bank management page on the management terminal. Each question is specified as either single-choice, multiple-choice, or true / false, and a correct answer is set. Users access the online exam page through the mini-program. The mini-program retrieves the test questions from the backend service layer 202 and displays them one by one. After answering, the user submits their answer sheet. The backend service layer 202 receives the answer sheet, automatically grades it, calculates the score, compares the correct answer for each question with the user's answer, and returns the score and correct answer to the mini-program for display. Incorrectly answered questions are automatically added to the user's incorrect question set. The backend service layer 202 performs statistical analysis based on the learning records stored in the data storage layer 203, categorizing them by the number of learners and learning duration, generating statistical reports, and displaying them in chart form on the management terminal.
[0035] Furthermore, the method also includes check-in and certificate management steps: the administrator creates a check-in table and generates a check-in QR code on the management terminal; personnel scan the check-in QR code through the mini-program to complete the check-in; the backend service layer 202 records the check-in personnel and check-in time; the backend service layer 202 also manages the certificates of fire-related personnel, supporting certificate upload, verification, and expiration reminders. Specifically, the administrator creates a check-in table in the check-in management module of the management terminal, setting the check-in name, check-in location, and valid check-in time range; the management terminal calls the backend service layer 202 to generate a check-in QR code. Within the valid time range, personnel scan the check-in QR code through the mini-program; the mini-program sends the check-in request to the backend service layer 202; the backend service layer 202 records the check-in personnel and check-in time to the data storage layer 203. Regarding certificate management, users upload certificate files for fire safety personnel via the mini-program or administrators via the management terminal. The backend service layer 202 receives these files, saves them to the data storage layer 203, and records the certificate's validity period. The backend service layer 202 periodically scans the certificate validity period using the scheduled task component and sends an expiration reminder to the certificate holder before the certificate expires.
[0036] Furthermore, the method also includes a four-level access control step: the backend service layer 202 uses a four-level access control system to control user access. The first level is the URL level, where Spring Security filters control access to API interfaces based on URL paths. When the frontend layer 201 sends an API request to the backend service layer 202, the Spring Security filter intercepts the request, extracts the URL path, and matches it against the currently logged-in user's access control list. If the URL path is not within the user's access control scope, access is denied. The second level is the method level, where the @PreAuthorize annotation controls access to service methods. The @PreAuthorize annotation is added to the business methods of the backend service layer 202, specifying the required access control expression. When the business method is called, Spring Security parses the access control expression in the annotation and compares it with the current user's access control. If the comparison fails, execution is denied. The third level is the data layer. Data permission annotations control the visibility of departmental data according to user roles. Data permission annotations are added to the data query methods of the backend service layer 202. When executing data queries, the backend service layer 202 dynamically constructs departmental data filtering conditions in the SQL query statement based on the data permission annotations and the current user role, restricting users to only querying data from their own department and its subordinate departments. The fourth level is the menu layer. The management terminal dynamically generates a front-end menu based on user permissions. Menus without permissions are not displayed. After a user logs into the management terminal, the front-end layer 201 obtains the current user's permission information from the backend service layer 202 and dynamically renders the left navigation menu based on this information, displaying only menu items that the user has permission to access. The system sets up roles such as system administrator, security administrator, inspector, ordinary user, and guest user, with different permission sets configured for different roles.
[0037] Furthermore, the method also includes cache management and degradation protection steps: the backend service layer 202 uses Redis distributed caching to cache user authentication information, hot data statistics, system configuration, attendance data, and user learning progress; for different data real-time requirements, write-through caching, invalidation caching, scheduled updates, and delayed double-deletion strategies are used for cache updates. Specifically, for data with high real-time requirements such as user authentication information, a write-through caching strategy is used, that is, updating the cache while updating the database; for data with moderate real-time requirements such as system configuration, an invalidation caching strategy is used, that is, updating the database and deleting the cache, and rebuilding it on the next query; for hot data statistics, a scheduled update strategy is used, that is, calculating statistical data and updating the cache periodically through scheduled tasks; for data updates in high-concurrency scenarios, a delayed double-deletion strategy is used, that is, deleting the cache first, updating the database, and deleting the cache again after a preset time. When the backend service layer 202 detects that the Redis distributed cache service is unavailable or the connection times out, it automatically degrades to the direct database query mode and records the degradation log. After the Redis distributed cache service recovers, it automatically switches back to cache mode to ensure the continuous availability of the system in the event of cache failure.
[0038] Furthermore, the method also includes file security management steps: when attachments such as images, videos, and documents are uploaded by each business module, the backend service layer 202 generates a UUID as a unique filename, organizes the object storage path according to the business type and date, calls the OSS object storage service to complete the upload, and saves the file path to the database; file access is performed through a temporary URL with a signature; the file type and size are verified during upload to prevent malicious file uploads; network transmission uses HTTPS encryption, sensitive data such as passwords are stored using AES-256 encryption, and sensitive information such as mobile phone numbers and ID card numbers are de-identified when displayed.
[0039] Furthermore, the method also includes data dashboard and statistical analysis steps: the backend service layer 202 performs multi-dimensional statistics on business data such as hot work inspection, patrol and inspection, learning and training, and attendance, and displays the statistical results in the form of charts through the data dashboard to provide data support for fire safety management decisions.
[0040] In a specific application scenario of this embodiment, taking a hospital deployment as an example: In the management module of the management terminal, administrators establish a tree-shaped inspection area according to the hierarchy of "Outpatient Building - First Floor - Emergency Department," assigning a regional head and responsible department to each area, generating and exporting QR codes for each area, and printing and posting them on-site in the corresponding departments. Inspection personnel use a mini-program to scan the QR code for the Emergency Department area. After the system verifies their inspection permissions, they enter the inspection interface for that area. The inspection personnel check the fire-fighting facilities item by item. Upon discovering a potential hazard such as insufficient fire extinguisher pressure, they fill in the hazard title and description, take photos of the scene, upload them, set a rectification deadline, and submit. After the management personnel review and confirm the reported hazard on the management terminal, the hazard is added to the public notice list, and the system simultaneously sends a reminder SMS to the Emergency Department area head. The responsible department in the Emergency Department completes the rectification before the deadline and uploads rectification photos. The management personnel verify the rectification results; after verification, the hazard is closed, completing the closed-loop handling. For hazards that have not been rectified by the rectification deadline, a scheduled task automatically sends a reminder SMS to the area head.
[0041] In another specific application scenario of this embodiment, the administrator creates a "Pre-Holiday Fire Safety Special Inspection" plan on the management terminal, setting the inspection period to April 25th to April 30th, the inspection area to key departments throughout the hospital, and assigning special inspection personnel. During the plan's effective period, when special inspection personnel scan the area's QR code, the system determines that the current time is within the special inspection period and enters the special inspection page to perform the special inspection task. After the plan ends, the same QR code reverts to mapping to the daily inspection page, and ordinary inspection personnel will still enter the daily inspection interface when scanning the code, realizing dynamic routing of QR codes.
[0042] In another specific application scenario of this embodiment, before construction workers perform hot work operations in the inpatient department, they submit a hot work application through a mini-program, filling in the work location, work time, work content, and fire safety measures; the safety administrator approves it on the management terminal; on-site inspectors inspect and record the work; after the work is completed, acceptance is completed, and the entire process is recorded. Simultaneously, the hospital issues an annual fire safety responsibility agreement. The administrator uploads the agreement template and generates a signing task, which is then distributed to each department; department heads and employees preview the agreement content on the mini-program and submit their handwritten signatures. The system saves the signatures and updates the signing status, and the security department views the signing completion status of each department on the management terminal. The administrator uploads learning videos and text materials on the management terminal, categorized by "fire prevention knowledge, fire extinguisher use, and evacuation escape"; employees learn and take online exams on the mini-program, and the system displays scores and generates a collection of incorrect answers after the exam; the administrator views statistical reports such as the number of participants and learning time for each department. When the hospital organizes fire drills, the administrator creates a sign-in sheet and generates a sign-in QR code. Participants scan the code to sign in, and the system records the sign-in status.
[0043] In the above steps, the management terminal is built based on the Vue.js framework and the Element UI component library, and runs on a PC browser; the mini-program terminal is built based on the uni-app cross-platform framework and runs on a mobile terminal; the backend service layer 202 is built based on the Spring Boot framework, integrating the Spring Security framework, JWT token authentication mechanism, MyBatis-Plus data access component, Redis distributed cache, OSS object storage service, and scheduled task component; the data storage layer 203 includes a MySQL relational database for storing business data, a Redis distributed cache for caching hot data, and an OSS object storage for storing attachments such as images, videos, and documents.
[0044] In this embodiment, the system has been deployed in a hospital and passed functional acceptance. All 56 functional points of the system management terminal and 34 functional points of the mini-program terminal have passed acceptance. The system response time is no more than 2 seconds, supports 1,000 people online at the same time, and the system availability reaches 99.9%.
[0045] Second embodiment: Please refer to Figure 2 This invention provides a QR code-based intelligent fire management system, including a front-end layer 201, a back-end service layer 202, and a data storage layer 203. The front-end layer 201 includes a management terminal and a mini-program terminal. The management terminal is built on the Vue.js framework and the ElementUI component library, runs on a PC browser, and is used by administrators for configuration management and statistical analysis. The mini-program terminal is built on the uni-app cross-platform framework, runs on mobile terminals, and is used by inspection personnel and ordinary employees for on-site operations. The front-end layer 201 connects to the back-end service layer 202 via a communication network, sends business requests to the back-end service layer 202, and receives the returned processing results.
[0046] The backend service layer 202 is built on the Spring Boot framework and integrates the Spring Security framework, JWT token authentication mechanism, MyBatis-Plus data access component, Redis distributed cache, OSS object storage service, and scheduled task component. The backend service layer 202 is connected to the data storage layer 203, writing business data to and reading business data from the data storage layer 203, caching hot data in the data storage layer 203, and reading cached hot data from the data storage layer 203.
[0047] The data storage layer 203 includes a MySQL relational database for storing business data, a Redis distributed cache for caching frequently accessed data, and an OSS object storage for storing attachments such as images, videos, and documents. The data storage layer 203 is used to store business data, cache frequently accessed data, and store attachments.
[0048] When the system is in operation: Administrators establish a tree-structured inspection area hierarchy based on building, floor, and department, assigning a region head and responsible department to each area, and generating a unique QR code for each area. Upon arrival, inspectors scan the QR code via a mini-program. The backend service layer 202 verifies the inspector's permissions and the area information corresponding to the QR code. After successful verification, the mini-program accesses the inspection interface for that area. Inspectors check each item and submit a hazard report when one is discovered. After review and confirmation by administrators, the hazard is displayed in a hazard disclosure list. The backend service layer 202 sends a reminder SMS to the region head via a scheduled task. The responsible department completes rectification and uploads supporting materials before the deadline. Administrators verify the rectification results; once verified, the hazard is closed. The backend service layer 202 automatically sends reminder SMS messages to the region head for overdue hazards. The specific workflow of the system has been described in detail in the first embodiment and will not be repeated here.
[0049] This invention generates a unique QR code for each inspection area, assigning a designated area manager and responsible department. Inspection personnel must scan the code and undergo a 202-level permission check at the backend service layer before accessing the inspection interface to report hazards. This binding of the inspection area QR code to personnel permissions ensures that inspection personnel must be physically present to scan the code before performing inspection tasks, effectively guaranteeing the authenticity of inspection records and preventing inspections from becoming mere formalities. Furthermore, after hazard reports are reviewed and confirmed, they are added to a public list, and a reminder SMS is sent to the area manager. The responsible department is then given a time limit to rectify the hazard and upload supporting materials. Once management personnel verify the rectification, the case is closed in a closed loop. Combined with scheduled tasks, overdue hazards are automatically reminded via SMS. This forms a complete closed-loop management system of "reporting-acceptance-rectification-verification-feedback," making the entire process from hazard discovery to rectification traceable and effectively shortening the hazard rectification cycle, ensuring that responsibilities are fulfilled. Building upon this foundation, this invention employs a dynamic routing method for specialized inspections, automatically mapping QR codes in the same area to different inspection modes at different times. This allows for flexible specialized inspections without requiring QR code replacement, significantly improving the flexibility of inspection deployment. A four-level access control system enables fine-grained access control at the interface, method, data, and menu levels, effectively reducing data security risks. Furthermore, a Redis distributed caching and automatic degradation mechanism ensures system response speed under high-concurrency access scenarios and guarantees continuous system availability in the event of cache service failure. The system has been deployed and functionally accepted in a hospital, with a response time of no more than 2 seconds, supporting 1000 simultaneous online users and achieving 99.9% availability. This fully verifies that this invention can solve the technical problems of long rectification cycles, untraceable processes, and difficulty in assigning responsibility in existing technologies, significantly improving the efficiency of fire hazard rectification and the level of management standardization.
[0050] The above-disclosed embodiments are merely one or more preferred embodiments of this application and should not be construed as limiting the scope of this application. Those skilled in the art can understand that all or part of the processes for implementing the above embodiments and equivalent changes made in accordance with the claims of this application still fall within the scope of this application.
Claims
1. A smart fire management method based on QR codes, characterized in that, Includes the following steps: On the management terminal, managers can establish a tree-shaped inspection area according to the hierarchy of building, floor, and department, set an area manager and the responsible department for each inspection area, and generate a unique area QR code that is bound to the area identifier for each inspection area. After arriving at the site, the inspection personnel scan the area QR code through the mini-program. The backend service layer verifies the inspection personnel's inspection permissions and the area information corresponding to the area QR code. After the verification is successful, the mini-program enters the inspection interface of the inspection area. The inspection personnel check each item one by one and fill in the hazard title and hazard description when they find a hazard, take and upload the hazard picture, set the rectification deadline, and submit the hazard report. After a potential hazard is reported and reviewed and confirmed by the management personnel, it is added to the hazard disclosure list for public display. The backend service layer sends a reminder SMS to the regional manager through a scheduled task component. The responsible department completes the rectification before the rectification deadline and uploads the rectification description and pictures. The management personnel verify the rectification results. Once the verification is passed, the hazard is closed in a closed loop, forming a complete closed loop of reporting, acceptance, rectification, verification, and feedback. For overdue potential problems that have not been rectified by the deadline, the backend service layer automatically sends reminder SMS messages to the regional manager through the scheduled task component to urge them to complete the rectification.
2. The intelligent fire management method based on QR codes as described in claim 1, characterized in that, After arriving at the site, inspection personnel scan the area's QR code via a mini-program. The backend service layer verifies the inspection personnel's inspection permissions and the area information corresponding to the QR code. Once verification is successful, the mini-program accesses the inspection interface for the designated area, which includes: The administrator creates a special inspection plan on the management terminal, setting the plan name, inspection cycle, inspection area and inspection personnel; During the effective period of the special inspection plan, when a user with special inspection authority scans the area QR code through the mini-program, the backend service layer determines that the current time is within the special inspection period and matches the user's special inspection authority, and the mini-program enters the special inspection page; Outside the effective period of the special inspection plan, when a user scans the area QR code through the mini-program, the mini-program will take them to the daily inspection page.
3. The intelligent fire management method based on QR codes as described in claim 1, characterized in that, It also includes the entire process management steps for hot work operations: Workers can submit hot work applications through the aforementioned mini-program, filling in the work location, work time, work content, and safety measures. The management personnel approve the hot work application on the management terminal, and the approval result includes approval or rejection, and fill in the approval comments; On-site inspectors conduct on-site inspections of hot work operations and record the inspection results. After the operation is completed, an acceptance inspection is carried out. The status and attachments of each stage of application, approval, inspection, and acceptance are fully recorded and stored in the data storage layer.
4. The intelligent fire management method based on QR codes as described in claim 1, characterized in that, It also includes the online signing process for the liability waiver: The administrator uploads the responsibility letter template document to the management terminal and maintains the document content, generates signing tasks and distributes them to departments or designated personnel. Users can preview the content of the responsibility letter template document on the mini-program and sign it by hand using the handwriting signature board. The backend service layer combines the signature and document, saves them, and updates the signing status. Department heads can view the signing statistics of their department on the management terminal.
5. The intelligent fire management method based on QR codes as described in claim 1, characterized in that, It also includes learning and training steps and online exam procedures: The administrators manage the learning content by category on the management terminal and upload learning videos and graphic materials. The backend service layer records the user's learning behavior, learning progress, and learning duration. The question bank supports single-choice, multiple-choice, and true / false question types. The backend service layer provides an online examination function. After the examination, the score and correct answer are returned to the mini-program, and the questions that are answered incorrectly are automatically added to the wrong question set. The backend service layer generates statistical reports on the number of learners and learning duration, and displays them on the management terminal.
6. The intelligent fire management method based on QR codes as described in claim 1, characterized in that, It also includes the check-in / check-out process: The administrator creates a sign-in sheet and generates a sign-in QR code on the management terminal. Personnel scan the sign-in QR code through the mini-program to complete the sign-in. The backend service layer records the sign-in personnel and the sign-in time.
7. The intelligent fire management method based on QR codes as described in claim 1, characterized in that, After a potential hazard is reported and reviewed and confirmed by the management personnel, it is added to the hazard disclosure list for public display. The backend service layer then sends a reminder SMS to the regional manager via a scheduled task component, specifically including: The backend service layer uses the scheduled task component to call the SMS service interface to send a reminder SMS to the mobile phone number of the person in charge of the region.
8. The intelligent fire management method based on QR codes as described in claim 1, characterized in that, It also includes four levels of access control steps: The backend service layer uses a four-level access control system to control user access: The first level is the URL level, where Spring Security filters control access to API interfaces based on the URL path; The second level is the method level, which uses the @PreAuthorize annotation to control access to service methods; The third level is the data level, which controls the visibility of departmental data according to user roles through data permission annotations. The fourth level is the menu level. The management terminal dynamically generates the front-end menu based on user permissions, and menus that users do not have permission to access will not be displayed. The system is configured with roles such as system administrator, security administrator, inspector, regular user, and guest user.
9. The intelligent fire management method based on QR codes as described in claim 1, characterized in that, It also includes cache management and degradation protection steps: The backend service layer uses Redis distributed cache to cache user authentication information, hotspot statistics, system configuration, check-in data, and user learning progress; To address the different real-time requirements of data, write-through caching, invalidation caching, timed updates, and delayed double deletion strategies are employed for cache updates. When the backend service layer detects that the Redis distributed cache service is unavailable or the connection times out, it automatically degrades to the direct database query mode and records the degradation log. Once the Redis distributed cache service recovers, it automatically switches back to the cache mode.
10. A QR code-based intelligent fire management system, used to implement the QR code-based intelligent fire management method as described in claim 1, characterized in that, It includes a front-end layer, a back-end service layer, and a data storage layer; The front-end layer includes a management terminal and a mini-program terminal. The management terminal is used for management personnel to perform configuration management and statistical analysis, and the mini-program terminal is used for inspection personnel and ordinary employees to perform on-site operations. The front-end layer connects to the back-end service layer through a communication network, sends business requests to the back-end service layer, and receives the returned processing results. The backend service layer is connected to the data storage layer, and writes business data to the data storage layer, reads business data from the data storage layer, caches hot data in the data storage layer, and reads cached hot data from the data storage layer. The data storage layer is used to store business data, cache hot data, and store attachment files.
