Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
T
taobao-mini-template
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
2
Issues
2
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
qinhaitao
taobao-mini-template
Commits
331d796d
Commit
331d796d
authored
Sep 08, 2020
by
慕轻风
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wnf
parent
6714621a
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
52 additions
and
1 deletion
+52
-1
constants.js
c_client/client/tbcc-sdk/lib/constants.js
+31
-0
tb.js
c_client/client/tbcc-sdk/lib/tb.js
+21
-1
No files found.
c_client/client/tbcc-sdk/lib/constants.js
View file @
331d796d
// 分享配置
export
const
SHARE_CONFIG
=
{
title
:
'分享测试标题'
,
desc
:
'分享测试描述'
,
imageUrl
:
''
,
// 分享图片URL
path
:
'pages/index/index'
};
// 链接配置
export
const
REDIRECT_URL
=
{
'testpage'
:
'/pages/testPage/testPage'
,
'tmall'
:
'https://www.tmall.com'
};
// 领取奖品状态
// 领取奖品状态
export
const
DRAW_STATUS
=
{
export
const
DRAW_STATUS
=
{
// 待领取
// 待领取
...
@@ -21,3 +35,20 @@ export const PRIZE_TYPE = {
...
@@ -21,3 +35,20 @@ export const PRIZE_TYPE = {
OBJECT
:
3
,
OBJECT
:
3
,
THANKS
:
5
THANKS
:
5
};
};
// 我的奖品状态
export
const
PRIZE_DRAW_STATUS_MAP
=
{
RECEIVE
:
1
,
// 待领取
DEALING
:
2
,
// 处理中
SUCCESS
:
3
,
// 领取成功
FAILURE
:
4
,
// 领取失败
FINISHED
:
5
,
// 已过期
REPEAT
:
6
,
// 重新领取
}
// 奖品类型
export
const
PRIZE_TYPE_MAP
=
{
EQUITY
:
1
,
// 权益
INTEGRATION
:
2
,
// 积分
ENTITY
:
3
,
// 实物
THANKS
:
5
// 谢谢参与
}
\ No newline at end of file
c_client/client/tbcc-sdk/lib/tb.js
View file @
331d796d
...
@@ -517,4 +517,24 @@ export const textRiskIdentification = async (text) => {
...
@@ -517,4 +517,24 @@ export const textRiskIdentification = async (text) => {
},
},
})
})
})
})
}
}
\ No newline at end of file
// 剪切板
export
function
setClipboard
(
params
)
{
return
promisifyMyApi
(
'setClipboard'
,
params
)
};
function
promisifyMyApi
(
methodName
,
params
=
{})
{
return
new
Promise
((
resolve
,
reject
)
=>
{
my
[
methodName
]({
...
params
,
success
:
res
=>
{
resolve
(
res
)
},
fail
:
err
=>
{
reject
(
err
)
}
})
})
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment