Interface display method and device, electronic equipment and storage medium

By storing configuration information for unreleased versions in the client and replacing response data with an interception component, the problem of manually configuring proxies and data in the version experience is solved, achieving an efficient new feature experience.

CN116361576BActive Publication Date: 2026-02-13BEIJING 58 INFORMATION TECH
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202211602376.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-12-09
Publication Date
2026-02-13
Estimated Expiration
2042-12-09

AI Technical Summary

Technical Problem

During the experience of new client versions, version testers need to manually configure proxies and data repeatedly, resulting in low efficiency.

Method used

The configuration information of the unreleased version is pre-stored in the client. The interception component determines whether the URL is contained in the configuration information. If it is, the response data is replaced with the configuration data for the interface display.

Benefits of technology

It improves the efficiency of the version experience, reduces the manual configuration process, and has universality and portability, making it suitable for unreleased version experiences on any client.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116361576B_ABST
    Figure CN116361576B_ABST
Patent Text Reader

Abstract

Embodiments of the present application provide an interface display method and device, electronic equipment and storage medium. The method is applied to a client and includes: determining a URL of a current access request in the case that a version experience mode is started; wherein the version experience mode represents that the current version of the client is an unreleased version; obtaining response data for the URL; determining whether the URL is included in configuration information of the unreleased version of the client, the configuration information including a plurality of configuration items, each configuration item corresponding to a new function of the unreleased version of the client, and each configuration item including a URL and configuration data corresponding to the URL; in the case that the URL is included in the configuration information, replacing the response data of the URL with the configuration data corresponding to the URL; and performing interface display according to the configuration data corresponding to the URL. Through the method, the configuration process can be effectively reduced, the experience efficiency of version experience is improved, and the method is portable and suitable for version experience of any unreleased version of any client.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of computer, and in particular to an interface display method and device, electronic equipment and storage medium. BACKGROUND

[0002] For the new version of the developed client (such as APP, etc.), before the new version of the client is released, the version experience personnel usually needs to perform version experience to experience a series of processes of the new version, for example, to perform a process operation in order to experience some features of the new function in the new version. Among them, the version experience is a process of overall experience and acceptance of the requirements in the version cycle of the client when the version cycle is about to end. In the version experience stage, since the new version of the client has not been released, the background interface corresponding to the new function has not been put into operation, and therefore the new function in the client is still in a state that only the configured data can be displayed.

[0003] At present, when performing version experience, the version experience personnel needs to obtain test data about a new function of the new version, then connect a proxy software, configure corresponding configuration data based on the obtained test data through the related interface of the proxy software, display the configured data in the client to perform display, so as to realize the experience of a new function in the new version of the client. And this is only the experience process of a new function, if there are multiple new functions in the new version that need to be experienced, the above process needs to be repeated.

[0004] It can be seen that, at present, when performing version experience, the version experience personnel needs to repeatedly perform manual configuration, the experience process is very tedious, which leads to low experience efficiency of version experience. SUMMARY

[0005] The embodiments of the present application provide an interface display method and device, electronic equipment and storage medium, so as to improve the experience efficiency of the version experience of the client.

[0006] The first aspect of the embodiments of the present application provides an interface display method applied to a client, and the method comprises:

[0007] In the case of starting a version experience mode, determine the URL of the current access request; the version experience mode represents that the current version of the client is an unpublished version;

[0008] Obtain response data corresponding to the URL;

[0009] Determine whether the URL is included in the configuration information of the unpublished version of the client, the configuration information comprises a plurality of configuration items, each configuration item corresponds to a new function of the unpublished version of the client, and each configuration item comprises a URL and configuration data corresponding to the URL;

[0010] In a case that the URL is not included in the configuration information, interface display is performed according to response data of the URL.

[0011] Interface display is performed according to configuration data corresponding to the URL.

[0012] Optionally, the method further comprises:

[0013] In a case that the URL is not included in the configuration information, interface display is performed according to response data of the URL.

[0014] Optionally, before the URL of the current access request is determined, the method further comprises:

[0015] When the client is started, a data request carrying version information of an unissued version of the client is sent to a server;

[0016] Configuration information of the unissued version of the client corresponding to the version information returned by the server is acquired and stored.

[0017] Optionally, the client comprises an interception component, and the response data for the URL is acquired, comprising:

[0018] The response data for the URL returned by the server is intercepted through the interception component;

[0019] The judgment whether the URL is included in the configuration information of the unissued version of the client comprises:

[0020] The configuration information of the unissued version of the client stored in the client is read through the interception component;

[0021] It is judged through the interception component whether the URL is included in the configuration information of the unissued version of the client;

[0022] The response data of the URL is replaced by configuration data corresponding to the URL, comprising:

[0023] The configuration data corresponding to the URL is determined from the configuration information through the interception component;

[0024] The response data of the URL is replaced by the configuration data corresponding to the URL through the interception component.

[0025] Optionally, the method further comprises:

[0026] In a case that the URL is not included in the configuration information, the response data of the URL is acquired by the intercepting component, and interface display is performed according to the response data of the URL.

[0027] The second aspect of the embodiment of the present application provides an interface display device, applied to a client, the device comprising:

[0028] A determining module is configured to determine a URL of a current access request in a case that a version experience mode is started, wherein the version experience mode indicates that a current version of the client is an unissued version.

[0029] An acquiring module is configured to acquire response data of the URL.

[0030] A judging module is configured to judge whether the URL is included in configuration information of the unissued version of the client, wherein the configuration information comprises a plurality of configuration items, each configuration item corresponds to a new function of the unissued version of the client, and each configuration item comprises a URL and configuration data corresponding to the URL.

[0031] A replacing module is configured to replace the response data of the URL with the configuration data corresponding to the URL in a case that the URL is included in the configuration information.

[0032] A first display module is configured to perform interface display according to the configuration data corresponding to the URL.

[0033] Optionally, the device further comprises:

[0034] A second display module is configured to perform interface display according to the response data of the URL in a case that the URL is not included in the configuration information.

[0035] Optionally, the device further comprises:

[0036] A requesting module is configured to send a data request carrying version information of the unissued version of the client to a server when the client is started before the URL of the current access request is determined.

[0037] A storage module is configured to acquire and store configuration information of the unissued version of the client corresponding to the version information returned by the server.

[0038] Optionally, the client comprises an intercepting component, and the acquiring module comprises:

[0039] An intercepting module is configured to intercept the response data of the URL returned by the server through the intercepting component.

[0040] The judging module comprises:

[0041] a reading module configured to read, by the intercepting component, the configuration information of the unpublished version of the client stored in the client;

[0042] a judging sub-module configured to judge, by the intercepting component, whether the URL is contained in the configuration information of the unpublished version of the client;

[0043] the replacing module comprises:

[0044] a determining sub-module configured to determine, by the intercepting component, the configuration data corresponding to the URL from the configuration information;

[0045] a replacing sub-module configured to replace, by the intercepting component, the response data of the URL with the configuration data corresponding to the URL.

[0046] Optionally, the apparatus further comprises:

[0047] a third displaying module configured to acquire, by the intercepting component, the response data of the URL in the case that the URL is not contained in the configuration information, and perform interface display according to the response data of the URL.

[0048] A third aspect of the embodiment of the present application provides an electronic device, comprising a processor, a memory, and a computer program stored in the memory and executable on the processor, and when the computer program is executed by the processor, the steps of the interface display method are implemented.

[0049] A fourth aspect of the embodiment of the present application provides a computer readable storage medium, and the computer readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the interface display method are implemented.

[0050] In the interface display method of the embodiment of the present application, in the case that the version experience mode is started, the client can determine whether the URL of the determined access request and the configuration information of the unissued version of the client stored in advance contain each other, if yes, replace the response data obtained for the URL with the configuration data corresponding to the URL, and display the interface according to the configuration data corresponding to the URL, so as to realize the experience of the new function of the client. Through the interface display method of the embodiment, the configuration information of the unissued version of the client is stored in the client in advance, when the new function is experienced, the client can determine whether the URL of the current access request is in the configuration information, if yes, the data is replaced directly, that is, the response data obtained for the URL is replaced with the configuration data corresponding to the URL configured in the configuration information in advance, so as to display the interface according to the configuration data, realize the experience of the new function, so as to effectively reduce the configuration process compared with the manual configuration of the proxy and the data in the prior art when the new function of the unissued version is experienced, and the configuration information of the unissued version of the client is saved in the client in advance before the experience, so as to realize the experience of the new function through the automatic judgment and data replacement of the client. In this way, the experience efficiency of the version experience is greatly improved, and the method is portable and suitable for the version experience of any unissued version of any client. BRIEF DESCRIPTION OF DRAWINGS

[0051] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the following will briefly introduce the drawings needed to be used in the description of the embodiments of the present application. Obviously, the drawings in the following description are only some embodiments of the present application, and other drawings can be obtained by those skilled in the art without any creative labor.

[0052] Figure 1 is a flow chart of an interface display method according to an embodiment of the present application;

[0053] Figure 2 is a schematic diagram of a request configuration information according to an embodiment of the present application;

[0054] Figure 3 is a schematic diagram of a version experience scheme according to an embodiment of the present application;

[0055] Figure 4 is a structural block diagram of an interface display device according to an embodiment of the present application;

[0056] Figure 5 is a schematic diagram of an electronic device according to an embodiment of the present application. DETAILED DESCRIPTION

[0057] The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are only some of the embodiments of the present application, rather than all the embodiments of the present application. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative efforts should fall within the scope of the present application.

[0058] As described above, in the version experience stage, the new version of the client has not been released, the background interface corresponding to the new function has not been put into operation, and the client cannot obtain the related data of the new function from the background, so that in this stage, the new function in the client is only in a state of relying on manual connection of the agent, configuration of the related data through the related interface of the agent, and display according to the configuration data.

[0059] Therefore, the current version experience needs the version experience personnel to manually perform the configuration work of the agent and the data again and again: for example, when performing the version experience, the version experience personnel connects the local agent software such as Charles, configures the network request data through the mock interface, and then displays the network data of the new requirement in the APP running.

[0060] For example, the process link of the existing APP version experience can be sorted out: the developer provides the test data-> the version experience personnel connects the agent-> configures the Charles software mock data-> experiences the new function in the APP. It can be seen that the link is long, and each version experience personnel needs to configure the agent and the data once, and this is only the configuration of one interface, and if there are multiple new interfaces in the version, the process needs to be repeated.

[0061] Therefore, in order to at least partially solve one or more of the above problems and other potential problems, the embodiments of the present application propose an interface display method, which stores the configuration information of the unpublished version of the client in advance in the client by pre-collecting the configuration information, so that when the new function is experienced, the client can judge whether the URL of the current access request is in the configuration information, if yes, the response data obtained for the URL is replaced, the interface is displayed according to the configuration data corresponding to the URL configured in advance, so as to realize the experience of the new function in the unpublished version of the client, and achieve the purpose of efficiently experiencing the new version requirement.

[0062] Please refer to Figure 1 , Figure 1is a flowchart of an interface display method according to an embodiment of the present application. The interface display method provided by the embodiment can be applied to a client. In the embodiment, the client can be a program providing local services for a user, and the client can be implemented in different program forms to realize the same software function. For example, the client can be an application software APP, a mini program, a web browser, etc. As shown in Figure 1 the interface display method of the embodiment can include the following steps:

[0063] Step S11: In the case of starting the version experience mode, determine the URL of the current access request; the version experience mode represents that the current version of the client is an unreleased version.

[0064] In the embodiment, when the version experience of the unreleased version of the client is performed, the client needs to start the version experience mode to prevent affecting other functions of the client. The version experience mode of the embodiment represents that the current version of the client is an unreleased version. After the client starts the version experience mode, the version experience of the unreleased version of the client can be performed in the client, and each step of the embodiment can be implemented. For example, the current version of the client is the released 1.0 version, and the developer newly develops the 1.5 version. Before the 1.5 version is released, the version experience of the 1.5 version needs to be performed in the client. Therefore, the user can start the version experience mode in the current client, so as to perform the version experience of the unreleased 1.5 version in the current client.

[0065] Generally, the switch of the version experience mode can be set in the developer option page of the client by the developer, and the opening and closing of the version experience mode can be performed by the technical personnel (such as the version experience personnel) in the developer option page through the switch. In addition, the developer can set the condition for starting the version experience mode by means of special packaging. When the client detects that the condition for starting the version experience mode is met, the version experience mode is started: for example, the number of clicks can be set by means of special packaging to realize the starting of the version experience mode, etc.

[0066] In the case that the version experience mode is started on the client, a user (such as a version experience personnel) can perform a corresponding operation in the client in order to experience a relevant new function or new page. The corresponding operation can include, but is not limited to, a voice operation, a gesture operation, a click operation on a preset key, a sliding operation, a pressing operation, and the like. Generally, the client relies on network data provided by the server to implement a corresponding function. Each function in the client corresponds to a corresponding server interface (i.e., the aforementioned background interface). The client can determine a corresponding client function of the corresponding operation of the user according to the detected corresponding operation, determine a URL corresponding to the function, send an access request carrying the URL to the server, and thus obtain corresponding network data sent by the server through the interface corresponding to the URL.

[0067] In this step, the client can determine the URL in each sent access request in the case that the version experience mode is started, and thus determine the URL of a current access request at each current time. The current access request in this embodiment is an access request sent at a current time, and the current time can be any time.

[0068] Step S12: Obtain response data corresponding to the URL.

[0069] In this embodiment, after the server receives the access request carrying the URL sent by the client, the server can return response data corresponding to the URL to the client according to the access request, and the client can obtain the response data corresponding to the URL.

[0070] Step S13: Determine whether the URL is included in configuration information of an unpublished version of the client, the configuration information including a plurality of configuration items, each configuration item corresponding to a new function of the unpublished version of the client, and each configuration item including a URL and configuration data corresponding to the URL.

[0071] In this embodiment, the configuration information of the unpublished version of the client is pre-stored in the client. The configuration information of the unpublished version of the client includes a plurality of configuration items, each configuration item corresponding to a new function of the unpublished version of the client, and each configuration item including a URL and configuration data corresponding to the URL. The URL in the configuration item is an interface URL of a background interface corresponding to the new function, and the configuration data corresponding to the URL in the configuration item is used to implement display of the new function corresponding to the URL.

[0072] Since the current version of the client is an unreleased version, the unreleased version can include the functions in the previous version and / or new functions added. For the functions in the previous version in the unreleased version, the background interface corresponding to the functions in the previous version has been online, so the server can determine the corresponding network data as the response data for the URL of the online interface and return it to the client. For the new functions in the unreleased version, the background interfaces corresponding to the new functions are not online, so for the interface URL that has not been online, the server cannot determine the corresponding network data and cannot return the corresponding network data. The server can only return error data such as 400, 404, etc. as the response data for the URL, and return it to the client. At this time, the response data received by the client for the URL is error data. Obviously, the client cannot display the new function according to the response data.

[0073] Therefore, in the embodiment, after the client obtains the response data for the URL, it does not immediately display the interface according to the response data, but first determines whether the URL in the access request is in the configuration information of the unreleased version of the client stored in advance by the client. Since each configuration item in the configuration information corresponds to a new function of the unreleased version of the client, the client needs to determine whether the URL in the access request is included in the configuration information, i.e., whether the URL in the access request is the same as the URL in any configuration item in the configuration information, so as to determine whether the current access request is a background access request of a new function, and whether the response data currently obtained for the URL can be used for interface display.

[0074] Step S14: In the case where the URL is included in the configuration information, the response data of the URL is replaced with the configuration data corresponding to the URL.

[0075] In the embodiment, in the case where the client determines that the URL of the access request is included in the configuration information of the unreleased version of the client, i.e., in the case where the client determines that the URL of the access request is the same as the URL in any configuration item in the configuration information of the unreleased version of the client, the client can determine that the current access request is a background access request of a new function, and the URL of the current access request is the interface URL of a background interface that has not been online. At this time, it can be represented that the user experience is a new function, and the response data obtained by the client for the URL is some error data returned by the server, which cannot be used for display of the new function. Therefore, at this time, the client can replace the response data, replace the response data obtained for the URL with the configuration data corresponding to the URL in the configuration information configured in advance, so as to achieve the purpose of experiencing the new function of the unreleased version of the client based on the configuration data configured in advance.

[0076] Step S15: interface display according to the configuration data corresponding to the URL.

[0077] In this embodiment, after the client replaces the response data for the URL with the configuration data corresponding to the URL in the pre-configured configuration information, the client can display the interface according to the configuration data corresponding to the URL, the client displays the new content of the experience, thereby completing the experience of the new function in the version experience stage.

[0078] It can be understood that each new function experienced by the user in the version experience stage in the client can be implemented by using the interface display method of this embodiment, and the client can implement the interface display of the new function by using the above steps S11-S15 whenever the user experiences a new function.

[0079] By using the interface display method of this embodiment, when the version experience of the client is performed, it is not necessary to manually connect the agent and configure one after another, and a series of pre-operations such as installation of the certificate involved in the connection of the agent are avoided, thereby greatly improving the experience efficiency of the version experience and fully improving the user experience. In addition, the embodiment can be applied to the version experience of any un-released version of any client, and has universality and portability.

[0080] In combination with the above embodiments, in an embodiment, the embodiment of the present application further provides an interface display method. Specifically, in the method, in addition to the above steps, the step S21 can be further included:

[0081] Step S21: in the case that the URL is not included in the configuration information, interface display according to the response data of the URL.

[0082] Generally, when the version experience of the client is performed, the un-released version of the client is not all new functions, but also has old functions. For example, the newly developed new function A needs to be implemented after the old function B is implemented, and therefore, the user can also need to experience and implement the old function when the version experience is performed.

[0083] In the embodiment, when the client determines that the URL of the access request is not included in the configuration information of the un-released version of the client, that is, when the client determines that the URL of the access request is not the same as the URL in any configuration item in the configuration information of the un-released version of the client, since the configuration information includes configuration items corresponding to all new functions in the un-released version of the client, the client can determine that the current access request is not a background access request of a new function, but a background access request of an existing function in the previous version. Accordingly, the URL of the current access request is the interface URL of the online background interface, and at this time, the user experience is an old function, and the response data obtained by the client for the URL is also the corresponding network data returned by the server for the old function, which can be used for display of the old function. Therefore, at this time, the client can display the related interface according to the response data obtained for the URL.

[0084] In the embodiment, during the version experience process, not only the new function can be experienced, but also the old function can be experienced. When the client determines that the current URL is not in the configuration information, the client can display the interface according to the received response data for the URL, so as to realize the experience of the old function during the version experience process, thereby realizing the flexibility and smoothness of the client version experience.

[0085] In combination with the above embodiments, in an embodiment, the embodiment of the present application further provides an interface display method. In the method, before the step S11 of "determining the URL of the current access request", the method can further include steps S31 and S32:

[0086] Step S31: when the client is started, sending a data request carrying version information of the un-released version of the client to the server.

[0087] In the embodiment, when the client starts the version experience mode, the client will request the network to pull the configuration information of the un-released version of the client configured in advance during the version experience when starting. Specifically, when the client is started, a data request carrying version information of the un-released version of the client is sent to the server, so as to request the configuration information of the un-released version of the client required by the current version experience.

[0088] The client start in the present step can refer to the next start after the client starts the version experience mode, because the start of the version experience mode can be performed on the developer options page after the client starts, or the start of the version experience mode can be performed by detecting the condition of starting the version experience mode after the client starts. Therefore, the client requests to pull the configuration information of the present version experience configuration when the next client start is performed after the start of the version experience mode.

[0089] It can be understood that when the next start is not performed after the start of the version experience mode after the client starts, if the version experience is to be performed in the present start stage of the client, the client can send a data request carrying the version information of the unissued version of the client to the server within a preset time period after the start of the version experience mode, so as to perform the version experience in the present start stage of the start of the version experience mode. The preset time period can be set by the technician as needed, and the present embodiment does not limit the same.

[0090] In the present embodiment, a plurality of configuration information is stored in the server, and each configuration information corresponds to an unissued version of a different client. For example, the configuration information stored in the server can include the configuration information of the unissued version 1.1 of the client A, the configuration information of the unissued version 3.2 of the client A, the configuration information of the unissued version 4.1 of the client D, the configuration information of the unissued version 1.1 of the client E, and the like. The creation and generation of each configuration information in the server can be collected and processed in advance by the technician (such as the version experience personnel).

[0091] Preferably, each configuration item corresponding to each new function in the unissued version of the client can be collected from the developer of the unissued version, and each configuration item includes a URL and configuration data corresponding to the URL. Since the unissued version is developed by the developer, the developer is most familiar with the new function, and the developer knows how to display the new function, how to obtain data and parse, so that the configuration data of the new function provided by the developer is the most reliable.

[0092] The technical person can generate a JSON array including the configuration information of multiple configuration items after collecting the configuration information of an unpublished version of a client each time, and upload the configuration information and its corresponding version information to a server storage, where the version information can include a client ID and a version ID. The server can store the configuration information and the version information in association after receiving the configuration information of an unpublished version of a client each time, that is, store the configuration information of an unpublished version of a client in association with the version information of the unpublished version of the client. In this embodiment, the server storing the configuration information can be a CDN (Content Delivery Network) server or a general background server.

[0093] For example, the configuration information of this embodiment can be: configuration item 1: interface URL "url":"https: / / app.com / getInfo / uid=xxx", and its corresponding configuration data is "data":"{\"code\":\"200\",\"msg\":\"success\",\"button\":[{\"name\":\"menu 1\"}]}" ; configuration item 2: interface URL "url":"https: / / app.com / updateInfo / uid=xxx", and its corresponding configuration data is "data":"{\"code\":"203\",\"msg\":\"updata fail\"}". The above is only a part of examples, and this embodiment will not make any limitation on this.

[0094] Step S32: Obtain the configuration information of the unpublished version of the client corresponding to the version information returned by the server and store it.

[0095] In this embodiment, after receiving the data request sent by the client, the server can determine the configuration information of the unpublished version of the client corresponding to the version information of the unpublished version of the client carried in the data request, so as to return the configuration information of the unpublished version of the client to the client. The client can obtain the configuration information of the unpublished version of the client corresponding to the version information of the unpublished version of the client returned by the server, and store it in the client after parsing. Preferably, it can be stored in the memory cache of the client for subsequent version experience.

[0096] In the embodiment, when the client starts, the version information of the unpublished version experienced by the current version of the client is directly requested from the server to pull the configuration information containing all configuration items of the unpublished version of the client, compared with the network request of the configuration information when the client experiences a certain function, the situation that the configured configuration data of the new function cannot be timely displayed due to the asynchronous network request can be avoided, and through the method of pulling and storing the configuration information when the client starts, the smooth progress of the new function experience in the version experience can be ensured.

[0097] Please refer to Figure 2 , Figure 2 is a schematic diagram of requesting configuration information according to an embodiment of the present application. As Figure 2 shown, the client can request configuration data from the server (i.e., server in Figure 2 ) when starting, specifically, can send a data request carrying version information (such as https: / / api.com / getConfig / version=v1.0 in Figure 2 ) to the server, the server can determine the configuration data corresponding to the version information according to the version information carried after receiving the data request, the configuration data includes multiple configuration items, each configuration item includes url+data, and then the server returns the determined configuration data corresponding to the version information to the requesting client, thereby completing the entire process of pulling configuration information when the client starts.

[0098] In combination with the above embodiment, in an embodiment, the present embodiment further provides an interface display method. In the method, the client includes an interception component. In the client of the present embodiment, a network request framework is internally included, and the network request framework is provided with an interception component.

[0099] For example, when the client of the present embodiment is an Android version client, the network request framework in the client can be an OKhttp network request framework, which is a network request framework implemented by java language and has the characteristics of simple configuration and high performance. Correspondingly, the interception component included by the client can be an interceptor provided by the OKhttp network request framework, which is a tool provided by the OKhttp network request framework to intercept network requests, and the interceptor can be customized to perform inspection and modification operations on various parameters of network requests such as request, response, header information, etc. It should be noted that the above is only an example provided by the present embodiment, and the type of client, network request framework and interception component is not limited in the present embodiment.

[0100] In the method, the step S12 can specifically include a step S41, the step S13 can specifically include a step S42 and a step S43, and the "replacing the response data of the URL with the configuration data corresponding to the URL" in the step S14 can specifically include a step S44 and a step S45.

[0101] The step S41: intercepting, by the intercepting component, the response data of the URL returned by the server.

[0102] In the embodiment, the network intercepting framework in the client is used for sending the request and receiving the response data. The client can send the current access request carrying the URL through the network request framework. At this time, the URL of the current access request can be determined through the intercepting component provided by the network request framework. The intercepting component of the embodiment is used for intercepting and replacing the response data.

[0103] In the client of the embodiment, the data returned to the client is required to go to the network request framework first and then return to the client through the network request framework, so as to complete the receiving of the data of the client. Therefore, the response data of the URL returned by the server to the client is first received through the network request framework in the client. At this time, the response data of the URL returned by the server can be intercepted by the intercepting component.

[0104] The step S42: reading, by the intercepting component, the configuration information of the unpublished version of the client stored in the client.

[0105] In the embodiment, the configuration information of the unpublished version of the client stored in the client can be equivalent to a singleton class, which can be globally acquired. However, the singleton is only valid for the intercepting component, that is, only the intercepting component can read the configuration information. Therefore, the client can read the configuration information of the unpublished version of the client stored in the client through the intercepting component.

[0106] The step S43: determining, by the intercepting component, whether the URL is included in the configuration information of the unpublished version of the client.

[0107] In the embodiment, after the intercepting component determines the URL of the current access request and reads the configuration information of the unpublished version of the client stored in the client, the client can determine whether the URL in the access request is included in the configuration information of the unpublished version of the client through the intercepting component, so as to determine whether the URL in the access request is the same as the URL in any configuration item in the configuration information through the intercepting component, so as to determine whether the current access request is a background access request of a new function and whether the response data of the URL currently acquired can be used for interface display.

[0108] Step S44: determining, by the intercepting component, configuration data corresponding to the URL from the configuration information.

[0109] In this embodiment, when the client determines, by the intercepting component, that the URL of the access request is contained in the configuration information of the unpublished version of the client, i.e., when the client determines, by the intercepting component, that the URL of the access request is the same as the URL in any configuration item in the configuration information of the unpublished version of the client, the client can determine, by the intercepting component, configuration data corresponding to the URL from the read configuration information.

[0110] Step S45: replacing, by the intercepting component, the response data of the URL with the configuration data corresponding to the URL.

[0111] When the client determines, by the intercepting component, that the URL of the access request is contained in the configuration information of the unpublished version of the client, after determining, by the intercepting component, the configuration data corresponding to the URL from the configuration information, the intercepted response data of the URL can be replaced, by the intercepting component, with the configuration data corresponding to the URL.

[0112] In this embodiment, after the client replaces the response data by the intercepting component, the intercepting component can return the configuration data corresponding to the replaced URL to the client, i.e., the client can obtain, by the intercepting component, the configuration data corresponding to the replaced URL, so that the client can display the interface according to the configuration data corresponding to the URL, the client displays the new content of the experience, thereby completing the experience of the new function in the version experience stage.

[0113] In this embodiment, the client can implement an interface display method by the intercepting component, when the response data returns to the client network request framework, the intercepting component can be used to judge the URL and replace the response data, so as to display the new function interface according to the replaced configuration data. This embodiment uses the intercepting component to achieve a way of intercepting network requests in the client and replacing the returned response data with the pre-configured configuration data to achieve the purpose of experiencing the new interface. The intercepting component is used to modify the data of the specific interface, which further saves the version experience time and improves the experience efficiency of the version experience, thereby achieving the purpose of efficiently experiencing the new version requirements.

[0114] In combination with any of the above embodiments, in an implementation, the embodiment of the present application further provides an interface display method. In the method, in addition to the above steps, step S51 can be further included:

[0115] Step S51: In the case that the URL is not contained in the configuration information, the response data of the URL is acquired by the intercepting component, and interface display is performed according to the response data of the URL.

[0116] In the embodiment, in the case that the client determines, by the intercepting component, that the URL of the access request is not contained in the configuration information of the un-released version of the client, that is, in the case that the client determines, by the intercepting component, that the URL of the access request is not the same as the URL in any configuration item in the configuration information of the un-released version of the client, since the configuration information contains configuration items corresponding to all new functions in the un-released version of the client, the client can determine, by the intercepting component, that the current access request is not a background access request of a new function, but a background access request of an existing function in the previous version, accordingly, the URL of the current access request is the interface URL of the online background interface, at this time, it can be represented that the user experience is an old function, at this time, the response data of the URL intercepted by the intercepting component is also the corresponding network data returned by the server for the old function, and the network data can be used for display of the old function. Therefore, the intercepting component can return the response data corresponding to the intercepted URL to the client, that is, the client can acquire, by the intercepting component, the response data of the URL, and perform interface display according to the response data of the URL.

[0117] In the embodiment, when the client determines, by the intercepting component, that the current URL is not in the configuration information, the client can acquire, according to the intercepting component, the response data of the URL intercepted by the intercepting component, and perform interface display, thereby further realizing flexibility and fluency of the version experience of the client.

[0118] Please refer to Figure 3 , Figure 3 is a schematic diagram of a version experience scheme according to an embodiment of the present application. As shown in Figure 3 , in the embodiment, the client is an Android APP.

[0119] Firstly, the version experience mode can be started in the APP to prevent affecting other functions. After starting the version experience mode, the version experience of the un-released version of the current APP can be performed in the APP. Usually, this version experience mode switch can be set on the developer option page, or the mode can be started by means of special package and setting the number of clicks.

[0120] Then, the APP is started, and the APP requests the pre-configured configuration information for the current version experience from the background server when the APP is started. Since a plurality of configuration information is stored in the background server, the APP needs to carry the current version information when requesting the configuration information, otherwise the background server does not know which version of the configuration information is requested. The APP parses the configuration information after pulling the configuration information, and stores the parsed configuration information in the APP memory cache for later use.

[0121] Among them, regarding the creation and generation of configuration information in the background server, the version experience personnel needs to collect and process in advance to generate a JSON array for each APP unissued version, forming the configuration information. Each configuration information includes all new functions in the APP unissued version corresponding to the configuration item, and the configuration item mainly includes url and data. After the version experience personnel completes the collection, the configuration information and its corresponding version information (including the client ID and version ID) are uploaded to the CDN server or the background. After the APP is started, the configuration information is pulled according to the version information (i.e. Figure 3 reading the configuration file in the background server).

[0122] Finally, the version experience personnel experiences the new page or new function in the APP, at this time the APP sends an access request carrying the interface URL to the background server through the network request framework in the APP, and receives the response data returned by the background server for the URL. At this time, the network interceptor (OKHttp.PreTestintercepter (chain)) provided by the network request framework will intercept the response data returned by the server for the URL, and determine whether the currently accessed URL exists in the configuration information according to the configuration information stored in the APP.

[0123] If it exists, it means that the current experience is a new function or a new page, at this time the interceptor replaces the intercepted response data of the URL with the configuration data corresponding to the URL in the configuration information, and returns the configuration data corresponding to the URL to the APP, so that the APP displays the interface according to the configuration data corresponding to the URL, and the APP displays the experience content, thereby realizing the display of new functions in the version experience.

[0124] If it does not exist, it means that the current experience is an old function or an old page, at this time the interceptor can return the intercepted response data of the URL to the APP directly, so that the APP displays the interface according to the response data of the URL, and the APP displays the experience content, thereby realizing the display of old functions in the version experience.

[0125] The scheme uses the OKhttp network framework to realize a set of application internal interception network requests, and replaces the response data returned by the server with the configured configuration data to achieve the purpose of experiencing new interfaces. Using the scheme for version experience configuration can effectively reduce the configuration process, and only needs to collect data and upload before experience, greatly improving the experience efficiency, and having portability. The data modification for specific interfaces is realized by the interceptor provided based on the Android network framework, and the purpose of efficiently experiencing new version requirements is achieved.

[0126] It should be noted that, for the method embodiments, in order to simply describe, they are all described as a series of action combinations, but those skilled in the art should know that the embodiments of the present application are not limited to the order of the described actions, because according to the embodiments of the present application, certain steps can be performed in other order or at the same time. Secondly, those skilled in the art should know that the embodiments described in the specification all belong to preferred embodiments, and the actions involved are not necessarily necessary for the embodiments of the present application.

[0127] Based on the same inventive concept, an embodiment of the present application provides an interface display device 400, which can be applied to a client. Referring to Figure 4 , Figure 4 is a structural block diagram of the interface display device provided by an embodiment of the present application. As Figure 4 shown, the interface display device 400 includes:

[0128] A determination module 401 is configured to determine a URL of a current access request when a version experience mode is started, wherein the version experience mode represents that a current version of the client is an unpublished version.

[0129] An acquisition module 402 is configured to acquire response data corresponding to the URL.

[0130] A judgment module 403 is configured to judge whether the URL is included in configuration information of the unpublished version of the client, wherein the configuration information includes a plurality of configuration items, each configuration item corresponds to a new function of the unpublished version of the client, and each configuration item includes a URL and configuration data corresponding to the URL.

[0131] A replacement module 404 is configured to replace the response data of the URL with the configuration data corresponding to the URL when the URL is included in the configuration information.

[0132] A first display module 405 is configured to display an interface according to the configuration data corresponding to the URL.

[0133] Optionally, the device 400 further includes:

[0134] The second display module is configured to display an interface according to the response data of the URL if the URL is not included in the configuration information.

[0135] Optionally, the apparatus 400 further comprises:

[0136] The request module is configured to send a data request carrying version information of the un-published version of the client to a server when the client is started before determining the URL of the current access request.

[0137] The storage module is configured to acquire and store the configuration information of the un-published version of the client corresponding to the version information returned by the server.

[0138] Optionally, the client comprises an interception component, and the acquisition module 402 comprises:

[0139] The interception module is configured to intercept the response data of the URL returned by the server through the interception component.

[0140] The judgment module 403 comprises:

[0141] The reading module is configured to read the configuration information of the un-published version of the client stored in the client through the interception component.

[0142] The judgment submodule is configured to judge whether the URL is included in the configuration information of the un-published version of the client through the interception component.

[0143] The replacement module 404 comprises:

[0144] The determination submodule is configured to determine the configuration data corresponding to the URL from the configuration information through the interception component.

[0145] The replacement submodule is configured to replace the response data of the URL with the configuration data corresponding to the URL through the interception component.

[0146] Optionally, the apparatus 400 further comprises:

[0147] The third display module is configured to acquire the response data of the URL through the interception component if the URL is not included in the configuration information, and display an interface according to the response data of the URL.

[0148] Based on the same inventive concept, another embodiment of the present application provides an electronic device 500, as shown in Figure 5 Figure 5 ​is a schematic diagram of an electronic device according to an embodiment of the present application. The electronic device comprises a processor 501, a memory 502, and a computer program stored in the memory 502 and executable on the processor 501, which, when executed by the processor, implements the steps of the interface display method according to any one of the above embodiments of the present application.

[0149] Based on the same inventive concept, another embodiment of the present application provides a computer readable storage medium, which stores a computer program, and the computer program, when executed by a processor, implements the steps of the interface display method according to any one of the above embodiments of the present application.

[0150] Each of the above embodiments is described in a progressive manner, and each embodiment focuses on the difference from other embodiments. The same or similar parts between the embodiments can be referred to each other.

[0151] It should be noted that, in this document, the term "comprising" or "including" or any other variant thereof is intended to cover non-exclusive inclusion, so that a process, method, article or apparatus including a series of elements not only includes those elements, but also includes other elements not explicitly listed or inherent to such a process, method, article or apparatus. Without more limitations, the element defined by the statement "comprising a" does not exclude the presence of additional identical elements in the process, method, article or apparatus including the element.

[0152] From the above description of the embodiments, those skilled in the art can clearly understand that the above embodiment methods can be realized by means of software and necessary general hardware platforms, of course, they can also be realized by hardware, but in many cases the former is a better embodiment. Based on such understanding, the technical solutions of the present application can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes a series of instructions for making a terminal (which can be a mobile phone, computer, server, air conditioner, or network device, etc.) execute the methods described in the embodiments of the present application.

[0153] The embodiments of the present application are described above in combination with the drawings, but the present application is not limited to the above specific embodiments, which are only illustrative and not restrictive. Those skilled in the art can make many forms under the guidance of the present application without departing from the purpose of the present application and the scope protected by the claims, which all belong to the protection of the present application.

[0154] Those skilled in the art can clearly understand the unit and algorithm steps of each example described in combination with the embodiments disclosed in the embodiments of the present application can be realized by electronic hardware or a combination of computer software and electronic hardware. Whether the functions are realized in hardware or software manner depends on the specific application and design constraints of the technical solution. The skilled person can use different methods to realize the described functions for each specific application, but such implementation should not be considered beyond the scope of the present application.

[0155] Those skilled in the art can clearly understand that, for the convenience and brevity of the description, the specific working processes of the above-described system, device and unit can refer to the corresponding processes in the foregoing method embodiments, which will not be repeated here.

[0156] In the embodiments provided by the present application, it should be understood that the disclosed device and method can be implemented in other ways. For example, the device embodiments described above are only schematic. The division of the units is only a logical function division. There can be another division during actual implementation. For example, a plurality of units or components can be combined or integrated into another system, or some features can be ignored or not executed. In addition, the displayed or discussed mutual couplings or direct couplings or communication connections between the units can be indirect couplings or communication connections through some interfaces, devices or units, and can be electrical, mechanical or in other forms.

[0157] The units described as separate components can or can not be physically separate, and the components shown as units can or can not be physical units, i.e. can be located in one place, or can be distributed on a plurality of network units. Part or all of the units can be selected according to actual needs to achieve the purpose of the embodiment.

[0158] In addition, each functional unit in each embodiment of the present application can be integrated into a processing unit, or each unit can exist physically independently, or two or more units can be integrated into one unit.

[0159] If the functions are realized in the form of software function units and sold or used as independent products, they can be stored in a computer readable storage medium. Based on this understanding, the technical solutions of the present application or the parts of the present application that essentially contribute to the prior art or the parts of the technical solutions can be embodied in the form of software products. The computer software product is stored in a storage medium and includes a plurality of instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the method described in the various embodiments of the present application. The aforementioned storage medium includes various storage media that can store program codes, such as a U disk, a mobile hard disk, a ROM, a RAM, a magnetic disk or an optical disk.

[0160] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art can easily think of changes or replacements within the technical range disclosed by the present application, which should be covered within the protection scope of the present application. Therefore, the protection scope of the present application should be subject to the protection scope of the claims.

Claims

1. An interface presentation method, characterized by, The method applied to a client comprises: In the case of opening a version experience mode, determining a URL of a current access request; the version experience mode represents that a current version of the client is an unreleased version; wherein the version experience mode is opened through a switch in a client developer options page, or is automatically opened through a condition of opening the version experience mode set by a special packaging; Obtaining response data for the URL; Judging whether the URL is contained in configuration information of the unreleased version of the client pre-stored in the client, the configuration information comprising a plurality of configuration items, each configuration item corresponding to a new function of the unreleased version of the client, each configuration item comprising a URL and configuration data corresponding to the URL; wherein the URL is an interface URL of a background interface corresponding to the new function, and the configuration data corresponding to the URL is used to realize display of the new function corresponding to the URL; In the case that the URL is contained in the configuration information, replacing the response data of the URL with the configuration data corresponding to the URL; According to the configuration data corresponding to the URL, performing interface display.

2. The interface presentation method of claim 1, wherein, The method further comprises: In the case that the URL is not contained in the configuration information, performing interface display according to the response data of the URL.

3. The interface presentation method of claim 1, wherein, Before the determination of the URL of the current access request, the method further comprises: When the client is started, sending a data request carrying version information of the unreleased version of the client to a server; Obtaining and storing configuration information of the unreleased version of the client corresponding to the version information returned by the server.

4. The interface presentation method of claim 3, wherein, The client comprises an interception component, and the obtaining of the response data for the URL comprises: Intercepting, through the interception component, the response data for the URL returned by the server; The judgment of whether the URL is contained in the configuration information of the unreleased version of the client comprises: Reading, through the interception component, the configuration information of the unreleased version of the client stored in the client; Judging, through the interception component, whether the URL is contained in the configuration information of the unreleased version of the client; The replacement of the response data of the URL with the configuration data corresponding to the URL comprises: Determining, through the interception component, the configuration data corresponding to the URL from the configuration information; Replacing, through the interception component, the response data of the URL with the configuration data corresponding to the URL.

5. The interface presentation method of claim 4, wherein, The method further comprises: In the case that the URL is not contained in the configuration information, obtaining, through the interception component, the response data of the URL, and performing interface display according to the response data of the URL.

6. An interface presentation device, characterized by The device applied to a client comprises: A determination module, configured to determine a URL of a current access request in the case of opening a version experience mode; the version experience mode represents that a current version of the client is an unreleased version; wherein the version experience mode is opened through a switch in a client developer options page, or is automatically opened through a condition of opening the version experience mode set by a special packaging; an acquisition module, configured to acquire response data for the URL; a judgment module, configured to judge whether the URL is contained in configuration information of an unissued version of the client, the configuration information comprising a plurality of configuration items, each configuration item corresponding to a new function of the unissued version of the client, and each configuration item comprising a URL and configuration data corresponding to the URL; wherein the URL is an interface URL of a background interface corresponding to the new function, and the configuration data corresponding to the URL is used to realize display of the new function corresponding to the URL; a replacement module, configured to replace the response data of the URL with the configuration data corresponding to the URL in a case where the URL is contained in the configuration information; a first display module, configured to perform interface display according to the configuration data corresponding to the URL.

7. The interface presentation device of claim 6, wherein, The device further comprises: a second display module, configured to perform interface display according to the response data of the URL in a case where the URL is not contained in the configuration information.

8. The interface presentation device of claim 6, wherein, The device further comprises: a request module, configured to send a data request carrying version information of an unissued version of the client to a server when the client is started before determining the URL of the current access request; a storage module, configured to acquire and store configuration information of the unissued version of the client corresponding to the version information returned by the server.

9. The interface presentation device of claim 8, wherein, The client comprises an interception component, the acquisition module, and comprises: an interception module, configured to intercept, through the interception component, the response data of the URL returned by the server; the judgment module, comprising: a reading module, configured to read, through the interception component, the configuration information of the unissued version of the client stored in the client; a judgment submodule, configured to judge, through the interception component, whether the URL is contained in the configuration information of the unissued version of the client; the replacement module, comprising: a determination submodule, configured to determine, through the interception component, the configuration data corresponding to the URL from the configuration information; a replacement submodule, configured to replace, through the interception component, the response data of the URL with the configuration data corresponding to the URL.

10. The interface presentation device of claim 9, wherein, The device further comprises: a third display module, configured to acquire, through the interception component, the response data of the URL in a case where the URL is not contained in the configuration information, and perform interface display according to the response data of the URL.

11. An electronic device, comprising: comprise: a processor, a memory, and a computer program stored in the memory and executable on the processor, and the computer program, when executed by the processor, implements the steps of the interface display method according to any one of claims 1 to 5.

12. A computer-readable storage medium, characterized in that, The computer program is stored in the computer readable storage medium, and when executed by the processor, implements the steps of the interface display method according to any one of claims 1 to 5.

Citation Information

Patent Citations

  • Application program testing method, device, computer device and storage medium

    CN108268375A