CN115146202A - Page form generation method and device - Google Patents

Page form generation method and device Download PDF

Info

Publication number
CN115146202A
CN115146202A CN202210777563.6A CN202210777563A CN115146202A CN 115146202 A CN115146202 A CN 115146202A CN 202210777563 A CN202210777563 A CN 202210777563A CN 115146202 A CN115146202 A CN 115146202A
Authority
CN
China
Prior art keywords
page
function
platform
configuration information
faas
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
CN202210777563.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.)
Beijing Jingdong Century Trading Co Ltd
Beijing Wodong Tianjun Information Technology Co Ltd
Original Assignee
Beijing Jingdong Century Trading Co Ltd
Beijing Wodong Tianjun 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 Jingdong Century Trading Co Ltd, Beijing Wodong Tianjun Information Technology Co Ltd filed Critical Beijing Jingdong Century Trading Co Ltd
Priority to CN202210777563.6A priority Critical patent/CN115146202A/en
Publication of CN115146202A publication Critical patent/CN115146202A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/958Organisation or management of web site content, e.g. publishing, maintaining pages or automatic linking
    • G06F16/986Document structures and storage, e.g. HTML extensions
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/10Text processing
    • G06F40/166Editing, e.g. inserting or deleting
    • G06F40/177Editing, e.g. inserting or deleting of tables; using ruled lines
    • G06F40/18Editing, e.g. inserting or deleting of tables; using ruled lines of spreadsheets
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/20Natural language analysis
    • G06F40/205Parsing

Abstract

The invention discloses a page form generation method and device, and relates to the technical field of computers. One embodiment of the method comprises: receiving a page form generation request, and generating a form number when the page form generation request does not include user form configuration information; the page form generation request comprises a form type; acquiring platform form configuration information from the FaaS function platform according to the form number and the form type; and analyzing the platform form configuration information, and rendering the analysis processing result to obtain the page form. The method and the device improve the generation efficiency of the page form, reduce the consumed development cost, expand the application scenes of the page form generation method and improve the user experience.

Description

Page form generation method and device
Technical Field
The invention relates to the technical field of computers, in particular to a method and a device for generating a page form.
Background
The Form at the front end can solve the problems of data acquisition, data verification and data assignment. The form components of the background in the prior art not only have an input (input frame component) and a select (multi-selection drop-down frame component), but also have components such as a range selector and a date selector, and the components are packaged on the native components in a multi-layer mode, so that more elegant UI (User Interface) and more complex interaction can be realized.
However, since the form involves complex scenes such as linkage, verification and layout, how to quickly and dynamically generate the page form meeting the user requirements is a technical problem that developers need to solve urgently.
The prior art has at least the following problems:
the existing method usually adopts a form code compiling or configuration file compiling mode to generate the page form, and has the technical problems of high consumption and development cost, low generation efficiency of the page form, narrow applicable scene of the page form generation method and poor user experience.
Disclosure of Invention
In view of this, embodiments of the present invention provide a method and an apparatus for generating a page form, which can combine with a FaaS function platform to dynamically generate form configuration information, and further render and generate a page form, so as to improve the generation efficiency of the page form, reduce the development cost consumed, expand the application scenarios of the page form generation method, and improve the user experience.
In order to achieve the above object, according to an aspect of the embodiments of the present invention, there is provided a page form generating method, including:
receiving a page form generation request, and generating a form number when the page form generation request does not include user form configuration information; the page form generation request comprises a form type;
acquiring platform form configuration information from the FaaS function platform according to the form number and the form type;
and analyzing the platform form configuration information, and rendering the analysis processing result to obtain the page form.
Further, before the step of obtaining the platform form configuration information from the FaaS function platform, the method further includes:
establishing a form submission function by using a FaaS function platform, and configuring a parameter field corresponding to the form submission function; establishing a form query function by using a FaaS function platform, and configuring simulation data corresponding to the parameter field in the form query function;
and receiving the interface parameters of the form submission function and the interface parameters of the form query function, which are sent by the FaaS function platform.
Further, the step of acquiring platform form configuration information from the FaaS function platform according to the form number and the form type includes:
determining a target form submission function and a target form query function according to the form number and the form type;
acquiring platform form configuration information from a FaaS function platform according to a target form submission function, a target form query function, a form submission function interface parameter and a form query function interface parameter; the platform form configuration information comprises target parameter fields and target simulation data corresponding to the target parameter fields.
Further, the steps of analyzing the platform form configuration information and rendering the analysis processing result to obtain the page form include:
analyzing the target parameter field and the target simulation data in the platform form configuration information, and rendering the analysis processing result to obtain a page form; and the analysis result indicates the form component type corresponding to the target simulation data.
Further, the user form configuration information includes form component types and form data within each form component; after the step of receiving the page form generation request, if it is determined that the page form generation request includes the user form configuration information, the method further includes:
and rendering the configuration information of the user form to obtain a page form.
Further, the method further comprises:
and receiving the configuration updating information of the user form, and updating the page form according to the configuration updating information of the user form.
According to another aspect of the embodiments of the present invention, there is provided a page form generating apparatus, including:
the receiving module is used for receiving the page form generation request and generating a form number when the page form generation request does not comprise user form configuration information; the page form generation request comprises a form type;
the acquisition module is used for acquiring platform form configuration information from the FaaS function platform according to the form number and the form type;
and the page generation module is used for analyzing the platform form configuration information and rendering the analysis processing result to obtain the page form.
Further, the method further comprises a function building module, before the step of obtaining the platform form configuration information from the FaaS function platform, the function building module is used for:
establishing a form submission function by using a FaaS function platform, and configuring parameter fields corresponding to the form submission function; establishing a form query function by using a FaaS function platform, and configuring analog data corresponding to the parameter fields in the form query function;
and receiving the interface parameters of the form submission function and the interface parameters of the form query function, which are sent by the FaaS function platform.
According to another aspect of the embodiments of the present invention, there is provided an electronic device for generating a page form, including:
one or more processors;
a storage device for storing one or more programs,
when executed by one or more processors, cause the one or more processors to implement any of the page form generation methods described above.
According to a further aspect of the embodiments of the present invention, there is provided a computer-readable medium on which a computer program is stored, the program, when executed by a processor, implementing any one of the above-described page form generation methods.
One embodiment of the above invention has the following advantages or benefits: because the method receives the page form generation request, and generates the form number when the page form generation request does not comprise the user form configuration information; the page form generation request comprises a form type; acquiring platform form configuration information from the FaaS function platform according to the form number and the form type; the technical means of analyzing the platform form configuration information and rendering the analysis processing result to obtain the page form is adopted, so that the technical problems that the page form is generated by adopting a form code compiling or configuration file compiling mode in the existing method, the consumption development cost is high, the generation efficiency of the page form is low, the application scene of the page form generation method is narrow, and the user experience is poor are solved, the form configuration information can be dynamically generated by combining a FaaS function platform, the page form is rendered and generated, the generation efficiency of the page form is improved, the consumed development cost is reduced, the application scene of the page form generation method is expanded, and the technical effect of the user experience is improved.
Further effects of the above-mentioned non-conventional alternatives will be described below in connection with the embodiments.
Drawings
The drawings are included to provide a better understanding of the invention and are not to be construed as unduly limiting the invention. Wherein:
fig. 1 is a schematic diagram of a main flow of a page form generation method according to an embodiment of the present invention;
fig. 2a is a schematic diagram of a main flow of a page form generation method according to another embodiment of the present invention;
FIG. 2b is a diagram illustrating a data value resolution rule of FIG. 2 a;
FIG. 3 is a schematic diagram of the main modules of the page form generation apparatus provided in the embodiment of the present invention;
FIG. 4 is an exemplary system architecture diagram in which embodiments of the present invention may be employed;
fig. 5 is a schematic block diagram of a computer system suitable for use in implementing a terminal device or server of an embodiment of the invention.
Detailed Description
Exemplary embodiments of the present invention are described below with reference to the accompanying drawings, in which various details of embodiments of the invention are included to assist understanding, and which are to be considered as merely exemplary. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the invention. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
Fig. 1 is a schematic diagram of a main flow of a page form generation method according to an embodiment of the present invention; as shown in fig. 1, the method for generating a page form provided by the embodiment of the present invention mainly includes:
step S101, receiving a page form generation request, and generating a form number when determining that the page form generation request does not include user form configuration information; the page form generation request comprises a form type.
Specifically, according to the embodiment of the present invention, after receiving a page form generation request, it is first determined whether the page form generation request includes user form configuration information, and since the user form configuration information includes a form component type indicated by a user and form data in each form component, the user form configuration information can be directly rendered to generate a corresponding page form. If the user form configuration information does not exist, a FaaS Function needs to be associated subsequently, platform form configuration information is acquired from a FaaS (Function as a service) Function platform, and then a page form is generated. The embodiment of the invention provides two page form generation methods, one is that a user transmits full data (user form configuration information) by himself when initiating a page form generation request, and the other is that a page form is dynamically generated by combining a FaaS platform.
According to a specific implementation manner of the embodiment of the invention, a unique form number is generated according to a received page form generation request, so that a FaaS function is subsequently associated according to the form number and a form type in the page form generation request, and further, corresponding platform form configuration information is acquired from the FaaS function to generate a page form.
And S102, acquiring platform form configuration information from the FaaS function platform according to the form number and the form type.
Specifically, according to the embodiment of the present invention, the step of acquiring platform form configuration information from the FaaS function platform according to the form number and the form type includes:
determining a target form submission function and a target form query function according to the form number and the form type;
acquiring platform form configuration information from a FaaS function platform according to a target form submission function, a target form query function, form submission function interface parameters and form query function interface parameters; the platform form configuration information comprises target parameter fields and target simulation data corresponding to the target parameter fields.
According to the embodiment of the invention, aiming at each form number, a corresponding FaaS function (a target form submission function and a target form query function) can be determined according to the corresponding form type, and then platform form configuration information is obtained from a FaaS function platform through the interface parameters of the form submission function and the interface parameters of the form query function. Through the arrangement, the technical problem that the cost for generating the page form is high due to the fact that the form code is compiled is solved, the efficiency, the accuracy and the matching degree (the matching degree of the generated page form and the user requirement) for obtaining the form configuration information are improved, and the user experience is improved.
Further, according to the embodiment of the present invention, before the step of obtaining the platform form configuration information from the FaaS function platform, the method further includes:
establishing a form submission function by using a FaaS function platform, and configuring a parameter field corresponding to the form submission function; establishing a form query function by using a FaaS function platform, and configuring simulation data corresponding to the parameter field in the form query function;
and receiving the interface parameters of the form submission function and the interface parameters of the form query function, which are sent by the FaaS function platform.
Specifically, according to the embodiment of the present invention, faaS functions (form submission functions and form query functions) can be respectively created on a FaaS function platform for a plurality of different form types, so as to meet the diversity requirements of users.
And step S103, analyzing the platform form configuration information, and rendering the analysis result to obtain a page form.
Specifically, according to the embodiment of the present invention, the step of analyzing the platform form configuration information and rendering the analysis result to obtain the page form includes:
analyzing the target parameter field and the target simulation data in the platform form configuration information, and rendering the analysis processing result to obtain a page form; and the analysis result indicates the form component type corresponding to the target simulation data.
Illustratively, because the platform form configuration information acquired from the FaaS function platform includes the target parameter field and the target simulation data corresponding to the target parameter field, and the form component type corresponding to the target simulation data is not limited, the target parameter field and the target simulation data in the platform form configuration file can be analyzed according to the value analysis rule, the corresponding form component type is determined according to the data value type of the target simulation data, and then the page form is obtained through rendering.
Further, according to the embodiment of the present invention, the user form configuration information includes a form component type and form data in each form component; after the step of receiving the page form generation request, if it is determined that the page form generation request includes the user form configuration information, the method further includes:
and rendering the configuration information of the user form to obtain a page form.
Because the form component types and the form data in each form component are directly transmitted in the user form configuration information, the user form configuration information can be directly rendered to obtain the page form, and the generation efficiency of the page form is further improved.
Preferably, according to an embodiment of the present invention, the method further includes:
and receiving the configuration updating information of the user form, and updating the page form according to the configuration updating information of the user form.
Through the arrangement, the method and the device also support the page form updating function, can directly perform adaptive updating on the generated page form according to the user form configuration updating information sent by the user, and further improve the user experience.
According to the technical scheme of the embodiment of the invention, because the received page form generation request is adopted, when the page form generation request does not include the user form configuration information, the form number is generated; the page form generation request comprises a form type; acquiring platform form configuration information from a FaaS function platform according to the form number and the form type; the technical means of analyzing the platform form configuration information and rendering the analysis processing result to obtain the page form is adopted, so that the technical problems that the page form is generated by adopting a form code compiling or configuration file compiling mode in the existing method, the consumption development cost is high, the generation efficiency of the page form is low, the application scene of the page form generation method is narrow, and the user experience is poor are solved, the form configuration information can be dynamically generated by combining a FaaS function platform, the page form is rendered and generated, the generation efficiency of the page form is improved, the consumed development cost is reduced, the application scene of the page form generation method is expanded, and the technical effect of the user experience is improved.
Fig. 2a is a schematic diagram of a main flow of a page form generation method according to another embodiment of the present invention; as shown in fig. 2a, the method for generating a page form according to the embodiment of the present invention mainly includes:
step S201, a form submission function is created by using a FaaS function platform, and a parameter field corresponding to the form submission function is configured; and establishing a form query function by using the FaaS function platform, and configuring simulation data corresponding to the parameter fields in the form query function.
Specifically, according to the embodiment of the present invention, faaS functions (form submission functions and form query functions) can be respectively created on a FaaS function platform for a plurality of different form types, so as to meet the diversity requirements of users.
According to a specific embodiment of the invention, a form submission function is created on a FaaS function platform, and parameter fields such as a name (name) field and an age (age) field can be configured; then, a form query function is created on the FaaS function platform, and the configuration parameters of the form query function are as follows:
Name:string
Age:number
then, configuring simulation data for the data type corresponding to the parameter field, for example:
name: 'Zhang three'
Age:‘18’
And meanwhile, determining form submission function interface information and form query function interface information.
Step S202, receiving the interface parameters of the form submission function and the interface parameters of the form query function sent by the FaaS function platform.
Through the setting, after a page form generation request is subsequently received and is associated to the FaaS function according to the form number and the form type, the function interface parameters and the form query function interface parameters can be submitted according to the form, corresponding platform form configuration information is obtained from the FaaS function platform, and then the page form is generated.
Step S203, receiving a page form generation request and generating a form number.
According to a specific implementation manner of the embodiment of the invention, a unique form number is generated according to a received page form generation request, so that a FaaS function is subsequently associated according to the form number and a form type in the page form generation request, and further, corresponding platform form configuration information is acquired from the FaaS function to generate a page form.
Step S204, judging whether the page form generation request includes the user form configuration information. If not, the page form generation request does not include the user form configuration information, and step S205 is executed; if yes, that is, the page form generation request includes the user form configuration information, step S208 is executed.
Specifically, according to the embodiment of the present invention, after receiving a page form generation request, it is first determined whether the page form generation request includes user form configuration information, and since the user form configuration information includes a form component type indicated by a user and form data in each form component, the user form configuration information can be directly rendered to generate a corresponding page form. If the user form configuration information does not exist, a FaaS Function needs to be associated subsequently, platform form configuration information is acquired from a FaaS (Function as a service) Function platform, and then a page form is generated. The embodiment of the invention provides two page form generation methods, one is that a user transmits full data (user form configuration information) by himself when initiating a page form generation request, and the other is that a page form is dynamically generated by combining a FaaS platform.
Step S205, according to the form number and the form type, determining a target form submission function and a target form query function.
According to the embodiment of the present invention, for each form number, a corresponding FaaS function (a target form submission function and a target form query function) can be determined according to the form type corresponding to the form number, and then, according to the embodiment of the present invention, a corresponding FaaS function (a target form submission function and a target form query function) can be subsequently determined for each form number according to the form type corresponding to the form number.
Step S206, acquiring platform form configuration information from the FaaS function platform according to the target form submission function, the target form query function, the form submission function interface parameter and the form query function interface parameter; the platform form configuration information comprises target parameter fields and target simulation data corresponding to the target parameter fields.
Through the arrangement, the technical problem that the cost for generating the page form is high due to the fact that the form code is compiled is solved, the efficiency, the accuracy and the matching degree (the matching degree of the generated page form and the user requirement) for obtaining the form configuration information are improved, and the user experience is improved.
And step S207, analyzing the target parameter field and the target simulation data in the platform form configuration information, and rendering the analysis result to obtain the page form.
Illustratively, because the platform form configuration information acquired from the FaaS function platform includes the target parameter field and the target simulation data corresponding to the target parameter field, and the form component type corresponding to the target simulation data is not limited, the target parameter field and the target simulation data in the platform form configuration file can be analyzed according to the value analysis rule, the corresponding form component type is determined according to the data value type of the target simulation data, and then the page form is obtained through rendering.
According to a specific implementation manner of the embodiment of the present invention, a value parsing rule (mockdata parsing) is adopted for the platform form configuration information, and a data value type "string" is taken as an example. As shown in fig. 2b, performing regular matching on string-type simulation data, and if a matching result matches a date, determining that the form component type corresponding to the part of simulation data is a date selector; if the matching result shows that the data is long, determining a multi-line text frame table single component; and if the matching result shows that the data is short, determining a single-line text box. The criterion for which more or less data is determined by the amount of data that can be accommodated by a single line of text boxes.
And S208, rendering the configuration information of the user form to obtain a page form.
Because the form component types and the form data in each form component are directly transmitted in the user form configuration information, the user form configuration information can be directly rendered to obtain the page form, and the generation efficiency of the page form is further improved.
Further, according to an embodiment of the present invention, the method further includes:
and receiving the configuration updating information of the user form, and updating the page form according to the configuration updating information of the user form.
Through the arrangement, the method and the device also support the page form updating function, can directly perform adaptive updating on the generated page form according to the user form configuration updating information sent by the user, and further improve the user experience.
Illustratively, according to the embodiment of the present invention, the rendering operation may be implemented by a form rendering engine (clip-form), and may also be implemented by using any scheme that configures a form in json.
According to the technical scheme of the embodiment of the invention, because the received page form generation request is adopted, when the page form generation request does not include the user form configuration information, the form number is generated; the page form generation request comprises a form type; acquiring platform form configuration information from the FaaS function platform according to the form number and the form type; the technical means of analyzing the platform form configuration information and rendering the analysis processing result to obtain the page form overcome the technical problems that the page form is generated by adopting a form code compiling or configuration file compiling mode in the existing method, the consumption development cost is high, the generation efficiency of the page form is low, the application scene of the page form generation method is narrow, and the user experience is poor, and further the purposes of combining a FaaS function platform, dynamically generating the form configuration information, further rendering and generating the page form, improving the generation efficiency of the page form, reducing the consumed development cost, expanding the application scene of the page form generation method, and improving the technical effect of the user experience are achieved.
FIG. 3 is a schematic diagram of the main modules of the page form generation apparatus provided in the embodiment of the present invention; as shown in fig. 3, the page form generating apparatus 300 provided in the embodiment of the present invention mainly includes:
the receiving module 301 is configured to receive a page form generation request, and generate a form number when it is determined that the page form generation request does not include user form configuration information; the page form generation request comprises a form type.
Specifically, according to the embodiment of the present invention, after receiving a page form generation request, it is first determined whether the page form generation request includes user form configuration information. And if the user form configuration information does not exist, associating the FaaS function subsequently, acquiring platform form configuration information from the FaaS function platform, and further generating a page form. Through the setting, the page form generation efficiency is improved, the application scenes of the page form single method are expanded, and the user experience is improved.
According to a specific implementation manner of the embodiment of the invention, a unique form number is generated according to a received page form generation request, so that a FaaS function is subsequently associated according to the form number and a form type in the page form generation request, and further, corresponding platform form configuration information is acquired from the FaaS function to generate a page form.
The obtaining module 302 is configured to obtain platform form configuration information from the FaaS function platform according to the form number and the form type.
Specifically, according to an embodiment of the present invention, the obtaining module 302 is further configured to:
determining a target form submission function and a target form query function according to the form number and the form type;
acquiring platform form configuration information from a FaaS function platform according to a target form submission function, a target form query function, form submission function interface parameters and form query function interface parameters; the platform form configuration information comprises target parameter fields and target simulation data corresponding to the target parameter fields.
According to the embodiment of the invention, aiming at each form number, a corresponding FaaS function (a target form submission function and a target form query function) can be determined according to the corresponding form type, and then platform form configuration information is obtained from a FaaS function platform through the interface parameters of the form submission function and the interface parameters of the form query function. Through the setting, the technical problem that the cost for generating the page form is high due to the fact that the form code is compiled is avoided, the efficiency, the accuracy and the matching degree (the matching degree of the generated page form and the user requirement) for obtaining the form configuration information are improved, and the user experience is improved.
Further, according to the embodiment of the present invention, the page form generating apparatus 300 further includes a function creating module, before the step of obtaining the platform form configuration information from the FaaS function platform, the function creating module is configured to:
establishing a form submission function by using a FaaS function platform, and configuring a parameter field corresponding to the form submission function; establishing a form query function by using a FaaS function platform, and configuring simulation data corresponding to the parameter field in the form query function;
and receiving form submission function interface parameters and form query function interface parameters sent by the FaaS function platform.
Specifically, according to the embodiment of the present invention, faaS functions (form submission functions and form query functions) can be respectively created on a FaaS function platform for a plurality of different form types, so as to meet the diversity requirements of users.
And the page generation module 303 is configured to analyze the platform form configuration information, and render an analysis result to obtain a page form.
Specifically, according to the embodiment of the present invention, the page generating module 303 is further configured to:
analyzing the target parameter field and the target simulation data in the platform form configuration information, and rendering the analysis processing result to obtain a page form; and the analysis result indicates the form component type corresponding to the target simulation data.
Exemplarily, because the platform form configuration information acquired from the FaaS function platform includes the target parameter field and the target simulation data corresponding to the target parameter field, and the form component type corresponding to the target simulation data is not limited, the target parameter field and the target simulation data in the platform form configuration file can be analyzed according to the value analysis rule, the corresponding form component type is determined according to the data value type of the target simulation data, and then the page form is obtained through rendering.
Further, according to the embodiment of the present invention, the user form configuration information includes a form component type and form data in each form component; after the step of receiving the page form generation request, if it is determined that the page form generation request includes the user form configuration information, the page generation module 303 is further configured to:
and rendering the configuration information of the user form to obtain a page form.
Because the form component types and the form data in each form component are directly transmitted in the user form configuration information, the user form configuration information can be directly rendered to obtain the page form, and the generation efficiency of the page form is further improved.
Preferably, according to the embodiment of the present invention, the page form generating apparatus 300 further includes an updating module, configured to:
and receiving the configuration updating information of the user form, and updating the page form according to the configuration updating information of the user form.
Through the arrangement, the method and the device also support the page form updating function, can directly perform adaptive updating on the generated page form according to the user form configuration updating information sent by the user, and further improve the user experience.
According to the technical scheme of the embodiment of the invention, because the page form generation request is received, when the page form generation request does not comprise the user form configuration information, the form number is generated; the page form generation request comprises a form type; acquiring platform form configuration information from the FaaS function platform according to the form number and the form type; the technical means of analyzing the platform form configuration information and rendering the analysis processing result to obtain the page form is adopted, so that the technical problems that the page form is generated by adopting a form code compiling or configuration file compiling mode in the existing method, the consumption development cost is high, the generation efficiency of the page form is low, the application scene of the page form generation method is narrow, and the user experience is poor are solved, the form configuration information can be dynamically generated by combining a FaaS function platform, the page form is rendered and generated, the generation efficiency of the page form is improved, the consumed development cost is reduced, the application scene of the page form generation method is expanded, and the technical effect of the user experience is improved.
Fig. 4 illustrates an exemplary system architecture 400 of a page form generation method or page form generation apparatus to which embodiments of the present invention may be applied.
As shown in fig. 4, the system architecture 400 may include terminal devices 401, 402, 403, a network 404, and a server 405 (this architecture is merely an example, and the components included in a particular architecture may be adapted according to application specific circumstances). The network 404 serves as a medium for providing communication links between the terminal devices 401, 402, 403 and the server 405. Network 404 may include various types of connections, such as wire, wireless communication links, or fiber optic cables, to name a few.
A user may use terminal devices 401, 402, 403 to interact with a server 405 over a network 404 to receive or send messages or the like. The terminal devices 401, 402, 403 may have installed thereon various communication client applications, such as a data processing type application, a web browser application, a search type application, an instant messaging tool, a mailbox client, social platform software, etc. (by way of example only).
The terminal devices 401, 402, 403 may be various electronic devices having a display screen and supporting web browsing, including but not limited to smart phones, tablet computers, laptop portable computers, desktop computers, and the like.
The server 405 may be a server that provides various services, such as a server (for example only) for (performing page form generation/performing data processing on) a user with the terminal device 401, 402, 403. The server may analyze and process the received data such as the page form generation request, and feed back the processing result (e.g., the page form — just an example) to the terminal device.
It should be noted that the method for generating a page form provided by the embodiment of the present invention is generally executed by the server 405, and accordingly, the page form generating apparatus is generally disposed in the server 405.
It should be understood that the number of terminal devices, networks, and servers in fig. 4 is merely illustrative. There may be any number of terminal devices, networks, and servers, as desired for an implementation.
Referring now to FIG. 5, a block diagram of a computer system 500 suitable for use with a terminal device or server implementing an embodiment of the invention is shown. The terminal device or the server shown in fig. 5 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present invention.
As shown in fig. 5, the computer system 500 includes a Central Processing Unit (CPU) 501 that can perform various appropriate actions and processes according to a program stored in a Read Only Memory (ROM) 502 or a program loaded from a storage section 508 into a Random Access Memory (RAM) 503. In the RAM 503, various programs and data necessary for the operation of the system 500 are also stored. The CPU 501, ROM 502, and RAM 503 are connected to each other via a bus 504. An input/output (I/O) interface 505 is also connected to bus 504.
The following components are connected to the I/O interface 505: an input portion 506 including a keyboard, a mouse, and the like; an output portion 507 including a display such as a Cathode Ray Tube (CRT), a Liquid Crystal Display (LCD), and the like, and a speaker; a storage portion 508 including a hard disk and the like; and a communication section 509 including a network interface card such as a LAN card, a modem, or the like. The communication section 509 performs communication processing via a network such as the internet. The driver 510 is also connected to the I/O interface 505 as necessary. A removable medium 511 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, or the like is mounted on the drive 510 as necessary, so that a computer program read out therefrom is mounted into the storage section 508 as necessary.
In particular, according to embodiments of the present disclosure, the processes described above with reference to the flow diagrams may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a computer readable medium, the computer program comprising program code for performing the method illustrated in the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network through the communication section 509, and/or installed from the removable medium 511. The computer program performs the above-described functions defined in the system of the present invention when executed by the Central Processing Unit (CPU) 501.
It should be noted that the computer readable medium shown in the present invention can be a computer readable signal medium or a computer readable storage medium or any combination of the two. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having 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. In the present invention, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In the present invention, however, a computer readable signal medium may include a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, fiber optic cable, RF, etc., or any suitable combination of the foregoing.
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present invention. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams or flowchart illustration, and combinations of blocks in the block diagrams or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The modules described in the embodiments of the present invention may be implemented by software or hardware. The described modules may also be provided in a processor, which may be described as: a processor includes a receiving module, an obtaining module, and a page generating module. The names of these modules do not form a limitation on the modules themselves in some cases, for example, the receiving module may also be described as "a module for receiving a page form generation request, determining that the page form generation request does not include the user form configuration information, and generating a form number".
As another aspect, the present invention also provides a computer-readable medium that may be contained in the apparatus described in the above embodiments; or may be separate and not incorporated into the device. The computer readable medium carries one or more programs which, when executed by a device, cause the device to comprise: receiving a page form generation request, and generating a form number when the page form generation request does not include user form configuration information; the page form generation request comprises a form type; acquiring platform form configuration information from the FaaS function platform according to the form number and the form type; and analyzing the platform form configuration information, and rendering the analysis processing result to obtain the page form.
According to the technical scheme of the embodiment of the invention, because the received page form generation request is adopted, when the page form generation request does not include the user form configuration information, the form number is generated; the page form generation request comprises a form type; acquiring platform form configuration information from a FaaS function platform according to the form number and the form type; the technical means of analyzing the platform form configuration information and rendering the analysis processing result to obtain the page form is adopted, so that the technical problems that the page form is generated by adopting a form code compiling or configuration file compiling mode in the existing method, the consumption development cost is high, the generation efficiency of the page form is low, the application scene of the page form generation method is narrow, and the user experience is poor are solved, the form configuration information can be dynamically generated by combining a FaaS function platform, the page form is rendered and generated, the generation efficiency of the page form is improved, the consumed development cost is reduced, the application scene of the page form generation method is expanded, and the technical effect of the user experience is improved.
The above-described embodiments should not be construed as limiting the scope of the invention. Those skilled in the art will appreciate that various modifications, combinations, sub-combinations, and substitutions can occur, depending on design requirements and other factors. Any modification, equivalent replacement, and improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.

