Sub-flow › Add Video
Background: Course Editor (SCR-CCM.02) β€” this dialog opens over the course editing page
Spec notes

Identity

SUC-CCM-04 Β· Screen: SCR-CCM.04 (Media Upload Dialog β€” parameterized: resource_type = video)

ReturnUrl context

Current returnUrl: /author-course/
Fallback: / when returnUrl is empty.
Propagation: all state-toggle links carry returnUrl. Save β†’ returnUrl. Cancel β†’ returnUrl + &sub_cancelled=1.

Sub-flow context

SUC-CCM-04 Β· Invoked by (Backoffice Portal): UC-CCM.01 (Author Course Content), step 6 "Add Content β†’ Video".
Precondition: the selected Content Item on the course editing page has no content linked yet.
Success: video saved and bound to the lesson; Course Editor updates its structure to display the new video.
Cancel after upload (AF 5A): the uploaded video file is deleted; the lesson item remains empty.
Selecting an existing video from the asset library (reuse) happens at SCR-CCM.26 "From library" tab, before this dialog opens β€” out of scope here.

Screen spec: SCR-CCM.04 (video)

  • Regions: Context header Β· Upload area Β· Resource metadata Β· Dialog actions
  • context_header: read-only Β· default: param.context_header Β· data_ref: passed from calling SUC
  • file_input: required Β· visible when upload_state == idle Β· accept: MP4, WebM (SS-CCM.02) Β· max size TBD (SS-CCM.02)
  • upload_progress: read-only Β· visible when upload_state == uploading Β· range 0–100
  • resource_title: required Β· min length 1 Β· default = param.original_filename Β· visible when upload_state == complete Β· data_ref: CourseDraftResource.title
  • resource_description: optional Β· visible when upload_state == complete Β· data_ref: CourseDraftResource.description
  • duration_estimate: optional Β· min 1 Β· visible when upload_state == complete && resource_type == video Β· default: param.auto_detect_duration Β· data_ref: CourseDraftResource.metadata.duration_seconds
  • Actions: save (enabled when upload_state == complete && resource_title != '') β†’ SUC-CCM-04-M-6; cancel (always enabled) β†’ SUC-CCM-04-A-5A
  • AR#1: parameterized by resource_type β€” video has no file preview, metadata = filename_original, file_size_bytes, mime_type, duration_seconds
  • AR#2: 2-stage format/size validation β€” client-side (AF 2A) + server-side re-check
  • AR#3: atomic save (SS-CCM.07) β€” binary write + CourseDraftResource insert + CourseDraftItem link commit/rollback together
  • AR#4: upload transfer failure β†’ error + Retry button; user can pick a new file or cancel
  • AR#5: WCAG-AA β€” file input label linkage, accessible progress bar, field-associated error messages, full keyboard navigation