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
5c7c3387
Commit
5c7c3387
authored
Sep 14, 2021
by
mqf_0707
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
更新tbcc-sdk版本
parent
43f76188
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
19 additions
and
19 deletions
+19
-19
package-lock.json
c_client/package-lock.json
+3
-3
package.json
c_client/package.json
+1
-1
util.js
c_client/src/utils/util.js
+11
-11
yarn.lock
c_client/yarn.lock
+4
-4
No files found.
c_client/package-lock.json
View file @
5c7c3387
...
@@ -5345,9 +5345,9 @@
...
@@ -5345,9 +5345,9 @@
}
}
},
},
"tbcc-sdk-ts"
:
{
"tbcc-sdk-ts"
:
{
"version"
:
"1.0.
9
"
,
"version"
:
"1.0.
10
"
,
"resolved"
:
"https://registry.npmjs.org/tbcc-sdk-ts/-/tbcc-sdk-ts-1.0.
9
.tgz"
,
"resolved"
:
"https://registry.npmjs.org/tbcc-sdk-ts/-/tbcc-sdk-ts-1.0.
10
.tgz"
,
"integrity"
:
"sha512-
g4Rr6thIurH+fWlgaF4y8/aXu0ViVYoAzrZG7Rji5CguzDuZ2L8lH/uXCAzYtNXBmnB7IvtkR2i11xxe1YI8Dw
=="
,
"integrity"
:
"sha512-
z+6/SVclywLnlbIqndPzUDFuVj1NEbojFm9vQAqx1hiXvpJbBcf5Ioo9J7k0rjymXgk0+at+QsnjhwuWEq3o/g
=="
,
"requires"
:
{
"requires"
:
{
"@types/lodash"
:
"^4.14.160"
,
"@types/lodash"
:
"^4.14.160"
,
"@types/node"
:
"^14.6.0"
,
"@types/node"
:
"^14.6.0"
,
...
...
c_client/package.json
View file @
5c7c3387
...
@@ -51,7 +51,7 @@
...
@@ -51,7 +51,7 @@
"react"
:
"^17.0.0"
,
"react"
:
"^17.0.0"
,
"react-dom"
:
"^17.0.0"
,
"react-dom"
:
"^17.0.0"
,
"taro-ui"
:
"^3.0.0-alpha.3"
,
"taro-ui"
:
"^3.0.0-alpha.3"
,
"tbcc-sdk-ts"
:
"^1.0.
9
"
"tbcc-sdk-ts"
:
"^1.0.
10
"
},
},
"devDependencies"
:
{
"devDependencies"
:
{
"@babel/core"
:
"^7.8.0"
,
"@babel/core"
:
"^7.8.0"
,
...
...
c_client/src/utils/util.js
View file @
5c7c3387
import
tbccTs
from
'tbcc-sdk-ts'
import
tbccTs
from
'tbcc-sdk-ts'
import
API
from
'@/api'
import
API
from
'@/api'
const
{
getUserAddress
,
common
Toast
}
=
tbccTs
.
tb
const
{
getUserAddress
,
show
Toast
}
=
tbccTs
.
tb
export
const
noopFn
=
()
=>
{
}
export
const
noopFn
=
()
=>
{
}
// 领取实物
// 领取实物
const
getUerAddressParam
=
async
()
=>
{
const
getUerAddressParam
=
async
()
=>
{
const
userAddress
=
await
getUserAddress
().
catch
(
err
=>
{
const
userAddress
=
await
getUserAddress
().
catch
(
err
=>
{
common
Toast
({
content
:
err
.
errorMessage
});
show
Toast
({
content
:
err
.
errorMessage
});
});
});
if
(
!
userAddress
)
return
false
if
(
!
userAddress
)
return
false
const
{
name
,
telNumber
,
provinceName
,
cityName
,
cityCode
,
countyName
,
detailInfo
,
streetName
}
=
userAddress
||
{};
const
{
name
,
telNumber
,
provinceName
,
cityName
,
cityCode
,
countyName
,
detailInfo
,
streetName
}
=
userAddress
||
{};
...
@@ -58,10 +58,10 @@ export const receiveObjectPrize = async (data) => {
...
@@ -58,10 +58,10 @@ export const receiveObjectPrize = async (data) => {
}
}
const
{
success
,
data
,
message
}
=
await
API
.
receiveObjectPrize
({
...
params
,
...
_params
})
const
{
success
,
data
,
message
}
=
await
API
.
receiveObjectPrize
({
...
params
,
...
_params
})
if
(
success
)
{
if
(
success
)
{
common
Toast
({
content
:
successMsg
})
show
Toast
({
content
:
successMsg
})
resolve
(
true
)
resolve
(
true
)
}
else
{
}
else
{
common
Toast
({
content
:
errorMsg
||
message
})
show
Toast
({
content
:
errorMsg
||
message
})
resolve
(
false
)
resolve
(
false
)
}
}
})
})
...
@@ -71,14 +71,14 @@ export const receiveEnamePrize = async (data) => {
...
@@ -71,14 +71,14 @@ export const receiveEnamePrize = async (data) => {
const
{
params
,
successMsg
,
errorMsg
}
=
data
const
{
params
,
successMsg
,
errorMsg
}
=
data
return
new
Promise
(
async
(
resolve
,
reject
)
=>
{
return
new
Promise
(
async
(
resolve
,
reject
)
=>
{
const
{
success
,
data
,
message
}
=
await
API
.
receiveEnamePrize
(
params
).
catch
(
res
=>
{
const
{
success
,
data
,
message
}
=
await
API
.
receiveEnamePrize
(
params
).
catch
(
res
=>
{
common
Toast
({
content
:
successMsg
||
res
.
message
})
show
Toast
({
content
:
successMsg
||
res
.
message
})
resolve
(
false
)
resolve
(
false
)
});
});
if
(
success
)
{
if
(
success
)
{
common
Toast
({
content
:
successMsg
})
show
Toast
({
content
:
successMsg
})
resolve
(
true
)
resolve
(
true
)
}
else
{
}
else
{
common
Toast
({
content
:
errorMsg
||
message
})
show
Toast
({
content
:
errorMsg
||
message
})
resolve
(
false
)
resolve
(
false
)
}
}
})
})
...
@@ -113,14 +113,14 @@ export const receiveMemberEname = async(data) => {
...
@@ -113,14 +113,14 @@ export const receiveMemberEname = async(data) => {
if
(
result
.
businessSuccess
)
{
if
(
result
.
businessSuccess
)
{
const
{
success
,
data
,
message
}
=
await
API
.
updateEnamePrizeReceived
({
...
ext
})
const
{
success
,
data
,
message
}
=
await
API
.
updateEnamePrizeReceived
({
...
ext
})
if
(
success
)
{
if
(
success
)
{
common
Toast
({
content
:
successMsg
||
'奖品发放成功,请前往我的奖品处进行使用'
})
show
Toast
({
content
:
successMsg
||
'奖品发放成功,请前往我的奖品处进行使用'
})
resolve
(
true
)
resolve
(
true
)
}
else
{
}
else
{
common
Toast
({
content
:
errorMsg
||
message
})
show
Toast
({
content
:
errorMsg
||
message
})
resolve
(
false
)
resolve
(
false
)
}
}
}
else
{
}
else
{
common
Toast
({
content
:
result
.
errorMsg
})
show
Toast
({
content
:
result
.
errorMsg
})
resolve
(
false
)
resolve
(
false
)
}
}
})
})
...
@@ -129,7 +129,7 @@ export const receiveMemberEname = async(data) => {
...
@@ -129,7 +129,7 @@ export const receiveMemberEname = async(data) => {
export
const
addStat
=
async
(
activityId
,
type
)
=>
{
export
const
addStat
=
async
(
activityId
,
type
)
=>
{
return
new
Promise
(
async
(
resolve
,
reject
)
=>
{
return
new
Promise
(
async
(
resolve
,
reject
)
=>
{
const
result
=
await
API
.
addStat
({
activityId
,
type
}).
catch
(
res
=>
{
const
result
=
await
API
.
addStat
({
activityId
,
type
}).
catch
(
res
=>
{
common
Toast
({
content
:
res
&&
res
.
message
});
show
Toast
({
content
:
res
&&
res
.
message
});
});
});
if
(
result
&&
result
.
success
)
{
if
(
result
&&
result
.
success
)
{
resolve
(
true
)
resolve
(
true
)
...
...
c_client/yarn.lock
View file @
5c7c3387
...
@@ -13894,10 +13894,10 @@ taro-ui@^3.0.0-alpha.3:
...
@@ -13894,10 +13894,10 @@ taro-ui@^3.0.0-alpha.3:
lodash "^4.17.10"
lodash "^4.17.10"
prop-types "^15.7.2"
prop-types "^15.7.2"
tbcc-sdk-ts@^1.0.
9
:
tbcc-sdk-ts@^1.0.
10
:
version "1.0.
9
"
version "1.0.
10
"
resolved "https://registry.yarnpkg.com/tbcc-sdk-ts/-/tbcc-sdk-ts-1.0.
9.tgz#36eedaa5f2d164c5e431cfe027dd8241d7622576
"
resolved "https://registry.yarnpkg.com/tbcc-sdk-ts/-/tbcc-sdk-ts-1.0.
10.tgz#8e1489176c843a43f95931aae3e04a5b6c1f8305
"
integrity sha512-
g4Rr6thIurH+fWlgaF4y8/aXu0ViVYoAzrZG7Rji5CguzDuZ2L8lH/uXCAzYtNXBmnB7IvtkR2i11xxe1YI8Dw
==
integrity sha512-
z+6/SVclywLnlbIqndPzUDFuVj1NEbojFm9vQAqx1hiXvpJbBcf5Ioo9J7k0rjymXgk0+at+QsnjhwuWEq3o/g
==
optionalDependencies:
optionalDependencies:
"@types/lodash" "^4.14.160"
"@types/lodash" "^4.14.160"
"@types/node" "^14.6.0"
"@types/node" "^14.6.0"
...
...
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