CN109753612B - Questionnaire display control method and device, storage medium and electronic equipment - Google Patents

Questionnaire display control method and device, storage medium and electronic equipment Download PDF

Info

Publication number
CN109753612B
CN109753612B CN201811489975.XA CN201811489975A CN109753612B CN 109753612 B CN109753612 B CN 109753612B CN 201811489975 A CN201811489975 A CN 201811489975A CN 109753612 B CN109753612 B CN 109753612B
Authority
CN
China
Prior art keywords
topic
option
display
binding relationship
selection instruction
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.)
Active
Application number
CN201811489975.XA
Other languages
Chinese (zh)
Other versions
CN109753612A (en
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.)
Neusoft Corp
Original Assignee
Neusoft Corp
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 Neusoft Corp filed Critical Neusoft Corp
Priority to CN201811489975.XA priority Critical patent/CN109753612B/en
Publication of CN109753612A publication Critical patent/CN109753612A/en
Application granted granted Critical
Publication of CN109753612B publication Critical patent/CN109753612B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

The disclosure relates to a method and a device for controlling questionnaire display, a storage medium and an electronic device, relating to the technical field of information, wherein the method comprises the following steps: the method comprises the steps of obtaining a first selection instruction corresponding to a first topic, wherein the first selection instruction is used for indicating that a first option in the first topic is selected, the first topic is any topic currently displayed in a questionnaire, the first option is any option of the first topic, determining a second topic bound with the first option and a first display strategy of the second topic according to the first selection instruction and a logic attribute of the first topic, the logic attribute comprises a binding relation corresponding to each option of the first topic, the binding relation corresponding to any option comprises a target topic bound with any option, and when any option is selected, the display strategy of the target topic controls rendering operation of an HTML element corresponding to the second topic according to the first display strategy. The response speed and the stability of the questionnaire display can be improved.

Description

Questionnaire display control method and device, storage medium and electronic equipment
Technical Field
The present disclosure relates to the field of information technology, and in particular, to a method and an apparatus for controlling questionnaire display, a storage medium, and an electronic device.
Background
Questionnaires are a common tool for collecting data, are increasingly used for quantitative research, and have become one of the major ways of social research. With the rapid development of information technologies such as the internet, cloud computing and the internet of things, the design, filling and collection processes of the questionnaire can be realized through the network, and the network inquiry is rolled into a main expression form for the questionnaire in actual application. With the increasing use rate of network questionnaires, the design of network questionnaires is more complex, and the targeted user population is more comprehensive, so that the network questionnaires usually contain a plurality of skip logics, and designers expect different groups to answer different questions, that is, different options in one topic can be skipped to different topics. In the prior art, a large amount of monitoring codes need to be written to monitor each option in a topic, and a DOM (Document Object Model) element needs to be repeatedly queried, which is a tedious process, so that a network questionnaire is displayed at a slow response speed and is easy to shake.
Disclosure of Invention
The disclosure aims to provide a method and a device for controlling questionnaire display, a storage medium and electronic equipment, which are used for solving the problems that the response speed of questionnaire display is slow, jitter is easy to occur and the like in the prior art.
In order to achieve the above object, the present disclosure provides a method of controlling a questionnaire display, the method comprising:
acquiring a first selection instruction corresponding to a first topic, wherein the first selection instruction is used for indicating that a first option in the first topic is selected, the first topic is any one currently displayed topic in a questionnaire, and the first option is any one option of the first topic;
determining a second topic bound with the first option and a first display strategy of the second topic according to the first selection instruction and a logic attribute of the first topic, wherein the logic attribute comprises a binding relationship corresponding to each option of the first topic, the binding relationship corresponding to any option comprises a target topic bound with any option, and the display strategy of the target topic is determined when any option is selected;
and controlling the rendering operation of the HTML element corresponding to the second title according to the first display strategy.
Optionally, the controlling, according to the first display policy, an HTML element corresponding to the second topic includes:
when the first display strategy is display, rendering the second theme according to an HTML element corresponding to the second theme so as to display the second theme;
and when the first display strategy is hidden, hiding the HTML element corresponding to the second theme.
Optionally, the binding relationship corresponding to any option in the logical attribute includes an option identification number of the option; the determining, according to the first selection instruction and the logical property of the first topic, a second topic bound to the first option and a first display policy of the second topic includes:
acquiring a first option identification number of the first option according to the first selection instruction;
determining a first binding relationship in the logical attribute of the first topic according to the first option identification number, wherein the first binding relationship is the binding relationship of the logical attribute including the first option identification number;
and determining the second theme and the first display strategy of the second theme according to the first binding relationship.
Optionally, after the controlling, according to the first display policy, a rendering operation on an HTML element corresponding to the second topic, the method further includes:
determining whether a third topic comprising a second binding relationship exists in a logic attribute, wherein the second binding relationship is the binding relationship comprising the second topic;
when the third topic exists, a second selection instruction corresponding to the third topic is obtained, and the second selection instruction is used for indicating that a second option indicated by the second binding relationship in the third topic is selected;
when a second display strategy of the second topic indicated by the second binding relationship is the same as the first display strategy, maintaining an HTML element corresponding to the second topic;
and when a second display strategy of the second topic indicated by the second binding relationship is different from the first display strategy, controlling rendering operation of an HTML element corresponding to the second topic according to the second display strategy.
Optionally, the logic attribute of the fourth topic is stored in an HTML element corresponding to the fourth topic, where the fourth topic is any topic in the questionnaire.
According to a second aspect of the embodiments of the present disclosure, there is provided a control apparatus of a questionnaire display, the apparatus including:
a first obtaining module, configured to obtain a first selection instruction corresponding to a first topic, where the first selection instruction is used to indicate that a first option in the first topic is selected, the first topic is any currently displayed topic in a questionnaire, and the first option is any option of the first topic;
a first determining module, configured to determine, according to the first selection instruction and a logical attribute of the first topic, a second topic bound to the first option and a first display policy of the second topic, where the logical attribute includes the binding relationship corresponding to each option of the first topic, the binding relationship corresponding to any option includes a target topic bound to the any option, and the display policy of the target topic when the any option is selected;
and the control module is used for controlling the rendering operation of the HTML element corresponding to the second title according to the first display strategy.
Optionally, the control module includes:
the first control submodule is used for rendering the second theme according to the HTML element corresponding to the second theme when the first display strategy is display so as to display the second theme;
and the second control submodule is used for hiding the HTML element corresponding to the second question when the first display strategy is hidden.
Optionally, the binding relationship corresponding to any option in the logical attribute includes an option identification number of the option;
the first determining module includes:
the obtaining submodule is used for obtaining a first option identification number of the first option according to the first selection instruction;
a first determining submodule, configured to determine a first binding relationship in the logical attribute of the first question according to the first option identification number, where the first binding relationship is a binding relationship in the logical attribute that includes the first option identification number;
and the second determining submodule is used for determining the second theme and the first display strategy of the second theme according to the first binding relationship.
Optionally, the apparatus further comprises:
a second determining module, configured to determine whether a third topic with a logical attribute including a second binding relationship exists after controlling a rendering operation on an HTML element corresponding to the second topic according to the first display policy, where the second binding relationship is a binding relationship including the second topic;
a second obtaining module, configured to obtain, when the third topic exists, a second selection instruction corresponding to the third topic, where the second selection instruction is used to indicate that a second option indicated by the second binding relationship has been selected in the third topic;
the control module is further configured to, when a second display policy of the second topic indicated by the second binding relationship is the same as the first display policy, maintain an HTML element corresponding to the second topic;
the control module is further configured to control rendering operation of an HTML element corresponding to the second topic according to the second display policy when the second display policy of the second topic indicated by the second binding relationship is different from the first display policy.
Optionally, the logic attribute of the fourth topic is stored in an HTML element corresponding to the fourth topic, where the fourth topic is any topic in the questionnaire.
According to a third aspect of embodiments of the present disclosure, there is provided a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, implements the steps of the method of controlling questionnaire display provided by the first aspect.
According to a fourth aspect of the embodiments of the present disclosure, there is provided an electronic apparatus including:
a memory having a computer program stored thereon;
a processor for executing the computer program in the memory to implement the steps of the method for controlling a questionnaire display provided by the first aspect.
According to the technical scheme, the method includes the steps that a first selection instruction corresponding to a first topic and used for indicating that a first option in the first topic is selected is obtained, the first topic is any one topic currently displayed in a questionnaire, a second topic bound with the first option and a first display strategy corresponding to the second topic are determined according to the first selection instruction and the logic attribute of the first topic, wherein the logic attribute comprises a binding relation corresponding to each option in the first topic, each binding relation comprises a target topic bound with the option, when the option is selected, the display strategy of the target topic is controlled, and finally, the rendering operation of an HTML element corresponding to the second topic is controlled according to the first display strategy. The operation of monitoring a large number of codes and inquiring document elements can be reduced, and the response speed and the stability of questionnaire display are improved.
Additional features and advantages of the disclosure will be set forth in the detailed description which follows.
Drawings
The accompanying drawings, which are included to provide a further understanding of the disclosure and are incorporated in and constitute a part of this specification, illustrate embodiments of the disclosure and together with the description serve to explain the disclosure without limiting the disclosure. In the drawings:
FIG. 1 is a flow chart illustrating a method of controlling a questionnaire display, according to an exemplary embodiment;
FIG. 2 is a flow chart illustrating another method of controlling the display of a questionnaire, according to an exemplary embodiment;
FIG. 3 is a flow chart illustrating another method of controlling the display of a questionnaire, according to an exemplary embodiment;
FIG. 4 is a flow chart illustrating another method of controlling the display of a questionnaire, according to an exemplary embodiment;
FIG. 5 is a block diagram illustrating a control device for a questionnaire display in accordance with an exemplary embodiment;
FIG. 6 is a block diagram illustrating another control device for a questionnaire display in accordance with an exemplary embodiment;
FIG. 7 is a block diagram illustrating another control device for a questionnaire display in accordance with an exemplary embodiment;
FIG. 8 is a block diagram illustrating another control device for a questionnaire display in accordance with an exemplary embodiment;
FIG. 9 is a block diagram illustrating an electronic device in accordance with an example embodiment.
Detailed Description
Reference will now be made in detail to the exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, like numbers in different drawings represent the same or similar elements unless otherwise indicated. The implementations described in the exemplary embodiments below are not intended to represent all implementations consistent with the present disclosure. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the present disclosure, as detailed in the appended claims.
Before introducing the control method, device, storage medium and electronic device for displaying questionnaires provided by the present disclosure, an application scenario related to each embodiment in the present disclosure is first introduced, where the application scenario is that a user acquires a questionnaire through a display interface of a terminal, and can perform a specified operation on the display interface to select any option of any topic currently displayed on the display interface in the questionnaire. The terminal can be a mobile terminal with a display interface, such as a smart phone, a tablet computer, a smart television, a smart watch, a PDA (personal digital Assistant, chinese), a portable computer, or a fixed terminal such as a desktop computer.
Fig. 1 is a flowchart illustrating a method of controlling a questionnaire display according to an exemplary embodiment, as shown in fig. 1, the method including:
step 101, a first selection instruction corresponding to a first topic is obtained, where the first selection instruction is used to indicate that a first option in the first topic has been selected, the first topic is any topic currently displayed in a questionnaire, and the first option is any option of the first topic.
For example, a user fills out a questionnaire through a terminal, wherein the questionnaire may include a plurality of topics, and each topic may include a plurality of options. On a display interface of the terminal, the number of currently displayed topics may be all the topics in the questionnaire, or may be a part of the topics in the questionnaire. The method includes the steps that a first selection instruction issued by a user is obtained, the first selection instruction can indicate that a first option in a first topic is selected, for example, the user can perform specified operation (for example, clicking, double-clicking, long-pressing and the like) in an area displayed by a display interface corresponding to the first option of the first topic to send out the first selection instruction, wherein the first topic is any topic currently displayed in a questionnaire, and the first option is any option of the first topic. It should be noted that before any selection instruction sent by the user is acquired, an initial topic may be displayed on the display interface, where the initial topic is a topic that needs to be displayed when the questionnaire is not acquired, and it can be understood that the state of the initial topic is a normally displayed state, and no matter whether the user selects any option in any topic, the initial topic is always displayed on the display interface (that is, every user who fills in the questionnaire needs to fill in the topic), and the number of the initial topics may be one or multiple.
Step 102, according to the first selection instruction and the logic attribute of the first title, determining a second title bound with the first option and a first display strategy of the second title, wherein the logic attribute comprises a binding relationship corresponding to each option of the first title, the binding relationship corresponding to any option comprises a target title bound with any option, and the display strategy of the target title when any option is selected.
For example, in the process of designing a questionnaire, in order to make a question more targeted, a plurality of jump logics are usually included, so that different groups (groups selecting different options) can answer different questions, that is, different options in one topic can be jumped to different topics. Thus, the jump logic can be assigned to each topic in the questionnaire as a logical attribute (i.e., an attribute is extended for each topic in the questionnaire). The logical attribute includes a binding relationship corresponding to each option in the first topic, the binding relationship corresponding to any option includes a target topic bound with any option, and a display policy of the target topic when any option is selected, where the display policy may include: display and hide (e.g., different display strategies may be represented by "0" and "1" in a binding relationship, respectively). After the first selection instruction is obtained in step 101, according to a first option indicated by the first selection instruction, a binding relationship matching the first option is searched in the logic attribute of the first topic, so as to determine a second topic bound to the first option and a first display policy of the second topic. For example: the questionnaire includes topic 1 (including options a and B), topic 2, and topic 3, and the skip logic may include: when the option a of the title 1 is selected, the title 2 is displayed and the title 3 is hidden, and when the option B of the title 1 is selected, the title 2 is hidden and the title 3 is displayed. Then the logical property corresponding to topic 1 can include four binding relationships: the binding relationship a includes: the option A is bound with the topic 2, the display strategy of the topic 2 is display when the option A is selected, and the binding relationship b comprises the following steps: the option A is bound with the topic 3, the display strategy of the topic 3 is hidden when the option A is selected, and the binding relationship c comprises: the option B is bound with the topic 2, the display strategy of the topic 2 is hidden when the option B is selected, and the binding relationship d comprises: the option B is bound with the title 3, and the display strategy of the title 3 is display when the option B is selected.
And 103, controlling the rendering operation of the HTML element corresponding to the second title according to the first display strategy.
Illustratively, according to the first display policy determined in step 102, the rendering operation of an HTML (english: Hyper Text Markup Language) element (e.g., a paragraph mark, a document mark, etc.) corresponding to the second topic is controlled, so as to achieve the purpose of controlling the second topic to be displayed or hidden on the display interface.
In summary, the present disclosure first obtains a first selection instruction corresponding to a first topic and used for indicating that a first option in the first topic is selected, where the first topic is any topic currently displayed in a questionnaire, then determines, according to the first selection instruction and a logical attribute of the first topic, a second topic bound to the first option and a first display policy corresponding to the second topic, where the logical attribute includes a binding relationship corresponding to each option in the first topic, each binding relationship includes a target topic bound to an option, and when the option is selected, a display policy of the target topic, and finally, controls a rendering operation on an HTML element corresponding to the second topic according to the first display policy. The operation of monitoring a large number of codes and inquiring document elements can be reduced, and the response speed and the stability of questionnaire display are improved.
Fig. 2 is a flowchart illustrating another method for controlling a questionnaire display according to an exemplary embodiment, and as shown in fig. 2, step 103 may include the following two implementations:
and step 1031, when the first display strategy is display, rendering the second theme according to the HTML element corresponding to the second theme so as to display the second theme.
Step 1032, when the first display policy is hidden, the HTML element corresponding to the second topic is hidden.
For example, the display policy indicated in the binding relationship may be divided into two types, i.e., display and hide, and when the first display policy is display, the second theme is rendered according to the HTML element corresponding to the second theme, so as to display the second theme on the display interface. And when the first display strategy is hidden, hiding the HTML element corresponding to the second title. For example, topic 1 includes two options: "Yes" and "No", the logical property of topic 1 includes two binding relationships: the option 'yes' is bound with the topic 2, and when the option 'yes' is selected, the first display strategy of the topic 2 is display; the option "no" is bound to topic 2, and the first display strategy of topic 2 is hidden when the option "no" is selected. Then, when the user selects the option "yes," title 2 is rendered according to the HTML element corresponding to title 2 to display title 2. When the user selects the option "no", the HTML element corresponding to title 2 is hidden. When the user selects the option of the topic 1, the user can regret, that is, the user selects the option "yes", step 101 to step 103 are executed, the topic 2 is displayed on the display interface, and then the user needs to reselect the option "no" after consideration, then in the process of reselecting, a new first selection instruction corresponding to the topic 1 is acquired (that is, the first selection instruction indicates that the option "no" in the topic 1 is selected), and step 101 to step 103 are executed again, so as to hide the topic 2.
Fig. 3 is a flowchart illustrating another method for controlling questionnaire display according to an exemplary embodiment, where as shown in fig. 3, a binding relationship corresponding to any option in a logical attribute includes an option identification number of any option. Step 102 may be implemented by:
step 1021, acquiring a first option identification number of the first option according to the first selection instruction.
Step 1022, determining a first binding relationship in the logical attribute of the first topic according to the first option identification number, where the first binding relationship is a binding relationship in which the logical attribute includes the first option identification number.
And 1023, determining the second topic and a first display strategy of the second topic according to the first binding relationship.
For example, each binding relationship in the logical attribute includes an option identification number corresponding to an option to which the binding relationship belongs. The option identification number can uniquely identify each option of each question in the questionnaire (that is, the option identification number corresponding to each option of each question in the questionnaire is different), and for example, the option identification number may be generated by using a Hash (english: Hash) algorithm. After the first selection instruction is obtained, first, according to the first option indicated by the first selection instruction, a first option identification number corresponding to the first option is determined, then, according to the first option identification number, a first binding relationship containing the first option identification number is searched in the logic attribute of the first question, and finally, according to the first binding relationship, a first display strategy of the second question and the second question is determined.
Fig. 4 is a flowchart illustrating another method of controlling a questionnaire display according to an exemplary embodiment, as shown in fig. 4, after step 103, the method further comprising:
and 104, determining whether a third topic with a second binding relationship in the logical attribute exists, wherein the second binding relationship is the binding relationship including the second topic.
And 105, when a third topic exists, acquiring a second selection instruction corresponding to the third topic, where the second selection instruction is used to indicate that a second option indicated by a second binding relationship in the third topic has been selected.
For example, after controlling the rendering operation for the second topic in step 103, it is searched in the questionnaire whether there are other logical attributes of topics than the first topic that include the second binding relationship, and these topics are regarded as a third topic (which may be one or more), where the second binding relationship is a binding relationship that includes the second topic. When a third topic exists, a status notification can be sent to the third topic to notify the third topic of the current first display strategy of the second topic. And then, acquiring a second selection instruction corresponding to the third topic issued by the user, where the second selection instruction can indicate that the second option in the third topic is selected, for example, the user can perform a specified operation (for example, clicking, double-clicking, long-pressing, and the like) in an area displayed by the second option corresponding to the third topic on the display interface to send out the second selection instruction, where the second option is an option indicated by the second binding relationship.
And 106, when the second display strategy of the second topic indicated by the second binding relationship is the same as the first display strategy, maintaining the HTML element corresponding to the second topic.
And step 107, when the second display strategy of the second topic indicated by the second binding relationship is different from the first display strategy, controlling the rendering operation of the HTML element corresponding to the second topic according to the second display strategy.
By way of example, the second display policy of the second topic indicated in the second binding relationship is compared with the first display policy indicated in the status notification received by the third topic, and if the first display policy and the second display policy are the same, the status (displayed or hidden) of the second topic does not need to be changed, that is, the HTML element corresponding to the second topic is maintained, rendering of the HTML element corresponding to the second topic can be reduced, and response speed and stability of questionnaire display are further improved. And if the first display strategy is different from the second display strategy, the state of the second theme needs to be changed, and the rendering operation of the HTML element corresponding to the second theme is controlled according to the second display strategy.
For example, the questionnaire includes topic 1 (including options a and B), topic 2 (including options C and D), topic 3, and topic 4, and the logical attributes corresponding to topic 1 include: binding relationship a: the option A is bound with the title 3, the display strategy of the title 3 is display when the option A is selected, and the binding relationship b: the option B is bound with the title 4, and the display strategy of the title 4 is display when the option B is selected. The logical attributes corresponding to topic 2 include: binding relationship c: the option C is bound with the title 3, the display strategy of the title 3 is display when the option C is selected, and the binding relationship d: the option D is bound with the title 4, and the display strategy of the title 4 is hidden when the option D is selected. When the user selects the option A in the topic 1, determining the display strategy (corresponding to the first display strategy) of the topic 3 as display according to the binding relation a, and then when the user selects the option C in the topic 2 again, determining the display strategy (corresponding to the second display strategy) of the topic 3 as display according to the binding relation C, wherein the first display strategy is the same as the second display strategy, and then keeping the HTML element corresponding to the topic 3 without re-rendering. If the user selects the option B in the topic 1, the display strategy (corresponding to the first display strategy) of the topic 4 is determined to be display according to the binding relation B, and then when the user selects the option D in the topic 2 again, the display strategy (corresponding to the second display strategy) of the topic 4 is determined to be hidden according to the binding relation D, at the moment, the first display strategy is different from the second display strategy, the rendering operation of the HTML element corresponding to the topic 4 is controlled according to the second display strategy, namely the HTML element corresponding to the topic 4 is hidden.
It should be noted that, in the foregoing embodiment, the logical attribute of the fourth topic may be an HTML element corresponding to the fourth topic (for example, the logical attribute may be in a Variable Logic form), that is, the logical attribute of the fourth topic is stored in the HTML element corresponding to the fourth topic, so that a storage space of a background database corresponding to a questionnaire is not required to be occupied, where the fourth topic is any topic in the questionnaire.
In summary, the present disclosure first obtains a first selection instruction corresponding to a first topic and used for indicating that a first option in the first topic is selected, where the first topic is any topic currently displayed in a questionnaire, then determines, according to the first selection instruction and a logical attribute of the first topic, a second topic bound to the first option and a first display policy corresponding to the second topic, where the logical attribute includes a binding relationship corresponding to each option in the first topic, each binding relationship includes a target topic bound to an option, and when the option is selected, a display policy of the target topic, and finally, controls a rendering operation on an HTML element corresponding to the second topic according to the first display policy. The operation of monitoring a large number of codes and inquiring document elements can be reduced, and the response speed and the stability of questionnaire display are improved.
Fig. 5 is a block diagram illustrating a control apparatus for questionnaire display according to an exemplary embodiment, and as shown in fig. 5, the apparatus 200 includes:
the first obtaining module 201 is configured to obtain a first selection instruction corresponding to a first topic, where the first selection instruction is used to indicate that a first option in the first topic is selected, the first topic is any topic currently displayed in a questionnaire, and the first option is any option of the first topic.
The first determining module 202 is configured to determine, according to the first selection instruction and a logical attribute of the first topic, a second topic bound to the first option and a first display policy of the second topic, where the logical attribute includes a binding relationship corresponding to each option of the first topic, and a binding relationship corresponding to any option includes a target topic bound to any option and a display policy of the target topic when any option is selected.
And the control module 203 is configured to control rendering operation on an HTML element corresponding to the second topic according to the first display policy.
Fig. 6 is a block diagram illustrating another control apparatus for questionnaire display according to an exemplary embodiment, and as shown in fig. 6, the control module 203 includes:
the first control sub-module 2031 is configured to, when the first display policy is display, render the second theme according to the HTML element corresponding to the second theme, so as to display the second theme.
The second control sub-module 2032 is configured to hide the HTML element corresponding to the second question when the first display policy is hiding.
Fig. 7 is a block diagram of another control apparatus for questionnaire display according to an exemplary embodiment, where as shown in fig. 7, a binding relationship corresponding to any option in a logical attribute includes an option identification number of any option. The first determination module 202 includes:
the obtaining sub-module 2021 is configured to obtain a first option identification number of the first option according to the first selection instruction.
The first determining sub-module 2022 is configured to determine, according to the first option identification number, a first binding relationship in the logical attribute of the first question, where the first binding relationship is a binding relationship in which the logical attribute includes the first option identification number.
The second determining sub-module 2023 is configured to determine the second topic and the first display policy of the second topic according to the first binding relationship.
Fig. 8 is a block diagram illustrating another control apparatus for questionnaire display according to an exemplary embodiment, and as shown in fig. 8, the apparatus 200 further includes:
the second determining module 204 is configured to determine whether a third topic including a second binding relationship in the logical attribute exists after controlling a rendering operation on an HTML element corresponding to the second topic according to the first display policy, where the second binding relationship is a binding relationship including the second topic.
The second obtaining module 205 is configured to obtain a second selection instruction corresponding to the third topic when the third topic exists, where the second selection instruction is used to indicate that a second option indicated by the second binding relationship in the third topic is selected.
The control module 203 is further configured to, when a second display policy of the second topic indicated by the second binding relationship is the same as the first display policy, maintain the HTML element corresponding to the second topic.
The control module 203 is further configured to control rendering operation on an HTML element corresponding to the second topic according to the second display policy when the second display policy of the second topic indicated by the second binding relationship is different from the first display policy.
Optionally, the logic attribute of the fourth topic is stored in an HTML element corresponding to the fourth topic, and the fourth topic is any topic in the questionnaire.
With regard to the apparatus in the above-described embodiment, the specific manner in which each module performs the operation has been described in detail in the embodiment related to the method, and will not be elaborated here.
In summary, the present disclosure first obtains a first selection instruction corresponding to a first topic and used for indicating that a first option in the first topic is selected, where the first topic is any topic currently displayed in a questionnaire, then determines, according to the first selection instruction and a logical attribute of the first topic, a second topic bound to the first option and a first display policy corresponding to the second topic, where the logical attribute includes a binding relationship corresponding to each option in the first topic, each binding relationship includes a target topic bound to an option, and when the option is selected, a display policy of the target topic, and finally, controls a rendering operation on an HTML element corresponding to the second topic according to the first display policy. The operation of monitoring a large number of codes and inquiring document elements can be reduced, and the response speed and the stability of questionnaire display are improved.
Fig. 9 is a block diagram illustrating an electronic device 300 in accordance with an example embodiment. As shown in fig. 9, the electronic device 300 may include: a processor 301 and a memory 302. The electronic device 300 may also include one or more of a multimedia component 303, an input/output (I/O) interface 304, and a communication component 305.
The processor 301 is configured to control the overall operation of the electronic device 300, so as to complete all or part of the steps in the above method for controlling the questionnaire display. The memory 302 is used to store various types of data to support operation at the electronic device 300, such as instructions for any application or method operating on the electronic device 300 and application-related data, such as contact data, transmitted and received messages, pictures, audio, video, and the like. The Memory 302 may be implemented by any type of volatile or non-volatile Memory device or combination thereof, such as Static Random Access Memory (SRAM), Electrically Erasable Programmable Read-Only Memory (EEPROM), Erasable Programmable Read-Only Memory (EPROM), Programmable Read-Only Memory (PROM), Read-Only Memory (ROM), magnetic Memory, flash Memory, magnetic disk or optical disk. The multimedia components 303 may include a screen and an audio component. Wherein the screen may be, for example, a touch screen and the audio component is used for outputting and/or inputting audio signals. For example, the audio component may include a microphone for receiving external audio signals. The received audio signal may further be stored in the memory 302 or transmitted through the communication component 305. The audio assembly also includes at least one speaker for outputting audio signals. The I/O interface 304 provides an interface between the processor 301 and other interface modules, such as a keyboard, mouse, buttons, etc. These buttons may be virtual buttons or physical buttons. The communication component 305 is used for wired or wireless communication between the electronic device 300 and other devices. Wireless Communication, such as Wi-Fi, bluetooth, Near Field Communication (NFC), 2G, 3G or 4G, or a combination of one or more of them, so that the corresponding Communication component 305 may include: Wi-Fi module, bluetooth module, NFC module.
In an exemplary embodiment, the electronic Device 300 may be implemented by one or more Application Specific Integrated Circuits (ASICs), Digital Signal Processors (DSPs), Digital Signal Processing Devices (DSPDs), Programmable Logic Devices (PLDs), Field Programmable Gate Arrays (FPGAs), controllers, microcontrollers, microprocessors or other electronic components for executing the above-mentioned control method of the questionnaire display.
In another exemplary embodiment, there is also provided a computer-readable storage medium including program instructions which, when executed by a processor, implement the steps of the above-described method of controlling a questionnaire display. For example, the computer readable storage medium may be the memory 302 including program instructions executable by the processor 301 of the electronic device 300 to perform the above-described method of controlling the display of the questionnaire.
In summary, the present disclosure first obtains a first selection instruction corresponding to a first topic and used for indicating that a first option in the first topic is selected, where the first topic is any topic currently displayed in a questionnaire, then determines, according to the first selection instruction and a logical attribute of the first topic, a second topic bound to the first option and a first display policy corresponding to the second topic, where the logical attribute includes a binding relationship corresponding to each option in the first topic, each binding relationship includes a target topic bound to an option, and when the option is selected, a display policy of the target topic, and finally, controls a rendering operation on an HTML element corresponding to the second topic according to the first display policy. The operation of monitoring a large number of codes and inquiring document elements can be reduced, and the response speed and the stability of questionnaire display are improved.
Preferred embodiments of the present disclosure are described in detail above with reference to the accompanying drawings, however, the present disclosure is not limited to the specific details of the above embodiments, and other embodiments of the present disclosure may be easily conceived by those skilled in the art within the technical spirit of the present disclosure after considering the description and practicing the present disclosure, and all fall within the protection scope of the present disclosure.
It should be noted that the various features described in the above embodiments may be combined in any suitable manner without departing from the scope of the invention. Meanwhile, any combination can be made between various different embodiments of the disclosure, and the disclosure should be regarded as the disclosure of the disclosure as long as the combination does not depart from the idea of the disclosure. The present disclosure is not limited to the precise structures that have been described above, and the scope of the present disclosure is limited only by the appended claims.

Claims (7)

1. A method for controlling display of a questionnaire, the method comprising:
acquiring a first selection instruction corresponding to a first topic, wherein the first selection instruction is used for indicating that a first option in the first topic is selected, the first topic is any one currently displayed topic in a questionnaire, and the first option is any one option of the first topic;
determining a second topic bound with the first option and a first display strategy of the second topic according to the first selection instruction and a logic attribute of the first topic, wherein the logic attribute comprises a binding relationship corresponding to each option of the first topic, the binding relationship corresponding to any option comprises a target topic bound with any option, and the display strategy of the target topic when any option is selected;
controlling rendering operation of an HTML element corresponding to the second title according to the first display strategy;
determining whether a third topic comprising a second binding relationship exists in a logic attribute, wherein the second binding relationship is the binding relationship comprising the second topic;
when the third topic exists, a second selection instruction corresponding to the third topic is obtained, and the second selection instruction is used for indicating that a second option indicated by the second binding relationship in the third topic is selected;
when a second display strategy of the second topic indicated by the second binding relationship is the same as the first display strategy, maintaining an HTML element corresponding to the second topic;
when a second display strategy of the second topic indicated by the second binding relationship is different from the first display strategy, controlling rendering operation of an HTML element corresponding to the second topic according to the second display strategy;
the logical attribute of the fourth topic is stored in an HTML element corresponding to the fourth topic in a Variable Logic form, and the fourth topic is any topic in the questionnaire.
2. The method according to claim 1, wherein the controlling the HTML element corresponding to the second topic according to the first display policy comprises:
when the first display strategy is display, rendering the second theme according to an HTML element corresponding to the second theme so as to display the second theme;
and when the first display strategy is hidden, hiding the HTML element corresponding to the second theme.
3. The method according to claim 1, wherein the binding relationship corresponding to any option in the logical attribute includes an option identification number of the any option; the determining, according to the first selection instruction and the logical property of the first topic, a second topic bound to the first option and a first display policy of the second topic includes:
acquiring a first option identification number of the first option according to the first selection instruction;
determining a first binding relationship in the logical attribute of the first topic according to the first option identification number, wherein the first binding relationship is the binding relationship of the logical attribute including the first option identification number;
and determining the second theme and the first display strategy of the second theme according to the first binding relationship.
4. A device for controlling questionnaire display, the device comprising:
a first obtaining module, configured to obtain a first selection instruction corresponding to a first topic, where the first selection instruction is used to indicate that a first option in the first topic is selected, the first topic is any currently displayed topic in a questionnaire, and the first option is any option of the first topic;
a first determining module, configured to determine, according to the first selection instruction and a logical attribute of the first topic, a second topic bound to the first option and a first display policy of the second topic, where the logical attribute includes a binding relationship corresponding to each option of the first topic, the binding relationship corresponding to any option includes a target topic bound to the any option, and the display policy of the target topic when the any option is selected;
the control module is used for controlling the rendering operation of the HTML element corresponding to the second question according to the first display strategy;
a second determining module, configured to determine whether a third topic with a logical attribute including a second binding relationship exists after controlling a rendering operation on an HTML element corresponding to the second topic according to the first display policy, where the second binding relationship is a binding relationship including the second topic;
a second obtaining module, configured to obtain, when the third topic exists, a second selection instruction corresponding to the third topic, where the second selection instruction is used to indicate that a second option indicated by the second binding relationship has been selected in the third topic;
the control module is further configured to, when a second display policy of the second topic indicated by the second binding relationship is the same as the first display policy, maintain an HTML element corresponding to the second topic;
the control module is further configured to control rendering operation of an HTML element corresponding to the second topic according to the second display policy when the second display policy of the second topic indicated by the second binding relationship is different from the first display policy;
the logical attribute of the fourth topic is stored in an HTML element corresponding to the fourth topic in a Variable Logic form, and the fourth topic is any topic in the questionnaire.
5. The apparatus according to claim 4, wherein the binding relationship corresponding to any option in the logical attribute includes an option identification number of the any option;
the first determining module includes:
the obtaining submodule is used for obtaining a first option identification number of the first option according to the first selection instruction;
a first determining submodule, configured to determine a first binding relationship in the logical attribute of the first question according to the first option identification number, where the first binding relationship is a binding relationship in the logical attribute that includes the first option identification number;
and the second determining submodule is used for determining the second theme and the first display strategy of the second theme according to the first binding relationship.
6. A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the steps of the method according to any one of claims 1 to 3.
7. An electronic device, comprising:
a memory having a computer program stored thereon;
a processor for executing the computer program in the memory to carry out the steps of the method of any one of claims 1 to 3.
CN201811489975.XA 2018-12-06 2018-12-06 Questionnaire display control method and device, storage medium and electronic equipment Active CN109753612B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811489975.XA CN109753612B (en) 2018-12-06 2018-12-06 Questionnaire display control method and device, storage medium and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811489975.XA CN109753612B (en) 2018-12-06 2018-12-06 Questionnaire display control method and device, storage medium and electronic equipment

Publications (2)

Publication Number Publication Date
CN109753612A CN109753612A (en) 2019-05-14
CN109753612B true CN109753612B (en) 2021-05-04

Family

ID=66402649

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811489975.XA Active CN109753612B (en) 2018-12-06 2018-12-06 Questionnaire display control method and device, storage medium and electronic equipment

Country Status (1)

Country Link
CN (1) CN109753612B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111785336A (en) * 2020-07-01 2020-10-16 山东维艾亚生物科技有限公司 Detection information processing method and device based on user assistance, and medium
CN111859869B (en) * 2020-07-13 2023-06-16 米哈游科技(上海)有限公司 Questionnaire editing method and device, electronic equipment and storage medium

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2012174659A1 (en) * 2011-06-20 2012-12-27 Novx Systems Canada Inc. System and method for dynamic and customized questionnaire generation
CN104699973A (en) * 2015-03-19 2015-06-10 腾讯科技(深圳)有限公司 Method and device for controlling logic of questionnaires
CN105824918A (en) * 2016-03-16 2016-08-03 平安科技(深圳)有限公司 Method for generating questionnaire and terminal

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105068980A (en) * 2015-08-07 2015-11-18 北京思特奇信息技术股份有限公司 Graphical display method and system for jump relationship among topics
CN105824887A (en) * 2016-03-11 2016-08-03 深圳市规划国土发展研究中心 Mobile electronic investigation system and method based on intelligent questionnaire generative design

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2012174659A1 (en) * 2011-06-20 2012-12-27 Novx Systems Canada Inc. System and method for dynamic and customized questionnaire generation
CN104699973A (en) * 2015-03-19 2015-06-10 腾讯科技(深圳)有限公司 Method and device for controlling logic of questionnaires
CN105824918A (en) * 2016-03-16 2016-08-03 平安科技(深圳)有限公司 Method for generating questionnaire and terminal

