From: Charles Holbrow Date: Thu, 18 Apr 2013 22:01:32 +0000 (-0400) Subject: option to prevent changing of school string field when adding a course. Code is comme... X-Git-Tag: release-20150131~442^2~2 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=b7bab4c6ac552691015c4ff7ad5f0bf119d342a5;p=oweals%2Fkarmaworld.git option to prevent changing of school string field when adding a course. Code is commented out -- need to add functionality to change it once you have set it -- and functionality to prevent adding a course until you have chosen a shool #103 --- diff --git a/karmaworld/assets/js/lightbox-add-course.js b/karmaworld/assets/js/lightbox-add-course.js index 9cd9128..1639f2b 100644 --- a/karmaworld/assets/js/lightbox-add-course.js +++ b/karmaworld/assets/js/lightbox-add-course.js @@ -59,6 +59,9 @@ $(function() { console.log(ui.item.value); console.log("name"); console.log(ui.item.label); + // don't let the user edit the field anymore + //$('#str_school').attr('readonly', true); + // set the school id as the value of the hidden field $('#id_school').val(ui.item.real_value); // set the School name as the textbox field