CN110609694A - BUG repairing method and device, terminal equipment and storage medium - Google Patents

BUG repairing method and device, terminal equipment and storage medium Download PDF

Info

Publication number
CN110609694A
CN110609694A CN201910814381.XA CN201910814381A CN110609694A CN 110609694 A CN110609694 A CN 110609694A CN 201910814381 A CN201910814381 A CN 201910814381A CN 110609694 A CN110609694 A CN 110609694A
Authority
CN
China
Prior art keywords
page
target
native
json
native page
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201910814381.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.)
OneConnect Smart Technology Co Ltd
Original Assignee
OneConnect Smart Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by OneConnect Smart Technology Co Ltd filed Critical OneConnect Smart Technology Co Ltd
Priority to CN201910814381.XA priority Critical patent/CN110609694A/en
Publication of CN110609694A publication Critical patent/CN110609694A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/65Updates

Abstract

The embodiment of the invention relates to the technical field of computers, and discloses a BUG repairing method, a device, terminal equipment and a storage medium. Wherein, the method comprises the following steps: the method comprises the steps that the terminal equipment receives a jump request in the running process of the APP, the jump request is used for enabling the APP to jump to a first native page from a historical native page, whether the first native page is a page with BUG or not is determined, if yes, a target H5 page corresponding to the first native page is determined, and the first native page is replaced by a target H5 page to be displayed. By implementing the embodiment of the invention, the BUG repair can be completed without issuing a new version, and the convenience of APP maintenance is improved.

Description

BUG repairing method and device, terminal equipment and storage medium
Technical Field
The present invention relates to the field of computer technologies, and in particular, to a method and an apparatus for repairing a BUG, a terminal device, and a storage medium.
Background
With the development of terminal equipment technology, various APPs in the terminal equipment are utilized to work and entertain, which is a common life style for people. In this case, the user generally needs to download the APP from the APP store to the terminal device of the user, so as to use the APP on the terminal device. However, in the development process of the APP, although a test link is passed, potential BUGs may still exist, and these BUGs are not found in the development stage, are generated when the user uses the APP, and seriously affect the use experience of the user.
Aiming at the problems, the APP in the terminal equipment of the user can be dynamically updated without issuing a new version through dynamic technologies such as hot update, plug-in, Reactnative and the like. However, the above techniques all have respective drawbacks, such as: 1. hot updating and plug-in realization are complex, and the code realization of the IOS system and the Android system is different; 2. although the ReactNative technology can be compatible with Android and IOS systems by only writing a set of codes, the ReactNative technology needs to be developed from the beginning and cannot be compatible with old codes; 3. the auditing of each application market tends to be strict, and the function of dynamically issuing codes is gradually limited.
Therefore, a method for efficiently repairing a BUG when a BUG occurs in the operation of an APP is needed to solve the above problems.
Disclosure of Invention
The embodiment of the invention provides a BUG repairing method, a device, terminal equipment and a storage medium, which can efficiently repair BUG without issuing a new version.
The first aspect of the embodiments of the present invention discloses a method for repairing a BUG, which includes:
in the running process of the APP, a jump request is received, and the jump request is used for enabling the APP to jump from a historical native page to a first native page;
determining whether the first native page is a page with BUG;
if yes, determining a target H5 page corresponding to the first native page;
and replacing the first native page with the target H5 page for display.
As an optional implementation manner, before determining the target H5 page corresponding to the first native page, the method further includes:
downloading a JSON mapping table from a server; wherein the JSON mapping table comprises: the corresponding relation between the native page and the H5 page, the address of the H5 page, and the parameter name and the parameter type to be received by the H5 page;
the determining whether the first native page is a page in which a BUG occurs includes:
searching whether the JSON mapping table comprises the first native page or not;
and if so, determining that the first native page is a page with BUG.
As an optional implementation manner, the determining a target H5 page corresponding to the first native page includes:
and searching the H5 page corresponding to the first native page from the JSON mapping table, and determining the H5 page corresponding to the first native page as the target H5 page.
As an optional implementation, the replacing the first native page with the target H5 page for displaying includes:
acquiring parameters and parameter values included in the first native page;
assembling the parameters and the parameter values into a first JSON character string according to the parameter type of the first native page;
acquiring the address of the target H5 page from the JSON mapping table;
splicing the first JSON character string serving as a parameter with an address of the target H5 page to obtain a first link;
the first link is parsed to load the target H5 page.
As an optional implementation manner, before splicing the first JSON string as a parameter with the address of the target H5 page to obtain the first link, the method further includes:
carrying out utf-8 coding on the first JSON character string;
the splicing the first JSON character string serving as a parameter and the address of the target H5 page to obtain a first link comprises the following steps:
splicing the encoded first JSON character string serving as a parameter with the address of the target H5 page to obtain the first link.
As an optional implementation, the downloading the JSON mapping table from the server includes:
when the APP is initialized, sending a request message to the server; the request message is used for acquiring version information of a JSON mapping table stored by the server;
determining whether the JSON mapping table stored by the server is a new version or not according to the version information of the JSON mapping table stored by the server and the locally stored version information;
and downloading the JSON mapping table under the condition that the JSON mapping table stored by the server is a new version.
As an optional implementation manner, after the replacing the first native page with the target H5 page for displaying, the method further includes:
assembling the parameters, parameter values and data types of the target H5 page needing to be transmitted to a second native page into a second JSON character string;
carrying out utf-8 coding on the second JSON character string;
splicing the encoded second JSON character string serving as a parameter with a protocol link of the second native page to obtain a second link;
triggering a jump through the second link to display the second native page.
The second aspect of the embodiments of the present invention discloses a BUG repair device, which includes:
the device comprises a receiving unit, a processing unit and a processing unit, wherein the receiving unit is used for receiving a jump request in the running process of an APP, and the jump request is used for jumping the APP from a history native page to a first native page;
a first determining unit, configured to determine whether the first native page is a page in which a BUG occurs;
a second determining unit, configured to determine, when the first native page is a page in which a BUG occurs, a target H5 page corresponding to the first native page;
and the replacing unit is used for replacing the first native page with the target H5 page for displaying.
A third aspect of the embodiments of the present invention discloses a terminal device, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor, where the processor executes the computer program to perform the method of the first aspect.
A fourth aspect of the embodiments of the present invention discloses a computer-readable storage medium, in which a computer program is stored, and the computer program, when executed by a processor, implements the method according to the above aspects.
According to the technical scheme, the terminal device receives a jump request in the running process of the APP, wherein the jump request is used for enabling the APP to jump to a first native page from a historical native page, determining whether the first native page is a page with BUG, if so, determining a target H5 page corresponding to the first native page, and replacing the first native page with a target H5 page for displaying. Therefore, when the APP appears on the first native interface of the APP, the first native interface can be replaced by the target H5 interface to be normally displayed, so that BUG repair can be completed without issuing a new version, and the convenience of APP maintenance is improved.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings needed to be used in the description of the embodiments will be briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without inventive exercise.
Fig. 1 is a schematic flow chart of a BUG repair method disclosed in the embodiment of the present invention;
FIG. 2 is a schematic flow chart of another BUG repairing method disclosed in the embodiment of the present invention;
fig. 3 is a schematic structural diagram of a BUG repair device disclosed in the embodiment of the present invention;
fig. 4 is a schematic structural diagram of a terminal device disclosed in the embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention clearer, the present invention will be described in further detail with reference to the accompanying drawings, and it is apparent that the described embodiments are only a part of the embodiments of the present invention, not all of the 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 invention.
The terms "first," "second," and the like in the description and claims of the present invention and in the above-described drawings are used for distinguishing between different objects and not for describing a particular order. Furthermore, the terms "include" and "have," as well as any variations thereof, are intended to cover non-exclusive inclusions. For example, a process, method, system, article, or apparatus that comprises a list of steps or elements is not limited to only those steps or elements listed, but may alternatively include other steps or elements not listed, or inherent to such process, method, or apparatus.
The embodiment of the invention discloses a method and a device for repairing BUG, terminal equipment and a storage medium, which can repair BUG efficiently without issuing a new version. The following are detailed below.
Referring to fig. 1, fig. 1 is a schematic flow chart illustrating a BUG repair method according to an embodiment of the present invention. The BUG repairing method may be executed by a terminal device used by a user, such as a smart phone, a smart watch, a palm computer, a tablet computer, a Personal Digital Assistant (PDA), a Point of Sales (POS), and the like, which is not limited in the embodiments of the present invention. The method for repairing the BUG shown in fig. 1 may include the following steps:
101. in the running process of the APP, a jump request is received, and the jump request is used for enabling the APP to jump from a historical native page to a first native page.
In the running process of the APP in the terminal equipment, due to the fact that design or development of some pages has problems, if the APP runs to the interface or a user performs some operations in the running process, BUG of the APP can occur. The expression form of the BUG comprises page blockage, abnormal display effect, white screen, APP flash back and the like.
In the scheme, the native page is a program interface which is designed in the APP program code and is displayed in the APP operation process. If a developer finds that a certain native page has a BUG or is easy to crash, a corresponding H5 page can be designed, the native page and the H5 are configured in the JSON mapping table, and when the APP of the terminal runs to the native page, the native page is replaced by an H5 page to eliminate the BUG or avoid the crash.
Therefore, in the embodiment of the present invention, after the developer finds that the first native page is a page in which a BUG occurs, a target H5 page for replacement is designed for the first native page, the target H5 page is stored in the server, and when waiting for the APP on the user terminal to run to the first native page, replacement of the first native page with the target H5 page is triggered.
Specifically, in the android system, a jump request for jumping from a historical native page to a first native page can be intercepted by inheriting the base class by Activity and rewriting the startActivityForResult method thereof.
102. It is determined whether the first native page is a page in which a BUG has occurred.
Therefore, when the terminal device runs the APP and receives a page jump instruction, it needs to determine whether a page to be jumped is a page with a BUG, and if so, replacement operation needs to be performed.
In the embodiment of the invention, whether the first native interface is a page with a BUG can be determined by searching a preset JSON mapping table. And if the JSON mapping table comprises a first native page, the first native page is a page with a BUG.
103. If yes, determining a target H5 page corresponding to the first native page.
In the embodiment of the present invention, a JSON mapping table downloaded from a server is stored in a terminal in advance, where the JSON mapping table includes: the correspondence between the native page and the H5 page, the address of the H5 page, and the parameter name and parameter type to be received by the H5 page.
Thus, it can be looked up from the JSON mapping table whether the first native page has a corresponding H5 page; in the case that the first native page has a corresponding H5 page, the H5 page corresponding to the first native page is determined to be the target H5 page.
104. The first native page is replaced with the target H5 page for display.
In the embodiment of the invention, parameters and parameter values included in a first native page are obtained; assembling the parameter and the parameter value into a first JSON character string according to the parameter type of the first native page; then acquiring the address of a target H5 page from the JSON mapping table; splicing the first JSON character string serving as a parameter with an address of a target H5 page to obtain a first link; the first link is parsed to load the target H5 page.
As an optional implementation manner, before the first JSON string is used as a parameter to be spliced with the address of the target H5 page to obtain the first link, the first JSON string may be subjected to utf-8 encoding to shorten the length of the string and avoid the compatibility problem of the generated link.
Specifically, in an android system, a new Intent is constructed, parameters and parameter values on the Intent of a first native page are assembled into a first JSON character string according to parameter types, the first JSON character string is subjected to UTF-8 encoding, the encoded first JSON character string is used as a parameter and is spliced with an address of a target H5 page, the form is that url? JSON is encodeData, wherein the JSON is the first JSON character string subjected to UTF-8 encoding, url is the address of the target H5 page, UTF-8(8-bit Unicode Transformation Format) encoding is a variable-length character encoding for Unicode, namely Unicode, 1-6 byte encoding characters are adopted, the UTF-8 encoding is carried out uniformly at the position, subsequent mixed recognition errors are avoided, the obtained first Intent link is set as a new WebwView link, the first JSON character string is analyzed and loaded in a target H5, and the target WebwActiveH is started.
In the IOS system, the url address of the target H5 page can be intercepted by the Webview function, the method and parameters to be executed are intercepted by the custom protocol header, and then the method is called to load the target H5 page.
Through the mode, the H5 page can be downloaded at any time without auditing, so that auditing limits of an application market and an operating system can be avoided, and running problems of the APP can be flexibly processed. In addition, the target H5 page can receive the data transmitted by the first native page through the first JSON character string in the first link, so that the connection between the historical native page and the display of the target H5 page is completed, and the normal use of the APP by the user is not influenced.
As an optional implementation manner, since the JSON configuration table can be updated every time a developer finds a new BUG, the APP of the user terminal needs to update the local JSON configuration table in time, so that the BUG is repaired in time, and the smooth operation of the APP is maintained. Specifically, when the APP is started and initialized each time, the APP requests the server for version information of the JSON configuration table in the server, then compares the version information of the local record with the version information of the JSON configuration table in the server, and if the server has an update, downloads and updates the latest JSON configuration table.
On the other hand, when the embodiment of the present invention is implemented, the H5 page is also operated to jump to the next native page like the native page, that is, to switch from the target H5 page to the next native page (hereinafter, referred to as the second native page) for display. Referring to fig. 2, fig. 2 is a schematic flow chart illustrating another BUG repairing method according to an embodiment of the present invention. The BUG repairing method may be executed by a terminal device used by a user, such as a smart phone, a smart watch, a palm computer, a tablet computer, a Personal Digital Assistant (PDA), a Point of Sales (POS), and the like, which is not limited in the embodiments of the present invention. The method for repairing the BUG shown in fig. 2 may include the following steps:
201. after the first native page is replaced with the target H5 page for display, a jump request to jump to a second native page is received.
202. And assembling the parameters, parameter values and data types of the target H5 page needing to be transmitted to a second native page into a second JSON character string according to the jump request.
203. And carrying out utf-8 encoding on the second JSON character string.
204. Splicing the encoded second JSON character string serving as a parameter with a protocol link of the second native page to obtain a second link.
205. Triggering a jump through the second link to display the second native page.
Specifically, in the android system, jumping from a target H5 page to a second native page can be achieved by defining a contract format which can be analyzed by WebViewActivity in the android system, such as protocolname:// com. pingan.XXX? JSON ═ encodedData to generate a protocol link of the target H5 page, then jumping the target H5 page to the data which needs to be transmitted of the second native page to generate a second JSON character string and encoding, splicing the encoded character string to the protocol link and then executing jumping, intercepting the H5 jump by a WebView rewrite intercepting method, passing the second JSON character string to the WebViewActivity to generate an Intent which needs to be transmitted to the second native page, and jumping to the Activity of the second native page, thereby realizing jumping from the H5 interface to the native page.
Therefore, by implementing the technical scheme, when a bug or crash occurs to a certain native page during the operation of the App, the native page can be immediately replaced by the H5 page, and the user experience is ensured to be complete. This kind of alternative is not restricted by each big application market place, and the flexibility is high, and the development degree of difficulty is low, to IOS and android system, also only need develop one set of H5 page and can realize the BUG restoration of two systems, and the developer need not additionally consider subsequent BUG problem when writing the native page code of APP yet, has further reduced the development and has realized the degree of difficulty.
On the other hand, please refer to fig. 3, fig. 3 is a schematic structural diagram of a BUG repair device according to an embodiment of the present invention. The BUG repairing apparatus 300 may be disposed in a terminal device used by a user, such as a smart phone, a smart watch, a palm computer, a tablet computer, a Personal Digital Assistant (PDA), a Point of sale (POS), and the like, and the specific device is not limited in the embodiment of the present invention. The embodiment of the present invention is described by taking a terminal device as an example. As shown in fig. 3, the apparatus may include:
a receiving unit 301, configured to receive a jump request in an APP running process, where the jump request is used to jump the APP from a history native page to a first native page.
In the running process of the APP in the terminal equipment, due to the fact that design or development of some pages has problems, if the APP runs to the interface or a user performs some operations in the running process, BUG of the APP can occur. The expression form of the BUG comprises page blockage, abnormal display effect, white screen, APP flash back and the like.
Specifically, in the android system, the receiving unit 301 may intercept a jump request to jump from a history native page to a first native page by inheriting the base class by Activity and rewriting its startactityforresult method.
A first determining unit 302, configured to determine whether the first native page is a page in which a BUG occurs.
Therefore, when the terminal device runs the APP and receives a page jump instruction, it needs to determine whether a page to be jumped is a page with a BUG, and if so, replacement operation needs to be performed.
In this embodiment of the present invention, the first determining unit 302 may determine whether the first native interface is a page where a BUG occurs by searching a preset JSON mapping table. And if the JSON mapping table comprises a first native page, the first native page is a page with a BUG.
A second determining unit 303, configured to determine, when the first native page is a page in which a BUG occurs, a target H5 page corresponding to the first native page.
In the embodiment of the present invention, a JSON mapping table downloaded from a server is stored in a terminal in advance, where the JSON mapping table includes: the correspondence between the native page and the H5 page, the address of the H5 page, and the parameter name and parameter type to be received by the H5 page.
Thus, the second determining unit 303 may look up from the JSON mapping table whether the first native page has a corresponding H5 page; in the case that the first native page has a corresponding H5 page, the H5 page corresponding to the first native page is determined to be the target H5 page.
A replacing unit 304, configured to replace the first native page with the target H5 page for display.
In this embodiment of the present invention, the replacing unit 304 obtains parameters and parameter values included in the first native page; assembling the parameter and the parameter value into a first JSON character string according to the parameter type of the first native page; then acquiring the address of a target H5 page from the JSON mapping table; splicing the first JSON character string serving as a parameter with an address of a target H5 page to obtain a first link; the first link is parsed to load the target H5 page.
Through the mode, the H5 page can be downloaded at any time without auditing, so that auditing limits of an application market and an operating system can be avoided, and running problems of the APP can be flexibly processed. In addition, the target H5 page can receive the data transmitted by the first native page through the first JSON character string in the first link, so that the connection between the historical native page and the display of the target H5 page is completed, and the normal use of the APP by the user is not influenced.
Referring to fig. 4, fig. 4 is a schematic structural diagram of a terminal device 400 according to an embodiment of the present invention. As shown in fig. 4, for convenience of illustration, only the portion related to the embodiment of the present invention is shown, and details of the technology are not disclosed, please refer to the method portion of the embodiment of the present invention. The terminal device 400 may be any terminal device such as a mobile phone, a tablet computer, a PDA (Personal digital assistant), a POS (Point of Sales), or a vehicle-mounted computer, taking the terminal device as a mobile phone as an example:
fig. 4 is a block diagram illustrating a partial structure of a mobile phone related to a terminal device provided in an embodiment of the present invention. Referring to fig. 4, the handset includes: a Radio Frequency (RF) circuit 401, a memory 402, an input unit 403, a display unit 404, a sensor 405, an audio circuit 406, a wireless fidelity (WiFi) module 407, a processor 408, and a power supply 409. Those skilled in the art will appreciate that the handset configuration shown in fig. 4 is not intended to be limiting and may include more or fewer components than those shown, or some components may be combined, or a different arrangement of components.
The following describes each component of the mobile phone in detail with reference to fig. 4:
the RF circuit 401 may be used for receiving and transmitting signals during information transmission and reception or during a call, and in particular, receives downlink information of a base station and then sends the received downlink information to the processor 408 for processing; in addition, the data for designing uplink is transmitted to the base station. In general, the RF circuit 401 includes, but is not limited to, an antenna, at least one amplifier, a transceiver, a coupler, a Low Noise Amplifier (LNA), a duplexer, and the like. In addition, the RF circuitry 401 may also communicate with networks and other devices via wireless communications. The wireless communication may use any communication standard or protocol, including but not limited to global system for Mobile communications (GSM), General Packet Radio Service (GPRS), Code Division Multiple Access (CDMA), Wideband Code Division Multiple Access (WCDMA), Long Term Evolution (LTE), email, Short Messaging Service (SMS), and the like.
The memory 402 may be used to store computer programs and modules, and the processor 408 executes various functional applications and data processing of the mobile phone by operating the computer programs and modules stored in the memory 402. The memory 402 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application program required by at least one function (such as a sound playing function, an image playing function, etc.), and the like; the storage data area may store data (such as audio data, a phonebook, etc.) created according to the use of the cellular phone, and the like. Further, the memory 402 may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device.
The input unit 403 may be used to receive input numeric or character information and generate key signal inputs related to user settings and function control of the cellular phone. Specifically, the input unit 403 may include a touch panel 4031 and other input devices 4032. Touch panel 4031, also referred to as a touch screen, can collect touch operations by a user on or near it (e.g., operations by a user on or near touch panel 4031 using any suitable object or accessory such as a finger, stylus, etc.) and drive the corresponding connected devices according to a predetermined program. Alternatively, the touch panel 4031 may include two portions, a touch detection device and a touch controller. The touch detection device detects the touch direction of a user, detects a signal brought by touch operation and transmits the signal to the touch controller; the touch controller receives touch information from the touch sensing device, converts it to touch point coordinates, and sends the touch point coordinates to the processor 408, and can receive and execute commands from the processor 408. In addition, the touch panel 4031 can be implemented by various types such as a resistive type, a capacitive type, an infrared ray, and a surface acoustic wave. The input unit 403 may include other input devices 4032 in addition to the touch panel 4031. In particular, other input devices 4032 may include, but are not limited to, one or more of a physical keyboard, function keys (such as volume control keys, switch keys, etc.), a trackball, a mouse, a joystick, and the like.
The display unit 404 may be used to display information input by the user or information provided to the user and various menus of the cellular phone. The display unit 404 may include a display panel 4041, and optionally, the display panel 4041 may be configured in the form of a Liquid Crystal Display (LCD), an Organic Light-Emitting Diode (OLED), or the like. Further, touch panel 4031 can overlay display panel 4041 and, when touch operation is detected on or near touch panel 4031, communicate to processor 408 to determine the type of touch event, and processor 408 can then provide a corresponding visual output on display panel 4041 based on the type of touch event. Although in fig. 4, the touch panel 4031 and the display panel 4041 are shown as two separate components to implement the input and output functions of the mobile phone, in some embodiments, the touch panel 4031 and the display panel 4041 may be integrated to implement the input and output functions of the mobile phone.
The handset may also include at least one sensor 405, such as a light sensor, motion sensor, and other sensors. Specifically, the light sensor may include an ambient light sensor that adjusts the brightness of the display panel 4041 according to the brightness of ambient light, and a proximity sensor that turns off the display panel 4041 and/or the backlight when the mobile phone is moved to the ear. As one of the motion sensors, the accelerometer sensor can detect the magnitude of acceleration in each direction (generally, three axes), can detect the magnitude and direction of gravity when stationary, and can be used for applications of recognizing the posture of a mobile phone (such as horizontal and vertical screen switching, related games, magnetometer posture calibration), vibration recognition related functions (such as pedometer and tapping), and the like; as for other sensors such as a gyroscope, a barometer, a hygrometer, a thermometer, and an infrared sensor, which can be configured on the mobile phone, further description is omitted here.
The audio circuitry 406, speaker 4061, microphone 4062 may provide an audio interface between the user and the handset. The audio circuit 406 may transmit the electrical signal converted from the received audio data to the speaker 4061, and convert the electrical signal into a sound signal by the speaker 4061 and output the sound signal; on the other hand, the microphone 4062 converts the collected sound signal into an electrical signal, which is received by the audio circuit 406 and converted into audio data, which is then processed by the audio data output processor 408 and then sent to, for example, another cellular phone via the RF circuit 401, or output to the memory 602 for further processing.
WiFi belongs to short-distance wireless transmission technology, and the mobile phone can help a user to receive and send e-mails, browse webpages, access streaming media and the like through the WiFi module 407, and provides wireless broadband Internet access for the user. Although fig. 4 shows the WiFi module 407, it is understood that it does not belong to the essential constitution of the handset, and can be omitted entirely as needed within the scope not changing the essence of the invention.
The processor 408 is a control center of the mobile phone, connects various parts of the entire mobile phone by using various interfaces and lines, and performs various functions of the mobile phone and processes data by operating or executing computer programs and/or modules stored in the memory 402 and calling data stored in the memory 402, thereby performing overall monitoring of the mobile phone. Alternatively, processor 408 may include one or more processing units; preferably, the processor 408 may integrate an application processor, which handles primarily the operating system, user interface, applications, etc., and a modem processor, which handles primarily the wireless communications. It will be appreciated that the modem processor described above may not be integrated into the processor 408.
The handset also includes a power source 409 (e.g., a battery) for powering the various components, which may preferably be logically connected to the processor 408 via a power management system, so that the power management system may be used to manage charging, discharging, and power consumption.
Although not shown, the mobile phone may further include a camera, a bluetooth module, etc., which are not described herein.
In the foregoing embodiment, the method flows of the steps may be implemented based on the structure of the terminal device. Where both the application layer and the operating system kernel can be viewed as components of the abstract structure of processor 408.
In an embodiment of the present invention, the processor 408, by invoking a computer program stored in the memory 402, is configured to perform the following operations:
in the running process of the APP, receiving a jump request, wherein the jump request is used for making the APPAPP jump from a historical native page to a first native page;
determining whether the first native page is a page with BUG;
if so, determining a target H5 page corresponding to the first native page;
the first native page is replaced with the target H5 page for display.
Therefore, when the APP appears on the first native interface of the APP, the first native interface can be replaced by the target H5 interface to be normally displayed, so that BUG repair can be completed without issuing a new version, and the convenience of APP maintenance is improved.
Those of ordinary skill in the art will appreciate that the elements and algorithm steps of the examples described in connection with the embodiments disclosed herein may be embodied in electronic hardware, computer software, or combinations of both, and that the components and steps of the examples have been described in a functional general in the foregoing description for the purpose of illustrating clearly the interchangeability of hardware and software. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
It can be clearly understood by those skilled in the art that, for convenience and brevity of description, the specific working processes of the terminal and the unit described above may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the several embodiments provided in the present application, it should be understood that the disclosed terminal and method can be implemented in other manners. For example, the above-described apparatus embodiments are merely illustrative, and for example, the above-described division of units is only one type of division of logical functions, 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 also be an electric, mechanical or other form of connection.
The steps in the method of the embodiment of the invention can be sequentially adjusted, combined and deleted according to actual needs. The units in the terminal of the embodiment of the invention can be merged, divided and deleted according to actual needs.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment of the present invention.
In addition, functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
The integrated unit may be stored in a computer-readable storage medium if it is implemented in the form of a software functional unit and sold or used as a separate product. Based on such understanding, the technical solution of the present invention essentially or partially contributes to the prior art, 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 instructions for enabling a terminal device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the above method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U disk, a removable hard disk, a Read-only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing computer programs.
While the invention has been described with reference to specific embodiments, the invention is not limited thereto, and various equivalent modifications and substitutions can be easily made by those skilled in the art within the technical scope of the invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.

Claims (10)

1. A method for repairing BUG is characterized by comprising the following steps:
in the running process of the APP, a jump request is received, and the jump request is used for enabling the APP to jump from a historical native page to a first native page;
determining whether the first native page is a page with BUG;
if yes, determining a target H5 page corresponding to the first native page;
and replacing the first native page with the target H5 page for display.
2. The method of claim 1, wherein before determining the target H5 page to which the first native page corresponds, the method further comprises:
downloading a JSON mapping table from a server; wherein the JSON mapping table comprises: the corresponding relation between the native page and the H5 page, the address of the H5 page, and the parameter name and the parameter type to be received by the H5 page;
the determining whether the first native page is a page in which a BUG occurs includes:
searching whether the JSON mapping table comprises the first native page or not;
and if so, determining that the first native page is a page with BUG.
3. The method of claim 2, wherein the determining the target H5 page to which the first native page corresponds comprises:
and searching the H5 page corresponding to the first native page from the JSON mapping table, and determining the H5 page corresponding to the first native page as the target H5 page.
4. The method of claim 3, wherein replacing the first native page with the target H5 page for display comprises:
acquiring parameters and parameter values included in the first native page;
assembling the parameters and the parameter values into a first JSON character string according to the parameter type of the first native page;
acquiring the address of the target H5 page from the JSON mapping table;
splicing the first JSON character string serving as a parameter with an address of the target H5 page to obtain a first link;
the first link is parsed to load the target H5 page.
5. The method of claim 4, wherein prior to concatenating the first JSON string as a parameter with the address of the target H5 page to obtain the first link, the method further comprises:
carrying out utf-8 coding on the first JSON character string;
the splicing the first JSON character string serving as a parameter and the address of the target H5 page to obtain a first link comprises the following steps:
splicing the encoded first JSON character string serving as a parameter with the address of the target H5 page to obtain the first link.
6. The method according to any one of claims 2 to 5, wherein the downloading the JSON mapping table from the server comprises:
when the APP is initialized, sending a request message to the server; the request message is used for acquiring version information of a JSON mapping table stored by the server;
determining whether the JSON mapping table stored by the server is a new version or not according to the version information of the JSON mapping table stored by the server and the locally stored version information;
and downloading the JSON mapping table under the condition that the JSON mapping table stored by the server is a new version.
7. The method of claim 1, wherein after replacing the first native page with the target H5 page for display, the method further comprises:
assembling the parameters, parameter values and data types of the target H5 page needing to be transmitted to a second native page into a second JSON character string;
carrying out utf-8 coding on the second JSON character string;
splicing the encoded second JSON character string serving as a parameter with a protocol link of the second native page to obtain a second link;
triggering a jump through the second link to display the second native page.
8. A BUG repair device, the device comprising:
the device comprises a receiving unit, a processing unit and a processing unit, wherein the receiving unit is used for receiving a jump request in the running process of an APP, and the jump request is used for jumping the APP from a history native page to a first native page;
a first determining unit, configured to determine whether the first native page is a page in which a BUG occurs;
a second determining unit, configured to determine, when the first native page is a page in which a BUG occurs, a target H5 page corresponding to the first native page;
and the replacing unit is used for replacing the first native page with the target H5 page for displaying.
9. Terminal device comprising a memory, a processor and a computer program stored in said memory and executable on said processor, characterized in that said processor implements the steps of the method for repairing a BUG according to any of claims 1 to 7 when executing said computer program.
10. A computer-readable storage medium, storing a computer program, characterized in that the computer program, when being executed by a processor, implements the steps of the method for repairing a BUG of any of claims 1 to 7.
CN201910814381.XA 2019-08-30 2019-08-30 BUG repairing method and device, terminal equipment and storage medium Pending CN110609694A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910814381.XA CN110609694A (en) 2019-08-30 2019-08-30 BUG repairing method and device, terminal equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910814381.XA CN110609694A (en) 2019-08-30 2019-08-30 BUG repairing method and device, terminal equipment and storage medium

Publications (1)

Publication Number Publication Date
CN110609694A true CN110609694A (en) 2019-12-24

Family

ID=68890741

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910814381.XA Pending CN110609694A (en) 2019-08-30 2019-08-30 BUG repairing method and device, terminal equipment and storage medium

Country Status (1)

Country Link
CN (1) CN110609694A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112764958A (en) * 2021-01-27 2021-05-07 上海淇玥信息技术有限公司 Method and device for assisting in repairing page fault and electronic equipment
CN115129355A (en) * 2022-09-01 2022-09-30 平安银行股份有限公司 Page repairing method and system and computer equipment
CN115687827A (en) * 2022-11-15 2023-02-03 中电金信软件有限公司 Method, device, equipment and medium for communicating native page and H5 page path

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112764958A (en) * 2021-01-27 2021-05-07 上海淇玥信息技术有限公司 Method and device for assisting in repairing page fault and electronic equipment
CN112764958B (en) * 2021-01-27 2023-01-13 上海淇玥信息技术有限公司 Method and device for assisting in repairing page fault and electronic equipment
CN115129355A (en) * 2022-09-01 2022-09-30 平安银行股份有限公司 Page repairing method and system and computer equipment
CN115129355B (en) * 2022-09-01 2023-05-26 平安银行股份有限公司 Page repair method, system and computer equipment thereof
CN115687827A (en) * 2022-11-15 2023-02-03 中电金信软件有限公司 Method, device, equipment and medium for communicating native page and H5 page path
CN115687827B (en) * 2022-11-15 2023-08-25 中电金信软件有限公司 Method, device, equipment and medium for communicating native page and H5 page path

Similar Documents

Publication Publication Date Title
CN106970790B (en) Application program creating method, related equipment and system
CN106850800B (en) Method for determining download path and client
CN104598262A (en) Method and device for updating mobile application
CN103544033A (en) Method, device and associated equipment for rolling back application program
CN107908407B (en) Compiling method and device and terminal equipment
CN110609694A (en) BUG repairing method and device, terminal equipment and storage medium
WO2019076293A1 (en) Differential upgrading method, device and system
CN106713608B (en) Application function state modification method and device and terminal
US20220255639A1 (en) Radio frequency parameter processing method and device, and mobile terminal and storage medium
CN110569078A (en) Method and device for preloading webpage-level program
CN107967153B (en) Application program management method and mobile terminal
CN107025574B (en) Promotion information display method and device
CN106506815A (en) A kind of application enables method and relevant device
CN107465646B (en) A kind of application method for down loading, system and relevant device
CN111966373B (en) APN resetting method, terminal equipment and storage medium
CN106339391B (en) Webpage display method and terminal equipment
US20200310771A1 (en) Application Processing Method for Terminal Device, and Terminal Device
CN106874038B (en) Application installation method and device and mobile terminal
CN110430252B (en) Resource data processing method and device, equipment and readable storage medium
CN106919458B (en) Method and device for Hook target kernel function
CN110865743A (en) Task management method and terminal equipment
CN107979688B (en) application program management method and mobile terminal
CN109145598B (en) Virus detection method and device for script file, terminal and storage medium
CN106445594B (en) System application installation method and device and terminal equipment
CN110287443B (en) Page data display method and related device

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