[go: up one dir, main page]

CN107346347B - Webpage table display method and device - Google Patents

Webpage table display method and device Download PDF

Info

Publication number
CN107346347B
CN107346347B CN201710821364.XA CN201710821364A CN107346347B CN 107346347 B CN107346347 B CN 107346347B CN 201710821364 A CN201710821364 A CN 201710821364A CN 107346347 B CN107346347 B CN 107346347B
Authority
CN
China
Prior art keywords
column
information
columns
visual attribute
web page
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
CN201710821364.XA
Other languages
Chinese (zh)
Other versions
CN107346347A (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.)
Guangzhou Kugou Computer Technology Co Ltd
Original Assignee
Guangzhou Kugou Computer Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Guangzhou Kugou Computer Technology Co Ltd filed Critical Guangzhou Kugou Computer Technology Co Ltd
Priority to CN201710821364.XA priority Critical patent/CN107346347B/en
Publication of CN107346347A publication Critical patent/CN107346347A/en
Application granted granted Critical
Publication of CN107346347B publication Critical patent/CN107346347B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/957Browsing optimisation, e.g. caching or content distillation
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/958Organisation or management of web site content, e.g. publishing, maintaining pages or automatic linking

Landscapes

  • Engineering & Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Transfer Between Computers (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

The invention discloses a webpage table display method and device, and belongs to the technical field of networks. The method comprises the following steps: receiving first column information of a web page table; acquiring second column information of the webpage table; determining the visual attribute value of the column in the second column of information according to the version number of the server side in the same column in the first column of information and the second column of information; and displaying the columns in the web page table according to the visual attribute values of all the columns in the second column information. According to the method and the device, even if the server modifies the visual attribute values of the columns in the webpage table, the terminal can reset the visual attribute values of the columns according to the currently received first column information and the locally stored second column information, for example, the visual attribute values of the columns in the second column information are set as the visual attribute values of the columns in the first column information, so that the visual attribute values of the columns in the webpage table are synchronized between the terminal and the server.

Description

Webpage table display method and device
Technical Field
The invention relates to the technical field of networks, in particular to a method and a device for displaying a webpage table.
Background
With the development of network technology, the application of web forms has become very popular. The traditional webpage table displays data in the same table form for different users, but because different users have different concerns about the table data, some users may only concern about data of one or more columns in the table, and the display of data of other columns causes certain interference to the browsing of the users, so that a webpage table display method is urgently needed, so that the users can define the display columns of the webpage table according to their own needs.
At present, a user can perform a check or cancel check operation on a column in the web page table, a terminal can store the column checked or canceled by the user, and use the column checked by the user as a display column of the web page table, for example, if a visual attribute value of the column checked by the user is set to true, and a visual attribute value of the column canceled by the user is set to false, the terminal can display the column with the visual attribute value of true in the web page table, that is, the column checked by the user is displayed in the web page table, and the column canceled by the user is not displayed, so that an effect of customizing the display column of the web page table by the user is achieved.
In the process of implementing the invention, the inventor finds that the prior art has at least the following problems:
in the prior art, in the process of self-defining a web page table display column, a visual attribute value of a column is set by checking or canceling the check of the column in the web page table by a user, even if a server modifies the visual attribute value of the column in the web page table, if the user does not perform check operation or cancel the check operation on the column, a terminal still keeps the visual attribute value of the column unchanged, so that synchronization of the visual attribute values of the column in the web page table cannot be realized between the terminal and the server.
Disclosure of Invention
The embodiment of the invention provides a method and a device for displaying a webpage table, which can solve the problem that the prior art cannot realize the synchronization of visual attribute values of columns in the webpage table. The technical scheme is as follows:
in a first aspect, a web page table display method is provided, including:
receiving first column information of a web page table, wherein the first column information comprises visual attribute values of all columns in the web page table stored by a server and a server version number, and the server version number is used for indicating the server to modify the visual attribute values of the columns;
acquiring second column information of the webpage table, wherein the second column information comprises visual attribute values and server version numbers of all columns in the webpage table locally stored by the terminal;
determining the visual attribute value of the column in the second column of information according to the version number of the server side in the same column in the first column of information and the second column of information;
and displaying the columns in the web page table according to the visual attribute values of all the columns in the second column information.
In a first implementation manner of the first aspect, the obtaining the second column of information of the web page table includes:
and acquiring the second column information of the webpage table from a local storage LocalStorage.
In a second implementation manner of the first aspect, the second column information further includes local version numbers of all columns in the web page table stored locally by the terminal, where the local version numbers are used to indicate modifications performed by the terminal on visual attribute values of the columns;
the determining the visual attribute value of the column in the second column of information according to the server version number of the same column in the first column of information and the second column of information includes:
when the server version numbers of the columns in the first column information and the second column information are the same, determining the visual attribute values of the columns in the second column information according to the visual attribute values of the columns in the first column information and the second column information and the local version numbers of the columns in the second column information;
when the server version numbers of the columns in the first column information and the second column information are different, setting the visual attribute values of the columns in the second column information as the visual attribute values of the columns in the first column information.
In a third implementation manner of the first aspect, the determining, according to the visual attribute values of the columns in the first column information and the second column information and the local version numbers of the columns in the second column information, the visual attribute values of the columns in the second column information includes:
when the visual attribute values of the columns in the first column information and the second column information are different and the local version number of the columns in the second column information is equal to a specified numerical value, setting the visual attribute values of the columns in the second column information as the visual attribute values of the columns in the first column information;
when the visualization attribute values of the columns in the first column of information and the second column of information are the same, or the visualization attribute values of the columns in the first column of information and the second column of information are different and the local version number of the columns in the second column of information is greater than a specified value, keeping the visualization attribute values of the columns in the second column of information unchanged.
In a fourth implementation manner of the first aspect, after displaying the columns in the web page table according to the visual attribute values of all the columns in the second column information, the method further includes:
when a modification instruction for the visualization attribute value of any column in the web page table is received, modifying the visualization attribute value of any column in the second column information.
In a fifth implementation manner of the first aspect, the modifying, when a modification instruction for any column in the web page table is received, the modifying, of the visualization attribute value of any column in the second column information, includes:
when a display instruction for any column is received, setting a visual attribute value of the any column in the second column information as a first attribute value, wherein the first attribute value indicates that the column is visible;
and when a cancel display instruction of any column is received, setting the visual attribute value of the any column in the second column of information as a second attribute value, wherein the second attribute value indicates that the column is invisible.
In a sixth implementation manner of the first aspect, after the obtaining the second column information of the web page table, the method further includes:
when the number of columns in the first column information is larger than that in the second column information, determining a first target column in the first column information, wherein the column information of the first target column is not included in the second column information;
adding the column information of the first target column to the second column information.
In a seventh implementation manner of the first aspect, after the obtaining the second column information of the web page table, the method further includes:
when the number of columns in the first column information is smaller than that in the second column information, determining a second target column in the first column information, wherein the column information of the second target column is not included in the first column information;
deleting the column information of the second target column from the second column information.
In a second aspect, there is provided a web page form display apparatus including:
the system comprises a receiving module, a processing module and a display module, wherein the receiving module is used for receiving first column information of a web page table, the first column information comprises visual attribute values of all columns in the web page table stored by a server and a server version number, and the server version number is used for indicating the server to modify the visual attribute values of the columns;
the acquisition module is used for acquiring second column information of the webpage table, wherein the second column information comprises visual attribute values and server version numbers of all columns in the webpage table, which are locally stored by the terminal;
a determining module, configured to determine a visual attribute value of a column in the second column of information according to a server version number of a same column in the first column of information and the second column of information;
and the display module is used for displaying the columns in the web page table according to the visual attribute values of all the columns in the second column information.
In a first implementation manner of the second aspect, the obtaining module is configured to obtain the second column information of the web page table from a local storage.
In a second implementation manner of the second aspect, the second column information further includes a local version number of all columns in the web page table stored locally by the terminal, where the local version number is used to indicate that the terminal modifies visual attribute values of the columns;
the determining module is configured to determine, when server version numbers of the columns in the first column of information and the second column of information are the same, a visual attribute value of the column in the second column of information according to a visual attribute value of the column in the first column of information and the second column of information and a local version number of the column in the second column of information; when the server version numbers of the columns in the first column information and the second column information are different, setting the visual attribute values of the columns in the second column information as the visual attribute values of the columns in the first column information.
In a third implementation manner of the second aspect, the determining module is configured to set the visualization attribute value of the column in the second column information to the visualization attribute value of the column in the first column information when the visualization attribute values of the columns in the first column information and the second column information are different and the local version number of the column in the second column information is equal to a specified value; when the visualization attribute values of the columns in the first column of information and the second column of information are the same, or the visualization attribute values of the columns in the first column of information and the second column of information are different and the local version number of the columns in the second column of information is greater than a specified value, keeping the visualization attribute values of the columns in the second column of information unchanged.
In a fourth implementation form of the second aspect, the apparatus further comprises:
and the modification module is used for modifying the visual attribute value of any column in the second column of information when a modification instruction of the visual attribute value of any column in the webpage table is received.
In a fifth implementation manner of the second aspect, the modifying module is configured to, when a display instruction for the any column is received, set a visualization attribute value of the any column in the second column information to a first attribute value, where the first attribute value indicates that the column is visible; and when a cancel display instruction of any column is received, setting the visual attribute value of the any column in the second column of information as a second attribute value, wherein the second attribute value indicates that the column is invisible.
In a sixth implementation form of the second aspect, the apparatus further comprises:
the determining module is further configured to determine a first target column in the first column information when the number of columns in the first column information is greater than the number of columns in the second column information, where the column information of the first target column is not included in the second column information;
and the adding module is used for adding the column information of the first target column into the second column information.
In a seventh implementation manner of the second aspect, the determining module is further configured to determine a second target column in the first column information when the number of columns in the first column information is smaller than the number of columns in the second column information, where the column information of the second target column is not included in the first column information;
the adding module is further configured to delete the column information of the second target column from the second column information.
In a third aspect, a terminal is provided that includes a processor and a memory; the memory is used for storing a computer program; the processor is configured to execute the computer program stored in the memory to implement the method steps of any one of the implementation manners of the first aspect.
In a fourth aspect, a computer-readable storage medium is provided, in which a computer program is stored which, when being executed by a processor, carries out the method steps of any of the implementations of the first aspect.
The technical scheme provided by the embodiment of the invention has the following beneficial effects:
after the terminal receives the first column information of the web page table sent by the server, the second column information of the web page table can be obtained from the local storage of the terminal, the visual attribute value of the column in the second column information is re-determined according to the server version number of the same column in the first column information and the second column information, and then the columns in the web page table are displayed according to the visual attribute values of all columns in the re-determined second column information. In the above technical solution, even if the server modifies the visual attribute value of the column in the web page table after the server sends the column information of the web page table to the terminal last time, so that the first column information currently received by the terminal is sent by the server after the visual attribute value of the column in the web page table is modified, the terminal may reset the visual attribute value of the column according to the first column information and the locally stored second column information, for example, the visual attribute value of the column in the second column information is set as the visual attribute value of the column in the first column information, so that synchronization of the visual attribute values of the columns in the web page table is realized between the terminal and the server.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings needed to be used in the description of the embodiments will be briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
Fig. 1 is a flowchart of a method for displaying a web form according to an embodiment of the present invention;
FIG. 2 is a flowchart of a method for displaying a web form according to an embodiment of the present invention;
fig. 3 is a flowchart of a gentle synchronization between a terminal and a server according to an embodiment of the present invention;
fig. 4 is a flowchart of forced synchronization between a terminal and a server according to an embodiment of the present invention;
FIG. 5 is a flowchart illustrating a user customizing a display column at a terminal according to an embodiment of the present invention;
FIG. 6 is a flowchart illustrating a user customizing a display column at a terminal according to an embodiment of the present invention;
fig. 7 is a schematic structural diagram of a web page table display apparatus according to an embodiment of the present invention;
fig. 8 is a schematic structural diagram of a web page table display apparatus according to an embodiment of the present invention;
fig. 9 is a schematic structural diagram of a web page table display apparatus according to an embodiment of the present invention;
fig. 10 is a schematic structural diagram of a terminal 1000 according to an embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, embodiments of the present invention will be described in detail with reference to the accompanying drawings.
Fig. 1 is a flowchart of a method for displaying a web page form according to an embodiment of the present invention. Referring to fig. 1, the method includes:
101. receiving first column information of a web page table, wherein the first column information comprises visualization attribute values of all columns in the web page table stored by a server and a server version number, and the server version number is used for indicating the server to modify the visualization attribute values of the columns.
102. And acquiring second column information of the web page table, wherein the second column information comprises visual attribute values and server version numbers of all columns in the web page table locally stored by the terminal.
103. And determining the visual attribute value of the column in the second column of information according to the server version number of the same column in the first column of information and the second column of information.
104. And displaying the columns in the web page table according to the visual attribute values of all the columns in the second column information.
According to the method provided by the embodiment of the invention, after the terminal receives the first column information of the web page table sent by the server, the second column information of the web page table can be obtained from the local storage of the terminal, the visual attribute value of the column in the second column information is re-determined according to the server version number of the same column in the first column information and the second column information, and then the columns in the web page table are displayed according to the visual attribute values of all columns in the re-determined second column information. In the above technical solution, even if the server modifies the visual attribute value of the column in the web page table after the server sends the column information of the web page table to the terminal last time, so that the first column information currently received by the terminal is sent by the server after the visual attribute value of the column in the web page table is modified, the terminal may reset the visual attribute value of the column according to the first column information and the locally stored second column information, for example, the visual attribute value of the column in the second column information is set as the visual attribute value of the column in the first column information, so that synchronization of the visual attribute values of the columns in the web page table is realized between the terminal and the server.
In one possible implementation, the obtaining the second column information of the web page table includes:
and acquiring the second column information of the web page table from a local storage LocalStorage.
In a possible implementation manner, the second column information further includes a local version number of all columns in the web page table stored locally by the terminal, where the local version number is used to indicate that the terminal modifies visual attribute values of the columns;
the determining the visual attribute value of the column in the second column of information according to the server version number of the same column in the first column of information and the second column of information includes:
when the server version numbers of the columns in the first column of information and the second column of information are the same, determining the visual attribute values of the columns in the second column of information according to the visual attribute values of the columns in the first column of information and the second column of information and the local version numbers of the columns in the second column of information;
and when the server version numbers of the columns in the first column of information and the second column of information are different, setting the visualization attribute value of the column in the second column of information as the visualization attribute value of the column in the first column of information.
In one possible implementation manner, the determining, according to the visual attribute value of the column in the first column of information and the second column of information and the local version number of the column in the second column of information, the visual attribute value of the column in the second column of information includes:
when the visual attribute values of the column in the first column of information and the second column of information are different and the local version number of the column in the second column of information is equal to a specified numerical value, setting the visual attribute value of the column in the second column of information as the visual attribute value of the column in the first column of information;
and when the visual attribute values of the column in the first column of information and the second column of information are the same, or the visual attribute values of the column in the first column of information and the second column of information are different and the local version number of the column in the second column of information is greater than a specified value, keeping the visual attribute value of the column in the second column of information unchanged.
In one possible implementation manner, after displaying the columns in the web page table according to the visual attribute values of all the columns in the second column information, the method further includes:
and when a modification instruction for the visualization attribute value of any column in the web page table is received, modifying the visualization attribute value of any column in the second column information.
In a possible implementation manner, when a modification instruction for any column in the web page table is received, modifying the visual attribute value of the any column in the second column of information includes:
when a display instruction for any column is received, setting the visual attribute value of the any column in the second column information as a first attribute value, wherein the first attribute value indicates that the column is visible;
and when a cancel display instruction of the any column is received, setting the visual attribute value of the any column in the second column information as a second attribute value, wherein the second attribute value indicates that the column is invisible.
In one possible implementation manner, after obtaining the second column information of the web page table, the method further includes:
when the number of columns in the first column of information is larger than that in the second column of information, determining a first target column in the first column of information, wherein the column information of the first target column is not included in the second column of information;
adding the column information of the first target column to the second column information.
In one possible implementation manner, after obtaining the second column information of the web page table, the method further includes:
when the number of columns in the first column of information is less than the number of columns in the second column of information, determining a second target column in the first column of information, wherein the column information of the second target column is not included in the first column of information;
the column information of the second target column is deleted from the second column information.
All the above-mentioned optional technical solutions can be combined arbitrarily to form the optional embodiments of the present invention, and are not described herein again.
Fig. 2 is a flowchart of a method for displaying a web form according to an embodiment of the present invention. The method is performed by a terminal, and referring to fig. 2, the method includes:
201. receiving first column information of a web page table, wherein the first column information comprises visualization attribute values of all columns in the web page table stored by a server and a server version number, and the server version number is used for indicating the server to modify the visualization attribute values of the columns.
The visualization attribute value comprises a first attribute value and a second attribute value, the first attribute value can be true and represents that the column is visible, and the second attribute value can be false and represents that the column is not visible.
In the embodiment of the present invention, when the user wants to view the web form on the terminal, a request for viewing the web form may be triggered on the terminal, for example, the user may click a link of the web form or input a website of the web form in a browser website input box. The terminal may send a column information obtaining request to the server according to the viewing request, where the column information obtaining request may carry a name of the web page table, and after receiving the column information obtaining request, the server may obtain the first column information of the web page table according to the name of the web page table, and return the first column information of the web page table to the terminal, so that the terminal may receive the first column information.
It should be noted that the first column information may further include column names or column identifiers of all columns in the web page table, so as to distinguish different columns in the web page table.
202. Acquiring second column information of the web page table, wherein the second column information comprises visual attribute values and server version numbers of all columns in the web page table stored locally by the terminal
The local version number can be greater than or equal to 0, and when the local version number is equal to 0, the user does not modify the visual attribute value of the column; and when the local version number is larger than 0, the visual attribute value of the column is modified by the user.
In one possible implementation manner, the acquiring, by the terminal, the second column of information of the web page table includes: the terminal acquires the second column information of the web page table from a local storage (LocalStorage). The LocalStorage is a way of web storage, and stores information of a web page table in a key-value (key value pair) form, where the key and the value are in one-to-one correspondence, and the value corresponding to the key can be found by the key. If the user does not actively delete, the information stored in the LocalStorage is always stored in the terminal. For each web page table, the name (e.g. 1.column) of the web page table is used as key, column information of all columns in the web page table is used as value, the value is a list, and the item in the list is column information of each column in the web page table.
In a possible implementation manner, the second column information further includes a local version number of all columns in a web page table stored locally by the terminal, where the local version number is used to indicate that the terminal modifies the visual attribute values of the columns. The modification refers to modification performed by the terminal when receiving a modification instruction, wherein the modification instruction can be triggered by user operation. In addition, the second column information may also include column names or column identifiers of all columns in the web page table, similarly to the first column information, to distinguish different columns in the web page table. Accordingly, the column information for each column may be as follows:
{"box_checked":{"visible":true,"client_version":0,"server_version":"0717"}};
wherein box _ checked is the column name; visual is a visualization attribute, which indicates whether the visualization attribute is visible (the visualization attribute value is true indicating visible, and the visualization attribute value is false indicating invisible); the client _ version represents a local version number, which may be recorded in the form of modification times, and for example, the local version number may be "0"; server _ version represents a server version number, which may be recorded in the form of a modification date, for example, the server version number may be "0717".
The server can send the first column information to the terminal and can also send the name of the webpage table to the server, so that the terminal can know which webpage table column information the first column information is received. Accordingly, for the process that the terminal acquires the second column of information from the LocalStorage, the terminal may read a value of the name of the LocalStorage by using the key in the LocalStorage, and acquire the column of the first attribute value (e.g., true) of the visual attribute value in the web page table from the value.
It should be noted that, in the embodiment of the present invention, the second column of information already exists in the local storage of the terminal, so the terminal may receive the first column of information sent by the server first, and then obtain the second column of information from the local storage. In fact, the terminal may not store the second column information in the local storage, for example, the terminal first sends a column information acquisition request to the server to request the column information of the web page table, the server may send the column information of the web page table to the terminal when receiving the column information acquisition request, and after receiving the column information, the terminal may directly store the column information as the second column information in the local storage, for example, LocalStorage, in which case, the terminal may directly display the web page table according to the visual attribute value of each column in the second column information.
In addition, in the embodiment of the present invention, the second column of information includes the local version number and the server version number of the column, and the first column of information includes only the server version number of the column as an example, but actually, the first column of information may include the local version number, but the local version number is always a specific value, such as 0.
203. And when the version numbers of the servers in the same column in the first column of information and the second column of information are the same, determining the visual attribute value of the column in the second column of information according to the visual attribute value of the column in the first column of information and the second column of information and the local version number of the column in the second column of information.
In the embodiment of the present invention, the terminal may determine, according to the version number of the server in the same column of the first column of information and the second column of information, whether to keep synchronization of the visual attribute value of the column between the server and the terminal, or to keep the visual attribute value of the column in the local storage of the terminal unchanged. Specifically, when the version numbers of the servers in the same column in the first column of information and the second column of information are the same, the terminal may set the visual attribute value of the column in the second column of information in a mild synchronization manner, that is, execute step 203; when the version numbers of the servers in the same column of the first column of information and the second column of information are different, the terminal may set the visual attribute value of the column of the second column of information in a forced synchronization manner, that is, perform the subsequent step 204.
The gentle synchronization means that when the visual attribute values of the columns in the web page table on the server side are changed, the terminal can determine whether to modify the visual attribute values of the columns in the web page table according to the first column information and the second column information, that is, the terminal can keep the visual attribute values of the columns unchanged and also modify the visual attribute values of the columns. The forced synchronization means that when the visual attribute value of the column in the web page table on the server side changes, the terminal directly modifies the visual attribute value of the column in the web page table so as to keep the synchronization of the visual attribute value of the column between the server and the terminal.
In a possible implementation manner, referring to fig. 3, a flowchart of a gentle synchronization between a terminal and a server is provided, as shown in fig. 3, after the terminal acquires a first column of information and a second column of information, determining a visual attribute value of the column in the second column of information may be implemented by:
step a, judging whether the visual attribute values of the column in the first column information and the second column information are the same, if so, keeping the visual attribute value of the column in the second column information unchanged, and if not, executing the subsequent step b.
In the embodiment of the present invention, the first column of information may be that the server sends the visual attribute values of the columns in the web page table to the terminal after modifying the visual attribute values of the columns, and the terminal may compare the visual attribute values of the columns in the first column of information and the second column of information after acquiring the first column of information. If the visual attribute values of the column in the first column information and the second column information are the same, the terminal can realize the synchronization of the visual attribute values of the column between the server and the terminal by keeping the visual attribute values of the column unchanged. If the visual attribute values of the column in the first column of information and the second column of information are different, the terminal may compare the local version number of the column in the second column of information with a specified numerical value, and determine how the terminal sets the visual attribute value of the column according to the comparison result.
And b, judging whether the local version number of the column in the second column of information is larger than a specified numerical value, if so, keeping the visual attribute value of the column in the second column of information unchanged, and if so, setting the visual attribute value of the column in the second column of information as the visual attribute value of the column in the first column of information.
And aiming at the fact that the local version number in the second column of information is used for indicating the number of times that the terminal modifies the visual attribute values of the column, if the local version number of the column in the second column of information is larger than a specified numerical value (such as 0), the fact that the user modifies the visual attribute values of the column on the terminal indicates that the user has the requirement of customizing the table display column, so that in order to meet the requirement of the user, the terminal can keep the visual attribute values of the column in the second column of information unchanged so as to keep the user-defined result. Therefore, the display column of the webpage table can be customized by a user, and whether the column is displayed in the webpage table can be set by the user according to the requirement of the user.
If the local version number of the column in the second column of information is equal to the designated value 0, it indicates that the user does not modify the visual attribute value of the column on the terminal, indicating that the user does not have a requirement for self-defining the table display column, so the terminal can set the visual attribute value of the column in the second column of information to the visual attribute value of the column in the first column of information, so as to implement synchronization of the visual attribute values of the column between the server and the terminal.
As can be seen from the above steps a and b, when the server version number of the same column in the first column of information and the second column of information is the same, the terminal may reset the visualization attribute value of the column in the second column of information, or may keep the visualization attribute value of the column in the second column of information unchanged. For the modified case, when the visualization attribute values of the column in the first column of information and the second column of information are different and the local version number of the column in the second column of information is equal to the specified value, the terminal may set the visualization attribute value of the column in the second column of information to the visualization attribute value of the column in the first column of information.
For the condition of being kept unchanged, when the visual attribute values of the column in the first column of information and the second column of information are the same, or the visual attribute values of the column in the first column of information and the second column of information are different and the local version number of the column in the second column of information is greater than a specified value, the terminal may keep the visual attribute value of the column in the second column of information unchanged.
It should be noted that, in the embodiment of the present invention, the local version number in the second column information is used to indicate the number of times that the terminal modifies the visual attribute value of the column, and the number of times is the number of times of cumulative modification. In fact, the number of times may also be the number of times that the terminal has received the column information of the web page table last time, and after determining the column information of the web page table in the local storage according to the column information, before the terminal currently receives the first column information, the visual attribute value of the column is modified, that is, the number of times that the terminal has modified the visual attribute value of the column between the last synchronization and the current synchronization. In this case, the local version number can reflect whether the terminal modifies the column of the web page table between two synchronizations, and accordingly, after each synchronization of the terminal, the local version number can be cleared to 0, and then the number of times of modifying the column of the web page table by the terminal between the synchronization and the next synchronization is recorded again.
In addition, for the case that the first column information and the second column information both include the local version numbers of all columns in the web page table, but the local version number in the first column information is always a specified value (e.g. 0), the step b may be replaced by the following process: the terminal determines whether the local version numbers of the columns in the first column information and the second column information are the same, if so, the visualization attribute value of the column in the second column information is kept unchanged, and if not, the visualization attribute value of the column in the second column information is set as the visualization attribute value of the column in the first column information.
Step 203 is a process of setting the visual attribute value in the second column of information by the terminal in a mild synchronization manner when the server version numbers in the same column of the first column of information and the second column of information are the same. When the version numbers of the servers in the same column in the first column of information and the second column of information are different, the terminal may adopt a forced synchronization mode to set the visual attribute value in the second column of information, and the specific process refers to the following step 204.
204. And when the server version numbers of the columns in the first column of information and the second column of information are different, setting the visualization attribute value of the column in the second column of information as the visualization attribute value of the column in the first column of information.
Referring to fig. 4, a flow chart for enforcing synchronization between a terminal and a server is provided. After the terminal acquires the first column of information and the second column of information, if the version numbers of the servers in the same column of the first column of information and the second column of information are different, the version numbers of the servers in the columns of the web page table are updated by the server and then the first column of information is sent to the terminal. In this case, the terminal may set the visualization attribute value of the column in the second column of information in a forced synchronization manner, for example, the terminal may set the visualization attribute value of the column in the second column of information as the visualization attribute value of the column in the first column of information, so as to implement synchronization of the visualization attribute values of the column between the server and the terminal.
The above step 203 and step 204 are two implementation manners for the terminal to determine the visual attribute value of the column in the second column of information according to the server version number of the same column in the first column of information and the second column of information.
205. And displaying the columns in the web page table according to the visual attribute values of all the columns in the second column information.
In the embodiment of the present invention, after setting the visual attribute values of the columns in the locally stored web page table, the terminal may display the target column in the web page table according to the visual attribute values of all the columns in the second column information, where the target column is a column whose visual attribute value is the first attribute value.
For the second column of information of the web page table stored in the LocalStorage by the terminal in the form of key-value in step 202, the terminal may read the value of the key in the LocalStorage as the name of the web page table, and determine the target column of the first attribute value (e.g., true) in the web page table according to the column information of each column in the value. Further, the terminal may determine the target column as a display column of the web page table, thereby displaying the target column in the web page table.
The above steps 201 to 205 are processes in which the terminal displays the web page table according to the first column information sent by the server and the second column information stored locally by the terminal. After the server modifies the visual attribute values in the columns in the web page table, the terminal can set the visual attribute values in the columns in the second column information of the web page table, which is locally stored by the terminal, according to the first column information of the web page table sent by the server, and then display the columns in the web page table according to the set visual attribute values in the columns in the web page table, so that the synchronization of the visual attribute values in the columns in the web page table can be realized between the terminal and the server.
In a possible implementation manner, after displaying a target column of which a visual attribute value is a first attribute value in a web page table, a terminal may send a data acquisition request to the server, where the data acquisition request is used to request to acquire data to be displayed in the target column; when the data to be shown of the target row sent by the server is received, the data to be shown of the target row is correspondingly shown in the target row. Therefore, the terminal can determine which columns are displayed in the web page table, then request the content to be displayed of the columns from the server, and correspondingly display the content in the columns of the web page table, so that the display of the web page table by the terminal is completed.
206. And when a modification instruction for the visualization attribute value of any column in the web page table is received, modifying the visualization attribute value of any column in the second column information.
The modification instruction is used for modifying the visualization attribute values of the columns, and different modification instructions are used for modifying the visualization attribute values of the columns differently, that is, the visualization attribute values of the columns are set to different values. For example, the modification instruction may be a display instruction or a cancel display instruction, where the display instruction is used to instruct to display the column, and the trigger terminal sets the visual attribute value of the column to be the first attribute value; and the cancel display instruction is used for indicating to cancel the display of the column, and triggering the terminal to set the visual attribute value of the column as a second attribute value.
In one possible implementation manner, the modification instruction may be triggered by a specified operation of the user, for example, the terminal may provide a column setting option for the user to custom modify the visualization attribute value of the column in the web page table. The user can click the column setting option, the terminal can display all columns of the web page table, wherein a part of the columns are in the checking state, the columns in the checking state are the columns currently displayed in the web page table, and the visual attribute value of the columns is the first attribute value. The other column is in an unchecked state, the columns in the unchecked state are columns which are not currently displayed in the web page table, and the visual attribute value of the columns is the second attribute value. The user may perform a specified operation on any column in the web page table to trigger the modification instruction, and the terminal may set the visualization attribute value of the column in the second column of information as the visualization attribute value corresponding to the modification instruction. The designating operation may include a checking operation and a checking cancellation operation.
Referring to fig. 5, a flow diagram for a user to customize a display column at a terminal is provided. The user may perform a check operation on any column in the web page table on the terminal, for example, the check operation is performed on a certain column which is not currently displayed in the web page table to trigger a display instruction for the column, and when the display instruction for any column in the web page table is received, the terminal may set the visual attribute value of the column in the second column information as the first attribute value, and store the modification in a local storage (LocalStorage), so that the column may be displayed in the web page table.
Referring to fig. 6, a flow diagram for a user to customize a display column at a terminal is provided. The user may perform a check canceling operation on any column in the web page table, for example, the check canceling operation is performed on a certain column currently displayed in the web page table to trigger a display canceling instruction for the column, and when the display canceling instruction for any column in the web page table is received, the terminal may set the visual attribute value of the column in the second column information to a second attribute value, and store the modification in a local storage (LocalStorage), so as to cancel the display of the column in the web page table.
As shown in fig. 5 and fig. 6, after the terminal modifies the visual attribute value of any column in the second column of information, the terminal may increase the local version number of the column in the second column of information by 1, so as to indicate that the user performs a custom modification on the column.
It should be noted that, in the foregoing steps 201 to 206 in the embodiment of the present invention, the terminal may set the visual attribute value of the column in a mild synchronization or forced synchronization manner according to the server version number of the same column in the first column information and the second column information, and then display the web page table. In fact, there may be different column information in the first column information and the second column information, such as that the first column information includes column information of a certain column but the second column information does not include column information of the certain column, or that the second column information includes column information of a certain column but the first column information does not include column information of the certain column, that is, the number of columns in the first column information and the second column information is different. For example, after adding or deleting a column, the server sends the first column information to the terminal, and the first column information received by the terminal and the second column information locally stored by the terminal contain column information of different columns. If the server adds columns, the number of columns in the first column information is greater than the number of columns in the second column information, and if the server deletes columns, the number of columns in the first column information is less than the number of columns in the second column information.
In consideration of the fact that different columns of column information may exist in the first column information and the second column information, when the terminal acquires the first column information and the second column information, the number of columns in the first column information and the second column information may be compared first. When the number of columns in the first column information is greater than the number of columns in the second column information, the terminal may determine a first target column in the first column information, the column information of the first target column not being included in the second column information, and add the column information of the first target column to the second column information. For the case that the server adds a column, the terminal may determine column information of the column added by the server according to the first column information and the second column information, and add the column information of the column to the second column information locally stored by the terminal, so that the visualization attribute values of the column in the second column information and the first column information are the same, and synchronization of the visualization attribute values of the column between the terminal and the server is maintained. Further, the terminal may determine whether to display the column in the web page table according to the visual attribute value of the column in the second column information.
When the number of columns in the first column information is smaller than the number of columns in the second column information, the terminal may determine a second target column in the first column information, the column information of the second target column not being included in the first column information, and delete the column information of the second target column from the second column information. For the case that the server deletes the column, the terminal may determine the column deleted by the server according to the first column information and the second column information, and delete the column information of the column from the second column information locally stored in the terminal, so that the terminal may not display the column in the web page table, and the user may not perform a specified operation on the column to customize whether the column is displayed in the web page table.
According to the method provided by the embodiment of the invention, after the terminal receives the first column information of the web page table sent by the server, the second column information of the web page table can be obtained from the local storage of the terminal, the visual attribute value of the column in the second column information is re-determined according to the server version number of the same column in the first column information and the second column information, and then the columns in the web page table are displayed according to the visual attribute values of all columns in the re-determined second column information. In the above technical solution, even if the server modifies the visual attribute value of the column in the web page table after the server sends the column information of the web page table to the terminal last time, so that the first column information currently received by the terminal is sent by the server after the visual attribute value of the column in the web page table is modified, the terminal may reset the visual attribute value of the column according to the first column information and the locally stored second column information, for example, the visual attribute value of the column in the second column information is set as the visual attribute value of the column in the first column information, so that synchronization of the visual attribute values of the columns in the web page table is realized between the terminal and the server.
In addition, in the process of displaying the web page table, the user can perform the checking operation or cancel the checking operation on any column in the web page table, the terminal can set the visual attribute value of the column according to the user operation, and determine whether to display the column according to the set visual attribute value of the column, so that the effect of customizing the web page table display column by the user is achieved.
Fig. 7 is a schematic structural diagram of a web form display apparatus according to an embodiment of the present invention. Referring to fig. 7, the apparatus includes:
a receiving module 701, configured to receive first column information of a web page table, where the first column information includes visual attribute values of all columns in the web page table stored by a server and a server version number, and the server version number is used to indicate that the server modifies the visual attribute values of the columns;
an obtaining module 702, configured to obtain second column information of the web page table, where the second column information includes visual attribute values and server version numbers of all columns in the web page table stored locally by the terminal;
a determining module 703, configured to determine a visual attribute value of the column in the second column of information according to a server version number of the same column in the first column of information and the second column of information;
a display module 704, configured to display the columns in the web page table according to the visualization attribute values of all the columns in the second column information.
In one possible implementation, the obtaining module 702 is configured to obtain the second column information of the web page table from a local storage.
In a possible implementation manner, the second column information further includes a local version number of all columns in the web page table stored locally by the terminal, where the local version number is used to indicate that the terminal modifies visual attribute values of the columns;
the determining module 703 is configured to determine, when the server version numbers of the columns in the first column of information and the second column of information are the same, a visual attribute value of the column in the second column of information according to the visual attribute values of the columns in the first column of information and the second column of information and the local version number of the column in the second column of information; and when the server version numbers of the columns in the first column of information and the second column of information are different, setting the visualization attribute value of the column in the second column of information as the visualization attribute value of the column in the first column of information.
In a possible implementation manner, the determining module 703 is configured to set the visualization attribute value of the column in the second column of information to the visualization attribute value of the column in the first column of information when the visualization attribute values of the columns in the first column of information and the second column of information are different and the local version number of the column in the second column of information is equal to a specified value; and when the visual attribute values of the column in the first column of information and the second column of information are the same, or the visual attribute values of the column in the first column of information and the second column of information are different and the local version number of the column in the second column of information is greater than a specified value, keeping the visual attribute value of the column in the second column of information unchanged.
In one possible implementation, referring to fig. 8, the apparatus further includes:
the modifying module 705 is configured to modify the visualization attribute value of any column in the second column information when a modification instruction for the visualization attribute value of any column in the web page table is received.
In a possible implementation manner, the modifying module 705 is configured to, when a display instruction for the any column is received, set a visualization attribute value of the any column in the second column information to a first attribute value, where the first attribute value indicates that the column is visible; and when a cancel display instruction of the any column is received, setting the visual attribute value of the any column in the second column information as a second attribute value, wherein the second attribute value indicates that the column is invisible.
In one possible implementation, referring to fig. 9, the apparatus further includes:
the determining module 703 is further configured to determine a first target column in the first column information when the number of columns in the first column information is greater than the number of columns in the second column information, where the column information of the first target column is not included in the second column information;
an adding module 706, configured to add the column information of the first target column to the second column information.
In a possible implementation manner, the determining module 703 is further configured to determine a second target column in the first column information when the number of columns in the first column information is less than the number of columns in the second column information, where the column information of the second target column is not included in the first column information;
the adding module 706 is further configured to delete the column information of the second target column from the second column information.
In the embodiment of the present invention, after the terminal receives the first column information of the web page table sent by the server, the second column information of the web page table may be obtained from the local storage of the terminal, and the visual attribute value of the column in the second column information is re-determined according to the server version number of the same column in the first column information and the second column information, so that the columns in the web page table are displayed according to the visual attribute values of all columns in the re-determined second column information. In the above technical solution, even if the server modifies the visual attribute value of the column in the web page table after the server sends the column information of the web page table to the terminal last time, so that the first column information currently received by the terminal is sent by the server after the visual attribute value of the column in the web page table is modified, the terminal may reset the visual attribute value of the column according to the first column information and the locally stored second column information, for example, the visual attribute value of the column in the second column information is set as the visual attribute value of the column in the first column information, so that synchronization of the visual attribute values of the columns in the web page table is realized between the terminal and the server.
It should be noted that: in the web page form display device provided in the above embodiment, only the division of the above function modules is exemplified when displaying the web page form, and in practical applications, the function distribution may be completed by different function modules according to needs, that is, the internal structure of the device is divided into different function modules to complete all or part of the functions described above. In addition, the web form display apparatus and the web form display method provided by the above embodiments belong to the same concept, and specific implementation processes thereof are described in the method embodiments in detail and are not described herein again.
The embodiment of the present invention provides a schematic structural diagram of a terminal 1000, and the terminal 1000 may be configured to execute the web page table display method provided in each of the above embodiments. Referring to fig. 10, the terminal 1000 includes:
terminal 1000 can include RF (Radio Frequency) circuitry 110, memory 120 including one or more computer-readable storage media, input unit 130, display unit 140, sensor 150, audio circuitry 160, WiFi (Wireless Fidelity) module 170, processor 180 including one or more processing cores, and power supply 190. Those skilled in the art will appreciate that the terminal structure shown in fig. 10 is not intended to be limiting and may include more or fewer components than those shown, or some components may be combined, or a different arrangement of components. Wherein:
the RF circuit 110 may be used for receiving and transmitting signals during information transmission and reception or during a call, and in particular, receives downlink information from a base station and then sends the received downlink information to the one or more processors 180 for processing; in addition, data relating to uplink is transmitted to the base station. In general, the RF circuitry 110 includes, but is not limited to, an antenna, at least one Amplifier, a tuner, one or more oscillators, a Subscriber Identity Module (SIM) card, a transceiver, a coupler, an LNA (Low Noise Amplifier), a duplexer, and the like. In addition, the RF circuitry 110 may also communicate with networks and other devices via wireless communications. The wireless communication may use any communication standard or protocol, including but not limited to GSM (Global System for Mobile communications), GPRS (General Packet Radio Service), CDMA (Code Division Multiple Access), WCDMA (Wideband Code Division Multiple Access), LTE (Long Term Evolution), e-mail, SMS (short messaging Service), etc.
The memory 120 may be used to store software programs and modules, and the processor 180 executes various functional applications and data processing by operating the software programs and modules stored in the memory 120. The memory 120 may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program required by at least one function (such as a sound playing function, an image playing function, etc.), and the like; the storage data area may store data (such as audio data, a phonebook, etc.) created according to the use of the terminal 1000, and the like. Further, the memory 120 may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device. Accordingly, the memory 120 may further include a memory controller to provide the processor 180 and the input unit 130 with access to the memory 120.
The input unit 130 may be used to receive input numeric or character information and generate keyboard, mouse, joystick, optical or trackball signal inputs related to user settings and function control. In particular, the input unit 130 may include a touch-sensitive surface 131 as well as other input devices 132. The touch-sensitive surface 131, also referred to as a touch display screen or a touch pad, may collect touch operations by a user on or near the touch-sensitive surface 131 (e.g., operations by a user on or near the touch-sensitive surface 131 using a finger, a stylus, or any other suitable object or attachment), and drive the corresponding connection device according to a predetermined program. Alternatively, the touch sensitive surface 131 may comprise two parts, a touch detection means and a touch controller. The touch detection device detects the touch direction of a user, detects a signal brought by touch operation and transmits the signal to the touch controller; the touch controller receives touch information from the touch sensing device, converts the touch information into touch point coordinates, sends the touch point coordinates to the processor 180, and can receive and execute commands sent by the processor 180. Additionally, the touch-sensitive surface 131 may be implemented using various types of resistive, capacitive, infrared, and surface acoustic waves. In addition to the touch-sensitive surface 131, the input unit 130 may also include other input devices 132. In particular, other input devices 132 may include, but are not limited to, one or more of a physical keyboard, function keys (such as volume control keys, switch keys, etc.), a trackball, a mouse, a joystick, and the like.
Display unit 140 can be used to display information entered by or provided to a user as well as various graphical user interfaces of terminal 1000, which can be made up of graphics, text, icons, video, and any combination thereof. The Display unit 140 may include a Display panel 141, and optionally, the Display panel 141 may be configured in the form of an LCD (Liquid Crystal Display), an OLED (Organic Light-Emitting Diode), or the like. Further, the touch-sensitive surface 131 may cover the display panel 141, and when a touch operation is detected on or near the touch-sensitive surface 131, the touch operation is transmitted to the processor 180 to determine the type of the touch event, and then the processor 180 provides a corresponding visual output on the display panel 141 according to the type of the touch event. Although in FIG. 10, touch-sensitive surface 131 and display panel 141 are shown as two separate components to implement input and output functions, in some embodiments, touch-sensitive surface 131 may be integrated with display panel 141 to implement input and output functions.
Terminal 1000 can also include at least one sensor 150, such as a light sensor, motion sensor, and other sensors. Specifically, the light sensor may include an ambient light sensor that adjusts the brightness of the display panel 141 according to the brightness of ambient light, and a proximity sensor that turns off the display panel 141 and/or a backlight when the terminal 1000 moves to the ear. As one of the motion sensors, the gravity acceleration sensor can detect the magnitude of acceleration in each direction (generally, three axes), can detect the magnitude and direction of gravity when the mobile phone is stationary, and can be used for applications of recognizing the posture of the mobile phone (such as horizontal and vertical screen switching, related games, magnetometer posture calibration), vibration recognition related functions (such as pedometer and tapping), and the like; other sensors such as a gyroscope, a barometer, a hygrometer, a thermometer, and an infrared sensor that can be configured for terminal 1000 are not described herein.
Audio circuitry 160, speaker 161, and microphone 162 can provide an audio interface between a user and terminal 1000. The audio circuit 160 may transmit the electrical signal converted from the received audio data to the speaker 161, and convert the electrical signal into a sound signal for output by the speaker 161; on the other hand, the microphone 162 converts the collected sound signal into an electric signal, converts the electric signal into audio data after being received by the audio circuit 160, and then outputs the audio data to the processor 180 for processing, and then to the RF circuit 110 to be transmitted to, for example, another terminal, or outputs the audio data to the memory 120 for further processing. Audio circuitry 160 may also include an earbud jack to provide communication of peripheral headphones with terminal 1000.
WiFi belongs to short-distance wireless transmission technology, and the terminal 1000 can help a user to send and receive e-mails, browse webpages, access streaming media and the like through the WiFi module 170, and provides wireless broadband Internet access for the user. Although fig. 10 shows the WiFi module 170, it is understood that it does not belong to the essential constitution of the terminal 1000, and can be omitted entirely as needed within the scope not changing the essence of the invention.
Processor 180 is the control center of terminal 1000, and interfaces and lines are used to connect various parts of the entire handset, and by running or executing software programs and/or modules stored in memory 120, and calling data stored in memory 120, various functions of terminal 1000 and processing data are executed, thereby performing overall monitoring of the handset. Optionally, processor 180 may include one or more processing cores; preferably, the processor 180 may integrate an application processor, which mainly handles operating systems, user interfaces, application programs, etc., and a modem processor, which mainly handles wireless communications. It will be appreciated that the modem processor described above may not be integrated into the processor 180.
Terminal 1000 can also include a power supply 190 (e.g., a battery) for powering the various components, which can be logically coupled to processor 180 via a power management system to manage charging, discharging, and power consumption management functions via the power management system. The power supply 190 may also include any component including one or more of a dc or ac power source, a recharging system, a power failure detection circuit, a power converter or inverter, a power status indicator, and the like.
Although not shown, terminal 1000 can also include a camera, a bluetooth module, etc., which are not described in detail herein. In this embodiment, the display unit of the terminal is a touch screen display, and the terminal further includes a memory and one or more programs, where the one or more programs are stored in the memory and configured to be executed by the one or more processors. The one or more programs include instructions for performing the terminal-side operations in the examples implemented in fig. 1 or fig. 2 described above.
In an exemplary embodiment, a computer readable storage medium, such as a memory, storing a computer program is also provided, and the computer program is executed by a processor to implement the web page table display method in the embodiment shown in fig. 1 or fig. 2. For example, the computer-readable storage medium may be a Read-Only Memory (ROM), a Random Access Memory (RAM), a Compact disc-Read-Only Memory (CD-ROM), a magnetic tape, a floppy disk, an optical data storage device, and the like.
It will be understood by those skilled in the art that all or part of the steps for implementing the above embodiments may be implemented by hardware, or may be implemented by a program instructing relevant hardware, where the program may be stored in a computer-readable storage medium, and the above-mentioned storage medium may be a read-only memory, a magnetic disk or an optical disk, etc.
The above description is only for the purpose of illustrating the preferred embodiments of the present invention and is not to be construed as limiting the invention, and any modifications, equivalents, improvements and the like that fall within the spirit and principle of the present invention are intended to be included therein.

Claims (14)

1. A web page table display method is applied to a terminal, and comprises the following steps:
receiving first column information of a web page table, wherein the first column information comprises visual attribute values of all columns in the web page table stored by a server and a server version number, and the server version number is used for indicating the server to modify the visual attribute values of the columns;
acquiring second column information of the web page table, wherein the second column information comprises visual attribute values and server version numbers of all columns in the web page table locally stored by the terminal, the second column information also comprises local version numbers of all columns in the web page table locally stored by the terminal, and the local version numbers are used for indicating the terminal to modify the visual attribute values of the columns;
when server version numbers of the columns in the first column of information and the second column of information are the same, determining the visual attribute values of the columns in the second column of information according to the visual attribute values of the columns in the first column of information and the second column of information and the local version numbers of the columns in the second column of information, wherein determining the visual attribute values of the columns in the second column of information according to the visual attribute values of the columns in the first column of information and the second column of information and the local version numbers of the columns in the second column of information comprises: when the visual attribute values of the columns in the first column information and the second column information are different and the local version number of the columns in the second column information is equal to a specified numerical value, setting the visual attribute values of the columns in the second column information as the visual attribute values of the columns in the first column information; when the visualization attribute values of the columns in the first column information and the second column information are the same, or the visualization attribute values of the columns in the first column information and the second column information are different and the local version number of the columns in the second column information is larger than a specified value, keeping the visualization attribute values of the columns in the second column information unchanged;
when the server version numbers of the columns in the first column information and the second column information are different, setting the visual attribute values of the columns in the second column information as the visual attribute values of the columns in the first column information;
and displaying the columns in the web page table according to the visual attribute values of all the columns in the second column information.
2. The method of claim 1, wherein the obtaining the second column information of the web page table comprises:
and acquiring the second column information of the webpage table from a local storage LocalStorage.
3. The method according to claim 1, wherein after displaying the columns in the web page table according to the visualized attribute values of all the columns in the second column information, the method further comprises:
when a modification instruction for the visualization attribute value of any column in the web page table is received, modifying the visualization attribute value of any column in the second column information.
4. The method according to claim 3, wherein the modifying the visual attribute value of any column in the second column of information when receiving a modification instruction for any column in the web page table comprises:
when a display instruction for any column is received, setting a visual attribute value of the any column in the second column information as a first attribute value, wherein the first attribute value indicates that the column is visible;
and when a cancel display instruction of any column is received, setting the visual attribute value of the any column in the second column of information as a second attribute value, wherein the second attribute value indicates that the column is invisible.
5. The method of claim 1, wherein after obtaining the second column of information of the web page table, the method further comprises:
when the number of columns in the first column information is larger than that in the second column information, determining a first target column in the first column information, wherein the column information of the first target column is not included in the second column information;
adding the column information of the first target column to the second column information.
6. The method of claim 1, wherein after obtaining the second column of information of the web page table, the method further comprises:
when the number of columns in the first column information is smaller than that in the second column information, determining a second target column in the first column information, wherein the column information of the second target column is not included in the first column information;
deleting the column information of the second target column from the second column information.
7. A web page form display apparatus, the apparatus comprising:
the system comprises a receiving module, a processing module and a display module, wherein the receiving module is used for receiving first column information of a web page table, the first column information comprises visual attribute values of all columns in the web page table stored by a server and a server version number, and the server version number is used for indicating the server to modify the visual attribute values of the columns;
the acquisition module is used for acquiring second column information of the webpage table, wherein the second column information comprises visual attribute values and server version numbers of all columns in the webpage table, which are locally stored by a terminal; the second column of information further includes local version numbers of all columns in the web page table stored locally by the terminal, and the local version numbers are used for indicating the terminal to modify visual attribute values of the columns;
a determining module, configured to determine a visual attribute value of the column in the second column of information according to a visual attribute value of the column in the first column of information and the second column of information and a local version number of the column in the second column of information when server version numbers of the columns in the first column of information and the second column of information are the same, where the determining a visual attribute value of the column in the second column of information according to a visual attribute value of the column in the first column of information and the second column of information and a local version number of the column in the second column of information includes: when the visual attribute values of the columns in the first column information and the second column information are different and the local version number of the columns in the second column information is equal to a specified numerical value, setting the visual attribute values of the columns in the second column information as the visual attribute values of the columns in the first column information; when the visualization attribute values of the columns in the first column information and the second column information are the same, or the visualization attribute values of the columns in the first column information and the second column information are different and the local version number of the columns in the second column information is larger than a specified value, keeping the visualization attribute values of the columns in the second column information unchanged; when the server version numbers of the columns in the first column information and the second column information are different, setting the visual attribute values of the columns in the second column information as the visual attribute values of the columns in the first column information;
and the display module is used for displaying the columns in the web page table according to the visual attribute values of all the columns in the second column information.
8. The apparatus of claim 7, wherein the obtaining module is configured to obtain the second column information of the web page table from a local storage.
9. The apparatus of claim 7, further comprising:
and the modification module is used for modifying the visual attribute value of any column in the second column of information when a modification instruction of the visual attribute value of any column in the webpage table is received.
10. The apparatus according to claim 9, wherein the modifying module is configured to, when receiving a display instruction for the any column, set a visual attribute value of the any column in the second column information to a first attribute value, where the first attribute value indicates that the column is visible; and when a cancel display instruction of any column is received, setting the visual attribute value of the any column in the second column of information as a second attribute value, wherein the second attribute value indicates that the column is invisible.
11. The apparatus of claim 7, further comprising:
the determining module is further configured to determine a first target column in the first column information when the number of columns in the first column information is greater than the number of columns in the second column information, where the column information of the first target column is not included in the second column information;
and the adding module is used for adding the column information of the first target column into the second column information.
12. The apparatus of claim 11, wherein the determining module is further configured to determine a second target column in the first column information when the number of columns in the first column information is smaller than the number of columns in the second column information, and the column information of the second target column is not included in the first column information;
the adding module is further configured to delete the column information of the second target column from the second column information.
13. A terminal comprising a processor and a memory; the memory is used for storing a computer program; the processor, configured to execute the computer program stored in the memory, implements the method steps of any of claims 1-6.
14. A computer-readable storage medium, characterized in that a computer program is stored in the computer-readable storage medium, which computer program, when being executed by a processor, carries out the method steps of any one of claims 1-6.
CN201710821364.XA 2017-09-13 2017-09-13 Webpage table display method and device Active CN107346347B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710821364.XA CN107346347B (en) 2017-09-13 2017-09-13 Webpage table display method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710821364.XA CN107346347B (en) 2017-09-13 2017-09-13 Webpage table display method and device

Publications (2)

Publication Number Publication Date
CN107346347A CN107346347A (en) 2017-11-14
CN107346347B true CN107346347B (en) 2020-04-24

Family

ID=60256827

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710821364.XA Active CN107346347B (en) 2017-09-13 2017-09-13 Webpage table display method and device

Country Status (1)

Country Link
CN (1) CN107346347B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109710237A (en) * 2019-01-10 2019-05-03 厦门商集网络科技有限责任公司 A kind of online modification method of calibration and equipment based on customized two-dimentional report
CN114610302A (en) * 2022-03-07 2022-06-10 上海英方软件股份有限公司 Method and device for realizing front-end table custom column

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101065723A (en) * 2004-11-26 2007-10-31 菲利普·K·钦 How to display data in a table
CN103631877A (en) * 2013-11-08 2014-03-12 四川长虹电器股份有限公司 Webpage table processing method
CN103916373A (en) * 2013-01-07 2014-07-09 腾讯科技(深圳)有限公司 Data updating method, server, client side and system
CN106610925A (en) * 2015-10-26 2017-05-03 北京国双科技有限公司 Method and device for displaying webpage table

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040049737A1 (en) * 2000-04-26 2004-03-11 Novarra, Inc. System and method for displaying information content with selective horizontal scrolling

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101065723A (en) * 2004-11-26 2007-10-31 菲利普·K·钦 How to display data in a table
CN103916373A (en) * 2013-01-07 2014-07-09 腾讯科技(深圳)有限公司 Data updating method, server, client side and system
CN103631877A (en) * 2013-11-08 2014-03-12 四川长虹电器股份有限公司 Webpage table processing method
CN106610925A (en) * 2015-10-26 2017-05-03 北京国双科技有限公司 Method and device for displaying webpage table

Also Published As

Publication number Publication date
CN107346347A (en) 2017-11-14

Similar Documents

Publication Publication Date Title
CN104518953B (en) Method for deleting message, instant communication terminal and system
CN106993227B (en) Method and device for information display
CN104967896A (en) Method for displaying bulletscreen comment information, and apparatus thereof
WO2018120905A1 (en) Message reminding method for terminal, and terminal
CN105094501B (en) Method, device and system for displaying messages in mobile terminal
CN105955739A (en) Graphical interface processing method, apparatus and system
CN107104930A (en) It is a kind of that the methods, devices and systems for checking authority are set
CN104660769B (en) A kind of methods, devices and systems for adding associated person information
US10298590B2 (en) Application-based service providing method, apparatus, and system
CN107423050A (en) A kind of method and apparatus for penetrating operation
CN106682189B (en) File name display method and device
CN111966373A (en) APN resetting method, terminal equipment and storage medium
CN114415893B (en) Image display method and device, electronic equipment and storage medium
CN109688611B (en) Frequency band parameter configuration method, device, terminal and storage medium
CN106339391B (en) Webpage display method and terminal equipment
CN106302101B (en) Message reminding method, terminal and server
CN105094872B (en) A kind of method and apparatus showing web application
CN107346347B (en) Webpage table display method and device
CN112799857B (en) Application access method, device, terminal and storage medium
CN105159655B (en) Behavior event playing method and device
CN105320532B (en) Method, device and terminal for displaying interactive interface
CN106899624A (en) A kind of method and apparatus for updating interlock account information
CN110928616A (en) Shortcut icon management method and electronic equipment
CN108234275B (en) Method and device for releasing communication information
CN111954193B (en) Bluetooth equipment connection detection method and device and mobile terminal

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
CB02 Change of applicant information
CB02 Change of applicant information

Address after: 510660 Guangzhou City, Guangzhou, Guangdong, Whampoa Avenue, No. 315, self - made 1-17

Applicant after: Guangzhou KuGou Networks Co., Ltd.

Address before: 510000 B1, building, No. 16, rhyme Road, Guangzhou, Guangdong, China 13F

Applicant before: Guangzhou KuGou Networks Co., Ltd.

GR01 Patent grant
GR01 Patent grant