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
cde4439e
Commit
cde4439e
authored
Nov 10, 2020
by
qinhaitao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix:
🐛
error
parent
1553e7a0
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
16 additions
and
9 deletions
+16
-9
base.controller.ts
v2.0/src/controller/common/base.controller.ts
+1
-1
login.controller.ts
v2.0/src/controller/common/login.controller.ts
+1
-1
stat.controller.ts
v2.0/src/controller/common/stat.controller.ts
+10
-2
task.controller.ts
v2.0/src/controller/common/task.controller.ts
+4
-4
test1.controller.ts
v2.0/src/controller/custom/test1.controller.ts
+0
-1
No files found.
v2.0/src/controller/common/base.controller.ts
View file @
cde4439e
...
...
@@ -14,7 +14,7 @@ export default class BaseController {
* 活动基本信息
*/
@
commonDecorator
.
checkParams
([
'activityId'
])
@
commonDecorator
.
noCheckUser
([
'activityId'
])
@
commonDecorator
.
noCheckUser
@
services
([
CommonBaseService
])
async
getActivityBaseInfoById
(
context
:
IContext
<
IParams
>
,
...
...
v2.0/src/controller/common/login.controller.ts
View file @
cde4439e
...
...
@@ -14,7 +14,7 @@ export default class LoginController {
* 登录接口, 初始化/更新用户信息
*/
@
commonDecorator
.
checkParams
([
'activityId'
,
'userNick'
,
'avatar'
,
'isFollow'
])
@
commonDecorator
.
noCheckUser
([
'activityId'
])
@
commonDecorator
.
noCheckUser
@
commonDecorator
.
registeInfos
([
'vipInfo'
])
@
services
([
CommonUserService
,
CommonAccessService
])
async
login
(
...
...
v2.0/src/controller/common/stat.controller.ts
View file @
cde4439e
...
...
@@ -35,8 +35,16 @@ export default class StatController {
{
activityInfo
,
userInfo
}:
IControllerInfos
,
[
commonStatService
]:
[
CommonStatService
]
)
{
const
commonStatGetStatsResult1
=
await
commonStatService
.
getStats
(
context
.
data
.
activityId
,
context
.
data
.
startDay
,
context
.
data
.
endDay
)
const
commonStatBuildExcelResult2
=
await
commonStatService
.
buildExcel
(
context
.
data
.
startDay
,
context
.
data
.
endDay
,
commonStatGetStatsResult1
)
const
commonStatGetStatsResult1
=
await
commonStatService
.
getStats
(
context
.
data
.
activityId
,
context
.
data
.
startDay
,
context
.
data
.
endDay
)
const
commonStatBuildExcelResult2
=
await
commonStatService
.
buildExcel
(
context
.
data
.
startDay
,
context
.
data
.
endDay
,
commonStatGetStatsResult1
)
return
resultsModel
.
success
({
...
commonStatBuildExcelResult2
})
...
...
v2.0/src/controller/common/task.controller.ts
View file @
cde4439e
...
...
@@ -15,8 +15,8 @@ export default class TaskController {
*/
@
commonDecorator
.
checkParams
([
'activityId'
])
@
commonDecorator
.
registeInfos
([
'vipInfo'
])
@
commonDecorator
.
preCheck
([
commonUtilCheck
.
checkActivityTime
)]
@
commonDecorator
.
preUpdate
([
commonUtilUpdate
.
updateVip
,
commonUtilUpdate
.
updateSignTask
,
commonUtilUpdate
.
updateOrderGoods
)]
@
commonDecorator
.
preCheck
([
commonUtilCheck
.
checkActivityTime
])
@
commonDecorator
.
preUpdate
([
commonUtilUpdate
.
updateVip
,
commonUtilUpdate
.
updateSignTask
,
commonUtilUpdate
.
updateOrderGoods
])
@
services
([
CommonTaskService
])
async
getTaskList
(
context
:
IContext
<
IParams
>
,
...
...
@@ -33,7 +33,7 @@ export default class TaskController {
*/
@
commonDecorator
.
checkParams
([
'activityId'
,
'taskType'
])
@
commonDecorator
.
registeInfos
([
'session'
])
@
commonDecorator
.
preCheck
([
commonUtilCheck
.
checkActivityTime
,
commonUtilCheck
.
checkTaskLimit
,
commonUtilCheck
.
checkExchangeCreditsTask
)]
@
commonDecorator
.
preCheck
([
commonUtilCheck
.
checkActivityTime
,
commonUtilCheck
.
checkTaskLimit
,
commonUtilCheck
.
checkExchangeCreditsTask
])
@
services
([
CommonTaskService
])
async
doCompleteTask
(
context
:
IContext
<
IParams
>
,
...
...
@@ -49,7 +49,7 @@ export default class TaskController {
* 领取任务奖励
*/
@
commonDecorator
.
checkParams
([
'activityId'
,
'taskType'
,
'rewardsKey'
])
@
commonDecorator
.
preCheck
([
commonUtilCheck
.
checkActivityTime
,
commonUtilCheck
.
checkRemainTimes
)]
@
commonDecorator
.
preCheck
([
commonUtilCheck
.
checkActivityTime
,
commonUtilCheck
.
checkRemainTimes
])
@
services
([
CommonTaskService
])
async
receiveTaskRewards
(
context
:
IContext
<
IParams
>
,
...
...
v2.0/src/controller/custom/test1.controller.ts
View file @
cde4439e
...
...
@@ -17,7 +17,6 @@ export default class Test1Controller {
*/
@
commonDecorator
.
checkParams
([
'activityId'
,
'type'
])
@
customDecorator
.
test1
([
'tt'
])
@
commonDecorator
.
noCatch
@
services
([
CommonStatService
,
CustomTestService
])
async
addStat
(
context
:
IContext
<
IParams
>
,
...
...
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