mirror of
https://github.com/MrXujiang/h5-Dooring.git
synced 2025-12-12 10:12:51 +00:00
update: encode url
This commit is contained in:
parent
e4dd3d162e
commit
ee28679ead
@ -22,6 +22,7 @@ import req from '@/utils/req';
|
|||||||
import { uuid } from '@/utils/tool';
|
import { uuid } from '@/utils/tool';
|
||||||
import styles from './index.less';
|
import styles from './index.less';
|
||||||
import MyPopover from 'yh-react-popover';
|
import MyPopover from 'yh-react-popover';
|
||||||
|
import { encode } from 'querystring';
|
||||||
|
|
||||||
const { confirm } = Modal;
|
const { confirm } = Modal;
|
||||||
|
|
||||||
@ -54,7 +55,7 @@ const HeaderComponent = memo((props: HeaderComponentProps) => {
|
|||||||
// );
|
// );
|
||||||
// }, 600);
|
// }, 600);
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
window.open(`http://localhost:8008/preview?tid=${props.location.query.tid}&pointData=${JSON.stringify(pointData)}`);
|
window.open(`http://localhost:8008/preview?tid=${props.location.query.tid}&pointData=${encodeURI(JSON.stringify(pointData))}`);
|
||||||
}, 600);
|
}, 600);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@ -19,7 +19,8 @@ interface PointDataItem {
|
|||||||
|
|
||||||
const PreviewPage = memo((props: PreviewPageProps) => {
|
const PreviewPage = memo((props: PreviewPageProps) => {
|
||||||
const [pointData, setPointData] = useState(() => {
|
const [pointData, setPointData] = useState(() => {
|
||||||
const pointDataStr = getQueryString('pointData') || localStorage.getItem('pointData');
|
const pointDataStr =
|
||||||
|
decodeURI(getQueryString('pointData') ?? '') ?? localStorage.getItem('pointData');
|
||||||
let points;
|
let points;
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user