       $q.all([_loadProjects(a), _loadStatuses(a)])
         .then(_loadIssues(a))
         .then(_loadIssueCount(a))
-
 
   ###
    load projects from redmine.

    # update
    DataAdapter.removeProjects(saved)
    DataAdapter.addProjects(projects)


  ###
   load activities for account.

    promises = promises.map (p) -> p.then(_successLoadProject, _errorLoadProject)
    $q.all(promises).then(_updateProjects)

  ###
   show success message.
  ###
  _successLoadProject = (data) =>
    if not data.project and (not data.projects or data.projects.length is 0)
      _errorLoadProject data
      return null
    data.projects = data.projects or [data.project]
    Message.toast Resource.string("msgLoadProjectSuccess").format(data.account.name, data.projects.length), 3000
    return data.projects

  ###
   show error message.
