Commit 57dea9f4 authored by zhangyuan's avatar zhangyuan

到实际

parent 0da62e72
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
import React from 'react'; import React from 'react';
import { observer } from 'mobx-react'; import { observer } from 'mobx-react';
import './sharePage.less'; import './sharePage.less';
import { _throttle, windowJumpUrl, CHANNEL, generateUUID } from '@/utils/utils'; import { _throttle, windowJumpUrl, CHANNEL, generateUUID, _asyncThrottle } from '@/utils/utils';
import { copyToClipboard } from '@spark/utils'; import { copyToClipboard } from '@spark/utils';
import { Toast } from "@grace/ui"; import { Toast } from "@grace/ui";
import API from '@/api'; import API from '@/api';
...@@ -39,7 +39,7 @@ class SharePage extends React.Component { ...@@ -39,7 +39,7 @@ class SharePage extends React.Component {
} }
/** 唤端 */ /** 唤端 */
toApp = _throttle(() => { toApp = _asyncThrottle(() => {
if (CFG.inviteCode) { if (CFG.inviteCode) {
copyToClipboard(CFG.inviteCode); copyToClipboard(CFG.inviteCode);
Toast.show("复制成功") Toast.show("复制成功")
...@@ -58,7 +58,7 @@ class SharePage extends React.Component { ...@@ -58,7 +58,7 @@ class SharePage extends React.Component {
}, 300) }, 300)
}) })
doAssist = _throttle(async () => { doAssist = _asyncThrottle(async () => {
const { success, message, code } = await API.doAsistInSharePage({ const { success, message, code } = await API.doAsistInSharePage({
channel: CFG.channel, channel: CFG.channel,
deviceId: localStorage.getItem('like_uuid'), deviceId: localStorage.getItem('like_uuid'),
...@@ -120,8 +120,8 @@ class SharePage extends React.Component { ...@@ -120,8 +120,8 @@ class SharePage extends React.Component {
</p> </p>
</div> </div>
<div className='btn_con'> <div className='btn_con'>
<span className='check-btn' onClick={_throttle(() => { <span className='check-btn' onClick={_asyncThrottle(() => {
windowJumpUrl(el.realBuyJumpUrl) this.toApp()
})}></span> })}></span>
</div> </div>
</div> </div>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment