Select Git revision
plugins.php
Forked from
Stud.IP / Stud.IP
Source project has a limited visibility.
Code owners
Assign users and groups as approvers for specific file changes. Learn more.
TandemPlugin.js 984 B
STUDIP.TandemPlugin = {
addMotherLanguage: function() {
var template = jQuery('#motherLanguageRowTemplate');
var tbody = jQuery(template).parent();
var new_row = jQuery(template).clone();
new_row.id = null;
var status_input = jQuery(new_row).find('input.EntryStatus')[0];
if(!status_input) { console.log('no status input!'); }
jQuery(status_input).val('K');
jQuery(new_row).removeAttr('style');
jQuery(new_row).appendTo(tbody);
},
deleteMotherLanguage: function(caller, language_id) {
var row = jQuery(caller).parent().parent();
if(language_id != null) {
jQuery(row).attr('style', 'display:none;');
//entry exists in the database:
var delete_input = jQuery(row).find('.EntryStatus');
jQuery(delete_input).val('D');
} else {
jQuery(row).remove();
}
}
};