|
|
@@ -19,7 +19,7 @@ fs = require "fs"
|
|
|
InactiveProjectManager = require("../InactiveData/InactiveProjectManager")
|
|
|
ProjectUpdateHandler = require("./ProjectUpdateHandler")
|
|
|
ProjectGetter = require("./ProjectGetter")
|
|
|
-OlProjectGetter = require("./OlProjectGetter")
|
|
|
+V1ProjectGetter = require("./V1ProjectGetter")
|
|
|
PrivilegeLevels = require("../Authorization/PrivilegeLevels")
|
|
|
AuthenticationController = require("../Authentication/AuthenticationController")
|
|
|
PackageVersions = require("../../infrastructure/PackageVersions")
|
|
|
@@ -153,7 +153,7 @@ module.exports = ProjectController =
|
|
|
projects: (cb)->
|
|
|
ProjectGetter.findAllUsersProjects user_id, 'name lastUpdated publicAccesLevel archived owner_ref tokens', cb
|
|
|
v1Projects: (cb) ->
|
|
|
- OlProjectGetter.findAllUsersProjects user_id, cb
|
|
|
+ V1ProjectGetter.findAllUsersProjects user_id, cb
|
|
|
hasSubscription: (cb)->
|
|
|
LimitationsManager.userHasSubscriptionOrIsGroupMember currentUser, cb
|
|
|
user: (cb) ->
|
|
|
@@ -398,7 +398,7 @@ module.exports = ProjectController =
|
|
|
showLinkSharingOnboarding: showLinkSharingOnboarding
|
|
|
timer.done()
|
|
|
|
|
|
- _buildProjectList: (allProjects, olProjects = [])->
|
|
|
+ _buildProjectList: (allProjects, v1Projects = [])->
|
|
|
{owned, readAndWrite, readOnly, tokenReadAndWrite, tokenReadOnly} = allProjects
|
|
|
projects = []
|
|
|
for project in owned
|
|
|
@@ -408,8 +408,8 @@ module.exports = ProjectController =
|
|
|
projects.push ProjectController._buildProjectViewModel(project, "readWrite", Sources.INVITE)
|
|
|
for project in readOnly
|
|
|
projects.push ProjectController._buildProjectViewModel(project, "readOnly", Sources.INVITE)
|
|
|
- for project in olProjects
|
|
|
- projects.push ProjectController._buildOlProjectViwModel(project)
|
|
|
+ for project in v1Projects
|
|
|
+ projects.push ProjectController._buildV1ProjectViewModel(project)
|
|
|
# Token-access
|
|
|
# Only add these projects if they're not already present, this gives us cascading access
|
|
|
# from 'owner' => 'token-read-only'
|
|
|
@@ -438,7 +438,7 @@ module.exports = ProjectController =
|
|
|
}
|
|
|
return model
|
|
|
|
|
|
- _buildOlProjectViewModel: (project) ->
|
|
|
+ _buildV1ProjectViewModel: (project) ->
|
|
|
{
|
|
|
id: project.id
|
|
|
name: project.title
|