代码提交
This commit is contained in:
@ -5,7 +5,7 @@
|
||||
* @description:useRouter.js
|
||||
* @update: 2023-10-30 10:52
|
||||
* */
|
||||
const PARAMS_KEY = 'details' // 路由参数key
|
||||
export const PARAMS_KEY = 'details' // 路由参数key
|
||||
|
||||
/**
|
||||
* 封装Router
|
||||
@ -130,8 +130,9 @@ export const useRouter = () => {
|
||||
function getParams(options) {
|
||||
if (typeof options !== 'object') return {}
|
||||
if (!options[PARAMS_KEY]) return {}
|
||||
console.log('参数原始-----',options[PARAMS_KEY])
|
||||
// #ifdef MP-WEIXIN
|
||||
console.log(typeof options[PARAMS_KEY],options[PARAMS_KEY],decodeURIComponent(options[PARAMS_KEY]))
|
||||
// console.log(typeof options[PARAMS_KEY],options[PARAMS_KEY],decodeURIComponent(options[PARAMS_KEY]))
|
||||
// #endif
|
||||
return JSON.parse(decodeURIComponent(options[PARAMS_KEY]));
|
||||
}
|
||||
|
Reference in New Issue
Block a user