Skip to main content

SureDrive Dashboards

SureDrive has two distinct dashboard views: the Application Dashboard (a list of all SureDrives the user can access) and the Project Dashboard (the home view for a single SureDrive). Both are Angular ui-router states defined in app-states.js.


Application Dashboard

The Application Dashboard is the entry point for the SureDrive product. It lists every archive the current user has access to and provides the controls to create a new one.

ItemValue
Route stateapp.network.drive.list
ControllerDrivesController
JS fileSC/suredms-web-client/src/main/webapp/app/js/network/study/drive.js
TemplateSC/suredms-web-client/src/main/webapp/app/views/network/study/drive-list.html
Feature flagFEATURE_SURE_DRIVE_APPLICATION_ENABLED

What the Application Dashboard Shows

  • A list of all SureDrive archives the user has read access to
  • Per-drive statistics: document count, organisation count, team size
  • Toggle between list view and image/tile view
  • Sort by name or creation date
  • Filter by name; option to show deleted drives
  • + button to open the New SureDrive Wizard

Data Loaded

The controller calls:

  • An archive-listing service that returns all SureDMS.CloudArchive documents accessible to the current user
  • ArchiveStatisticsService for per-drive document and team counts

Project Dashboard

The Project Dashboard is the home view for a single SureDrive. It is shown after the user selects a drive from the Application Dashboard.

ItemValue
Route stateapp.network.study.browse.dashboard-drive
ControllerDriveDashboardController
JS fileSC/suredms-web-client/src/main/webapp/app/js/network/study/drive/drive-dashboard.js
TemplateSC/suredms-web-client/src/main/webapp/app/views/network/study/drive/drive-dashboard.html

What the Project Dashboard Shows

  • Milestone Manager widget — summary of milestone phases and completion status
  • Document count — aggregate count for the archive
  • Activity stream — documents and user activity over the last week/month (loaded via StudyStreamService)
  • Workflow task progress — current user's open tasks and completion progress (loaded via WorkflowService.getCurrentUserTaskStatistics)
  • Health gadgets — visual indicators for project status (signing, discrepancy, compliance)
  • Top-level navigation links to: Documents, Acquire Queue, Quality Queue, Workflow, Reports, Team

Data Loaded

ServicePurpose
StudiesService.getStudy(studyId)Fetches basic project metadata
ArchiveStatisticsService.getStatistics(studyId)Aggregate document and organisation counts
UserArchiveStatisticsServiceUser-specific document statistics
WorkflowService.getCurrentUserTaskStatistics(studyId)Drives the task progress bars
StudyStreamService.getStudyStream(studyId)Chronological activity list

From the Project Dashboard, users navigate to all major SureDrive features via the top-level menu:

Menu ItemRoute AreaDocument
Documentsbrowse.documentsDocument Management
Acquire Queuebrowse.acquire-queueAcquire and Quality Queues
Quality Queuebrowse.quality-queueAcquire and Quality Queues
Workflowbrowse.workflowWorkflow Platform
Reportsbrowse.report-wizardReports
Teambrowse.teamTeam Management
Propertiesbrowse.propertiesSureDrive Properties
Audit Trailbrowse.audit-trailAudit Trail
Milestone Managerbrowse.milestonesMilestone Manager
Content Model Editorbrowse.content-model-editorContent Model Editor

StudyDashboardController — Service and Data Model

StudyDashboardController (SC/suredms-web-client/src/main/webapp/app/js/network/study/dashboard/study-dashboard.js) powers both the Application Dashboard and the Project Dashboard views.

Injected Services

ServiceRole
ArchiveStatisticsServiceLoads document count statistics per archive via getStatistics(studyId, success, error)
UserArchiveStatisticsServiceLoads per-user document and report statistics via getDocumentStatistics / getReportsStatistics
StudyStreamServiceProvides an activity stream for the drive via getStudyStream(studyId)
SystemSnapshotCacheServiceSupplies recent-activity user list via getActivity(true)
WorkflowServiceProvides workflow task counts via getCurrentUserTaskStatistics(studyId)
DashboardQuickShortcutsServiceLoads and persists quick-shortcut settings
DashboardGadgetsVisibilityServiceControls per-gadget visibility (which health gadgets the user has enabled)
FeatureServiceChecks feature flags inline (e.g. FEATURE_SHARE_VIEW)
ActionAvailabilityServiceChecks action flags (e.g. FEATURE_GLOBAL_UPLOAD, FEATURE_VIEW_WORKFLOW)

Document and Activity Streams

The controller loads two time-series streams from the cached study object:

PropertyStream keyMeaning
studyDashboard.documentsInLastWeekSTUDY_STREAM_DOCUMENTS_IN_LAST_MONTHArray of daily document count points (keyed by day)
studyDashboard.activityInLastWeekSTUDY_STREAM_ACTIVITY_IN_LAST_MONTHArray of daily user activity points

Both arrays are compared against the cached study streams on each reload (reloadStudyStreams). If the JSON representation has changed, the local array is replaced and the Flot chart re-renders. The isFlotDataLoadingInProgress flag gates the chart render, toggling off after a 500ms $timeout.

Statistics Refresh

refreshArchiveStatistics() calls ArchiveStatisticsService.getStatistics(studyId) for drive-level counts (total documents, forms, etc.). If the DASHBOARD_GADGET_MY_DOCUMENTS gadget is visible, UserArchiveStatisticsService.getDocumentStatistics and getReportsStatistics are also called to populate per-user counts.

Workflow Task Bar

reloadUserTasks() calls WorkflowService.getCurrentUserTaskStatistics(studyId). The result has .total and .completed fields. If total > 0, a progress percentage is computed as Math.round(100 * completed / total) and bound to studyDashboard.studyWorkflowTasksProgress. If total === 0, the bar shows 100.

Permission Flags Set on Activation

PropertyCondition
userCanGenerateAdminReportUserService.isAdmin()
userCanUploadDocumentFEATURE_GLOBAL_UPLOAD action available
userCanViewWorkflowFEATURE_VIEW_WORKFLOW action available
canModifyTeamAdmin OR (FEATURE_SHARE_VIEW or FEATURE_SHARE_VIEW_WITH_DELETION enabled) AND study is not unmodifiable