Browse Source

SCORM module functions properly if SCORM player is not enabled.

pull/2/head
Alexander O'Neill 14 years ago
parent
commit
264bdd3e4a
  1. 14
      plugins/nmlt/scorm.inc

14
plugins/nmlt/scorm.inc

@ -99,7 +99,11 @@ class SCORMObject {
//$result = db_query("SELECT * FROM {content_node_field} nf INNER JOIN {content_node_field_instance} ni ON nf.field_name = ni.field_name WHERE nf.type='field_fedora_pid_reference'"); //$result = db_query("SELECT * FROM {content_node_field} nf INNER JOIN {content_node_field_instance} ni ON nf.field_name = ni.field_name WHERE nf.type='field_fedora_pid_reference'");
fedora_pidfield_redirect_to_node($this); fedora_pidfield_redirect_to_node($this);
module_load_include('module', 'SCORM', 'SCORM'); $tabset['my_tabset']['first_tab'] = array(
'#type' => 'tabpage',
'#title' => t('Description'),
);
if (module_load_include('module', 'SCORM', 'SCORM')) {
$dest_array = explode('/', urldecode(drupal_get_destination())); $dest_array = explode('/', urldecode(drupal_get_destination()));
$nid = $dest_array[count($dest_array) - 1]; $nid = $dest_array[count($dest_array) - 1];
$node = node_load($nid); $node = node_load($nid);
@ -109,16 +113,14 @@ class SCORMObject {
$tabset['my_tabset'] = array( $tabset['my_tabset'] = array(
'#type' => 'tabset', '#type' => 'tabset',
); );
$tabset['my_tabset']['first_tab'] = array(
'#type' => 'tabpage',
'#title' => t('Description'),
);
$tabset['my_tabset']['second_tab'] = array( $tabset['my_tabset']['second_tab'] = array(
'#type' => 'tabpage', '#type' => 'tabpage',
'#title' => t('Results'), '#title' => t('Results'),
'#content' => scorm_show_results($node), '#content' => scorm_show_results($node),
); );
}
module_load_include('inc', 'fedora_repository', 'ObjectHelper'); module_load_include('inc', 'fedora_repository', 'ObjectHelper');
$obj = new ObjectHelper(); $obj = new ObjectHelper();
$tabset['my_tabset']['first_tab']['tabset'] = array( $tabset['my_tabset']['first_tab']['tabset'] = array(

Loading…
Cancel
Save