CN114385124A - Jumping method, device and device for independent page based on Vue framework - Google Patents
Jumping method, device and device for independent page based on Vue framework Download PDFInfo
- Publication number
- CN114385124A CN114385124A CN202210047945.3A CN202210047945A CN114385124A CN 114385124 A CN114385124 A CN 114385124A CN 202210047945 A CN202210047945 A CN 202210047945A CN 114385124 A CN114385124 A CN 114385124A
- Authority
- CN
- China
- Prior art keywords
- page
- identifier
- independent
- target
- independent 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.)
- Granted
Links
- 238000000034 method Methods 0.000 title claims abstract description 59
- 230000009191 jumping Effects 0.000 title claims abstract description 50
- 238000013507 mapping Methods 0.000 claims abstract description 43
- 238000004590 computer program Methods 0.000 claims description 17
- 238000012545 processing Methods 0.000 claims description 17
- 230000004044 response Effects 0.000 claims description 9
- 238000013461 design Methods 0.000 description 14
- 238000010586 diagram Methods 0.000 description 13
- 235000014510 cooky Nutrition 0.000 description 8
- 230000006870 function Effects 0.000 description 8
- 230000008569 process Effects 0.000 description 5
- 230000008859 change Effects 0.000 description 4
- 230000000694 effects Effects 0.000 description 4
- 238000011161 development Methods 0.000 description 3
- 238000005516 engineering process Methods 0.000 description 3
- 230000003993 interaction Effects 0.000 description 3
- 230000003287 optical effect Effects 0.000 description 3
- 238000004891 communication Methods 0.000 description 2
- 238000013500 data storage Methods 0.000 description 2
- 239000004973 liquid crystal related substance Substances 0.000 description 2
- 230000003068 static effect Effects 0.000 description 2
- 230000000007 visual effect Effects 0.000 description 2
- 230000001788 irregular Effects 0.000 description 1
- 238000007726 management method Methods 0.000 description 1
- 239000000463 material Substances 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 238000012544 monitoring process Methods 0.000 description 1
- 230000002093 peripheral effect Effects 0.000 description 1
- 230000000750 progressive effect Effects 0.000 description 1
- 238000012795 verification Methods 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F8/00—Arrangements for software engineering
- G06F8/20—Software design
- G06F8/24—Object-oriented
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/44—Arrangements for executing specific programs
- G06F9/451—Execution arrangements for user interfaces
Landscapes
- Engineering & Computer Science (AREA)
- Software Systems (AREA)
- Theoretical Computer Science (AREA)
- General Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Human Computer Interaction (AREA)
- Computer And Data Communications (AREA)
- Information Transfer Between Computers (AREA)
Abstract
Description
技术领域technical field
本申请涉及互联网技术领域,尤其涉及一种基于Vue框架的独立页面的跳转方法、装置及设备。The present application relates to the field of Internet technologies, and in particular, to a method, device, and device for jumping an independent page based on a Vue framework.
背景技术Background technique
Vue是一套用于构建用户界面的渐进式JavaScript框架,Vue在处理表单时,能够非常便捷的根据数据的变化同步改变视图,从而保证用户的视觉效果,使得Vue在全球广域网(World Wide Web,web)项目中得到了广泛的应用。Vue is a set of progressive JavaScript frameworks for building user interfaces. When Vue processes forms, it can easily change the view synchronously according to the changes of data, so as to ensure the visual effect of users, making Vue in the World Wide Web (World Wide Web, web) very convenient. ) project has been widely used.
现有技术中,通过Vue框架构建的web项目通常存在一个独立页面和多个子页面,终端设备通过响应用户的操作,获取用户需要切换至的目标页面对应的统一资源定位系统(uniform resource locator,URL),通过独立页面的Vue路由访问该URL,从而实现不同子页面的跳转。In the prior art, a web project constructed by using the Vue framework usually has an independent page and multiple sub-pages, and the terminal device obtains the uniform resource locator (URL) corresponding to the target page that the user needs to switch to by responding to the user's operation. ), access the URL through the Vue route of the independent page, so as to realize the jump of different sub-pages.
然而,在web项目中存在多个独立页面时,多个独立页面无法共用一个Vue路由,可能存在多个独立页面间无法进行跳转的问题。However, when there are multiple independent pages in a web project, multiple independent pages cannot share a Vue route, and there may be a problem that the jump between multiple independent pages cannot be performed.
发明内容SUMMARY OF THE INVENTION
本申请提供一种基于Vue框架的独立页面的跳转方法、装置及设备,以解决多个独立页面间无法进行跳转的问题。The present application provides a method, device and device for jumping an independent page based on the Vue framework, so as to solve the problem that jumping between multiple independent pages is impossible.
第一方面,本申请实施例提供一种基于Vue框架的独立页面的跳转方法,应用于终端设备,所述终端设备运行有应用程序,所述应用程序用于对第一独立页面进行显示,所述方法包括:In a first aspect, an embodiment of the present application provides a method for jumping an independent page based on a Vue framework, which is applied to a terminal device, where the terminal device runs an application program, and the application program is used to display a first independent page, The method includes:
响应于用户对第一独立页面的点击操作,向应用程序对应的服务器发送页面跳转请求,所述页面跳转请求包括初始会话信息以及第二独立页面的标识;In response to the user's click operation on the first independent page, send a page jump request to the server corresponding to the application, where the page jump request includes the initial session information and the identifier of the second independent page;
接收所述服务器返回的目标会话信息,所述目标会话信息包括目标路由信息;receiving target session information returned by the server, where the target session information includes target routing information;
通过应用程序的导航组件,对所述目标路由信息对应的第二独立页面进行显示。The second independent page corresponding to the target routing information is displayed through the navigation component of the application.
在第一方面的一种可能设计中,所述通过应用程序的导航组件,对所述目标路由信息对应的第二独立页面进行显示,包括:In a possible design of the first aspect, displaying the second independent page corresponding to the target routing information through the navigation component of the application includes:
将所述目标路由信息绑定至所述导航组件中,获取绑定后的导航组件;Binding the target routing information to the navigation component, and obtaining the bound navigation component;
通过所述绑定后的导航组件,访问目标路由信息中的所述第二独立页面对应的目标URL,并对所述第二独立页面进行显示。Through the bound navigation component, the target URL corresponding to the second independent page in the target routing information is accessed, and the second independent page is displayed.
在第一方面的另一种可能设计中,所述初始会话信息包括会话控制标识。In another possible design of the first aspect, the initial session information includes a session control identifier.
第二方面,本申请实施例提供一种基于Vue框架的独立页面的跳转方法,应用于服务器,所述方法包括:In the second aspect, an embodiment of the present application provides a method for jumping an independent page based on a Vue framework, which is applied to a server, and the method includes:
接收终端设备发送的页面跳转请求,所述页面跳转请求包括初始会话信息以及第二独立页面的标识;receiving a page jump request sent by a terminal device, where the page jump request includes initial session information and an identifier of a second independent page;
根据页面的标识与路由信息的第一映射关系以及所述第二独立页面的标识,获取所述第二独立页面的标识对应的目标路由信息;Obtain target routing information corresponding to the identifier of the second independent page according to the first mapping relationship between the identifier of the page and the routing information and the identifier of the second independent page;
根据所述目标路由信息对所述初始会话信息进行配置,生成目标会话信息;Configure the initial session information according to the target routing information to generate target session information;
将所述目标会话信息发送至所述终端设备。Sending the target session information to the terminal device.
在第二方面的一种可能设计中,所述根据页面的标识与路由信息的第一映射关系以及所述第二独立页面的标识,获取所述第二独立页面的标识对应的目标路由信息,包括:In a possible design of the second aspect, the target routing information corresponding to the identifier of the second independent page is acquired according to the first mapping relationship between the identifier of the page and the routing information and the identifier of the second independent page, include:
根据页面的标识与服务器的标识的第二映射关系以及所述第二独立页面的标识,获取所述第二独立页面的标识对应的目标服务器的标识;Obtain the identifier of the target server corresponding to the identifier of the second independent page according to the second mapping relationship between the identifier of the page and the identifier of the server and the identifier of the second independent page;
根据所述第一映射关系以及所述第二独立页面的标识,从所述目标服务器的标识对应的目标服务器中获取所述第二独立页面的标识对应的目标路由信息。According to the first mapping relationship and the identifier of the second independent page, the target routing information corresponding to the identifier of the second independent page is acquired from the target server corresponding to the identifier of the target server.
在第二方面的另一种可能设计中,所述初始会话信息包括会话控制标识,在所述接收终端设备发送的页面跳转请求之后,所述方法还包括:In another possible design of the second aspect, the initial session information includes a session control identifier, and after receiving the page jump request sent by the terminal device, the method further includes:
根据所述会话控制标识,对所述页面跳转请求进行身份验证。The page jump request is authenticated according to the session control identifier.
第三方面,本申请实施例提供一种基于Vue框架的独立页面的跳转装置,应用于终端设备,所述终端设备运行有应用程序,所述应用程序用于对第一独立页面进行显示,所述装置包括:In a third aspect, an embodiment of the present application provides a device for jumping an independent page based on a Vue framework, which is applied to a terminal device, where the terminal device runs an application program, and the application program is used to display a first independent page, The device includes:
发送模块,用于响应于用户对第一独立页面的点击操作,向应用程序对应的服务器发送页面跳转请求,所述页面跳转请求包括初始会话信息以及第二独立页面的标识;a sending module, configured to send a page jump request to the server corresponding to the application in response to the user's click operation on the first independent page, where the page jump request includes the initial session information and the identifier of the second independent page;
接收模块,用于接收所述服务器返回的目标会话信息,所述目标会话信息包括目标路由信息;a receiving module, configured to receive target session information returned by the server, where the target session information includes target routing information;
显示模块,用于通过应用程序的导航组件,对所述目标路由信息对应的第二独立页面进行显示。The display module is used for displaying the second independent page corresponding to the target routing information through the navigation component of the application program.
在第三方面的一种可能设计中,所述显示模块,具体用于:In a possible design of the third aspect, the display module is specifically used for:
将所述目标路由信息绑定至所述导航组件中,获取绑定后的导航组件;Binding the target routing information to the navigation component, and obtaining the bound navigation component;
通过所述绑定后的导航组件,访问目标路由信息中的所述第二独立页面对应的目标URL,并对所述第二独立页面进行显示。Through the bound navigation component, the target URL corresponding to the second independent page in the target routing information is accessed, and the second independent page is displayed.
在第三方面的另一种可能设计中,所述初始会话信息包括会话控制标识。In another possible design of the third aspect, the initial session information includes a session control identifier.
第四方面,本申请实施例提供一种基于Vue框架的独立页面的跳转装置,应用于服务器,所述装置包括:In a fourth aspect, an embodiment of the present application provides a device for jumping an independent page based on a Vue framework, which is applied to a server, and the device includes:
接收模块,用于接收终端设备发送的页面跳转请求,所述页面跳转请求包括初始会话信息以及第二独立页面的标识;a receiving module, configured to receive a page jump request sent by the terminal device, where the page jump request includes initial session information and an identifier of the second independent page;
处理模块,用于根据页面的标识与路由信息的第一映射关系以及所述第二独立页面的标识,获取所述第二独立页面的标识对应的目标路由信息;a processing module, configured to acquire target routing information corresponding to the identifier of the second independent page according to the first mapping relationship between the identifier of the page and the routing information and the identifier of the second independent page;
所述处理模块,还用于根据所述目标路由信息对所述初始会话信息进行配置,生成目标会话信息;The processing module is further configured to configure the initial session information according to the target routing information to generate target session information;
发送模块,用于将所述目标会话信息发送至所述终端设备。A sending module, configured to send the target session information to the terminal device.
在第四方面的一种可能设计中,所述处理模块,具体用于:In a possible design of the fourth aspect, the processing module is specifically used for:
根据页面的标识与服务器的标识的第二映射关系以及所述第二独立页面的标识,获取所述第二独立页面的标识对应的目标服务器的标识;Obtain the identifier of the target server corresponding to the identifier of the second independent page according to the second mapping relationship between the identifier of the page and the identifier of the server and the identifier of the second independent page;
根据所述第一映射关系以及所述第二独立页面的标识,从所述目标服务器的标识对应的目标服务器中获取所述第二独立页面的标识对应的目标路由信息。According to the first mapping relationship and the identifier of the second independent page, the target routing information corresponding to the identifier of the second independent page is acquired from the target server corresponding to the identifier of the target server.
在第四方面的另一种可能设计中,所述初始会话信息包括会话控制标识,在所述接收终端设备发送的页面跳转请求之后,所述处理模块,还用于:In another possible design of the fourth aspect, the initial session information includes a session control identifier, and after receiving the page jump request sent by the terminal device, the processing module is further configured to:
根据所述会话控制标识,对所述页面跳转请求进行身份验证。The page jump request is authenticated according to the session control identifier.
第五方面,本申请实施例提供一种终端设备,包括:收发器、显示器、处理器、存储器及存储在所述存储器上并可在处理器上运行的计算机程序指令,所述处理器执行所述计算机程序指令时用于实现第一方面以及各可能设计提供的方法。In a fifth aspect, an embodiment of the present application provides a terminal device, including: a transceiver, a display, a processor, a memory, and computer program instructions stored in the memory and executable on the processor, the processor executing the The computer program instructions described are used to implement the first aspect and the methods provided by each possible design.
第六方面,本申请实施例提供一种服务器,包括:收发器、处理器、存储器及存储在所述存储器上并可在处理器上运行的计算机程序指令,所述处理器执行所述计算机程序指令时用于实现第二方面以及各可能设计提供的方法。In a sixth aspect, an embodiment of the present application provides a server, including: a transceiver, a processor, a memory, and computer program instructions stored in the memory and executable on the processor, and the processor executes the computer program Instructions are used to implement the second aspect and the methods provided by each possible design.
本申请实施例提供的基于Vue框架的独立页面的跳转方法、装置及设备,在该方法中,通过终端设备响应于用户对第一独立页面的点击操作,向应用程序对应的服务器发送页面跳转请求,服务器接收终端设备发送的页面跳转请求,根据第一映射关系以及第二独立页面的标识,获取第二独立页面的标识对应的目标路由信息,根据目标路由信息对初始会话信息进行配置,生成目标会话信息,并将目标会话信息发送至终端设备。终端设备接收服务器返回的目标会话信息,并通过应用程序的导航组件,对目标路由信息对应的第二独立页面进行显示,从而实现了多个独立页面间的跳转。The method, device, and device for jumping an independent page based on the Vue framework provided by the embodiments of the present application. In the method, the terminal device responds to the user's click operation on the first independent page, and sends the page jump to the server corresponding to the application program. The server receives the page jump request sent by the terminal device, obtains the target routing information corresponding to the identifier of the second independent page according to the first mapping relationship and the identifier of the second independent page, and configures the initial session information according to the target routing information , generate target session information, and send the target session information to the terminal device. The terminal device receives the target session information returned by the server, and displays the second independent page corresponding to the target routing information through the navigation component of the application, thereby realizing jumping between multiple independent pages.
附图说明Description of drawings
此处的附图被并入说明书中并构成本说明书的一部分,示出了符合本申请的实施例,并与说明书一起用于解释本申请的原理。The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the application and together with the description serve to explain the principles of the application.
图1为本申请实施例提供的基于Vue框架的独立页面的跳转方法的一种应用场景示意图;1 is a schematic diagram of an application scenario of a method for jumping an independent page based on a Vue framework provided by an embodiment of the present application;
图2为本申请实施例提供的基于Vue框架的独立页面的跳转方法实施例一的流程示意图;2 is a schematic flowchart of Embodiment 1 of a method for jumping an independent page based on a Vue framework provided by an embodiment of the present application;
图3为本申请实施例提供的Vue框架的结构示意图;3 is a schematic structural diagram of a Vue framework provided by an embodiment of the present application;
图4为本申请实施例提供的基于Vue框架的独立页面的跳转装置实施例一的结构示意图;4 is a schematic structural diagram of Embodiment 1 of a jumping device for an independent page based on a Vue framework provided by an embodiment of the present application;
图5为本申请实施例提供的基于Vue框架的独立页面的跳转装置实施例二的结构示意图;5 is a schematic structural diagram of Embodiment 2 of a jumping device for an independent page based on a Vue framework provided by an embodiment of the present application;
图6为本申请实施例提供的终端设备的结构示意图;FIG. 6 is a schematic structural diagram of a terminal device provided by an embodiment of the present application;
图7为本申请实施例提供的服务器的结构示意图。FIG. 7 is a schematic structural diagram of a server provided by an embodiment of the present application.
通过上述附图,已示出本公开明确的实施例,后文中将有更详细的描述。这些附图和文字描述并不是为了通过任何方式限制本公开构思的范围,而是通过参考特定实施例为本领域技术人员说明本公开的概念。The foregoing drawings have shown clear embodiments of the present disclosure, and will be described in greater detail hereinafter. The drawings and written description are not intended to limit the scope of the disclosed concepts in any way, but rather to illustrate the disclosed concepts to those skilled in the art by referring to specific embodiments.
具体实施方式Detailed ways
为使本申请实施例的目的、技术方案和优点更加清楚,下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。In order to make the purposes, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be described clearly and completely below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments It is a part of the embodiments of the present application, but not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative work fall within the protection scope of the present application.
在介绍本申请的实施例之前,首先对本申请实施例的所涉及的名词进行解释:Before introducing the embodiments of the present application, the terms involved in the embodiments of the present application are first explained:
Vue路由(英文:Vue Router)是单页应用(single page web application,SPA)的路径管理器,换句话说,Vue Router就是web项目的链接路径管理系统。Vue-router是Vue.js官方的路由插件,它和Vue.js是深度集成的,适合用于构建单页面应用。Vue的单页面应用是基于路由和组件构建得到的,路由用于设定访问路径,并建立路径和组件的映射关系。在传统的页面应用中,通常通过超链接实现页面切换和跳转的。在Vue-router单页面应用中,则是通过路径之间的切换,也就是组件的切换,实现页面切换和跳转。换句话说,路由的本质就是建立URL和页面之间的映射关系。Vue Router (English: Vue Router) is a path manager for a single page web application (SPA). In other words, Vue Router is a link path management system for web projects. Vue-router is the official routing plugin for Vue.js. It is deeply integrated with Vue.js and is suitable for building single-page applications. Vue's single-page application is built based on routing and components. Routing is used to set access paths and establish a mapping relationship between paths and components. In traditional page applications, page switching and jumping are usually achieved through hyperlinks. In the Vue-router single-page application, page switching and jumping are realized by switching between paths, that is, switching components. In other words, the essence of routing is to establish a mapping relationship between URLs and pages.
会话信息(英文:Session):负责访问者与网站之间的交互,在用户关闭终端设备时,会话结束。Session information (English: Session): responsible for the interaction between the visitor and the website. When the user closes the terminal device, the session ends.
URL:是互联网上标准资源的地址,举例来说,如:https://www.xxx.com。URL: is the address of a standard resource on the Internet, for example: https://www.xxx.com.
接下来,对本申请实施例的应用背景进行解释:Next, the application background of the embodiment of the present application is explained:
Vue是一种数据双向绑定的前端技术开发框架,当终端设备中的数据发生变化时,显示在终端设备中的视图会随之变化,同样,在视图变化时,数据也会随着视图的改变同步进行更改。这一特性使得Vue能够非常便捷的处理表单,同时保证用户的视觉效果,因此,Vue受到大量开发者的青睐,越来越多的项目采用Vue作为开发技术,使得Vue成为前端编码的主流框架。Vue is a front-end technology development framework with two-way data binding. When the data in the terminal device changes, the view displayed in the terminal device will change accordingly. Similarly, when the view changes, the data will also change with the view. Change sync to make changes. This feature enables Vue to process forms very conveniently and at the same time ensure the user's visual effects. Therefore, Vue is favored by a large number of developers. More and more projects use Vue as a development technology, making Vue the mainstream framework for front-end coding.
现有技术中,使用Vue搭建的web项目,通常存在一个独立页面和多个子页面,终端设备通过响应用户的操作,获取用户需要切换至的目标页面对应的URL,通过独立页面的Vue路由访问该URL,从而实现不同子页面的跳转。In the prior art, a web project built with Vue usually has an independent page and multiple sub-pages. The terminal device responds to the user's operation to obtain the URL corresponding to the target page that the user needs to switch to, and access the page through the Vue route of the independent page. URL, so as to realize the jump to different sub-pages.
然而,上述方法在首次加载该独立页面时需要加载大量静态资源,存在加载时间长,无法实现页面导航功能的问题。为了解决上述问题,在实际开发过程中,通常在web项目中设置多个独立页面,以使多个独立页面之间进行交互,从而解决上述问题。However, the above method needs to load a large number of static resources when the independent page is loaded for the first time, and there is a problem that the loading time is long and the page navigation function cannot be realized. In order to solve the above problems, in the actual development process, multiple independent pages are usually set in the web project, so that the multiple independent pages can interact with each other, so as to solve the above problems.
然而,在web项目中存在多个独立页面时,多个独立页面无法共用一个Vue路由,可能存在多个独立页面间无法进行跳转的问题。However, when there are multiple independent pages in a web project, multiple independent pages cannot share a Vue route, and there may be a problem that the jump between multiple independent pages cannot be performed.
针对上述问题,本申请的发明构思如下:可以预先在服务器中存储页面的标识与路由信息的第一映射关系,在终端设备需要页面跳转时,只需要向服务器发送页面跳转请求,服务器接收该页面跳转请求后,根据该页面请求中的第二独立页面的标识和第一映射关系,获取第二独立页面的标识对应的目标路由信息,并根据该目标路由信息对页面跳转请求中的初始会话信息进行配置,将配置好的目标会话信息发送给终端设备。终端设备在接受到目标会话信息后,就可以通过导航组件对目标会话信息对应的第二独立页面进行显示,就能解决现有技术中多个独立页面间无法进行跳转的问题,提高了用户的使用感受。In view of the above problems, the inventive concept of the present application is as follows: the first mapping relationship between the identifier of the page and the routing information can be stored in the server in advance, and when the terminal device needs page jumping, it only needs to send a page jumping request to the server, and the server receives After the page jump request, according to the identifier of the second independent page in the page request and the first mapping relationship, obtain the target routing information corresponding to the identifier of the second independent page, and according to the target routing information to the page jump request The initial session information is configured, and the configured target session information is sent to the terminal device. After receiving the target session information, the terminal device can display the second independent page corresponding to the target session information through the navigation component, which solves the problem of inability to jump between multiple independent pages in the prior art, and improves the user experience. experience of use.
示例性的,本申请实施例提供的基于Vue框架的独立页面的跳转方法可以应用于图1所示的一种应用场景示意图中。图1为本申请实施例提供的基于Vue框架的独立页面的跳转方法的一种应用场景示意图,用以解决上述技术问题。如图1所示,该应用场景可以包括:终端设备11和至少一个服务器(如图1中的服务器12、服务器13以及服务器14)。Exemplarily, the method for jumping an independent page based on the Vue framework provided by the embodiment of the present application may be applied to the schematic diagram of an application scenario shown in FIG. 1 . FIG. 1 is a schematic diagram of an application scenario of a method for jumping an independent page based on a Vue framework provided by an embodiment of the present application, to solve the above technical problem. As shown in FIG. 1 , the application scenario may include: a
在本实施例中,终端设备11运行有应用程序,该应用程序用于对第一独立页面进行显示。其中,终端设备11还包括导航组件,导航组件包括独立页面控件(如,第一独立页面控件、第二独立页面控件、第三独立页面控件)。In this embodiment, the
在一种可实现的方式下,终端设备11显示有第一独立页面,用户点击导航组件中的第二独立页面控件,终端设备11响应于用户的点击操作,向服务器12发送页面跳转请求。服务器12接收终端设备11发送的页面跳转请求,既可以根据该页面跳转请求从服务器12中获取目标路由信息,还可以从服务器13或服务器14中获取目标路由信息,并根据目标路由信息对初始会话信息进行配置,将配置好的目标会话信息发送至终端设备11,以使终端设备11能够通过应用程序的导航组件对目标路由信息对应的第二独立页面进行显示。In an achievable manner, the
下面,通过具体实施例对本申请的技术方案进行详细说明。Hereinafter, the technical solutions of the present application will be described in detail through specific embodiments.
需要说明的是,下面这几个具体的实施例可以相互结合,对于相同或相似的概念或过程可能在某些实施例中不再赘述。It should be noted that the following specific embodiments may be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments.
图2为本申请实施例提供的基于Vue框架的独立页面的跳转方法实施例一的流程示意图。如图2所示,该基于Vue框架的独立页面的跳转方法可以包括如下步骤:FIG. 2 is a schematic flowchart of Embodiment 1 of a method for jumping an independent page based on a Vue framework provided by an embodiment of the present application. As shown in Figure 2, the jumping method of the independent page based on the Vue framework may include the following steps:
S21、终端设备响应于用户对第一独立页面的点击操作,向应用程序对应的服务器发送页面跳转请求。S21. In response to the user's click operation on the first independent page, the terminal device sends a page jump request to the server corresponding to the application program.
本申请实施例提供的基于Vue框架的独立页面的跳转方案,需要为用户提供操作界面,并且为了进行数据的获取和分析,还需要后台服务平台,以使用户能够通过安装在终端设备上的应用程序对服务平台进行访问。The jumping scheme of the independent page based on the Vue framework provided by the embodiment of the present application needs to provide the user with an operation interface, and in order to acquire and analyze data, a background service platform is also required, so that the user can The application accesses the service platform.
其中,页面跳转请求包括初始会话信息以及第二独立页面的标识。The page jump request includes initial session information and an identifier of the second independent page.
示例性的,用于显示第二独立页面的应用程序与用于显示第一独立页面的应用程序可以是同一个,也可以是不同的应用程序。Exemplarily, the application for displaying the second independent page and the application for displaying the first independent page may be the same, or may be different applications.
举例来说,假设该应用程序中有四个独立页面,分别为首页页面,消息页面,购物车页面和我的页面,该应用程序中的导航组件包括独立页面控件(如首页控件、消息控件,购物车控件和我的控件)。假设第一独立页面为首页页面,第二独立页面为消息页面,用户可以点击消息控件,终端设备响应于用户的点击操作,向应用程序对应的服务器发送页面跳转请求。For example, suppose there are four independent pages in the application, namely the home page, message page, shopping cart page and my page, and the navigation components in this application include independent page controls (such as home page control, message control, cart control and my control). Assuming that the first independent page is the home page and the second independent page is a message page, the user can click on the message control, and the terminal device sends a page jump request to the server corresponding to the application in response to the user's click operation.
再举例来说,终端设备预先安装有至少一个应用程序,假设至少一个应用程序为商品推广应用程序和商品购买应用程序,商品推广应用程序用于对第一独立页面进行显示,第一独立页面用于显示商品的推广信息;商品购买应用程序用于对第二独立页面进行显示,当前时刻终端设备运行有商品推广应用程序。在用户使用商品推广应用程序浏览第一独立页面中显示的商品推广信息时,若用户想要购买商品推广信息对应的商品,可以点击该商品对应的商品控件,终端设备响应于用户的点击操作,向商品推广应用程序对应的服务器发送页面跳转请求,以使后续终端设备向用户显示第二独立页面(也就是商品购买页面),从而方便用户购买该商品。For another example, the terminal device is pre-installed with at least one application program, assuming that the at least one application program is a commodity promotion application and a commodity purchase application, the commodity promotion application is used to display the first independent page, and the first independent page uses It is used to display the promotion information of the commodity; the commodity purchase application is used to display the second independent page, and the terminal device runs the commodity promotion application at the current moment. When the user browses the product promotion information displayed on the first independent page using the product promotion application, if the user wants to purchase the product corresponding to the product promotion information, he can click the product control corresponding to the product, and the terminal device responds to the user's click operation, A page jump request is sent to the server corresponding to the product promotion application, so that the subsequent terminal device displays a second independent page (that is, a product purchase page) to the user, thereby facilitating the user to purchase the product.
相应的,针对于服务器来说,则接收终端设备发送的页面跳转请求。Correspondingly, for the server, the page jump request sent by the terminal device is received.
S22、服务器根据页面的标识与路由信息的第一映射关系以及第二独立页面的标识,获取第二独立页面的标识对应的目标路由信息。S22. The server acquires target routing information corresponding to the identifier of the second independent page according to the first mapping relationship between the identifier of the page and the routing information and the identifier of the second independent page.
其中,第一映射关系可以是该服务器对应的技术人员预先存储在服务器中的映射关系,如,该技术人员可以通过数据存储设备将上述第一映射关系存储到该服务器中。除此以外,还可以是从其他服务器或数据库中获取的映射关系,可以根据实际情况进行选择,本申请实施例对此不进行具体限制,The first mapping relationship may be a mapping relationship pre-stored in the server by a technician corresponding to the server. For example, the technician may store the above-mentioned first mapping relationship in the server through a data storage device. In addition, it can also be a mapping relationship obtained from other servers or databases, which can be selected according to the actual situation, which is not specifically limited in this embodiment of the present application.
示例性的,上述第一映射关系可以如下表1所示:Exemplarily, the above-mentioned first mapping relationship may be as shown in Table 1 below:
表1Table 1
以表1所示的第一映射关系为例,若页面跳转请求中的第二独立页面的标识为页面的标识1,则根据该第一映射关系,服务器可以确定与第二独立页面的标识对应的目标路由信息为路由信息1。Taking the first mapping relationship shown in Table 1 as an example, if the identifier of the second independent page in the page jump request is the identifier 1 of the page, then according to the first mapping relationship, the server can determine the identifier of the second independent page. The corresponding target routing information is routing information 1.
在一种可能的实现方式中,假设第一独立页面与第二独立页面可以通过一个应用程序在终端设备上进行显示,则服务器根据第一映射关系以及第二独立页面的标识,从存储在服务器本地的路由信息中确定出目标路由信息。In a possible implementation manner, assuming that the first independent page and the second independent page can be displayed on the terminal device through an application, the server will store the data in the server according to the first mapping relationship and the identifier of the second independent page. The target routing information is determined from the local routing information.
在另一种可能的实现方式中,假设第一独立页面与第二独立页面需要通过不同的应用程序在终端设备上进行显示,则服务器根据页面的标识与服务器的标识的第二映射关系以及第二独立页面的标识,获取第二独立页面的标识对应的目标服务器的标识,并根据第一映射关系以及第二独立页面的标识,从目标服务器的标识对应的目标服务器中获取第二独立页面的标识对应的目标路由信息。In another possible implementation manner, assuming that the first independent page and the second independent page need to be displayed on the terminal device through different application programs, the server can use the second mapping relationship between the identifier of the page and the identifier of the server and the first The identifier of the second independent page is obtained, and the identifier of the target server corresponding to the identifier of the second independent page is obtained, and the identifier of the second independent page is obtained from the target server corresponding to the identifier of the second independent page according to the first mapping relationship and the identifier of the second independent page. Identifies the corresponding destination routing information.
其中,第二映射关系可以是上述服务器对应的技术人员预先存储在服务器中的映射关系,如,该技术人员可以通过数据存储设备将上述第二映射关系存储到该服务器中。除此以外,还可以是从其他服务器或数据库中获取的映射关系,可以根据实际情况进行选择,本申请实施例对此不进行具体限制,The second mapping relationship may be a mapping relationship pre-stored in the server by a technician corresponding to the server. For example, the technician may store the second mapping relationship in the server through a data storage device. In addition, it can also be a mapping relationship obtained from other servers or databases, which can be selected according to the actual situation, which is not specifically limited in this embodiment of the present application.
示例性的,上述第二映射关系可以如下表2所示:Exemplarily, the foregoing second mapping relationship may be shown in Table 2 below:
表2Table 2
以表2所示的第二映射关系为例,若页面跳转请求中的第二独立页面的标识为标识1,则根据该第二映射关系,服务器可以确定与第二独立页面的标识对应的目标服务器的标识为服务器的标识1。Taking the second mapping relationship shown in Table 2 as an example, if the identification of the second independent page in the page jump request is identification 1, then according to the second mapping relationship, the server can determine the identification corresponding to the second independent page. The ID of the target server is ID 1 of the server.
其中,第一映射关系和第二映射关系可以为技术人员灵活配置在服务器中映射关系,以便于后续服务器获取携带目标路由信息的目标会话信息,并发送给终端设备。与现有技术中在终端设备侧的应用程序代码中固定路由信息,通过导航组件实现独立页面的跳转相比,本申请实施例实现了动态绑定路由信息,提高了独立页面跳转的灵活性。The first mapping relationship and the second mapping relationship can be flexibly configured in the server for technicians, so that the subsequent server can obtain the target session information carrying the target routing information and send it to the terminal device. Compared with the prior art in which the routing information is fixed in the application code on the terminal device side and the jumping of the independent page is realized through the navigation component, the embodiment of the present application realizes the dynamic binding of the routing information, which improves the flexibility of the jumping of the independent page. sex.
现有技术中,存在通过储存在用户本地终端上的数据(英文:Cookie)存储路由信息,实现多独立页面的路由交互的方法,然而该方法仅适用于不跨域的情况。与现有技术相比,本方式可以实现跨域访问,从而解决了为独立页面的跳转多样性和兼容性。In the prior art, there is a method of storing routing information through data (cookies in English) stored on the user's local terminal to realize routing interaction of multiple independent pages. However, this method is only applicable to the situation that does not cross domains. Compared with the prior art, this method can realize cross-domain access, thereby solving the diversity and compatibility of jumping for independent pages.
在再一种可能的实现方式中,服务器还可以根据第一映射关系以及第二独立页面的标识,从预先设置的路由信息服务器中获取第二独立页面的标识对应的目标路由信息,实现了跨域访问。In yet another possible implementation manner, the server may also obtain the target routing information corresponding to the identifier of the second independent page from the preset routing information server according to the first mapping relationship and the identifier of the second independent page, so as to realize the crossover Domain access.
其中,路由信息服务器可以为远程字典服务(Remote Dictionary Server,Redis),还可以为路由信息数据库,可以根据实际情况进行设定,本申请实施例对此不进行具体限制。The routing information server may be a remote dictionary service (Remote Dictionary Server, Redis) or a routing information database, which may be set according to actual conditions, which is not specifically limited in this embodiment of the present application.
S23、服务器根据目标路由信息对初始会话信息进行配置,生成目标会话信息。S23. The server configures the initial session information according to the target routing information, and generates target session information.
在一种可能的实现方式中,将目标路由信息写入初始会话信息中的对应位置,从而生成目标会话信息。In a possible implementation manner, target routing information is written into a corresponding position in the initial session information, thereby generating target session information.
在另一种可能的实现方式中,提取目标路由信息中的路由参数,并将该路由参数中的各参数分别写入初始会话信息中的对应位置,从而生成目标会话信息,以使目标会话信息中携带有目标路由信息。In another possible implementation manner, the routing parameters in the target routing information are extracted, and each parameter in the routing parameters is written into the corresponding positions in the initial session information, so as to generate the target session information, so that the target session information It carries the destination routing information.
S24、服务器将目标会话信息发送至终端设备。S24, the server sends the target session information to the terminal device.
相应的,针对于终端设备来说,则接收服务器返回的目标会话信息,目标会话信息包括目标路由信息。Correspondingly, for the terminal device, the target session information returned by the server is received, and the target session information includes target routing information.
S25、终端设备通过应用程序的导航组件,对目标路由信息对应的第二独立页面进行显示。S25. The terminal device displays the second independent page corresponding to the target routing information through the navigation component of the application.
在一种可能的实现方式中,将目标路由信息绑定至导航组件中,获取绑定后的导航组件,通过绑定后的导航组件,访问目标路由信息中的第二独立页面对应的目标URL,并对第二独立页面进行显示,从而实现独立页面的跳转,以便于用户后续对第二独立页面进行操作。In a possible implementation, the target routing information is bound to the navigation component, the bound navigation component is obtained, and the target URL corresponding to the second independent page in the target routing information is accessed through the bound navigation component. , and display the second independent page, so as to realize the jumping of the independent page, so as to facilitate the user to operate the second independent page later.
其中,访问第二独立页面对应的目标URL,并对第二独立页面进行显示可以通过以下方式实现:Wherein, accessing the target URL corresponding to the second independent page and displaying the second independent page can be implemented in the following ways:
图3为本申请实施例提供的Vue框架的结构示意图。如图3所示,该Vue框架可以为Model-View-View Model(简称:MVVM)框架,该Vue框架包括指令解析器31、观察器32以及数据监听器33。其中,指令解析器31用于对元素节点的指令进行扫描和解析,实现动态绑定函数的功能;观察器32用于通过指令绑定回调函数,从而更新视图;数据监听器33用于对数据对象的所有属性进行监听,从而获取到最新的通知订阅者和订阅者的新值。FIG. 3 is a schematic structural diagram of a Vue framework provided by an embodiment of the present application. As shown in FIG. 3 , the Vue framework may be a Model-View-View Model (referred to as: MVVM) framework, and the Vue framework includes an
在一种具体的实现方式中,终端设备访问第二独立页面对应的目标URL,并接受该目标URL返回的用于显示第二独立页面的数据。通过指令解析器31对上述数据进行扫描和解析,获取处理后的数据,并将处理后的数据发送至观察器32。进一步的,终端设备通过观察器32中的更新器更新视图,对第二独立页面进行显示,并通过观察器32中的数据执行保护模块将处理后的数据发送给数据监听器33,以使数据监听器33对其进行监听。In a specific implementation manner, the terminal device accesses the target URL corresponding to the second independent page, and accepts the data returned by the target URL for displaying the second independent page. The above data is scanned and parsed by the
本申请实施例提供的基于Vue框架的独立页面的跳转方法,通过终端设备响应于用户对第一独立页面的点击操作,向应用程序对应的服务器发送页面跳转请求,服务器接收终端设备发送的页面跳转请求,根据第一映射关系以及第二独立页面的标识,获取第二独立页面的标识对应的目标路由信息,根据目标路由信息对初始会话信息进行配置,生成目标会话信息,并将目标会话信息发送至终端设备。终端设备接收服务器返回的目标会话信息,并通过应用程序的导航组件,对目标路由信息对应的第二独立页面进行显示,从而实现了多个独立页面间的跳转。In the method for jumping an independent page based on the Vue framework provided by the embodiment of the present application, in response to the user's click operation on the first independent page, the terminal device sends a page jump request to the server corresponding to the application program, and the server receives the information sent by the terminal device. The page jump request, according to the first mapping relationship and the identifier of the second independent page, obtains the target routing information corresponding to the identifier of the second independent page, configures the initial session information according to the target routing information, generates the target session information, and converts the target session information to the target session information. Session information is sent to the terminal device. The terminal device receives the target session information returned by the server, and displays the second independent page corresponding to the target routing information through the navigation component of the application, thereby realizing jumping between multiple independent pages.
在现有技术中,通过Cookie实现多独立页面的路由交互需要应用程序开启Cookie功能,然而,由于任何人都可以分析存放在本地的Cookie,可能存在Cookie欺骗的情况,导致安全性较差。且,在应用程序为浏览器时,原有Cookie存储的路由信息将会失效,可靠性较差。与上述相比,本申请实施例通过携带有目标路由信息的目标会话信息实现独立页面的跳转,由于目标路由信息并不会被恶意程序获取,且无法对服务器中存储的路由信息进行修改,从而保证了信息的安全性。进一步的,由于浏览器无法禁用会话信息,会话信息不依赖浏览器环境,适用性强,保证了第二独立页面的可获取性和可靠性。In the prior art, implementing the routing interaction of multiple independent pages through cookies requires the application to enable the cookie function. However, since anyone can analyze the cookies stored locally, there may be cookie deception, resulting in poor security. Moreover, when the application is a browser, the routing information stored in the original cookie will be invalid, and the reliability is poor. Compared with the above, the embodiment of the present application realizes the jumping of an independent page through the target session information carrying the target routing information, because the target routing information will not be acquired by malicious programs, and the routing information stored in the server cannot be modified. Thereby ensuring the security of information. Further, since the browser cannot disable the session information, the session information does not depend on the browser environment and has strong applicability, which ensures the availability and reliability of the second independent page.
可选的,在一些实施例中,初始会话信息还包括会话控制标识,则在接收终端设备发送的页面跳转请求之后,该基于Vue框架的独立页面的跳转还包括:根据会话控制标识,对页面跳转请求进行身份验证。Optionally, in some embodiments, the initial session information further includes a session control identifier, then after receiving a page jump request sent by the terminal device, the jumping of the independent page based on the Vue framework further includes: according to the session control identifier, Authenticate page redirect requests.
其中,在终端设备的应用程序的Cookie功能禁用,或不支持Cookie功能时,终端设备可以将会话控制标识重写入第一独立页面的URL中,获取重写后的第一独立页面的URL,并根据该重写后的第一独立页面的URL生成初始会话信息,以使服务器对重写后的第一独立页面的URL进行解析,获取会话控制标识。也就是说,此时初始会话信息包括重写后的第一独立页面的URL。Wherein, when the cookie function of the application program of the terminal device is disabled or does not support the cookie function, the terminal device can rewrite the session control identifier into the URL of the first independent page, and obtain the rewritten URL of the first independent page, The initial session information is generated according to the URL of the rewritten first independent page, so that the server parses the URL of the rewritten first independent page to obtain the session control identifier. That is to say, at this time, the initial session information includes the rewritten URL of the first independent page.
在上述实施例中,通过根据会话控制标识,对页面跳转请求进行身份验证,保证了信息的安全性,防止非法入侵者对信息进行窃取。In the above-mentioned embodiment, by performing identity verification on the page jump request according to the session control identifier, the security of the information is ensured and information is prevented from being stolen by illegal intruders.
可选的,在一些实施例中,应用程序的导航组件预先设置有默认路由信息。在用户首次点击处于关闭状态的应用程序,或点击应用程序中的初始化控件(如首页控件)时,终端设备为用户显示默认路由信息对应的独立页面,实现默认的路由导航,从而提高了用户的体验。Optionally, in some embodiments, the navigation component of the application is preset with default routing information. When the user clicks the closed application for the first time, or clicks the initialization control (such as the home page control) in the application, the terminal device displays the independent page corresponding to the default routing information for the user, and realizes the default routing navigation, thereby improving the user's experience. experience.
下述为本申请装置实施例,可以用于执行本申请方法实施例。对于本申请装置实施例中未披露的细节,请参照本申请方法实施例。The following are apparatus embodiments of the present application, which can be used to execute the method embodiments of the present application. For details not disclosed in the device embodiments of the present application, please refer to the method embodiments of the present application.
图4为本申请实施例提供的基于Vue框架的独立页面的跳转装置实施例一的结构示意图。如图4所示,该装置应用于终端设备,终端设备运行有应用程序,应用程序用于对第一独立页面进行显示,装置包括:FIG. 4 is a schematic structural diagram of Embodiment 1 of an apparatus for jumping an independent page based on a Vue framework provided by an embodiment of the present application. As shown in FIG. 4 , the device is applied to a terminal device, and the terminal device runs an application program, and the application program is used to display the first independent page, and the device includes:
发送模块41,用于响应于用户对第一独立页面的点击操作,向应用程序对应的服务器发送页面跳转请求,页面跳转请求包括初始会话信息以及第二独立页面的标识;The sending
接收模块42,用于接收服务器返回的目标会话信息,目标会话信息包括目标路由信息;a receiving
显示模块43,用于通过应用程序的导航组件,对目标路由信息对应的第二独立页面进行显示。The
在本申请实施例的一种可能设计中,显示模块43,具体用于:In a possible design of the embodiment of the present application, the
将目标路由信息绑定至导航组件中,获取绑定后的导航组件;Bind the target routing information to the navigation component, and obtain the bound navigation component;
通过绑定后的导航组件,访问目标路由信息中的第二独立页面对应的目标URL,并对第二独立页面进行显示。Through the bound navigation component, the target URL corresponding to the second independent page in the target routing information is accessed, and the second independent page is displayed.
在本申请实施例的另一种可能设计中,初始会话信息包括会话控制标识。In another possible design of the embodiment of the present application, the initial session information includes a session control identifier.
本申请实施例提供的基于Vue框架的独立页面的跳转装置,可用于执行上述任一实施例中的终端设备侧的基于Vue框架的独立页面的跳转方法,其实现原理和技术效果类似,在此不再赘述。The jumping device for an independent page based on the Vue framework provided by the embodiment of the present application can be used to execute the jumping method for the independent page based on the Vue framework on the terminal device side in any of the above embodiments, and its implementation principle and technical effect are similar. It is not repeated here.
图5为本申请实施例提供的基于Vue框架的独立页面的跳转装置实施例二的结构示意图。如图5所示,该装置应用于服务器,该装置包括:FIG. 5 is a schematic structural diagram of Embodiment 2 of an apparatus for jumping an independent page based on a Vue framework provided by an embodiment of the present application. As shown in Figure 5, the device is applied to a server, and the device includes:
接收模块51,用于接收终端设备发送的页面跳转请求,页面跳转请求包括初始会话信息以及第二独立页面的标识;The receiving
处理模块52,用于根据页面的标识与路由信息的第一映射关系以及第二独立页面的标识,获取第二独立页面的标识对应的目标路由信息;The
处理模块52,还用于根据目标路由信息对初始会话信息进行配置,生成目标会话信息;The
发送模块53,用于将目标会话信息发送至终端设备。The sending
在本申请实施例的一种可能设计中,处理模块52,具体用于:In a possible design of the embodiment of the present application, the
根据页面的标识与服务器的标识的第二映射关系以及第二独立页面的标识,获取第二独立页面的标识对应的目标服务器的标识;According to the second mapping relationship between the identifier of the page and the identifier of the server and the identifier of the second independent page, obtain the identifier of the target server corresponding to the identifier of the second independent page;
根据第一映射关系以及第二独立页面的标识,从目标服务器的标识对应的目标服务器中获取第二独立页面的标识对应的目标路由信息。According to the first mapping relationship and the identifier of the second independent page, the target routing information corresponding to the identifier of the second independent page is acquired from the target server corresponding to the identifier of the target server.
在本申请实施例的另一种可能设计中,初始会话信息包括会话控制标识,在接收终端设备发送的页面跳转请求之后,处理模块52,还用于:In another possible design of the embodiment of the present application, the initial session information includes a session control identifier, and after receiving a page jump request sent by the terminal device, the
根据会话控制标识,对页面跳转请求进行身份验证。Authenticate page jump requests based on session control identifiers.
本申请实施例提供的基于Vue框架的独立页面的跳转装置,可用于执行上述任一实施例中的服务器侧的基于Vue框架的独立页面的跳转方法,其实现原理和技术效果类似,在此不再赘述。The jumping device for an independent page based on the Vue framework provided by the embodiment of the present application can be used to execute the jumping method for the independent page based on the Vue framework on the server side in any of the above embodiments. The implementation principle and technical effect are similar. This will not be repeated here.
需要说明的是,应理解以上装置的各个模块的划分仅仅是一种逻辑功能的划分,实际实现时可以全部或部分集成到一个物理实体上,也可以物理上分开。且这些模块可以全部以软件通过处理元件调用的形式实现;也可以全部以硬件的形式实现;还可以部分模块通过处理元件调用软件的形式实现,部分模块通过硬件的形式实现。此外,这些模块全部或部分可以集成在一起,也可以独立实现。这里的处理元件可以是一种集成电路,具有信号的处理能力。在实现过程中,上述方法的各步骤或以上各个模块可以通过处理器元件中的硬件的集成逻辑电路或者软件形式的指令完成。It should be noted that it should be understood that the division of each module of the above apparatus is only a division of logical functions, and may be fully or partially integrated into a physical entity in actual implementation, or may be physically separated. And these modules can all be implemented in the form of software calling through processing elements; they can also all be implemented in hardware; some modules can also be implemented in the form of calling software through processing elements, and some modules can be implemented in hardware. In addition, all or part of these modules can be integrated together, and can also be implemented independently. The processing element here may be an integrated circuit with signal processing capability. In the implementation process, each step of the above-mentioned method or each of the above-mentioned modules can be completed by an integrated logic circuit of hardware in the processor element or an instruction in the form of software.
图6为本申请实施例提供的终端设备的结构示意图。如图6所示,该终端设备11可以包括:处理器61、存储器62、收发器63、显示器64及存储在存储器62上并可在处理器61上运行的计算机程序指令,处理器61执行计算机程序指令时实现前述任一实施例提供的终端设备侧的基于Vue框架的独立页面的跳转方法。FIG. 6 is a schematic structural diagram of a terminal device provided by an embodiment of the present application. As shown in FIG. 6 , the
可选的,该终端设备11的上述各个器件之间可以通过系统总线连接。Optionally, the above-mentioned components of the
可选的,终端设备11还可以包括与其他设备进行交互的接口。Optionally, the
收发器63用于和其他服务器进行通信,该收发器63构成通信接口。The transceiver 63 is used to communicate with other servers, and the transceiver 63 constitutes a communication interface.
可选的,在硬件实现上,上述图4所示实施例中的:发送模块41和接收模块42对应于本实施例中的收发器63,显示模块43对应于本实施例中的显示器64。Optionally, in terms of hardware implementation, in the embodiment shown in FIG. 4 above, the sending
显示器64用于通过终端设备11显示独立页面以及和人机交互。可选的,显示器64可以是用户界面,该用户界面可以包括图形、文本、图标、视频及其它们的任意组合。在一些实施例中,显示器64可以为终端设备11的前面板;在另一些实施例中,显示器64可以是柔性显示屏,设置在终端设备11的弯曲表面上或折叠面上。甚至,显示器64还可以设置成非矩形的不规则图形的显示屏,也即异形屏。显示器64可以采用液晶显示屏(Liquid CrystalDisplay,LCD)、有机发光二极管(Organic Light-Emitting Diode,OLED)等材质制备。The display 64 is used for displaying independent pages and interacting with the human-computer through the
本申请实施例提供的终端设备,可用于执行上述任一方法实施例提供的终端设备侧的基于Vue框架的独立页面的跳转方法,其实现原理和技术效果类似,在此不再赘述。The terminal device provided by the embodiment of the present application can be used to execute the method for jumping an independent page based on the Vue framework on the terminal device side provided by any of the above method embodiments, and the implementation principle and technical effect thereof are similar, and are not repeated here.
图7为本申请实施例提供的服务器的结构示意图。如图7所示,该服务器可以包括:处理器71、存储器72、收发器73及存储在存储器72上并可在处理器71上运行的计算机程序指令,处理器71执行计算机程序指令时实现前述任一实施例提供的服务器侧的基于Vue框架的独立页面的跳转方法。FIG. 7 is a schematic structural diagram of a server provided by an embodiment of the present application. As shown in FIG. 7 , the server may include: a processor 71, a memory 72, a transceiver 73, and computer program instructions stored in the memory 72 and executable on the processor 71, and the processor 71 implements the foregoing when executing the computer program instructions Any one of the embodiments provides a server-side jumping method for an independent page based on the Vue framework.
可选的,该服务器的上述各个器件之间可以通过系统总线连接。Optionally, the above-mentioned various devices of the server may be connected through a system bus.
可选的,服务器还可以包括与其他设备进行交互的接口。Optionally, the server may further include interfaces for interacting with other devices.
收发器73用于和其他服务器以及终端设备进行通信,该收发器73构成通信接口。The transceiver 73 is used to communicate with other servers and terminal devices, and the transceiver 73 constitutes a communication interface.
可选的,在硬件实现上,上述图5所示实施例中的:接收模块51和发送模块53对应于本实施例中的收发器73,处理模块52对应于本实施例中的处理器71。Optionally, in terms of hardware implementation, in the embodiment shown in FIG. 5 above, the receiving
本申请实施例提供的服务器,可用于执行上述任一方法实施例提供的服务器侧的基于Vue框架的独立页面的跳转方法,其实现原理和技术效果类似,在此不再赘述。The server provided by this embodiment of the present application can be used to execute the server-side jumping method for an independent page based on the Vue framework provided by any of the above method embodiments, and the implementation principle and technical effect thereof are similar, and are not repeated here.
存储器可以是单独的存储单元,也可以是集成在处理器中的存储单元。处理器的数量为一个或者多个。The memory can be a separate storage unit or a storage unit integrated in the processor. The number of processors is one or more.
应理解,处理器可以是中央处理单元(Central Processing Unit,CPU),还可以是其他通用处理器、数字信号处理器(Digital Signal Processor,DSP)、专用集成电路(Application Specific Integrated Circuit,ASIC)等。通用处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。结合本申请所公开的方法的步骤可以直接体现为硬件处理器执行完成,或者用处理器中的硬件及软件模块组合执行完成。It should be understood that the processor may be a central processing unit (Central Processing Unit, CPU), or other general-purpose processors, a digital signal processor (Digital Signal Processor, DSP), an application specific integrated circuit (Application Specific Integrated Circuit, ASIC), etc. . A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like. The steps in combination with the method disclosed in the present application can be directly embodied as executed by a hardware processor, or executed by a combination of hardware and software modules in the processor.
系统总线可以是外设部件互连标准(peripheral component interconnect,PCI)总线或扩展工业标准结构(extended industry standard architecture,EISA)总线等。系统总线可以分为地址总线、数据总线、控制总线等。为便于表示,图中仅用一条粗线表示,但并不表示仅有一根总线或一种类型的总线。存储器可能包括随机存取存储器(randomaccess memory,RAM),也可能还包括非易失性存储器(non-volatile memory,NVM),例如至少一个磁盘存储器。The system bus may be a peripheral component interconnect (PCI) bus or an extended industry standard architecture (EISA) bus or the like. The system bus can be divided into address bus, data bus, control bus and so on. For ease of presentation, only one thick line is used in the figure, but it does not mean that there is only one bus or one type of bus. The memory may include random access memory (RAM), and may also include non-volatile memory (NVM), such as at least one disk storage.
实现上述各方法实施例的全部或部分步骤可以通过程序指令相关的硬件来完成。前述的程序可以存储于一可读取存储器中。该程序在执行时,执行包括上述各方法实施例的步骤;而前述的存储器(存储介质)包括:只读存储器(read-only memory,ROM)、RAM、快闪存储器、硬盘、固态硬盘、磁带(英文:magnetic tape)、软盘(英文:floppy disk)、光盘(英文:optical disc)及其任意组合。All or part of the steps for implementing the above method embodiments may be completed by program instructions related to hardware. The aforementioned program can be stored in a readable memory. When the program is executed, the steps including the above method embodiments are executed; and the aforementioned memory (storage medium) includes: read-only memory (ROM), RAM, flash memory, hard disk, solid-state hard disk, magnetic tape (English: magnetic tape), floppy disk (English: floppy disk), optical disc (English: optical disc) and any combination thereof.
本申请实施例提供一种计算机可读存储介质,该计算机可读存储介质中存储有计算机指令,当该计算机指令在计算机上运行时,使得计算机执行上述基于Vue框架的独立页面的跳转方法。Embodiments of the present application provide a computer-readable storage medium, where computer instructions are stored in the computer-readable storage medium, and when the computer instructions are executed on a computer, the computer executes the above-mentioned method for jumping an independent page based on the Vue framework.
上述的计算机可读存储介质,上述可读存储介质可以是由任何类型的易失性或非易失性存储设备或者它们的组合实现,如静态随机存取存储器,电可擦除可编程只读存储器,可擦除可编程只读存储器,可编程只读存储器,只读存储器,磁存储器,快闪存储器,磁盘或光盘。可读存储介质可以是通用或专用计算机能够存取的任何可用介质。The above-mentioned computer-readable storage medium, the above-mentioned readable storage medium can be realized by any type of volatile or non-volatile storage device or their combination, such as static random access memory, electrically erasable programmable read-only memory memory, erasable programmable read-only memory, programmable read-only memory, read-only memory, magnetic memory, flash memory, magnetic disk or optical disk. A readable storage medium can be any available medium that can be accessed by a general purpose or special purpose computer.
可选的,将可读存储介质耦合至处理器,从而使处理器能够从该可读存储介质读取信息,且可向该可读存储介质写入信息。当然,可读存储介质也可以是处理器的组成部分。处理器和可读存储介质可以位于专用集成电路(Application Specific IntegratedCircuits,ASIC)中。当然,处理器和可读存储介质也可以作为分立组件存在于设备中。Optionally, a readable storage medium is coupled to the processor such that the processor can read information from, and write information to, the readable storage medium. Of course, the readable storage medium can also be an integral part of the processor. The processor and the readable storage medium may reside in Application Specific Integrated Circuits (ASIC). Of course, the processor and the readable storage medium may also exist in the device as discrete components.
本申请实施例还提供一种计算机程序产品,该计算机程序产品包括计算机程序,该计算机程序存储在计算机可读存储介质中,至少一个处理器可以从该计算机可读存储介质中读取该计算机程序,至少一个处理器执行计算机程序时可实现上述基于Vue框架的独立页面的跳转方法。Embodiments of the present application further provide a computer program product, where the computer program product includes a computer program, the computer program is stored in a computer-readable storage medium, and at least one processor can read the computer program from the computer-readable storage medium , when at least one processor executes a computer program, the above-mentioned method for jumping an independent page based on the Vue framework can be implemented.
应当理解的是,本公开并不局限于上面已经描述并在附图中示出的精确结构,并且可以在不脱离其范围进行各种修改和改变。本公开的范围仅由所附的权利要求书来限制。It is to be understood that the present disclosure is not limited to the precise structures described above and illustrated in the accompanying drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.
Claims (10)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210047945.3A CN114385124B (en) | 2022-01-17 | 2022-01-17 | Independent page jump method, device and equipment based on Vue framework |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210047945.3A CN114385124B (en) | 2022-01-17 | 2022-01-17 | Independent page jump method, device and equipment based on Vue framework |
Publications (2)
Publication Number | Publication Date |
---|---|
CN114385124A true CN114385124A (en) | 2022-04-22 |
CN114385124B CN114385124B (en) | 2025-04-08 |
Family
ID=81201141
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202210047945.3A Active CN114385124B (en) | 2022-01-17 | 2022-01-17 | Independent page jump method, device and equipment based on Vue framework |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN114385124B (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN115150662A (en) * | 2022-06-20 | 2022-10-04 | 北京奇艺世纪科技有限公司 | Data processing method, system, device, readable storage medium and electronic equipment |
WO2024109881A1 (en) * | 2022-11-25 | 2024-05-30 | 天翼数字生活科技有限公司 | Multi-module routing jumping method, apparatus and terminal for client, and medium |
Citations (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2008142614A1 (en) * | 2007-05-24 | 2008-11-27 | Nokia Corporation | Webpage history view |
CN106815276A (en) * | 2015-11-27 | 2017-06-09 | 阿里巴巴集团控股有限公司 | Method for page jump and device |
CN108153768A (en) * | 2016-12-05 | 2018-06-12 | 腾讯科技(深圳)有限公司 | Method for page jump, data processing method, device and page jump control system |
WO2019080796A1 (en) * | 2017-10-23 | 2019-05-02 | 北京金山云网络技术有限公司 | Method, apparatus and device for separating foreground and background of web system, and storage medium |
CN110046310A (en) * | 2019-04-03 | 2019-07-23 | 北京字节跳动网络技术有限公司 | The method and apparatus for analyzing the redirected link in the page |
CN110502232A (en) * | 2018-05-16 | 2019-11-26 | 杭州海康威视系统技术有限公司 | The routing address configuration method and configuration device of page application |
CN110647700A (en) * | 2019-08-13 | 2020-01-03 | 平安普惠企业管理有限公司 | Page resource loading method and device, computer equipment and storage medium |
CN110968824A (en) * | 2018-09-30 | 2020-04-07 | 北京国双科技有限公司 | Page data processing method and device |
CN111143723A (en) * | 2019-12-26 | 2020-05-12 | 五八同城信息技术有限公司 | Page jump method and device, electronic equipment and storage medium |
CN111443908A (en) * | 2020-03-19 | 2020-07-24 | 深圳市震有软件科技有限公司 | vue method, device, equipment and medium for realizing route interaction of multiple independent pages |
CN113127772A (en) * | 2021-04-22 | 2021-07-16 | 挂号网(杭州)科技有限公司 | Method and device for determining webpage access address, electronic equipment and storage medium |
-
2022
- 2022-01-17 CN CN202210047945.3A patent/CN114385124B/en active Active
Patent Citations (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2008142614A1 (en) * | 2007-05-24 | 2008-11-27 | Nokia Corporation | Webpage history view |
CN106815276A (en) * | 2015-11-27 | 2017-06-09 | 阿里巴巴集团控股有限公司 | Method for page jump and device |
CN108153768A (en) * | 2016-12-05 | 2018-06-12 | 腾讯科技(深圳)有限公司 | Method for page jump, data processing method, device and page jump control system |
WO2019080796A1 (en) * | 2017-10-23 | 2019-05-02 | 北京金山云网络技术有限公司 | Method, apparatus and device for separating foreground and background of web system, and storage medium |
CN110502232A (en) * | 2018-05-16 | 2019-11-26 | 杭州海康威视系统技术有限公司 | The routing address configuration method and configuration device of page application |
CN110968824A (en) * | 2018-09-30 | 2020-04-07 | 北京国双科技有限公司 | Page data processing method and device |
CN110046310A (en) * | 2019-04-03 | 2019-07-23 | 北京字节跳动网络技术有限公司 | The method and apparatus for analyzing the redirected link in the page |
CN110647700A (en) * | 2019-08-13 | 2020-01-03 | 平安普惠企业管理有限公司 | Page resource loading method and device, computer equipment and storage medium |
CN111143723A (en) * | 2019-12-26 | 2020-05-12 | 五八同城信息技术有限公司 | Page jump method and device, electronic equipment and storage medium |
CN111443908A (en) * | 2020-03-19 | 2020-07-24 | 深圳市震有软件科技有限公司 | vue method, device, equipment and medium for realizing route interaction of multiple independent pages |
CN113127772A (en) * | 2021-04-22 | 2021-07-16 | 挂号网(杭州)科技有限公司 | Method and device for determining webpage access address, electronic equipment and storage medium |
Non-Patent Citations (2)
Title |
---|
SHIQI GUAN等: "Front-end and Back-end Separation - React Based Framework for Networked Remote Control Laboratory", 《2018 37TH CHINESE CONTROL CONFERENCE (CCC)》, 7 October 2018 (2018-10-07) * |
刘一田等: "微前端化微应用管理控制台", 《计算机系统应用》, no. 09, 15 September 2020 (2020-09-15) * |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN115150662A (en) * | 2022-06-20 | 2022-10-04 | 北京奇艺世纪科技有限公司 | Data processing method, system, device, readable storage medium and electronic equipment |
CN115150662B (en) * | 2022-06-20 | 2024-05-14 | 北京奇艺世纪科技有限公司 | Data processing method, system, device, readable storage medium and electronic equipment |
WO2024109881A1 (en) * | 2022-11-25 | 2024-05-30 | 天翼数字生活科技有限公司 | Multi-module routing jumping method, apparatus and terminal for client, and medium |
Also Published As
Publication number | Publication date |
---|---|
CN114385124B (en) | 2025-04-08 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN111639278B (en) | A web page loading method and device | |
EP2183721B1 (en) | Secure inter-module communication mechanism | |
US10015226B2 (en) | Methods for making AJAX web applications bookmarkable and crawlable and devices thereof | |
JP6945782B2 (en) | Methods and devices and electronic devices that enable communication between web pages and native applications | |
US20160335680A1 (en) | Securing expandable display advertisements in a display advertising environment | |
CN107390994B (en) | Interface presentation method and device | |
US20080120393A1 (en) | Web control simulators for mobile devices | |
US7984170B1 (en) | Cross-domain communication in domain-restricted communication environments | |
CN108416021B (en) | Browser webpage content processing method and device, electronic equipment and readable medium | |
US10866884B2 (en) | Stateless injected script debugging | |
US11455365B2 (en) | Data processing method and apparatus | |
CN111079048B (en) | Page loading method and device | |
CN109194742B (en) | A virtual machine console connection method, device and storage medium | |
CN105354337A (en) | Web crawler implementation method and web crawler system | |
CN114385124A (en) | Jumping method, device and device for independent page based on Vue framework | |
CN105095220B (en) | A browser implementation method, terminal and virtualized proxy device | |
CN109299331B (en) | Method and device for displaying hypertext markup language HTML5 page by Air | |
WO2020073374A1 (en) | Advertisement anti-shielding method and device | |
CN104932910A (en) | Method and system for application program interface extension | |
AU2018390863B2 (en) | Computer system and method for extracting dynamic content from websites | |
CN105607928A (en) | Supporting method for browser kernel and webpage display method and apparatus | |
CN105721251A (en) | Reconfigurable testing pile service method and system | |
CN108459890B (en) | Interface display method and device for application | |
CN113515710B (en) | Page information display method and device, electronic equipment and storage medium | |
US12026272B2 (en) | Loading and managing third-party tools on a website |
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 | ||
GR01 | Patent grant | ||
GR01 | Patent grant |