Disclosure of Invention
The embodiment of the application provides a system page development management method, a computer device and a computer storage medium, which are used for backing up page generation data of a secondary development page, so that the secondary development page can be recovered by using the backed-up data subsequently, the secondary development result can be rapidly recovered, the secondary development page under the scheme is prevented from being redeveloped, and the cost of manpower and material resources is saved.
A first aspect of the embodiments of the present application provides a method for system page development management, including:
receiving a new version instruction;
searching page information of secondary development according to the newly added version instruction;
acquiring page generation data according to the page information;
and saving the page generation data under the first file path.
Optionally, the page generation data includes page metadata script data and page resource data;
acquiring page generation data according to the page information, comprising:
acquiring corresponding page metadata script data in a database according to the page information;
and acquiring page resource data under the corresponding second file path according to the page information.
Optionally, the first file path includes a third file path and a fourth file path;
saving page generation data under a first file path, comprising:
saving page metadata script data under a third file path;
and saving the page resource data under the fourth file path.
Optionally, after saving the page generation data in the first file path, the method further includes:
receiving a version reduction instruction;
replacing the page metadata script data stored in the third file path into the database;
and replacing the page resource data stored in the fourth file path into the second file path.
Optionally, the third file path is the same as the fourth file path.
Optionally, after receiving the new version instruction, before obtaining the corresponding page metadata script data in the database according to the page information, the method further includes:
and searching page element data script data in the database according to the page information.
Optionally, the page resource data includes at least one of the following:
a JS file of an transliteration script language, a CSS file of a cascading style sheet, and a JAR package or CLASS file of a Java language filing.
A second aspect of the embodiments of the present application provides a system page development management apparatus, including:
the receiving unit is used for receiving the new version instruction;
the searching unit is used for searching the page information of the secondary development according to the newly added version instruction;
the acquisition unit is used for acquiring page generation data according to the page information;
and the saving unit is used for saving the page generation data under the first file path.
Optionally, the page generation data includes page metadata script data and page resource data;
optionally, the obtaining unit is specifically configured to obtain at least one page metadata script data in the database according to the page information;
optionally, the obtaining unit is specifically configured to obtain the page resource data in the second file path according to the page information.
Optionally, the first file path includes a third file path and a fourth file path;
optionally, the saving unit is specifically configured to save the page metadata script data in the third file path;
optionally, the saving unit is specifically configured to save the page resource data in the fourth file path;
optionally, the receiving unit is further configured to receive a version restoring instruction;
optionally, the system page development management device further includes:
the replacing unit is specifically used for replacing the page metadata script data stored in the third file path into the database;
the replacing unit is also used for replacing the page resource data stored in the fourth file path into the second file path;
optionally, the second file path is the same as the third file path;
optionally, the fourth file path is the same as the second file path;
optionally, the system page development management device further includes:
the searching unit is specifically used for searching page element data script data in the database according to the page information;
optionally, the page resource data includes at least one of the following:
a JS file of an transliteration script language, a CSS file of a cascading style sheet, and a JAR package or CLASS file of a Java language filing.
Operations executed by each unit in the system page development management device are similar to the method in the first aspect of the embodiment of the present application, and are not described herein again.
A third aspect of embodiments of the present application provides a computer storage medium having instructions stored therein, which when executed on a computer, cause the computer to perform the method of the first aspect of embodiments of the present application.
A fourth aspect of the embodiments of the present application provides a computer device, including a memory and a processor, where the memory stores a computer program, and the computer program is executed by the processor to implement the method of the first aspect of the embodiments of the present application.
According to the technical scheme, the embodiment of the application has the following advantages:
in the embodiment of the application, the page generation data is backed up in the first file path through the version addition instruction, so that even if the page generation data corresponding to the second-opening page of the current scheme is modified or deleted, the page generation data can be acquired from the first file path and used for generating the corresponding second-opening page, the secondary development result can be rapidly recovered, the second-opening page under the scheme is prevented from being redeveloped, and the cost of manpower and material resources is saved.
Detailed Description
The embodiment of the application provides a system page development management method, which is used for backing up page generation data of a newly added version of a secondary development page, so that the secondary development page can be recovered by using the backed-up data subsequently, and the operability of a user can be improved.
Referring to fig. 1, an embodiment of a system page development management method in the present application includes:
101. receiving a new version instruction;
when the user clicks the new version button, a new version command is received.
102. Searching page information of secondary development according to the newly added version instruction;
after receiving the new version instruction, the system page development management device searches corresponding page information according to the new version instruction, wherein the page information comprises basic information of a secondary development page needing to be backed up.
103. Acquiring page generation data according to the page information;
after the system page development management device finds the corresponding page information, the system page development management device obtains page generation data of the secondary development page according to the page information, and the page generation data is used for generating the secondary development page.
104. Saving page generation data under a first file path;
after the system page development management device obtains the page generation data, the system page development management device stores the page generation data to a first file path of the system page development management device. The page generation data may be called when needed, for example, when the user terminal needs the page generation data, the page generation data may be obtained from the first file path of the system page development management device.
Wherein, the first file path is different from the path for saving the page generation data in the step 102.
In the embodiment of the application, the system page development management device backs up the page generation data in the first file path through the newly added version instruction, so that even if the page generation data corresponding to the current secondary development page is modified or deleted, the page generation data can be acquired from the first file path and used for generating the corresponding secondary development page, and the operability of a user is improved.
Referring to fig. 2, another embodiment of the system page development management method in the embodiment of the present application includes:
201. receiving a new version instruction;
after the system page development management device stores the page generation data of the current secondary development page, when the secondary development page needs to be backed up or other stored secondary development pages need to be backed up, the newly added version button can be clicked on the development platform interface of the computer device. After clicking the new version button, the computer device generates a new version instruction and sends the new version instruction to the system page development management device, and the system page development management device receives the new version instruction sent by the user side. The new version instruction is used for instructing the system page development management device to backup the secondary development page which is already saved.
Beforestep 201, the system page development management device stores page generation data of the current secondary development page, which may specifically include: and after the saving button is clicked, the computer equipment generates a saving instruction, the saving instruction instructs the system page development management device to save the page generation data of the secondary development page, the system page development management device receives the saving instruction and saves the page generation data of the secondary development page into the system page development management device according to the saving instruction.
It should be noted that the new version instruction may instruct to backup a plurality of secondary development pages, or may instruct to backup one secondary development page. For example, a user develops a certain product on a certain development platform, the product corresponds to one or more secondary development pages, when the user edits and saves a certain secondary development page, a new version button is continuously clicked, the computer device generates indication data, the computer device has a display screen, and displays the indication data in the display screen, and the indication data includes the identifier of the saved secondary development page. The user can select one or more identifications of the secondary development page according to the displayed identifications of the secondary development page. The computer equipment acquires the one or more identifications, determines one or more secondary development pages needing to be stored according to the one or more identifications, and generates a new version instruction according to data of the one or more secondary development pages. And then the user side sends the new version instruction to the system page development management device in a wireless or wired mode, and the system page development management device receives the new version instruction.
In the embodiment of the application, after the user clicks the new version instruction, the instruction for requesting to select the secondary development page may not be triggered, but the new version instruction for instructing the system page development management device to backup all the secondary development pages that have been saved may be directly generated. For example, a user develops a certain product scheme on a certain development platform, the product scheme corresponds to one or more secondary development pages, when the user edits and saves one or more secondary development pages, the user continues to click a new version adding button, and the computer device generates a new version adding instruction according to the secondary development pages saved under the product scheme. The new version instruction instructs the system page development management device to backup all secondary development pages under the stored product scheme, the computer device sends the new version instruction to the system page development management device in a wireless or wired mode, and the system page development management device receives the new version instruction.
202. Searching page information of secondary development according to the newly added version instruction;
after receiving the new version instruction, the system page development management device searches corresponding page information according to the new version instruction, wherein the page information comprises basic information of a secondary development page needing to be backed up. For example, the information identifier of the secondary development page, the file data size information of the secondary development page, the file path of the secondary development page, and the like, the basic information may include one or more types of basic information, and is not limited herein.
203. Acquiring page element data script data under a database according to the page information;
after the system page development management device finds the corresponding page information, the page metadata script data corresponding to the secondary development page is found in the database according to the page information. After the page metadata script data corresponding to the secondary development page is found, the system page development management device obtains the page metadata script data in a copying mode.
204. Acquiring page resource data under a second file path according to the page information;
after the system page development management device finds the corresponding page information, searching page resource data corresponding to the secondary development page under a second file path of the system page development management device according to the page information. When the page resource data corresponding to the secondary development page is found, the page resource data is obtained in a copying mode, and the second file path is a saving path for saving the page resource data by the system page development management device after the user side triggers the saving button.
205. Saving page metadata script data under a third file path;
after the system page development management device acquires the page metadata script data, the page metadata script data is stored in a third file path of the system page development management device. The third file path is under the file directory of the system page development management device.
In this embodiment, the page metadata script data may be stored in the third file path in the form of a data file, for example, a folder is created in a file directory of the system page development management device, and the page metadata script data is stored in the folder.
It is understood that the page metadata script data may also be stored in a compressed file under the path, for example, a folder is created under a certain file path of the system page development management device, and a compressed file is created in the folder, and the page metadata script data is stored in the compressed file. In the specific implementation process, other storage forms are possible, and the specific implementation process is not limited herein.
206. Saving the page resource data under the fourth file path;
after the system page development management device acquires the page resource data, the page resource data is stored in a fourth file path.
In this embodiment of the application, the page resource data may be stored in the third file path in the form of a data file, for example, a folder is created under a certain file path of the system page development management apparatus, where the file path is different from the second file path, that is, different from a path stored in the current secondary development page, and the page resource data is stored in the folder.
It is understood that the page metadata script data may also be stored in a compressed file under the path, for example, a folder is created under a certain file path of the system page development management device, and a compressed file is created in the folder, and the page resource data is stored in the compressed file. In the specific implementation process, other storage forms are possible, and the specific implementation process is not limited herein.
207. Receiving a version reduction instruction;
when the secondary development page needs to be recovered, the user can click a version restoring button on the computer equipment, and the computer equipment generates a version restoring instruction and sends the version restoring instruction to the system page development management device.
Optionally, after clicking the version restoring button, the computer device generates indication data, has a display screen, and displays the indication data in the display screen, where the indication data includes an identifier of the backed-up secondary development page. The user can select one or more identifications of the secondary development page according to the displayed identifications of the secondary development page. The computer equipment acquires the one or more identifications, determines one or more secondary development pages needing to be restored according to the one or more identifications, and generates a restoration version instruction according to data of the one or more secondary development pages. And then the computer equipment sends the reduced version instruction to a system page development management device in a wireless or wired mode, and the system page development management device receives the reduced version instruction.
208. Replacing the page metadata script data stored in the third file path into the database;
after the system page development management device receives the version reduction instruction, the system page development management device determines metadata script data corresponding to the secondary development page to be reduced according to the version reduction instruction, copies page metadata script data corresponding to the secondary development page stored in a third file path of the system page development management device, and replaces the metadata script data corresponding to the secondary development page stored in the database with the page metadata script data.
209. And replacing the page resource data stored in the fourth file path into the second file path.
After the system page development management device receives the version reduction instruction, the system page development management device determines page resource data corresponding to the secondary development page to be reduced according to the version reduction instruction, copies the page resource data corresponding to the secondary development page stored in the fourth file path of the system page development management device, and replaces the page resource data corresponding to the secondary development page stored in the second file path of the system page development management device with the page resource data corresponding to the secondary development page.
In this embodiment, the page resource data may be a transliteration type scripting language JS file, a cascading style sheet CSS file, a Java language archive JAR package, or a CLASS file, which is not limited herein.
In this embodiment, the third file path may be the same as the fourth file path, and when the third file path is the same as the fourth file path, that is, when the page metadata script data and the page resource data are backed up in the same file path, there is no need to separately search when searching the page metadata script data and the page resource data, which saves system resources.
In this embodiment, the steps 206-208 are optional steps. For example, when the secondary development page data needs to be restored, the system page development management device executes the corresponding steps, and in practical application, the system page development management device may back up only the relevant data without executing the restoration steps.
In the embodiment of the application, the system page development management device replaces the page element data script data under the third file path into the database through the version restoring instruction, and replaces the page resource data under the fourth file path into the second file path, so that the backed-up secondary development page can be restored, and the operability of a user is improved.
In the embodiment of the application, the system page development management device can back up a plurality of secondary development pages through the newly added version instruction, and can select one or more secondary development pages for restoring the back-up through the version restoring instruction, so that the switching of a plurality of product schemes, namely the switching among a plurality of secondary development pages, is realized.
In this embodiment of the application, the system page development management device may also be a server, a computer, or a network device, and is not limited herein.
The above describes a system page development management method in an embodiment of the present application, and the following describes a system page development management apparatus in an embodiment of the present application, with reference to fig. 3, an embodiment of the system page development management apparatus in an embodiment of the present application includes:
a receivingunit 301, configured to receive a new version instruction;
the searchingunit 302 is configured to search for the page information of the secondary development according to the newly added version instruction;
an obtainingunit 303, configured to obtain page generation data according to the page information;
a savingunit 304, configured to save the page generation data under the first file path.
Referring to fig. 4, another embodiment of the page development management apparatus in the embodiment of the present application includes:
a receiving unit 401, configured to receive a new version instruction;
the searching unit 405 is configured to search page information of the secondary development according to the newly added version instruction;
an obtaining unit 402, configured to obtain page generation data according to the page information;
a saving unit 403, configured to save the page generation data in the first file path;
the page generation data comprises page metadata script data and page resource data;
the obtaining unit 402 is specifically configured to obtain corresponding page metadata script data in a database according to the page information;
the obtaining unit 402 is specifically configured to obtain page resource data in a second file path according to the page information;
the first file path comprises a third file path and a fourth file path;
the saving unit 403 is specifically configured to save the page metadata script data in the third file path;
the saving unit 403 is specifically configured to save the page resource data in the fourth file path;
the receiving unit 401 is further configured to receive a restore version instruction;
the system page development management device further comprises:
a replacing unit 404, configured to replace the page metadata script data stored in the third file path into the database;
a replacing unit 404, further configured to replace the page resource data stored in the fourth file path into the second file path;
the third file path is the same as the fourth file path;
the searching unit 405 is specifically configured to search page element data script data in the database according to the page information;
the page resource data includes at least one of:
a JS file of an transliteration script language, a CSS file of a cascading style sheet, and a JAR package or CLASS file of a Java language filing.
The operations performed by the units in the system page management apparatus are similar to those described in the foregoing embodiment shown in fig. 2, and are not described again here.
Fig. 5 is a schematic structural diagram of a computer device according to an embodiment of the present disclosure, where thecomputer device 500 may include one or more Central Processing Units (CPUs) 501 and amemory 505, and one or more applications or data are stored in thememory 505.
Memory 505 may be volatile storage or persistent storage, among others. The program stored inmemory 505 may include one or more modules, each of which may include a sequence of instructions for operating on a computer device. Still further, thecentral processor 501 may be arranged in communication with thememory 505 to execute a series of instruction operations in thememory 505 on thecomputer device 500.
Thecomputer apparatus 500 may also include one ormore power supplies 502, one or more wired or wireless network interfaces 503, one or more input-output interfaces 504, and/or one or more operating systems, such as Windows ServerTM, Mac OS XTM, UnixTM, LinuxTM, FreeBSDTM, etc.
Thecentral processing unit 501 may perform the operations performed by the system page development management apparatus in the embodiments shown in fig. 1 or fig. 2, which are not described herein again.
The embodiment of the present application further provides a computer-readable storage medium, on which a computer program is stored, where the computer program, when executed by a computer, implements the method flow in any of the above method embodiments.
It is clear to those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the several embodiments provided in the present application, it should be understood that the disclosed system, apparatus and method may be implemented in other manners. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the units is only one logical division, and other divisions may be realized in practice, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
The integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present application may be substantially implemented or contributed to by the prior art, or all or part of the technical solution may be embodied in a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present application. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a read-only memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and various other media capable of storing program codes.