CN112905183A - External data conversion mapping method for flow form - Google Patents

External data conversion mapping method for flow form Download PDF

Info

Publication number
CN112905183A
CN112905183A CN201911229759.6A CN201911229759A CN112905183A CN 112905183 A CN112905183 A CN 112905183A CN 201911229759 A CN201911229759 A CN 201911229759A CN 112905183 A CN112905183 A CN 112905183A
Authority
CN
China
Prior art keywords
mapping
data
work order
template
flow
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
CN201911229759.6A
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.)
Guangzhou Faisco Internet Technology Co ltd
Original Assignee
Guangzhou Faisco Internet 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 Guangzhou Faisco Internet Technology Co ltd filed Critical Guangzhou Faisco Internet Technology Co ltd
Priority to CN201911229759.6A priority Critical patent/CN112905183A/en
Publication of CN112905183A publication Critical patent/CN112905183A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/40Transformation of program code
    • G06F8/41Compilation
    • G06F8/43Checking; Contextual analysis
    • G06F8/433Dependency analysis; Data or control flow analysis

Landscapes

  • Engineering & Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Stored Programmes (AREA)

Abstract

The invention discloses a method for converting and mapping external data of a flow form, which comprises the following steps: carrying out basic configuration on the mapping, including basic configuration of a mapping template, a mapping field table, a mapping rule and a dictionary table; binding a flow ID and a form ID by a mapping table template; defining an effective receiving method; checking whether the access source is legal or not, and checking whether the parameters meet the rules and the specifications or not; mapping a parameter format required by the generated flow instance according to the mapping template table and the mapping field table; calling a process engine service and a form engine service to generate a process instance; inquiring a corresponding work order list and work order details according to the type of the work order, and performing mutual data conversion; and after the data are merged, responding to the access service system. The invention improves the flexibility of the external system to create the flow form, simplifies the implementation time of developers, optimizes the service codes with excessive code layers and avoids redundant codes.

Description

