@uxda/appkit 4.2.98 → 4.3.0

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.js CHANGED
@@ -8,6 +8,7 @@ import Taro, { showModal, getSystemInfoSync, getMenuButtonBoundingClientRect, up
8
8
  import '@nutui/nutui-taro/dist/packages/popup/style/css';
9
9
  import isMobilePhone from 'validator/es/lib/isMobilePhone';
10
10
  import isIdentityCard from 'validator/es/lib/isIdentityCard';
11
+ import qs from 'qs';
11
12
  import { NsForm, NsInput, NsButton, NsIcon, usePopup, useNutshell, NsButtonGroup, usePaging, NsPage, NsTabs, NsTabsItem, NsPageContent, NsSkeleton, NsRepeator, NsCard, NsEmpty, NsCheckbox } from '@uxda/nutshell/taro';
12
13
  import '@nutui/nutui-taro/dist/packages/actionsheet/style/css';
13
14
  import pako from 'pako';
@@ -474,9 +475,19 @@ function useLogger(options) {
474
475
  const pages = Taro.getCurrentPages();
475
476
  const currentPage = pages?.[pages.length - 1];
476
477
  const lastPage = pages?.[pages.length - 2];
478
+ const taroParams = currentPage.$taroParams;
479
+ if (taroParams) {
480
+ delete taroParams.stamp;
481
+ delete taroParams.$taroTimestamp;
482
+ }
483
+ const laseTaroParams = lastPage?.$taroParams;
484
+ if (laseTaroParams) {
485
+ delete laseTaroParams.stamp;
486
+ delete laseTaroParams.$taroTimestamp;
487
+ }
477
488
  params.pages = JSON.stringify({
478
- current: currentPage?.$taroPath,
479
- last: lastPage?.$taroPath
489
+ current: `${currentPage?.route}?${qs.stringify(taroParams)}`,
490
+ last: lastPage ? `${lastPage?.route}?${qs.stringify(laseTaroParams)}` : ""
480
491
  }).slice(0, 1024);
481
492
  console.log(params);
482
493
  const tmpStr = Object.keys(params).map((key) => `${key}=${encodeURIComponent(params[key])}`).join("&");
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@uxda/appkit",
3
- "version": "4.2.98",
3
+ "version": "4.3.0",
4
4
  "description": "小程序应用开发包",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.ts",
@@ -2,6 +2,7 @@
2
2
  * 记录阿里日志
3
3
  * 生产: https://sls.console.aliyun.com/lognext/project/ddyk-prod/logsearch/ddjf-internet-web
4
4
  */
5
+ import qs from 'qs'
5
6
  import { useAppKitOptions } from '../../Appkit'
6
7
  import Taro, { getSystemInfoSync, request } from '@tarojs/taro'
7
8
 
@@ -89,9 +90,21 @@ export function useLogger(options?: LogType) {
89
90
  const pages = Taro.getCurrentPages()
90
91
  const currentPage = pages?.[pages.length - 1]
91
92
  const lastPage = pages?.[pages.length - 2]
93
+ const taroParams = currentPage.$taroParams
94
+ if (taroParams) {
95
+ delete taroParams.stamp
96
+ delete taroParams.$taroTimestamp
97
+ }
98
+ const laseTaroParams = lastPage?.$taroParams
99
+ if (laseTaroParams) {
100
+ delete laseTaroParams.stamp
101
+ delete laseTaroParams.$taroTimestamp
102
+ }
92
103
  params.pages = JSON.stringify({
93
- current: currentPage?.$taroPath,
94
- last: lastPage?.$taroPath,
104
+ current: `${currentPage?.route}?${qs.stringify(taroParams)}`,
105
+ last: lastPage
106
+ ? `${lastPage?.route}?${qs.stringify(laseTaroParams)}`
107
+ : '',
95
108
  }).slice(0, 1024)
96
109
 
97
110
  console.log(params)