Disclosure of Invention
In view of this, embodiments of the present invention provide an information interaction method, a readable storage medium, and an electronic device, so as to automatically change the format of each cell to be moved when moving the cell rows of different forms in online notes, and improve the efficiency of editing forms in online notes.
In a first aspect, an embodiment of the present invention provides an information interaction method, where the method includes:
displaying a first form and a second form in a note editor page through a form editing control; the data in each cell in the first table and the second table have corresponding data types, the data in each cell in the first table is displayed in a first data type corresponding to the column, and the data in each cell in the second table is displayed in a second data type corresponding to the column;
determining a selected row of cells in the first table in response to a selection operation;
And in response to the moving operation, moving the selected cell row to a second table, and displaying the data of the moved cell according to the second data type of the corresponding column of the second table.
Further, the displaying the data of the moved cell according to the second data type of the corresponding column of the second table includes:
Responding to the data type corresponding to the data in the moved cell to comprise a second data type corresponding to the column corresponding to the second table, and displaying the data type with the second data type;
and responding to the data type corresponding to the data in the moved cell without the second data type corresponding to the column corresponding to the second table, displaying the data type in the first data type corresponding to the column where the data is located before the movement, and displaying the error identification corresponding to the cell.
Further, the first table comprises a first header row, and the second table comprises a second header row;
The first header row comprises at least one first header cell, the second header row comprises at least one second header cell, and the first header cell and the second header cell are used for defining the name and the data type of the corresponding column;
the displaying the first form and the second form through the form editing control comprises:
displaying a first header row and a column corresponding to each first header cell through a table editing control; and
And displaying the second header row and a column corresponding to each second header cell.
Further, the table editing control also comprises a table header editing sub-control;
The method further comprises the steps of:
receiving header names for the selected first header cell or second header cell through the header editing sub-control;
And displaying the header name in the first header cell or the second header cell.
Further, receiving, by the header editing sub-control, a header name for the selected first header cell or second header cell comprises:
In response to receiving a first header cell or a second header cell trigger instruction, displaying a header editing sub-control at a predetermined position around a corresponding table cell, the header editing sub-control comprising a text input box;
The header name entered by receipt of the text entry box.
Further, the table editing control also comprises a data type conversion sub-control;
The method further comprises the steps of:
responsive to the data type conversion child control being triggered, determining a target data type corresponding to a column of the selected first table or a column of the second table;
And displaying the data of each cell in the column of the first table or the column of the second table in the target data type.
Further, the method further comprises:
And responding to the error identification selected, and displaying error prompt text corresponding to the error identification.
Further, the method further comprises:
And responding to a note synchronization instruction, and storing note editor page data to a cloud end, wherein the note editor page data comprises the first table, the second table and error identifications corresponding to cells.
In a second aspect, an embodiment of the present invention provides a computer-readable storage medium storing computer program instructions which, when executed by a processor, implement a method according to any one of the first aspects.
In a third aspect, an embodiment of the present invention provides an electronic device, including a memory for storing one or more computer program instructions, and a processor, wherein the one or more computer program instructions are executed by the processor to implement the method of any of the first aspects.
The first table and the second table type of the data corresponding to the data type are displayed in the cells in the page of the note editor through the table editing control, wherein the data in each cell in the first table is displayed in the first data type corresponding to the column, and the data in each cell in the second table is displayed in the second data type corresponding to the column. And after the cell line in the first table is selected to move to the second table, displaying the data of the moved cell according to the second data type of the corresponding column of the second table. The embodiment of the invention can realize the data movement of different forms in the process of editing online notes, and the data types of the data in each cell after the movement are converted after the movement and are directly displayed in the second data type of the corresponding column, so that the efficiency of editing online notes is improved.
Detailed Description
The present invention is described below based on examples, but the present invention is not limited to only these examples. In the following detailed description of the present invention, certain specific details are set forth in detail. The present invention will be fully understood by those skilled in the art without the details described herein. Well-known methods, procedures, flows, components and circuits have not been described in detail so as not to obscure the nature of the invention.
Moreover, those of ordinary skill in the art will appreciate that the drawings are provided herein for illustrative purposes and that the drawings are not necessarily drawn to scale.
Unless the context clearly requires otherwise, the words "comprise," "comprising," and the like in the description are to be construed in an inclusive sense as opposed to an exclusive or exhaustive sense; that is, it is the meaning of "including but not limited to".
In the description of the present invention, it should be understood that the terms "first," "second," and the like are used for descriptive purposes only and are not to be construed as indicating or implying relative importance. Furthermore, in the description of the present invention, unless otherwise indicated, the meaning of "a plurality" is two or more.
Fig. 1 is a schematic diagram of an information interaction system to which the information interaction method according to the embodiment of the present invention is applied, as shown in fig. 1, the information interaction system includes a first terminal device 11, where the first terminal device 11 may be a general-purpose data processing terminal with a communication function, such as a smart phone, a tablet computer, or a notebook computer, capable of running a computer program.
The terminal device 11 may perform man-machine interaction with the user 10 through a preset I/O communication interface. The man-machine interaction process is to display a note editor page comprising a form editing control through a display interface of the first terminal device 11, wherein the form editing control comprises a first form and a second form. After the user 10 selects the cell line in the first table to move to the second table, each cell in the moved cell line is displayed according to the data type of the corresponding column of the second table.
Further, the information interaction system may further include a server 12 of the first terminal device 11 logging in the note editor with the account corresponding to the user 10 through the network, where the server 12 may be a single server or may be a server cluster configured in a distributed manner. The server 12 is configured to store a result of the man-machine interaction between the first terminal device 11 and the user 10, that is, a finally stored note editor page including a form editing control after moving a form cell line, and is configured to enable the user to obtain the stored note editor page through the server 10 when the user replaces the terminal device 11. Further, the server 12 may also store a process of human-computer interaction between the first terminal device 11 and the user 10, for locating the fault operation when the fault information occurs.
In the embodiment of the present invention, the user 10 may be bound to the note editor by registering a corresponding account in the note editor, so as to implement migration of online notes recorded by the user 10 between different terminal devices. For example, when the user 10 logs in the note editor through the first terminal device 11 first and records the online notes, and then logs in the note editor through the second terminal device 13, the online notes recorded in the first terminal device 11 can be transferred to the second terminal device 13 through the account corresponding to the user 10, so that the user can browse, review, edit and other operations.
FIG. 2 is a schematic diagram of a notebook editor page according to an embodiment of the invention. As shown in fig. 2, the note editor page 20 includes a text input control 21 for inputting text content, and an attachment insertion control 22 for inserting file attachments in different formats, such as audio, video, pictures, tables, and the like. The text input control 21 is used for receiving text data input by a user, and the attachment insertion control 22 is used for inserting attachments in a corresponding format. For example, when a user triggers a smart form insertion child control inserted into the attachment insertion control 22, a form editing control is displayed on the note editing page. Meanwhile, in order to ensure that online notes recorded by a user in the note editor cannot be lost in the migration process of different terminal devices, the note editor page further comprises a user login control 23 for logging in a user account, and the user can trigger the user login control 23 to acquire online notes recorded by any terminal device through history in different terminal devices.
Further, the note editing page 20 further includes a note sharing control 24 for sharing online notes by different users. When the note sharing control 24 is triggered, corresponding online notes may be sent to other terminal devices. The terminal device receiving the online note may be a terminal device logged in by other users, a terminal device logged in by a user who sends the online note, or a terminal device logged in by a user who does not use the online note.
FIG. 3 is a schematic diagram of online note transfer according to an embodiment of the present invention. As shown in fig. 3, when a first user 30 and a second user 31 log into the note editor through corresponding first user terminals 32 and second user terminals 33, respectively. The first user 30 and the second user 31 may transfer online notes between the first user terminal 32 and the second terminal device 33 by triggering a note sharing control in a note editing page.
Specifically, when the first user 30 triggers the note sharing control in the note editing page displayed by the first user terminal 32, the first user terminal 32 may transmit, to the second user terminal 33, an online note displayed on the note editing page where the note sharing control is located. When the second user 31 triggers the note sharing control in the note editing page displayed by the second user terminal 33, the second user terminal 33 may transmit the online note displayed on the note editing page where the note sharing control is located to the first user terminal 32.
Fig. 4 is a flowchart of an information interaction method according to an embodiment of the present invention. As shown in fig. 4, the method comprises the steps of:
and step S100, displaying the first table and the second table in the page of the note editor through a table editing control.
Specifically, the page of the note editor is a front page corresponding to the note editor, and is displayed through a display interface of terminal equipment provided with the note editor. In the embodiment of the invention, the note editor page is used for generating the online notes through man-machine interaction with a user, and can comprise a text input control, an accessory insertion control and other controls for editing the online notes. The text input control is used for receiving text data input by a user, the accessory insertion control is used for inserting accessories into the online notes, and the accessories can comprise audio, video, pictures, tables, network links and the like. And after triggering the form insertion sub-control in the accessory insertion control by clicking or the like, displaying a form editing control in the note editor page. A user may trigger a form add sub-control in the form editing control to add a form to the online note, the form being displayed by the form editing control. When the online notes need to be added with a plurality of forms, a user can add a corresponding number of forms into the online notes by triggering the form adding sub-control for a plurality of times. In the embodiment of the invention, the user can add the first table and the second table to the table editing control by triggering the table adding sub-control in the table editing control twice.
Further, each cell in the table editing control is used for displaying corresponding data, and each data has a corresponding data type. The data types may include text, numbers, dates, currencies, percentages, and so forth. For example, for data "text", the corresponding data type that may be displayed is text, for data "10", the corresponding data type that may be displayed includes text, number, currency, percentage, and for data "2020/2/3", the corresponding data type that may be displayed includes text, number, date, currency, percentage. Optionally, the data types may also include further sub-data types. For example, a "date" may include sub-data types of long dates and short dates for a data type; "digital" for a data type may include displaying a digital integer and displaying a sub-data type that includes an N-bit number after a digital decimal point; for data types "currency" may include the sub-data types Renminbi, dollars, euro, japanese, etc. In the embodiment of the invention, the data types corresponding to each column of data of the table inserted in the online note are the same.
Therefore, when the first table and the second table are displayed in the table editing control, the data in each cell in the first table and the second table respectively have a corresponding data type. The data in each cell in the first table is displayed in a first data type corresponding to the column, and the data in each cell in the second table is displayed in a second data type corresponding to the column.
In the embodiment of the present invention, each table inserted in the page of the note editor includes a corresponding header row, and each cell in the header row is a header cell, which is used to define a name and a data type of a corresponding column. Therefore, when the first table and the second table are included in the table editing control, the first table includes a first header row, and the second table includes a second header row. The first header row comprises at least one first header cell, the second header row comprises at least one second header cell, and the first header cell and the second header cell are used for defining the name and the data type of the corresponding column.
Displaying the first table and the second table through the table editing control comprises displaying first header rows and columns corresponding to the first header cells through the table editing control. And displaying the second header row and the column corresponding to each second header cell through a table editing control.
FIG. 5 is a schematic diagram of a note editor page including a form editing control in accordance with an embodiment of the invention. As shown in fig. 5, the note editor page 50 is displayed through a display interface, and is configured to receive note content input by a user through a man-machine interaction port. The note editor page 50 includes form editing controls therein for displaying a first form 51 and a second form 52.
In the embodiment of the present invention, the first table 51 and the second table 52 respectively include a corresponding first header row, a second header row, and a plurality of table cells 53. The data in each cell 53 in the first table 51 is displayed in a first data type corresponding to the column where the data is located, and the data in each cell 53 in the second table 52 is displayed in a second data type corresponding to the column where the data is located. The data types corresponding to the columns in the first table 51 may be determined according to the corresponding first header cells, and the data types corresponding to the columns in the second table 52 may be determined according to the corresponding second header cells. For example, it is determined that the data type of the data display in each cell 53 in the first column in the first table 51 is text, the data type of the data display in each cell 53 in the second column is an integer number, the data type of the data display in each cell 53 in the third column is a percentage, and the data type of the data display in each cell 53 in the fourth column is a short date. The data type of the data display of each cell 53 in the first column in the second table 52 is a number including two digits after the decimal point, the data type of the data display of each cell 53 in the second column is a text, the data type of the data display of each cell 53 in the third column is a rmb, and the data type of the data display of each cell 53 in the fourth column is a long date.
Further, a text input control 54 for entering text data is also included in the markup editor page 50.
Step S200, in response to the selection operation, determining the selected cell row in the first table.
Specifically, the form editing control may perform editing operations on one or more forms in addition to adding forms. For example, for each table in the note editor page, the table editing control may also make edits such as adding rows, columns, and splitting tables in each table. For at least two tables in the page of the note editor, the table editing control may further combine different tables to obtain one table, or move at least one cell row or cell column in one table into another table. When at least one cell row or cell column of a table in the table editing control is moved, the cell row or cell column to be moved needs to be selected in the table.
In the embodiment of the invention, at least one cell line in the first table needs to be moved to the second table, so that the cell line to be moved, which is selected by at least one cell line, is determined in the first table. The selection operation may be performed by a preset selection rule, such as a long on-demand selected cell line, or a double click on a desired selected cell line.
And step 300, responding to the moving operation, moving the selected cell line to a second table, and displaying the data of the moved cell according to the second data type of the corresponding column of the second table.
Specifically, after at least one cell row is selected in the first table, the selected cell row is moved to the second table according to a movement operation of the user. Before moving, the data of each cell in the cell row is displayed in a first data type corresponding to the column where the data is located, and because the second data type corresponding to each column in the second table is not necessarily the same as the first data type corresponding to each column in the first table, the data of each cell in the moved cell row may be mismatched with the data type of the corresponding column in the second table. Thus, after moving the cell row, the data of the moved cell is displayed according to the second data type of the corresponding column of the second table.
After the at least one selected cell row is moved, determining the data type of the data in each cell in the moved cell row according to the second data type of the corresponding column of the second table, and displaying the data type. And when the data type corresponding to the data in the moved cell comprises a second data type corresponding to the corresponding column in the second table after movement, displaying the data in the moved cell by the second data type. For example, when the data in the moved cell is "10", the data type corresponding to the corresponding column after the movement is rmb, the data in the cell is displayed as "10". And when the data type corresponding to the data in the moved cell does not comprise the second data type corresponding to the corresponding column in the second table after the movement, displaying the data in the moved cell by the first data type corresponding to the column before the movement. For example, when the data in the moved cell is "text", the data type corresponding to the corresponding column after the movement is a number, the data in the cell is displayed as "text".
Further, when the data type corresponding to the data in the moved cell does not include the second data type corresponding to the corresponding column in the second table after the movement, it is proved that the data in the moved cell is not matched with the corresponding column in the second table, and the probability of being an error operation is high. Therefore, while the data in the moved cell is displayed in the first data type corresponding to the column in which the movement was performed, the corresponding error identification is also displayed in the cell. Optionally, the error identifier may also correspond to error prompt text. When the error identification is selected, a corresponding error prompt text is displayed to prompt a user that the data type of the data in the cell is wrong, and reasons, solutions and the like of the error.
FIG. 6 is a schematic diagram of a mobile cell line process note editor page in accordance with an embodiment of the invention. As shown in fig. 6, the note editor page 60 includes a first table 61 and a second table 62, and a unit cell line 63 is selected in the first table 61 and moved to the second table 62.
Specifically, before the cell line 63 is moved, the data in the cells of the first column in the cell line 63 is "text", the first data type displayed is text, the data in the cells of the second column is "10", the first data type displayed is an integer number, the data in the cells of the third column is "100%", the first data type displayed is a percentage, the data in the cells of the fourth column is "2020/2/30", and the first data type displayed is a short date.
After the cell line 63 is moved to the second table 62, since the second data type corresponding to the first column in the second table 62 is a number including two digits after the decimal point, and the data type corresponding to the data in the cells in the first column in the cell line 63 is only text, only the text of the first data type before the movement can be displayed as "text", and the corresponding error identification 64 is displayed in the cells. The second data type corresponding to the second column in the second table 62 is text, and the data type corresponding to the data in the cells in the second column in the cell row 63 includes text, so that the text is displayed as "10" in the second data type. The second data type corresponding to the third column is rmb, and the data type corresponding to the data in the cells of the third column in the cell row 63 includes rmb, so that the rmb is shown as "1" in the second data type. The second data type corresponding to the fourth column is long date, and the data type corresponding to the data in the cells in the fourth column in the cell row 63 includes long date, so the long date is displayed as "30 days of 2 months in 2020" in the second data type.
In the embodiment of the invention, in order to realize the visual representation of the contents of the corresponding columns through each header cell in each table in the online notes, the table editing control also comprises a header editing sub-control for editing the contents of the header cells. Therefore, in the case that each header cell needs to be edited, the information interaction method can receive the header name of the selected first header cell or second header cell through the header editing sub-control, and display the header name in the first header cell or the second header cell. The header name can be input into the selected first header cell or second header cell by a user through a man-machine interaction mode. And the process of editing the header name is to select the corresponding header cell when a trigger instruction of the first header cell or the second header cell is received, and display a header editing sub-control comprising a text input box at a preset position around the table cell. And displaying the header names in the corresponding header cells by receiving the header names input by the user through the text input box.
FIG. 7 is a schematic diagram of a note editor page for editing header names according to an embodiment of the invention. As shown in fig. 7, the first table includes a first header row 70, and the second table includes a second header row 71. Wherein each of the cells in the first header row 70 is a first header cell 72, and each of the cells in the second header row 71 is a second header cell 73. When one of the first header cells 72 in the first header row 70 is selected, a header editing sub-control including a text entry box 74 is displayed at a predetermined location around the selected first header cell 72. The user may input a corresponding header name into the text input box 74 through a predetermined I/O communication interface, and the header name is displayed in the selected first header cell 72 after the input is completed.
And in order to set the data types of each column of the inserted form in the online note, the form editing control further comprises a data type conversion sub-control. Because each cell in the header row of the table is used to define the name and the data type of the corresponding column, in an optional implementation manner of the embodiment of the present invention, the data type conversion sub-control may be displayed in the header cell in the header row of each table, and is used to define the data type of the corresponding column. And the process of defining the data type of the corresponding column is to determine the target data type corresponding to the column of the selected first table or the column of the second table when the data type conversion sub-control is triggered, and display the data of each cell in the column of the selected first table or the column of the second table by the target data type.
FIG. 8 is a schematic diagram of a note editor page that adjusts column data types in accordance with an embodiment of the invention. As shown in fig. 8, the first table in the table editing control includes a first header row 80, and the first header row 80 includes a plurality of first header cells 81. When a first header cell of a data type to be converted is selected in the first header row, a data type conversion sub-control 82 is displayed in the selected first header cell. After the user triggers the data type conversion sub-control 82, a drop down list 83 of the data types to be determined is displayed at a predetermined location around the data type conversion sub-control 82. The user may select a target data type corresponding to the column in the drop-down list 83. When the user changes the data type corresponding to the column by triggering the data type conversion sub-control 82, the data of each cell in the corresponding column is displayed in the changed target data type.
The information interaction method is applied to the note editor, so that the note content inserted with the audio data is prevented from being lost, and the safety of the online note in the migration process is ensured. And when receiving a note synchronization instruction, the note editor saves the page data of the note editor to the cloud, wherein the page data of the note editor comprises the first table, the second table and error identifications corresponding to the cells. When the user replaces the terminal equipment provided with the note editor, the user can still acquire the online note comprising the first table, the second table and the cell error identifier through the cloud.
The embodiment of the invention can realize the data movement among different tables in the process of editing online notes, and the data types of the data in each cell after the movement are converted after the movement and are directly displayed in the data types of the corresponding columns, so that the efficiency of editing online notes is improved.
Fig. 9 is a schematic diagram of an electronic device according to an embodiment of the invention. As shown in fig. 9, the electronic device shown in fig. 9 is a general address query device, which includes a general computer hardware structure including at least a processor 90 and a memory 91. Processor 90 and memory 91 are connected by bus 92. The memory 91 is adapted to store instructions or programs executable by the processor 90. Processor 90 may be a stand-alone microprocessor or may be a collection of one or more microprocessors. Thus, the processor 90 implements processing of data and control of other devices by executing instructions stored by the memory 91 to perform the method flows of embodiments of the present invention as described above. The bus 92 connects the above components together, and connects the above components to the display controller 93 and the display device and input/output (I/O) device 94. Input/output (I/O) devices 94 may be a mouse, keyboard, modem, network interface, touch input device, somatosensory input device, printer, and other devices known in the art. Typically, an input/output device 94 is connected to the system through an input/output (I/O) controller 93.
It will be apparent to those skilled in the art that embodiments of the present application may be provided as a method, apparatus (device) or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may employ a computer program product embodied on one or more computer-readable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations of methods, apparatus (devices) and computer program products according to embodiments of the application. It will be understood that each of the flows in the flowchart may be implemented by computer program instructions.
These computer program instructions may be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows.
These computer program instructions may also be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows.
Another embodiment of the present invention is directed to a non-volatile storage medium storing a computer readable program for causing a computer to perform some or all of the method embodiments described above.
That is, it will be understood by those skilled in the art that all or part of the steps in implementing the methods of the embodiments described above may be implemented by a program stored in a storage medium, where the program includes several instructions for causing a device (which may be a single-chip microcomputer, a chip or the like) or a processor (processor) to perform all or part of the steps in the methods of the embodiments of the present application. And the aforementioned storage medium includes: a usb disk, a removable hard disk, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), a magnetic disk, or an optical disk, or other various media capable of storing program codes.
The above description is only of the preferred embodiments of the present invention and is not intended to limit the present invention, and various modifications and variations may be made to the present invention by those skilled in the art. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention should be included in the protection scope of the present invention.