Service process generation method and device, terminal equipment and storage medium
By obtaining the rule data published by the business system to generate a rule processor and configuring it into a process model to form a service process, it solves the problem of inflexible process generation in the existing technology, and realizes the function of user-defined generation of service processes, satisfying the The personalized needs of the company.
Patent Information
- Application Number
- CN202411577026.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-06
- Publication Date
- 2025-02-25
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The existing technology is not flexible enough in the process generation of internal systems of the enterprise. It requires developers to edit the underlying code to meet new process needs, and provides limited support in the customization of process rules, event listeners and user interfaces, which limits the The personalized needs of the company.
By obtaining the rule data released by the business system, generating the rule processor, and configuring it into the process model to form a service process. This method allows users to customize generation rules and service processes through methods other than code to meet personalized needs.
It realizes that users can customize the generation service process without coding, improves the flexibility and efficiency of process development, and meets the personalized needs of enterprises.
Smart Images

Figure CN119512505A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of software development technology, and in particular to a service process generation method, apparatus, terminal device and storage medium. Background Art
[0002] The internal systems of a company or enterprise involve many OA approval processes, business processes or other process matters, which often require developers to edit the code according to the needs. However, when the company expands or the department expands, new process requirements will arise, and even the old processes will be affected. Therefore, the existing process generation method is very inconvenient and requires developers to re-edit the underlying code to meet the corresponding requirements. At the same time, in terms of process rules, event listeners and user interface customization, existing software often provides limited support, which restricts the personalized needs of enterprises. Summary of the invention
[0003] In view of this, the embodiments of the present application provide a service process generation method, apparatus, terminal device and storage medium, which can effectively solve the problem of inconvenient process development.
[0004] In a first aspect, an embodiment of the present application provides a service process generation method, including:
[0005] Obtaining rule data published by the business system and verifying the rule data;
[0006] Acquire configuration information in the rule data, and generate a rule processor corresponding to the rule data according to the configuration information;
[0007] A process model is constructed, and the rule processor is configured into the process model to form a service process.
[0008] In one embodiment, the configuration information includes a rule name, a rule scope, a rule policy, candidate interface information, and authentication information;
[0009] The obtaining of configuration information in the rule data and generating a rule processor corresponding to the rule data according to the configuration information includes:
[0010] According to the rule scope and the rule strategy, the corresponding basic rules are matched respectively;
[0011] The candidate interface information and the authentication information are used as configuration parameters to configure the matched basic rules, and after integration, a rule processor marked with the rule name is obtained.
[0012] In one embodiment, matching corresponding basic rules according to the rule scope and the rule policy respectively includes:
[0013] Get the rule description of each basic rule;
[0014] A rule description matching the rule scope and the rule policy is searched to obtain a basic rule corresponding to the rule description.
[0015] In one embodiment, the verifying the rule data includes:
[0016] Determine whether all necessary configuration information in the rule data exists. If the configuration information is missing, the rule data verification fails and an error prompt is given.
[0017] In one embodiment, the forming of the service process further includes:
[0018] Obtaining an input task monitoring configuration, wherein the task monitoring configuration includes a task monitoring name and a task number;
[0019] According to the task number, the task to be monitored is determined, and a task monitor marked with the task monitoring name is generated.
[0020] In one embodiment, the step of constructing a process model and configuring the rule processor into the process model to form a service process includes:
[0021] Configure each task node in the process model and the order of each task node to obtain the process model;
[0022] Define the rule configuration for each process task node;
[0023] According to the rule configuration, obtain the corresponding rule processor;
[0024] The rule processor is configured into each process task node to obtain a service process formed by each process task node.
[0025] In one embodiment, the obtaining of rule data published by the business system includes:
[0026] The rule data published by the business system is obtained through HTTP, or the rule data encapsulated into an MQ message is obtained by subscribing to an MQ queue.
[0027] In a second aspect, the present application further provides a service process integration device, comprising:
[0028] A data processing module is used to obtain the rule data published by the business system and verify the rule data;
[0029] A rule generation module, used to obtain configuration information in the rule data, and generate a rule processor corresponding to the rule data according to the configuration information;
[0030] The process construction module is used to construct a process model and configure the rule processor into the process model to form a service process.
[0031] In a third aspect, the present application further provides a terminal device, the terminal device comprising a processor and a memory, the memory storing a computer program, and the processor being used to execute the computer program to implement the service process generation method.
[0032] In a fourth aspect, the present application also provides a computer-readable storage medium storing a computer program, which, when executed on a processor, implements the service process generation method.
[0033] The embodiments of the present application have the following beneficial effects:
[0034] This application parses the rule data input by the user, generates a rule processor, and then configures the rule processor into the process model to form a service process, so that both the rules and the service process can be customized by the user through methods other than code, so that the user can flexibly customize the service process he needs. BRIEF DESCRIPTION OF THE DRAWINGS
[0035] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the embodiments will be briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present application and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without paying creative work.
[0036] Figure 1 A schematic diagram of the structure of a service system according to an embodiment of the present application is shown;
[0037] Figure 2 A schematic diagram of a service process generation method according to an embodiment of the present application is shown;
[0038] Figure 3 A schematic diagram of a task model according to an embodiment of the present application is shown;
[0039] Figure 4 A schematic diagram of the structure of a service process generating device according to an embodiment of the present application is shown. DETAILED DESCRIPTION
[0040] The technical solutions in the embodiments of the present application will be described clearly and completely below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, rather than all of the embodiments.
[0041] The components of the embodiments of the present application generally described and shown in the drawings herein may be arranged and designed in various configurations. Therefore, the following detailed description of the embodiments of the present application provided in the drawings is not intended to limit the scope of the application claimed for protection, but merely represents the selected embodiments of the present application. Based on the embodiments of the present application, all other embodiments obtained by those skilled in the art without making creative work belong to the scope of protection of the present application.
[0042] Hereinafter, the terms "including", "having" and their cognates that can be used in various embodiments of the present application are intended only to indicate specific features, numbers, steps, operations, elements, components or a combination of the foregoing items, and should not be understood as first excluding the existence of one or more other features, numbers, steps, operations, elements, components or a combination of the foregoing items or increasing the possibility of one or more features, numbers, steps, operations, elements, components or a combination of the foregoing items. In addition, the terms "first", "second", "third" and the like are only used to distinguish descriptions and cannot be understood as indicating or implying relative importance.
[0043] Unless otherwise defined, all terms (including technical terms and scientific terms) used herein have the same meanings as those generally understood by those skilled in the art to which the various embodiments of the present application belong. The terms (such as those defined in generally used dictionaries) will be interpreted as having the same meanings as the contextual meanings in the relevant technical field and will not be interpreted as having idealized meanings or overly formal meanings unless clearly defined in the various embodiments of the present application.
[0044] In conjunction with the accompanying drawings, some embodiments of the present application are described in detail below. In the absence of conflict, the following embodiments and features in the embodiments can be combined with each other.
[0045] As corporate businesses become increasingly complex and diversified, traditional workflow management methods can no longer meet the needs of efficiency, flexibility, and security. Although existing workflow software has achieved process automation to a certain extent, it still has many deficiencies in deployment methods, system scalability, and user customization capabilities. For example, some software relies on specific business environments and is difficult to deploy independently; when dealing with high-concurrency or large-scale businesses, there is a lack of effective cluster deployment solutions; at the same time, in terms of process rules, event listeners, and user interface customization, existing software often provides limited support, which restricts the personalized needs of enterprises and makes it difficult for enterprise users to quickly, stably, and efficiently customize the required service processes.
[0046] The service process generation method of the present application obtains rule data, generates a rule processor that can execute rule logic according to the rules, and then configures the rule processor into the process model after building the process, thereby obtaining a service process.
[0047] The service process generation method is described below in conjunction with some specific embodiments.
[0048] like Figure 1 FIG. 1 is a schematic diagram of the service system structure of this embodiment. The service flow generation method of this embodiment runs on the service system.
[0049] The service system includes a business system 100 , core dependencies 200 and process services 300 .
[0050] The business system 100 is a system that provides business functions to users. The core dependency 200 is a program that provides specific solutions for the business system 100 and the process service 300. The process service 300 is a service that specializes in processing processes through a process engine, wherein the process service 300 is independently deployed and is not coupled with the business system.
[0051] It can be seen that both the business system 100 and the process service 300 have an interactive relationship with the core dependency 200, wherein the business system 100 and the process service 300 can communicate with the core dependency 200 through HTTP or MQ message queues respectively. When the business system 100 and the process service 300 need to call functions in the core dependency 200, they can send data to the core dependency 200 through the above communication method to make corresponding requests, so that the core dependency 200 calls its own internal methods to respond to the corresponding requests.
[0052] It is understandable that in this embodiment, if the business system 100 wants to customize rules, its rule data can be sent to the core dependency through the above-mentioned HTTP or MQ message queue. At this time, the core dependency can call the corresponding method in itself to process these rule data.
[0053] Figure 2 A flow chart of a service flow generation method according to an embodiment of the present application is shown. The service flow generation method is mainly executed in the above-mentioned core dependency 200. Exemplarily, the method includes the following steps:
[0054] Step S100, obtaining rule data published by the business system, and verifying the rule data.
[0055] The technical solution of the present application is applied to the generation process of the service process, in which it can be understood that there are various nodes in the service process, and each node has its own rule requirements according to the different matters it handles. Therefore, in this embodiment, it is possible to publish rule data through the business system to generate a rule processor that can process the required rules.
[0056] The above rule data can be edited and published by the user through a business system, where the business system is any system that needs to create a service process, such as a personnel management system, a project management system, and other business systems.
[0057] Among them, the rule data needs to contain some necessary data. Without this data, the corresponding rule processor cannot be generated. Therefore, when obtaining the rule data, the rule data will be verified to ensure that the necessary data exists in the rule data. If the data is missing during the verification step, the subsequent steps will not be performed, and an error prompt will be given to inform the user that the rule data it has published is incomplete.
[0058] It can be understood that this embodiment provides an interface for users to input rule data, so that the users can directly input rule data instead of generating a corresponding rule processor through code.
[0059] Step S200: Acquire configuration information in the rule data, and generate a rule processor corresponding to the rule data according to the configuration information.
[0060] The rule data mainly includes some configuration information, including rule name, rule scope, rule strategy, candidate interface information and authentication information.
[0061] The rule name is a unique string that names the rule. The rule scope indicates the scope of application of the rule, such as which systems it is used in, or which people with which permissions can access it. The rule strategy is the execution logic of the rule. For example, a rule that lists the check-in status of the current person has rule strategies such as query logic for events and display methods.
[0062] The candidate interface information is set for the service process corresponding to the rule. In addition to the executor, the service process also has an approver. For example, if the members of Group A execute the process, the approver must be the group leader of Group A. If the group does not have a group leader, it is necessary to continue to look for the manager or other related persons with approval authority. At this time, the candidate interface information is used to define the approver's interface information. Through this information, it can be defined which type of people can perform approval operations.
[0063] Authentication information is information used to identify the authority of people who execute or approve processes. It can be a simple authority level, or it can be corresponding authentication parameters set for certain departments, positions, etc.
[0064] Then, the corresponding basic rules can be matched according to the rule scope and the rule strategy. According to the rule scope and the rule strategy, at least one basic rule can be matched. These basic rules can be combined to implement the corresponding rule methods and scope limitations required by the rule scope and the rule strategy.
[0065] Basic rules are small rules that come with the system itself and can be considered as the smallest unit of rules. For example, within the rule scope of department A, the rule strategy is to list the current staff check-in status. In this case, it is necessary to match the basic rules that limit the scope of use of the rules, match the rules that can query the staff check-in status and the corresponding display rules.
[0066] Each basic rule has its own rule description, and the rule scope and rule strategy itself is also a kind of rule description. Therefore, only text matching is required to determine the rule description that matches the rule scope and rule strategy, thereby obtaining the basic rules corresponding to the rule description.
[0067] It can be seen that a custom rule can be implemented by combining multiple small rules, and some specific parameters are configured according to the candidate interface information and authentication information, so as to specify who can approve the rule and finally integrate it into a rule processor marked by the rule name.
[0068] After the rule processor is generated, the rule processor can be retrieved according to the rule name and thus called.
[0069] It should be noted that through the above operations, multiple rule processors can be generated, that is, there can be multiple rule data. According to the multiple rule data, they can be processed separately to generate multiple rule processors. Each rule processor is a program method that can be used to process corresponding rule events.
[0070] It can be understood that the rule processor of this embodiment can be completely customized by the user and does not need to be written from the bottom code. The user only needs to provide specific rule data to complete the editing of a rule processor. Through the basic rules in this embodiment and the rule data provided by the user, the corresponding rule processor can be automatically generated. The whole process is flexible and does not require the user to have programming skills. It only needs to fill in the relevant rule data as required, and then the rule processor can be automatically generated, which greatly simplifies the requirements for generating new rules.
[0071] In this embodiment, the rule processors formed in the above manner will be stored and managed by a rule manager. The rule manager is mainly used to provide corresponding retrieval and query functions when the business system or process service calls the rule processor.
[0072] Step S300: construct a process model, and configure the rule processor into the process model to form a service process.
[0073] Constructing a process model can be used to form a process service. It can be understood that there will be multiple task nodes in the process service. Each node is executed in a certain logical order to achieve the purpose of the process. Constructing a process model is to construct each task node and configure corresponding rule methods for each task node.
[0074] Specifically, the above-mentioned task nodes may be arranged in the form of node one, node two, and node three, and the generation of these nodes may be performed based on user input or through a visual programming interface.
[0075] like Figure 3 As shown, it is a simple process model diagram, which includes three task nodes, namely application node S1, approval node S2 and end node S3. The three task nodes are executed in sequence, and a process model is constructed in this way. It can be seen that the model only defines several task nodes and the sequence relationship between each task node. The specific method of each task node still needs to be defined by the subsequent user.
[0076] Therefore, it can be seen that when this embodiment constructs a process model, each task node and the execution order between each task node will be constructed first. Thus, a process model is obtained. It can be understood that the process model can be completely customized by the user, which can be as follows: Figure 3 The simple three-step process can also add more task nodes according to actual business needs to meet user requirements.
[0077] The method for configuring rules in the task node can be implemented by configuring the rule processor generated in the above steps into the task node.
[0078] It can be understood that the functions of each task node are different according to different requirements, so different rule processors need to be configured for each task node. Therefore, when building a process model, the rule configuration of each process task node will be defined, and the corresponding rule processor can be found according to the rule configuration. That is, through the aforementioned rule manager, according to the rule configuration, to match the corresponding rule processor.
[0079] In addition to setting the rule configuration, the user can also manually configure the rule processor in the previous steps into the corresponding node. That is, when defining the above-mentioned task nodes, the calling interface provided by the rule manager can be called to call the specified rule processor. Because the rule processor has a unique rule name, which is one of the rule data set in the previous steps, the user can directly make a directed association so that the rule processor can be called by the task node set by himself. In this way, a task node is configured.
[0080] If the task node does not find a matching rule processor, the configuration of the task node fails. Therefore, before building the process, it is necessary to determine whether the rule processor required by each task node exists. If not, it is necessary to generate the corresponding rule processor according to the above steps and then configure it.
[0081] The rule processor contains relevant parameters such as candidate interface information and authentication information. For task nodes, these relevant parameters can be used to configure approval, assign participants to the task node, and related judgment conditions, so that when the task node is running, the object it faces meets the limitations of the rule processor, thereby completing the configuration of each task node. Therefore, it can be seen that through the rule processor, in addition to adding rule processing logic to each task node, the corresponding parameters will also be configured to make the entire process meet the user's design expectations.
[0082] After forming the service process, this embodiment may also generate a task listener to monitor the task.
[0083] Specifically, the business system 100 may also receive task listening configurations input by the user, and these task listening configurations may also be sent to the core dependency 200 for processing to obtain a task listener.
[0084] The task listener configuration includes the task listener name and the task number. The task number is the number of the task to be listened to, which can be obtained by querying the specific task. The task listener name is a unique identifier used to mark the task listener.
[0085] The task listener is used to listen to tasks. The task here can be the process service generated in this embodiment, or it can be a task node in the process service. When the task listener listens to the corresponding task trigger, it can execute the preset response operation. For example, when it listens to the execution of process A, it sends a prompt email to let the associated processor handle related operations.
[0086] In addition, through the service process generation method of this embodiment, business systems that are not originally in the local service system can be integrated. It can be understood that the normal operation of a service system relies on various service processes. As long as the business system to be integrated has one or more sets of special service processes to meet the data interaction requirements, the integration of other business systems can be achieved. Figure 1 As shown, the core dependency 200 and the business system 100 and the process service 300 are in a separated state, that is, the core dependency used to realize the main functions of the service system itself is an independent module, and its content can be called by the connected business system. Therefore, in this architecture, the service system of this embodiment has good compatibility. When the company's departments expand or subsidiaries are generated, these newly generated departments and the company's business systems can still be connected to the service system through customized service processes, thereby realizing the dynamic expansion of the service system and enabling the enterprise to better adapt to the fast-paced development of the contemporary era.
[0087] The service process generation method of this embodiment obtains the rule data input by the user, parses it, matches the corresponding basic rules, and combines them to obtain a rule processor that can execute the rule logic in the rule data, and then creates a process model of the service process, performs corresponding configuration for each task node in the process model, and finally forms a service process. The service process can be automatically generated by the user through code, and the user is given certain customization rights, so that the user can set different rules based on the basic rules and related parameters.
[0088] like Figure 4 The figure is a schematic diagram of the structure of the service process integration device provided in this embodiment.
[0089] Exemplarily, the device comprises:
[0090] The data processing module 10 is used to obtain the rule data published by the business system and verify the rule data;
[0091] A rule generation module 20, configured to obtain configuration information in the rule data, and generate a rule processor corresponding to the rule data according to the configuration information;
[0092] The process construction module 30 is used to construct a process model and configure the rule processor into the process model to form a service process.
[0093] The present application also provides a terminal device, which includes a processor and a memory, wherein the memory stores a computer program, and the processor is used to execute the computer program to implement the service process generation method.
[0094] The terminal device may be a computer device such as a personal computer, a smart phone or a server.
[0095] The present application also provides a computer-readable storage medium storing a computer program, which implements the service process generation method when executed on a processor.
[0096] It can be understood that the device of this embodiment corresponds to the method of the above embodiment, and the options in the above embodiment are also applicable to this embodiment, so they will not be described repeatedly here.
[0097] Among them, the processor can be an integrated circuit chip with signal processing capabilities. The processor can be a general-purpose processor, including a central processing unit (CPU), a graphics processing unit (GPU) and a network processor (NP), a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field programmable gate array (FPGA) or at least one of other programmable logic devices, discrete gates or transistor logic devices, and discrete hardware components. The general-purpose processor can be a microprocessor or the processor can also be any conventional processor, etc., which can implement or execute the disclosed methods, steps and logic block diagrams in the embodiments of the present application.
[0098] The memory may be, but is not limited to, a random access memory (RAM), a read only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), etc. The memory is used to store a computer program, and the processor may execute the computer program accordingly after receiving an execution instruction.
[0099] For example, the computer-readable storage medium may include, but is not limited to, various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.
[0100] In several embodiments provided in the present application, it should be understood that the disclosed devices and methods can also be implemented in other ways. The device embodiments described above are merely schematic. For example, the flowcharts and structure diagrams in the accompanying drawings show the possible architecture, functions and operations of the devices, methods and computer program products according to multiple embodiments of the present application. In this regard, each box in the flowchart or block diagram can represent a module, a program segment or a part of a code, and the module, a program segment or a part of a code contains one or more executable instructions for implementing the specified logical function. It should also be noted that in an alternative implementation, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two consecutive boxes can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the structure diagram and / or the flow diagram, and the combination of boxes in the structure diagram and / or the flow diagram, can be implemented with a dedicated hardware-based system that performs a specified function or action, or can be implemented with a combination of dedicated hardware and computer instructions.
[0101] In addition, the functional modules or units in the various embodiments of the present application may be integrated together to form an independent part, or each module may exist separately, or two or more modules may be integrated to form an independent part.
[0102] If the functions are implemented in the form of software function modules and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art, or the part of the technical solution, can be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for a computer device (which can be a smart phone, a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the methods described in the various embodiments of the present application.
[0103] The above description is only a specific implementation manner of the present application, but the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application.
Claims
1. A service process generation method, characterized in that: include: Obtaining rule data published by the business system and verifying the rule data; Acquire configuration information in the rule data, and generate a rule processor corresponding to the rule data according to the configuration information; A process model is constructed, and the rule processor is configured into the process model to form a service process.
2. The service process generation method according to claim 1, characterized in that: The configuration information includes rule name, rule scope, rule strategy, candidate interface information and authentication information; The obtaining of configuration information in the rule data and generating a rule processor corresponding to the rule data according to the configuration information includes: According to the rule scope and the rule strategy, the corresponding basic rules are matched respectively; The candidate interface information and the authentication information are used as configuration parameters to configure the matched basic rules, and after integration, a rule processor marked with the rule name is obtained.
3. The service process generation method according to claim 2, characterized in that: The matching of corresponding basic rules according to the rule scope and the rule policy includes: Obtaining a rule description of each basic rule to be obtained; A rule description matching the rule scope and the rule policy is searched to obtain the basic rule corresponding to the rule description.
4. The service process generation method according to claim 1, characterized in that: The verifying the rule data includes: Determine whether all necessary configuration information in the rule data exists. If the configuration information is missing, confirm that the rule data verification has failed and give an error prompt.
5. The service process generation method according to claim 1, characterized in that: The service process also includes: Obtaining an input task monitoring configuration, wherein the task monitoring configuration includes a task monitoring name and a task number; According to the task number, the task to be monitored is determined, and a task monitor marked with the task monitoring name is generated.
6. The service process generation method according to claim 1, characterized in that: The process model is constructed, and the rule processor is configured into the process model to form a service process, including: Configure each task node in the process model and the order of each task node to obtain the process model; Define the rule configuration for each process task node; According to the rule configuration, obtain the corresponding rule processor; The rule processor is configured into each process task node to obtain a service process formed by each process task node.
7. The service process generation method according to claim 1, characterized in that: The obtaining of rule data published by the business system includes: The rule data published by the business system is obtained through HTTP, or the rule data encapsulated into an MQ message is obtained by subscribing to an MQ queue.
8. A service process integration device, characterized in that: include: A data processing module is used to obtain the rule data published by the business system and verify the rule data; A rule generation module, used to obtain configuration information in the rule data, and generate a rule processor corresponding to the rule data according to the configuration information; The process construction module is used to construct a process model and configure the rule processor into the process model to form a service process.
9. A terminal device, characterized in that: The terminal device comprises a processor and a memory, wherein the memory stores a computer program, and the processor is configured to execute the computer program to implement the service process generation method according to any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that: It stores a computer program, which, when executed on a processor, implements the service process generation method according to any one of claims 1-7.
Citation Information
Patent Citations
Information configuration method and device, computer equipment and computer readable storage medium
CN116798588A
Template material display method and device based on rule engine, equipment and medium
CN118193042A