External data conversion mapping method for flow form
Technical Field
The invention relates to the technical field of web and java, in particular to a method for converting and mapping external data of a flow form.
Background
The emergence of micro services, which services can be provided by a system, the independence, characteristics, safety and the like of the services are all important standards for perfection of system services, and reflect the importance of interaction between the system and the system, which is an important subject, so that the management of the interaction between the systems becomes the first step and the most core technology.
If the self-defining technology of the flow form can only be used by a self system, the self-defining technology has high limitation, so the self-defining technology is popularized to external system calling, and the external system calling relates to safety problems, data asymmetry problems and the like, so the external data conversion mapping method of the flow form is provided at present.
Disclosure of Invention
Based on the technical problems in the background art, the invention provides a method for converting and mapping external data of a flow sheet.
The invention provides a method for converting and mapping external data of a flow chart, which comprises the following steps:
s1: carrying out basic configuration on the mapping, including basic configuration of a mapping template, a mapping field table, a mapping rule and a dictionary table;
s2: binding a flow ID and a form ID by a mapping table template;
s3: defining an effective receiving method;
s4: checking whether the access source is legal or not, and checking whether the parameters meet the rules and the specifications or not;
s5: mapping a parameter format required by the generated flow instance according to the mapping template table and the mapping field table;
s6: calling a process engine service and a form engine service to generate a process instance;
s7: inquiring a corresponding work order list and work order details according to the type of the work order, and performing mutual data conversion;
s8: and after the data are merged, responding to the access service system.
Preferably, the data transport carrier is a MAP and the varying portions of the data blocks of the data are persisted to a database.
Preferably, the mapping uses native java, SpringMVC and is based on java base, referencing to reflection, generic and inheritance.
Preferably, the work order list and the query work order details corresponding to the query are queried by performing mutual conversion according to four elements of an internal field name, an internal control type, an external field name and an external field type of the mapping template table and the mapping field table.
Preferably, the en-route sources of the transformation data include data of the process instance, details of the form instance, and specific methods of the additional service class.
Preferably, the data format is json format.
Preferably, the mapping template and the mapping field are both configured at the database side.
The beneficial effects of the invention are as follows:
1. the flexibility of creating the flow form by the external system is improved, the implementation time of developers is simplified, the service codes with excessive code layers are optimized, redundant codes are avoided, unified management is achieved, and maintenance cost is reduced.
2. The method greatly standardizes the interaction mode of the external system and the internal system flow form, simultaneously improves the safety and the data effectiveness, and improves the flexibility of system interaction.
3. Under the condition that external data is unstable, interaction is more flexible in a configuration mode, and modification is easy on the premise that service stability is not influenced.
Drawings
FIG. 1 is a schematic diagram illustrating a method for mapping external data conversion of a flow form according to the present invention;
fig. 2 is a flowchart illustrating an operation of the external data conversion mapping method of the flowchart according to the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments.
Referring to fig. 1-2, a method for converting and mapping external data of a flow sheet includes the following steps:
acquiring a user-defined form id and a user-defined flow id according to the name of the work order; setting input and output mapping rules on the basis, and binding a user-defined form and a user-defined flow; setting a dictionary relation table, and taking key and value as conversion bases; calling a method for automatically creating a mapping template and a mapping field table according to the user-defined form data; according to the type of the work order and three parameters of form id and process id, automatically creating three mapping templates which are respectively a query list, a query detail and a work order;
calling a custom form template detailed interface to obtain json format data of a custom form template, after analyzing the json data, binding the relation between a mapping template table and a mapping field table according to a generated template, and automatically generating a control id and an internal control type corresponding to an internal control of the mapping field table;
according to the binding relationship between the mapping template table and the mapping field table, the remaining field information of the mapping field table is automatically generated, wherein the remaining field information comprises basic attributes such as an internal field control id, an internal field type, whether filling and remarking are necessary and the like; the internal field type is multi-selection and single-selection fields, a dictionary relation table is bound, and the internal field type can be automatically converted into code; supplementing the external field and the external field type of the mapping field table according to the parameter name and the parameter type defined by the external interface document; configuring an ip white list and adding access authority control;
testing whether the connection between the external system and the system is normal; the external system calls the system interface to trigger the creation operation; judging whether the format of the parameters transmitted by the external system is correct and whether key parameters are missing; entering a verification method, acquiring a mapping template according to a user-defined work order type, and acquiring a mapping field detail list according to a mapping template id; matching the Map-key and the mapping field table according to the transmitted parameters (formatted as Map) and the transmitted parameters formatted as Map; and (3) checking Map-value after matching: verifying whether the configuration types of the external fields in the mapping field table are matched or not, verifying whether the control types of the internal control fields in the mapping field table are matched with the reflected format or not, verifying whether fields are required to be filled in the mapping field table or not, and executing non-null verification; after the verification is passed, calling a creation work order interface; calling a mapping table template service class, acquiring corresponding mapping template table data according to the work order type, obtaining a mapping field table object array in a linkage manner, and acquiring a control object array of a self-defined form according to the id of the self-defined form bound by the mapping template table;
calling a mapping conversion method, converting an external object into an internal object, circularly customizing a control object array of the form, classifying data, and judging whether the data is sub-form data or not, wherein the sub-form data is divided into sub-form data and common control data; processing common control data, calling a control processing method, and performing mutual conversion according to Map-value and the internal control type of a mapping field table, wherein each control has a corresponding conversion method, and the conversion method is defined according to a rule generated by a user-defined form, circularly self-defining a form control array, reflecting the control type of a control object, matching a corresponding control processing method, and executing the formatting operation of the control;
processing the sub-form data, calling a special control processing method of the sub-form, performing mutual conversion according to the Map-value and the internal control type of the mapping field table, circularly customizing the form control array, reflecting the control type of the control object, matching a corresponding control processing method, and executing the formatting operation of the control; combining the result after the common control is processed with the result of the sub-form control processing to generate a Map for creating a user-defined form; calling and creating a custom form interface after the combined maps to generate a custom form example; updating the source field of the form data table according to the self-defined form example;
after a work order is created, inquiring different work order lists and work order details according to different work order types, after an external system calls an interface, judging whether parameters are correct or not, judging whether the work order type exists in a mapping template or not, calling a process instance service class according to the work order type and a form template id of the mapping template, and acquiring all process instance objects under all the form templates; and the circular process example object array is used as a matching basis according to the rule of the mapping field table, wherein the mapping rule is as follows: the external name Map-value in the Map-key mapping field table is a source, and the value can be automatically assigned only if the keys are the same;
according to data on a process example as mapping data, converting the format of the data into Map as a unified type, according to data of a form data example as the mapping data, converting the format of the data into Map as the unified type, according to different service classes, reflecting and executing a method with a specified name, acquiring the data as a data source as the mapping data, and converting the format of the data into Map as the unified type; after mapping the three data, combining the three data into Map, and adding work order reply content; map is converted to json object and responds to the request.
In the invention, SpringMVC notes acquire the type of a work order, corresponding log records, authority control and the like are uniformly added in an interface, a mapping template and a mapping field function are both configured at a database end, mapping basic information can be modified, external mapping conversion of a process form is carried out, the mapping template and the mapping field function are used as a data transmission bridge of a user-defined form and a user-defined process, check data and standardize a data format, the mapping template and the mapping field function are used as interceptors and filters for creating process examples, data conversion is carried out by matching with the creation requirement of the user-defined form, an external system calls the user-defined work order function of the system according to the data format of each control as a conversion rule, the management function of unified import and export of business services with the same logic can be expanded through a conversion mapping mechanism according to the business type, an agent for the external services, an external data, and carrying out unified management and unified conversion on external data rules. The external mapping conversion of the flow form is used as a data transmission bridge of a user-defined form and a user-defined flow, is also a unique entry for externally creating and inquiring a user-defined work order, adds log management, authority management, verification management and the like, adopts the technology of native java and SpringMVC, refers to the technologies of reflection, generalization, inheritance and the like on the basis of java foundation, constructs a method capable of being shared, takes nodes and contents which are easy to change as basic fields of mapping configuration, configures the basic fields in a mysql database, basically uses a Map mode as a data transmission carrier, meets the requirement of key-value of the Map, finally returns of each interface and is transmitted by the Map as much as possible, uses the reflection and the generalization to extract more common logics into the method, and the changed part of the data block is completely persisted to the database without being solidified in a code layer, so that no front-section code exists, and the configuration is carried out in a mode of expanding and using a page in the future.
The above description is only for the preferred embodiment of the present invention, but the scope of the present invention is not limited thereto, and any person skilled in the art should be considered to be within the technical scope of the present invention, and the technical solutions and the inventive concepts thereof according to the present invention should be equivalent or changed within the scope of the present invention.

