sync(dev): fehlende Admin-Theme-Assets vom Live-Stand ergaenzt (nichts ueberschrieben)
This commit is contained in:
@@ -0,0 +1,31 @@
|
||||
$(document).ready(function() {
|
||||
|
||||
$('#email_template_selection').change(function(e) {
|
||||
e.preventDefault();
|
||||
if ($(this).val() == 0) {
|
||||
$('#subject').val('');
|
||||
$('#message').val('');
|
||||
}
|
||||
else {
|
||||
jqxhr = $.ajax({
|
||||
'url' : './index.php?admin_modul=admin_object_edit&action=get_data&object=Email_template&object_id=' + $(this).val(),
|
||||
'dataType' : 'JSON',
|
||||
'type' : 'GET'
|
||||
});
|
||||
jqxhr.success(function(data) {
|
||||
if (data.name) {
|
||||
$('#subject').val(data.subject);
|
||||
$('#message').val(data.body);
|
||||
} else {
|
||||
alert('Error!');
|
||||
}
|
||||
});
|
||||
jqxhr.error(function() {
|
||||
alert("ERROR: can't load url");
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
|
||||
});
|
||||
Reference in New Issue
Block a user