CN115328459A - Business logic generation method and device, electronic equipment and storage medium - Google Patents

Business logic generation method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN115328459A
CN115328459A CN202210772109.1A CN202210772109A CN115328459A CN 115328459 A CN115328459 A CN 115328459A CN 202210772109 A CN202210772109 A CN 202210772109A CN 115328459 A CN115328459 A CN 115328459A
Authority
CN
China
Prior art keywords
component
configuration
logic
service
information
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202210772109.1A
Other languages
Chinese (zh)
Inventor
郑澈
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Dajia Internet Information Technology Co Ltd
Original Assignee
Beijing Dajia Internet Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Dajia Internet Information Technology Co Ltd filed Critical Beijing Dajia Internet Information Technology Co Ltd
Priority to CN202210772109.1A priority Critical patent/CN115328459A/en
Publication of CN115328459A publication Critical patent/CN115328459A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/30Creation or generation of source code
    • G06F8/34Graphical or visual programming
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/30Creation or generation of source code
    • G06F8/38Creation or generation of source code for implementing user interfaces
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/451Execution arrangements for user interfaces

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Human Computer Interaction (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

The disclosure relates to a method and a device for generating business logic, electronic equipment and a storage medium, and relates to the technical field of data processing. The specific scheme comprises the following steps: displaying a service management interface, wherein the service management interface comprises a plurality of services; responding to the selection operation of a target service in the plurality of services, switching from a display service management interface to a display configuration interface, wherein the configuration interface comprises a configuration component to be edited, the configuration component is used for generating a service logic of the target service after configuration, and the service logic is used for executing the target service; acquiring component information of the configuration component in response to an editing operation on the configuration component; and generating the service logic of the target service according to the component information of the configuration component. The method and the system realize the generation of the business logic by abstracting the business logic into products which are universal, easy to use, graphical and visual, and improve the universality and the development efficiency of software development.

Description

Business logic generation method and device, electronic equipment and storage medium
Technical Field
The present disclosure relates to the field of data processing technologies, and in particular, to a method and an apparatus for generating a service logic, an electronic device, and a storage medium.
Background
With the change of informatization construction requirements and underlying technologies, the traditional software development mode cannot meet complicated and variable service requirements. At present, the traditional software development mode mainly comprises a code-driven mode and a form-driven mode.
The code driving mode needs to firstly develop codes and then realize business logic, and the mode requires programmers to know the business logic and the realization of underlying technologies at the same time, so that the requirement is extremely high.
The form driving mode is a mode in which a user drags and arranges a generated form according to a preset rule. The mode has insufficient mobility and universality, and cannot realize ultra-complex and large-capacity software construction.
Disclosure of Invention
The present disclosure provides a method and an apparatus for generating a business logic, an electronic device, and a storage medium, which abstract the business logic into a product that is easy to use, graphical, and visual, so as to generate the business logic, thereby improving the universality and development efficiency of software development.
The technical scheme of the disclosure is as follows:
according to a first aspect of the present disclosure, a method for generating business logic is provided, where the method includes:
displaying a service management interface, wherein the service management interface comprises a plurality of services;
responding to the selection operation of a target service in the plurality of services, and switching from displaying the service management interface to displaying a configuration interface, wherein the configuration interface comprises a configuration component to be edited, the configuration component is used for generating a service logic of the target service after configuration, and the service logic is used for executing the target service;
acquiring component information of the configuration component in response to an editing operation on the configuration component;
and generating the service logic of the target service according to the component information of the configuration component.
Optionally, obtaining component information of the configuration component in response to the editing operation on the configuration component includes:
responding to the clicking operation of the configuration component, displaying a bullet box on the configuration interface, wherein the bullet box comprises attribute information of the configuration component, and the attribute information comprises at least one of the following items: configuring rules and self-defining information;
responding to clicking operation on the attribute information, displaying a drop-down box at a relevant position of the attribute information, wherein the drop-down box comprises a plurality of attribute values, and responding to selection operation on a target attribute value in the plurality of attribute values to take the target attribute value as the attribute value of the attribute information;
or, in response to an input operation to the attribute information, user input data is taken as an attribute value of the attribute information.
Optionally, the configuration component comprises at least one of: the system comprises a trigger configuration component, a logic node configuration component, an acquisition data component and an action component;
the trigger configuration component is configured to configure an execution condition of the target service, the logic node configuration component is configured to configure a logic flow of the target service, the data acquisition component is configured to configure a data source of the target service, and the action component is configured to configure an execution operation of the target service.
Optionally, the configuration component includes the trigger configuration component, the logic node configuration component, the data acquisition component, and the action component;
the generating the service logic of the target service according to the component information of the configuration component includes:
generating the execution condition according to the component information of the trigger configuration component;
generating a microflow according to the execution condition, the component information of the logic node configuration component, the component information of the acquired data component and the component information of the action component, wherein the microflow is used for representing a logic operation sequence of the target service;
and generating the business logic according to the microflow.
Optionally, the types of action components include at least one of: adding a record type, deleting the record type, updating the record type and rendering the type, wherein the rendering type is used for indicating whether attribute information is returned to the front-end component or not.
According to a second aspect of the present disclosure, there is provided a generating apparatus of business logic, including:
a display module configured to execute displaying a business management interface, the business management interface comprising a plurality of businesses; responding to the selection operation of a target service in the plurality of services, and switching from displaying the service management interface to displaying a configuration interface, wherein the configuration interface comprises a configuration component to be edited, the configuration component is used for generating a service logic of the target service after configuration, and the service logic is used for executing the target service;
an acquisition module configured to execute component information of the configuration component in response to an editing operation on the configuration component;
the generating module is configured to execute the service logic of the target service according to the component information of the configuration component acquired by the acquiring module.
Optionally, the obtaining module is specifically configured to perform:
responding to the clicking operation of the configuration component, displaying a bullet box on the configuration interface, wherein the bullet box comprises attribute information of the configuration component, and the attribute information comprises at least one of the following items: configuring rules and self-defining information;
responding to clicking operation on the attribute information, displaying a drop-down box at a relevant position of the attribute information, wherein the drop-down box comprises a plurality of attribute values, and responding to selection operation on a target attribute value in the plurality of attribute values to take the target attribute value as the attribute value of the attribute information;
or, in response to an input operation to the attribute information, user input data is taken as an attribute value of the attribute information.
Optionally, the configuration component comprises at least one of: the system comprises a trigger configuration component, a logic node configuration component, a data acquisition component and an action component;
the trigger configuration component is configured to configure an execution condition of the target service, the logic node configuration component is configured to configure a logic flow of the target service, the data acquisition component is configured to configure a data source of the target service, and the action component is configured to configure an execution operation of the target service.
Optionally, the configuration component includes the trigger configuration component, the logic node configuration component, the data acquisition component, and the action component. A generation module specifically configured to perform:
generating the execution condition according to the component information of the trigger configuration component;
generating a microflow according to the execution condition, the component information of the logic node configuration component, the component information of the acquired data component and the component information of the action component, wherein the microflow is used for expressing the logic operation sequence of the target service;
and generating the business logic according to the microflow.
Optionally, the types of action components include at least one of: adding a record type, deleting the record type, updating the record type and rendering the type, wherein the rendering type is used for indicating whether attribute information is returned to the front-end component or not.
According to a third aspect of the present disclosure, there is provided an electronic apparatus comprising:
a processor;
a memory for storing processor-executable instructions; wherein the processor is configured to execute the instructions to implement any one of the above-described first aspect, optionally the method for generating business logic.
According to a fourth aspect of the present disclosure, there is provided a computer-readable storage medium having instructions stored thereon, which, when executed by a processor of an electronic device, enable the electronic device to perform the method for generating any one of the above-mentioned first aspects, optionally business logic.
According to a fifth aspect of the present disclosure, there is provided a computer program product containing instructions which, when run on an electronic device, cause the electronic device to perform the method of generating optionally business logic as in any of the first aspects.
The technical scheme provided by the disclosure at least brings the following beneficial effects: the generation device of the business logic displays a business management interface, responds to the selection operation of a user on a target business in a plurality of businesses included in the business management interface, and switches from the display business management interface to a display configuration interface, wherein the configuration interface includes a configuration component to be edited, the configuration component is used for generating the business logic of the target business after configuration, and the business logic is used for executing the target business. The business logic generating device can respond to the editing operation of the configuration component by the user, acquire the component information of the configuration component, and generate the business logic of the target business according to the component information of the configuration component.
By providing a visual service management interface, a user can select a target service on the service management interface, and a visual configuration interface of the target service is provided, so that the user can edit a configuration component of the target service on the configuration interface, and a service logic generation device can acquire component information of the configuration component of the target service and generate a service logic of the target service based on the component information. Therefore, the business logic is abstracted into a visual product, codes do not need to be written, and the generation of the business logic can be realized only by simple configuration, so that the technical threshold of software development is reduced, and the universality and the development efficiency of the software development are improved.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the disclosure.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and, together with the description, serve to explain the principles of the disclosure and are not to be construed as limiting the disclosure.
FIG. 1 is one of the flow diagrams illustrating a method for generating business logic in accordance with an exemplary embodiment.
FIG. 2 is a schematic diagram illustrating a configuration interface for a target service in accordance with an illustrative embodiment.
FIG. 3 is a schematic diagram illustrating a bullet box of a time trigger assembly according to an exemplary embodiment.
FIG. 4 is a schematic diagram illustrating a bullet box of a get data sheet component in accordance with an exemplary embodiment.
FIG. 5 is a schematic diagram illustrating a bullet box of a loop node assembly, according to an example embodiment.
FIG. 6 is a second flowchart illustrating a method of generating business logic in accordance with an exemplary embodiment.
Fig. 7 is a block diagram illustrating a logical structure of a business logic generation apparatus according to an exemplary embodiment.
Fig. 8 is a block diagram illustrating a structure of an electronic device according to an example embodiment.
Detailed Description
In order to make the technical solutions of the present disclosure better understood by those of ordinary skill in the art, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below with reference to the accompanying drawings.
It should be noted that the embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present disclosure. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the disclosure, as detailed in the appended claims.
It should be noted that the user information (including but not limited to user device information, user personal information, etc.) related to the embodiments of the present disclosure is information authorized by the user or sufficiently authorized by each party.
The method for generating the service logic provided by the embodiment of the disclosure can be applied to a scene that the electronic device generates the service logic of the target service. In the related art, the business logic is generated through a code-driven mode or a form-driven mode, but the code development mode requires programmers to know the business logic and the implementation of the underlying technology at the same time, and the form-driven mode has insufficient migratability and universality.
In order to improve the universality and the development efficiency of software development, the embodiment of the disclosure provides a method for generating business logic, and the business logic is abstracted into a visual product, so that codes do not need to be written, and the generation of the business logic can be realized only by simple configuration, thereby reducing the technical threshold of software development and improving the universality and the development efficiency of software development.
For convenience of understanding, before describing the method for generating the business logic of the embodiment of the present disclosure, the words involved in the embodiment of the present disclosure are described in detail.
1. Microflow (microflow)
The microflow can connect triggers, nodes, actions, express the running order of the business logic. A complete microflow represents an end-to-end business logic.
It will be appreciated that a micro-flow represents a complete business logic, and a micro-flow is composed of a trigger and several actions. The trigger is a switch started by the process, acquires data required in the data acquisition process, completes service logic torsion in the microflow through the logic node, and completes tasks required to be completed by the system through various types of actions, so that the automation of the process is realized.
2. Trigger (trigger)
The trigger refers to a condition that the micro-flow is triggered to proceed, and may include several types, such as a time trigger (time trigger), a data table event trigger (database event trigger), a front end event trigger (front end event trigger), and a webhook trigger (webhook trigger). The time trigger is to set a cycle time, and each time the time reaches a cycle time, the micro-flow can be executed once. The data table event trigger means that when the record in the data table is added, updated or deleted, the micro-flow can be executed once. The front-end event trigger refers to that when the front-end component performs operations such as inputting, clicking, selecting and the like, the micro-flow can be executed once. The interface trigger means that when the data table supports passive data receiving, other systems can execute the microflow once after the data table is changed.
3. Acquiring data (database retrieve)
Acquiring data refers to acquiring a single or multiple records and using them in subsequent processes. The data acquisition may include several types, such as a database recovery table (database recovery), a component parameter (component parameter recovery), a webhook recovery interface parameter (webhook recovery), and a variable definition, depending on the data source. Wherein, acquiring the data table means acquiring a single or multiple records from the data table and using the records in the following process. Acquiring component parameters refers to acquiring pass-through parameters of the front-end component and using the parameters in a later process. Acquiring the interface parameters refers to acquiring the parameters from other systems, and table data of the system can also be pushed to other systems. The definition variables refer to custom variables and are assigned values and used in the following process.
4. Logic node (local node)
The logical nodes support logical torsion in the microflow, such as conditional decisions, traversal loops, and the like. Based on different logics, the logical node may include a conditional node (condition node), a loop node (loop node), and the like. The condition nodes can lead the data of different types to different branches by setting the screening of the condition nodes. The loop node may perform a traversal loop over the list data.
5. Action (action)
An action refers to an operational response by the system. According to different operation responses, the action may include several types, such as a new record (adding record), an update record (update record), a delete record (delete record), and a data return (data return). Wherein, adding new record refers to adding one or more rows of record to the designated data table automatically. Updating a record refers to updating the value of a field or fields in a record. Deleting a record refers to deleting a record in the table. Data return refers to returning values, whether hidden, color, etc. to the front-end component.
Fig. 1 is a flow chart illustrating a method for generating business logic according to an exemplary embodiment, which may include the following steps 101-104, as shown in fig. 1.
101. And displaying a service management interface, wherein the service management interface comprises a plurality of services.
When the business logic needs to be generated, a user can log in the business management platform on the electronic equipment. The electronic equipment responds to the login operation of the user, displays a service management interface of the service management platform, and displays a plurality of services in the service management interface for the user to select.
102. And responding to the selection operation of the target service in the plurality of services, and switching from the service management display interface to a configuration display interface, wherein the configuration interface comprises a configuration component to be edited.
When the business logic of the target business needs to be generated, the user can select the target business from the multiple businesses displayed on the business management interface. The electronic equipment can respond to the selection operation of the user on the target service, switch from the display service management interface to the configuration interface for displaying the target service, and display the configuration component to be edited in the configuration interface. The configuration component is used for configuring business logic of the target business, and the business logic is used for executing the target business.
Optionally, in an embodiment of the present disclosure, the configuration component in the configuration interface may include at least one of the following: the system comprises a trigger configuration component, a logic node configuration component, a data acquisition component and an action component. The trigger configuration component is used for configuring the execution condition of the target service, the logic node configuration component is used for configuring the logic flow of the target service, the data component is used for configuring the data source of the target service, and the action component is used for configuring the execution operation of the target service.
Optionally, in an embodiment of the present disclosure, the type of the action component includes at least one of: adding a record type, deleting a record type, updating a record type and rendering a type. Wherein the rendering type is used to indicate whether to return the property information to the front-end component. That is to say, the execution action of the service logic of the target service may be to add or delete a record, or may be front-end and back-end information interaction, or of course may also be other operations, and the embodiment of the present disclosure is not limited herein.
103. And acquiring component information of the configuration component in response to the editing operation on the configuration component.
After the configuration interface of the target service is displayed, the electronic device may respond to the editing operation of the user on each configuration component in the configuration interface to acquire component information of each configuration component.
It is to be understood that the above-mentioned component information of the configuration component may include one or more attribute information of the configuration component, and an attribute value corresponding to each attribute information. The attribute information may include, but is not limited to, at least one of: configuration rules and self-defined information. That is, the attribute information may be a preset rule, and a plurality of attribute values corresponding to the attribute information are preset for the user to select, or of course, the user may customize the attribute values of the attribute information. The attribute information and corresponding values may also be fully user-defined.
104. And generating the service logic of the target service according to the component information of the configuration component.
After the electronic device acquires the component information of all the configuration components, the electronic device can generate the service logic of the target service according to the component information of the configuration components. In one possible embodiment, the electronic device may generate the business logic according to the component information of all the configuration components in response to a configuration end operation of the user. After the electronic device generates the service logic, the target service can be executed according to the service logic under the condition that the execution condition of the service logic is met.
Illustratively, the target task may be an enrollment service for an enrollment staff, a departure service for a departure staff, a position management service for an on-staff, a cost reimbursement service, and the like.
The technical scheme provided by the embodiment at least has the following beneficial effects: the generation device of the business logic displays a business management interface, and responds to the selection operation of a user on a target business in a plurality of businesses included in the business management interface, the business management interface is switched to a display configuration interface from the display business management interface, the configuration interface includes a configuration component to be edited, the configuration component is used for generating the business logic of the target business after configuration, and the business logic is used for executing the target business. The business logic generation device can respond to the editing operation of the configuration component by the user, acquire the component information of the configuration component, and generate the business logic of the target business according to the component information of the configuration component.
By providing a visual service management interface, a user can select a target service on the service management interface, and a visual configuration interface of the target service is provided, so that the user can edit a configuration component of the target service on the configuration interface, and a service logic generation device can acquire component information of the configuration component of the target service and generate a service logic of the target service based on the component information. Therefore, the business logic is abstracted into a visual product, codes do not need to be written, and the generation of the business logic can be realized only by simple configuration, so that the technical threshold of software development is reduced, and the universality and the development efficiency of the software development are improved.
Optionally, in this embodiment of the present disclosure, a specific process of the electronic device obtaining the component information of the configuration component in step 103 may be that the electronic device responds to a click operation of a user on a certain configuration component in the configuration interface of the target service, and displays a pop-up frame on the configuration interface, where the pop-up frame may include one or more attribute information of the configuration component. These attribute information may include at least one of: configuration rules and custom information.
In the case that the attribute information includes the configuration rule, the electronic device may display a drop-down box in a position associated with the attribute information in response to a click operation of a user on certain attribute information in the configuration component, where the drop-down box may include a plurality of attribute values. The electronic device may take the target attribute value as the attribute value of the attribute information in response to a user's selection operation of the target attribute value among the plurality of attribute values. Alternatively, the electronic device may set the user input data as the attribute value of the attribute information in response to an input operation of the attribute information by the user.
In the case that the attribute information includes the custom information, the electronic device may obtain the custom information of the configuration component input by the user in response to an editing operation of the user on the custom information. The customization information may include attribute information and corresponding attribute values for the configuration component.
In this way, by providing the configuration component capable of being edited in the form of a pop-up box, a drop-down box and the like, the user can edit the configuration component of the target service according to actual requirements. The electronic equipment can acquire the component information of the configuration components according to the editing operation of the user, and prepare for the subsequent automatic generation of the business logic of the target business. In the process of generating the service logic, a user does not need to write codes and directly operates in the configuration interface according to task requirements, so that the technical threshold of software development is reduced, and the universality of the software development is improved.
Illustratively, fig. 2 is a schematic diagram of a configuration interface of a target service displayed by an electronic device. As shown in fig. 2, the configuration interface includes four configuration components to be edited, namely a trigger configuration component, a logic node configuration component, a data acquisition component, and an action component. The trigger configuration component comprises a time trigger component, a data table event trigger component, an interface trigger component and a front-end event trigger component. The logic node configuration component comprises a condition node component and a circulation node component. The data acquisition component comprises a data acquisition table component, a parameter acquisition component, an interface parameter acquisition component and a variable definition component. The action component comprises an adding record component, an updating record component, a deleting record component and a data returning component.
For example, when the user clicks the trigger configuration component as shown in fig. 2, the electronic device receives a click operation of the trigger configuration component by the user. In response to the clicking operation, the electronic device displays a pop-up box of the trigger configuration component on the configuration interface.
Assuming that the trigger configuration component is a time trigger component, fig. 3 is a schematic diagram of a bullet box of the time trigger component. As shown in fig. 3, the bullet box includes attribute information of the trigger configuration component: start execution time, loop rules. After the user configures the two attribute information, the electronic device may obtain component information of the time trigger component: the start execution time is 2022 years, 6 months, 1 am, 11 am, and the loop rule is every three weeks. That is, the target service is executed once every wednesday at 11 am, starting at 11 am on day 1 of 6/month 2022. For example, assuming that the target service is a holiday, from 11 am on 1 st on 6 th and 1 st in 2022, holiday morning, holiday afternoon 11 pm. It will be appreciated that the attribute information of the time trigger component may also include a message reminder time. For example, the message reminder time may be 10 a.m. every wednesday, then the message reminder may be made to project members of the weekly conference at 10 a.m. every wednesday.
Assuming that the trigger configuration component is a spreadsheet event trigger component, the attribute information of the spreadsheet event trigger component may include: selecting a data table, a trigger mode, a trigger field, etc. The component information for the spreadsheet event trigger component may include: and selecting the attribute value of the data table as a data table A, and selecting the attribute value of the trigger mode as a field B when only the record is updated and the attribute value of the trigger field is. And executing the business logic of the target business when the record in which the field B in the data table A is positioned is updated. For example, assuming that the target service is a forward service and the field B is a forward state, when the forward state of an employee in the data table a is updated, such as when the trial period is changed to a forward state, the electronic device may push a corresponding message reminder to the employee. Optionally, the attribute information of the data table event trigger component may further include: and (4) screening conditions. The attribute values of the filter criteria may include all fields in data table a and all fields in the association table of the data table a, such as creator, creation time, modification time, identification, and the like. The selectable conditions and definable ranges for different types of fields differ. It is noted that when the screening conditions are set, the trigger, the logical node, and the screening conditions for obtaining data in the micro-flow need to be consistent.
Assuming that the trigger configuration component is an interface trigger component, the attribute information of the interface trigger component includes: a link to accept the request, a list of configuration parameters, etc. The component information of the interface trigger component may include: the link is https://, the configuration parameter list is the sent request instance or custom parameter list. In this case, the data table of the service management platform supports passive data reception, and when the data table called by the link is updated and the requirement of the configuration parameter list is met, the service logic of the target service can be executed.
Assuming that the trigger configuration component is a front-end event trigger component, the attribute information of the front-end event trigger component includes: front-end components, trigger operations. The component information of the front-end event trigger component includes: the front-end component is a text box component at the front end, and the triggering operation is a clicking operation. When the text box component at the front end is clicked by the user, the business logic of the target business can be executed, for example, the identity of the employee is returned.
For another example, when the user clicks the get data component shown in fig. 2, the electronic device receives a click operation of the user on the get data component. In response to the clicking operation, the electronic device displays a pop-up box of the acquired data component on the configuration interface.
Assuming the get data component is a get data sheet component, FIG. 4 is a schematic diagram of a bullet box of the get data sheet component. As shown in fig. 4, the bullet frame includes an attribute information selection data table for obtaining the data table component, and a screening condition, where the screening condition includes a search type and a sorting rule. The attribute value of the selected data table may be the name of a certain data table, and the attribute value of the search type may be the name of all data, the name of the first data, the name of the user, and the like. The ordering rules may include selection rules for user-selected fields, which may select a field range. When the search type is to search all data, all records found according to the rules are arranged in the order of time from back to front by default. And when the search type is to search the first piece of data, arranging all records meeting the requirements in the order from back to front according to time, acquiring the arranged first piece of record, and returning any one record in all records if no rule is set.
Assuming that the get data component is a get parameter component, obtaining attribute information of the parameter component may include: front-end component, get operation. The attribute value of the front-end component may be the name of a certain front-end component, and the obtaining operation may be a click operation, a double click operation, a long press operation, or the like. In a specific implementation, a user may drag an acquisition parameter component, open a pop-up window, and perform a click operation on a certain front-end component in the pop-up window, so that the electronic device may acquire a value of the front-end component and use the value in a subsequent process.
Assuming that the component for acquiring data is the component for acquiring interface parameters, the electronic device may acquire data from the service management platform through a predefined interface and push the data to another system, or acquire parameters from another system. For example, the electronic device may periodically obtain information about employees from the human resources system of the enterprise and add the information about newly added employees to the data sheet.
Assuming the get data component is a define variable component, the electronic device can receive a user-defined variable and assign a value to the variable for use in later processes.
For another example, when the user clicks on the logical node configuration component shown in fig. 2, the electronic device receives a click operation of the logical node configuration component by the user. In response to the clicking operation, the electronic device displays a pop-up box of the logical node configuration component on the configuration interface.
Assuming that the logical node configuration component is a conditional node component, the bounding box of the conditional node component includes a plurality of conditional nodes, a plurality of branches for each conditional node, and a screening rule for each branch. It should be noted that there is no logical mutual exclusion between branches and no prioritization between branches. Therefore, different types of data are led to different branches by setting the screening of the condition nodes.
Assuming that the logical node configuration component is a cyclic node component, fig. 5 is a schematic diagram of a bullet box of the cyclic node component. As shown in fig. 5, the bullet box includes a list that needs to be looped and an end condition. The end condition may include one or more end fields and the relationship of these fields, such as a relationship of (a) and (b), or a relationship of (a) and (b), etc. After setting the attribute values of the attribute information, the user can perform traversal circulation on the list data according to the setting rule.
For another example, when the user clicks the action component as shown in fig. 2, the electronic device receives a click operation of the user on the action component. In response to the clicking operation, the electronic device displays a pop-up frame of the action component on the configuration interface. When the action component is an update record component, an add record component, or a delete record component, the attribute information may include: objects that need to be selected (i.e., selected data tables, representing in which data table records are added or deleted), selected fields, etc. When the action component is a data return component, data will only be returned in the microflow triggered by the front-end component. Attributes of the returned data can be set, referring to which attributes of the return front-end component, such as return value, whether to hide, color, etc.
Optionally, in this disclosure, when the configuration component of the configuration interface includes a trigger configuration component, a logic node configuration component, a data acquisition component, and an action component, with reference to fig. 1, as shown in fig. 6, the step 104 may specifically include the following steps 105 to 107.
105. And generating an execution condition according to the component information of the trigger configuration component.
After obtaining the component information of each configuration component, the electronic device may generate an execution condition of the service logic according to a trigger rule corresponding to the component information of the trigger configuration component, such as a trigger type.
For example, in combination with the example in the foregoing embodiment, the execution condition may be that the execution is performed from 11 am on 1 st day of 6 months in 2022, every wednesday at 11 am, or may be that the record in a certain data table is updated or newly added.
106. And generating a microflow according to the execution condition, the component information of the logic node configuration component, the component information of the acquired data component and the component information of the action component.
Microflows are used to represent the logical run order of the target traffic. After generating the execution condition of the target service, the electronic device may combine the execution condition, the component information of the logical node configuration component, the component information of the acquired data component, and the component information of the action component into a service flow, that is, a micro flow. That is, after the execution condition is satisfied, it is done first and then until the last action is performed.
107. Business logic is generated from the microflows.
After the electronic device generates the micro-flow, the electronic device can generate the service logic of the target service according to the micro-flow, so that the subsequent direct execution is facilitated.
The technical scheme provided by the embodiment at least has the following beneficial effects: after the electronic equipment acquires the component information of each configuration component, the service logic of the target service is automatically acquired by processing the component information, and the development efficiency of the service logic is improved.
Fig. 7 is a block diagram illustrating a logical structure of a business logic generation apparatus according to an exemplary embodiment. Referring to fig. 7, the apparatus for generating service logic is applied to an electronic device, and includes: a display module 71, an acquisition module 72 and a generation module 73.
A display module 71 configured to execute displaying a service management interface, wherein the service management interface comprises a plurality of services; responding to the selection operation of a target service in the plurality of services, and switching from displaying the service management interface to displaying a configuration interface, wherein the configuration interface comprises a configuration component to be edited, the configuration component is used for generating a service logic of the target service after configuration, and the service logic is used for executing the target service;
an obtaining module 72 configured to perform obtaining component information of the configuration component in response to an editing operation on the configuration component;
a generating module 73 configured to execute the service logic for generating the target service according to the component information of the configuration component acquired by the acquiring module 72.
Optionally, the obtaining module 72 is specifically configured to perform:
responding to the clicking operation of the configuration component, displaying a bullet box on the configuration interface, wherein the bullet box comprises attribute information of the configuration component, and the attribute information comprises at least one of the following items: configuring rules and self-defining information;
responding to clicking operation on the attribute information, displaying a drop-down box at a relevant position of the attribute information, wherein the drop-down box comprises a plurality of attribute values, and responding to selection operation on a target attribute value in the plurality of attribute values to take the target attribute value as the attribute value of the attribute information;
or, in response to an input operation to the attribute information, user input data is taken as an attribute value of the attribute information.
Optionally, the configuration component comprises at least one of: the system comprises a trigger configuration component, a logic node configuration component, a data acquisition component and an action component;
the trigger configuration component is configured to configure an execution condition of the target service, the logic node configuration component is configured to configure a logic flow of the target service, the data acquisition component is configured to configure a data source of the target service, and the action component is configured to configure an execution operation of the target service.
Optionally, the configuration component includes the trigger configuration component, the logic node configuration component, the data acquisition component, and the action component. The generating module 73 is specifically configured to perform:
generating the execution condition according to the component information of the trigger configuration component;
generating a microflow according to the execution condition, the component information of the logic node configuration component, the component information of the acquired data component and the component information of the action component, wherein the microflow is used for expressing the logic operation sequence of the target service;
and generating the business logic according to the microflow.
Optionally, the types of action components include at least one of: adding a record type, deleting the record type, updating the record type and rendering the type, wherein the rendering type is used for indicating whether attribute information is returned to a front-end component or not.
With regard to the apparatus in the above-described embodiment, the specific manner in which each module performs the operation has been described in detail in the embodiment related to the method, and will not be elaborated here.
Fig. 8 is a block diagram illustrating a structure of an electronic device according to an exemplary embodiment, where the electronic device may be a business logic generation apparatus, and the business logic generation apparatus may be: a smartphone, a tablet, a laptop, or a desktop computer.
The means for generating the service logic may comprise at least one processor 81, a communication bus 82, a memory 83 and at least one communication interface 84.
The processor 81 may be a Central Processing Unit (CPU), a micro-processing unit, or one or more integrated circuits for controlling the execution of programs in accordance with the disclosed aspects.
The communication bus 82 may include a path to transfer information between the aforementioned components.
The communication interface 84 may be any device, such as a transceiver, for communicating with other devices or communication networks, such as an ethernet, a Radio Access Network (RAN), a Wireless Local Area Network (WLAN), etc.
The memory 83 may be, but is not limited to, a read-only memory (ROM) or other type of static storage device that may store static information and instructions, a Random Access Memory (RAM) or other type of dynamic storage device that may store information and instructions, an electrically erasable programmable read-only memory (EEPROM), a compact disk read-only memory (CD-ROM) or other optical disk storage, optical disk storage (including compact disk, laser disk, optical disk, digital versatile disk, blu-ray disk, etc.), a magnetic disk storage medium or other magnetic storage device, or any other medium that can be used to carry or store desired program code in the form of instructions or data structures and that can be accessed by a computer. The memory may be self-contained and connected to the processing unit by a bus. The memory may also be integrated with the processing unit.
The memory 83 is used for storing application program codes for executing the disclosed solution, and is controlled by the processor 81. The processor 81 is configured to execute application program code stored in the memory 83 to implement the functions of the disclosed method.
In particular implementations, processor 81 may include one or more CPUs, such as CPU0 and CPU1 in fig. 8, as one embodiment.
In a specific implementation, the generating means of the business logic may include a plurality of processors, such as the processor 81 and the processor 85 in fig. 8, as an embodiment. Each of these processors may be a single-core (single-CPU) processor or a multi-core (multi-CPU) processor.
In a specific implementation, the generating apparatus of the service logic may further include an input device 86 and an output device 87 as an embodiment. The input device 86 is in communication with the processor 81 and can accept user input in a variety of ways. For example, the input device 86 may be a mouse, a keyboard, a touch screen device, or a sensing device, among others. An output device 87 is in communication with the processor 81 and can display information in a variety of ways. For example, the output device 87 may be a Liquid Crystal Display (LCD), a Light Emitting Diode (LED) display device, or the like.
Those skilled in the art will appreciate that the configuration shown in fig. 8 does not constitute a limitation of the electronic device and may include more or fewer components than those shown, or combine certain components, or employ a different arrangement of components.
The present disclosure also provides a computer-readable storage medium including instructions stored thereon, which, when executed by a processor of a computer, enable the computer to perform the method for generating business logic provided by the above-described illustrated embodiments. For example, the computer readable storage medium may be a memory 83 comprising instructions executable by a processor 81 of an electronic device to perform the above-described method. Alternatively, the computer readable storage medium may be a ROM, a RAM, a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, and the like.
The present disclosure also provides a computer program product containing instructions which, when run on an electronic device, cause the electronic device to perform the method of generating business logic provided by the above-described illustrative embodiments.
Other embodiments of the disclosure will be apparent to those skilled in the art from consideration of the specification and practice of the disclosure disclosed herein. This disclosure is intended to cover any variations, uses, or adaptations of the disclosure following, in general, the principles of the disclosure and including such departures from the present disclosure as come within known or customary practice in the art to which the disclosure pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the disclosure being indicated by the following claims.
It will be understood that the present disclosure is not limited to the precise arrangements described above and shown in the drawings and that various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.

Claims (10)

1. A method for generating business logic, comprising:
displaying a service management interface, wherein the service management interface comprises a plurality of services;
responding to the selection operation of a target service in the plurality of services, and switching from displaying the service management interface to displaying a configuration interface, wherein the configuration interface comprises a configuration component to be edited, the configuration component is used for generating a service logic of the target service after configuration, and the service logic is used for executing the target service;
acquiring component information of the configuration component in response to an editing operation on the configuration component;
and generating the service logic of the target service according to the component information of the configuration component.
2. The method for generating business logic according to claim 1, wherein the obtaining component information of the configuration component in response to the editing operation on the configuration component comprises:
responding to the clicking operation of the configuration component, displaying a bullet box on the configuration interface, wherein the bullet box comprises attribute information of the configuration component, and the attribute information comprises at least one of the following items: configuring rules and self-defining information;
responding to clicking operation on the attribute information, displaying a drop-down box at a relevant position of the attribute information, wherein the drop-down box comprises a plurality of attribute values, and responding to selection operation on a target attribute value in the plurality of attribute values, and taking the target attribute value as the attribute value of the attribute information;
or, in response to an input operation on the attribute information, taking user input data as an attribute value of the attribute information.
3. The method of generating business logic according to claim 1 or 2, wherein the configuration component comprises at least one of: the system comprises a trigger configuration component, a logic node configuration component, an acquisition data component and an action component;
the trigger configuration component is configured to configure an execution condition of the target service, the logic node configuration component is configured to configure a logic flow of the target service, the data acquisition component is configured to configure a data source of the target service, and the action component is configured to configure an execution operation of the target service.
4. The business logic generation method according to claim 3, wherein the configuration component comprises the trigger configuration component, the logical node configuration component, the data acquisition component, and the action component;
the generating the service logic of the target service according to the component information of the configuration component includes:
generating the execution condition according to the component information of the trigger configuration component;
generating a microflow according to the execution condition, the component information of the logic node configuration component, the component information of the acquired data component and the component information of the action component, wherein the microflow is used for expressing the logic operation sequence of the target service;
and generating the business logic according to the microflow.
5. The business logic generation method of claim 3, wherein the type of the action component comprises at least one of: adding a record type, deleting the record type, updating the record type and rendering the type, wherein the rendering type is used for indicating whether attribute information is returned to the front-end component or not.
6. An apparatus for generating business logic, comprising:
a display module configured to execute displaying a business management interface, the business management interface comprising a plurality of businesses; responding to selection operation of a target service in the plurality of services, and switching from displaying the service management interface to displaying a configuration interface, wherein the configuration interface comprises a configuration component to be edited, the configuration component is used for generating service logic of the target service after configuration, and the service logic is used for executing the target service;
an acquisition module configured to execute component information of the configuration component in response to an editing operation on the configuration component;
the generating module is configured to execute the service logic for generating the target service according to the component information of the configuration component acquired by the acquiring module.
7. The apparatus for generating business logic according to claim 6, wherein the obtaining module is specifically configured to perform:
responding to the clicking operation of the configuration component, displaying a bullet box on the configuration interface, wherein the bullet box comprises attribute information of the configuration component, and the attribute information comprises at least one of the following items: configuring rules and self-defining information;
responding to clicking operation on the attribute information, displaying a drop-down box at a relevant position of the attribute information, wherein the drop-down box comprises a plurality of attribute values, and responding to selection operation on a target attribute value in the plurality of attribute values to take the target attribute value as the attribute value of the attribute information;
or, in response to an input operation to the attribute information, user input data is taken as an attribute value of the attribute information.
8. An electronic device, comprising:
a processor;
a memory for storing the processor-executable instructions;
wherein the processor is configured to execute the instructions to implement the method of generating business logic of any of claims 1-5.
9. A computer-readable storage medium having instructions stored thereon, wherein the instructions in the computer-readable storage medium, when executed by a processor of an electronic device, enable the electronic device to perform the method of generating business logic of any of claims 1-5.
10. A computer program product comprising computer instructions, characterized in that the computer instructions, when executed by a processor, implement the method of generating business logic of any of claims 1-5.
CN202210772109.1A 2022-06-30 2022-06-30 Business logic generation method and device, electronic equipment and storage medium Pending CN115328459A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210772109.1A CN115328459A (en) 2022-06-30 2022-06-30 Business logic generation method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210772109.1A CN115328459A (en) 2022-06-30 2022-06-30 Business logic generation method and device, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN115328459A true CN115328459A (en) 2022-11-11

Family

ID=83917143

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210772109.1A Pending CN115328459A (en) 2022-06-30 2022-06-30 Business logic generation method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN115328459A (en)

Similar Documents

Publication Publication Date Title
US11703826B1 (en) Monitoring asset hierarchies based on asset group metrics
CN112036736B (en) Workflow creation method and device
US20190392617A1 (en) Visual workflow model
US9268538B2 (en) Metadata driven user interface system and method
US11809439B1 (en) Updating client dashboarding component of an asset monitoring and reporting system
US20070282659A1 (en) System and Methods for Managing Complex Service Delivery Through Coordination and Integration of Structured and Unstructured Activities
US11461350B1 (en) Control interface for dynamic elements of asset monitoring and reporting system
US11561771B2 (en) System and method for in-ide code review
JP2012059261A (en) Context based user interface, retrieval, and navigation
WO2019062673A1 (en) Information-based management implementation method and system based on input and output semantization
US20190180337A1 (en) Requirement-specific configuration of user interface forms
CN112764736B (en) Web end flow chart modeling method, device and system
US11210278B1 (en) Asset group interface driven by search-derived asset tree hierarchy
US20140074526A1 (en) Synchronizing data related to workflow
US20130247051A1 (en) Implementation of a process based on a user-defined sub-task sequence
CN116382643A (en) Running system based on low-code platform
US11295260B2 (en) Multi-process workflow designer
US20150317721A1 (en) Enterprise mobile application for managing sales activites
US20200201610A1 (en) Generating user interfaces for managing data resources
CN115328459A (en) Business logic generation method and device, electronic equipment and storage medium
US20130218893A1 (en) Executing in-database data mining processes
US20140324496A1 (en) Project management application including competency search capability
US11288611B2 (en) Multi-process workflow designer user interface
US11740986B2 (en) System and method for automated desktop analytics triggers
Sun et al. UMDISW: A universal multi-domain intelligent scientific workflow framework for the whole life cycle of scientific data

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination