CN115688679A - Processing method and device for webpage embedded document based on RPA - Google Patents

Processing method and device for webpage embedded document based on RPA Download PDF

Info

Publication number
CN115688679A
CN115688679A CN202211179159.5A CN202211179159A CN115688679A CN 115688679 A CN115688679 A CN 115688679A CN 202211179159 A CN202211179159 A CN 202211179159A CN 115688679 A CN115688679 A CN 115688679A
Authority
CN
China
Prior art keywords
document
webpage
embedded
form data
rpa
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
CN202211179159.5A
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.)
Industrial and Commercial Bank of China Ltd ICBC
Original Assignee
Industrial and Commercial Bank of China Ltd ICBC
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 Industrial and Commercial Bank of China Ltd ICBC filed Critical Industrial and Commercial Bank of China Ltd ICBC
Priority to CN202211179159.5A priority Critical patent/CN115688679A/en
Publication of CN115688679A publication Critical patent/CN115688679A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Information Transfer Between Computers (AREA)

Abstract

The invention can be used in the technical field of application of robot process automation technology in finance, and provides a method and a device for processing webpage embedded documents based on RPA, wherein the corresponding method comprises the following steps: acquiring webpage form data embedded with a document; analyzing the webpage form data to generate webpage form data with a Json array format; and processing the embedded document of the webpage form data according to the webpage form data with the Json array format. According to the processing method and device for the webpage embedded document based on the RPA, provided by the invention, the defect of an RPA robot in the aspect of automatic filling of the webpage embedded document is made up by using a JavaScript technology, and business personnel are liberated from single and repeated copying, pasting and online document editing work, so that the repeated labor workload is reduced, and the business processing efficiency and the data entry accuracy are improved.

Description

Processing method and device for webpage embedded document based on RPA
Technical Field
The application belongs to the technical field of robot flow automation, particularly relates to the technical field of automatic processing of embedded office documents of webpages in robot flow automation, and particularly relates to a processing method and device of embedded documents of webpages based on RPA.
Background
The Robot Process Automation (RPA) simulates the interaction between a user and a computer by applying an externally provided interface, a win32 handle and web page element attributes of application software and combining operations such as mouse clicking and keyboard input, thereby realizing the automatic processing of a business Process. The RPA realizes the flow linkage between heterogeneous systems in a non-intrusive mode, does not damage the advantages of the original IT structure, and is widely applied to data migration and entry scenes, such as data migration and entry between a financial system A and a financial system B.
In the prior art, for the collection and entry of web page content, RPA is generally implemented by positioning element positions according to attributes or indexes of HTML tag elements. However, in many existing systems, such as electronic subscription systems, contract templates often change according to policies or other reasons, and information is displayed in a form of embedding office documents in web pages instead of using common web page elements such as texts, tables and forms to display information. For the application scenario of the automatic filling of the office document embedded in the webpage, the RPA robot cannot provide good support, cannot quickly position a specific position of a certain content in the document through the attribute or index of the HTML tag element, and at the moment, the document position needs to be positioned by means of OCR and the like, and then the content filling is performed, so that the process is complicated, and the requirements on technical personnel are high.
Disclosure of Invention
The method can be used in the technical field of application of the robot process automation technology in the aspect of finance, can also be used in any field except the financial field, can finish automatic input of the office document embedded in the webpage without the help of an OCR technology, is convenient, quick and technically friendly, particularly can be combined with the RPA technology, and then is applied to expanding the application scene of data migration and input of the RPA robot between heterogeneous systems.
In a first aspect, the present invention provides a method for processing a document embedded in a web page based on an RPA, the method including:
acquiring webpage form data embedded with a document;
analyzing the webpage form data to generate webpage form data with a Json array format;
and processing the embedded document of the webpage form data according to the webpage form data with the Json array format.
In one embodiment, the acquiring the data of the web form embedded with the document includes:
and acquiring an attribute value corresponding to the target element name in the webpage according to the webpage label index string and/or the webpage label attribute.
In an embodiment, before the obtaining an attribute value corresponding to a name of a target element in a web page according to a web page tag index string and/or a web page tag attribute, the method further includes:
generating a query condition according to the client code;
and acquiring the name of the target element according to the query condition.
In one embodiment, the parsing the web form data to generate web form data having a Json array format includes:
generating a key value according to the target element name;
generating a value according to the attribute value;
generating a key value pair according to the key value and the value corresponding to the key value;
and generating the webpage form data with the Json array format according to a plurality of key value pairs.
In one embodiment, processing the embedded document of the web form data according to the web form data with the Json array format includes:
determining html tags of sub-pages of the web page;
determining a sub-page of a target webpage according to the window object of the html tag;
determining an embedded document according to the sub-page;
and editing the embedded document according to the ActiveDocument attribute of the sub-page.
In one embodiment, the processing method of the RPA-based web page embedded document further includes:
judging whether the attribute value in the document is the same as the attribute value in the Json array or not;
and if so, editing the embedded document according to the ActiveDocument attribute of the sub-page.
In one embodiment, said determining said embedded document thereof from said sub-page comprises:
and starting from the initial page of the webpage, judging whether each sub-page contains the embedded document or not step by step downwards.
In a second aspect, the present invention provides an apparatus for processing a document embedded in a web page based on RPA, the apparatus comprising:
the form data acquisition module is used for acquiring webpage form data embedded with a document;
the form data analysis module is used for analyzing the webpage form data to generate webpage form data with a Json array format;
and the embedded document processing module is used for processing the embedded document of the webpage form data according to the webpage form data with the Json array format.
In one embodiment, the form data obtaining module includes:
and the attribute value acquisition unit is used for acquiring the attribute value corresponding to the target element name in the webpage according to the webpage label index string and/or the webpage label attribute.
In one embodiment, the apparatus for processing a document embedded in a web page based on RPA further includes:
the query condition generating module is used for generating a query condition according to the client code;
and the name acquisition module is used for acquiring the name of the target element according to the query condition.
In one embodiment, the form data parsing module includes:
the key value generating unit is used for generating a key value according to the target element name;
a value generating unit, configured to generate a value according to the attribute value;
the key value pair generating unit is used for generating a key value pair according to the key value and the value corresponding to the key value;
and the form data generation unit is used for generating the webpage form data with the Json array format according to the plurality of key value pairs.
In one embodiment, the inline document processing module comprises:
the tag obtaining unit is used for determining html tags of sub pages of the webpage;
the sub-page determining unit is used for determining a sub-page of the target webpage according to the window object of the html tag;
the embedded document determining unit is used for determining an embedded document according to the subpages;
and the document editing unit is used for editing the embedded document according to the ActiveDocument attribute of the sub-page.
In one embodiment, the processing device for RPA-based web page embedded documents further includes:
the attribute value judging module is used for judging whether the attribute value in the document is the same as the attribute value in the Json array or not;
and the embedded document editing unit is used for editing the embedded document according to the ActiveDocument attribute of the sub-page if the same.
In one embodiment, the embedded document determining unit includes:
and the embedded document determining subunit is used for downwards and gradually judging whether each subpage contains the embedded document or not from the initial page of the webpage.
In a third aspect, the present invention provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the processing method for the RPA-based web page embedded document when executing the program.
In a fourth aspect, the present invention provides a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, implements the steps of a method for processing an RPA-based web page inline document.
As can be seen from the above description, an embodiment of the present invention provides a method and an apparatus for processing an RPA-based web page embedded document, including: firstly, acquiring webpage form data embedded with a document; then, analyzing the webpage form data to generate webpage form data with a Json array format; and finally, processing the embedded document of the web form data according to the web form data with the Json array format. According to the processing method and device for the webpage embedded document based on the RPA, the defects of an RPA robot in the aspect of automatic filling of the webpage embedded document are overcome by using the JavaScript technology, and business personnel are liberated from single and repeated copying, pasting and online document editing work, so that the repeated labor workload is reduced, and the business processing efficiency and the data entry accuracy are improved.
Drawings
In order to more clearly illustrate the embodiments or technical solutions of the present invention, the drawings used in the embodiments or technical solutions in the prior art are briefly introduced below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and it is obvious for those skilled in the art that other drawings can be obtained according to these drawings without creative efforts.
FIG. 1 is a first flowchart illustrating a method for processing an RPA-based document embedded in a web page according to an embodiment of the present invention;
FIG. 2 is a flowchart illustrating a step 100 of a method for processing an RPA-based document embedded in a web page according to an embodiment of the present invention;
FIG. 3 is a flowchart illustrating a second method for processing an RPA-based document embedded in a web page according to an embodiment of the present invention;
FIG. 4 is a flowchart illustrating a step 200 of a method for processing an RPA-based document embedded in a web page according to an embodiment of the present invention;
FIG. 5 is a first flowchart illustrating a method 300 for processing an RPA-based document embedded in a web page according to an embodiment of the present invention;
FIG. 6 is a third schematic flowchart illustrating a method for processing an RPA-based document embedded in a web page according to an embodiment of the present invention;
FIG. 7 is a flowchart illustrating a step 303 of a method for processing an RPA-based document embedded in a web page according to an embodiment of the present invention;
FIG. 8 is a flowchart illustrating a second step 300 of a method for processing an RPA-based document embedded in a webpage according to an embodiment of the present invention;
FIG. 9 is a schematic structural diagram of a system for processing a document embedded in a webpage based on RPA according to an embodiment of the present invention;
FIG. 10 is a diagram of the input and output of a data acquisition module according to an embodiment of the present invention;
FIG. 11 is a diagram illustrating the input and output of a data parsing module according to an embodiment of the present invention;
FIG. 12 is a diagram illustrating the input and output of a data entry module according to an embodiment of the present invention;
FIG. 13 is a flowchart illustrating a method for processing a document embedded in a webpage based on RPA according to an embodiment of the present invention;
FIG. 14 is a first block diagram illustrating a device for processing an RPA-based document embedded in a web page according to an embodiment of the present invention;
FIG. 15 is a block diagram of the form data acquisition module 10 in accordance with an embodiment of the present invention;
FIG. 16 is a second block diagram illustrating a device for processing an RPA-based document embedded in a web page according to an embodiment of the present invention;
FIG. 17 is a block diagram of the form data parsing module 20 according to an embodiment of the present invention;
FIG. 18 is a block diagram of an inline document processing module 30 in accordance with an embodiment of the present invention;
FIG. 19 is a third schematic structural diagram of a device for processing an RPA-based document embedded in a web page according to an embodiment of the present invention;
fig. 20 is a block diagram of an embedded document determining unit 303 in accordance with the embodiment of the present invention;
fig. 21 is a schematic structural diagram of an electronic device in an embodiment of the invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, but not all, embodiments of the present invention. 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 invention.
As will be appreciated by one skilled in the art, embodiments of the present invention may be provided as a method, system, or computer program product. Accordingly, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present invention may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
It should be noted that the terms "comprises" and "comprising," and any variations thereof, in the description and claims of this application and the above-described drawings, 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. The embodiments and features of the embodiments in the present application may be combined with each other without conflict. The present application will be described in detail below with reference to the embodiments with reference to the attached drawings.
According to the technical scheme, the data acquisition, storage, use, processing and the like meet the relevant regulations of national laws and regulations.
Aiming at the defects of the existing RPA technology in automatic filling of a webpage, the invention designs and realizes a method for automatically processing a webpage embedded document by the RPA, which fully utilizes the advantages of a JavaScript technology in the aspect of online document editing to assist an RPA robot in completing the work of acquiring webpage form data and inputting webpage embedded office document data, and particularly provides a specific implementation mode of a processing method for the webpage embedded document based on the RPA with reference to the embodiment of FIG. 1, wherein the method specifically comprises the following contents:
step 100: acquiring webpage form data embedded with a document;
taking financial system a as an example, after inputting a user name and a password, the RPA robot automatically logs in financial system a, then queries related information of the user in financial system a by taking a customer code and the like as query conditions, and finally obtains attribute values corresponding to the information through a webpage label index string or a webpage label attribute to obtain webpage form data such as a contract serial number, a name of my party, a name of a borrower, a delivery address of the borrower, a telephone number of the borrower, a loan purpose, a money amount, a capitalization of a loan amount, a contract validity period, a repayment date, a repayment account name and a repayment account number.
Step 200: and analyzing the webpage form data to generate the webpage form data with the Json array format.
Specifically, the contract serial number, the name of my party, the name of borrower, the address of borrower, the telephone number of borrower, the phone number of borrower, the loan purpose, the amount of money, the capitalization of loan amount, the validity period of the contract, the repayment date, the account name of the repayment account, the account number of the repayment account, and the corresponding value are stored in the form of Json array in step 100, so as to obtain the web page form data in the format of Json array.
It should be noted that the Josn array values must be of the legal Josn data type (string, number, object, array, boolean, or null).
Step 300: and processing the embedded document of the webpage form data according to the webpage form data with the Json array format.
Firstly, a JavaScript script is generated according to the webpage form data with the Json array format obtained in the step 200, and then the JavaScript script is called, so that the automatic input of the office document embedded in the webpage is realized.
As can be seen from the above description, an embodiment of the present invention provides a method for processing an RPA-based web page embedded document, including: firstly, acquiring webpage form data embedded with a document; then, analyzing the webpage form data to generate webpage form data with a Json array format; and finally, processing the embedded document of the web form data according to the web form data with the Json array format. According to the processing method of the webpage embedded document based on the RPA, provided by the invention, the defects of an RPA robot in the aspect of automatic filling of the webpage embedded document are made up by using a JavaScript technology, and business personnel are liberated from single and repeated copying, pasting and online document editing work, so that the repeated labor workload is reduced, and the business processing efficiency and the data entry accuracy are improved.
In some embodiments, referring to fig. 2, step 100 comprises:
step 101: and acquiring an attribute value corresponding to the target element name in the webpage according to the webpage label index string and/or the webpage label attribute.
It will be appreciated that RPA is an automated flow, low code development tool. The RPA mainly enables a user to utilize dragging controls through various packaged controls, generates an automatic flow through simple operation, and realizes automatic mouse clicking and keyboard input of a browser and an application program on a computer; performing excel operation; processing data; adding, deleting, modifying and checking the database; executing at fixed time; automatically generate an interactive interface, and so on.
In the step 101, when implemented, data is acquired through the webpage tag index string or the webpage tag attribute based on the RPA technology, so as to realize the acquisition of the webpage form data. Taking financial system a as an example, after inputting a user name and a password, the RPA robot automatically logs in financial system a, and obtains attribute values corresponding to these information through the web tag index string or the web tag attribute, to obtain the information shown in table 1.
TABLE 1 financial System A data acquisition results
Figure BDA0003865853840000081
In an embodiment, referring to fig. 3, in the processing method of the RPA-based web page embedded document, before step 101, the method further includes:
step 400: generating a query condition according to the client code;
step 500: and acquiring the name of the target element according to the query condition.
In step 400 and step 500, the relevant information of the user is queried in the a system using the client code or the like as a query condition, and the target element name is acquired from the relevant information.
In one embodiment, referring to fig. 4, step 200 specifically includes:
step 201: generating a key value according to the target element name;
step 202: generating a value according to the attribute value;
step 203: generating a key value pair according to the key value and the value corresponding to the key value;
step 204: and generating the webpage form data with the Json array format according to the plurality of key value pairs.
In steps 201 to 204, the data information collected from the web page form is parsed into a form of a Json array, so that the data entry module performs subsequent processing. Specifically, a value corresponding to a bookmark key in the Json array is an element name in the data acquisition module, and a value corresponding to a value key is an attribute value of an element acquired by an RPA in the data acquisition module from a web form. An example of the format of the Json array is as follows:
<xnotran> [ { "bookmark": " ", "value": CONTRACT _ NO _ VALUE }, { "bookmark": " ", "value": OUR _ NAME _ VALUE }, { "bookmark": " ", "value": BORROWER _ NAME _ VALUE }, { "bookmark": " ", "value": BORROWER _ ADDRESS _ VALUE }, { "bookmark": " ", "value": BORROWER _ TELEPHONE _ VALUE }, { "bookmark": " ", "value": BORROWER _ MOBILEPHONE _ VALUE }, { "bookmark": " ", "value": LOAN _ USE _ VALUE }, { "bookmark": " ", "value": LOAN _ AMOUNT _ VALUE }, { "bookmark": " ", "value": CAP _ LOAN _ AMOUNT _ VALUE }, { "bookmark": " ", "value": CYCLIC _ CONTRACT _ LIFE _ VALUE }, { "bookmark": " ", "value": REPAY _ DAY _ VALUE }, { "bookmark": " ", "value": REPAY _ ACCOUNT _ NAME _ VALUE }, { "bookmark": " ", "value": REPAY _ ACCOUNT _ VALUE }, { "bookmark": " ", "value": REPAY _ ACCOUNT _ BANK _ VALUE }, … …, { "bookmark": " ", "value": HANDLE _ BANK _ NAME _ VALUE }, { "bookmark": " ", "value": CONTRACT _ NO _ VALUE }, { "bookmark": " ", "value": SUB _ OUR _ NAME _ VALUE }, { "bookmark": " ", "value": SIGN _ DATE _ VALUE } ]. </xnotran>
In one embodiment, referring to fig. 5, step 300 specifically includes:
step 301: determining html tags of sub-pages of the webpage;
specifically, the iframe tag (i.e., html tag, which is a document in the document, that is, the sub-page can be embedded in the page) of the sub-page is obtained by the document.
Step 302: determining a sub-page of a target webpage according to the window object of the html tag;
on the basis of the step 301, the sub-page is obtained through the contentWindow attribute, and the above operations are performed step by step (step 301 and step 302) until the page where the webpage embedded document is located is found.
Step 303: determining an embedded document according to the sub-page;
step 304: and editing the embedded document according to the ActiveDocument attribute of the sub-page.
The IDispatch programming interface of a document application is exposed to the outside through the ActiveDocument property, and thus the office application can be manipulated by obtaining this property. Step 304 is implemented, and the document displayed in the browser can be edited through the ActiveDocument attribute of the page.
In an embodiment, referring to fig. 6, the method for processing the RPA-based web page embedded document further includes:
step 600: judging whether the attribute value in the document is the same as the attribute value in the Json array or not;
step 700: and if so, editing the embedded document according to the ActiveDocument attribute of the sub-page.
In step 600 and step 700, all bookmarks of the document embedded in the web page are traversed, and if the bookmark value is the same as the bookmark value in the Json array, the bookmark value is assigned, specifically:
Figure BDA0003865853840000101
in one embodiment, referring to fig. 7, step 303 comprises:
step 3031: and starting from the initial page of the webpage, judging whether each sub-page contains the embedded document or not step by step downwards.
Specifically, the sub-page is obtained through the contentWindow attribute, and the operations of step 301 and step 302 are performed step by step until the page where the office document embedded in the webpage is located is found.
In one embodiment, referring to fig. 8, before step 304, step 300 further comprises:
step 305: the target document is activated.
Before assigning an office document embedded in a webpage, activating a target document, specifically: active ();
in a specific embodiment, the present invention takes an office document as an example, and further provides a specific embodiment of a method for processing an RPA-based web page embedded document, which specifically includes the following contents.
First, the present invention provides a processing system for a webpage embedded document based on RPA, referring to fig. 9, the system includes: the processing method of the webpage embedded document based on the RPA is explained in detail by taking data migration and input between an A system and a B system as an example (note: the A system is in a form of a webpage form, and the B system is in a form of a webpage embedded office document).
And the data acquisition module acquires data through the webpage label index string or the webpage label attribute based on the RPA technology to realize the acquisition of the webpage form data. Taking the system a as an example, after the RPA robot inputs a user name and a password, the RPA robot automatically logs in the system a, then queries the relevant information of the user in the system a by using a client code and the like as query conditions, and finally obtains attribute values corresponding to the information through a webpage label index string or a webpage label attribute to obtain the information listed in the following table. The input and output schematic diagram of the module is shown in fig. 10.
And the data analysis module is used for analyzing the data information acquired from the webpage form into a Json array form so as to facilitate the subsequent processing of the data entry module, and the input and output schematic diagram of the data entry module is shown in the attached figure 11. The value corresponding to the bookmark key in the Json array is the element name in the data acquisition module (the value of the bookmark is obtained from the B system (the B system can be positioned to the position of the corresponding information to be entered in the embedded office document through the bookmark) through the RPA.
And the data entry module is used for generating a JavaScript script according to the Json array obtained by the data analysis module. And the RPA automatically logs in the system B and enters a target page, namely the page where the office document is embedded in the webpage, and then calls the JavaScript to realize the automatic input of the office document embedded in the webpage. The input and output schematic diagram of the module is shown in fig. 12.
Referring to fig. 13, based on the processing system for the RPA-based web page embedded document, the specific implementation of the processing method for the RPA-based web page embedded document provided by the present invention includes the following steps:
s1: acquiring webpage form data embedded with a document;
s2: analyzing the webpage form data to generate webpage form data with a Json array format;
s3: and processing the embedded document of the webpage form data according to the webpage form data with the Json array format.
Further, step S3 includes the steps of:
the method comprises the following steps: the method comprises the steps of firstly obtaining an iframe label of a sub-page through a document getElementById () method, then obtaining the sub-page through a contentWindow attribute (the contentWindow is a designated iframe or a window object where the iframe is located), and carrying out the operations step by step until a page where an office document embedded in a webpage is located is found.
var wordObject=document.getElementById("xxxXXX").contentWindow……
Step two: the office document displayed in the browser can be edited through the ActiveDocument attribute of the page. The IDispatch programming interface of the Office application program is exposed to the outside through an ActiveDocument attribute (ActiveDocument is an automatic interface object used for returning to a document object interface when a control successfully loads an Office document).
var wDoc=wordObject.ActiveDocument;
Step three: before assigning value to the office document embedded in the webpage, the target document needs to be activated.
wDoc.Activate();
Step four: and traversing all bookmarks of the office document embedded in the webpage, and assigning the bookmarks if the bookmark values are the same as the bookmark values in the Json array.
As can be seen from the above description, in order to make up for the deficiency of the RPA robot in the automated filling of the embedded office document in the web page, an embodiment of the present invention provides a method for processing an embedded document in a web page based on RPA, where the method includes: firstly, acquiring webpage form data embedded with a document; then, analyzing the webpage form data to generate webpage form data with a Json array format; and finally, processing the embedded document of the webpage form data according to the webpage form data with the Json array format. The method can complete automatic input of office documents embedded in the webpage without the help of an OCR technology, is convenient, quick and technically friendly, and can expand the application scene of data migration and input of the RPA robot between heterogeneous systems by combining the RPA technology and the RPA technology.
Based on the same inventive concept, the embodiment of the present application further provides a processing apparatus for processing a document embedded in a web page based on RPA, which can be used to implement the method described in the above embodiment, such as the following embodiments. Because the principle of the processing device for the webpage embedded document based on the RPA for solving the problems is similar to the processing method for the webpage embedded document based on the RPA, the implementation of the processing device for the webpage embedded document based on the RPA can be realized by the processing method for the webpage embedded document based on the RPA, and repeated parts are not repeated. As used hereinafter, the term "unit" or "module" may be a combination of software and/or hardware that implements a predetermined function. While the system described in the embodiments below is preferably implemented in software, implementations in hardware, or a combination of software and hardware are also possible and contemplated.
The embodiment of the present invention first provides a specific implementation manner of a processing apparatus for an RPA-based in-web document, which is capable of implementing a processing method for an RPA-based in-web document, and referring to fig. 14, the processing apparatus for an RPA-based in-web document specifically includes the following contents:
the form data acquisition module 10 is used for acquiring webpage form data embedded with a document;
a form data analysis module 20, configured to analyze the web form data to generate web form data in a Json array format;
and the embedded document processing module 30 is configured to process the embedded document of the web form data according to the web form data with the Json array format.
In one embodiment, referring to fig. 15, the form data obtaining module 10 includes:
the attribute value obtaining unit 101 is configured to obtain an attribute value corresponding to a target element name in a web page according to the web page tag index string and/or the web page tag attribute.
In an embodiment, referring to fig. 16, the apparatus for processing an RPA-based web page embedded document further includes:
a query condition generating module 40, configured to generate a query condition according to the customer code;
and a name obtaining module 50, configured to obtain the name of the target element according to the query condition.
In one embodiment, referring to fig. 17, the form data parsing module 20 includes:
a key value generating unit 201 for generating a key value according to the target element name;
a value generating unit 202, configured to generate a value according to the attribute value;
a key-value pair generating unit 203, configured to generate a key-value pair according to the key value and the value corresponding to the key value;
and the form data generation unit 204 is configured to generate the web page form data with the Json array format according to a plurality of key value pairs.
In one embodiment, referring to fig. 18, the inline document processing module 30 includes:
a tag obtaining unit 301, configured to determine html tags of sub pages of a web page;
a sub-page determining unit 302, configured to determine a sub-page of the target web page according to the window object of the html tag;
an embedded document determining unit 303, configured to determine an embedded document according to the sub-page;
and the document editing unit 304 is configured to edit the embedded document according to the ActiveDocument attribute of the sub page.
In one embodiment, referring to fig. 19, the apparatus for processing RPA-based web page embedded documents further comprises:
an attribute value judging module 60, configured to judge whether an attribute value in the document is the same as an attribute value in the Json array;
and the embedded document editing unit 70 is used for editing the embedded document according to the ActiveDocument attribute of the sub-page if the active document attribute is the same as the ActiveDocument attribute of the sub-page.
In one embodiment, referring to fig. 20, the embedded document determining unit 303 includes:
the embedded document determining subunit 3031 is configured to determine whether each sub page contains the embedded document in a downward step-by-step manner from the initial page of the web page.
As can be seen from the foregoing description, an embodiment of the present invention provides an apparatus for processing a document embedded in a web page based on an RPA, including: firstly, acquiring webpage form data embedded with a document; then, analyzing the webpage form data to generate webpage form data with a Json array format; and finally, processing the embedded document of the webpage form data according to the webpage form data with the Json array format. The processing device for the webpage embedded document based on the RPA provided by the invention makes up the defects of an RPA robot in the aspect of automatically filling the webpage embedded document by using the JavaScript technology, and liberates business personnel from single and repeated copying, pasting and online document editing work, thereby not only reducing the repeated labor workload, but also improving the business processing efficiency and the accuracy of data entry.
An embodiment of the present application further provides a specific implementation manner of an electronic device, which is capable of implementing all steps in the processing method of the RPA-based web page embedded document in the foregoing embodiment, and referring to fig. 21, the electronic device specifically includes the following contents:
a processor (processor) 1201, a memory (memory) 1202, a communication Interface 1203, and a bus 1204;
the processor 1201, the memory 1202 and the communication interface 1203 complete communication with each other through the bus 1204; the communication interface 1203 is used for implementing information transmission between related devices such as a server-side device and a client-side device;
the processor 1201 is configured to call the computer program in the memory 1202, and the processor executes the computer program to implement all the steps in the processing method of the RPA-based web page embedded document in the above embodiment, for example, the processor executes the computer program to implement the following steps:
step 100: acquiring webpage form data embedded with a document;
step 200: analyzing the webpage form data to generate webpage form data with a Json array format;
step 300: and processing the embedded document of the webpage form data according to the webpage form data with the Json array format.
Embodiments of the present application also provide a computer-readable storage medium capable of implementing all steps in the processing method of the RPA-based web page embedded document in the above embodiments, where the computer-readable storage medium stores thereon a computer program, and the computer program implements all steps of the processing method of the RPA-based web page embedded document in the above embodiments when executed by a processor, for example, the processor implements the following steps when executing the computer program:
step 100: acquiring webpage form data embedded with a document;
step 200: analyzing the webpage form data to generate webpage form data with a Json array format;
step 300: and processing the embedded document of the webpage form data according to the webpage form data with the Json array format.
The embodiments in the present specification are described in a progressive manner, and the same and similar parts among the embodiments are referred to each other, and each embodiment focuses on the differences from the other embodiments. In particular, for the hardware + program class embodiment, since it is substantially similar to the method embodiment, the description is simple, and the relevant points can be referred to the partial description of the method embodiment.
The foregoing description has been directed to specific embodiments of this disclosure. Other embodiments are within the scope of the following claims. In some cases, the actions or steps recited in the claims may be performed in a different order than in the embodiments and still achieve desirable results. In addition, the processes depicted in the accompanying figures do not necessarily require the particular order shown, or sequential order, to achieve desirable results. In some embodiments, multitasking and parallel processing may also be possible or may be advantageous.
Although the present application provides method steps as in an embodiment or a flowchart, more or fewer steps may be included based on conventional or non-inventive labor. The order of steps recited in the embodiments is merely one manner of performing the steps in a multitude of orders and does not represent the only order of execution. When an actual apparatus or client product executes, it may execute sequentially or in parallel (e.g., in the context of parallel processors or multi-threaded processing) according to the embodiments or methods shown in the figures.
For convenience of description, the above devices are described as being divided into various modules by functions, and are described separately. Of course, in implementing the embodiments of the present description, the functions of each module may be implemented in one or more software and/or hardware, or a module implementing the same function may be implemented by a combination of multiple sub-modules or sub-units, and the like. The above-described embodiments of the apparatus 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.
Those skilled in the art will also appreciate that, in addition to implementing the controller as pure computer readable program code, the same functionality can be implemented by logically programming method steps such that the controller is in the form of logic gates, switches, application specific integrated circuits, programmable logic controllers, embedded microcontrollers and the like. Such a controller may therefore be considered as a hardware component, and the means included therein for performing the various functions may also be considered as a structure within the hardware component. Or even means for performing the functions may be regarded as being both a software module for performing the method and a structure within a hardware component.
In a typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
The memory may include forms of volatile memory in a computer readable medium, random Access Memory (RAM) and/or non-volatile memory, such as Read Only Memory (ROM) or flash memory (flash RAM). Memory is an example of a computer-readable medium.
The embodiments of this specification may be described in the general context of computer-executable instructions, such as program modules, being executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, etc. that perform particular tasks or implement particular abstract data types. The described embodiments may also be practiced in distributed computing environments where tasks are performed by remote processing devices that are linked through a communications network. In a distributed computing environment, program modules may be located in both local and remote computer storage media including memory storage devices.
The embodiments in the present specification are described in a progressive manner, and the same and similar parts among the embodiments are referred to each other, and each embodiment focuses on the differences from the other embodiments. In particular, for the system embodiment, since it is substantially similar to the method embodiment, the description is simple, and for the relevant points, reference may be made to the partial description of the method embodiment. In the description herein, references to the description of the term "one embodiment," "some embodiments," "an example," "a specific example," or "some examples," etc., mean that a particular feature, structure, material, or characteristic described in connection with the embodiment or example is included in at least one embodiment or example of an embodiment of the specification. In this specification, the schematic representations of the terms used above are not necessarily intended to refer to the same embodiment or example. Furthermore, the particular features, structures, materials, or characteristics described may be combined in any suitable manner in any one or more embodiments or examples. Furthermore, various embodiments or examples and features of different embodiments or examples described in this specification can be combined and combined by one skilled in the art without contradiction.
The above description is only an example of the embodiments of the present disclosure, and is not intended to limit the embodiments of the present disclosure. Various modifications and variations to the embodiments described herein will be apparent to those skilled in the art. Any modification, equivalent replacement, improvement or the like made within the spirit and principle of the embodiments of the present invention should be included in the scope of the claims of the embodiments of the present invention.

Claims (10)

1. A processing method of webpage embedded documents based on RPA is characterized by comprising the following steps:
acquiring webpage form data embedded with a document;
analyzing the webpage form data to generate webpage form data with a Json array format;
and processing the embedded document of the webpage form data according to the webpage form data with the Json array format.
2. The RPA-based processing method of in-web documents according to claim 1, wherein the acquiring the data of the web form with the document embedded therein comprises:
and acquiring an attribute value corresponding to the target element name in the webpage according to the webpage label index string and/or the webpage label attribute.
3. The method for processing the RPA-based web page embedded document according to claim 2, wherein before the obtaining the attribute value corresponding to the target element name in the web page according to the tab index string and/or the tab attribute, the method further comprises:
generating a query condition according to the client code;
and acquiring the name of the target element according to the query condition.
4. The method for processing an RPA-based web page inline document according to claim 3, wherein the parsing the web page form data to generate web page form data having a Json array format comprises:
generating a key value according to the target element name;
generating a value according to the attribute value;
generating a key value pair according to the key value and the value corresponding to the key value;
and generating the webpage form data with the Json array format according to the plurality of key value pairs.
5. The method for processing an RPA-based web page inline document according to claim 1, wherein processing the inline document of the web page form data according to the web page form data having a Json array format comprises:
determining html tags of sub-pages of the web page;
determining a sub-page of a target webpage according to the window object of the html tag;
determining the embedded document according to the sub-page;
and editing the embedded document according to the ActiveDocument attribute of the sub-page.
6. The RPA-based processing method of in-web documents according to claim 5, further comprising:
judging whether the attribute value in the document is the same as the attribute value in the Json array or not;
and if so, editing the embedded document according to the ActiveDocument attribute of the sub-page.
7. The method for processing an RPA-based web page inline document according to claim 5, wherein said determining the inline document thereof according to the sub-page comprises:
and starting from the initial page of the webpage, judging whether each sub-page contains the embedded document or not step by step downwards.
8. An apparatus for processing a document embedded in a web page based on an RPA, comprising:
the form data acquisition module is used for acquiring webpage form data embedded with a document;
the form data analysis module is used for analyzing the webpage form data to generate webpage form data with a Json array format;
and the embedded document processing module is used for processing the embedded document of the webpage form data according to the webpage form data with the Json array format.
9. An electronic device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the method for processing the document embedded in the RPA-based web page according to any one of claims 1 to 7 when executing the program.
10. A computer-readable storage medium, on which a computer program is stored, wherein the computer program, when executed by a processor, implements the steps of the method for processing an RPA-based web page inline document according to any one of claims 1 to 7.
CN202211179159.5A 2022-09-27 2022-09-27 Processing method and device for webpage embedded document based on RPA Pending CN115688679A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211179159.5A CN115688679A (en) 2022-09-27 2022-09-27 Processing method and device for webpage embedded document based on RPA

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211179159.5A CN115688679A (en) 2022-09-27 2022-09-27 Processing method and device for webpage embedded document based on RPA

Publications (1)

Publication Number Publication Date
CN115688679A true CN115688679A (en) 2023-02-03

Family

ID=85062121

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211179159.5A Pending CN115688679A (en) 2022-09-27 2022-09-27 Processing method and device for webpage embedded document based on RPA

Country Status (1)

Country Link
CN (1) CN115688679A (en)

Similar Documents

Publication Publication Date Title
WO2017124952A1 (en) Webpage script loading method and device
US20090113387A1 (en) Methods and systems for dynamically generating and optimizing code for business rules
WO2003005189A9 (en) Method for creating browser-based user interface applications using a framework
CN111125598A (en) Intelligent data query method, device, equipment and storage medium
US9454535B2 (en) Topical mapping
CN109240692A (en) A kind of method for building up and system of the web database exploitation based on common template
JP7209306B2 (en) Online work system for Excel documents based on templates
US20210056006A1 (en) Automated searching and identification of software patches
CN105550206A (en) Version control method and device for structured query language
CN112883030A (en) Data collection method and device, computer equipment and storage medium
CN110765402A (en) Visual acquisition system and method based on network resources
CN104346398A (en) Method and device for automatically filling and submitting data on line
CN114138244A (en) Method and device for automatically generating model files, storage medium and electronic equipment
US9244707B2 (en) Transforming user interface actions to script commands
JP2022093293A (en) Online report preparation system using excel tool
CN112231197A (en) Page testing method and device and storage medium
CN117033249A (en) Test case generation method and device, computer equipment and storage medium
CN117111909A (en) Code automatic generation method, system, computer equipment and storage medium
US11550990B2 (en) Machine first approach for identifying accessibility, non-compliances, remediation techniques and fixing at run-time
CN115688679A (en) Processing method and device for webpage embedded document based on RPA
US10606728B2 (en) Framework for detecting source code anomalies
CN115033436A (en) Page testing method and device, electronic equipment and storage medium
US20160373402A1 (en) Information Management and Notification System
CN115437621A (en) Process editing method and device based on robot process automation
Oh et al. Automatic extraction of dependencies between web components and database resources in java web applications

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination