CN113626392A - Method and device for updating document data, electronic equipment and storage medium - Google Patents

Method and device for updating document data, electronic equipment and storage medium Download PDF

Info

Publication number
CN113626392A
CN113626392A CN202111034106.XA CN202111034106A CN113626392A CN 113626392 A CN113626392 A CN 113626392A CN 202111034106 A CN202111034106 A CN 202111034106A CN 113626392 A CN113626392 A CN 113626392A
Authority
CN
China
Prior art keywords
document
data
executable script
interface
target service
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.)
Pending
Application number
CN202111034106.XA
Other languages
Chinese (zh)
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.)
Weimin Insurance Agency Co Ltd
Original Assignee
Weimin Insurance Agency 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 Weimin Insurance Agency Co Ltd filed Critical Weimin Insurance Agency Co Ltd
Priority to CN202111034106.XA priority Critical patent/CN113626392A/en
Publication of CN113626392A publication Critical patent/CN113626392A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/16File or folder operations, e.g. details of user interfaces specifically adapted to file systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/16File or folder operations, e.g. details of user interfaces specifically adapted to file systems
    • G06F16/168Details of user interfaces specifically adapted to file systems, e.g. browsing and visualisation, 2d or 3d GUIs
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/17Details of further file system functions

Abstract

The application provides a method and a device for updating document data, an electronic device and a storage medium, wherein the method comprises the following steps: acquiring an executable script, wherein the executable script is compiled by adopting a script language and is used for acquiring a document of a target service from a data warehouse according to a document interface; under the condition that a document display window of a target service is started in a target application, a second document of the target service is acquired from a data warehouse according to a document interface by executing an executable script, wherein the second document is a document of the latest version of the target service currently stored in the data warehouse; and displaying the second document in the document display window. Through the method and the device, the problems that manual document updating in the related technology causes waste of human resources and document updating cannot be synchronized in real time are solved.

Description

Method and device for updating document data, electronic equipment and storage medium
Technical Field
The present application relates to the field of data processing, and in particular, to a method and an apparatus for updating document data, an electronic device, and a storage medium.
Background
At present, when a user performs various interactions and updates a document, the user needs to manually change a plain text format written file of a webpage at a front end and submit and publish the file again to a document generation website system after updating a serialization protocol at a back end, and then the updated document can be displayed on a webpage at a web end.
Therefore, the related technology can cause that after the serialization protocol is updated each time, the document is written in the text format which needs to be manually updated, which wastes too much human resources and can not realize real-time synchronous display during file updating.
Therefore, the related art has the problems that documents are written in a plain text format and need to be manually updated every time a serialization protocol is updated, so that human resources are wasted, and the documents cannot be updated synchronously in real time.
Disclosure of Invention
The application provides a document data updating device, a storage medium and electronic equipment, which are used for at least solving the problems that human resources are wasted and the document updating cannot be synchronized in real time in the related technology.
According to an aspect of an embodiment of the present application, there is provided a method of document data update, the method including: acquiring an executable script, wherein the executable script is compiled by adopting a script language and is used for acquiring a document of a target service from a data warehouse according to a document interface; under the condition that a document display window of the target service is started in a target application, acquiring a second document of the target service from the data warehouse according to the document interface by executing the executable script, wherein the second document is a document of a latest version of the target service currently stored in the data warehouse; and displaying the second document in the document display window.
According to another aspect of the embodiments of the present application, there is also provided an apparatus for document data update, the apparatus including: the system comprises a first acquisition unit, a second acquisition unit and a third acquisition unit, wherein the first acquisition unit is used for acquiring an executable script, and the executable script is compiled by adopting a script language and is used for acquiring a document of a target service from a data warehouse according to a document interface; a second obtaining unit, configured to, when a document display window of the target service is started in a target application, obtain, according to the document interface, a second document of the target service from the data repository by executing the executable script, where the second document is a document of a latest version of the target service currently stored in the data repository; and the first display unit is used for displaying the second document in the document display window.
Optionally, the first display unit comprises: the analysis module is used for analyzing the document data in the second document into a preset data structure; the conversion module is used for converting the preset data structure into a second hypertext markup element; the rendering module is used for rendering an updating page corresponding to the second hypertext markup element; and the display module is used for displaying the update page in the document display window.
Optionally, the apparatus further comprises: a third obtaining unit, configured to obtain a first document before obtaining the executable script, where the first document includes the executable script; the analysis unit is used for analyzing the document data in the first document by using a file generation tool and converting the analyzed document data into a first hypertext markup element; a second presentation unit for presenting the rendered first hypertext markup element to the update page.
Optionally, the apparatus further comprises: a fourth obtaining unit, configured to obtain the identification parameter in the executable script and the identification parameter of the second document before the converting of the document data in the second document into a hypertext markup element; and the stopping unit is used for stopping analyzing the document data corresponding to the identification parameter in the second document into the preset data structure under the condition that the identification parameter in the executable script is the same as the identification parameter of the second document.
Optionally, the rendering module comprises: the acquiring subunit is used for acquiring the request parameters in the executable script; a matching subunit, configured to match the request parameter with a preset dimension parameter, where the preset dimension includes: a service dimension and an interface dimension; and the generating subunit is used for generating at least one updating page by using the second hypertext markup element according to the matching result.
Optionally, the generating subunit comprises: the first rendering submodule is used for rendering a plurality of updating pages in a list form according to a plurality of times of rendering instructions requested in the service dimension under the condition that the request parameter is matched with the parameter corresponding to the service dimension; or the second rendering submodule is used for rendering the updated page in a single form according to a request specified rendering instruction in the interface dimension under the condition that the request parameter is matched with the parameter corresponding to the interface dimension.
Optionally, the second obtaining unit includes: the sending module is used for sending request data to the data warehouse by using a transmission protocol; and the receiving module is used for receiving the second document by using the document interface, wherein the second document is feedback information returned according to the request data.
According to another aspect of the embodiments of the present application, there is also provided an electronic device, including a processor, a communication interface, a memory, and a communication bus, where the processor, the communication interface, and the memory communicate with each other through the communication bus; wherein the memory is used for storing the computer program; a processor for executing the steps of document data update in any of the above embodiments by running the computer program stored on the memory.
According to still another aspect of embodiments of the present application, there is further provided a computer-readable storage medium, in which a computer program is stored, where the computer program is configured to execute the step of updating document data in any of the above embodiments when the computer program runs.
According to yet another aspect of an embodiment of the present application, there is also provided a computer program product or a computer program comprising computer instructions stored in a computer readable storage medium; the processor of the computer device reads the computer instructions from the computer-readable storage medium, and executes the computer instructions to cause the computer device to perform the steps of document data update in any of the embodiments described above.
In the embodiment of the application, the executable script is obtained by pulling the document of the latest version from the data warehouse in a mode of adopting the executable script, wherein the executable script is compiled by adopting a script language and is used for obtaining the document of the target service from the data warehouse according to a document interface; under the condition that a document display window of a target service is started in a target application, a second document of the target service is acquired from a data warehouse according to a document interface by executing an executable script, wherein the second document is a document of the latest version of the target service currently stored in the data warehouse; and displaying the second document in the document display window. According to the embodiment of the application, every time the document display window is accessed, the second document of the latest version corresponding to the target service is acquired from the data warehouse by using the executable script, and the second document is displayed on the display window, so that the data does not need to be pulled manually, the purpose of updating the document data in real time is achieved, and the problems that in the related technology, the documents are updated manually, human resources are wasted, and the documents cannot be updated synchronously in real time are solved.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the invention and together with the description, serve to explain the principles of the invention.
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, and it is obvious for those skilled in the art that other drawings can be obtained according to the drawings without inventive exercise.
FIG. 1 is a schematic flow chart diagram illustrating an alternative method for updating document data according to an embodiment of the present application;
FIG. 2 is a schematic diagram of an alternative method of document data update according to an embodiment of the application;
FIG. 3 is a flowchart illustrating a further alternative method for updating document data according to an embodiment of the present application;
fig. 4 is a block diagram of an alternative apparatus for document data update according to an embodiment of the present application;
fig. 5 is a block diagram of an alternative electronic device according to an embodiment of the present application.
Detailed Description
In order to make the technical solutions better understood by those skilled in the art, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only partial embodiments of the present application, but not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
It should be noted that the terms "first," "second," and the like in the description and claims of this application and in the drawings described above are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the application described herein are capable of operation in sequences other than those illustrated or described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
When a user carries out various interactions and document updating on a document, the user needs to manually change a plain text format of a webpage at the front end to write a file after updating a serialization protocol at the rear end, and then submits and releases the file to a document generation website system, and then the updated document can be displayed on the webpage at the web end, so that the problems of human resource waste and incapability of real-time synchronous document updating are caused. The user may refer to a developer, or may be a person other than a developer.
In order to solve the above problem, an embodiment of the present application provides a method for updating document data, where the method may be executed on a background server side of a user side, as shown in fig. 1, fig. 1 is a schematic flowchart of an optional method for updating document data according to an embodiment of the present application, and a flow of the method may include the following steps:
step S101, an executable script is obtained, wherein the executable script is written by adopting a script language and is used for obtaining the document of the target service from the data warehouse according to a document interface.
Optionally, git is a unified code management platform, and a git warehouse (i.e. a data warehouse) stores user-written codes. When a user revises and updates the displayed document, the internal interface unified management platform queries the document interface which is currently responsible, and then the user sends the js script (namely the executable script) edited by the user to the git warehouse through the document interface.
Since the git warehouse is stored in the background server side of the user side, the background server of the user side can also obtain the executable script after the user sends the executable script to the git warehouse. The executable script is written by adopting a script language and is used for acquiring the document of the target service from the data warehouse according to the inquired document interface.
Step S102, under the condition that the document display window of the target service is started in the target application, the executable script is executed, and the second document of the target service is obtained from the data warehouse according to the document interface, wherein the second document is the document of the latest version of the target service currently stored in the data warehouse.
Optionally, in the target application at the front end of the user side, when a document display window of a target service is started, the background server of the user side may obtain the started prompt information, at this time, the background server may execute the obtained executable script, and obtain, by executing the executable script, the document of the latest version of the target service currently stored from the data repository according to the document interface, as the second document. The target application may be various app software, the target business may be various service businesses, such as insurance business, and the document displayed in the document display window may be a statistical list document of the insurance business, and the like.
Optionally, the way that the executable script pulls the latest version of the document corresponding to the target service from the data warehouse may be: the executable script edits the display document every time, and after the display document is written into the executable script, the executable script can perform name mode conversion when the document is stored, for example, the executable script writes the document named xxxx1.0 for the first time, and writes the document named xxxx2.0 for the second time, so that the document of the latest version can be easily obtained according to the number of the document named in the executable script.
Step S103, displaying the second document on the document display window.
Optionally, after the second document is obtained, the second document is rendered and displayed in the document display window by using the page rendering tool.
It should be noted that, in the embodiment of the present application, a user enters a platform for modifying a document by using a document interface, then writes an executable script, and obtains a second document by executing the executable script under the condition that a document display window of a target service is started in a target application, so that an automatic interaction between the user and the document can be achieved.
In the embodiment of the application, the executable script is obtained by pulling the document of the latest version from the data warehouse in a mode of adopting the executable script, wherein the executable script is compiled by adopting a script language and is used for obtaining the document of the target service from the data warehouse according to a document interface; under the condition that a document display window of a target service is started in a target application, a second document of the target service is acquired from a data warehouse according to a document interface by executing an executable script, wherein the second document is a document of the latest version of the target service currently stored in the data warehouse; and displaying the second document in the document display window. According to the embodiment of the application, every time the document display window is accessed, the second document of the latest version corresponding to the target service is acquired from the data warehouse by using the executable script, and the second document is displayed on the display window, so that the data does not need to be pulled manually, the purpose of updating the document data in real time is achieved, and the problems that in the related technology, the documents are updated manually, human resources are wasted, and the documents cannot be updated synchronously in real time are solved.
As an alternative embodiment, presenting the second document in the document presentation window includes:
analyzing the document data in the second document into a preset data structure;
converting the preset data structure into a second hypertext markup element;
rendering an updating page corresponding to the second hypertext markup element;
and displaying the updating page in the document display window.
Optionally, the document data in the second document is first converted into a preset data structure, such as a json (JavaScript object notation) data structure format, then the json data structure format is converted into a second hypertext markup element, then a corresponding updated page is rendered according to the second hypertext markup element, and the updated page is displayed in the document display window.
In the embodiment of the application, the update page is displayed in the document display window, so that users and other users can conveniently check the document update condition in real time.
As an alternative embodiment, before the executable script is obtained, the method further comprises:
acquiring a first document, wherein the first document contains an executable script;
analyzing the document data in the first document by using a file generation tool, and converting the analyzed document data into a first hypertext markup element;
the rendered first hypertext markup element is shown to the update page.
Optionally, in this embodiment of the present application, a first document is first obtained, where the first document includes an executable script. It should be noted that the first document is a plain text writing document, and the executable script may be written in the first document.
And analyzing the document data in the first document by using a file generation tool (such as docsolid), converting the analyzed document data into a first hypertext markup element, and rendering the first hypertext markup element to an updated page.
It can be understood that, in the case that each time the document presentation window for acquiring the target service is started, the docswift re-parses the document data in the first document and renders the document data to the update page by using the rendering tool, so that the content of the first document is also presented in the update page.
As an alternative embodiment, before parsing the document data in the second document into the preset data structure, the method further comprises:
acquiring identification parameters in the executable script and identification parameters of a second document;
and under the condition that the identification parameters in the executable script are the same as the identification parameters of the second document, stopping analyzing the document data corresponding to the identification parameters in the second document into a preset data structure.
Optionally, the internal interface uniformly manages all services in the platform scanning platform, generates a unique ID for each service, and then obtains a link of the currently loaded executable script inside the executable script through a built-in browser method document.
Acquiring an identification parameter in the link, such as ID1, comparing the ID1 with an identification parameter of a second document, such as ID2, and in the case that the ID1 is the same as the ID2, indicating that rendering of the current page has been completed before the current page rendering, so that subsequent logic operations are stopped, such as stopping parsing document data corresponding to the identification parameter in the second document into a preset data structure, so as to prevent a situation of repeatedly rendering pages.
In the embodiment of the application, by comparing the identification parameter in the script link with the identification parameter in the second document, under the condition that the identification parameter in the script link is determined to be the same as the identification parameter in the second document, the subsequent page rendering operation of the second document is not executed any more, and the resource waste caused by repeated rendering is avoided.
As an alternative embodiment, rendering the updated page corresponding to the second hypertext markup element includes:
acquiring request parameters in the executable script;
matching the request parameters with preset dimension parameters, wherein the preset dimension comprises: a service dimension and an interface dimension;
generating at least one updated page by using the second hypertext markup element according to the matching result;
wherein, according to the matching result, generating at least one updating page comprises: under the condition that the request parameters are matched with the parameters corresponding to the service dimensions, rendering a plurality of updating pages in a list form; or in the case that the request parameter is matched with the corresponding parameter of the interface dimension, an updating page is rendered in a single form.
Optionally, in this embodiment of the present application, a request dimension corresponding to a request parameter may be obtained through the request parameter in the script link, and specifically, in this embodiment of the present application, the request parameter in the script link in the executable script may be obtained, the request parameter is matched with a preset dimension parameter preset in this embodiment of the present application, such as byte matching, and then a page rendering is generated according to a matching result.
Wherein, preset dimension includes: service dimensions and interface dimensions. It should be noted that the page rendering of the interface dimension means that only a certain page corresponding to the interface is rendered. And page rendering of the service dimension means that all pages indicated by the service list are subjected to page rendering.
Optionally, generally, there are more corresponding page update requests in a certain service dimension, so in the embodiment of the present application, under the condition that the request parameter matches with the parameter corresponding to the service dimension, for example, the byte matching degree is 100%, at this time, multiple rendering instructions are requested in the service dimension, and multiple update pages are rendered in a list form; or, under the condition that the request parameter is matched with the parameter corresponding to the interface dimension, for example, the byte matching degree is 100%, an updated page required to be rendered by the designated rendering instruction is rendered in a single form according to the designated rendering instruction requested in the interface dimension. It is understood that the single form is a representation corresponding to the aforementioned list form, and the single form means that there is only one update page currently rendered, and the update page corresponds to the interface.
In the embodiment of the application, the subsequent rendering of a single element or a list element is determined by judging whether the request parameter dimension is the service dimension or the interface dimension, so that the page can be purposefully rendered, and the problem of complex maintenance workload due to overlarge data volume is prevented.
As an alternative embodiment, obtaining the second document of the target business from the data repository according to the document interface includes:
sending request data to a data warehouse by using a transmission protocol;
and receiving a second document by using the document interface, wherein the second document is feedback information returned according to the request data.
Optionally, in this embodiment of the present application, request data is sent to the data warehouse by using a transmission protocol (such as a hypertext transfer protocol), and a latest document after the serialization protocol is updated is requested, at this time, a second document fed back according to the request data is received by using the document interface, where the second document is a latest document in the target service corresponding to the request data.
In the embodiment of the application, the latest data in the corresponding service is requested through the hypertext transfer protocol, so that the real-time performance of the data is ensured.
As an alternative embodiment, as shown in fig. 2, fig. 2 is a schematic diagram of another alternative method for updating document data according to an embodiment of the present application, where the method is an overall flow of updating the whole document data described from the product side, and specifically includes:
the internal interface management platform scans all the services in a company, generates a unique ID for each service to obtain a corresponding executable script, a user queries an interface in charge of the internal interface management platform, obtains the executable script embedded in an md (markdown) file (namely, a first document in each embodiment), writes the executable script into the md file and submits the md file to a git warehouse, and the docsify obtains the md file added with the executable script and analyzes and renders the md file to a page through the docsify.
As an alternative embodiment, as shown in fig. 3, fig. 3 is a schematic flowchart of a further alternative method for updating document data according to an embodiment of the present application, where the method is an overall flow of updating the whole document data described from the technical side, and specifically includes:
1. the internal interface management platform scans all the services in the company, generates a unique ID for each service, and simultaneously generates an executable script link carrying the ID and other parameters.
2. The user obtains the executable script of the required service from the internal interface management platform.
3. The user writes the executable script into the md file and submits it to the git repository, understandably writing the executable script link carrying the ID and other parameters into the md file.
And 4, the docsify system pulls the md file in the git warehouse and analyzes the md file into html elements through docsify.
And 5, analyzing and executing the executable script in the md file while analyzing the md file by the docsify.
5.1 the executable script obtains the link of the currently loaded executable script through the built-in method document of the browser.
5.2 analyzing the parameters in the link, judging whether the current page to be rendered has the elements marked by the ID through the ID in the parameters, and stopping running the subsequent logic if the current page to be rendered has the elements marked by the ID, so as to prevent repeated rendering.
5.3 judge that the request dimension is the service dimension or the interface dimension through the parameters in the link to decide a single element or a list element for subsequent rendering, thereby preventing the maintenance workload from being complicated when the data volume is overlarge.
And 5.4, requesting the latest data in the document in the corresponding service through http, and analyzing the latest data into json language to ensure the real-time performance of the data.
5.5 generating an interactive html element through the json language, rendering the html element to a page, and simultaneously reflecting the document updated again by the subsequent user to the page in real time.
6. Each time a user updates a document, it is submitted to the git repository.
7. And the user enters the docsify system, views the document page and displays the latest pulled data on the page.
It should be noted that, for simplicity of description, the above-mentioned method embodiments are described as a series of acts or combination of acts, but those skilled in the art will recognize that the present application is not limited by the order of acts described, as some steps may occur in other orders or concurrently depending on the application. Further, those skilled in the art should also appreciate that the embodiments described in the specification are preferred embodiments and that the acts and modules referred to are not necessarily required in this application.
Through the above description of the embodiments, those skilled in the art can clearly understand that the method according to the above embodiments can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware, but the former is a better implementation mode in many cases. Based on such understanding, the technical solutions of the present application may be embodied in the form of a software product, which is stored in a storage medium (e.g., a ROM (Read-Only Memory)/RAM (Random Access Memory), a magnetic disk, an optical disk) and includes several instructions for enabling a terminal device (e.g., a mobile phone, a computer, a server, or a network device) to execute the methods of the embodiments of the present application.
According to another aspect of the embodiments of the present application, there is also provided an apparatus for document data update for implementing the method for document data update described above. Fig. 4 is a block diagram of an optional apparatus for document data update according to an embodiment of the present application, and as shown in fig. 4, the apparatus may include:
a first obtaining unit 401, configured to obtain an executable script, where the executable script is written in a scripting language and is used to obtain a document of a target service from a data repository according to a document interface;
a second obtaining unit 402, configured to, in a case where a document display window of a target service is started in a target application, obtain, according to a document interface, a second document of the target service by executing an executable script, where the second document is a document of a latest version of the target service currently stored in the data repository;
the first display unit 403 is configured to display the second document in the document display window.
It should be noted that the first obtaining unit 401 in this embodiment may be configured to execute the step S101, the second obtaining unit 402 in this embodiment may be configured to execute the step S102, and the first displaying unit 403 in this embodiment may be configured to execute the step S103.
Through the module, the executable script is obtained in a mode of pulling the document of the latest version from the data warehouse by adopting the executable script, wherein the executable script is compiled by adopting a script language and is used for obtaining the document of the target service from the data warehouse according to a document interface; under the condition that a document display window of a target service is started in a target application, a second document of the target service is acquired from a data warehouse according to a document interface by executing an executable script, wherein the second document is a document of the latest version of the target service currently stored in the data warehouse; and displaying the second document in the document display window. According to the embodiment of the application, every time the document display window is accessed, the second document of the latest version corresponding to the target service is acquired from the data warehouse by using the executable script, and the second document is displayed on the display window, so that the data does not need to be pulled manually, the purpose of updating the document data in real time is achieved, and the problems that in the related technology, the documents are updated manually, human resources are wasted, and the documents cannot be updated synchronously in real time are solved.
As an alternative embodiment, the first display unit 403 includes: the analysis module is used for analyzing the document data in the second document into a preset data structure; the conversion module is used for converting the preset data structure into a second hypertext markup element; the rendering module is used for rendering an updating page corresponding to the second hypertext marking element; and the display module is used for displaying the update page in the document display window.
As an alternative embodiment, the apparatus further comprises: the third acquiring unit is used for acquiring a first document before acquiring the executable script, wherein the first document contains the executable script; the analysis unit is used for analyzing the document data in the first document by using a file generation tool and converting the analyzed document data into a first hypertext markup element; and the second display unit is used for displaying the rendered first hypertext markup element to the update page.
As an alternative embodiment, the apparatus further comprises: a fourth acquiring unit, configured to acquire the identification parameter in the executable script and the identification parameter of the second document before converting the document data in the second document into the hypertext markup element; and the stopping unit is used for stopping analyzing the document data corresponding to the identification parameter in the second document into a preset data structure under the condition that the identification parameter in the executable script is the same as the identification parameter of the second document.
As an alternative embodiment, the rendering module comprises: the acquiring subunit is used for acquiring the request parameters in the executable script; a matching subunit, configured to match the request parameter with a preset dimension parameter, where the preset dimension includes: a service dimension and an interface dimension; and the generating subunit is used for generating at least one updating page by utilizing the second hypertext markup element according to the matching result.
As an alternative embodiment, the generating subunit includes: the first rendering submodule is used for rendering a plurality of updating pages in a list form according to a plurality of rendering instructions requested in the service dimension under the condition that the request parameter is matched with the corresponding parameter of the service dimension; or the second rendering submodule is used for rendering an updated page in a single form according to a request specified rendering instruction in the interface dimension under the condition that the request parameter is matched with the parameter corresponding to the interface dimension.
As an alternative embodiment, the second obtaining unit includes: the sending module is used for sending request data to the data warehouse by using a transmission protocol; and the receiving module is used for receiving a second document by using the document interface, wherein the second document is feedback information returned according to the request data.
It should be noted here that the modules described above are the same as the examples and application scenarios implemented by the corresponding steps, but are not limited to the disclosure of the above embodiments.
According to still another aspect of the embodiments of the present application, there is also provided an electronic device, which may be a server, a terminal, or a combination thereof, for implementing the method for document data update described above.
Fig. 5 is a block diagram of an alternative electronic device according to an embodiment of the present application, as shown in fig. 5, including a processor 501, a communication interface 502, a memory 503, and a communication bus 504, where the processor 501, the communication interface 502, and the memory 503 are communicated with each other through the communication bus 504, where,
a memory 503 for storing a computer program;
the processor 501, when executing the computer program stored in the memory 503, implements the following steps:
acquiring an executable script, wherein the executable script is compiled by adopting a script language and is used for acquiring a document of a target service from a data warehouse according to a document interface;
under the condition that a document display window of a target service is started in a target application, a second document of the target service is acquired from a data warehouse according to a document interface by executing an executable script, wherein the second document is a document of the latest version of the target service currently stored in the data warehouse;
and displaying the second document in the document display window.
Alternatively, in this embodiment, the communication bus may be a PCI (Peripheral Component Interconnect) bus, an EISA (Extended Industry Standard Architecture) bus, or the like. The communication bus may be divided into an address bus, a data bus, a control bus, etc. For ease of illustration, only one thick line is shown in FIG. 5, but this is not intended to represent only one bus or type of bus.
The communication interface is used for communication between the electronic equipment and other equipment.
The memory may include RAM, and may also include non-volatile memory (non-volatile memory), such as at least one disk memory. Alternatively, the memory may be at least one memory device located remotely from the processor.
As an example, as shown in fig. 5, the memory 503 may include, but is not limited to, a first obtaining unit 401, a second obtaining unit 402, and a first presenting unit 403 in the device for updating document data. In addition, the device may further include, but is not limited to, other module units in the above apparatus for updating document data, which is not described in this example again.
The processor may be a general-purpose processor, and may include but is not limited to: a CPU (Central Processing Unit), an NP (Network Processor), and the like; but also a DSP (Digital Signal Processing), an ASIC (Application Specific Integrated Circuit), an FPGA (Field Programmable Gate Array) or other Programmable logic device, discrete Gate or transistor logic device, discrete hardware component.
In addition, the electronic device further includes: and a display for a result of the document data update.
Optionally, the specific examples in this embodiment may refer to the examples described in the above embodiments, and this embodiment is not described herein again.
It can be understood by those skilled in the art that the structure shown in fig. 5 is only an illustration, and the device implementing the method for updating document data may be a terminal device, and the terminal device may be a terminal device such as a smart phone (e.g., an Android phone, an iOS phone, etc.), a tablet computer, a palm computer, a Mobile Internet Device (MID), a PAD, and the like. Fig. 5 is a diagram illustrating a structure of the electronic device. For example, the terminal device may also include more or fewer components (e.g., network interfaces, display devices, etc.) than shown in FIG. 5, or have a different configuration than shown in FIG. 5.
Those skilled in the art will appreciate that all or part of the steps in the methods of the above embodiments may be implemented by a program instructing hardware associated with the terminal device, where the program may be stored in a computer-readable storage medium, and the storage medium may include: flash disk, ROM, RAM, magnetic or optical disk, and the like.
According to still another aspect of an embodiment of the present application, there is also provided a storage medium. Alternatively, in the present embodiment, the storage medium described above may be used for program codes for executing a method of document data update.
Optionally, in this embodiment, the storage medium may be located on at least one of a plurality of network devices in a network shown in the above embodiment.
Optionally, in this embodiment, the storage medium is configured to store program code for performing the following steps:
acquiring an executable script, wherein the executable script is compiled by adopting a script language and is used for acquiring a document of a target service from a data warehouse according to a document interface;
under the condition that a document display window of a target service is started in a target application, a second document of the target service is acquired from a data warehouse according to a document interface by executing an executable script, wherein the second document is a document of the latest version of the target service currently stored in the data warehouse;
and displaying the second document in the document display window.
Optionally, the specific example in this embodiment may refer to the example described in the above embodiment, which is not described again in this embodiment.
Optionally, in this embodiment, the storage medium may include, but is not limited to: various media capable of storing program codes, such as a U disk, a ROM, a RAM, a removable hard disk, a magnetic disk, or an optical disk.
According to yet another aspect of an embodiment of the present application, there is also provided a computer program product or a computer program comprising computer instructions stored in a computer readable storage medium; the processor of the computer device reads the computer instructions from the computer readable storage medium, and the processor executes the computer instructions to cause the computer device to perform the method steps of document data update in any of the embodiments described above.
The above-mentioned serial numbers of the embodiments of the present application are merely for description and do not represent the merits of the embodiments.
The integrated unit in the above embodiments, if implemented in the form of a software functional unit and sold or used as a separate product, may be stored in the above computer-readable storage medium. Based on such understanding, the technical solution of the present application may be substantially implemented or a part of or all or part of the technical solution may be embodied in the form of a software product stored in a storage medium, and including a plurality of instructions for causing one or more computer devices (which may be personal computers, servers, or network devices, etc.) to execute all or part of the steps of the method for updating document data of the embodiments of the present application.
In the above embodiments of the present application, the descriptions of the respective embodiments have respective emphasis, and for parts that are not described in detail in a certain embodiment, reference may be made to related descriptions of other embodiments.
In the several embodiments provided in the present application, it should be understood that the disclosed client may be implemented in other manners. The above-described embodiments of the apparatus are merely illustrative, and for example, a division of a unit is merely a division of a logic function, and an actual implementation may have another division, 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, units or modules, and may be in an electrical 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, and may also be distributed on a plurality of network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution provided in 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 foregoing is only a preferred embodiment of the present application and it should be noted that those skilled in the art can make several improvements and modifications without departing from the principle of the present application, and these improvements and modifications should also be considered as the protection scope of the present application.

Claims (10)

1. A method of document data update, the method comprising:
acquiring an executable script, wherein the executable script is compiled by adopting a script language and is used for acquiring a document of a target service from a data warehouse according to a document interface;
under the condition that a document display window of the target service is started in a target application, acquiring a second document of the target service from the data warehouse according to the document interface by executing the executable script, wherein the second document is a document of a latest version of the target service currently stored in the data warehouse;
and displaying the second document in the document display window.
2. The method of claim 1, wherein said presenting the second document in the document presentation window comprises:
analyzing the document data in the second document into a preset data structure;
converting the preset data structure into a second hypertext markup element;
rendering an updating page corresponding to the second hypertext marking element;
and displaying the updating page in the document display window.
3. The method of claim 2, wherein prior to said obtaining an executable script, the method further comprises:
acquiring a first document, wherein the first document comprises the executable script;
analyzing the document data in the first document by using a file generation tool, and converting the analyzed document data into a first hypertext markup element;
displaying the first hypertext markup element rendered to the update page.
4. The method of claim 2, wherein prior to said parsing the document data in the second document into a preset data structure, the method further comprises:
acquiring identification parameters in the executable script and identification parameters of the second document;
and under the condition that the identification parameters in the executable script are the same as the identification parameters of the second document, stopping analyzing the document data corresponding to the identification parameters in the second document into the preset data structure.
5. The method of claim 2, wherein rendering the updated page corresponding to the second hypertext markup element comprises:
acquiring request parameters in the executable script;
matching the request parameter with a preset dimension parameter, wherein the preset dimension comprises: a service dimension and an interface dimension;
and generating at least one updating page by utilizing the second hypertext markup element according to a matching result.
6. The method of claim 5, wherein generating at least one of the updated pages using the second hypertext markup element according to the matching result comprises:
under the condition that the request parameters are matched with the parameters corresponding to the service dimensions, rendering a plurality of updating pages in a list form according to a plurality of times of rendering instructions requested in the service dimensions;
alternatively, the first and second electrodes may be,
and under the condition that the request parameter is matched with the parameter corresponding to the interface dimension, rendering one updated page in a single form according to a request specified rendering instruction in the interface dimension.
7. The method of claim 1, wherein said obtaining a second document of the target service from the data repository according to the document interface comprises:
sending request data to the data warehouse by using a transmission protocol;
and receiving the second document by using the document interface, wherein the second document is feedback information returned according to the request data.
8. An apparatus for document data update, characterized in that the apparatus comprises:
the system comprises a first acquisition unit, a second acquisition unit and a third acquisition unit, wherein the first acquisition unit is used for acquiring an executable script, and the executable script is compiled by adopting a script language and is used for acquiring a document of a target service from a data warehouse according to a document interface;
a second obtaining unit, configured to, when a document display window of the target service is started in a target application, obtain, according to the document interface, a second document of the target service from the data repository by executing the executable script, where the second document is a document of a latest version of the target service currently stored in the data repository;
and the first display unit is used for displaying the second document in the document display window.
9. An electronic device comprising a processor, a communication interface, a memory and a communication bus, wherein said processor, said communication interface and said memory communicate with each other via said communication bus,
the memory for storing a computer program;
the processor for executing the steps of document data update of any one of claims 1 to 7 by executing the computer program stored on the memory.
10. A storage medium readable by a computer, in which a computer program is stored, wherein the computer program is configured to execute the steps of document data update as claimed in any one of claims 1 to 7 when executed.
CN202111034106.XA 2021-09-03 2021-09-03 Method and device for updating document data, electronic equipment and storage medium Pending CN113626392A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111034106.XA CN113626392A (en) 2021-09-03 2021-09-03 Method and device for updating document data, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111034106.XA CN113626392A (en) 2021-09-03 2021-09-03 Method and device for updating document data, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN113626392A true CN113626392A (en) 2021-11-09

Family

ID=78389064

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111034106.XA Pending CN113626392A (en) 2021-09-03 2021-09-03 Method and device for updating document data, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN113626392A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115268841A (en) * 2022-06-27 2022-11-01 北京五八信息技术有限公司 Data management method and device, electronic equipment and storage medium

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115268841A (en) * 2022-06-27 2022-11-01 北京五八信息技术有限公司 Data management method and device, electronic equipment and storage medium
CN115268841B (en) * 2022-06-27 2023-05-23 北京五八信息技术有限公司 Data management method, device, electronic equipment and storage medium

Similar Documents

Publication Publication Date Title
KR102105261B1 (en) Method and device for displaying interface data
CN106933722B (en) Webpage application monitoring method, server and system
CN109542427B (en) System customization method and device, electronic equipment and storage medium
US8234627B2 (en) System and method for expediting information display
US9268547B2 (en) Conditional logic for delivering computer-executable program instructions and content
CN105872083A (en) Method and system supporting server access by different types of clients as well as server
CN111222070B (en) Data processing method, device, equipment and storage medium
CN109359194B (en) Method and apparatus for predicting information categories
CN107508720B (en) Automatic testing method and device
CN103500210A (en) Method, device and browser for carrying out webpage loading
CN103530329A (en) Method and device for performing webpage loading and browsers
CN115065652B (en) Message reply method and device, storage medium and computer equipment
CA2846581A1 (en) Data infrastructure for providing interconnectivity between platforms, devices and operating systems
CN111680244A (en) Page display method and device, electronic equipment and computer readable storage medium
CN111506551A (en) Conference file extraction method and system and computer equipment
CN113626392A (en) Method and device for updating document data, electronic equipment and storage medium
CN112631564A (en) Content management system-based interface generation method, device, equipment and storage medium
CN113190229A (en) Method and device for generating government affair page
CN109101429B (en) Method and device for debugging browser page of set top box
CN103139298A (en) Method for transmitting network data and device
CN111124924A (en) API (application program interface) deployment method and device, electronic equipment and storage medium
CN110874278A (en) Embedding method of external system, workflow system, device and storage medium
CN112486482A (en) Page display method and device
CN111782993A (en) Page display method and device and server
US20220284371A1 (en) Method, device and medium for a business function page

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication