Merge branch 'aragonc-BT9886' into 1.10.x

1.10.x
Yannick Warnier 10 years ago
commit 28cabc8b3e
  1. 504
      app/Resources/public/css/base.css
  2. 164
      app/Resources/public/css/default_scorm.css
  3. 388
      app/Resources/public/css/scorm.css
  4. 543
      app/Resources/public/css/themes/chamilo/dataTable.css
  5. BIN
      app/Resources/public/css/themes/chamilo/images/2leftarrow.gif
  6. BIN
      app/Resources/public/css/themes/chamilo/images/2rightarrow.gif
  7. BIN
      app/Resources/public/css/themes/chamilo/images/bg-button.png
  8. BIN
      app/Resources/public/css/themes/chamilo/images/bg-main.png
  9. BIN
      app/Resources/public/css/themes/chamilo/images/blue_arrow.png
  10. BIN
      app/Resources/public/css/themes/chamilo/images/border-line.png
  11. BIN
      app/Resources/public/css/themes/chamilo/images/bullet.gif
  12. BIN
      app/Resources/public/css/themes/chamilo/images/button_accept.png
  13. BIN
      app/Resources/public/css/themes/chamilo/images/button_delete.gif
  14. BIN
      app/Resources/public/css/themes/chamilo/images/button_login.gif
  15. BIN
      app/Resources/public/css/themes/chamilo/images/button_minus.gif
  16. BIN
      app/Resources/public/css/themes/chamilo/images/button_minus.png
  17. BIN
      app/Resources/public/css/themes/chamilo/images/button_plus_blue.png
  18. BIN
      app/Resources/public/css/themes/chamilo/images/button_plus_green.png
  19. BIN
      app/Resources/public/css/themes/chamilo/images/button_refresh.gif
  20. BIN
      app/Resources/public/css/themes/chamilo/images/button_search.gif
  21. BIN
      app/Resources/public/css/themes/chamilo/images/button_upload.gif
  22. BIN
      app/Resources/public/css/themes/chamilo/images/chamilo-welcome.png
  23. BIN
      app/Resources/public/css/themes/chamilo/images/dataTable/Sorting icons.psd
  24. BIN
      app/Resources/public/css/themes/chamilo/images/dataTable/back_disabled.jpg
  25. BIN
      app/Resources/public/css/themes/chamilo/images/dataTable/back_enabled.jpg
  26. BIN
      app/Resources/public/css/themes/chamilo/images/dataTable/favicon.ico
  27. BIN
      app/Resources/public/css/themes/chamilo/images/dataTable/forward_disabled.jpg
  28. BIN
      app/Resources/public/css/themes/chamilo/images/dataTable/forward_enabled.jpg
  29. BIN
      app/Resources/public/css/themes/chamilo/images/dataTable/sort_asc.png
  30. BIN
      app/Resources/public/css/themes/chamilo/images/dataTable/sort_asc_disabled.png
  31. BIN
      app/Resources/public/css/themes/chamilo/images/dataTable/sort_both.png
  32. BIN
      app/Resources/public/css/themes/chamilo/images/dataTable/sort_desc.png
  33. BIN
      app/Resources/public/css/themes/chamilo/images/dataTable/sort_desc_disabled.png
  34. BIN
      app/Resources/public/css/themes/chamilo/images/help2.png
  35. BIN
      app/Resources/public/css/themes/chamilo/images/icon-chamilo.png
  36. BIN
      app/Resources/public/css/themes/chamilo/images/install.png
  37. BIN
      app/Resources/public/css/themes/chamilo/images/loading.gif
  38. BIN
      app/Resources/public/css/themes/chamilo/images/nav-border.png
  39. BIN
      app/Resources/public/css/themes/chamilo/images/next.png
  40. BIN
      app/Resources/public/css/themes/chamilo/images/portal.png
  41. BIN
      app/Resources/public/css/themes/chamilo/images/previus.png
  42. BIN
      app/Resources/public/css/themes/chamilo/images/refresh.png
  43. BIN
      app/Resources/public/css/themes/chamilo/images/scorm_completed.png
  44. BIN
      app/Resources/public/css/themes/chamilo/images/scorm_failed.png
  45. BIN
      app/Resources/public/css/themes/chamilo/images/scorm_highlight.png
  46. BIN
      app/Resources/public/css/themes/chamilo/images/scorm_not_attempted.png
  47. BIN
      app/Resources/public/css/themes/chamilo/images/sprite-icon-social.png
  48. BIN
      app/Resources/public/css/themes/chamilo/images/sprite-icon.png
  49. BIN
      app/Resources/public/css/themes/chamilo/images/start-level.png
  50. BIN
      app/Resources/public/css/themes/chamilo/images/user_icon.png
  51. BIN
      app/Resources/public/css/themes/chamilo/images/user_password.png
  52. BIN
      app/Resources/public/css/themes/chamilo/images/vineta.png
  53. BIN
      app/Resources/public/css/themes/chamilo/images/white_arrow.png
  54. 14
      app/Resources/public/css/themes/chamilo/learnpath.css
  55. 0
      app/Resources/public/css/themes/chamilo/scorm.css
  56. 82
      app/Resources/public/css/themes/chamilo/scormfs.css
  57. 6
      main/course_progress/thematic_advance.php
  58. 151
      main/inc/lib/api.lib.php
  59. 15
      main/inc/lib/template.lib.php
  60. 8
      main/inc/lib/thematic.lib.php
  61. 7
      main/install/data.sql
  62. 200
      main/newscorm/learnpath.class.php
  63. 5
      main/newscorm/lp_add.php
  64. 19
      main/newscorm/lp_controller.php
  65. 462
      main/newscorm/lp_list.php
  66. 297
      main/newscorm/lp_view.php
  67. 3
      main/newscorm/scorm_api.php
  68. 4
      main/template/default/layout/head.tpl
  69. 134
      main/template/default/learnpath/list.tpl
  70. 201
      main/template/default/learnpath/view.tpl
  71. 2
      src/Chamilo/CoreBundle/Component/Editor/CkEditor/CkEditor.php
  72. 55
      src/Chamilo/CoreBundle/Migrations/Schema/V110/Version20150527101600.php

