Browse Source

[svn r19614] Minor - A chapter item shouldn't have audio because it hasn't a content - partial FS#3909

Cristian Fasanando 16 years ago
parent
commit
058946de31
1 changed files with 6 additions and 4 deletions
  1. 6 4
      main/newscorm/learnpath.class.php

+ 6 - 4
main/newscorm/learnpath.class.php

@@ -4434,10 +4434,12 @@ class learnpath {
 					}
 					else 
 					{
-						$return .= ' <input type="file" name="mp3file'.$arrLP[$i]['id'].'" id="mp3file" />';
-						if (!empty($arrLP[$i]['audio']))
-						{
-							$return .= '<input type="checkbox" name="removemp3'.$arrLP[$i]['id'].'" id="checkbox'.$arrLP[$i]['id'].'" />'.get_lang('RemoveAudio');
+						if ($arrLP[$i]['item_type']!='dokeos_chapter') {
+							$return .= ' <input type="file" name="mp3file'.$arrLP[$i]['id'].'" id="mp3file" />';
+							if (!empty($arrLP[$i]['audio']))
+							{
+								$return .= '<br /><input type="checkbox" name="removemp3'.$arrLP[$i]['id'].'" id="checkbox'.$arrLP[$i]['id'].'" />'.get_lang('RemoveAudio');
+							}
 						}
 					}
 					$return .= '</td>' . "\n";