fast-vue-multi-pages-vite 1.2.1 → 1.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +1 -1
- package/dist/index.js +18 -6
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -1606,10 +1606,11 @@ var FastVueMultiWindow = class FastVueMultiWindow {
|
|
|
1606
1606
|
/**
|
|
1607
1607
|
* 获取实际访问的浏览器地址
|
|
1608
1608
|
*/
|
|
1609
|
-
static
|
|
1610
|
-
let
|
|
1611
|
-
if (window["__LOCATION_HREF"])
|
|
1612
|
-
|
|
1609
|
+
static getRealWindowUrls() {
|
|
1610
|
+
let urls = [];
|
|
1611
|
+
if (window["__LOCATION_HREF"]) urls.push(window["__LOCATION_HREF"]);
|
|
1612
|
+
urls.push(window.location.href);
|
|
1613
|
+
return urls;
|
|
1613
1614
|
}
|
|
1614
1615
|
/**
|
|
1615
1616
|
* 设置当前window对象里实际的url地址
|
|
@@ -1623,13 +1624,24 @@ var FastVueMultiWindow = class FastVueMultiWindow {
|
|
|
1623
1624
|
* @param paramName 参数名
|
|
1624
1625
|
*/
|
|
1625
1626
|
static getWindowUrlParam(paramName) {
|
|
1626
|
-
|
|
1627
|
+
let urls = FastVueMultiWindow.getRealWindowUrls();
|
|
1628
|
+
for (let url of urls) {
|
|
1629
|
+
let value = FastVueMultiHttp.Base.getUrlParam(url, paramName);
|
|
1630
|
+
if (value !== null && value !== void 0) return value;
|
|
1631
|
+
}
|
|
1632
|
+
return null;
|
|
1627
1633
|
}
|
|
1628
1634
|
/**
|
|
1629
1635
|
* 获取地址栏携带的参数对象信息
|
|
1630
1636
|
*/
|
|
1631
1637
|
static getWindowUrlInfo() {
|
|
1632
|
-
|
|
1638
|
+
let info = {};
|
|
1639
|
+
let urls = FastVueMultiWindow.getRealWindowUrls();
|
|
1640
|
+
for (let url of urls) {
|
|
1641
|
+
let value = FastVueMultiHttp.Base.getUrlParamInfo(url);
|
|
1642
|
+
if (value !== null && value !== void 0) for (let valueKey in value) info[valueKey] = value[valueKey];
|
|
1643
|
+
}
|
|
1644
|
+
return info;
|
|
1633
1645
|
}
|
|
1634
1646
|
/**
|
|
1635
1647
|
* 设置当前页面是否使用了vue-router
|