Claims (10)

1. A method for generating a page form is characterized by comprising the following steps:
receiving a page form generation request, and generating a form number when the page form generation request does not include user form configuration information; the page form generation request comprises a form type;
acquiring platform form configuration information from a FaaS function platform according to the form number and the form type;
and analyzing the platform form configuration information, and rendering an analysis processing result to obtain a page form.
2. The method for generating a page form according to claim 1, wherein before the step of obtaining platform form configuration information from a FaaS function platform, the method further comprises:
creating a form submission function by using the FaaS function platform, and configuring a parameter field corresponding to the form submission function; creating a form query function by using the FaaS function platform, and configuring simulation data corresponding to the parameter field in the form query function;
and receiving the interface parameters of the form submission function and the interface parameters of the form query function, which are sent by the FaaS function platform.
3. The method for generating a page form according to claim 2, wherein the step of obtaining platform form configuration information from a FaaS function platform according to the form number and the form type includes:
determining a target form submitting function and a target form inquiring function according to the form number and the form type;
acquiring platform form configuration information from the FaaS function platform according to the target form submission function, the target form query function, the form submission function interface parameter and the form query function interface parameter; the platform form configuration information comprises a target parameter field and target simulation data corresponding to the target parameter field.
4. The method for generating a page form according to claim 3, wherein the step of parsing the platform form configuration information and rendering a result of the parsing to obtain a page form includes:
analyzing the target parameter field and the target simulation data in the platform form configuration information, and rendering an analysis processing result to obtain the page form; and the analysis result indicates the form component type corresponding to the target simulation data.
5. The page form generation method of claim 1, wherein the user form configuration information includes form component types and form data within each form component; after the step of receiving a page form generation request, if it is determined that the page form generation request includes the user form configuration information, the method further includes:
and rendering the user form configuration information to obtain the page form.
6. The method for generating a page form according to claim 1, further comprising:
and receiving the configuration updating information of the user form, and updating the page form according to the configuration updating information of the user form.
7. A page form generation apparatus, comprising:
the receiving module is used for receiving a page form generation request and generating a form number when determining that the page form generation request does not include user form configuration information; the page form generation request comprises a form type;
the acquisition module is used for acquiring platform form configuration information from a FaaS function platform according to the form number and the form type;
and the page generation module is used for analyzing the platform form configuration information and rendering the analysis processing result to obtain a page form.
8. The page form generating apparatus according to claim 7, further comprising a function building module, before the step of obtaining platform form configuration information from a FaaS function platform, the function building module being configured to:
creating a form submission function by using the FaaS function platform, and configuring a parameter field corresponding to the form submission function; creating a form query function by using the FaaS function platform, and configuring simulation data corresponding to the parameter field in the form query function;
and receiving the interface parameters of the form submission function and the interface parameters of the form query function, which are sent by the FaaS function platform.
9. An electronic device for page form generation, comprising:
one or more processors;
a storage device for storing one or more programs,
when executed by the one or more processors, cause the one or more processors to implement the method of any one of claims 1-6.
10. A computer-readable medium, on which a computer program is stored, which, when being executed by a processor, carries out the method according to any one of claims 1-6.
CN202210777563.6A 2022-07-01 2022-07-01 Page form generation method and device Pending CN115146202A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210777563.6A CN115146202A (en) 2022-07-01 2022-07-01 Page form generation method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210777563.6A CN115146202A (en) 2022-07-01 2022-07-01 Page form generation method and device

Publications (1)

Publication Number Publication Date
CN115146202A true CN115146202A (en) 2022-10-04

Family

ID=83410768

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210777563.6A Pending CN115146202A (en) 2022-07-01 2022-07-01 Page form generation method and device

Country Status (1)

Country Link
CN (1) CN115146202A (en)

Similar Documents

Publication Publication Date Title
CN107832045B (en) Method and apparatus for cross programming language interface conversion
CN109388626B (en) Method and apparatus for assigning numbers to services
CN112527649A (en) Test case generation method and device
CN110706093A (en) Accounting processing method and device
CN113010405A (en) Application program testing method and device
CN113050940A (en) Method for previewing small program, related device and computer program product
CN113076153A (en) Interface calling method and device
CN113779004A (en) Data verification method and device
CN111881392A (en) Page display method and device
CN111414154A (en) Method and device for front-end development, electronic equipment and storage medium
CN111382953A (en) Dynamic process generation method and device
CN112948138A (en) Method and device for processing message
CN112685481A (en) Data processing method and device
CN113779122B (en) Method and device for exporting data
CN114625458A (en) Page data processing method and device, electronic equipment and storage medium
CN115146202A (en) Page form generation method and device
CN114125067A (en) Front-end and back-end separated gray scale publishing method, front-end server and configuration server
CN113515328A (en) Page rendering method and device, electronic equipment and storage medium
CN113779018A (en) Data processing method and device
CN113760274A (en) Front-end component logic injection method and device
CN113760344A (en) Dynamic configuration method, device, electronic equipment and storage medium
CN110647327A (en) Method and device for dynamic control of user interface based on card
CN110858240A (en) Front-end module loading method and device
CN114157917B (en) Video editing method and device and terminal equipment
CN108984189B (en) Module parsing method and device

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