@ -94,6 +94,11 @@ select {
.carousel-indicators{
bottom: 0px !important;
}
#updatemp3 .footer-audio{
padding-bottom: 10px;
padding-top: 10px;
margin-bottom: 20px;
}
ul#navigation {
position: fixed;
margin: 0px;
@ -151,122 +156,10 @@ ul#navigation .report a {
/* END CSS BASE */
.button-load{
background: url("../img/icons/64/file_upload.png") no-repeat center 20px;
background: url("../../main/img/icons/64/file_upload.png") no-repeat center 20px;
padding-top: 70px;
}
/* START COURSE PROGRESS */
.thematic-postit{
padding-top: 5px;
padding-bottom: px;
}
.thematic-postit .tittle-score{
padding-bottom: 5px;
font-size: 16px;
color: #006699;
}
.thematic-postit .topics{
font-size: 12px;
padding-bottom: 5px;
color: #006699;
}
.thematic-postit .items-progress {
border-top: 2px solid #C4DDEB;
padding: 5px;
margin-top: 0px;
background-color: #ECF4F8;
}
.thematic-postit .items-progress.current {
border-top: 2px solid #C4DDEB;
padding: 5px;
margin-top: 0px;
background-color: #C4DDEB;
}
.thematic-postit .items-progress .date{
color: #666;
font-size: 11px;
display: block;
}
.thematic-postit .items-progress .title{
font-size: 14px;
line-height: 18px;
display: block;
}
.thematic-postit .items-progress .time{
display: block;
padding-top: 5px;
}
.thematic-postit .info-progress{
padding: 10px;
}
.thematic-postit .score-thematic .score{
text-align: right;
}
.thematic-postit .score-thematic .name-student{
font-weight: bold;
font-size: 16px;
padding-left: 70px;
margin: 0px;
}
.thematic-postit .score-thematic{
color: #666;
}
.thematic-postit .score-thematic p{
padding: 0px;
margin: 0px;
}
.thematic-postit .row-fluid.score-thematic {
padding-top: 5px;
}
.thematic-postit .accordion-heading .accordion-toggle {
display: inline;
padding-bottom: 3px;
padding-left: 10px;
padding-right: 10px;
padding-top: 3px;
float: right;
margin-top: 10px;
margin-bottom: 10px;
margin-right: 15px;
}
.thematic-postit .accordion-heading .title-accordion{
padding:0px;
background:url(thematic.png) no-repeat left bottom transparent;
}
.thematic-postit .name-student h2{
font-size: 18px;
margin: 0;
}
.thematic-postit .accordion-heading h3, .accordion-heading h2{
line-height: 17px;
}
.thematic-postit .accordion-group{
border: 1px solid #D4E6F0;
}
.thematic-postit .name-student h3{
font-size: 13px;
font-weight: normal;
margin: 0;
}
.thematic-postit .accordion-heading {
background-color: #E7F1F7;
}
.thematic-postit .items-progress p{
margin-bottom: 3px;
}
.thematic-postit .accordion-body.collapse {
height: 0;
display: none;
}
.thematic-postit .accordion-body.collapse.in {
height: auto;
display: block;
}
/* END COURSE PROGRESS*/
/* IMPRESS JS */
.impress-content{
@ -3316,7 +3209,7 @@ form .formw .freeze {
padding-bottom: 1em;
}
.skill-options .skill-winner li a{
background: url("../img/icons/16/winner.png") no-repeat;
background: url("../../main/img/icons/16/winner.png") no-repeat;
padding-left: 1.5em;
padding-bottom: 1em;
}
@ -3462,119 +3355,7 @@ form .formw .freeze {
/* ****************************************************
END SKILL
**************************************************** */
/*SCORM CSS BASE */
#learning_path_left_zone .home{
display: inline-block;
width: 94%;
margin-bottom: .5em;
margin-top: .5em;
font-size: 12px;
}
#lp_navigation_elem .buttons {
margin-bottom: .5em;
text-align: center;
}
#learning_path_left_zone .scorm_title{
font-size: 20px;
color: #666;
margin-bottom: .5em;
margin-top: .5em;
}
/* for section */
.scorm_item_section.scorm_completed{
background:url("../img/icon_completed_section.png")no-repeat 98% center #606c88;
padding-right: 1.5em;
}
.scorm_item_section{
background: #2b3d53; /* Old browsers */
background: -moz-linear-gradient(top, #2b3d53 0%, #2c3d4d 100%); /* FF3.6+ */
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#2b3d53), color-stop(100%,#2c3d4d)); /* Chrome,Safari4+ */
background: -webkit-linear-gradient(top, #2b3d53 0%,#2c3d4d 100%); /* Chrome10+,Safari5.1+ */
background: -o-linear-gradient(top, #2b3d53 0%,#2c3d4d 100%); /* Opera 11.10+ */
background: -ms-linear-gradient(top, #2b3d53 0%,#2c3d4d 100%); /* IE10+ */
background: linear-gradient(to bottom, #2b3d53 0%,#2c3d4d 100%); /* W3C */
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#2b3d53', endColorstr='#2c3d4d',GradientType=0 ); /* IE6-9 */
padding-top: 10px;
padding-bottom: 10px;
font-size: 14px;
color: #ffffff;
/* border-top-left-radius:5px;
border-top-right-radius: 5px;*/
}
.scorm_item_section .scorm_section_level_0{
padding-left: .5em;
padding-right: .5em;
}
.scorm_item_section .scorm_section_level_1{
padding-left: 1.5em;
padding-right: .5em;
}
.scorm_item_section .scorm_section_level_2{
padding-left: 2.5em;
padding-right: .5em;
}
.scorm_item_section .scorm_section_level_3{
padding-left: 3.5em;
padding-right: .5em;
}
/* items scorm*/
.scorm_item_normal.scorm_completed {
background:url("../img/icon_completed.png") no-repeat 98% center;
}
.scorm_item_normal.scorm_failed{
background:url("../img/icon_failed.png") no-repeat 98% center;
}
.scorm_item_normal .scorm_item_level_0{
padding-left: .5em;
padding-right: 1.5em;
padding-top: 10px;
padding-bottom: 10px;
}
.scorm_item_normal{
padding:0;
border-bottom: 1px solid #DCDCDC;
border-left: 1px solid #DCDCDC;
border-right: 1px solid #DCDCDC;
}
.scorm_item_normal a{
color: #666666;
text-decoration: none;
}.scorm_item_normal a:hover{
text-decoration: none;
}
.scorm_highlight{
background-color: #6AAEFF !important;
}
.scorm_highlight a{
color: #ffffff !important;
}
#scorm-info .panel-heading{
padding: 5px;
}
/* .scorm_item_normal .scorm_item_level_1{
padding-left: 1.8em;
padding-right: 1.5em;
background:url("../img/level_one.png") no-repeat 0 top;
padding-top: 10px;
padding-bottom: 10px;
}
.scorm_item_normal .scorm_item_level_2{
padding-left: 2.5em;
padding-right: 1.5em;
background:url("../img/level_two.png") no-repeat 0 top;
padding-top: 10px;
padding-bottom: 10px;
}
.scorm_item_normal .scorm_item_level_3{
padding-left: 3.5em;
padding-right: 1.5em;
background:url("../img/level_tree.png") no-repeat 0 top;
padding-top: 10px;
padding-bottom: 10px;
}*/
/* END SCORM CSS BASE*/
.skill_root {
box-shadow: 2px 2px 19px #aaa;
-o-box-shadow: 2px 2px 19px #aaa;
@ -3835,7 +3616,7 @@ div#no-data-view div.controls {
height: 25px;
position: relative;
overflow:hidden;
background: url(../img/alt_star.png) top left repeat-x;
background: url(../../main/img/alt_star.png) top left repeat-x;
}
.star-rating li{
padding:0px;
@ -3857,7 +3638,7 @@ div#no-data-view div.controls {
overflow:hidden;
}
.star-rating li a:hover{
background: url(../img/alt_star.png) left bottom;
background: url(../../main/img/alt_star.png) left bottom;
z-index: 2;
left: 0px;
border:none;
@ -3893,7 +3674,7 @@ div#no-data-view div.controls {
width: 125px;
}
.star-rating li.current-rating{
background: url(../img/alt_star.png) left center;
background: url(../../main/img/alt_star.png) left center;
position: absolute;
height: 25px;
display: block;
@ -3925,7 +3706,7 @@ a:active{
height: 20px;
width: 20px;
position:absolute;
background: url("../img/offline.png") no-repeat scroll right center transparent;
background: url("../../main/img/offline.png") no-repeat scroll right center transparent;
}
.online_user {
@ -3933,32 +3714,32 @@ a:active{
height: 20px;
width: 20px;
position:absolute;
background: url("../img/online.png") no-repeat scroll right center transparent;
background: url("../../main/img/online.png") no-repeat scroll right center transparent;
}
.online_user_in_text {
background: url("../img/online.png") no-repeat scroll right center transparent;
background: url("../../main/img/online.png") no-repeat scroll right center transparent;
height: 16px;
width: 17px;
display: inline-block;
margin-right: 4px;
}
.send_msg_in_text {
background: url("../img/mail_send.png") no-repeat scroll right center transparent;
background: url("../../main/img/mail_send.png") no-repeat scroll right center transparent;
height: 16px;
width: 17px;
display: inline-block;
margin-right: 4px;
}
.send_inv_in_text {
background: url("../img/invitation.png") no-repeat scroll right center transparent;
background: url("../../main/img/invitation.png") no-repeat scroll right center transparent;
height: 16px;
width: 17px;
display: inline-block;
margin-right: 4px;
}
.teacher_online {
background: url("../img/icons/16/teacher.png") no-repeat scroll right center transparent;
background: url("../../main/img/icons/16/teacher.png") no-repeat scroll right center transparent;
height: 16px;
width: 17px;
display: inline-block;
@ -3966,7 +3747,7 @@ a:active{
}
.student_online {
background: url("../img/icons/16/user.png") no-repeat scroll right center transparent;
background: url("../../main/img/icons/16/user.png") no-repeat scroll right center transparent;
height: 16px;
width: 17px;
display: inline-block;
@ -3978,7 +3759,7 @@ a:active{
}
.offline_user_in_text {
background: url("../img/offline.png") no-repeat scroll right center transparent;
background: url("../../main/img/offline.png") no-repeat scroll right center transparent;
height: 16px;
width: 17px;
display: inline-block;
@ -4074,14 +3855,14 @@ a:active{
}
#my_timeline #next {
background: url("../img/action_next.png") no-repeat transparent;
background: url("../../main/img/action_next.png") no-repeat transparent;
height: 32px;
width: 32px;
float:right;
}
#my_timeline #prev {
background: url("../img/action_prev.png") no-repeat transparent;
background: url("../../main/img/action_prev.png") no-repeat transparent;
height: 32px;
width: 32px;
float:left;
@ -4346,13 +4127,13 @@ a.forum_group_link {
cursor:pointer;
background-color:#eee;
margin-left: 4px !important;
background-image: url("../img/hide0.png");
background-image: url("../../main/img/hide0.png");
background-repeat: no-repeat;
background-position: center center;
}
.hide_bar_template_not_hide {
background-image: url("../img/hide2.png") !important;
background-image: url("../../main/img/hide2.png") !important;
}
#hide_bar_template:hover {
@ -4485,7 +4266,7 @@ a.forum_group_link {
}
.handle{
background-image: url('../img/div_show.gif');
background-image: url('../../main/img/div_show.gif');
background-repeat: no-repeat;
background-position:left center;
padding-left: 25px;
@ -4493,7 +4274,7 @@ a.forum_group_link {
}
.handle.collapsed{
background-image: url('../img/div_show.gif');
background-image: url('../../main/img/div_show.gif');
background-repeat: no-repeat;
background-position:left center;
padding-left: 25px;
@ -4501,7 +4282,7 @@ a.forum_group_link {
}
.handle.expanded{
background-image: url('../img/div_hide.gif');
background-image: url('../../main/img/div_hide.gif');
background-repeat: no-repeat;
background-position:left center;
padding-left: 25px;
@ -4509,7 +4290,7 @@ a.forum_group_link {
}
.collapsible .handle{
background-image: url('../img/div_hide.gif');
background-image: url('../../main/img/div_hide.gif');
background-repeat: no-repeat;
background-position:left center;
padding-left: 25px;
@ -4517,7 +4298,7 @@ a.forum_group_link {
}
.collapsible .handle.collapsed{
background-image: url('../img/div_show.gif');
background-image: url('../../main/img/div_show.gif');
background-repeat: no-repeat;
background-position:left center;
padding-left: 25px;
@ -4525,7 +4306,7 @@ a.forum_group_link {
}
.collapsible.expanded .handle{
background-image: url('../img/div_hide.gif');
background-image: url('../../main/img/div_hide.gif');
background-repeat: no-repeat;
background-position:left center;
padding-left: 25px;
@ -4541,7 +4322,7 @@ a.forum_group_link {
margin:0;
padding:0;
display:inline-block;
background-image: url('../img/icons/22/invisible.png');
background-image: url('../../main/img/icons/22/invisible.png');
background-repeat: no-repeat;
background-position:center center;
box-shadow:none;
@ -4556,7 +4337,7 @@ a.forum_group_link {
width:22px;
height:22px;
display:inline-block;
background-image: url('../img/icons/22/visible.png');
background-image: url('../../main/img/icons/22/visible.png');
background-repeat: no-repeat;
background-position:center center;
box-shadow:none;
@ -4571,7 +4352,7 @@ a.forum_group_link {
margin:0;
padding:0;
display:inline-block;
background-image: url('../img/loading1.gif') !important;
background-image: url('../../main/img/loading1.gif') !important;
background-repeat: no-repeat;
background-position:center center;
box-shadow:none;
@ -4608,7 +4389,7 @@ a.forum_group_link {
margin:0;
padding:0;
display:inline-block;
background-image: url('../img/attachment.gif');
background-image: url('../../main/img/attachment.gif');
background-repeat: no-repeat;
background-position:center center;
box-shadow:none;
@ -4724,11 +4505,11 @@ li.annoucement{
}
.link.invalid .status{
background-image: url('../img/icons/22/error.png');
background-image: url('../../main/img/icons/22/error.png');
}
.link.valid .status{
background-image: url('../img/icons/22/accept.png');
background-image: url('../../main/img/icons/22/accept.png');
}
.btn.validate_link{
@ -4740,7 +4521,7 @@ li.annoucement{
margin:0;
padding:0;
display:inline-block;
background-image: url('../img/icons/22/preview_view.png');
background-image: url('../../main/img/icons/22/preview_view.png');
background-repeat: no-repeat;
background-position:center center;
box-shadow:none;
@ -4751,7 +4532,7 @@ li.annoucement{
*/
i.size-32.icon-new-glossary-term{
background-image: url('../img/icons/32/new_glossary_term.png');
background-image: url('../../main/img/icons/32/new_glossary_term.png');
}
/*
@ -4759,7 +4540,7 @@ i.size-32.icon-new-glossary-term{
*/
i.size-32.icon-new-note{
background-image: url('../img/icons/32/new_note.png');
background-image: url('../../main/img/icons/32/new_note.png');
}
.notebook.entries li{
@ -4852,13 +4633,13 @@ i.size-32.icon-new-note{
.dataTables_wrapper .paginate_disabled_previous, .dataTables_wrapper .paginate_enabled_previous {
padding-left: 23px;
background: url("../img/action_prev.png") no-repeat scroll left top;
background: url("../../main/img/action_prev.png") no-repeat scroll left top;
}
.dataTables_wrapper .paginate_disabled_next, .dataTables_wrapper .paginate_enabled_next {
margin-left: 10px;
padding-right: 23px;
background: url("../img/action_next.png") no-repeat scroll left top;
background: url("../../main/img/action_next.png") no-repeat scroll left top;
}
.dataTables_wrapper .paginate_disabled_previous, .dataTables_wrapper .paginate_disabled_next{
@ -4866,14 +4647,14 @@ i.size-32.icon-new-note{
}
.dataTables_wrapper .sorting_asc {
background-image: url("../img/sort_asc.png");
background-image: url("../../main/img/sort_asc.png");
background-repeat: no-repeat;
background-attachment: scroll;
background-position: right center;
}
.dataTables_wrapper .sorting_desc{
background-image: url("../img/sort_desc.png");
background-image: url("../../main/img/sort_desc.png");
background-repeat: no-repeat;
background-attachment: scroll;
background-position: right center;
@ -4893,21 +4674,21 @@ i.size-32.icon-new-note{
padding: 10px 0px 10px 40px;
background-repeat:no-repeat;
}
select#question_type_hidden option[value="1"] {background-image: url(../img/icons/32/mcua.png);}
select#question_type_hidden option[value="2"] {background-image: url(../img/icons/32/mcma.png);}
select#question_type_hidden option[value="3"] {background-image: url(../img/icons/32/fill_in_blanks.png);}
select#question_type_hidden option[value="4"] {background-image: url(../img/icons/32/matching.png);}
select#question_type_hidden option[value="5"] {background-image: url(../img/icons/32/open_answer.png);}
select#question_type_hidden option[value="6"] {background-image: url(../img/icons/32/hotspot.png);}
select#question_type_hidden option[value="7"] {background-image: url(../img/icons/32/mcma.png);}
select#question_type_hidden option[value="8"] {background-image: url(../img/icons/32/mcma.png);}
select#question_type_hidden option[value="9"] {background-image: url(../img/icons/32/mcmac.png);}
select#question_type_hidden option[value="10"] {background-image: url(../img/icons/32/mcuao.png);}
select#question_type_hidden option[value="11"] {background-image: url(../img/icons/32/mcmao.png);}
select#question_type_hidden option[value="12"] {background-image: url(../img/icons/32/mcmaco.png);}
select#question_type_hidden option[value="13"] {background-image: url(../img/icons/32/audio_question.png);}
select#question_type_hidden option[value="14"] {background-image: url(../img/icons/32/mcmagl.png);}
select#question_type_hidden option[value="16"] {background-image: url(../img/icons/32/calculated_answer.png);}
select#question_type_hidden option[value="1"] {background-image: url(../../main/img/icons/32/mcua.png);}
select#question_type_hidden option[value="2"] {background-image: url(../../main/img/icons/32/mcma.png);}
select#question_type_hidden option[value="3"] {background-image: url(../../main/img/icons/32/fill_in_blanks.png);}
select#question_type_hidden option[value="4"] {background-image: url(../../main/img/icons/32/matching.png);}
select#question_type_hidden option[value="5"] {background-image: url(../../main/img/icons/32/open_answer.png);}
select#question_type_hidden option[value="6"] {background-image: url(../../main/img/icons/32/hotspot.png);}
select#question_type_hidden option[value="7"] {background-image: url(../../main/img/icons/32/mcma.png);}
select#question_type_hidden option[value="8"] {background-image: url(../../main/img/icons/32/mcma.png);}
select#question_type_hidden option[value="9"] {background-image: url(../../main/img/icons/32/mcmac.png);}
select#question_type_hidden option[value="10"] {background-image: url(../../main/img/icons/32/mcuao.png);}
select#question_type_hidden option[value="11"] {background-image: url(../../main/img/icons/32/mcmao.png);}
select#question_type_hidden option[value="12"] {background-image: url(../../main/img/icons/32/mcmaco.png);}
select#question_type_hidden option[value="13"] {background-image: url(../../main/img/icons/32/audio_question.png);}
select#question_type_hidden option[value="14"] {background-image: url(../../main/img/icons/32/mcmagl.png);}
select#question_type_hidden option[value="16"] {background-image: url(../../main/img/icons/32/calculated_answer.png);}
}
@ -4919,7 +4700,7 @@ i.size-32.icon-new-note{
* work
*/
i.size-32.icon-new-work{
background-image: url('../img/icons/32/new_work.png');
background-image: url('../../main/img/icons/32/new_work.png');
}
/* Default skill partition colors */
@ -5512,70 +5293,7 @@ i.size-32.icon-new-work{
vertical-align: bottom;
margin-right: 5px;
}
/* LP SCORM */
/* Default LP left column values */
#learning_path_left_zone {
float:left;
width:315px;
height:100%;
padding-left: 8px;
padding-right: 4px;
}
#learning_path_left_zone #header {
font-size:14px;
}
#author_image {
border: 1px solid #CCCCCC;
float: left;
margin: 0;
padding: 8px;
position: relative;
width: 100%;
}
#author_name {
float: left;
text-align:center;
width: 100%;
font-size: 11px;
color: #888;
margin-top: 2px;
}
#lp_media_file {
float: left;
text-align:center;
width: 94%;
}
#learning_path_toc {
font-size:9pt;
margin:0;
}
#learning_path_left_zone .image-avatar{
text-align: center;
padding: 10px;
border:1px solid #dddddd;
border-radius: 4px;
-webkit-border-radius: 4px;
-moz-border-radius: 4px;
margin-bottom: 10px;
margin-top: 5px;
}
#learning_path_left_zone .navegation-bar .buttons{
text-align: center;
padding-top: 5px;
padding-bottom: 5px;
margin-bottom: 5px;
}
#learning_path_left_zone .description-autor{
color: #666666;
font-size: 12px;
}
.ui-state-highlight_lp {
border: 1px solid #FEAA18;
background: #FFB738;
@ -5671,110 +5389,7 @@ ul.holder li.bit-box{
#file-descrtiption.form-control{
width: 80%;
}
#learning_path_breadcrumb_zone .breadcrumb{
background: #2b3d53; /* Old browsers */
background: -moz-linear-gradient(top, #2b3d53 0%, #2c3d4d 100%); /* FF3.6+ */
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#2b3d53), color-stop(100%,#2c3d4d)); /* Chrome,Safari4+ */
background: -webkit-linear-gradient(top, #2b3d53 0%,#2c3d4d 100%); /* Chrome10+,Safari5.1+ */
background: -o-linear-gradient(top, #2b3d53 0%,#2c3d4d 100%); /* Opera 11.10+ */
background: -ms-linear-gradient(top, #2b3d53 0%,#2c3d4d 100%); /* IE10+ */
background: linear-gradient(to bottom, #2b3d53 0%,#2c3d4d 100%); /* W3C */
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#2b3d53', endColorstr='#2c3d4d',GradientType=0 ); /* IE6-9 */
border-radius: 0;
-moz-border-radius: 0;
-webkit-border-radius: 0;
color: #ffffff;
}
#learning_path_breadcrumb_zone .breadcrumb a{
color: #ffffff;
text-decoration: none;
}
#learning_path_breadcrumb_zone .breadcrumb a:hover{
color: #dddddd;
}
#view_as_link{
margin-top: 5px;
margin-right: 10px;
}
#learning_path_left_zone #accordion .panel-heading{
text-align: center;
}
#learning_path_left_zone #ui-option{
width: 100%;
display: block;
text-align: center;
cursor: pointer;
}
#learning_path_left_zone #ui-option #icon-up,
#learning_path_left_zone #ui-option #icon-down{
width: 100%;
display: block;
}
.hidden{
visibility: hidden;
display: none;
}
.sidebar-scorm,
.content-scorm{
position: relative;
min-height: 1px;
padding-left: 15px;
padding-right: 15px;
}
.sidebar-scorm,
.content-scorm{
float: left;
}
.total{
width: 100%;
}
.panel-default .panel-heading .btn{
top: -25px;
}
.panel-default .panel-heading .dropdown-menu{
top: 30%;
}
#touch-button{
text-decoration: none;
position: fixed;
top: 40px;
left: -5px;
overflow: hidden;
width: 51px;
height: 51px;
border: none;
text-indent: 100%;
opacity: 50;
z-index: 2;
}
.search-skill ul.holder_simple{
padding: 0;
}
.hidden-touch{
background: url("../img/icons/48/hidden-touch-left.png")center center no-repeat;
}
.show-touch{
background: url("../img/icons/48/show-touch-right.png")center center no-repeat;
}
.inner_lp_toc{
overflow-y:scroll;
}
.scorm-heading{
font-size: 16px;
font-weight: bold;
padding: 10px;
}
#control-bottom{
position: fixed;
bottom: 0;
width: 100%;
text-align: center;
left: 0;
}
#control-bottom.well{
margin-bottom: 0;
}
.session-course-edit .control{
padding-top: 2em;
padding-bottom: 2em;
@ -6211,7 +5826,9 @@ div#chat-remote-video video {
.content-scorm{
width: 83.33333333%;
}
#learning_path_right_zone{
width: 68%;
}
}
@media (min-width: 1024px) {
.sidebar-scorm{
@ -6364,4 +5981,3 @@ div#chat-remote-video video {
font-size: 20px;
}
}

@ -1,164 +0,0 @@
/*
File used to display Learning Path item in student view
If scorm.css file exists in theme folder, scorm.css file is used instead of this one
See https://support.chamilo.org/issues/6976
*/
.inner_lp_toc {
overflow: auto;
background-color: white;
height: 210px;
}
.inner_lp_toc .scorm_item a {
font-weight: bold;
font-size: 14px;
margin-right: 1px;
padding-bottom: 2px;
text-decoration: none;
color: #2F3E46;
}
.inner_lp_toc .scorm_item a.chapter_module {
font-weight: normal;
margin-right: 10px;
}
.inner_lp_toc .scorm_item_highlight {
border: 1px solid #999;
background:#999;
font-weight:bold;
text-shadow:0 -1px 1px #666;
background-image:-webkit-gradient(linear,left top,left bottom,from(#666),to(#999));
background-image:-webkit-linear-gradient(top,#666,#999);
background-image:-moz-linear-gradient(top,#666,#999);
background-image:-ms-linear-gradient(top,#666,#999);
background-image:-o-linear-gradient(top,#666,#999);
background-image:linear-gradient(top,#666,#999);
margin-right: 0px;
padding: 10px 0px 10px 0px;
text-decoration: none;
}
.inner_lp_toc .scorm_item_highlight a {
color:#fff;
margin-right: 1px;
text-decoration: none;
font-weight: bold;
}
.inner_lp_toc .scorm_item_section {
border:1px solid #222;
background:#333;
font-weight:bold;
color:#fff;
text-shadow:0 -1px 1px #000;
background-image:-webkit-gradient(linear,left top,left bottom,from(#555),to(#333));
background-image:-webkit-linear-gradient(top,#555,#333);
background-image:-moz-linear-gradient(top,#555,#333);
background-image:-ms-linear-gradient(top,#555,#333);
background-image:-o-linear-gradient(top,#555,#333);
background-image:linear-gradient(top,#555,#333);
margin-right: 1px;
padding: 10px 0px 10px 0px;
text-decoration: none;
}
.inner_lp_toc .scorm_item {
font-size: 16px;
margin-left: 10px;
margin-right:10px;
text-decoration: none;
border-color: rgba(255, 255, 255, 0.3);
}
.inner_lp_toc .scorm_item_1 {
border-bottom: 1px solid #CCCCCC;
background:#eee;
font-weight:bold;
color:#444;
text-shadow:0 1px 1px #f6f6f6;
background-image:-webkit-gradient(linear,left top,left bottom,from(#fdfdfd),to(#eee));
background-image:-webkit-linear-gradient(top,#fdfdfd,#eee);
background-image:-moz-linear-gradient(top,#fdfdfd,#eee);
background-image:-ms-linear-gradient(top,#fdfdfd,#eee);
background-image:-o-linear-gradient(top,#fdfdfd,#eee);
background-image:linear-gradient(top,#fdfdfd,#eee);
margin-right: 1px;
padding: 10px 0px 10px 0px;
text-decoration: none;
font-weight: normal;
background:#FDFDFD;
}
.inner_lp_toc .scorm_item_2 {
background-image:-webkit-gradient(linear,left top,left bottom,from(#fdfdfd),to(#eee));
background-image:-webkit-linear-gradient(top,#fdfdfd,#eee);
background-image:-moz-linear-gradient(top,#fdfdfd,#eee);
background-image:-ms-linear-gradient(top,#fdfdfd,#eee);
background-image:-o-linear-gradient(top,#fdfdfd,#eee);
background-image:linear-gradient(top,#fdfdfd,#eee);
border-bottom: 1px solid #CCCCCC;
color: #444444;
font-weight: bold;
text-shadow: 0 1px 1px #F6F6F6;
margin-right: 1px;
padding: 10px 0px 10px 0px;
text-decoration: none;
font-weight: normal;
}
.inner_lp_toc .scorm_item_section .scorm_item:before {
content : url('../../img/lp_section.png'); /* path from main/newscorm/lp_controller.php file */
vertical-align: text-top;
margin-right : 5px;
}
/* learning path's classes for section and item for 5 levels of depth */
.scorm_section_level_0 {
padding : 0 0 0 0;
}
.scorm_section_level_1 {
padding : 0 0.5em 0 2em;
}
.scorm_section_level_2 {
padding : 0 0.5em 0 4em;
}
.scorm_section_level_3 {
padding : 0 0.5em 0 6em;
}
.scorm_section_level_4 {
padding : 0 0.5em 0 8em;
}
.scorm_section_level_5 {
padding : 0 0.5em 0 10em;
}
.scorm_item_level_0 {
padding : 0 0 0 0;
}
.scorm_item_level_1 {
padding : 0 0.5em 0 1.5em;
}
.scorm_item_level_2 {
padding : 0 0.5em 0 3em;
}
.scorm_item_level_3 {
padding : 0 0.5em 0 4.5em;
}
.scorm_item_level_4 {
padding : 0 0.5em 0 6em;
}
.scorm_item_level_5 {
padding : 0 0.5em 0 7.5em;
}

@ -0,0 +1,388 @@
/*
File used to display Learning Path item in student view
If scorm.css file exists in theme folder, scorm.css file is used instead of this one
See https://support.chamilo.org/issues/6976
*/
/* LP SCORM */
/* Default LP left column values */
#learning_path_left_zone {
float:left;
height:100%;
padding-left: 8px;
padding-right: 4px;
}
#learning_path_left_zone #header {
font-size:14px;
}
#scorm-info.panel-default{
margin: 0px;
}
#author_image {
border: 1px solid #CCCCCC;
float: left;
margin: 0;
padding: 8px;
position: relative;
width: 100%;
}
#author_name {
float: left;
text-align:center;
width: 100%;
font-size: 11px;
color: #888;
margin-top: 2px;
}
#lp_media_file {
float: left;
text-align:center;
width: 94%;
}
#learning_path_toc {
font-size:9pt;
margin:0;
}
#learning_path_left_zone .image-avatar{
text-align: center;
padding: 10px;
border:1px solid #dddddd;
border-radius: 4px;
-webkit-border-radius: 4px;
-moz-border-radius: 4px;
margin-bottom: 10px;
margin-top: 5px;
}
#learning_path_left_zone .navegation-bar .buttons{
text-align: center;
padding-top: 5px;
padding-bottom: 5px;
margin-bottom: 5px;
}
#learning_path_left_zone .description-autor{
color: #666666;
font-size: 12px;
}
.inner_lp_toc {
overflow: auto;
border-top: 1px solid #dcdcdc;
}
.inner_lp_toc .scorm_item a {
font-weight: bold;
font-size: 14px;
margin-right: 1px;
padding-bottom: 2px;
text-decoration: none;
color: #2F3E46;
}
.inner_lp_toc .scorm_item a.chapter_module {
font-weight: normal;
margin-right: 10px;
}
.inner_lp_toc .scorm_item_highlight {
border: 1px solid #999;
background:#999;
font-weight:bold;
text-shadow:0 -1px 1px #666;
background-image:-webkit-gradient(linear,left top,left bottom,from(#666),to(#999));
background-image:-webkit-linear-gradient(top,#666,#999);
background-image:-moz-linear-gradient(top,#666,#999);
background-image:-ms-linear-gradient(top,#666,#999);
background-image:-o-linear-gradient(top,#666,#999);
background-image:linear-gradient(top,#666,#999);
margin-right: 0px;
padding: 10px 0px 10px 0px;
text-decoration: none;
}
.inner_lp_toc .scorm_item_highlight a {
color:#fff;
margin-right: 1px;
text-decoration: none;
font-weight: bold;
}
.inner_lp_toc .scorm_item_section {
border:1px solid #222;
background:#333;
font-weight:bold;
color:#fff;
text-shadow:0 -1px 1px #000;
background-image:-webkit-gradient(linear,left top,left bottom,from(#555),to(#333));
background-image:-webkit-linear-gradient(top,#555,#333);
background-image:-moz-linear-gradient(top,#555,#333);
background-image:-ms-linear-gradient(top,#555,#333);
background-image:-o-linear-gradient(top,#555,#333);
background-image:linear-gradient(top,#555,#333);
margin-right: 1px;
padding: 10px 0px 10px 0px;
text-decoration: none;
}
.inner_lp_toc .scorm_item {
font-size: 16px;
margin-left: 10px;
margin-right:10px;
text-decoration: none;
border-color: rgba(255, 255, 255, 0.3);
}
.inner_lp_toc .scorm_item_section .scorm_item:before {
content : url('../../img/lp_section.png'); /* path from main/newscorm/lp_controller.php file */
vertical-align: text-top;
margin-right : 5px;
}
/* learning path's classes for section and item for 5 levels of depth */
.scorm_section_level_0 {
padding : 0 0 0 0;
}
.scorm_section_level_1 {
padding : 0 0.5em 0 2em;
}
.scorm_section_level_2 {
padding : 0 0.5em 0 4em;
}
.scorm_section_level_3 {
padding : 0 0.5em 0 6em;
}
.scorm_section_level_4 {
padding : 0 0.5em 0 8em;
}
.scorm_section_level_5 {
padding : 0 0.5em 0 10em;
}
.scorm_item_level_0 {
padding : 0 0 0 0;
}
.scorm_item_level_1 {
padding : 0 0.5em 0 1.5em;
}
.scorm_item_level_2 {
padding : 0 0.5em 0 3em;
}
.scorm_item_level_3 {
padding : 0 0.5em 0 4.5em;
}
.scorm_item_level_4 {
padding : 0 0.5em 0 6em;
}
.scorm_item_level_5 {
padding : 0 0.5em 0 7.5em;
}
#learning_path_right_zone{
border-left: 1px solid #CCCCCC;
padding-left: 10px;
box-sizing: border-box;
}
#learning_path_breadcrumb_zone .breadcrumb{
background: #2b3d53; /* Old browsers */
background: -moz-linear-gradient(top, #2b3d53 0%, #2c3d4d 100%); /* FF3.6+ */
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#2b3d53), color-stop(100%,#2c3d4d)); /* Chrome,Safari4+ */
background: -webkit-linear-gradient(top, #2b3d53 0%,#2c3d4d 100%); /* Chrome10+,Safari5.1+ */
background: -o-linear-gradient(top, #2b3d53 0%,#2c3d4d 100%); /* Opera 11.10+ */
background: -ms-linear-gradient(top, #2b3d53 0%,#2c3d4d 100%); /* IE10+ */
background: linear-gradient(to bottom, #2b3d53 0%,#2c3d4d 100%); /* W3C */
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#2b3d53', endColorstr='#2c3d4d',GradientType=0 ); /* IE6-9 */
border-radius: 0;
-moz-border-radius: 0;
-webkit-border-radius: 0;
color: #ffffff;
}
#learning_path_breadcrumb_zone .breadcrumb a{
color: #ffffff;
text-decoration: none;
}
#learning_path_breadcrumb_zone .breadcrumb a:hover{
color: #dddddd;
}
#view_as_link{
margin-top: 5px;
margin-right: 10px;
}
#learning_path_left_zone #accordion .panel-heading{
text-align: center;
}
#learning_path_left_zone #ui-option{
width: 100%;
display: block;
text-align: center;
cursor: pointer;
}
#learning_path_left_zone #ui-option #icon-up,
#learning_path_left_zone #ui-option #icon-down{
width: 100%;
display: block;
}
.hidden{
visibility: hidden;
display: none;
}
.sidebar-scorm,
.content-scorm{
position: relative;
min-height: 1px;
padding-left: 15px;
padding-right: 15px;
}
.sidebar-scorm,
.content-scorm{
float: left;
}
.total{
width: 100%;
}
.panel-default .panel-heading .btn{
top: -25px;
}
.panel-default .panel-heading .dropdown-menu{
top: 30%;
}
#touch-button{
text-decoration: none;
position: fixed;
top: 40px;
left: -5px;
overflow: hidden;
width: 51px;
height: 51px;
border: none;
opacity: 50;
z-index: 2;
font-size: 26px;
}
.inner_lp_toc{
overflow-y:scroll;
}
.scorm-heading{
font-size: 16px;
font-weight: bold;
padding: 10px;
}
#control-bottom{
position: fixed;
bottom: 0;
width: 100%;
text-align: center;
left: 0;
}
#control-bottom.well{
margin-bottom: 0;
}
/*SCORM CSS BASE */
#learning_path_left_zone .home{
display: inline-block;
width: 94%;
margin-bottom: .5em;
margin-top: .5em;
font-size: 12px;
}
#lp_navigation_elem .buttons {
margin-bottom: .5em;
text-align: center;
}
#learning_path_left_zone .scorm_title{
font-size: 20px;
color: #666;
margin-bottom: .5em;
margin-top: .5em;
}
/* for section */
.scorm_item_section.scorm_completed{
background:url("../img/icon_completed_section.png")no-repeat 98% center #606c88;
padding-right: 1.5em;
}
.scorm_item_section{
background: #2b3d53; /* Old browsers */
background: -moz-linear-gradient(top, #2b3d53 0%, #2c3d4d 100%); /* FF3.6+ */
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#2b3d53), color-stop(100%,#2c3d4d)); /* Chrome,Safari4+ */
background: -webkit-linear-gradient(top, #2b3d53 0%,#2c3d4d 100%); /* Chrome10+,Safari5.1+ */
background: -o-linear-gradient(top, #2b3d53 0%,#2c3d4d 100%); /* Opera 11.10+ */
background: -ms-linear-gradient(top, #2b3d53 0%,#2c3d4d 100%); /* IE10+ */
background: linear-gradient(to bottom, #2b3d53 0%,#2c3d4d 100%); /* W3C */
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#2b3d53', endColorstr='#2c3d4d',GradientType=0 ); /* IE6-9 */
padding-top: 10px;
padding-bottom: 10px;
font-size: 14px;
color: #ffffff;
/* border-top-left-radius:5px;
border-top-right-radius: 5px;*/
}
.scorm_item_section .scorm_section_level_0{
padding-left: .5em;
padding-right: .5em;
}
.scorm_item_section .scorm_section_level_1{
padding-left: 1.5em;
padding-right: .5em;
}
.scorm_item_section .scorm_section_level_2{
padding-left: 2.5em;
padding-right: .5em;
}
.scorm_item_section .scorm_section_level_3{
padding-left: 3.5em;
padding-right: .5em;
}
.scorm_item_normal .scorm_item_level_0{
/* padding-left: .5em;
padding-right: 1.5em;
padding-top: 10px;
padding-bottom: 10px;
*/
}
.scorm_item_normal{
padding:0;
border-bottom: 1px solid #DCDCDC;
}
.scorm_item_normal a.items-list{
color: #666666;
text-decoration: none;
display: block;
padding-left: 2em;
padding-right: 1.5em;
padding-top: 5px;
padding-bottom: 5px;
}
.scorm_item_normal a:hover{
text-decoration: none;
}
.scorm_highlight{
background-color: #2B3D50 !important;
}
.scorm_highlight a{
color: #ffffff !important;
}
#scorm-info .panel-heading{
padding: 5px;
}
/* END SCORM CSS BASE*/

@ -1,543 +0,0 @@
/*
* File: demo_table.css
* CVS: $Id$
* Description: CSS descriptions for DataTables demo pages
* Author: Allan Jardine
* Created: Tue May 12 06:47:22 BST 2009
* Modified: $Date$ by $Author$
* Language: CSS
* Project: DataTables
*
* Copyright 2009 Allan Jardine. All Rights Reserved.
* Note: dataTable.css was later released as part of the jquery.dataTables
* plugin, released itself as GPLv2. As such, we believe this copyright is no
* longer an issue and will try to upgrade to a later version of dataTables
* in the near future. -- Yannick Warnier, Chamilo project leader, 2014-04
* See https://support.chamilo.org/issues/7043
*
* ***************************************************************************
* DESCRIPTION
*
* The styles given here are suitable for the demos that are used with the standard DataTables
* distribution (see www.datatables.net). You will most likely wish to modify these styles to
* meet the layout requirements of your site.
*
* Common issues:
* 'full_numbers' pagination - I use an extra selector on the body tag to ensure that there is
* no conflict between the two pagination types. If you want to use full_numbers pagination
* ensure that you either have "example_alt_pagination" as a body class name, or better yet,
* modify that selector.
* Note that the path used for Images is relative. All images are by default located in
* images/dataTable/ - relative to this CSS file.
*/
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* DataTables features
*/
.dataTables_wrapper {
position: relative;
min-height: 302px;
clear: both;
_height: 302px;
zoom: 1; /* Feeling sorry for IE */
}
.dataTables_processing {
position: absolute;
top: 50%;
left: 50%;
width: 250px;
height: 30px;
margin-left: -125px;
margin-top: -15px;
padding: 14px 0 2px 0;
border: 1px solid #ddd;
text-align: center;
color: #999;
font-size: 14px;
background-color: white;
}
.dataTables_length {
width: 40%;
float: left;
}
.dataTables_filter {
width: 50%;
float: right;
text-align: right;
}
.dataTables_info {
width: 60%;
float: left;
}
.dataTables_paginate {
width: 44px;
* width: 50px;
float: right;
text-align: right;
}
/* Pagination nested */
.paginate_disabled_previous, .paginate_enabled_previous, .paginate_disabled_next, .paginate_enabled_next {
height: 19px;
width: 19px;
margin-left: 3px;
float: left;
}
.paginate_disabled_previous {
background-image: url('images/dataTale/back_disabled.jpg');
}
.paginate_enabled_previous {
background-image: url('images/dataTable/back_enabled.jpg');
}
.paginate_disabled_next {
background-image: url('images/dataTable/forward_disabled.jpg');
}
.paginate_enabled_next {
background-image: url('images/dataTable/forward_enabled.jpg');
}
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* DataTables display
*/
table.display {
margin: 0 auto;
clear: both;
width: 100%;
/* Note Firefox 3.5 and before have a bug with border-collapse
* ( https://bugzilla.mozilla.org/show%5Fbug.cgi?id=155955 )
* border-spacing: 0; is one possible option. Conditional-css.com is
* useful for this kind of thing
*
* Further note IE 6/7 has problems when calculating widths with border width.
* It subtracts one px relative to the other browsers from the first column, and
* adds one to the end...
*
* If you want that effect I'd suggest setting a border-top/left on th/td's and
* then filling in the gaps with other borders.
*/
}
table.display thead th {
padding: 3px 18px 3px 10px;
border-bottom: 1px solid black;
font-weight: bold;
cursor: pointer;
* cursor: hand;
}
table.display tfoot th {
padding: 3px 18px 3px 10px;
border-top: 1px solid black;
font-weight: bold;
}
table.display tr.heading2 td {
border-bottom: 1px solid #aaa;
}
table.display td {
padding: 3px 10px;
}
table.display td.center {
text-align: center;
}
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* DataTables sorting
*/
.sorting_asc {
background: url('images/dataTable/sort_asc.png') no-repeat center right;
}
.sorting_desc {
background: url('images/dataTable/sort_desc.png') no-repeat center right;
}
.sorting {
background: url('images/dataTable/sort_both.png') no-repeat center right;
}
.sorting_asc_disabled {
background: url('images/dataTable/sort_asc_disabled.png') no-repeat center right;
}
.sorting_desc_disabled {
background: url('images/dataTable/sort_desc_disabled.png') no-repeat center right;
}
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* DataTables row classes
*/
table.display tr.odd.gradeA {
background-color: #ddffdd;
}
table.display tr.even.gradeA {
background-color: #eeffee;
}
table.display tr.odd.gradeC {
background-color: #ddddff;
}
table.display tr.even.gradeC {
background-color: #eeeeff;
}
table.display tr.odd.gradeX {
background-color: #ffdddd;
}
table.display tr.even.gradeX {
background-color: #ffeeee;
}
table.display tr.odd.gradeU {
background-color: #ddd;
}
table.display tr.even.gradeU {
background-color: #eee;
}
tr.odd {
background-color: #E2E4FF;
}
tr.even {
background-color: white;
}
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* Misc
*/
.dataTables_scroll {
clear: both;
}
.dataTables_scrollBody {
*margin-top: -1px;
}
.top, .bottom {
padding: 15px;
background-color: #F5F5F5;
border: 1px solid #CCCCCC;
}
.top .dataTables_info {
float: none;
}
.clear {
clear: both;
}
.dataTables_empty {
text-align: center;
}
tfoot input {
margin: 0.5em 0;
width: 100%;
color: #444;
}
tfoot input.search_init {
color: #999;
}
td.group {
background-color: #d1cfd0;
border-bottom: 2px solid #A19B9E;
border-top: 2px solid #A19B9E;
}
td.details {
background-color: #d1cfd0;
border: 2px solid #A19B9E;
}
.example_alt_pagination div.dataTables_info {
width: 40%;
}
.paging_full_numbers {
width: 400px;
height: 22px;
line-height: 22px;
}
.paging_full_numbers span.paginate_button,
.paging_full_numbers span.paginate_active {
border: 1px solid #aaa;
-webkit-border-radius: 5px;
-moz-border-radius: 5px;
padding: 2px 5px;
margin: 0 3px;
cursor: pointer;
*cursor: hand;
}
.paging_full_numbers span.paginate_button {
background-color: #ddd;
}
.paging_full_numbers span.paginate_button:hover {
background-color: #ccc;
}
.paging_full_numbers span.paginate_active {
background-color: #99B3FF;
}
table.display tr.even.row_selected td {
background-color: #B0BED9;
}
table.display tr.odd.row_selected td {
background-color: #9FAFD1;
}
/*
* Sorting classes for columns
*/
/* For the standard odd/even */
tr.odd td.sorting_1 {
background-color: #D3D6FF;
}
tr.odd td.sorting_2 {
background-color: #DADCFF;
}
tr.odd td.sorting_3 {
background-color: #E0E2FF;
}
tr.even td.sorting_1 {
background-color: #EAEBFF;
}
tr.even td.sorting_2 {
background-color: #F2F3FF;
}
tr.even td.sorting_3 {
background-color: #F9F9FF;
}
/* For the Conditional-CSS grading rows */
/*
Colour calculations (based off the main row colours)
Level 1:
dd > c4
ee > d5
Level 2:
dd > d1
ee > e2
*/
tr.odd.gradeA td.sorting_1 {
background-color: #c4ffc4;
}
tr.odd.gradeA td.sorting_2 {
background-color: #d1ffd1;
}
tr.odd.gradeA td.sorting_3 {
background-color: #d1ffd1;
}
tr.even.gradeA td.sorting_1 {
background-color: #d5ffd5;
}
tr.even.gradeA td.sorting_2 {
background-color: #e2ffe2;
}
tr.even.gradeA td.sorting_3 {
background-color: #e2ffe2;
}
tr.odd.gradeC td.sorting_1 {
background-color: #c4c4ff;
}
tr.odd.gradeC td.sorting_2 {
background-color: #d1d1ff;
}
tr.odd.gradeC td.sorting_3 {
background-color: #d1d1ff;
}
tr.even.gradeC td.sorting_1 {
background-color: #d5d5ff;
}
tr.even.gradeC td.sorting_2 {
background-color: #e2e2ff;
}
tr.even.gradeC td.sorting_3 {
background-color: #e2e2ff;
}
tr.odd.gradeX td.sorting_1 {
background-color: #ffc4c4;
}
tr.odd.gradeX td.sorting_2 {
background-color: #ffd1d1;
}
tr.odd.gradeX td.sorting_3 {
background-color: #ffd1d1;
}
tr.even.gradeX td.sorting_1 {
background-color: #ffd5d5;
}
tr.even.gradeX td.sorting_2 {
background-color: #ffe2e2;
}
tr.even.gradeX td.sorting_3 {
background-color: #ffe2e2;
}
tr.odd.gradeU td.sorting_1 {
background-color: #c4c4c4;
}
tr.odd.gradeU td.sorting_2 {
background-color: #d1d1d1;
}
tr.odd.gradeU td.sorting_3 {
background-color: #d1d1d1;
}
tr.even.gradeU td.sorting_1 {
background-color: #d5d5d5;
}
tr.even.gradeU td.sorting_2 {
background-color: #e2e2e2;
}
tr.even.gradeU td.sorting_3 {
background-color: #e2e2e2;
}
/*
* Row highlighting example
*/
.ex_highlight #example tbody tr.even:hover, #example tbody tr.even td.highlighted {
background-color: #ECFFB3;
}
.ex_highlight #example tbody tr.odd:hover, #example tbody tr.odd td.highlighted {
background-color: #E6FF99;
}
.ex_highlight_row #example tr.even:hover {
background-color: #ECFFB3;
}
.ex_highlight_row #example tr.even:hover td.sorting_1 {
background-color: #DDFF75;
}
.ex_highlight_row #example tr.even:hover td.sorting_2 {
background-color: #E7FF9E;
}
.ex_highlight_row #example tr.even:hover td.sorting_3 {
background-color: #E2FF89;
}
.ex_highlight_row #example tr.odd:hover {
background-color: #E6FF99;
}
.ex_highlight_row #example tr.odd:hover td.sorting_1 {
background-color: #D6FF5C;
}
.ex_highlight_row #example tr.odd:hover td.sorting_2 {
background-color: #E0FF84;
}
.ex_highlight_row #example tr.odd:hover td.sorting_3 {
background-color: #DBFF70;
}
/*
* KeyTable
*/
table.KeyTable td {
border: 3px solid transparent;
}
table.KeyTable td.focus {
border: 3px solid #3366FF;
}
table.display tr.gradeA {
background-color: #eeffee;
}
table.display tr.gradeC {
background-color: #ddddff;
}
table.display tr.gradeX {
background-color: #ffdddd;
}
table.display tr.gradeU {
background-color: #ddd;
}
div.box {
height: 100px;
padding: 10px;
overflow: auto;
border: 1px solid #8080FF;
background-color: #E5E5FF;
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 597 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 260 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 789 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 294 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 772 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 226 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 606 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 601 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 617 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 738 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 729 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 248 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 613 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 601 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 612 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 807 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 894 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 635 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 852 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 263 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 252 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 282 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 260 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 251 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 39 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 520 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 619 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 611 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 912 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 461 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 449 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 396 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 269 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 418 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 425 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 203 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 421 B

@ -1,3 +1,17 @@
/* items scorm*/
.scorm_item_normal.scorm_completed {
background:url("images/scorm_completed.png") no-repeat left center;
}
.scorm_item_normal.scorm_failed{
background:url("images/scorm_failed.png") no-repeat left center;
}
.scorm_item_normal.scorm_not_attempted{
background:url("images/scorm_not_attempted.png") no-repeat left center;
}
.scorm_item_normal.scorm_highlight{
background:url("images/scorm_highlight.png") no-repeat left center;
}
div.text {
margin-left : 6;
margin-right : 6;

@ -1,82 +0,0 @@
.scormpage {
}
.scormpage .menu {
width: 180px;
padding: 0px;
font-size: small;
position: absolute;
background-color: white;
}
.scormpage .menu .lp_nav {
height: 50px;
width: 160px;
padding-top: 4px;
padding-bottom:0px;
/*
margin-left: 10px;
margin-right: 10px;
*/
margin-top: 0px;
}
.lp_navigation_elem {
padding-left: 15px;
padding-top: 0px;
}
/*.scormpage .menu */
.lp_navigation_elem .progresstext {
font-size: smaller;
}
/*.scormpage .menu */
.lp_navigation_elem .buttons {
margin-left: 5px;
margin-right: 0em;
margin-top: 0.4em;
}
#msg_div_id {
padding-left: 10px;
padding-top: 4px;
}
.scormpage .menu .notification {
height: 50px;
margin-left: 15px;
margin-right: 15px;
}
.scormpage .menu .notification .message {
height: 50px;
width: 140px;
border: none;
}
.scormpage .menu .notification .lp_log {
height: 100px;
width: 180px;
border: none;
overflow: auto;
}
.scormpage .content .iframe {
/*
border: none;
height: 700px;
margin: 0px;
padding-right: 0px;
margin-right: 0%;
margin-left: 0%;
*/
/* trying the absolute mode */
position: fixed;
bottom:0;
left:0;
width: 100%;
height: 100%;
}
.scormpage .footer {
clear: both;
}
#image_preview {
padding-left: 17px;
}
#author_name {
padding-left: 5px;
padding-top: 5px;
font-size: 11px;
color:#888;
}

@ -48,7 +48,7 @@ if ($action == 'thematic_advance_add' || $action == 'thematic_advance_edit') {
$form->addElement('html', '<div id="div_custom_datetime" style="display:none">');
}
$form->addElement('DatePicker', 'custom_start_date', get_lang('StartDate'));
$form->addElement('DateTimePicker', 'custom_start_date', get_lang('StartDate'));
$form->addElement('html', '</div>');
if (isset($thematic_advance_data['attendance_id']) &&
@ -104,7 +104,7 @@ if ($action == 'thematic_advance_add' || $action == 'thematic_advance_edit') {
}
$default['start_date_type'] = 1;
$default['custom_start_date'] = date('Y-m-d', api_strtotime(api_get_local_time()));
$default['custom_start_date'] = date('Y-m-d H:i:s', api_strtotime(api_get_local_time()));
$default['duration_in_hours'] = 1;
if (!empty($thematic_advance_data)) {
@ -117,7 +117,7 @@ if ($action == 'thematic_advance_add' || $action == 'thematic_advance_edit') {
$default['custom_start_date'] = null;
if (isset($thematic_advance_data['start_date'])) {
$default['custom_start_date'] = date(
'Y-m-d',
'Y-m-d H:i:s',
api_strtotime(api_get_local_time($thematic_advance_data['start_date']))
);
}

@ -278,6 +278,7 @@ define('VALID_WEB_SERVER_BASE', '/https?:\/\/[^\/]*/i'); // $new_path
// Constants for api_get_path() and api_get_path_type(), etc. - registered path types.
define('WEB_PATH', 'WEB_PATH');
define('WEB_APP_PATH', 'WEB_APP_PATH');
define('SYS_PATH', 'SYS_PATH');
define('SYS_APP_PATH', 'SYS_APP_PATH');
define('SYS_UPLOAD_PATH', 'SYS_UPLOAD_PATH');
@ -651,6 +652,7 @@ function api_get_path($path_type, $path = null)
SYS_ARCHIVE_PATH => 'app/cache/',
WEB_ARCHIVE_PATH => 'app/cache/',
SYS_APP_PATH => 'app/',
WEB_APP_PATH => 'app/',
SYS_UPLOAD_PATH => 'app/upload/',
REL_UPLOAD_PATH => 'app/upload/',
INCLUDE_PATH => 'inc/',
@ -773,6 +775,7 @@ function api_get_path($path_type, $path = null)
$paths[SYS_LANG_PATH] = $paths[SYS_CODE_PATH].$paths[SYS_LANG_PATH];
$paths[SYS_APP_PATH] = $paths[SYS_PATH].$paths[SYS_APP_PATH];
$paths[WEB_APP_PATH] = $paths[WEB_PATH].$paths[WEB_APP_PATH];
$paths[SYS_UPLOAD_PATH] = $paths[SYS_PATH].$paths[SYS_UPLOAD_PATH];
$paths[SYS_PLUGIN_PATH] = $paths[SYS_PATH].$paths[SYS_PLUGIN_PATH];
@ -1764,6 +1767,8 @@ function api_get_course_info($course_code = null, $strict = false)
* Now if the course_code is given, the returned array gives info about that
* particular course, not specially the current one.
* @param int $id Numeric ID of the course
* @return array The course info as an array formatted by api_format_course_array, including category.name
*/
function api_get_course_info_by_id($id = null) {
if (!empty($id)) {
@ -3530,6 +3535,7 @@ function api_get_item_visibility(
* @param int $userId
* @param int $groupId
* @param int $sessionId
* @return void
*/
function api_item_property_delete(
$courseInfo,
@ -3594,6 +3600,7 @@ function api_item_property_delete(
* @param int $to_user_id : id of the intended user (always has priority over $to_group_id !), only relevant for $type (1)
* @param string $start_visible 0000-00-00 00:00:00 format
* @param string $end_visible 0000-00-00 00:00:00 format
* @param int $session_id The session ID, if any, otherwise will default to 0
* @return boolean False if update fails.
* @author Toon Van Hoecke <Toon.VanHoecke@UGent.be>, Ghent University
* @version January 2005
@ -3603,7 +3610,7 @@ function api_item_property_update(
$_course,
$tool,
$item_id,
$lastedit_type,
$last_edit_type,
$user_id,
$to_group_id = 0,
$to_user_id = null,
@ -3624,8 +3631,8 @@ function api_item_property_update(
// Definition of variables.
$tool = Database::escape_string($tool);
$item_id = intval($item_id);
$lastEditTypeNoFilter = $lastedit_type;
$lastedit_type = Database::escape_string($lastedit_type);
$lastEditTypeNoFilter = $last_edit_type;
$last_edit_type = Database::escape_string($last_edit_type);
$user_id = intval($user_id);
$startVisible = "NULL";
@ -3650,7 +3657,7 @@ function api_item_property_update(
}
// Definition of tables.
$TABLE_ITEMPROPERTY = Database::get_course_table(TABLE_ITEM_PROPERTY);
$tableItemProperty = Database::get_course_table(TABLE_ITEM_PROPERTY);
if ($to_user_id <= 0) {
$to_user_id = null; // No to_user_id set
@ -3670,16 +3677,13 @@ function api_item_property_update(
$toValueCondition = empty($to_value) ? "NULL" : "'$to_value'";
// Set filters for $to_user_id and $to_group_id, with priority for $to_user_id
$condition_session = '';
if (!empty($session_id)) {
$condition_session = " AND session_id = '$session_id' ";
}
$condition_session = " AND session_id = $session_id ";
$filter = " c_id = $course_id AND tool='$tool' AND ref='$item_id' $condition_session ";
$filter = " c_id = $course_id AND tool = '$tool' AND ref = $item_id $condition_session ";
if ($item_id === '*') {
// For all (not deleted) items of the tool
$filter = " c_id = $course_id AND tool = '$tool' AND visibility<>'2' $condition_session";
$filter = " c_id = $course_id AND tool = '$tool' AND visibility <> 2 $condition_session";
}
// Check whether $to_user_id and $to_group_id are passed in the function call.
@ -3690,11 +3694,11 @@ function api_item_property_update(
if (!is_null($to_user_id)) {
// Set filter to intended user.
$to_filter = " AND to_user_id= '$to_user_id' $condition_session";
$to_filter = " AND to_user_id = $to_user_id $condition_session";
} else {
// Set filter to intended group.
if (($to_group_id != 0) && $to_group_id == strval(intval($to_group_id))) {
$to_filter = " AND to_group_id = '$to_group_id' $condition_session";
$to_filter = " AND to_group_id = $to_group_id $condition_session";
}
}
@ -3708,40 +3712,40 @@ function api_item_property_update(
// delete = make item only visible for the platform admin.
$visibility = '2';
if (!empty($session_id)) {
// Check whether session id already exist into itemp_properties for updating visibility or add it.
$sql = "SELECT session_id FROM $TABLE_ITEMPROPERTY
// Check whether session id already exist into item_properties for updating visibility or add it.
$sql = "SELECT session_id FROM $tableItemProperty
WHERE
c_id = $course_id AND
tool = '$tool' AND
ref='$item_id' AND
session_id = '$session_id'";
ref = $item_id AND
session_id = $session_id";
$rs = Database::query($sql);
if (Database::num_rows($rs) > 0) {
$sql = "UPDATE $TABLE_ITEMPROPERTY
$sql = "UPDATE $tableItemProperty
SET lastedit_type = '".str_replace('_', '', ucwords($tool))."Deleted',
lastedit_date = '$time',
lastedit_user_id = '$user_id',
visibility = '$visibility',
session_id = '$session_id' $set_type
lastedit_user_id = $user_id,
visibility = $visibility,
session_id = $session_id $set_type
WHERE $filter";
$result = Database::query($sql);
} else {
$sql = "INSERT INTO $TABLE_ITEMPROPERTY (c_id, tool, ref, insert_date, insert_user_id, lastedit_date, lastedit_type, lastedit_user_id, $to_field, visibility, start_visible, end_visible, session_id)
VALUES ($course_id, '$tool','$item_id','$time', '$user_id', '$time', '$lastedit_type','$user_id', $toValueCondition, '$visibility', $startVisible, $endVisible, '$session_id')";
$sql = "INSERT INTO $tableItemProperty (c_id, tool, ref, insert_date, insert_user_id, lastedit_date, lastedit_type, lastedit_user_id, $to_field, visibility, start_visible, end_visible, session_id)
VALUES ($course_id, '$tool',$item_id, '$time', $user_id, '$time', '$last_edit_type',$user_id, $toValueCondition, $visibility, $startVisible, $endVisible, $session_id)";
$result = Database::query($sql);
$id = Database::insert_id();
if ($id) {
$sql = "UPDATE $TABLE_ITEMPROPERTY SET id = iid WHERE iid = $id";
$sql = "UPDATE $tableItemProperty SET id = iid WHERE iid = $id";
Database::query($sql);
}
}
} else {
$sql = "UPDATE $TABLE_ITEMPROPERTY
$sql = "UPDATE $tableItemProperty
SET
lastedit_type='".str_replace('_', '', ucwords($tool))."Deleted',
lastedit_date='$time',
lastedit_user_id = '$user_id',
visibility='$visibility' $set_type
lastedit_user_id = $user_id,
visibility = $visibility $set_type
WHERE $filter";
$result = Database::query($sql);
}
@ -3750,40 +3754,40 @@ function api_item_property_update(
$visibility = '1';
if (!empty($session_id)) {
// Check whether session id already exist into item_properties for updating visibility or add it.
$sql = "SELECT session_id FROM $TABLE_ITEMPROPERTY
$sql = "SELECT session_id FROM $tableItemProperty
WHERE
c_id = $course_id AND
tool = '$tool' AND
ref = '$item_id' AND
session_id = '$session_id'";
ref = $item_id AND
session_id = $session_id";
$rs = Database::query($sql);
if (Database::num_rows($rs) > 0) {
$sql = "UPDATE $TABLE_ITEMPROPERTY
$sql = "UPDATE $tableItemProperty
SET
lastedit_type='".str_replace('_', '', ucwords($tool))."Visible',
lastedit_date='$time',
lastedit_user_id = '$user_id',
visibility='$visibility',
session_id = '$session_id' $set_type
lastedit_user_id = $user_id,
visibility = $visibility,
session_id = $session_id $set_type
WHERE $filter";
$result = Database::query($sql);
} else {
$sql = "INSERT INTO $TABLE_ITEMPROPERTY (c_id, tool, ref, insert_date, insert_user_id, lastedit_date, lastedit_type, lastedit_user_id, $to_field, visibility, start_visible, end_visible, session_id)
VALUES ($course_id, '$tool', '$item_id', '$time', '$user_id', '$time', '$lastedit_type', '$user_id', $toValueCondition, '$visibility', $startVisible, $endVisible, '$session_id')";
$sql = "INSERT INTO $tableItemProperty (c_id, tool, ref, insert_date, insert_user_id, lastedit_date, lastedit_type, lastedit_user_id, $to_field, visibility, start_visible, end_visible, session_id)
VALUES ($course_id, '$tool', $item_id, '$time', $user_id, '$time', '$last_edit_type', $user_id, $toValueCondition, $visibility, $startVisible, $endVisible, $session_id)";
$result = Database::query($sql);
$id = Database::insert_id();
if ($id) {
$sql = "UPDATE $TABLE_ITEMPROPERTY SET id = iid WHERE iid = $id";
$sql = "UPDATE $tableItemProperty SET id = iid WHERE iid = $id";
Database::query($sql);
}
}
} else {
$sql = "UPDATE $TABLE_ITEMPROPERTY
$sql = "UPDATE $tableItemProperty
SET
lastedit_type='".str_replace('_', '', ucwords($tool))."Visible',
lastedit_date='$time',
lastedit_user_id='$user_id',
visibility='$visibility' $set_type
lastedit_user_id = $user_id,
visibility = $visibility $set_type
WHERE $filter";
$result = Database::query($sql);
}
@ -3792,65 +3796,65 @@ function api_item_property_update(
$visibility = '0';
if (!empty($session_id)) {
// Check whether session id already exist into item_properties for updating visibility or add it
$sql = "SELECT session_id FROM $TABLE_ITEMPROPERTY
$sql = "SELECT session_id FROM $tableItemProperty
WHERE
c_id = $course_id AND
tool = '$tool' AND
ref='$item_id' AND
session_id = '$session_id'";
ref = $item_id AND
session_id = $session_id";
$rs = Database::query($sql);
if (Database::num_rows($rs) > 0) {
$sql = "UPDATE $TABLE_ITEMPROPERTY
$sql = "UPDATE $tableItemProperty
SET
lastedit_type = '".str_replace('_', '', ucwords($tool))."Invisible',
lastedit_date = '$time',
lastedit_user_id='$user_id',
visibility = '$visibility',
session_id = '$session_id' $set_type
lastedit_user_id = $user_id,
visibility = $visibility,
session_id = $session_id $set_type
WHERE $filter";
$result = Database::query($sql);
} else {
$sql = "INSERT INTO $TABLE_ITEMPROPERTY (c_id, tool, ref, insert_date, insert_user_id, lastedit_date, lastedit_type, lastedit_user_id,$to_field, visibility, start_visible, end_visible, session_id)
VALUES ($course_id, '$tool', '$item_id', '$time', '$user_id', '$time', '$lastedit_type', '$user_id', $toValueCondition, '$visibility', $startVisible, $endVisible, '$session_id')";
$sql = "INSERT INTO $tableItemProperty (c_id, tool, ref, insert_date, insert_user_id, lastedit_date, lastedit_type, lastedit_user_id,$to_field, visibility, start_visible, end_visible, session_id)
VALUES ($course_id, '$tool', $item_id, '$time', $user_id, '$time', '$last_edit_type', $user_id, $toValueCondition, $visibility, $startVisible, $endVisible, $session_id)";
$result = Database::query($sql);
$id = Database::insert_id();
if ($id) {
$sql = "UPDATE $TABLE_ITEMPROPERTY SET id = iid WHERE iid = $id";
$sql = "UPDATE $tableItemProperty SET id = iid WHERE iid = $id";
Database::query($sql);
}
}
} else {
$sql = "UPDATE $TABLE_ITEMPROPERTY
$sql = "UPDATE $tableItemProperty
SET
lastedit_type = '".str_replace('_', '', ucwords($tool))."Invisible',
lastedit_date = '$time',
lastedit_user_id = '$user_id',
visibility = '$visibility' $set_type
lastedit_user_id = $user_id,
visibility = $visibility $set_type
WHERE $filter";
$result = Database::query($sql);
}
break;
default : // The item will be added or updated.
$set_type = ", lastedit_type='$lastedit_type' ";
$set_type = ", lastedit_type = '$last_edit_type' ";
$visibility = '1';
//$filter .= $to_filter; already added
$sql = "UPDATE $TABLE_ITEMPROPERTY
$sql = "UPDATE $tableItemProperty
SET
lastedit_date = '$time',
lastedit_user_id='$user_id' $set_type
lastedit_user_id = $user_id $set_type
WHERE $filter";
$result = Database::query($sql);
}
// Insert if no entries are found (can only happen in case of $lastedit_type switch is 'default').
// Insert if no entries are found (can only happen in case of $last_edit_type switch is 'default').
if (Database::affected_rows($result) == 0) {
$sessionCondition = empty($session_id) ? "NULL" : "'$session_id'";
$sql = "INSERT INTO $TABLE_ITEMPROPERTY (c_id, tool,ref,insert_date,insert_user_id,lastedit_date,lastedit_type, lastedit_user_id, $to_field, visibility, start_visible, end_visible, session_id)
VALUES ($course_id, '$tool', '$item_id', '$time', '$user_id', '$time', '$lastedit_type', '$user_id', $toValueCondition, '$visibility', $startVisible, $endVisible, $sessionCondition)";
$sql = "INSERT INTO $tableItemProperty (c_id, tool,ref,insert_date,insert_user_id,lastedit_date,lastedit_type, lastedit_user_id, $to_field, visibility, start_visible, end_visible, session_id)
VALUES ($course_id, '$tool', $item_id, '$time', $user_id, '$time', '$last_edit_type', $user_id, $toValueCondition, $visibility, $startVisible, $endVisible, $sessionCondition)";
$res = Database::query($sql);
$id = Database::insert_id();
if ($id) {
$sql = "UPDATE $TABLE_ITEMPROPERTY SET id = iid WHERE iid = $id";
$sql = "UPDATE $tableItemProperty SET id = iid WHERE iid = $id";
Database::query($sql);
return false;
}
@ -3864,6 +3868,8 @@ function api_item_property_update(
* @param string course code
* @param string tool name, linked to 'rubrique' of the course tool_list (Warning: language sensitive !!)
* @param int id of the item itself, linked to key of every tool ('id', ...), "*" = all items of the tool
* @param int $session_id
* @return array All fields from c_item_property (all rows found) or empty array
*/
function api_get_item_property_by_tool($tool, $course_code, $session_id = null)
{
@ -3874,6 +3880,9 @@ function api_get_item_property_by_tool($tool, $course_code, $session_id = null)
$item_property_table = Database::get_course_table(TABLE_ITEM_PROPERTY);
$session_id = intval($session_id);
$session_condition = ' AND session_id = '.$session_id;
if (empty($session_id)) {
$session_condition = " AND (session_id = 0 OR session_id IS NULL) ";
}
$course_id = $course_info['real_id'];
$sql = "SELECT * FROM $item_property_table
@ -3913,6 +3922,9 @@ function api_get_item_property_list_by_tool_by_user(
// Definition of tables.
$item_property_table = Database::get_course_table(TABLE_ITEM_PROPERTY);
$session_condition = ' AND session_id = '.$session_id;
if (empty($session_id)) {
$session_condition = " (session_id = 0 OR session_id IS NULL) ";
}
$sql = "SELECT * FROM $item_property_table
WHERE
insert_user_id = $userId AND
@ -3932,21 +3944,27 @@ function api_get_item_property_list_by_tool_by_user(
/**
* Gets item property id from tool of a course
* @param string course code
* @param string tool name, linked to 'rubrique' of the course tool_list (Warning: language sensitive !!)
* @param int id of the item itself, linked to key of every tool ('id', ...), "*" = all items of the tool
* @param string $course_code course code
* @param string $tool tool name, linked to 'rubrique' of the course tool_list (Warning: language sensitive !!)
* @param int $ref id of the item itself, linked to key of every tool ('id', ...), "*" = all items of the tool
* @param int $sessionId Session ID (optional)
* @return int
*/
function api_get_item_property_id($course_code, $tool, $ref)
function api_get_item_property_id($course_code, $tool, $ref, $sessionId = 0)
{
$course_info = api_get_course_info($course_code);
$tool = Database::escape_string($tool);
$ref = intval($ref);
// Definition of tables.
$TABLE_ITEMPROPERTY = Database::get_course_table(TABLE_ITEM_PROPERTY);
$tableItemProperty = Database::get_course_table(TABLE_ITEM_PROPERTY);
$course_id = $course_info['real_id'];
$sql = "SELECT id FROM $TABLE_ITEMPROPERTY
WHERE c_id = $course_id AND tool = '$tool' AND ref = '$ref'";
$sessionCondition = " AND session_id = $sessionId ";
if (empty($sessionId)) {
$sessionCondition = " (session_id = 0 OR session_id IS NULL) ";
}
$sql = "SELECT id FROM $tableItemProperty
WHERE c_id = $course_id AND tool = '$tool' AND ref = $ref $sessionCondition";
$rs = Database::query($sql);
$item_property_id = '';
if (Database::num_rows($rs) > 0) {
@ -4015,6 +4033,7 @@ function api_get_track_item_property_history($tool, $ref)
* @param string tool name, linked to 'rubrique' of the course tool_list (Warning: language sensitive !!)
* @param int id of the item itself, linked to key of every tool ('id', ...), "*" = all items of the tool
* @param int $session_id
* @return array Array with all fields from c_item_property, empty array if not found or false if course could not be found
*/
function api_get_item_property_info($course_id, $tool, $ref, $session_id = 0)
{

@ -532,19 +532,18 @@ class Template
global $disable_js_and_css_files;
// Base CSS
$css[] = api_get_cdn_path(api_get_path(WEB_CSS_PATH).'base.css');
$css[] = api_get_cdn_path(api_get_path(WEB_CSS_PATH).'themes/'.$this->theme.'/default.css');
if ($this->show_learnpath) {
$css[] = api_get_path(WEB_CSS_PATH).$this->theme.'/learnpath.css';
// if we have a SCORM file in theme, don't use default_scorm.css file
if (is_file(api_get_path(SYS_CSS_PATH).$this->theme.'/scorm.css')) {
$css[] = api_get_path(WEB_CSS_PATH).$this->theme.'/scorm.css';
} else {
$css[] = api_get_cdn_path(api_get_path(WEB_CSS_PATH).'default_scorm.css');
$css[] = api_get_cdn_path(api_get_path(WEB_CSS_PATH).'scorm.css');
if (is_file(api_get_path(SYS_CSS_PATH).'themes/'.$this->theme.'/learnpath.css')) {
$css[] = api_get_path(WEB_CSS_PATH).'themes/'.$this->theme.'/learnpath.css';
}
}
$css[] = api_get_cdn_path(api_get_path(WEB_CSS_PATH).'themes/'.$this->theme.'/default.css');
$css_file_to_string = null;
foreach ($css as $file) {
$css_file_to_string .= api_get_css($file);

@ -521,7 +521,7 @@ class Thematic
}
}
//DATE_TIME_FORMAT_LONG
$thematic_advance_item = '<div><strong>'.api_convert_and_format_date($thematic_advance['start_date'], DATE_FORMAT_LONG).$session_star.'</strong></div>';
$thematic_advance_item = '<div><strong>'.api_convert_and_format_date($thematic_advance['start_date'], DATE_TIME_FORMAT_LONG).$session_star.'</strong></div>';
// $thematic_advance_item .= '<div>'.get_lang('DurationInHours').' : '.$thematic_advance['duration'].'</div>';
$thematic_advance_item .= '<div>'.$thematic_advance['duration'].' '.get_lang('HourShort').'</div>';
$thematic_advance_item .= '<div>'.Security::remove_XSS($thematic_advance['content'], STUDENT).'</div>';
@ -662,7 +662,7 @@ class Thematic
// protect data
$id = intval($this->thematic_advance_id);
$tematic_id = intval($this->thematic_id);
$thematic_id = intval($this->thematic_id);
$attendance_id = intval($this->attendance_id);
$content = Database::escape_string($this->thematic_advance_content);
$start_date = Database::escape_string($this->start_date);
@ -673,7 +673,7 @@ class Thematic
if (empty($id)) {
// Insert
$sql = "INSERT INTO $tbl_thematic_advance (c_id, thematic_id, attendance_id, content, start_date, duration)
VALUES ($this->course_int_id, $tematic_id, $attendance_id, '$content', '".api_get_utc_datetime($start_date)."', '$duration') ";
VALUES ($this->course_int_id, $thematic_id, $attendance_id, '$content', '".api_get_utc_datetime($start_date)."', '$duration') ";
$result = Database::query($sql);
$last_id = Database::insert_id();
@ -685,7 +685,7 @@ class Thematic
}
} else {
// update
$sql = "UPDATE $tbl_thematic_advance SET thematic_id = '$tematic_id', attendance_id = '$attendance_id', content = '$content', start_date = '".api_get_utc_datetime($start_date)."', duration = '$duration'
$sql = "UPDATE $tbl_thematic_advance SET thematic_id = $thematic_id, attendance_id = $attendance_id, content = '$content', start_date = '".api_get_utc_datetime($start_date)."', duration = '$duration'
WHERE c_id = {$this->course_int_id} AND id = $id ";
$result = Database::query($sql);
if (Database::affected_rows($result)) {

@ -1706,7 +1706,8 @@ VALUES
('hide_certificate_export_link', NULL, 'radio', 'Gradebook', 'false', 'CertificateHideExportLinkTitle', 'CertificateHideExportLinkComment', NULL, NULL, 1),
('dropbox_hide_course_coach', NULL, 'radio', 'Tools', 'false', 'DropboxHideCourseCoachTitle', 'DropboxHideCourseCoachComment', NULL, NULL, 1),
('sso_force_redirect', NULL, 'radio', 'Security', 'false', 'SSOForceRedirectTitle', 'SSOForceRedirectComment', NULL, NULL, 1),
('session_course_ordering', NULL, 'radio', 'Session', 'false', 'SessionCourseOrderingTitle', 'SessionCourseOrderingComment', NULL, NULL, 1);
('session_course_ordering', NULL, 'radio', 'Session', 'false', 'SessionCourseOrderingTitle', 'SessionCourseOrderingComment', NULL, NULL, 1),
('gamification_mode', NULL, 'radio', 'Platform', '0', 'GamificationModeTitle', 'GamificationModeComment', NULL, NULL, 1);
INSERT INTO settings_options (variable, value, display_text)
VALUES
@ -1780,6 +1781,8 @@ VALUES
('sso_force_redirect', 'true', 'Yes'),
('sso_force_redirect', 'false', 'No'),
('session_course_ordering', 'true', 'Yes'),
('session_course_ordering', 'false', 'No');
('session_course_ordering', 'false', 'No'),
('gamification_mode', '1', 'Yes'),
('gamification_mode', '0', 'No');
UPDATE settings_current SET selected_value = '1.10.0.40' WHERE variable = 'chamilo_database_version';

@ -3229,7 +3229,7 @@ class learnpath
$html .= stripslashes($title);
} else {
$this->get_link('http', $item['id'], $toc_list);
$html .= '<a href="" onClick="switch_item(' .$mycurrentitemid . ',' .$item['id'] . ');' .'return false;" >' . stripslashes($title) . '</a>';
$html .= '<a class="items-list" href="" onClick="switch_item(' .$mycurrentitemid . ',' .$item['id'] . ');' .'return false;" >' . stripslashes($title) . '</a>';
}
$html .= "</div>";
@ -5272,7 +5272,6 @@ class learnpath
* but possibility to do again a completed item.
*
* @return boolean true if seriousgame_mode has been set to 1, false otherwise
* @deprecated seems not to be used
* @author ndiechburg <noel@cblue.be>
**/
public function set_seriousgame_mode()
@ -5473,7 +5472,10 @@ class learnpath
// We need to close the form when we are updating the mp3 files.
if ($update_audio == 'true') {
$return .= '<div><button class="save" type="submit" name="save_audio" id="save_audio">' . get_lang('SaveAudioAndOrganization') . '</button></div>'; // TODO: What kind of language variable is this?
$return .= '<div class="footer-audio">';
$return .= Display::button('save_audio','<i class="fa fa-file-audio-o"></i> '. get_lang('SaveAudioAndOrganization'),array('class'=>'btn btn-primary','type'=>'submit'));
$return .= '</div>';
//$return .= '<div><button class="btn btn-primary" type="submit" name="save_audio" id="save_audio">' . get_lang('SaveAudioAndOrganization') . '</button></div>'; // TODO: What kind of language variable is this?
}
}
@ -5565,7 +5567,7 @@ class learnpath
}
// The audio column.
$return_audio .= '<td align="center">';
$return_audio .= '<td align="left" style="padding-left:10px;">';
$audio = '';
@ -10139,6 +10141,8 @@ EOD;
}
/**
* Get whether this is a learning path with the possibility to subscribe
* users or not
* @return int
*/
public function getSubscribeUsers()
@ -10147,7 +10151,9 @@ EOD;
}
/**
* @param int $subscribeUsers
* Set whether this is a learning path with the possibility to subscribe
* users or not
* @param int $subscribeUsers (0 = false, 1 = true)
*/
public function setSubscribeUsers($value)
{
@ -10157,12 +10163,192 @@ EOD;
$this->subscribeUsers = intval($value);;
$lp_table = Database :: get_course_table(TABLE_LP_MAIN);
$lp_id = $this->get_id();
$sql = "UPDATE $lp_table SET subscribe_users = '".$this->subscribeUsers."'
WHERE c_id = ".$this->course_int_id." AND id = '$lp_id'";
$sql = "UPDATE $lp_table SET subscribe_users = ".$this->subscribeUsers."
WHERE c_id = ".$this->course_int_id." AND id = $lp_id";
Database::query($sql);
return true;
}
/**
* Calculate the count of stars for a user
* @param int $lpId The learn path ID
* @param int $userId The user ID
* @param int $courseId The course ID
* @param int $sessionId Optional. The session ID
* @return int The count of stars
*/
public function getCalculateStars()
{
$stars = 0;
$progress = self::getProgress($this->lp_id, $this->user_id, $this->course_int_id, $this->lp_session_id);
if ($progress > 50) {
$stars++;
}
// Calculate stars chapters evaluation
$exercisesItems = $this->getExercisesItems();
if ($exercisesItems === false) {
return $stars;
}
$totalResult = 0;
foreach ($exercisesItems as $exerciseItem) {
$exerciseResultInfo = Event::getExerciseResultsByUser(
$this->user_id,
$exerciseItem->ref,
$this->course_int_id,
$this->lp_session_id,
$this->lp_id,
$exerciseItem->db_id
);
$exerciseResult = 0;
foreach ($exerciseResultInfo as $result) {
$exerciseResult += $result['exe_result'] * 100 / $result['exe_weighting'];
}
$exerciseAverage = $exerciseResult / (count($exerciseResultInfo) > 0 ? count($exerciseResultInfo) : 1);
$totalResult += $exerciseAverage;
}
$totalExerciseAverage = $totalResult / (count($exercisesItems) > 0 ? count($exercisesItems) : 1);
if ($totalExerciseAverage >= 50) {
$stars++;
}
if ($totalExerciseAverage >= 80) {
$stars++;
}
// Calculate star for final evaluation
$finalEvaluationItem = $this->getFinalEvaluationItem();
if ($finalEvaluationItem === false) {
return $stars;
}
$evaluationResultInfo = Event::getExerciseResultsByUser(
$this->user_id,
$finalEvaluationItem->ref,
$this->course_int_id,
$this->lp_session_id,
$this->lp_id,
$finalEvaluationItem->db_id
);
$evaluationResult = 0;
foreach ($evaluationResultInfo as $result) {
$evaluationResult += $result['exe_result'] * 100 / $result['exe_weighting'];
}
$evaluationAverage = $evaluationResult / (count($evaluationResultInfo) > 0 ? count($evaluationResultInfo) : 1);
if ($evaluationAverage >= 80) {
$stars++;
}
return $stars;
}
/**
* Get the items of exercise type
* @return array The items. Otherwise return false
*/
public function getExercisesItems()
{
$exercises = [];
foreach ($this->items as $item) {
if ($item->type != 'quiz') {
continue;
}
$exercises[] = $item;
}
array_pop($exercises);
return $exercises;
}
/**
* Get the item of exercise type (evaluation type)
* @return array The final evaluation. Otherwise return false
*/
public function getFinalEvaluationItem()
{
$exercises = [];
foreach ($this->items as $item) {
if ($item->type != 'quiz') {
continue;
}
$exercises[] = $item;
}
return array_pop($exercises);
}
/**
* Calculate the total points achieved for the current user in this learning path
* @return int
*/
public function getCalculateScore()
{
// Calculate stars chapters evaluation
$exercisesItems = $this->getExercisesItems();
$finalEvaluationItem = $this->getFinalEvaluationItem();
$totalExercisesResult = 0;
$totalEvaluationResult = 0;
if ($exercisesItems !== false) {
foreach ($exercisesItems as $exerciseItem) {
$exerciseResultInfo = Event::getExerciseResultsByUser(
$this->user_id,
$exerciseItem->ref,
$this->course_int_id,
$this->lp_session_id,
$this->lp_id,
$exerciseItem->db_id
);
$exerciseResult = 0;
foreach ($exerciseResultInfo as $result) {
$exerciseResult += $result['exe_result'];
}
$totalExercisesResult += $exerciseResult;
}
}
if ($finalEvaluationItem !== false) {
$evaluationResultInfo = Event::getExerciseResultsByUser(
$this->user_id,
$finalEvaluationItem->ref,
$this->course_int_id,
$this->lp_session_id,
$this->lp_id,
$finalEvaluationItem->db_id
);
foreach ($evaluationResultInfo as $result) {
$totalEvaluationResult += $result['exe_result'];
}
}
return $totalExercisesResult + $totalEvaluationResult;
}
}
if (!function_exists('trim_value')) {

@ -115,10 +115,7 @@ $form->addElement('hidden', 'action', 'add_lp');
$form->addButtonAdvancedSettings('advanced_params');
$form->addElement('html', '<div id="advanced_params_options" style="display:none">');
$items = learnpath::getCategoryFromCourseIntoSelect(api_get_course_int_id());
if (!empty($items)) {
$items = array_merge(array(get_lang('SelectACategory')), $items);
}
$items = learnpath::getCategoryFromCourseIntoSelect(api_get_course_int_id(), true);
$form->addElement('select', 'category_id', get_lang('Category'), $items);
// Start date

@ -1247,6 +1247,25 @@ switch ($action) {
$url = api_get_self().'?action=add_item&type=step&lp_id='.intval($_SESSION['oLP']->lp_id)."&message=ItemUpdated";
header('Location: '.$url);
break;
case 'toggle_seriousgame': //activate/deactive seriousgame_mode
if (!$is_allowed_to_edit) {
api_not_allowed(true);
}
if ($debug > 0) {
error_log('New LP - seriousgame_mode action triggered');
}
if (!$lp_found) {
error_log('New LP - No learnpath given for visibility');
require 'lp_list.php';
}
$_SESSION['refresh'] = 1;
$_SESSION['oLP']->set_seriousgame_mode();
require 'lp_list.php';
break;
default:
if ($debug > 0) error_log('New LP - default action triggered', 0);
require 'lp_list.php';

@ -48,53 +48,64 @@ if (api_get_setting('search_enabled') == 'true') {
require api_get_path(LIBRARY_PATH).'search/search_widget.php';
search_widget_prepare($htmlHeadXtra);
}
Display::display_header($nameTools, 'Path');
$current_session = api_get_session_id();
/* Introduction section (editable by course admins) */
Display::display_introduction_section(TOOL_LEARNPATH, array(
$introductionSection = Display::return_introduction_section(
TOOL_LEARNPATH,
array(
'CreateDocumentWebDir' => api_get_path(WEB_COURSE_PATH).api_get_course_path().'/document/',
'CreateDocumentDir' => '../../courses/'.api_get_course_path().'/document/',
'BaseHref' => api_get_path(WEB_COURSE_PATH).api_get_course_path().'/'
));
)
);
$is_allowed_to_edit = api_is_allowed_to_edit(null, true);
$message = '';
$actions = '';
if ($is_allowed_to_edit) {
if (!empty($dialog_box)) {
switch ($_GET['dialogtype']) {
case 'confirmation':
Display::display_confirmation_message($dialog_box);
$message = Display::return_message($dialog_box, 'success');
break;
case 'error':
Display::display_error_message($dialog_box);
$message = Display::return_message($dialog_box, 'danger');
break;
case 'warning':
Display::display_warning_message($dialog_box);
$message = Display::return_message($dialog_box, 'warning');
break;
default:
Display::display_normal_message($dialog_box);
$message = Display::return_message($dialog_box);
break;
}
}
if (api_failure::get_last_failure()) {
Display::display_normal_message(api_failure::get_last_failure());
$message = Display::return_message(api_failure::get_last_failure());
}
echo '<div class="actions">';
echo Display::url(
$actions .= Display::url(
Display::return_icon('new_folder.png', get_lang('AddCategory'), array(), ICON_SIZE_MEDIUM),
api_get_self().'?'.api_get_cidreq().'&action=add_lp_category'
);
echo '<a href="'.api_get_self().'?'.api_get_cidreq().'&action=add_lp">'.Display::return_icon('new_learnpath.png', get_lang('LearnpathAddLearnpath'), '', ICON_SIZE_MEDIUM).'</a>'.
str_repeat('&nbsp;', 3).
'<a href="../upload/index.php?'.api_get_cidreq().'&curdirpath=/&tool='.TOOL_LEARNPATH.'">'.Display::return_icon('import_scorm.png', get_lang('UploadScorm'), '', ICON_SIZE_MEDIUM).'</a>';
$actions .= Display::url(
Display::return_icon('new_learnpath.png', get_lang('LearnpathAddLearnpath'), '', ICON_SIZE_MEDIUM),
api_get_self().'?'.api_get_cidreq().'&action=add_lp'
);
$actions .= Display::url(
Display::return_icon('import_scorm.png', get_lang('UploadScorm'), '', ICON_SIZE_MEDIUM),
'../upload/index.php?'.api_get_cidreq().'&curdirpath=/&tool='.TOOL_LEARNPATH
);
if (api_get_setting('service_ppt2lp', 'active') == 'true') {
echo str_repeat('&nbsp;', 3).'<a href="../upload/upload_ppt.php?'.api_get_cidreq().'&curdirpath=/&tool='.TOOL_LEARNPATH.'">
'.Display::return_icon('import_powerpoint.png', get_lang('PowerPointConvert'), '', ICON_SIZE_MEDIUM).'</a>';
$actions .= Display::url(
Display::return_icon('import_powerpoint.png', get_lang('PowerPointConvert'), '', ICON_SIZE_MEDIUM),
'../upload/upload_ppt.php?'.api_get_cidreq().'&curdirpath=/&tool='.TOOL_LEARNPATH
);
}
echo '</div>';
}
$token = Security::get_token();
@ -118,12 +129,12 @@ if (!empty($categoriesTempList)) {
$userId = api_get_user_id();
$userInfo = api_get_user_info();
$lp_showed = false;
$total = count($categories);
$counterCategories = 1;
$lpIsShown = false;
$test_mode = api_get_setting('server_type');
$data = [];
foreach ($categories as $item) {
$categoryId = $item->getId();
@ -143,59 +154,14 @@ foreach ($categories as $item) {
continue;
}
$edit_link = null;
$delete_link = null;
$moveUpLink = null;
$moveDownLink = null;
if ($item->getId() > 0 && api_is_allowed_to_edit()) {
$url = 'lp_controller.php?'.api_get_cidreq().'&action=add_lp_category&id='.$item->getId();
$edit_link = Display::url(Display::return_icon('edit.png', get_lang('Edit')), $url);
$delete_url = 'lp_controller.php?'.api_get_cidreq().'&action=delete_lp_category&id='.$item->getId();
$moveUpUrl = 'lp_controller.php?'.api_get_cidreq().'&action=move_up_category&id='.$item->getId();
$moveDownUrl = 'lp_controller.php?'.api_get_cidreq().'&action=move_down_category&id='.$item->getId();
if ($counterCategories == 1) {
$moveUpLink = Display::url(Display::return_icon('up_na.png', get_lang('Move')), '#');
} else {
$moveUpLink = Display::url(Display::return_icon('up.png', get_lang('Move')), $moveUpUrl);
}
if (($total -1) == $counterCategories) {
$moveDownLink = Display::url(Display::return_icon('down_na.png', get_lang('Move')), '#');
} else {
$moveDownLink = Display::url(Display::return_icon('down.png', get_lang('Move')), $moveDownUrl);
}
$delete_link = Display::url(Display::return_icon('delete.png', get_lang('Delete')), $delete_url);
$counterCategories++;
}
echo Display::page_subheader2($item->getName().$edit_link.$moveUpLink.$moveDownLink.$delete_link);
$listData = [];
if (!empty($flat_list)) {
echo '<table class="data_table">';
echo '<tr>';
if ($is_allowed_to_edit) {
echo '<th width="35%">'.get_lang('Title').'</th>';
echo '<th>'.get_lang('PublicationDate').'</th>';
echo '<th>'.get_lang('ExpirationDate').'</th>';
echo '<th>'.get_lang('Progress')."</th>";
echo '<th width="300px">'.get_lang('AuthoringOptions')."</th>";
} else {
echo '<th width="50%">'.get_lang('Title').'</th>';
if (!api_is_invitee()) {
echo '<th>'.get_lang('Progress')."</th>";
}
echo '<th>'.get_lang('Actions')."</th>";
}
echo '</tr>';
$max = count($flat_list);
$counter = 0;
$current = 0;
$autolaunch_exists = false;
foreach ($flat_list as $id => $details) {
// Validation when belongs to a session.
@ -318,10 +284,6 @@ foreach ($categories as $item) {
);
}
$dsp_line = '<tr align="center" class="'.$oddclass.'">'.
'<td align="left" valign="top">'.$icon_learnpath.'
<a href="'.$url_start_lp.'">'.$my_title.'</a>'.$session_img.$extra."</td>";
$dsp_desc = '';
$dsp_export = '';
$dsp_build = '';
@ -343,21 +305,15 @@ foreach ($categories as $item) {
}
if ($is_allowed_to_edit) {
$dsp_progress = '<td><center>'.$progress.'</center></td>';
$dsp_progress = '<center>'.$progress.'</center>';
} else {
$dsp_progress = "";
if (!api_is_invitee()) {
$dsp_progress = '<td>'.learnpath::get_progress_bar(
$progress,
'%'
).'</td>';
$dsp_progress = learnpath::get_progress_bar($progress, '%');
}
}
$dsp_edit = '<td class="td_actions">';
$dsp_edit_close = '</td>';
$token_parameter = "&sec_token=$token";
$dsp_edit_lp = null;
$dsp_publish = null;
@ -366,19 +322,16 @@ foreach ($categories as $item) {
$dsp_disk = null;
$copy = null;
$lp_auto_launch_icon = null;
$actionSeriousGame = null;
if ($is_allowed_to_edit) {
// EDIT LP
if ($current_session == $details['lp_session']) {
$dsp_edit_lp = '<a href="lp_controller.php?'.api_get_cidreq(
).'&action=edit&lp_id='.$id.'">'.
Display::return_icon(
'settings.png',
get_lang('CourseSettings'),
'',
ICON_SIZE_SMALL
).'</a>';
$dsp_edit_lp = Display::url(
Display::return_icon('settings.png', get_lang('CourseSettings'), '', ICON_SIZE_SMALL),
"lp_controller.php?" . api_get_cidreq() . "&action=edit&lp_id=$id"
);
} else {
$dsp_edit_lp = Display::return_icon(
'settings_na.png',
@ -391,13 +344,15 @@ foreach ($categories as $item) {
// BUILD
if ($current_session == $details['lp_session']) {
if ($details['lp_type'] == 1 || $details['lp_type'] == 2) {
$dsp_build = '<a href="lp_controller.php?'.api_get_cidreq().'&action=add_item&type=step&lp_id='.$id.'&isStudentView=false">'.
Display::return_icon(
'edit.png',
get_lang('LearnpathEditLearnpath'),
'',
ICON_SIZE_SMALL
).'</a>';
$dsp_build = Display::url(
Display::return_icon('edit.png', get_lang('LearnpathEditLearnpath'), '', ICON_SIZE_SMALL),
'lp_controller.php?' . api_get_cidreq() . '&' . http_build_query([
'action' => 'add_item',
'type' => 'step',
'lp_id' => $id,
'isStudentView' => 'false'
])
);
} else {
$dsp_build = Display::return_icon(
'edit_na.png',
@ -423,26 +378,30 @@ foreach ($categories as $item) {
*/
if (!isset($details['subscribe_users']) || $details['subscribe_users'] != 1) {
if ($details['lp_visibility'] == 0) {
$dsp_visible = "<a href=\"".api_get_self()."?".api_get_cidreq()."&lp_id=$id&action=toggle_visible&new_status=1\">".
Display::return_icon('invisible.png', get_lang('Show'), '', ICON_SIZE_SMALL )."</a>";
$dsp_visible = Display::url(
Display::return_icon('invisible.png', get_lang('Show'), '', ICON_SIZE_SMALL),
api_get_self() . '?' . api_get_cidreq() . "&lp_id=$id&action=toggle_visible&new_status=1"
);
} else {
$dsp_visible = "<a href='".api_get_self()."?".api_get_cidreq()."&lp_id=$id&action=toggle_visible&new_status=0'>".
Display::return_icon('visible.png', get_lang('Hide'), '', ICON_SIZE_SMALL )."</a>";
$dsp_visible = Display::url(
Display::return_icon('visible.png', get_lang('Hide'), '', ICON_SIZE_SMALL),
api_get_self() . '?' . api_get_cidreq() . "&lp_id=$id&action=toggle_visible&new_status=0"
);
}
}
/* PUBLISH COMMAND */
if ($current_session == $details['lp_session']) {
if ($details['lp_published'] == "i") {
$dsp_publish = "<a href=\"".api_get_self(
)."?".api_get_cidreq(
)."&lp_id=$id&action=toggle_publish&new_status=v\">".
$dsp_publish = Display::url(
Display::return_icon(
'lp_publish_na.png',
get_lang('LearnpathPublish'),
'',
ICON_SIZE_SMALL
)."</a>";
),
api_get_self() . '?' . api_get_cidreq() . "&lp_id=$id&action=toggle_publish&new_status=v"
);
} else {
$dsp_publish = "<a href='".api_get_self(
)."?".api_get_cidreq(
@ -452,6 +411,15 @@ foreach ($categories as $item) {
'',
ICON_SIZE_SMALL
)."</a>";
$dsp_publish = Display::url(
Display::return_icon(
'lp_publish.png',
get_lang('LearnpathDoNotPublish'),
'',
ICON_SIZE_SMALL
),
api_get_self() . '?' . api_get_cidreq() . "&lp_id=$id&action=toggle_publish&new_status=i"
);
}
} else {
$dsp_publish = Display::return_icon(
@ -471,36 +439,37 @@ foreach ($categories as $item) {
*/
if ($current_session == $details['lp_session']) {
if ($details['seriousgame_mode'] == 1 && $details['lp_prevent_reinit'] == 1) { //seriousgame mode | next = single
$dsp_reinit = '<a href="lp_controller.php?'.api_get_cidreq(
).'&action=switch_attempt_mode&lp_id='.$id.'">'.
$dsp_reinit = Display::url(
Display::return_icon(
'reload.png',
get_lang('PreventMultipleAttempts'),
'',
ICON_SIZE_SMALL
).
'</a>';
),
"lp_controller.php?" . api_get_cidreq() . "&action=switch_attempt_mode&lp_id=$id"
);
}
if ($details['seriousgame_mode'] == 0 && $details['lp_prevent_reinit'] == 1) { //single mode | next = multiple
$dsp_reinit = '<a href="lp_controller.php?'.api_get_cidreq(
).'&action=switch_attempt_mode&lp_id='.$id.'">'.
$dsp_reinit = Display::url(
Display::return_icon(
'reload_na.png',
get_lang('AllowMultipleAttempts'),
'',
ICON_SIZE_SMALL
).
'</a>';
),
"lp_controller.php?" . api_get_cidreq() . "&action=switch_attempt_mode&lp_id=$id"
);
}
if ($details['seriousgame_mode'] == 0 && $details['lp_prevent_reinit'] == 0) { //multiple mode | next = seriousgame
$dsp_reinit = '<a href="lp_controller.php?'.api_get_cidreq(
).'&action=switch_attempt_mode&lp_id='.$id.'">'.Display::return_icon(
$dsp_reinit = Display::url(
Display::return_icon(
'reload.png',
get_lang('AllowMultipleAttempts'),
'',
ICON_SIZE_SMALL
).
'</a>';
),
"lp_controller.php?" . api_get_cidreq() . "&action=switch_attempt_mode&lp_id=$id"
);
}
} else {
$dsp_reinit = Display::return_icon(
@ -516,44 +485,52 @@ foreach ($categories as $item) {
switch ($details['lp_view_mode']) {
case 'fullscreen':
$dsp_default_view = '<a href="lp_controller.php?'.api_get_cidreq(
).'&action=switch_view_mode&lp_id='.$id.$token_parameter.'">'.
$dsp_default_view = Display::url(
Display::return_icon(
'view_fullscreen.png',
get_lang('ViewModeFullScreen'),
'',
ICON_SIZE_SMALL
).'</a>';
),
'lp_controller.php?' . api_get_cidreq()
. '&action=switch_view_mode&lp_id=' . $id . $token_parameter
);
break;
case 'embedded':
$dsp_default_view = '<a href="lp_controller.php?'.api_get_cidreq(
).'&action=switch_view_mode&lp_id='.$id.$token_parameter.'">'.
$dsp_default_view = Display::url(
Display::return_icon(
'view_left_right.png',
get_lang('ViewModeEmbedded'),
'',
ICON_SIZE_SMALL
).'</a>';
),
'lp_controller.php?' . api_get_cidreq()
. '&action=switch_view_mode&lp_id=' . $id . $token_parameter
);
break;
case 'embedframe':
$dsp_default_view = '<a href="lp_controller.php?'.api_get_cidreq(
).'&action=switch_view_mode&lp_id='.$id.$token_parameter.'">'.
$dsp_default_view = Display::url(
Display::return_icon(
'view_nofullscreen.png',
get_lang('ViewModeEmbedFrame'),
'',
ICON_SIZE_SMALL
).'</a>';
),
'lp_controller.php?' . api_get_cidreq()
. '&action=switch_view_mode&lp_id=' . $id . $token_parameter
);
break;
case 'impress':
$dsp_default_view = '<a href="lp_controller.php?'.api_get_cidreq(
).'&action=switch_view_mode&lp_id='.$id.$token_parameter.'">'.
$dsp_default_view = Display::url(
Display::return_icon(
'window_list_slide.png',
get_lang('ViewModeImpress'),
'',
ICON_SIZE_SMALL
).'</a>';
),
'lp_controller.php?' . api_get_cidreq()
. '&action=switch_view_mode&lp_id=' . $id . $token_parameter
);
break;
}
} else {
@ -577,23 +554,25 @@ foreach ($categories as $item) {
/* DEBUG */
if ($test_mode == 'test' or api_is_platform_admin()) {
if ($details['lp_scorm_debug'] == 1) {
$dsp_debug = '<a href="lp_controller.php?'.api_get_cidreq(
).'&action=switch_scorm_debug&lp_id='.$id.'">'.
$dsp_debug = Display::url(
Display::return_icon(
'bug.png',
get_lang('HideDebug'),
'',
ICON_SIZE_SMALL
).'</a>';
),
"lp_controller.php?" . api_get_cidreq() . "&action=switch_scorm_debug&lp_id=$id"
);
} else {
$dsp_debug = '<a href="lp_controller.php?'.api_get_cidreq(
).'&action=switch_scorm_debug&lp_id='.$id.'">'.
$dsp_debug = Display::url(
Display::return_icon(
'bug_na.png',
get_lang('ShowDebug'),
'',
ICON_SIZE_SMALL
).'</a>';
),
"lp_controller.php?" . api_get_cidreq() . "&action=switch_scorm_debug&lp_id=$id"
);
}
}
@ -657,45 +636,41 @@ foreach ($categories as $item) {
if (api_get_course_setting('enable_lp_auto_launch') == 1) {
if ($details['autolaunch'] == 1 && $autolaunch_exists == false) {
$autolaunch_exists = true;
$lp_auto_launch_icon = '<a href="'.api_get_self(
).'?'.api_get_cidreq(
).'&action=auto_launch&status=0&lp_id='.$id.'">
<img src="../img/launch.png" border="0" title="'.get_lang(
'DisableLPAutoLaunch'
).'" /></a>';
$lp_auto_launch_icon = Display::url(
Display::return_icon('launch.png', get_lang('DisableLPAutoLaunch')),
api_get_self() . '?' . api_get_cidreq() . "&action=auto_launch&status=0&lp_id=$id"
);
} else {
$lp_auto_launch_icon = '<a href="'.api_get_self(
).'?'.api_get_cidreq(
).'&action=auto_launch&status=1&lp_id='.$id.'">
<img src="../img/launch_na.png" border="0" title="'.get_lang(
'EnableLPAutoLaunch'
).'" /></a>';
$lp_auto_launch_icon = Display::url(
Display::return_icon('launch_na.png', get_lang('EnableLPAutoLaunch')),
api_get_self() . '?' . api_get_cidreq() . "&action=auto_launch&status=1&lp_id=$id"
);
}
}
// Export to PDF
$export_icon = ' <a href="'.api_get_self().'?'.api_get_cidreq(
).'&action=export_to_pdf&lp_id='.$id.'">
'.Display::return_icon(
$export_icon = Display::url(
Display::return_icon(
'pdf.png',
get_lang('ExportToPDFOnlyHTMLAndImages'),
'',
ICON_SIZE_SMALL
).'</a>';
),
api_get_self() . '?' . api_get_cidreq() . "&action=export_to_pdf&lp_id=$id"
);
/* Delete */
if ($current_session == $details['lp_session']) {
$dsp_delete = "<a href=\"lp_controller.php?".api_get_cidreq(
)."&action=delete&lp_id=$id\" ".
"onclick=\"javascript: return confirmation('".addslashes(
$name
)."');\">".
$dsp_delete = Display::url(
Display::return_icon(
'delete.png',
get_lang('LearnpathDeleteLearnpath'),
'',
ICON_SIZE_SMALL
).'</a>';
),
'lp_controller.php?' . api_get_cidreq() . "&action=delete&lp_id=$id",
['onclick' => "javascript: return confirmation('" . addslashes($name) . "');"]
);
} else {
$dsp_delete = Display::return_icon(
'delete_na.png',
@ -709,66 +684,66 @@ foreach ($categories as $item) {
// Only active while session mode is not active
if ($current_session == 0) {
if ($details['lp_display_order'] == 1 && $max != 1) {
$dsp_order .= '<a href="lp_controller.php?'.api_get_cidreq(
).'&action=move_lp_down&lp_id='.$id.'">
'.Display::return_icon(
'down.png',
get_lang('MoveDown'),
'',
ICON_SIZE_SMALL
).'</a>';
$dsp_order .= Display::url(
Display::return_icon('down.png', get_lang('MoveDown'), '', ICON_SIZE_SMALL),
"lp_controller.php?" . api_get_cidreq() . "&action=move_lp_down&lp_id=$id"
);
} elseif ($current == $max - 1 && $max != 1) {
$dsp_order .= '<a href="lp_controller.php?'.api_get_cidreq(
).'&action=move_lp_up&lp_id='.$id.'">
'.Display::return_icon(
'up.png',
get_lang('MoveUp'),
'',
ICON_SIZE_SMALL
).'</a>';
$dsp_order .= Display::url(
Display::return_icon('up.png', get_lang('MoveUp'), '', ICON_SIZE_SMALL),
"lp_controller.php?" . api_get_cidreq() . "&action=move_lp_up&lp_id=$id"
);
} elseif ($max == 1) {
$dsp_order = '';
} else {
$dsp_order .= '<a href="lp_controller.php?'.api_get_cidreq(
).'&action=move_lp_down&lp_id='.$id.'">'.
Display::return_icon(
'down.png',
get_lang('MoveDown'),
'',
ICON_SIZE_SMALL
).'</a>';
$dsp_order .= '<a href="lp_controller.php?'.api_get_cidreq(
).'&action=move_lp_up&lp_id='.$id.'">'.
Display::return_icon(
'up.png',
get_lang('MoveUp'),
'',
ICON_SIZE_SMALL
).'</a>';
$dsp_order .= Display::url(
Display::return_icon('down.png', get_lang('MoveDown'), '', ICON_SIZE_SMALL),
"lp_controller.php?" . api_get_cidreq() . "&action=move_lp_down&lp_id=$id"
);
$dsp_order .= Display::url(
Display::return_icon('up.png', get_lang('MoveUp'), '', ICON_SIZE_SMALL),
"lp_controller.php?" . api_get_cidreq() . "&action=move_lp_up&lp_id=$id"
);
}
}
if ($is_allowed_to_edit) {
$start_time = Display::tag(
'td',
Display::div($start_time, array('class' => 'small'))
);
$end_time = Display::tag(
'td',
Display::div($end_time, array('class' => 'small'))
);
$start_time = $start_time;
$end_time = $end_time;
} else {
$start_time = $end_time = '';
}
if (api_get_setting('gamification_mode') == 'true') {
if ($details['seriousgame_mode'] == 0) {
$actionSeriousGame = Display::toolbarButton(
null,
api_get_self() . '?' . api_get_cidreq() . "&lp_id=$id&action=toggle_seriousgame",
'trophy',
'default',
[
'class' => 'btn-xs',
'title' => get_lang('EnableGamificationMode')
]
);
} else {
$actionSeriousGame = Display::toolbarButton(
null,
api_get_self() . '?' . api_get_cidreq() . "&lp_id=$id&action=toggle_seriousgame",
'trophy',
'warning',
[
'class' => 'btn-xs active',
'title' => get_lang('DisableGamificationMode')
]
);
}
}
} else {
// Student
$export_icon = ' <a href="'.api_get_self().'?'.api_get_cidreq(
).'&action=export_to_pdf&lp_id='.$id.'">'.
Display::return_icon(
'pdf.png',
get_lang('ExportToPDF'),
'',
ICON_SIZE_SMALL
).'</a>';
$export_icon = Display::url(
Display::return_icon('pdf.png', get_lang('ExportToPDF'), '', ICON_SIZE_SMALL),
api_get_self() . '?' . api_get_cidreq() . "&action=export_to_pdf&lp_id=$id"
);
}
$hideScormExportLink = api_get_setting('hide_scorm_export_link');
@ -786,50 +761,60 @@ foreach ($categories as $item) {
$export_icon = null;
}
echo
$dsp_line.
$start_time.
$end_time.
$dsp_progress.
$dsp_desc.
$dsp_export.
$dsp_edit.
$dsp_build.
$dsp_edit_lp.
$dsp_visible.
$dsp_publish.
$subscribeUsers.
$dsp_reinit.
$dsp_default_view.
$dsp_debug.
$dsp_disk.
$copy.
$lp_auto_launch_icon.
$export_icon.
$dsp_delete.
$dsp_order.
$dsp_edit_close;
$lp_showed = true;
echo "</tr>";
$listData[] = [
'learnpath_icon' => $icon_learnpath,
'url_start' => $url_start_lp,
'title' => $my_title,
'session_image' => $session_img,
'extra' => $extra,
'start_time' => $start_time,
'end_time' => $end_time,
'dsp_progress' => $dsp_progress,
'action_build' => $dsp_build,
'action_edit' => $dsp_edit_lp,
'action_visible' => $dsp_visible,
'action_publish' => $dsp_publish,
'action_reinit' => $dsp_reinit,
'action_default_view' => $dsp_default_view,
'action_debug' => $dsp_debug,
'action_export' => $dsp_disk,
'action_copy' => $copy,
'action_auto_launch' => $lp_auto_launch_icon,
'action_pdf' => $export_icon,
'action_delete' => $dsp_delete,
'action_order' => $dsp_order,
'action_serious_game' => $actionSeriousGame,
'action_subscribe_users' => $subscribeUsers
];
$lpIsShown = true;
//counter for number of elements treated
$current++;
} // end foreach ($flat_list)
echo "</table>";
}
}
if ($is_allowed_to_edit && $lp_showed == false) {
echo '<div id="no-data-view">';
echo '<h2>'.get_lang('LearningPaths').'</h2>';
echo Display::return_icon('scorms.png', '', array(), 64);
echo '<div class="controls">';
echo Display::url(get_lang('LearnpathAddLearnpath'), api_get_self().'?'.api_get_cidreq().'&action=add_lp', array('class' => 'btn'));
echo '</div>';
echo '</div>';
$data[] = [
'category' => $item,
'lp_list' => $listData
];
}
$template = new Template($nameTools);
$template->assign('is_allowed_to_edit', $is_allowed_to_edit);
$template->assign('is_invitee', api_is_invitee());
$template->assign('actions', $actions);
$template->assign('message', $message);
$template->assign('introduction_section', $introductionSection);
$template->assign('data', $data);
$template->assign('lp_is_shown', $lpIsShown);
$content = $template->fetch('default/learnpath/list.tpl');
$template->assign('content', $content);
$template->display_one_col_template();
$course_info = api_get_course_info();
learnpath::generate_learning_path_folder($course_info);
@ -837,4 +822,3 @@ learnpath::generate_learning_path_folder($course_info);
Session::erase('oLP');
Session::erase('lpobject');
DocumentManager::removeGeneratedAudioTempFile();
Display::display_footer();

@ -12,7 +12,6 @@
* @author Isthvan Mandak, several new features
* @author Roan Embrechts, code improvements and refactoring
*/
use \ChamiloSession as Session;
$use_anonymous = true;
@ -37,7 +36,8 @@ $lp_id = intval($_GET['lp_id']);
// Check if the learning path is visible for student - (LP requisites)
if (!api_is_platform_admin()) {
if (!api_is_allowed_to_edit(null, true) &&
if (
!api_is_allowed_to_edit(null, true) &&
!learnpath::is_lp_visible_for_student($lp_id, api_get_user_id())
) {
api_not_allowed(true);
@ -77,7 +77,8 @@ $user_id = api_get_user_id();
$platform_theme = api_get_setting('stylesheets'); // Platform's css.
$my_style = $platform_theme;
$htmlHeadXtra[] = '<script src="'.api_get_path(WEB_LIBRARY_PATH).'javascript/jquery.lp_minipanel.js" type="text/javascript" language="javascript"></script>';
$htmlHeadXtra[] = '<script src="' . api_get_path(WEB_LIBRARY_PATH) .
'javascript/jquery.lp_minipanel.js" type="text/javascript" language="javascript"></script>';
$htmlHeadXtra[] = '<script>
$(document).ready(function() {
$("div#log_content_cleaner").bind("click", function() {
@ -87,7 +88,6 @@ $(document).ready(function() {
var chamilo_xajax_handler = window.oxajax;
</script>';
if ($_SESSION['oLP']->mode == 'embedframe' || $_SESSION['oLP']->get_hide_toc_frame() == 1) {
$htmlHeadXtra[] = 'hello';
}
@ -128,7 +128,6 @@ $htmlHeadXtra[] = '<script type="text/javascript" src="js/storageapi.js"></scrip
/**
* Get a link to the corresponding document.
*/
if ($debug) {
error_log(" src: $src ");
error_log(" lp_type: $lp_type ");
@ -155,10 +154,13 @@ if (!isset($src)) {
// Prevents FF 3.6 + Adobe Reader 9 bug see BT#794 when calling a pdf file in a LP.
$file_info = parse_url($src);
$file_info = pathinfo($file_info['path']);
if (isset($file_info['extension']) &&
if (
isset($file_info['extension']) &&
api_strtolower(substr($file_info['extension'], 0, 3) == 'pdf')
) {
$src = api_get_path(WEB_CODE_PATH).'newscorm/lp_view_item.php?lp_item_id='.$lp_item_id.'&'.api_get_cidreq();
$src = api_get_path(WEB_CODE_PATH)
. 'newscorm/lp_view_item.php?lp_item_id=' . $lp_item_id
. '&' . api_get_cidreq();
}
$_SESSION['oLP']->start_current_item(); // starts time counter manually if asset
} else {
@ -180,7 +182,8 @@ if (!isset($src)) {
case 3:
// aicc
$_SESSION['oLP']->stop_previous_item(); // save status manually if asset
$htmlHeadXtra[] = '<script src="'.$_SESSION['oLP']->get_js_lib().'" type="text/javascript" language="javascript"></script>';
$htmlHeadXtra[] = '<script src="' . $_SESSION['oLP']->get_js_lib()
. '" type="text/javascript" language="javascript"></script>';
$prereq_check = $_SESSION['oLP']->prerequisites_match($lp_item_id);
if ($prereq_check === true) {
$src = $_SESSION['oLP']->get_link('http', $lp_item_id, $get_toc_list);
@ -204,7 +207,8 @@ if ($debug) {
error_log('$_GET[lp_item_id]: ' . intval($_GET['lp_item_id']));
}
if (!empty($_REQUEST['exeId']) &&
if (
!empty($_REQUEST['exeId']) &&
isset($lp_id) &&
isset($_GET['lp_item_id'])
) {
@ -218,7 +222,8 @@ if (!empty($_REQUEST['exeId']) &&
$safe_id = $lp_id;
$safe_exe_id = intval($_REQUEST['exeId']);
if ($safe_id == strval(intval($safe_id)) &&
if (
$safe_id == strval(intval($safe_id)) &&
$safe_item_id == strval(intval($safe_item_id))
) {
$sql = 'SELECT start_date, exe_date, exe_result, exe_weighting
@ -257,7 +262,10 @@ if (!empty($_REQUEST['exeId']) &&
total_time = $mytime
WHERE id='" . $lp_item_view_id . "' AND c_id = $course_id ";
if ($debug) error_log($sql);
if ($debug) {
error_log($sql);
}
Database::query($sql);
$sql = "UPDATE $TBL_TRACK_EXERCICES SET
@ -271,7 +279,9 @@ if (!empty($_REQUEST['exeId']) &&
} else {
$src = api_get_path(WEB_CODE_PATH) . 'exercice/result.php?origin=learnpath&id=' . $safe_exe_id;
if ($debug) error_log('Calling URL: '.$src);
if ($debug) {
error_log('Calling URL: ' . $src);
}
}
$autostart = 'false';
}
@ -290,8 +300,6 @@ if ($_SESSION['oLP']->mode == 'fullscreen') {
}
// Not in fullscreen mode.
Display::display_reduced_header($nameTools);
// Check if audio recorder needs to be in studentview.
if (isset($_SESSION['status']) && $_SESSION['status'][$course_code] == 5) {
$audio_recorder_studentview = true;
@ -342,226 +350,77 @@ if (Database::num_rows($res_media) > 0) {
}
}
echo '<div id="learning_path_main" style="width:100%;height:100%;">';
$is_allowed_to_edit = api_is_allowed_to_edit(false, true, true, false);
$breadcrumb = null;
if ($is_allowed_to_edit) {
echo '<div class="row">';
echo '<div id="learning_path_breadcrumb_zone" class="col-md-12">';
global $interbreadcrumb;
$interbreadcrumb[] = array('url' => 'lp_controller.php?action=list&isStudentView=false', 'name' => get_lang('LearningPaths'));
$interbreadcrumb[] = array('url' => api_get_self()."?action=add_item&type=step&lp_id=".$_SESSION['oLP']->lp_id."&isStudentView=false", 'name' => $_SESSION['oLP']->get_name());
$interbreadcrumb[] = array('url' => '#', 'name' => get_lang('Preview'));
echo return_breadcrumb($interbreadcrumb, null, null);
echo '</div>';
echo '</div>';
}
/* button hiden left zone */
echo '<a id="touch-button" class="hidden-touch" href="#"></a>';
/* Fin left zone */
echo '<div class="container-fluid"><div class="row">';
echo '<div id="learning_path_left_zone" class="sidebar-scorm"> ';
echo '<div id="scorm-info" class="panel panel-default">';
echo '<div class="panel-heading">
<a id="ui-option">
<i id="icon-down"class="fa fa-chevron-down hidden"></i>
<i id="icon-up" class="fa fa-chevron-up"></i>
</a></div>';
?>
<!-- end header -->
<!-- Author image preview -->
<div id="panel-scorm" class="panel-body">
<?php
$interbreadcrumb[] = array(
'url' => 'lp_controller.php?action=list&isStudentView=false',
'name' => get_lang('LearningPaths')
);
$interbreadcrumb[] = array(
'url' => api_get_self() . "?action=add_item&type=step&lp_id={$_SESSION['oLP']->lp_id}&isStudentView=false",
'name' => $_SESSION['oLP']->get_name()
);
$interbreadcrumb[] = array(
'url' => '#',
'name' => get_lang('Preview')
);
$breadcrumb = return_breadcrumb($interbreadcrumb, null, null);
}
// Return to course home.
if ($is_allowed_to_edit) {
$url = 'lp_controller.php?isStudentView=false&action=return_to_course_homepage&' . api_get_cidreq();
$buttonHomeUrl = 'lp_controller.php?' . api_get_cidreq() . '&' . http_build_query([
'isStudentView' => 'false',
'action' => 'return_to_course_homepage'
]);
} else {
$url = 'lp_controller.php?action=return_to_course_homepage&' . api_get_cidreq();
$buttonHomeUrl = 'lp_controller.php?' . api_get_cidreq() . '&' . http_build_query([
'action' => 'return_to_course_homepage'
]);
}
$iconHome='<i class="fa fa-home"></i>';
$name = get_lang('CourseHomepageLink');
$buttonHomeText = get_lang('CourseHomepageLink');
// Return to lp list
if (api_get_course_setting('lp_return_link') == 1) {
$url .= '&redirectTo=lp_list';
$name = get_lang('LearningPathList');
}
echo Display::url(
$iconHome.' '.$name,
$url,
array(
'class' => 'btn btn-success btn-block',
'target' => '_self',
'onclick' => 'javascript: window.parent.API.save_asset();'
)
);
?>
<div class="image-avatar">
<?php
if ($_SESSION['oLP']->get_preview_image() != '') {
$picture = getimagesize(api_get_path(SYS_COURSE_PATH).api_get_course_path().'/upload/learning_path/images/'.$_SESSION['oLP']->get_preview_image());
$style = null;
if ($picture['1'] < 96) {
$style = ' style="padding-top:'.((94 -$picture['1'])/2).'px;" ';
}
$size = ($picture['0'] > 104 && $picture['1'] > 96 )? ' width="104" height="96" ': $style;
$my_path = $_SESSION['oLP']->get_preview_image_path();
echo '<img src="'.$my_path.'">';
} else {
echo Display :: display_icon('unknown_250_100.jpg');
}
?>
</div>
<div id="lp_navigation_elem" class="navegation-bar">
<?php echo $navigation_bar; ?>
<div id="progress_bar">
<?php echo $progress_bar; ?>
</div>
</div>
<div class="description-autor">
<?php echo $_SESSION['oLP']->get_author(); ?>
</div>
<?php
if ($show_audioplayer) {
echo '<div id="lp_media_file">';
echo $mediaplayer;
echo '</div>';
}
?>
</div>
</div>
<!-- TOC layout -->
<div id="toc_id" name="toc_name">
<div id="learning_path_toc" class="scorm-list">
<?php echo $_SESSION['oLP']->get_html_toc($get_toc_list); ?>
</div>
</div>
<!-- end TOC layout -->
</div>
<!-- end left zone
<div id="hide_bar" class="scorm-toggle" style="display:inline-block; width: 25px; height: 1000px;"></div>-->
<!-- right zone -->
<div id="learning_path_right_zone" style="height:100%" class="content-scorm">
<?php
// hub 26-05-2010 Fullscreen or not fullscreen
$height = '100%';
if ($_SESSION['oLP']->mode == 'fullscreen') {
echo '<iframe id="content_id_blank" name="content_name_blank" src="blank.php" border="0" frameborder="0" style="width:100%;height:'.$height.'" ></iframe>';
} else {
echo '<iframe id="content_id" name="content_name" src="'.$src.'" border="0" frameborder="0" style="display: block; width:100%;height:'.$height.'"></iframe>';
$buttonHomeUrl .= '&redirectTo=lp_list';
$buttonHomeText = get_lang('LearningPathList');
}
?>
</div>
<!-- end right Zone -->
</div>
<?php echo $navigation_bar_bottom; ?>
</div></div>
<script>
// Resize right and left pane to full height (HUB 20-05-2010).
function updateContentHeight() {
document.body.style.overflow = 'hidden';
var IE = window.navigator.appName.match(/microsoft/i);
/* Identified new height */
var heightControl = $('#control-bottom').height();
var heightBreadcrumb = ($('#learning_path_breadcrumb_zone').height())? $('#learning_path_breadcrumb_zone').height() : 0 ;
var heightScormInfo = $('#scorm-info').height();
var heightTop = heightScormInfo + 100;
//heightTop = (heightTop > 300)? heightTop : 300;
var innerHeight = $(window).height();
if(innerHeight<=640){
$('#inner_lp_toc').css('height', innerHeight - heightTop + "px");
$('#content_id').css('height', innerHeight - heightControl + "px");
}else{
$('#inner_lp_toc').css('height', innerHeight - heightBreadcrumb - heightTop + "px");
$('#content_id').css('height', innerHeight - heightControl + "px");
}
//var innerHeight = (IE) ? document.body.clientHeight : window.innerHeight ;
// Loads the glossary library.
<?php
$glossaryExtraTools = api_get_setting('show_glossary_in_extra_tools');
if (in_array($glossaryExtraTools, array('true', 'lp', 'exercise_and_lp'))) {
if (api_get_setting('show_glossary_in_documents') == 'ismanual') {
?>
$.frameReady(function(){
// $("<div>I am a div courses</div>").prependTo("body");
}, "top.content_name",
{ load: [
{ type:"script", id:"_fr1", src:"<?php echo api_get_jquery_web_path(); ?>"},
{ type:"script", id:"_fr4", src:"<?php echo api_get_jquery_ui_js_web_path(); ?>"},
{ type:"stylesheet", id:"_fr5", src:"<?php echo api_get_jquery_ui_css_web_path(); ?>"},
{ type:"script", id:"_fr2", src:"<?php echo api_get_path(WEB_LIBRARY_PATH); ?>javascript/jquery.highlight.js"}
] }
);
<?php } elseif (api_get_setting('show_glossary_in_documents') == 'isautomatic') { ?>
$.frameReady(function(){
// $("<div>I am a div courses</div>").prependTo("body");
},
"top.content_name",
{
load: [
{ type:"script", id:"_fr1", src:"<?php echo api_get_jquery_web_path(); ?>"},
{ type:"script", id:"_fr4", src:"<?php echo api_get_jquery_ui_js_web_path(); ?>"},
{ type:"stylesheet", id:"_fr5", src:"<?php echo api_get_jquery_ui_css_web_path(); ?>"},
{ type:"script", id:"_fr2", src:"<?php echo api_get_path(WEB_LIBRARY_PATH); ?>javascript/jquery.highlight.js"}
]}
$template = new Template('title', false, false, true, true, false);
$template->assign('glossary_extra_tools', api_get_setting('show_glossary_in_extra_tools'));
$template->assign(
'glossary_tool_availables',
['true', 'lp', 'exercise_and_lp']
);
<?php }
}
?>
}
$(document).ready(function() {
updateContentHeight();
$('#touch-button').children().click(function(){
updateContentHeight();
});
$(window).resize(function() {
updateContentHeight();
});
});
window.onload = updateContentHeight();
window.onresize = updateContentHeight();
$(document).ready(function(){
$template->assign('show_glossary_in_documents', api_get_setting('show_glossary_in_documents'));
$template->assign('jquery_web_path', api_get_jquery_web_path());
$template->assign('jquery_ui_js_web_path', api_get_jquery_ui_js_web_path());
$template->assign('jquery_ui_css_web_path', api_get_jquery_ui_css_web_path());
$template->assign('is_allowed_to_edit', $is_allowed_to_edit);
$template->assign('gamification_mode', api_get_setting('gamification_mode'));
$template->assign('breadcrumb', $breadcrumb);
$template->assign('button_home_url', $buttonHomeUrl);
$template->assign('button_home_text', $buttonHomeText);
$template->assign('navigation_bar', $navigation_bar);
$template->assign('progress_bar', $progress_bar);
$template->assign('oLP', $_SESSION['oLP']);
$template->assign('show_audio_player', $show_audioplayer);
$template->assign('media_player', $mediaplayer);
$template->assign('toc_list', $get_toc_list);
$template->assign('iframe_src', $src);
$template->assign('navigation_bar_bottom', $navigation_bar_bottom);
$content = $template->fetch('default/learnpath/view.tpl');
$template->assign('content', $content);
$template->display_no_layout_template();
$("#icon-down").click(function(){
$("#icon-up").removeClass("hidden");
$(this).addClass("hidden");
$('#panel-scorm').slideDown("slow",function(){
updateContentHeight();
});
});
$("#icon-up").click(function(){
$("#icon-down").removeClass("hidden");
$(this).addClass("hidden");
$('#panel-scorm').slideUp("slow",function(){
updateContentHeight();
});
});
});
</script>
<?php
// Restore a global setting.
$_setting['show_navigation_menu'] = $save_setting;

@ -1234,7 +1234,6 @@ function update_toc(update_action, update_id, change_ids) {
change_ids = 'yes';
}
var myelem = $("#toc_"+update_id);
var myelemimg = $("#toc_img_"+update_id);
logit_lms('update_toc("'+update_action+'", '+update_id+')',2);
if (update_id != 0) {
@ -1242,13 +1241,11 @@ function update_toc(update_action, update_id, change_ids) {
if (update_action == "unhighlight" || update_action == "highlight") {
if (update_action == "unhighlight") {
myelem.removeClass('scorm_highlight');
//myelem.addClass('scorm_item_normal');
} else {
if (change_ids=='yes') {
olms.lms_next_item = update_id;
olms.lms_previous_item = update_id;
}
//myelem.removeClass('scorm_item_normal');
myelem.addClass('scorm_highlight');
}
} else {

@ -331,9 +331,9 @@ $(function() {
}
// Fixes buttons to the new btn class.
if (!$('#button').hasClass('btn')) {
/* if (!$('#button').hasClass('btn')) {
$("button").addClass('btn');
}
} */
// Dropdown effect.
$('.dropdown-toggle').dropdown();

@ -0,0 +1,134 @@
<script>
function confirmation(name) {
if (confirm(" {{ "AreYouSureToDelete"|get_lang }} name ?")) {
return true;
} else {
return false;
}
}
</script>
{{ introduction_section }}
{% for lp_data in data %}
<h3 class="page-header">
{{ lp_data.category.getName() }}
{% if lp_data.category.getId() > 0 and is_allowed_to_edit %}
<a href="{{ 'lp_controller.php?' ~ web_cid_query ~ '&action=add_lp_category&id=' ~ lp_data.category.getId() }}" title="{{ "Edit"|get_lang }}">
<img src="{{ "edit.png"|icon }}" alt="{{ "Edit"|get_lang }}">
</a>
{% if loop.index0 == 1 %}
<a href="#">
<img src="{{ "up_na.png"|icon }}" alt="{{ "Move"|get_lang }}">
</a>
{% else %}
<a href="{{ 'lp_controller.php?' ~ web_cid_query ~ '&action=move_up_category&id=' ~ lp_data.category.getId() }}" title="{{ "Move"|get_lang }}">
<img src="{{ "up.png"|icon }}" alt="{{ "Move"|get_lang }}">
</a>
{% endif %}
{% if (data|length - 1) == loop.index0 %}
<a href="#">
<img src="{{ "down_na.png"|icon }}" alt="{{ "Move"|get_lang }}">
</a>
{% else %}
<a href="{{ 'lp_controller.php?' ~ web_cid_query ~ '&action=move_down_category&id=' ~ lp_data.category.getId() }}" title="{{ "Move"|get_lang }}">
<img src="{{ "down.png"|icon }}" alt="{{ "Move"|get_lang }}">
</a>
{% endif %}
<a href="{{ 'lp_controller.php?' ~ web_cid_query ~ '&action=delete_lp_category&id=' ~ lp_data.category.getId() }}" title="{{ "Delete"|get_lang }}">
<img src="{{ "delete.png"|icon }}" alt="{{ "Delete"|get_lang }}">
</a>
{% endif %}
</h3>
{% if lp_data.lp_list %}
<div class="table-responsive">
<table class="table table-hover table-striped">
<thead>
<tr>
<th>{{ "Title"|get_lang }}</th>
{% if is_allowed_to_edit %}
<th>{{ "PublicationDate"|get_lang }}</th>
<th>{{ "ExpirationDate"|get_lang }}</th>
<th>{{ "Progress"|get_lang }}</th>
<th>{{ "AuthoringOptions"|get_lang }}</th>
{% else %}
{% if not is_invitee %}
<th>{{ "Progress"|get_lang }}</th>
{% endif %}
<th>{{ "Actions"|get_lang }}</th>
{% endif %}
</tr>
</thead>
<tbody>
{% for row in lp_data.lp_list %}
<tr>
<td>
{{ row.learnpath_icon }}
<a href="{{ row.url_start }}">
{{ row.title }}
{{ row.session_image }}
{{ row.extra }}
</a>
</td>
{% if is_allowed_to_edit %}
<td>
{% if row.start_time %}
<span class="small">{{ row.start_time }}</span>
{% endif %}
</td>
<td>
<span class="small">{{ row.end_time }}</span>
</td>
<td>
{{ row.dsp_progress }}
</td>
{% else %}
{% if not is_invitee %}
<td>
{{ row.dsp_progress }}
</td>
{% endif %}
{% endif %}
<td>
{{ row.action_build }}
{{ row.action_edit }}
{{ row.action_visible }}
{{ row.action_publish }}
{{ row.action_subscribe_users }}
{{ row.action_serious_game }}
{{ row.action_reinit }}
{{ row.action_default_view }}
{{ row.action_debug }}
{{ row.action_export }}
{{ row.action_copy }}
{{ row.action_auto_launch }}
{{ row.action_pdf }}
{{ row.action_delete }}
{{ row.action_order }}
</td>
</tr>
{% endfor %}
</tbody>
</table>
</div>
{% endif %}
{% endfor %}
{% if is_allowed_to_edit and not lp_is_shown %}
<div id="no-data-view">
<h2>{{ "LearningPaths"|get_lang }}</h2>
<img src="{{ "scorms.png"|icon(64) }}">
<div class="controls">
<a href="{{ web_self ~ "?" ~ web_cid_query ~ "&action=add_lp" }}" class="btn btn-default">
{{ "LearnpathAddLearnpath"|get_lang }}
</a>
</div>
</div>
{% endif %}

@ -0,0 +1,201 @@
<div id="learning_path_main" style="width:100%; height: 100%;">
{% if is_allowed_to_edit %}
<div class="row">
<div id="learning_path_breadcrumb_zone" class="col-md-12">
{{ breadcrumb }}
</div>
</div>
{% endif %}
<button id="touch-button" class="btn btn-primary"><i class="fa fa-bars"></i></button>
<div class="container-fluid">
<div class="row">
<div id="learning_path_left_zone" class="sidebar-scorm">
{% if gamification_mode == 1 %}
<div class="row">
<div class="col-xs-8">
{% set lp_stars = oLP.getCalculateStars() %}
{% if lp_stars > 0%}
{% for i in 1..lp_stars %}
<i class="fa fa-star fa-2x"></i>
{% endfor %}
{% endif %}
{% if lp_stars < 4 %}
{% for i in 1..4 - lp_stars %}
<i class="fa fa-star-o fa-2x"></i>
{% endfor %}
{% endif %}
</div>
<div class="col-xs-4 text-right">
{{ "XPoints"|get_lang|format(oLP.getCalculateScore()) }}
</div>
</div>
{% else %}
<div id="scorm-info" class="panel panel-default">
<div class="panel-heading">
<a id="ui-option">
<i id="icon-down" class="fa fa-chevron-down hidden"></i>
<i id="icon-up" class="fa fa-chevron-up"></i>
</a>
</div>
{# Author image preview #}
<div id="panel-scorm" class="panel-body">
<a href="{{ button_home_url }}" class="btn btn-success btn-block" target="_self" onclick="javascript: window.parent.API.save_asset();">
<i class="fa fa-home"></i> {{ button_home_text }}
</a>
<div class="image-avatar">
{% if oLP.get_preview_image() %}
<img src="{{ oLP.get_preview_image_path() }}" width="104" height="96">
{% else %}
<img src="{{ "unknown_250_100.jpg"|icon }}" width="104" height="96">
{% endif %}
</div>
<div id="lp_navigation_elem" class="navegation-bar">
{{ navigation_bar }}
<div id="progress_bar">
{{ progress_bar }}
</div>
</div>
<div class="description-autor">
{{ oLP.get_author() }}
</div>
{% if show_audio_player %}
<div id="lp_media_file">
{{ media_player }}
</div>
{% endif %}
</div>
</div>
{% endif %}
{# TOC layout #}
<div id="toc_id" name="toc_name">
<div id="learning_path_toc" class="scorm-list">
{{ oLP.get_html_toc(toc_list) }}
</div>
</div>
{# end TOC layout #}
</div>
{# end left zone #}
{# <div id="hide_bar" class="scorm-toggle" style="display:inline-block; width: 25px; height: 1000px;"></div> #}
{# right zone #}
<div id="learning_path_right_zone" style="height:100%" class="content-scorm">
{% if oLP.mode == 'fullscreen' %}
<iframe id="content_id_blank" name="content_name_blank" src="blank.php" border="0" frameborder="0" style="width: 100%; height: 100%" ></iframe>
{% else %}
<iframe id="content_id" name="content_name" src="{{ iframe_src }}" border="0" frameborder="0" style="display: block; width: 100%; height: 100%"></iframe>
{% endif %}
</div>
{# end right Zone #}
{{ navigation_bar_bottom }}
</div>
</div>
</div>
<script>
// Resize right and left pane to full height (HUB 20-05-2010).
var updateContentHeight = function () {
document.body.style.overflow = 'hidden';
var IE = window.navigator.appName.match(/microsoft/i);
/* Identified new height */
var heightControl = $('#control-bottom').height();
var heightBreadcrumb = ($('#learning_path_breadcrumb_zone').height()) ? $('#learning_path_breadcrumb_zone').height() : 0;
var heightScormInfo = $('#scorm-info').height();
var heightTop = heightScormInfo + 100;
//heightTop = (heightTop > 300)? heightTop : 300;
var innerHeight = $(window).height();
if (innerHeight <= 640) {
$('#inner_lp_toc').css('height', innerHeight - heightTop + "px");
$('#content_id').css('height', innerHeight - heightControl + "px");
} else {
$('#inner_lp_toc').css('height', innerHeight - heightBreadcrumb - heightTop + "px");
$('#content_id').css('height', innerHeight - heightControl + "px");
}
//var innerHeight = (IE) ? document.body.clientHeight : window.innerHeight ;
// Loads the glossary library.
{% if glossary_extra_tools in glossary_tool_availables %}
{% if show_glossary_in_documents == 'ismanual' %}
$.frameReady(
function(){
// $("<div>I am a div courses</div>").prependTo("body");
},
"top.content_name",
{
load: [
{ type:"script", id:"_fr1", src:"{{ jquery_web_path }}"},
{ type:"script", id:"_fr4", src:"{{ jquery_ui_js_web_path }}"},
{ type:"stylesheet", id:"_fr5", src:"{{ jquery_ui_css_web_path }}"},
{ type:"script", id:"_fr2", src:"{{ _p.web_lib }}javascript/jquery.highlight.js"}
]
}
);
{% elseif show_glossary_in_documents == 'isautomatic' %}
$.frameReady(
function(){
// $("<div>I am a div courses</div>").prependTo("body");
},
"top.content_name",
{
load: [
{ type:"script", id:"_fr1", src:"{{ jquery_web_path }}"},
{ type:"script", id:"_fr4", src:"{{ jquery_ui_js_web_path }}"},
{ type:"stylesheet", id:"_fr5", src:"{{ jquery_ui_css_web_path }}"},
{ type:"script", id:"_fr2", src:"{{ _p.web_lib }}javascript/jquery.highlight.js"}
]
}
);
{% endif %}
{% endif %}
};
$(document).ready(function() {
updateContentHeight();
$('#touch-button').children().click(function(){
updateContentHeight();
});
$(window).resize(function() {
updateContentHeight();
});
});
window.onload = updateContentHeight();
window.onresize = updateContentHeight();
$(document).ready(function(){
$("#icon-down").click(function(){
$("#icon-up").removeClass("hidden");
$(this).addClass("hidden");
$('#panel-scorm').slideDown("slow",function(){
updateContentHeight();
});
});
$("#icon-up").click(function(){
$("#icon-down").removeClass("hidden");
$(this).addClass("hidden");
$('#panel-scorm').slideUp("slow",function(){
updateContentHeight();
});
});
});
</script>

@ -134,7 +134,7 @@ class CkEditor extends Editor
foreach ($templates as $template) {
$image = $template['image'];
$image = !empty($image) ? $image : 'empty.gif';
$image = api_get_path(WEB_PATH).'home/default_platform_document/template_thumb/'.$image;
$image = api_get_path(WEB_APP_PATH).'home/default_platform_document/template_thumb/'.$image;
/*$image = $this->urlGenerator->generate(
'get_document_template_action',

@ -0,0 +1,55 @@
<?php
namespace Chamilo\CoreBundle\Migrations\Schema\V110;
use Chamilo\CoreBundle\Migrations\AbstractMigrationChamilo;
use Doctrine\DBAL\Schema\Schema;
/**
* Class Version20150527120703
* LP autolunch -> autolaunch
* @package Chamilo\CoreBundle\Migrations\Schema\V110
*/
class Version20150527101600 extends AbstractMigrationChamilo
{
/**
* @param Schema $schema
*/
public function up(Schema $schema)
{
$this->addSettingCurrent(
'gamification_mode',
'',
'radio',
'Platform',
0,
'GamificationModeTitle',
'GamificationModeComment',
null,
'',
1,
true,
false,
[
[
'value' => 1,
'text' => 'Yes'
],
[
'value' => 0,
'text' => 'No'
]
]
);
}
/**
* @param Schema $schema
*/
public function down(Schema $schema)
{
$this->addSql("DELETE FROM settings_options WHERE variable = 'gamification_mode'");
$this->addSql("DELETE FROM settings_current WHERE variable = 'gamification_mode'");
}
}
Loading…
Cancel
Save