Method, device, storage medium and electronic device for generating form
By obtaining the material attribute data of the target material and pre-configured form description information, dynamically generate forms, solving the problems of complex form configuration and high maintenance costs in the existing technology, and achieving flexible form generation for multiple material types.
Patent Information
- Application Number
- CN202110767659.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-07-07
- Publication Date
- 2025-02-28
- Estimated Expiration
- 2041-07-07
AI Technical Summary
When existing form generation solutions deal with multiple complex material types, they are complex in configuration and high maintenance costs, making it difficult to dynamically generate forms that adapt to different material types.
By obtaining the material attribute data of the target material and pre-configured form description information, dynamically look up configurations to generate forms, simplifying form description rules, and reducing configuration maintenance costs.
Dynamic form generation of multiple material types is realized, reducing the complexity and maintenance cost of form configuration, and improving the efficiency and flexibility of form generation.
Smart Images

Figure 00000000_0000_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of computer application technology, and in particular, to a method, device, storage medium and electronic device for generating a form. Background Art
[0002] Currently, various interactive works, such as interactive games, can be created based on preset materials through the interactive editor. When developers create interactive works through the interactive editor, they can edit the properties of the selected target material in the property form displayed on the interface property panel. Therefore, before creating interactive works, it is necessary to generate corresponding property forms for different preset materials.
[0003] There are many open source form solutions in the prior art, such as form-create, formily, ace-form, etc. However, the above open source form generation solutions require the use of code to write a separate form for the attribute form corresponding to each preset material, and the relationship between configuration and data in the above existing form generation solutions is not independent of each other, but the configuration determines the data. However, the interactive editor involves a wide variety of material types, and different interactive components can be generated based on different materials. There are also many component types and the structure is complex. In the existing solution, the data is determined by the configuration. In order to support complex data as much as possible, the configuration will become more and more complex. Complex configuration will increase maintenance costs and calculation difficulty. Summary of the invention
[0004] This summary is provided to introduce concepts in a brief form that will be described in detail in the detailed description below. This summary is not intended to identify key features or essential features of the claimed technical solution, nor is it intended to limit the scope of the claimed technical solution.
[0005] In a first aspect, the present disclosure provides a method for generating a form, the method comprising:
[0006] Acquire material attribute data corresponding to at least one target material;
[0007] Acquire pre-configured form description information, where the form description information is pre-configured form description information based on multiple candidate materials in the current business;
[0008] Determining form attribute information of a target form according to the material attribute data and the form description information, the target form being a form to be generated corresponding to at least one of the target materials, the form attribute information including description information of each form item in the target form and layout information of each form item in the target form;
[0009] The target form is generated according to the description information and the layout information of each form item.
[0010] In a second aspect, the present disclosure provides a device for generating a form, the device comprising:
[0011] A first acquisition module, used to acquire material attribute data corresponding to at least one target material;
[0012] A second acquisition module is used to acquire pre-configured form description information, where the form description information is pre-configured form description information according to a plurality of candidate materials in the current business;
[0013] a determination module, configured to determine form attribute information of a target form according to the material attribute data and the form description information, wherein the target form is a form to be generated corresponding to at least one of the target materials, and the form attribute information includes description information of each form item in the target form and layout information of each form item in the target form;
[0014] The form generating module is used to generate the target form according to the description information and the layout information of each form item.
[0015] In a third aspect, the present disclosure provides a computer-readable medium having a computer program stored thereon, which, when executed by a processing device, implements the steps of the method described in the first aspect of the present disclosure.
[0016] In a fourth aspect, an electronic device is provided, comprising: a storage device on which a computer program is stored; and a processing device for executing the computer program in the storage device to implement the steps of the method described in the first aspect of the present disclosure.
[0017] Through the above technical scheme, material attribute data corresponding to at least one target material is obtained; pre-configured form description information is obtained, and the form description information is pre-configured according to multiple candidate materials in the current business; form attribute information of a target form is determined according to the material attribute data and the form description information, and the target form is a form to be generated corresponding to at least one of the target materials, and the form attribute information includes description information of each form item in the target form and layout information of each form item in the target form; the target form is generated according to the description information and the layout information of each form item, so that the material attribute data of each form item corresponding to the target material can be dynamically searched and configured in the pre-configured form description information, so that corresponding forms can be dynamically generated for various material types including interactive components, and the form description rules in the form description information are simple and easy to calculate, and more dynamic form effects can be achieved, thereby reducing the maintenance cost and calculation difficulty of the form configuration.
[0018] Other features and advantages of the present disclosure will be described in detail in the following detailed description. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] The above and other features, advantages and aspects of the embodiments of the present disclosure will become more apparent with reference to the following detailed description in conjunction with the accompanying drawings. Throughout the drawings, the same or similar reference numerals represent the same or similar elements. It should be understood that the drawings are schematic and the originals and elements are not necessarily drawn to scale. In the drawings:
[0020] Figure 1 is a flow chart of a method for generating a form according to an exemplary embodiment;
[0021] Figure 2 is a schematic diagram of an interface of an interactive editor according to an exemplary embodiment;
[0022] Figure 3 is a schematic diagram of a form of a text node according to an exemplary embodiment;
[0023] Figure 4 is a schematic diagram of a form layout of a text node according to an exemplary embodiment;
[0024] Figure 5 is a schematic diagram of a form layout according to an exemplary embodiment;
[0025] Figure 6 is a flow chart of a method for generating a form according to an exemplary embodiment;
[0026] Figure 7a-Figure 7b is a schematic diagram of extends inheritance structure configuration information according to an exemplary embodiment;
[0027] Figure 8 is a schematic diagram of a form layout of an image node according to an exemplary embodiment;
[0028] Figure 9a-9b It is a form diagram of physical properties;
[0029] Fig.10 is a schematic diagram of a form layout of a text node according to an exemplary embodiment;
[0030] Fig.11 is a schematic diagram of classification and merging of form items according to an exemplary embodiment;
[0031] Fig.12 is a block diagram of a device for generating a form according to an exemplary embodiment;
[0032] Fig.13 is a block diagram of a device for generating a form according to an exemplary embodiment;
[0033] Fig.14 It is a structural block diagram of an electronic device according to an exemplary embodiment. DETAILED DESCRIPTION
[0034] Embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. Although certain embodiments of the present disclosure are shown in the accompanying drawings, it should be understood that the present disclosure can be implemented in various forms and should not be construed as being limited to the embodiments described herein, which are instead provided for a more thorough and complete understanding of the present disclosure. It should be understood that the drawings and embodiments of the present disclosure are only for exemplary purposes and are not intended to limit the scope of protection of the present disclosure.
[0035] It should be understood that the various steps described in the method embodiments of the present disclosure may be performed in different orders and / or in parallel. In addition, the method embodiments may include additional steps and / or omit the steps shown. The scope of the present disclosure is not limited in this respect.
[0036] The term "including" and its variations used herein are open inclusions, i.e., "including but not limited to". The term "based on" means "based at least in part on". The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment"; the term "some embodiments" means "at least some embodiments". The relevant definitions of other terms will be given in the following description.
[0037] It should be noted that the concepts such as "first" and "second" mentioned in the present disclosure are only used to distinguish different devices, modules or units, and are not used to limit the order or interdependence of the functions performed by these devices, modules or units.
[0038] It should be noted that the modifications of "one" and "plurality" mentioned in the present disclosure are illustrative rather than restrictive, and those skilled in the art should understand that unless otherwise clearly indicated in the context, it should be understood as "one or more".
[0039] The names of the messages or information exchanged between multiple devices in the embodiments of the present disclosure are only used for illustrative purposes and are not used to limit the scope of these messages or information.
[0040] The present disclosure is mainly applied to the scenario of generating a corresponding attribute form for a preset material or an interactive component composed of different preset materials before making an interactive work based on preset materials through an interactive editor. In the related technology, open source form solutions such as form-create, formily, ace-form, etc. are mainly used to write a separate form with code for each preset material, and the relationship between configuration and data in the above-mentioned existing form generation solutions is not independent of each other, but the configuration determines the data. However, the interactive editor involves a wide variety of material types (such as scenes, text, pictures, videos, audio, particle animations, Lottie animations, sequence frames, graphics, animations, events), and different interactive components can be generated based on different materials. There are also many types of components and the structure is complex. In the existing solution, the data is determined by the configuration. In order to support complex data as much as possible, the configuration will become more and more complex. The complex configuration will increase the maintenance cost and calculation difficulty.
[0041] In order to solve the above-mentioned problems, the present disclosure provides a method, device, storage medium and electronic device for generating a form, which can dynamically search and configure in pre-configured form description information according to the material attribute data of each form item corresponding to the target material, so that corresponding forms can be dynamically generated for various material types including interactive components, and the form description rules in the form description information are simple and easy to calculate, and more dynamic form effects can be achieved, thereby reducing the maintenance cost and calculation difficulty of the form configuration.
[0042] The specific embodiments of the present disclosure are described in detail below with reference to the accompanying drawings.
[0043] Figure 1 is a flowchart of a method for generating a form according to an exemplary embodiment. Figure 1 As shown, the method comprises the following steps:
[0044] In step S101, material attribute data corresponding to at least one target material is obtained.
[0045] Among them, the target material refers to the material selected by the user from multiple preset materials in an interactive editor (such as RUBEEX, Modao and other editors) for making interactive works. The preset material may include at least one or more of the following: scenes, interactive components, text, pictures, videos, audio, particle animation, Lottie animation, sequence frames, graphics, animation, events. Among them, interactive components are usually composed of multiple other materials. For example, text nodes and picture nodes in the preset materials can form an interactive component.
[0046] The material attribute data refers to preset default attribute data corresponding to the target material.
[0047] For example, Figure 2 is a schematic diagram of an interface of an interactive editor according to an exemplary embodiment. Figure 2 As shown, the user selects a text node in the interactive editor, and the material attribute data corresponding to the text node is as follows Figure 2 As shown in the box in , it includes attribute data such as the center point coordinates (anchor X, anchor Y), color (color), font size (fontSize), width (width), height (height), name (name: "text node"), text information (text: "text content"), etc. of the text node. The above examples are only for illustration and the present disclosure does not limit this.
[0048] In addition, in this step, the material attribute data corresponding to each target material can be obtained in any of the following two ways:
[0049] Method 1: in response to a material selection operation of a user in a preset content editing area, obtaining the material attribute data corresponding to at least one target material selected by the user.
[0050] like Figure 2 As shown, the preset content editing area refers to the operation area of the material node. Based on method one, the user can select one or more target materials from multiple preset materials according to the actual work requirements. After obtaining the user's material selection trigger operation, the terminal can display the target material selected by the user in the preset content editing area, and obtain the material attribute data corresponding to the target material from the preset path corresponding to the target material.
[0051] Method 2: in response to a user inputting an attribute of at least one of the target materials in a preset attribute editing area (or referred to as an attribute panel), obtaining the material attribute data corresponding to at least one of the target materials.
[0052] In another possible application scenario, after selecting the target material, the user can also perform real-time changes to one or more attributes of the target material in the property panel (for example, for a text node, the text content, font size, and other information in the "Basic" attribute can be modified). After the user's attribute input operation in the property panel is obtained, the material attribute data can be obtained once.
[0053] In step S102, pre-configured form description information is obtained, where the form description information is pre-configured according to a plurality of candidate materials in the current business.
[0054] The current service refers to generating a corresponding attribute form for a material in a specified interactive editor. The selected interactive editor is different, and the current service is also different. The types of the candidate materials (or preset materials) corresponding to different services may be different. The form description information may include structure configuration information and attribute configuration information. The structure configuration information includes... The attribute configuration information includes attribute information of each form item component (i.e., the presentation form of the form item in the form) (such as the data attribute name of each form item, the data attribute type, the form item name, the form item default value, the form item prompt, and other information).
[0055] In the process of configuring the form description information, the material attribute data may be configured first, and then the structure configuration information may be configured. Specifically, the material attribute data may be pre-configured in the following manner:
[0056] Obtain at least one candidate material corresponding to the current business; for each candidate material, configure the description information of each form item through JS object notation JSON to obtain the material attribute data.
[0057] For example, taking the candidate material as a text node, Figure 3 is a schematic diagram of a form corresponding to a text node according to an exemplary embodiment. Figure 3 The description of the form item "name" in the form shown can be configured using JSON configuration in the following way:
[0058]
[0059]
[0060] Among them, key represents the data attribute name, type represents the data attribute type, and different attribute types can use different input components. For example, the string type is the input input box, name represents the form item name, default represents the form item default value, and tooltip represents the form item prompt;
[0061] Assuming that the form corresponding to the text node includes three form items: "Name", "Text", and "Font Size", based on the same method, the description information of each form item can be configured through JSON to obtain the material attribute data under the PropertyList field:
[0062]
[0063]
[0064] The above examples are merely illustrative and the present disclosure is not limited thereto.
[0065] After obtaining the description information describing the form item component, you can continue to configure the structure configuration information of the form for at least one candidate material corresponding to the current business:
[0066] First, you can use a grid layout to define the structural information of each form item.
[0067] For example, Figure 4 is a schematic diagram of a form layout corresponding to a text node according to an exemplary embodiment. Figure 4 The form layout shown, assuming that the total number of grids in each row is 12, can be configured in the following way:
[0068]
[0069]
[0070] like Figure 4 As shown in the figure, the form item "name" occupies a separate line in the form, and the corresponding configuration is "column":12. The form items "text" and "font size" are distributed in the same line in the form. For these two form items, "column":6 is configured. Based on the above structure configuration, the following can be generated: Figure 4 The form layout shown in the above example is only for illustration and the present disclosure does not limit this.
[0071] Taking into account the actual application scenarios, the above configuration method may cause repeated configuration problems. For example, the text node has a name attribute and the picture node also has a name attribute. The text node and the picture node have repeated configuration problems, which wastes system configuration resources. To solve the problem of repeated configuration, in a possible implementation method of the present invention, the structural information of the form item can be split from the description information of each form item. However, after the split, the column field is not split out. Since the layout information described by the column field is related to the structure, and in the actual development process, it is often encountered that the layout information of the same attribute in different data is different. In this case, the column field needs to be reconfigured. Therefore, the above configuration structure information is poorly readable and will also increase the maintenance cost of layout changes.
[0072] In another possible implementation of the present disclosure, in order to solve the problem of poor readability of configuration structure information and high layout change cost, a table structure may be used for initialization based on the following configuration method:
[0073]
[0074]
[0075] In the above structure configuration, the column field in each form item information can be deleted, and the structure information of each form item can be configured in the structure configuration list ConfigList, with 12 columns in one row (i.e., 12 grids). The square brackets where the data attribute keyword (or data attribute name) of each form item under the ConfigList field is located represent a row. Therefore, based on the above configuration, it can be more intuitive to determine that the form item "name" in the form occupies a whole row, and the form items "text" and "fontSize" in the form are in the same row and occupy 6 columns of a row respectively, that is, the following is obtained: Figure 4 The form layout shown above is only an example and is not limited to this disclosure.
[0076] Taking into account the actual application scenarios, different data have the same attributes, which often means that they are likely to inherit from a common base class, but the current configuration does not reflect this; in addition, when there are many data attributes, classification is required. In the present disclosure, the individual attributes of each form item can be declared through the second preset field (such as the extends field) in the structure configuration list (i.e., ConfigList), and the public attributes of each form item can be declared through the third preset field (such as the className field). Classification is performed by adding a fourth preset field (such as the groups field), wherein the third preset field represents the base class (or parent class), and the second preset field represents the subclass.
[0077] For example,
[0078]
[0079]
[0080]
[0081]
[0082] In this way, the individual properties of each form item "base", "font", and "style" can be declared through the extends field, and the common properties of the form items "base", "size & position", and "transform" can be declared through className.
[0083] Considering the newly added inheritance and classification features in the configuration, there are two problems. One is the layout sorting problem of different data categories (the data category refers to the preset data category corresponding to one or more form items in the current business) after the subclass inherits the parent class. To address this problem, the present disclosure can set the display sorting identifier corresponding to each data category according to preset rules, and the display sorting identifier is used to indicate the display position corresponding to the data category.
[0084] In a possible implementation, the sortIndex field may be used to represent the display sort identifier, which may be in the form of a number such as 0, 1, or 2. Thus, the larger the display sort identifier, the higher the corresponding data category is ranked in the form layout.
[0085] For example, Figure 5 is a schematic diagram of a form layout according to an exemplary embodiment. Figure 5 As shown, the sortIndex field is used to identify the display sorting identifiers of different data categories respectively. The data category "property setting panel" corresponds to sortIndex=2, the data category "position alignment" corresponds to sortIndex=1, the data category "foundation" corresponds to sortIndex=0, and the data category "font" corresponds to sortIndex=0. In this way, based on the form layout rule that the larger the display sorting identifier, the higher the corresponding data category is ranked in the form layout, the following can be obtained: Figure 5 The form layout shown in the above example is only for illustration and the present disclosure does not limit this.
[0086] After adding inheritance and classification features in the configuration, the following problem still exists: in the process of dynamically generating forms, the same categories of the parent class and child class need to be merged. For example, the classname field contains the form item "Basic", and the extends field also contains the form item "Basic". The attribute information of the two needs to be merged, but considering that when merging the same category, the sortIndex sorting field may be set differently. In order to solve this problem, as shown in the above example, the order of all categories can be declared in the common parent class classname field, and the categories that do not actually exist in the parent class are set to empty categories as placeholders. This can greatly reduce the use of the sortIndex field in the configuration, making the form structure configuration rules more concise and clear.
[0087] In the process of pre-configuring the structural configuration information, in order to support the function of embedding forms in forms and realize dynamic search and configuration according to the data of form items, the present invention can declare a preset matching condition through a first preset field according to the current business, and the preset matching condition is used to indicate the form configuration entry corresponding to the current business.
[0088] The first preset field may include a match field, and the preset matching condition may include one or more matching conditions. For example, the following three preset matching conditions are configured under the match field:
[0089]
[0090] The above examples are merely illustrative and the present disclosure is not limited thereto.
[0091] At this point, the form description information is pre-configured based on multiple candidate materials in the current business.
[0092] In step S103, form attribute information of a target form is determined according to the material attribute data and the form description information, the target form being a form to be generated corresponding to at least one of the target materials, and the form attribute information includes description information of each form item in the target form and layout information of each form item in the target form.
[0093] The description information of each form item includes one or more of a data attribute name, a data attribute type, a form item name, a form item default value, and a form item prompt; the layout information includes at least one or more of the following: a displayable attribute of each form item, a grid number of each form item, and a display sort of each data category; the displayable attribute is used to indicate whether the form item is displayed; and the data category includes at least one form item.
[0094] In this step, you can Figure 6 The following sub-steps are shown to determine the form attribute information of the target form to be generated:
[0095] In step S1031, the material attribute data is matched with a preset matching condition under a first preset field in the structure configuration information, where the first preset field is used to locate a structure configuration entry of the target form.
[0096] The first preset field includes a match field.
[0097] In obtaining Figure 2 After the material attribute data shown is found, a match is first performed to match the material attribute data to the match field in the structure configuration information ConfigList. If the condition is met, it means that the match is successful, that is, the structure configuration entry of the current dynamic form is found. For example, the preset matching condition under the match field is match:{'==':[{var:'type'},'Text']}. If the material attribute data includes data of data type type=Text, it is determined that the match is successful.
[0098] In step S1032, if the material attribute data successfully matches the preset matching condition, the structure configuration information is traversed in sequence starting from the first preset field, and the description information of each form item in the target form is determined according to the traversal result and the attribute configuration information.
[0099] In this step, if it is determined according to the traversal result that the traversal reaches the second preset field, at least one target keyword corresponding to the second preset field is obtained, and the at least one target keyword is matched with the keyword corresponding to the third preset field in the structure configuration information. If the match is successful, at least one data attribute name is determined from the configuration information corresponding to the third preset field, and different data attribute names correspond to different form items; the description information of each form item is obtained from the attribute configuration information according to at least one data attribute name.
[0100] Here, the second preset field includes the extends field, and the third preset field includes the className field.
[0101] For example, Figure 7a and 7b As shown in the figure, the obtained material attribute data is Figure 7a The preset matching condition under the match field in the structure configuration information shown is matched successfully, and the traversal continues to obtain the extends field. At this time, the extends inheritance is performed, and the target keyword 'Base' under the extends field is matched with Figure 7b The target keyword 'Base' under the className field in the structure configuration information shown is matched. If the two are consistent, it means that the text form corresponding to the current text node to be generated contains the structure configuration, and at least one data attribute name is determined from the configuration information corresponding to the className field, such as Figure 7b As shown in the " ", different data attribute names correspond to different form items; for example, the following data attribute names "name", "text", and "fontSize" are obtained. At this time, the obtained form item information only contains the data attribute name (or data attribute keyword), but no detailed form item description information. Therefore, keyword matching can be performed next, that is, the description information of each form item is obtained from the property configuration information PropertyList according to at least one of the data attribute names. For example, based on the data attribute keyword "fontSize", the description information corresponding to the form item "font size" can be obtained:
[0102]
[0103] The above examples are merely illustrative and the present disclosure is not limited thereto.
[0104] After obtaining the complete description information of each form item, you can perform runtime data calculation, including extended data filling and visibility calculation. First, we will introduce how to fill in extended data.
[0105] In the current business form generation process, in order to improve the user experience, some business components need to be filled with extended data. Figure 8 is a schematic diagram of a form layout corresponding to a picture node according to an exemplary embodiment. Figure 8 As shown, the node image needs to support replacement. For a better experience, the user needs to be prompted with the recommended size of the image. At this time, the replacement image component requires the width and height of the image. In the present disclosure, the preset form items in the structure configuration information can be filled with data according to the material attribute data. The preset form items are pre-set according to the actual needs of the current business.
[0106] For example, assume that the material data corresponding to the image node is obtained as follows:
[0107]
[0108] You can fill in the recommended size data under the preset field template field in the description information of the form item "Picture Material" corresponding to the picture node. The specific configuration is as follows:
[0109]
[0110]
[0111] In the extended data, arguments[0] refers to the picture object, that is, arguments[0].width represents the width attribute of the picture object, and arguments[0].height represents the height attribute of the picture object, thereby completing the filling of the extended data for the preset form item "Picture Material" of the picture node. The above example is only for illustration and the present disclosure does not limit this.
[0112] In step S1033, dynamic form calculation is performed according to the material attribute data and the structure configuration information to determine the layout information of each form item in the target form.
[0113] The dynamic form calculation described below includes visibility calculation, initialization of form layout, category merging, category sorting, common attribute calculation, and layout calculation, thereby dynamically generating a form by matching pre-configured form description information according to the material attribute data of the target material.
[0114] When performing visibility calculation in this step, for each form item, a preset visible configuration condition corresponding to the form item can be determined from the structural configuration information; the material attribute data is matched with the preset visible configuration condition, and the displayable attribute corresponding to the form item is determined according to the matching result.
[0115] For example, Figure 9a and 9b As shown in the figure, if you select the static rigid body type in the physical properties, the linear damping, rotational damping, gravity coefficient, angular velocity and other properties will not be displayed, but if you select the dynamic rigid body type, they will be displayed. The corresponding configuration is as follows: rigidBodyType represents the rigid body type, and the linearDamping, angularDamping and other properties set the visible property to {'! =':[{var:'rigidBodyType'},'static']}, which means that these properties are not displayed when the rigid body type is static. On the contrary, the linearDamping, angularDamping and other properties set the visible property to {'==':[{var:'rigidBodyType'},dynamic']}, which means that these properties are displayed when the rigid body type is dynamic, thus achieving the following: Figure 9a and 9b The effect shown.
[0116] Afterwards, initial layout calculation may be performed, that is, the number of grids of each form item may be determined according to the structural configuration information and the displayable attributes.
[0117] Taking the text node as an example, Fig.10 is a schematic diagram of a form layout corresponding to a text node according to an exemplary embodiment. Fig.10 As shown, the data category "text" has four rows, of which wordWrap automatically wraps: one row and one column; leading line spacing, padding inner margin: one row and two columns; align horizontal alignment, valign vertical alignment: one row and two columns; overflow overflow mode: one row and one column. The corresponding layout configuration information is as follows:
[0118] name:'text',
[0119] props:{['wordWrap'],['leading','padding'],['align','valign'],['overflow']}
[0120] When initializing the layout, only the columns that are not explicitly set are initialized, and the impact of column visibility must also be considered. For example, the configuration information becomes:
[0121] name:'text',
[0122] props:{['wordWrap'],['leading',{key:'padding',visible:false}],[{key:'align',column:8},'valign'],['overflow']}
[0123] The padding inner margin is invisible, and the second row is the leading row spacing, one row and one column; the third row, align, horizontal alignment explicitly sets the number of column grids to 8, and then the valign vertical alignment is the total number of grids 12 minus the number of occupied grids 8, which ultimately equals 4. This is just an example and the present disclosure does not limit this.
[0124] Next, the categories can be merged and sorted frequently, that is, the form items of the same data category corresponding to the second preset field and the third preset field in the structural configuration information are merged; the display sorting identifier of each data category is determined from the structural configuration information, and each data category is displayed and sorted according to the display sorting identifier.
[0125] For example, assuming that the form item in the second preset field of the data category "Basic" is "text", and the form items in the third preset field are "name" and "type", after merging the two, the following can be generated: Fig.11 The form layout shown.
[0126] The specific implementation method of classification and sorting here can refer to the specific description in the implementation method of pre-configuring form description information, which will not be repeated here.
[0127] After completing the above matching and form calculation process, the common attributes of multiple target materials selected by the user can be calculated in the following way:
[0128] For each of the target materials, the description information of the form items included in the target material is matched with the description information of the form items included in other materials in turn, and the other materials are any other target materials among the multiple target materials except the target material; according to the matching results, the same form items corresponding to the multiple target materials are used as common attributes.
[0129] After calculating the common attributes, the overall layout calculation of the form must be performed to solve the problem of empty columns and rows that may be caused by runtime data calculation. Specifically, for the same type of attributes, for each row in multiple rows, determine whether there is a hidden column in the row after calculation. If so, it means that the grid number of the row is not full and can be carried forward by subsequent rows, that is, the position of the modified hidden column can be filled by the adjacent form items of subsequent rows.
[0130] In step S104, the target form is generated according to the description information and the layout information of each form item.
[0131] After the above matching and form calculation, the target form can be dynamically generated according to the description information and layout information of each form item.
[0132] By adopting the above method, the configuration can be dynamically searched in the pre-configured form description information according to the material attribute data of each form item corresponding to the target material, so that corresponding forms can be dynamically generated for various material types including interactive components. For example, forms embedded in forms, selecting multiple material nodes at the same time, editing common attributes at the same time, multi-select mixed editing and setting of editable attributes can all be achieved based on the form generation solution disclosed in the present invention, and the form description rules in the form description information are simple and easy to calculate, which can achieve more dynamic form effects, thereby reducing the maintenance cost and calculation difficulty of the form configuration.
[0133] Fig.12 is a block diagram of a device for generating a form according to an exemplary embodiment. Fig.12 As shown, the device comprises:
[0134] The first acquisition module 1201 is used to acquire material attribute data corresponding to at least one target material;
[0135] The second acquisition module 1202 is used to acquire pre-configured form description information, where the form description information is pre-configured form description information according to multiple candidate materials in the current business;
[0136] A determination module 1203 is used to determine form attribute information of a target form according to the material attribute data and the form description information, wherein the target form is a form to be generated corresponding to at least one of the target materials, and the form attribute information includes description information of each form item in the target form and layout information of each form item in the target form;
[0137] The form generating module 1204 is used to generate the target form according to the description information and the layout information of each form item.
[0138] Optionally, the form description information includes structure configuration information and attribute configuration information, and the determination module 1203 is used to match the material attribute data with a preset matching condition under a first preset field in the structure configuration information, and the first preset field is used to locate the structure configuration entry of the target form; if the material attribute data successfully matches the preset matching condition, the structure configuration information is traversed in sequence starting from the first preset field, and the description information of each form item in the target form is determined according to the traversal result and the attribute configuration information; dynamic form calculation is performed according to the material attribute data and the structure configuration information to determine the layout information of each form item in the target form.
[0139] Optionally, the determination module 1203 is used to, if traversing to the second preset field, obtain at least one target keyword corresponding to the second preset field, and match the at least one target keyword with the keyword corresponding to the third preset field in the structure configuration information; if the match is successful, determine at least one data attribute name from the configuration information corresponding to the third preset field, different data attribute names correspond to different form items; and obtain the description information of each form item from the attribute configuration information according to at least one data attribute name.
[0140] Optionally, the device further comprises:
[0141] The data filling module is used to fill the preset form items in the structure configuration information with data according to the material attribute data.
[0142] Optionally, the layout information includes at least one or more of the following: a displayable attribute of each form item, a grid number of each form item, and a display order of each data category, wherein the displayable attribute is used to indicate whether the form item is displayed, and the data category includes at least one form item;
[0143] The determination module 1203 is used to determine, for each form item, a preset visible configuration condition corresponding to the form item from the structural configuration information; match the material attribute data with the preset visible configuration condition, and determine the displayable attribute corresponding to the form item according to the matching result; determine the number of grids for each of the form items according to the structural configuration information and the displayable attribute; merge the form items of the same data category corresponding to the second preset field and the third preset field in the structural configuration information; determine a display sorting identifier for each data category from the structural configuration information, and display sort each of the data categories according to the display sorting identifier.
[0144] Optionally, Fig.13 is based on Fig.12The embodiment shown is a block diagram of a device for generating a form, wherein the target material includes multiple, such as Fig.13 As shown, the device also includes:
[0145] The common attribute calculation module 1205 is used to match the description information of the form items included in each target material with the description information of the form items included in other materials in sequence, where the other materials are any other target materials among the multiple target materials except the target material; and according to the matching results, the same form items corresponding to the multiple target materials are used as common attributes.
[0146] Optionally, the material attribute data is preconfigured in the following manner:
[0147] Obtain at least one candidate material corresponding to the current business; for each candidate material, configure the description information of each form item through the JS object notation JSON to obtain the material attribute data;
[0148] The structure configuration information is configured in the following way:
[0149] A grid layout is used to define the structural information of each form item; the individual attributes of each form item are declared through a second preset field, and the common attributes of each form item are declared through a third preset field; for each of the data categories, a display sorting identifier corresponding to the data category is set according to a preset rule, and the display sorting identifier is used to indicate the display position corresponding to the data category; according to the current business, a preset matching condition is declared through a first preset field, and the preset matching condition is used to indicate the form configuration entry corresponding to the current business.
[0150] Optionally, the description information of each form item includes one or more of a data attribute name, a data attribute type, a form item name, a form item default value, and a form item prompt.
[0151] Optionally, the first acquisition module 1201 is used to obtain the material attribute data corresponding to at least one of the target materials selected by the user in response to a material selection operation of the user in a preset content editing area; or to obtain the material attribute data corresponding to at least one of the target materials in response to a property input operation of the user for at least one of the target materials in a preset property editing area.
[0152] By adopting the above-mentioned device, the configuration can be dynamically searched in the pre-configured form description information according to the material attribute data of each form item corresponding to the target material, so that corresponding forms can be dynamically generated for various material types including interactive components, and the form description rules in the form description information are simple and easy to calculate, which can achieve more dynamic form effects, thereby reducing the maintenance cost and calculation difficulty of the form configuration.
[0153] Reference below Fig.14 , which shows an electronic device (eg, Figure 1 The terminal device in the embodiment of the present disclosure may include but is not limited to mobile terminals such as mobile phones, notebook computers, digital broadcast receivers, PDAs (personal digital assistants), PADs (tablet computers), PMPs (portable multimedia players), vehicle-mounted terminals (such as vehicle-mounted navigation terminals), etc., and fixed terminals such as digital TVs, desktop computers, etc. Fig.14 The electronic device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present disclosure.
[0154] like Fig.14 As shown, the electronic device 1400 may include a processing device (e.g., a central processing unit, a graphics processor, etc.) 1401, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 1402 or a program loaded from a storage device 1408 to a random access memory (RAM) 1403. In the RAM 1403, various programs and data required for the operation of the electronic device 1400 are also stored. The processing device 1401, the ROM 1402, and the RAM 1403 are connected to each other via a bus 1404. An input / output (I / O) interface 1405 is also connected to the bus 1404.
[0155] Typically, the following devices may be connected to the I / O interface 1405: an input device 1406 including, for example, a touch screen, a touch pad, a keyboard, a mouse, a camera, a microphone, an accelerometer, a gyroscope, etc.; an output device 1407 including, for example, a liquid crystal display (LCD), a speaker, a vibrator, etc.; a storage device 1408 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 1409. The communication device 1409 may allow the electronic device 1400 to communicate with other devices wirelessly or by wire to exchange data. Although Fig.14 The electronic device 1400 is shown with various devices, but it should be understood that it is not required to implement or possess all the devices shown. More or fewer devices may be implemented or possessed instead.
[0156] In particular, according to an embodiment of the present disclosure, the process described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present disclosure includes a computer program product, which includes a computer program carried on a non-transitory computer-readable medium, and the computer program contains program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from the network through the communication device 1409, or installed from the storage device 1408, or installed from the ROM 1402. When the computer program is executed by the processing device 1401, the above-mentioned functions defined in the method of the embodiment of the present disclosure are executed.
[0157] It should be noted that the computer-readable medium disclosed above may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, 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 disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present disclosure, a computer-readable storage medium may be any tangible medium containing or storing a program that may be used by or in combination with an instruction execution system, device or device. In the present disclosure, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, in which a computer-readable program code is carried. This propagated data signal may take a variety of forms, including but not limited to an electromagnetic signal, an optical signal, or any suitable combination of the above. The computer readable signal medium may also be any computer readable medium other than a computer readable storage medium, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer readable medium may be transmitted using any suitable medium, including but not limited to: wires, optical cables, RF (radio frequency), etc., or any suitable combination of the above.
[0158] In some embodiments, the client can communicate using any currently known or future developed network protocol such as HTTP (HyperText Transfer Protocol), and can be interconnected with any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include a local area network ("LAN"), a wide area network ("WAN"), an internet (e.g., the Internet), and a peer-to-peer network (e.g., an ad hoc peer-to-peer network), as well as any currently known or future developed network.
[0159] The computer-readable medium may be included in the electronic device, or may exist independently without being incorporated into the electronic device.
[0160] The computer-readable medium carries one or more programs. When the one or more programs are executed by the electronic device, the electronic device: obtains material attribute data corresponding to at least one target material; obtains pre-configured form description information, wherein the form description information is pre-configured according to multiple candidate materials in the current business; determines form attribute information of a target form according to the material attribute data and the form description information, wherein the target form is a form to be generated corresponding to at least one of the target materials, and the form attribute information includes description information of each form item in the target form and layout information of each form item in the target form; and generates the target form according to the description information and the layout information of each form item.
[0161] Computer program code for performing the operations of the present disclosure may be written in one or more programming languages or a combination thereof, including, but not limited to, object-oriented programming languages, such as Java, Smalltalk, C++, and conventional procedural programming languages, such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving a remote computer, the remote computer may be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., via the Internet using an Internet service provider).
[0162] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present disclosure. In this regard, each square box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some implementations as replacements, the functions marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two square boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0163] The modules involved in the embodiments described in the present disclosure may be implemented by software or hardware. The name of a module does not limit the module itself in some cases. For example, the first acquisition module may also be described as a "module for acquiring material attribute data".
[0164] The functions described above herein may be performed at least in part by one or more hardware logic components. For example, without limitation, exemplary types of hardware logic components that may be used include: field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), complex programmable logic devices (CPLDs), and the like.
[0165] In the context of the present disclosure, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, device, or equipment. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or equipment, or any suitable combination of the foregoing. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, 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 disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0166] According to one or more embodiments of the present disclosure, Example 1 provides a method for generating a form, including: obtaining material attribute data corresponding to at least one target material; obtaining pre-configured form description information, the form description information being form description information pre-configured according to multiple candidate materials in a current business; determining form attribute information of a target form according to the material attribute data and the form description information, the target form being a form to be generated corresponding to at least one of the target materials, the form attribute information including description information of each form item in the target form and layout information of each form item in the target form; generating the target form according to the description information and the layout information of each form item.
[0167] According to one or more embodiments of the present disclosure, Example 2 provides the method of Example 1, wherein the form description information includes structure configuration information and attribute configuration information, and determining the form attribute information of the target form according to the material attribute data and the form description information includes:
[0168] Matching the material attribute data with a preset matching condition under a first preset field in the structure configuration information, wherein the first preset field is used to locate a structure configuration entry of the target form;
[0169] If the material attribute data successfully matches the preset matching condition, traversing the structure configuration information in sequence starting from the first preset field, and determining the description information of each form item in the target form according to the traversal result and the attribute configuration information;
[0170] Dynamic form calculation is performed according to the material attribute data and the structural configuration information to determine the layout information of each form item in the target form.
[0171] According to one or more embodiments of the present disclosure, Example 3 provides the method of Example 2, wherein determining the description information of each form item in the target form according to the traversal result and the attribute configuration information includes:
[0172] If the second preset field is traversed, at least one target keyword corresponding to the second preset field is obtained, and matching is performed with a keyword corresponding to the third preset field in the structure configuration information according to the at least one target keyword;
[0173] If the match is successful, determining at least one data attribute name from the configuration information corresponding to the third preset field, where different data attribute names correspond to different form items;
[0174] The description information of each of the form items is acquired from the attribute configuration information according to at least one of the data attribute names.
[0175] According to one or more embodiments of the present disclosure, Example 4 provides the method of Example 2, and after determining the description information of each form item in the target form according to the traversal result and the attribute configuration information, the method further includes:
[0176] The preset form items in the structure configuration information are filled with data according to the material attribute data.
[0177] According to one or more embodiments of the present disclosure, Example 5 provides the method of Example 2, wherein the layout information includes at least one or more of the following: a displayable attribute of each form item, a grid number of each form item, and a display order of each data category, wherein the displayable attribute is used to indicate whether the form item is displayed, and the data category includes at least one form item;
[0178] The performing dynamic form calculation according to the material attribute data and the structure configuration information to determine the layout information of each form item in the target form includes:
[0179] For each form item, determining a preset visible configuration condition corresponding to the form item from the structure configuration information;
[0180] Matching the material attribute data with the preset visible configuration condition, and determining the displayable attribute corresponding to the form item according to the matching result;
[0181] Determine the number of grids for each of the form items according to the structural configuration information and the displayable attributes;
[0182] Merging form items of the same data category corresponding to the second preset field and the third preset field in the structure configuration information;
[0183] A display sorting identifier of each data category is determined from the structural configuration information, and display sorting is performed on each data category according to the display sorting identifier.
[0184] According to one or more embodiments of the present disclosure, Example 6 provides the method of Example 2, wherein the target material includes a plurality of target materials, and the method further includes:
[0185] For each of the target materials, the description information of the form items included in the target material is matched in sequence with the description information of the form items included in other materials, where the other materials are any other target materials among the multiple target materials except the target material;
[0186] According to the matching result, the same form items corresponding to the plurality of target materials are taken as common attributes.
[0187] According to one or more embodiments of the present disclosure, Example 7 provides the method of Example 2, wherein the material attribute data is preconfigured in the following manner:
[0188] Obtain at least one candidate material corresponding to the current business; for each candidate material, configure the description information of each form item through the JS object notation JSON to obtain the material attribute data;
[0189] The structure configuration information is configured in the following way:
[0190] A grid layout is used to define the structural information of each form item; the individual attributes of each form item are declared through a second preset field, and the common attributes of each form item are declared through a third preset field; for each of the data categories, a display sorting identifier corresponding to the data category is set according to a preset rule, and the display sorting identifier is used to indicate the display position corresponding to the data category; according to the current business, a preset matching condition is declared through a first preset field, and the preset matching condition is used to indicate the form configuration entry corresponding to the current business.
[0191] According to one or more embodiments of the present disclosure, Example 8 provides the method of Example 7, wherein the description information of each form item includes one or more of a data attribute name, a data attribute type, a form item name, a form item default value, and a form item prompt.
[0192] According to one or more embodiments of the present disclosure, Example 9 provides the method of any one of Examples 1-8, wherein obtaining material attribute data corresponding to at least one target material includes:
[0193] In response to a material selection operation by a user in a preset content editing area, acquiring the material attribute data respectively corresponding to at least one target material selected by the user; or,
[0194] In response to a user inputting an attribute in a preset attribute editing area for at least one of the target materials, the material attribute data respectively corresponding to at least one of the target materials is acquired.
[0195] According to one or more embodiments of the present disclosure, Example 10 provides a device for generating a form, including:
[0196] A first acquisition module, used to acquire material attribute data corresponding to at least one target material;
[0197] A second acquisition module is used to acquire pre-configured form description information, where the form description information is pre-configured form description information according to a plurality of candidate materials in the current business;
[0198] a determination module, configured to determine form attribute information of a target form according to the material attribute data and the form description information, wherein the target form is a form to be generated corresponding to at least one of the target materials, and the form attribute information includes description information of each form item in the target form and layout information of each form item in the target form;
[0199] The form generating module is used to generate the target form according to the description information and the layout information of each form item.
[0200] The above description is only a preferred embodiment of the present disclosure and an explanation of the technical principles used. Those skilled in the art should understand that the scope of disclosure involved in the present disclosure is not limited to the technical solutions formed by a specific combination of the above technical features, but should also cover other technical solutions formed by any combination of the above technical features or their equivalent features without departing from the above disclosed concept. For example, the above features are replaced with the technical features with similar functions disclosed in the present disclosure (but not limited to) by each other to form a technical solution.
[0201] In addition, although each operation is described in a specific order, this should not be understood as requiring these operations to be performed in the specific order shown or in a sequential order. Under certain circumstances, multitasking and parallel processing may be advantageous. Similarly, although some specific implementation details are included in the above discussion, these should not be interpreted as limiting the scope of the present disclosure. Some features described in the context of a separate embodiment can also be implemented in a single embodiment in combination. On the contrary, the various features described in the context of a single embodiment can also be implemented in multiple embodiments individually or in any suitable sub-combination mode.
[0202] Although the subject matter has been described in language specific to structural features and / or method logic actions, it should be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or actions described above. On the contrary, the specific features and actions described above are merely example forms of implementing the claims. Regarding the device in the above embodiment, the specific manner in which each module performs the operation has been described in detail in the embodiment related to the method, and will not be elaborated here.
Claims
1. A method for generating a form, characterized in that: The method comprises: Acquire material attribute data corresponding to at least one target material; Acquire pre-configured form description information, where the form description information is pre-configured form description information based on multiple candidate materials in the current business; Determining form attribute information of a target form according to the material attribute data and the form description information, the target form being a form to be generated corresponding to at least one of the target materials, the form attribute information including description information of each form item in the target form and layout information of each form item in the target form; Generate the target form according to the description information and the layout information of each form item; The target material includes a plurality of materials, and the form attribute information of the target form determined according to the material attribute data and the form description information includes: For each of the target materials, the description information of the form items included in the target material is matched in sequence with the description information of the form items included in other materials, where the other materials are any other target materials among the multiple target materials except the target material; According to the matching result, the same form items corresponding to the plurality of target materials are taken as common attributes.
2. The method according to claim 1, characterized in that The form description information includes structure configuration information and attribute configuration information, and the form attribute information of the target form determined according to the material attribute data and the form description information includes: Matching the material attribute data with a preset matching condition under a first preset field in the structure configuration information, wherein the first preset field is used to locate a structure configuration entry of the target form; If the material attribute data successfully matches the preset matching condition, traversing the structure configuration information in sequence starting from the first preset field, and determining the description information of each form item in the target form according to the traversal result and the attribute configuration information; Dynamic form calculation is performed according to the material attribute data and the structural configuration information to determine the layout information of each form item in the target form.
3. The method according to claim 2, characterized in that The step of determining the description information of each form item in the target form according to the traversal result and the attribute configuration information includes: If the second preset field is traversed, at least one target keyword corresponding to the second preset field is obtained, and matching is performed with a keyword corresponding to the third preset field in the structure configuration information according to the at least one target keyword; If the match is successful, determining at least one data attribute name from the configuration information corresponding to the third preset field, where different data attribute names correspond to different form items; The description information of each of the form items is acquired from the attribute configuration information according to at least one of the data attribute names.
4. The method according to claim 2, characterized in that: After determining the description information of each form item in the target form according to the traversal result and the attribute configuration information, the method further includes: The preset form items in the structure configuration information are filled with data according to the material attribute data.
5. The method according to claim 3, characterized in that: The layout information includes at least one or more of the following: a displayable attribute of each form item, a grid number of each form item, and a display order of each data category, wherein the displayable attribute is used to indicate whether the form item is displayed, and the data category includes at least one form item; The performing dynamic form calculation according to the material attribute data and the structure configuration information to determine the layout information of each form item in the target form includes: For each form item, determining a preset visible configuration condition corresponding to the form item from the structure configuration information; Matching the material attribute data with the preset visible configuration condition, and determining the displayable attribute corresponding to the form item according to the matching result; Determine the number of grids for each of the form items according to the structural configuration information and the displayable attributes; Merging form items of the same data category corresponding to the second preset field and the third preset field in the structure configuration information; A display sorting identifier of each data category is determined from the structural configuration information, and display sorting is performed on each data category according to the display sorting identifier.
6. The method according to claim 5, characterized in that The material attribute data is pre-configured in the following manner: Obtain at least one candidate material corresponding to the current business; for each candidate material, configure the description information of each form item through the JS object notation JSON to obtain the material attribute data; The structure configuration information is configured in the following way: A grid layout is used to define the structural information of each form item; the individual attributes of each form item are declared through a second preset field, and the common attributes of each form item are declared through a third preset field; for each of the data categories, a display sorting identifier corresponding to the data category is set according to a preset rule, and the display sorting identifier is used to indicate the display position corresponding to the data category; according to the current business, a preset matching condition is declared through a first preset field, and the preset matching condition is used to indicate the form configuration entry corresponding to the current business.
7. The method according to claim 6, characterized in that The description information of each form item includes one or more of a data attribute name, a data attribute type, a form item name, a form item default value, and a form item prompt.
8. The method according to any one of claims 1 to 7, characterized in that: The acquiring of material attribute data corresponding to at least one target material comprises: In response to a material selection operation by a user in a preset content editing area, acquiring the material attribute data respectively corresponding to at least one target material selected by the user; or, In response to a user inputting an attribute in a preset attribute editing area for at least one of the target materials, the material attribute data respectively corresponding to at least one of the target materials is acquired.
9. A device for generating a form, characterized in that: The device comprises: A first acquisition module, used to acquire material attribute data corresponding to at least one target material; A second acquisition module is used to acquire pre-configured form description information, where the form description information is pre-configured form description information according to a plurality of candidate materials in the current business; a determination module, configured to determine form attribute information of a target form according to the material attribute data and the form description information, wherein the target form is a form to be generated corresponding to at least one of the target materials, and the form attribute information includes description information of each form item in the target form and layout information of each form item in the target form; A form generation module, used to generate the target form according to the description information and the layout information of each form item; The target materials include multiple ones, and the determination module is used to match, for each of the target materials, the description information of the form items included in the target material with the description information of the form items included in other materials in sequence, where the other materials are any other target materials among the multiple target materials except the target material; and according to the matching results, the same form items corresponding to the multiple target materials are used as common attributes.
10. A computer readable medium having a computer program stored thereon, characterized in that: When the program is executed by a processing device, the steps of the method described in any one of claims 1 to 8 are implemented.
11. An electronic device, characterized in that: include: a storage device having a computer program stored thereon; A processing device, configured to execute the computer program in the storage device to implement the steps of the method according to any one of claims 1 to 8.
Citation Information
Patent Citations
Method and device for generating playing strategy
CN104683883A
Form generation method, device and electronic device
CN109460546A