CN118133794A - Table configuration method, apparatus, device and storage medium - Google Patents

Table configuration method, apparatus, device and storage medium Download PDF

Info

Publication number
CN118133794A
CN118133794A CN202410558125.XA CN202410558125A CN118133794A CN 118133794 A CN118133794 A CN 118133794A CN 202410558125 A CN202410558125 A CN 202410558125A CN 118133794 A CN118133794 A CN 118133794A
Authority
CN
China
Prior art keywords
data
target
configuration
json
determining
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
CN202410558125.XA
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.)
Taiping Finance Technology Services Shanghai Co ltd
Original Assignee
Taiping Finance Technology Services Shanghai 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 Taiping Finance Technology Services Shanghai Co ltd filed Critical Taiping Finance Technology Services Shanghai Co ltd
Priority to CN202410558125.XA priority Critical patent/CN118133794A/en
Publication of CN118133794A publication Critical patent/CN118133794A/en
Pending legal-status Critical Current

Links

Classifications

    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The application discloses a table configuration method, a table configuration device, table configuration equipment and a storage medium, and relates to the technical field of data processing. The method comprises the following steps: analyzing the target table file to obtain target table data; determining a target JSON object according to target table data based on a lightweight data exchange format JSON configuration template; the JSON configuration template is pre-constructed based on the mapping relation between the table and the database field; and determining target configuration data according to the target JSON object and the table configuration scene. According to the technical scheme, the mapping relation between the table and the database field is established by using the JSON, and when the table is configured, only the JSON is required to be configured, so that the configuration efficiency of the table is improved.

Description

Table configuration method, apparatus, device and storage medium
Technical Field
The embodiment of the application relates to the technical field of computers, in particular to the technical field of data processing, and particularly relates to a table configuration method, a device, equipment and a storage medium.
Background
In the field of batch data processing, it is often necessary to process large amounts of data, including user information, recipe execution rules, and the like. With the increase of intelligent network office environment, the scale and complexity of these data are increasing, and the scope is also expanding and increasing.
Currently, when configuring table data, columns of a table need to be mapped to fields in a target system to establish a mapping relationship between column indexes of the table and fields in the target system. Since the mapping method generally adopts column subscripts, when the column order changes, the mapping relationship needs to be manually updated. Under the conditions of large field number and complex mapping, a large amount of time is needed to analyze the mapping relation between the column index of the table and the fields in the target system, so that the table configuration period is longer. And the efficiency is low.
Disclosure of Invention
The application provides a table configuration method, a device, equipment and a storage medium, which are used for improving the configuration efficiency of a table.
According to an aspect of the present application, there is provided a table configuration method, including:
analyzing the target table file to obtain target table data;
Determining a target JSON object according to the target table data based on a lightweight data exchange format JSON configuration template; the JSON configuration template is pre-constructed based on the mapping relation between the table and the database field;
and determining target configuration data according to the target JSON object and the table configuration scene.
According to another aspect of the present application, there is provided a form configuration apparatus including:
the file analysis module is used for analyzing the target form file to obtain target form data;
The data conversion module is used for configuring a template based on a lightweight data exchange format JSON, and determining a target JSON object according to the target table data; the JSON configuration template is pre-constructed based on the mapping relation between the table and the database field;
And the data determining module is used for determining target configuration data according to the target JSON object and the table configuration scene.
According to another aspect of the present application, there is provided an electronic apparatus including:
One or more processors;
A memory for storing one or more programs;
When the one or more programs are executed by the one or more processors, the one or more processors implement any of the table configuration methods provided by the embodiments of the present application.
According to another aspect of the present application, there is provided a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, implements any of the table configuration methods provided by the embodiments of the present application.
Analyzing a target form file to obtain target form data; determining a target JSON object according to target table data based on a lightweight data exchange format JSON configuration template; the JSON configuration template is pre-constructed based on the mapping relation between the table and the database field; and determining target configuration data according to the target JSON object and the table configuration scene. According to the technical scheme, the mapping relation between the table and the database field is established by using the JSON, and when the table is configured, only the JSON is required to be configured, so that the configuration efficiency of the table is improved.
Drawings
FIG. 1 is a flow chart of a table configuration method according to a first embodiment of the present application;
FIG. 2 is a flowchart of a table configuration method according to a second embodiment of the present application;
Fig. 3 is a schematic structural diagram of a table configuration device according to a third embodiment of the present application;
Fig. 4 is a schematic structural diagram of an electronic device implementing a table configuration method according to an embodiment of the present application.
Detailed Description
In order that those skilled in the art will better understand the present application, a technical solution in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in which it is apparent that the described embodiments are only some embodiments of the present application, not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the present application without making any inventive effort, shall fall within the scope of the present application.
It should be noted that the terms "first," "second," and the like in the description and the claims of the present application and the above figures are used for distinguishing between similar objects and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used may be interchanged where appropriate such that the embodiments of the application described herein may be implemented in sequences other than those illustrated or otherwise described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
In addition, in the technical scheme of the application, the related processes of collecting, storing, using, processing, transmitting, providing, disclosing and the like of the target table file, the target table data and the like all accord with the regulations of related laws and regulations, and the public welfare is not violated.
Example 1
Fig. 1 is a flowchart of a table configuration method according to a first embodiment of the present application, where the present embodiment is applicable to a case where excel (Microsoft Office Excel, microsoft office electronic form) table data is imported into or exported from a target system, and the table configuration apparatus may be implemented by a table configuration apparatus, which may be implemented in the form of hardware and/or software, and the table configuration apparatus may be configured in a computer device, for example, a server. As shown in fig. 1, the method includes:
s110, analyzing the target table file to obtain target table data.
The target table file refers to a table file to be configured, and may include at least one of an excel file and a WPS (Kingsoft Office Software, gold mountain office software) table file. The target table data refers to data which is obtained by analyzing each line of data in the target table file and accords with a preset format.
It should be noted that, the preset format of the target table data is set manually according to the actual situation or the experience value; for example, it may be JSONObject (JavaScript Object Notation ) format.
Optionally, analyzing the target table file through a data importing component to obtain candidate table data; performing format verification on the candidate form data to obtain a format verification result; and determining target table data according to the format verification result and the candidate table data.
The data importing component refers to a tool or a module for importing data in an external data source into an application program or a system, and may include at least one of a tp-import-execl component (THIRD PARTY Import Excel Component, a third party Excel importing component), a JDBC (Java Database Connectivity, java database connection) component, and the like; the component can be used to provide a simple and flexible way to parse and process various data identifications, such as Excel, JSON, databases, etc. The candidate table data refers to data obtained by analyzing each line of data in the target table file. The format verification result is a result obtained by verifying the data identifier of the candidate table data and is used for representing whether the data identifier of the candidate table data is loaded with the preset data identifier or not.
Further, according to the format verification result and the candidate table data, determining that the target table data can be the candidate table data if the format verification result is passed; if the format check result is not passed, the target table file is analyzed again.
The preset format of the target table data is JSONObject format; analyzing the target excel data file through the tp-import-execl component to obtain candidate excel data; verifying the data identification of the candidate excel data; if the data identification of the candidate excel data is JSONObject format, taking the candidate excel data as target excel data; and if the data identification of the candidate excel data is not JSONObject format, re-acquiring the target excel data file and analyzing the target exce data file.
S120, determining a target JSON object according to target table data based on a lightweight data exchange format JSON configuration template; wherein, the JSON configuration template is pre-constructed based on the mapping relationship between the table and the database fields.
Wherein the database field refers to a column defined in a database table for storing a specific type of data. The target JSON object refers to target table data expressed in JSON language.
Taking an excel table as an example, configuring a template based on a lightweight data exchange format (JSON), and determining that a target JSON object can be according to target table data, wherein the title of excel in the target table data is used as a key to acquire data corresponding to the title of excel in the target table data; and replacing the value in the JSON with the data corresponding to the title of excel in the target table data, thereby obtaining a target JSON object.
Optionally, after determining the target JSON object according to the target table data, sequentially checking the data identifiers in the target JSON object according to the configuration sequence of the table in the JSON configuration template to obtain a first check result; based on the database field configured in the JSON configuration template, verifying the data value type in the target JSON object to obtain a second verification result; if the first check result is not passed or the second check result is not passed, analyzing the target table file again.
The configuration sequence refers to the sequence of the table titles in the JSON configuration template. The data identification in the object JSON object refers to information for identifying and describing data, and may include at least one of a table title, a column name, and the like. The first verification result is a result obtained by verifying the data identifier and is used for representing that the data identifier in the target JSON object is correct. The data value type refers to a specific data type of a field, is used for defining the type and format of data that the field can contain, and can include at least one of an integer type, a floating point number type, a character string type, and the like. The second checking result is a result obtained by checking the data value type and is used for representing whether the data value type in the target JSON object is correct or not.
Taking an excel table as an example, comparing the titles in the target JSON object one by one based on the sequence of the excel titles in the JSON configuration template to obtain a first verification result; comparing the value type of the database field in the JSON configuration template with the data value type corresponding to the excel title in the target JSON object to obtain a second check result; when the first check result and the second check result are both passed, continuing to execute the next step; and when the first check result and/or the second check result is failed, resolving the target table file again.
It can be understood that by checking the data identifier and the data value type of the target JSON object, the imported target table data can be ensured to meet the requirements more comprehensively, and the accuracy and the integrity of the data can be improved.
S130, determining target configuration data according to the target JSON object and the table configuration scene.
The table configuration scene refers to a specific environment faced by the target system when processing the target configuration data, and may include at least one of data import, data export, data modification and the like. The target configuration data refers to data meeting the requirements of the table configuration scene.
For example, data meeting the requirements of the table configuration scene can be screened out from the target JSON object to serve as target configuration data.
Optionally, after determining the target configuration data according to the target JSON object and the table configuration scene, mapping the target configuration data to a user interface based on the JSON mapping template, and displaying the target configuration data; the JSON mapping template is pre-constructed based on the mapping relation between the user interface and the data object in the target system.
The user interface is an interface for interaction and communication between a person and a computer or other devices, and provides a bridge, so that a user can communicate, operate and control with the computer system in a mode of graphics, sound, touch and the like. The data objects in the target system refer to data objects stored in the database tables.
The JSON mapping template may be a JSON object array template of a front dynamic field, where each object in the JSON object array template corresponds to a field of a page, and correspondingly, the JSON mapping template created based on a mapping relationship between a user interface and a data object in a target system may be that a database table field external key is used as a key (PRIMARY KEY, a key), a database table field is used as a property, a user interface field is used as a Label name, and a supplementary field is used as labelSub (Label Subtitle), so as to obtain the JSON object array template.
The external key of the database table field refers to a field for establishing an association relationship between tables, and is usually a main key pointing to other tables. The database table field refers to a field used in the actual application process for describing and recording the attribute of the service data. User interface fields refer to fields that expose and collect user input on a front-end page. The supplementary field refers to a sub-tag or supplementary information abstracted from the user interface field for enhancing the descriptive capability of the user interface field or presenting more detailed service data.
Further, if the front-end dynamic field is required to be rendered, the target object array can be traversed circularly, and the target data object of the corresponding level is determined according to the key; based on a JSON object array template of the front-end dynamic field, determining a front-end field corresponding to a target data object through prop mapping; and modifying the field of the target data object to determine a target JSON object array.
The target object array refers to a JSON object array stored in the target system. The target data object refers to a data object corresponding to a front-end field that needs to be rendered. Front-end fields refer to fields or attributes used to present, receive user input, or interact with back-end data. The target JSON object array refers to a new object array obtained after the front-end field is rendered.
According to the embodiment of the application, the target table file is analyzed to obtain target table data; determining a target JSON object according to target table data based on a lightweight data exchange format JSON configuration template; the JSON configuration template is pre-constructed based on the mapping relation between the table and the database field; and determining target configuration data according to the target JSON object and the table configuration scene. According to the technical scheme, the mapping relation between the table and the database field is established by using the JSON, and when the table is configured, only the JSON is required to be configured, so that the configuration efficiency of the table is improved.
Example two
Fig. 2 is a flowchart of a table configuration method according to a second embodiment of the present application, where, based on the technical solutions of the foregoing embodiments, the "determining the target configuration data according to the target JSON object and the table configuration scene" refines the target configuration data to "perform a reflection operation on the target JSON object to obtain initial configuration data; the target configuration data is determined according to the table configuration scene and the initial configuration data. It should be noted that, in the embodiments of the present application, parts that are not described in detail may be referred to in the related description of other embodiments. As shown in fig. 2, the method includes:
s210, analyzing the target table file to obtain target table data.
S220, determining a target JSON object according to target table data based on a lightweight data exchange format JSON configuration template; wherein, the JSON configuration template is pre-constructed based on the mapping relationship between the table and the database fields.
Alternatively, the JSON configuration template created based on the mapping relationship between the table and the database field may be that a key in JSON is used as a database field name, a value corresponding to the key is used as a table header, and a target key value pair is obtained and used for representing the mapping relationship between the table and the database field.
The database field names refer to column names defined in a database table, and are used for identifying the name and the data type of each field in the table. Form title refers to a name used to identify the entire worksheet or a single row of data. A key refers to an identification for uniquely identifying one data item. The value refers to the specific data content associated with the key. Key-value pairs are data structures used to represent the mapping relationship between tables and database fields.
Further, if a master-slave relationship exists among the fields in the single-row data of the table, a plurality of JSON configuration templates are created for associating mappings of different levels.
Wherein, the master-slave relationship refers to that one field is the dependence or association of other fields, and concretely refers to the association relationship between the master field and the slave field; the master field contains a unique identifier or key information and the slave field is data for which a corresponding value is determined from the value of the master field.
It can be appreciated that creating multiple JSON configuration templates to represent master-slave relationships in Excel data can better organize and process the data, improving the readability and maintainability of the data.
S230, performing reflection operation on the target JSON object to obtain initial configuration data.
The reflection refers to that the target program dynamically acquires and operates information of elements such as classes, objects, methods, attributes and the like when running. The initial configuration data is obtained by reflection of the target JSON
It can be appreciated that the target JSON obtains initial configuration data through reflection, and a developer can dynamically acquire and process metadata of a program during running, so that code implementation is simplified, and readability and maintainability of the code are improved.
Specifically, based on a preset programming language or programming tool, the target JSON object is subjected to reflection operation, so that initial configuration data is obtained.
Wherein, the preset programming language or programming tool is set manually according to the actual situation or experience value; for example, the preset programming language may be JS (JavaScript, transliterated script) language, and the preset programming tool may be a popular JSON processing library for Java (Java Programming Language ) platform.
S240, determining target configuration data according to the table configuration scene and the initial configuration data.
Optionally, performing logic processing on the initial configuration data according to the table configuration scene to obtain target configuration data; wherein the table configuration scenario includes an import of table data, an export of table data, and a modification of table data.
The data is imported into the target system by importing the target table file into the target system. Export of the form data refers to exporting the target form file from the target system. Modification of the tabular data refers to modification of tabular data in the target system.
In one embodiment, taking an excel table as an example, a table configuration scenario is to configure a drop-down option of the excel table when excel data is exported from a target system; at this time, the initial configuration data is analyzed to obtain keys and values in the initial configuration data; and taking keys in the initial configuration data as values of the pull-down options, and filling the values in the initial configuration data into the hidden pages to obtain the target configuration data.
Wherein, the hidden page refers to a Sheet (Worksheet) page that exists in the workbook but is not displayed on the tab.
Note that when the user opens a workbook containing hidden Sheet pages, the hidden Sheet pages are not seen unless the Sheet pages are selected to be displayed in the workbook.
According to the embodiment of the application, the target table file is analyzed to obtain target table data; determining a target JSON object according to target table data based on a lightweight data exchange format JSON configuration template; the JSON configuration template is pre-constructed based on the mapping relation between the table and the database field; performing reflection operation on the target JSON object to obtain initial configuration data; and determining target configuration data according to the table configuration scene and the initial configuration data. According to the technical scheme, the target configuration data is determined after the reflection operation is carried out on the target JSON object, so that the flexibility and the expandability of the form configuration are improved.
Example III
Fig. 3 is a schematic structural diagram of a table configuration device according to a third embodiment of the present application, which may be suitable for a case of importing excel table data into or exporting excel table data from a target system, and the table configuration device may be implemented in the form of hardware and/or software, and the table configuration device may be configured in a computer device, for example, a server. As shown in fig. 3, the apparatus includes:
the file parsing module 310 is configured to parse the target table file to obtain target table data;
the data conversion module 320 is configured to determine a target JSON object according to the target table data based on the lightweight data exchange format JSON configuration template; the JSON configuration template is pre-constructed based on the mapping relation between the table and the database field;
the data determining module 330 is configured to determine target configuration data according to the target JSON object and the table configuration scene.
According to the embodiment of the application, the target table file is analyzed to obtain target table data; determining a target JSON object according to target table data based on a lightweight data exchange format JSON configuration template; the JSON configuration template is pre-constructed based on the mapping relation between the table and the database field; and determining target configuration data according to the target JSON object and the table configuration scene. According to the technical scheme, the mapping relation between the table and the database field is established by using the JSON, and when the table is configured, only the JSON is required to be configured, so that the configuration efficiency of the table is improved.
Optionally, the data determining module 330 includes:
The data reflection unit is used for carrying out reflection operation on the target JSON object to obtain initial configuration data;
And the configuration data determining unit is used for determining target configuration data according to the table configuration scene and the initial configuration data.
Optionally, the configuration data determining unit is specifically configured to:
According to the table configuration scene, carrying out logic processing on the initial configuration data to obtain target configuration data; wherein the table configuration scenario includes an import of table data, an export of table data, and a modification of table data.
Optionally, the file parsing module 310 includes:
The file analysis unit is used for analyzing the target electronic form file through the data importing component to obtain candidate form data;
the format verification unit is used for performing format verification on the candidate form data to obtain a format verification result;
And the table data determining unit is used for determining target table data according to the format check result and the candidate table data.
Optionally, the table data determining unit is specifically configured to:
if the format check result is passed, determining the candidate form data as target form data;
if the format check result is not passed, the target table file is analyzed again.
Optionally, the apparatus further comprises:
The data verification module is used for sequentially verifying the data identifiers in the target JSON object according to the configuration sequence of the table in the JSON configuration template to obtain a first verification result; based on the database field configured in the JSON configuration template, verifying the data value type in the target JSON object to obtain a second verification result; if the first check result is not passed or the second check result is not passed, analyzing the target table file again.
Optionally, the apparatus further comprises:
The data mapping module is used for mapping the target configuration data to the user interface based on the JSON mapping template and displaying the target configuration data; the JSON mapping template is pre-constructed based on the mapping relation between the user interface and the data object in the target system.
The form configuration device provided by the embodiment of the application can execute the form configuration method provided by any embodiment of the application, and has the corresponding functional modules and beneficial effects of executing the form configuration methods.
Example IV
Fig. 4 is a schematic structural diagram of an electronic device 410 implementing a table configuration method according to an embodiment of the present application. Electronic devices are intended to represent various forms of digital computers, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other appropriate computers. Electronic equipment may also represent various forms of mobile devices, such as personal digital processing, cellular telephones, smartphones, wearable devices (e.g., helmets, glasses, watches, etc.), and other similar computing devices. The components shown herein, their connections and relationships, and their functions, are meant to be exemplary only, and are not meant to limit implementations of the applications described and/or claimed herein.
As shown in fig. 4, the electronic device 410 includes at least one processor 411, and a memory, such as a Read Only Memory (ROM) 412, a Random Access Memory (RAM) 413, etc., communicatively connected to the at least one processor 411, wherein the memory stores computer programs executable by the at least one processor, and the processor 411 may perform various suitable actions and processes according to the computer programs stored in the Read Only Memory (ROM) 412 or the computer programs loaded from the storage unit 418 into the Random Access Memory (RAM) 413. In the RAM413, various programs and data required for the operation of the electronic device 410 may also be stored. The processor 411, the ROM412, and the RAM413 are connected to each other through a bus 414. An input/output (I/O) interface 415 is also connected to bus 414.
Various components in the electronic device 410 are connected to the I/O interface 415, including: an input unit 416 such as a keyboard, a mouse, etc.; an output unit 417 such as various types of displays, speakers, and the like; a storage unit 418, such as a magnetic disk, optical disk, or the like; and a communication unit 419 such as a network card, modem, wireless communication transceiver, etc. The communication unit 419 allows the electronic device 410 to exchange information/data with other devices through a computer network such as the internet and/or various telecommunication networks.
The processor 411 may be a variety of general and/or special purpose processing components having processing and computing capabilities. Some examples of processor 411 include, but are not limited to, a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), various specialized Artificial Intelligence (AI) computing chips, various processors running machine learning model algorithms, digital Signal Processors (DSPs), and any suitable processor, controller, microcontroller, etc. The processor 411 performs the various methods and processes described above, such as a table configuration method.
In some embodiments, the table configuration method may be implemented as a computer program tangibly embodied on a computer-readable storage medium, such as storage unit 418. In some embodiments, some or all of the computer program may be loaded and/or installed onto the electronic device 410 via the ROM412 and/or the communication unit 419. When the computer program is loaded into RAM413 and executed by processor 411, one or more steps of the table configuration method described above may be performed. Alternatively, in other embodiments, processor 411 may be configured as a table configuration method by any other suitable means (e.g., by means of firmware).
Various implementations of the systems and techniques described here above may be implemented in digital electronic circuitry, integrated circuit systems, field Programmable Gate Arrays (FPGAs), application Specific Integrated Circuits (ASICs), application Specific Standard Products (ASSPs), systems On Chip (SOCs), load programmable logic devices (CPLDs), computer hardware, firmware, software, and/or combinations thereof. These various embodiments may include: implemented in one or more computer programs, the one or more computer programs may be executed and/or interpreted on a programmable system including at least one programmable processor, which may be a special purpose or general-purpose programmable processor, that may receive data and instructions from, and transmit data and instructions to, a storage system, at least one input device, and at least one output device.
A computer program for carrying out methods of the present application may be written in any combination of one or more programming languages. These computer programs may be provided to a processor of a general purpose computer, special purpose computer, or other programmable table configuration device such that the computer programs, when executed by the processor, cause the functions/operations specified in the flowchart and/or block diagram block or blocks to be implemented. The computer program may execute entirely on the machine, partly on the machine, as a stand-alone software package, partly on the machine and partly on a remote machine or entirely on the remote machine or server.
In the context of the present application, a computer-readable storage medium may be a tangible medium that can contain, or store a computer program for use by or in connection with an instruction execution system, apparatus, or device. The computer readable storage medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. Alternatively, the computer readable storage medium may be a machine readable signal medium. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
To provide for interaction with a user, the systems and techniques described here can be implemented on an electronic device having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to a user; and a keyboard and a pointing device (e.g., a mouse or a trackball) through which a user can provide input to the electronic device. Other kinds of devices may also be used to provide for interaction with a user; for example, feedback provided to the user may be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form, including acoustic input, speech input, or tactile input.
The systems and techniques described here can be implemented in a computing system that includes a background component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front-end component (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such background, middleware, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: local Area Networks (LANs), wide Area Networks (WANs), blockchain networks, and the internet.
The computing system may include clients and servers. The client and server are typically remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other. The server can be a cloud server, also called a cloud computing server or a cloud host, and is a host product in a cloud computing service system, so that the defects of high management difficulty and weak service expansibility in the traditional physical hosts and VPS service are overcome.
It should be appreciated that various forms of the flows shown above may be used to reorder, add, or delete steps. For example, the steps described in the present application may be performed in parallel, sequentially, or in a different order, so long as the desired results of the technical solution of the present application are achieved, and the present application is not limited herein.
The above embodiments do not limit the scope of the present application. It will be apparent to those skilled in the art that various modifications, combinations, sub-combinations and alternatives are possible, depending on design requirements and other factors. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present application should be included in the scope of the present application.

Claims (9)

1. A form configuration method, comprising:
analyzing the target table file to obtain target table data;
Determining a target JSON object according to the target table data based on a lightweight data exchange format JSON configuration template; the JSON configuration template is pre-constructed based on the mapping relation between the table and the database field;
performing reflection operation on the target JSON object to obtain initial configuration data;
determining target configuration data according to a table configuration scene and the initial configuration data; wherein the table configuration scene comprises the importing of table data, the exporting of table data and the modification of table data.
2. The method of claim 1, wherein said determining target configuration data from a table configuration scenario and said initial configuration data comprises:
And carrying out logic processing on the initial configuration data according to the table configuration scene to obtain target configuration data.
3. The method of claim 1, wherein parsing the target spreadsheet file to obtain target spreadsheet data comprises:
analyzing the target table file through a data importing component to obtain candidate table data;
performing format verification on the candidate form data to obtain a format verification result;
and determining target table data according to the format verification result and the candidate table data.
4. The method of claim 3, wherein said determining target table data based on said format verification result and said candidate table data comprises:
if the format check result is passed, determining the candidate form data as target form data;
if the format check result is not passed, the target table file is analyzed again.
5. The method of claim 1, further comprising, after determining a target JSON object from the target table data:
sequentially checking the data identifiers in the target JSON object according to the configuration sequence of the table in the JSON configuration template to obtain a first check result;
Based on the database field configured in the JSON configuration template, verifying the data value type in the target JSON object to obtain a second verification result;
and if the first check result is not passed or the second check result is not passed, analyzing the target table file again.
6. The method of claim 1, further comprising, after determining target configuration data from the target JSON object and form configuration scenario:
Mapping the target configuration data to a user interface based on a JSON mapping template, and displaying the target configuration data; the JSON mapping template is pre-constructed based on the mapping relation between the user interface and the data object in the target system.
7. A form configuration apparatus, comprising:
the file analysis module is used for analyzing the target form file to obtain target form data;
The data conversion module is used for configuring a template based on a lightweight data exchange format JSON, and determining a target JSON object according to the target table data; the JSON configuration template is pre-constructed based on the mapping relation between the table and the database field;
The data determining module is used for determining target configuration data according to the target JSON object and the table configuration scene;
wherein the data determination module comprises:
The data reflection unit is used for carrying out reflection operation on the target JSON object to obtain initial configuration data;
A configuration data determining unit, configured to determine target configuration data according to the table configuration scene and the initial configuration data; the table configuration scenario includes an import of table data, an export of table data, and a modification of table data.
8. An electronic device, comprising:
One or more processors;
A memory for storing one or more programs;
when executed by the one or more processors, causes the one or more processors to implement the table configuration method of any of claims 1-6.
9. A computer readable storage medium, on which a computer program is stored, characterized in that the program, when being executed by a processor, implements a table configuration method as claimed in any one of claims 1-6.
CN202410558125.XA 2024-05-08 2024-05-08 Table configuration method, apparatus, device and storage medium Pending CN118133794A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202410558125.XA CN118133794A (en) 2024-05-08 2024-05-08 Table configuration method, apparatus, device and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202410558125.XA CN118133794A (en) 2024-05-08 2024-05-08 Table configuration method, apparatus, device and storage medium

Publications (1)

Publication Number Publication Date
CN118133794A true CN118133794A (en) 2024-06-04

Family

ID=91240857

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202410558125.XA Pending CN118133794A (en) 2024-05-08 2024-05-08 Table configuration method, apparatus, device and storage medium

Country Status (1)

Country Link
CN (1) CN118133794A (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116028022A (en) * 2023-01-09 2023-04-28 广东云智安信科技有限公司 Java technology-based zero code Excel data importing method, device and medium
CN117608569A (en) * 2023-10-20 2024-02-27 河南翔宇医疗设备股份有限公司 Table form rendering method, system and storage medium
CN117609347A (en) * 2023-11-21 2024-02-27 深圳图为技术有限公司 Data importing method, device and equipment based on verification and correction

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116028022A (en) * 2023-01-09 2023-04-28 广东云智安信科技有限公司 Java technology-based zero code Excel data importing method, device and medium
CN117608569A (en) * 2023-10-20 2024-02-27 河南翔宇医疗设备股份有限公司 Table form rendering method, system and storage medium
CN117609347A (en) * 2023-11-21 2024-02-27 深圳图为技术有限公司 Data importing method, device and equipment based on verification and correction

Similar Documents

Publication Publication Date Title
CN115061721A (en) Report generation method and device, computer equipment and storage medium
CN113836314B (en) Knowledge graph construction method, device, equipment and storage medium
US20230134615A1 (en) Method of processing task, electronic device, and storage medium
CN113626223A (en) Interface calling method and device
CN114925143A (en) Method, device, equipment, medium and product for describing logical model blood relationship
CN115617888A (en) Data import method, device, equipment, storage medium and product
CN116089258A (en) Data migration test method, device, equipment, storage medium and program product
CN114816578A (en) Method, device and equipment for generating program configuration file based on configuration table
EP4246365A1 (en) Webpage identification method and apparatus, electronic device, and medium
CN116303013A (en) Source code analysis method, device, electronic equipment and storage medium
US20220129418A1 (en) Method for determining blood relationship of data, electronic device and storage medium
CN116414814A (en) Data checking method, device, equipment, storage medium and program product
CN115934550A (en) Test method, test device, electronic equipment and storage medium
CN113642295B (en) Page typesetting method, device and computer program product
CN115577689A (en) Table component generation method, device, equipment and medium
CN115454971A (en) Data migration method and device, electronic equipment and storage medium
CN115408111A (en) Database script control method, system, device, storage medium and program product
CN118133794A (en) Table configuration method, apparatus, device and storage medium
CN115458103B (en) Medical data processing method, medical data processing device, electronic equipment and readable storage medium
CN113254826B (en) Dump file processing method and device
CN116755684B (en) OAS Schema generation method, device, equipment and medium
CN117742686A (en) Program source code file generation method and device, electronic equipment and storage medium
CN116842926A (en) Template generation method and device, electronic equipment and storage medium
CN115495368A (en) Data testing method and device and electronic equipment
CN116841982A (en) Database migration method, device, equipment, storage medium and program product

Legal Events

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