Revision 16fffacb
Von Niclas Zimmermann vor fast 11 Jahren hinzugefügt
templates/webpages/gl/form_header.html | ||
---|---|---|
16 | 16 |
var taxkeyposition = taxkey.lastIndexOf(found[0]); |
17 | 17 |
var account = taxkey.substr(0, taxkeyposition); |
18 | 18 |
|
19 |
var xmlhttp; |
|
20 |
if (window.XMLHttpRequest) |
|
21 |
{// code for IE7+, Firefox, Chrome, Opera, Safari |
|
22 |
xmlhttp=new XMLHttpRequest(); |
|
23 |
} |
|
24 |
else |
|
25 |
{// code for IE6, IE5 |
|
26 |
xmlhttp=new ActiveXObject("Microsoft.XMLHTTP"); |
|
27 |
} |
|
28 |
xmlhttp.onreadystatechange=function() |
|
29 |
{ |
|
30 |
if (xmlhttp.readyState==4 && xmlhttp.status==200) |
|
31 |
{ |
|
32 |
var element = document.getElementById("taxchart_" + row); |
|
33 |
element.innerHTML = xmlhttp.responseText; |
|
34 |
} |
|
35 |
} |
|
36 |
xmlhttp.open("GET","gl.pl?action=get_tax_dropdown&accno=" + account + "&select_index=" + index,true); |
|
37 |
xmlhttp.send(); |
|
19 |
$.ajax({ |
|
20 |
url: 'gl.pl?action=get_tax_dropdown', |
|
21 |
data: { accno: account, |
|
22 |
selected_index: index}, |
|
23 |
dataType: 'html', |
|
24 |
success: function (new_html) { |
|
25 |
$("#taxchart_" + row).html(new_html); |
|
26 |
}, |
|
27 |
}); |
|
38 | 28 |
}; |
39 | 29 |
|
40 | 30 |
function copy_debit_to_credit() { |
Auch abrufbar als: Unified diff
Ersetzt alten Ajax-Aufruf durch neue Methode