Claims (7)

1. A method for converting and mapping external data of a flow form is characterized by comprising the following steps:
s1: carrying out basic configuration on the mapping, including basic configuration of a mapping template, a mapping field table, a mapping rule and a dictionary table;
s2: binding a flow ID and a form ID by a mapping table template;
s3: defining an effective receiving method;
s4: checking whether the access source is legal or not, and checking whether the parameters meet the rules and the specifications or not;
s5: mapping a parameter format required by the generated flow instance according to the mapping template table and the mapping field table;
s6: calling a process engine service and a form engine service to generate a process instance;
s7: inquiring a corresponding work order list and work order details according to the type of the work order, and performing mutual data conversion;
s8: and after the data are merged, responding to the access service system.
2. The method for flow sheet external data transformation mapping of claim 1, wherein the data transmission carrier is MAP, and the changed portions of the data blocks of the data are all persisted to the database.
3. The method for flow form external data conversion mapping of claim 2, wherein the mapping is native java, SpringMVC, and based on java base, referring to reflection, generic and inheritance.
4. The method as claimed in claim 3, wherein the query work order list and the query work order details are obtained by performing a conversion between four elements, i.e. an internal field name, an internal control type, an external field name and an external field type, of the mapping template table and the mapping field table.
5. The method of claim 4, wherein the en-route sources of the transformation data include data of process instances, details of form instances, and specific methods of additional service classes.
6. The method of claim 5, wherein the data format is json format.
7. The method for external data transformation mapping of process form as claimed in claim 6, wherein said mapping template and mapping field are both configured on the database side.
CN201911229759.6A 2019-12-04 2019-12-04 External data conversion mapping method for flow form Pending CN112905183A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911229759.6A CN112905183A (en) 2019-12-04 2019-12-04 External data conversion mapping method for flow form

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911229759.6A CN112905183A (en) 2019-12-04 2019-12-04 External data conversion mapping method for flow form

Publications (1)

Publication Number Publication Date
CN112905183A true CN112905183A (en) 2021-06-04

Family

ID=76111212

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911229759.6A Pending CN112905183A (en) 2019-12-04 2019-12-04 External data conversion mapping method for flow form

Country Status (1)

Country Link
CN (1) CN112905183A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116483841A (en) * 2023-06-25 2023-07-25 北京长亭科技有限公司 Form data management method and device based on compact framework
CN117076544A (en) * 2023-10-13 2023-11-17 腾讯科技(深圳)有限公司 Data conversion service request processing method, system, device and computer equipment
CN117130692A (en) * 2023-10-23 2023-11-28 成都赛力斯科技有限公司 Application management method, device, electronic equipment and storage medium

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7281018B1 (en) * 2004-05-26 2007-10-09 Microsoft Corporation Form template data source change
CN101661512A (en) * 2009-09-25 2010-03-03 万斌 System and method for identifying traditional form information and establishing corresponding Web form
CN101777143A (en) * 2009-12-22 2010-07-14 金蝶软件(中国)有限公司 Method, device and system for business bill conversion
CN103617047A (en) * 2013-12-16 2014-03-05 北京中电普华信息技术有限公司 Method, device and processor for developing business processes
CN105046408A (en) * 2015-06-25 2015-11-11 国网山东省电力公司 Configurable workflow realization method and system
CN105630502A (en) * 2015-12-28 2016-06-01 武汉传神信息技术有限公司 Method and system for generating dynamic form
CN106503217A (en) * 2016-11-03 2017-03-15 用友网络科技股份有限公司 Data interaction device and method based on business-driven
CN110231936A (en) * 2019-06-21 2019-09-13 北京金山软件有限公司 A kind of application method of mobile terminal flow engine frame and mobile terminal flow engine
CN110442340A (en) * 2019-07-04 2019-11-12 重庆金融资产交易所有限责任公司 List generation method, device and computer equipment based on data processing
CN110458430A (en) * 2019-07-29 2019-11-15 武汉宏途科技有限公司 A kind of system and method for realizing dynamic duty stream configuration based on graphical tools

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7281018B1 (en) * 2004-05-26 2007-10-09 Microsoft Corporation Form template data source change
CN101661512A (en) * 2009-09-25 2010-03-03 万斌 System and method for identifying traditional form information and establishing corresponding Web form
CN101777143A (en) * 2009-12-22 2010-07-14 金蝶软件(中国)有限公司 Method, device and system for business bill conversion
CN103617047A (en) * 2013-12-16 2014-03-05 北京中电普华信息技术有限公司 Method, device and processor for developing business processes
CN105046408A (en) * 2015-06-25 2015-11-11 国网山东省电力公司 Configurable workflow realization method and system
CN105630502A (en) * 2015-12-28 2016-06-01 武汉传神信息技术有限公司 Method and system for generating dynamic form
CN106503217A (en) * 2016-11-03 2017-03-15 用友网络科技股份有限公司 Data interaction device and method based on business-driven
CN110231936A (en) * 2019-06-21 2019-09-13 北京金山软件有限公司 A kind of application method of mobile terminal flow engine frame and mobile terminal flow engine
CN110442340A (en) * 2019-07-04 2019-11-12 重庆金融资产交易所有限责任公司 List generation method, device and computer equipment based on data processing
CN110458430A (en) * 2019-07-29 2019-11-15 武汉宏途科技有限公司 A kind of system and method for realizing dynamic duty stream configuration based on graphical tools

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116483841A (en) * 2023-06-25 2023-07-25 北京长亭科技有限公司 Form data management method and device based on compact framework
CN116483841B (en) * 2023-06-25 2023-09-12 北京长亭科技有限公司 Form data management method and device based on compact framework
CN117076544A (en) * 2023-10-13 2023-11-17 腾讯科技(深圳)有限公司 Data conversion service request processing method, system, device and computer equipment
CN117076544B (en) * 2023-10-13 2024-01-26 腾讯科技(深圳)有限公司 Data conversion service request processing method, system, device and computer equipment
CN117130692A (en) * 2023-10-23 2023-11-28 成都赛力斯科技有限公司 Application management method, device, electronic equipment and storage medium
CN117130692B (en) * 2023-10-23 2024-01-23 成都赛力斯科技有限公司 Application management method, device, electronic equipment and storage medium

Similar Documents

Publication Publication Date Title
WO2022160707A1 (en) Human-machine interaction method and apparatus combined with rpa and ai, and storage medium and electronic device
CN112905183A (en) External data conversion mapping method for flow form
US10558434B2 (en) Rule-based automatic class generation from a JSON message
US7516229B2 (en) Method and system for integrating interaction protocols between two entities
US6996589B1 (en) System and method for database conversion
US9690822B2 (en) System and method for metadata level validation of custom setup objects
CN105407024B (en) A kind of isomeric data interoperability methods and device based on distribution subscription communication mechanism
US7461335B2 (en) Dynamic conversion of data into markup language format
US10445675B2 (en) Confirming enforcement of business rules specified in a data access tier of a multi-tier application
US20120158807A1 (en) Matching data based on numeric difference
CN112671734B (en) Message processing method for multiple data sources and related equipment thereof
CN111752542B (en) Database query interface engine based on XML template
CN110674205B (en) Single table query method, device, terminal and readable storage medium
CN111078213B (en) Code generation method and code generation device
CN114510262A (en) Interface request parameter verification method and device
CN101000618A (en) Method and device for set-up disconnection data programmed model and its application
CN112395339B (en) Intersystem data admission verification method, device, computer equipment and storage medium
CN101952805A (en) Nominally related effectively incompatible type
CN103714035B (en) Multilayer software bus structure for integrated environment
JP2009517780A (en) Business transaction representation
CN112445811A (en) Data service method, device, storage medium and component based on SQL configuration
CN105117571A (en) Design and simulation method for ramjet engine and simulation platform data bus
CN111222015A (en) Method for generating document by heterogeneous XML mapping
CN117435177B (en) Application program interface construction method, system, equipment and storage medium
CN111310414B (en) RDF format file analysis method and generation method

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