Also Published As

Publication number Publication date
CN109753612A (en) 2019-05-14

Similar Documents

Publication Publication Date Title
US11379108B2 (en) Display controlling method, terminal, information processing apparatus, and storage medium
KR101390228B1 (en) Device and method of displaying image on chat area, and server for managing chat data
KR102021317B1 (en) Custom optimization of web pages
RU2645276C2 (en) Creation of variations when converting data to consumer content
US11151212B2 (en) Information analysis method, electronic device, and storage medium
US20200073903A1 (en) Method and device of tagging links included in a screenshot of webpage
CN109831532B (en) Data sharing method, device, equipment and medium
CN104781776A (en) Apparatus and method for dynamic actions based on context
US11360640B2 (en) Method, device and browser for presenting recommended news, and electronic device
US20110252022A1 (en) Dynamic generation of relevant items
CN113253880B (en) Method and device for processing pages of interaction scene and storage medium
US20140258846A1 (en) Method and apparatus for controlling page switching capacity
US20120191756A1 (en) Terminal having searching function and method for searching using data saved in clipboard
CN109753612B (en) Questionnaire display control method and device, storage medium and electronic equipment
KR20110127584A (en) A system for collecting other web's contents by wysiwyg method and method for the same
US11928172B2 (en) Systems and methods for a web browser for use in handheld wireless devices that renders web pages without advertisement
JP2018508061A (en) Adaptive electronic documents
CN112711731A (en) Data point burying method, device, equipment and storage medium
CN114239524A (en) Questionnaire generation method, questionnaire generation device, computer equipment and storage medium
CN107431732B (en) Computer-implemented method, system for providing scanning options and storage medium
CN111782915B (en) Information display method and device, electronic equipment and medium
CN113988009A (en) Information delivery area generation method, information delivery method, electronic device and storage medium
US9465515B2 (en) Graphical user interface for mobile presentation application
CN112433723A (en) Personalized list development method and device
CN111880698A (en) Information processing method and device of intelligent terminal, electronic equipment and storage medium

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
GR01 Patent grant
GR01 Patent grant