Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fixed a problem with TIMESPAN pattern matching

  • Loading branch information...
commit 90e1b39acd6403f17999c565c03380de969c6419 1 parent bdeae2b
bobopinna authored
Showing with 2 additions and 2 deletions.
  1. +2 −2 mod/scorm/datamodels/scorm_13.js.php
View
4 mod/scorm/datamodels/scorm_13.js.php
@@ -28,7 +28,7 @@ function SCORMapi1_3() {
CMIString64000 = '^.{0,64000}$';
CMILang = '^([a-zA-Z]{2,3}|i|x)(\-[a-zA-Z0-9\-]{2,8})?$|^$';
CMITime = '^(19[7-9]{1}[0-9]{1}|20[0-2]{1}[0-9]{1}|203[0-8]{1})((-(0[1-9]{1}|1[0-2]{1}))((-(0[1-9]{1}|[1-2]{1}[0-9]{1}|3[0-1]{1}))(T([0-1]{1}[0-9]{1}|2[0-3]{1})((:[0-5]{1}[0-9]{1})((:[0-5]{1}[0-9]{1})((\\.[0-9]{1,2})((Z|([+|-]([0-1]{1}[0-9]{1}|2[0-3]{1})))(:[0-5]{1}[0-9]{1})?)?)?)?)?)?)?)?$';
- CMITimespan = '^P(\\d+Y)?(\\d+M)?(\\d+D)?(T(\\d+H)?(\\d+M)?(\\d+(\.\\d{1,2})?S)?)?$';
+ CMITimespan = '^P(\\d+Y)?(\\d+M)?(\\d+D)?(T(((\\d+H)(\\d+M)?(\\d+(\.\\d{1,2})?S)?)|((\\d+M)(\\d+(\.\\d{1,2})?S)?)|((\\d+(\.\\d{1,2})?S))))?$';
CMIInteger = '^\\d+$';
CMISInteger = '^-?([0-9]+)$';
CMIDecimal = '^-?([0-9]{1,4})(\\.[0-9]{1,18})?$';
@@ -45,7 +45,7 @@ function SCORMapi1_3() {
CMIResult = '^correct$|^incorrect$|^unanticipated$|^neutral$|^-?([0-9]{1,4})(\\.[0-9]{1,18})?$';
NAVEvent = '^previous$|^continue$|^exit$|^exitAll$|^abandon$|^abandonAll$|^suspendAll$|^{target=\\S{0,200}[a-zA-Z0-9]}choice$';
NAVBoolean = '^unknown$|^true$|^false$';
- NAVTarget = '^previous$|^continue$|^{target=\\S{0,200}[a-zA-Z0-9]}$'
+ NAVTarget = '^previous$|^continue$|^choice.{target=\\S{0,200}[a-zA-Z0-9]}$'
// Children lists
cmi_children = '_version, comments_from_learner, comments_from_lms, completion_status, credit, entry, exit, interactions, launch_data, learner_id, learner_name, learner_preference, location, max_time_allowed, mode, objectives, progress_measure, scaled_passing_score, score, session_time, success_status, suspend_data, time_limit_action, total_time';
comments_children = 'comment, timestamp, location';
Please sign in to comment.
Something went wrong with that request. Please try again.