FIX bug
This commit is contained in:
parent
62f38402f7
commit
83270ab272
|
@ -21,7 +21,7 @@ curl -X PUT http://localhost:3001/api/v1/homes/sync_count \
|
|||
|
||||
token(requires): String,权限验证
|
||||
|
||||
type(requires): String;同步的类型,取值范围: {user(用户) | project(开源项目) | practical_training_project(实训项目) | scholl(应用高校)}
|
||||
type(requires): String;同步的类型,取值范围: {user(用户) | project(开源项目) | practical_training_project(实训项目) | school(应用高校)}
|
||||
|
||||
number(optional): Integer;同步数量, 该参数可选,不传时,后台默认值为1
|
||||
|
||||
|
|
|
@ -6,7 +6,7 @@ class HomesService
|
|||
home.update_attributes!(users_count: home.users_count + sync_count)
|
||||
when "project"
|
||||
home.update_attributes!(projects_count: home.projects_count + sync_count)
|
||||
when 'scholl'
|
||||
when 'school'
|
||||
home.update_attributes!(scholls_count: home.scholls_count + sync_count)
|
||||
when "practical_training_project"
|
||||
home.update_attributes!(practical_training_projects_count: home.practical_training_projects_count + sync_count)
|
||||
|
|
Loading…
Reference in New Issue