Solved bad request...?

pull/3/head
Davide Bongiovanni 8 years ago
parent 415dc0af20
commit eb6c7ffae4

@ -117,7 +117,7 @@ function save(partID) {
return; return;
} }
partnos = partno_v.split(' '); var partnos = partno_v.split(' ');
var data = new FormData(); var data = new FormData();
@ -128,8 +128,12 @@ function save(partID) {
data.append('partno', partnos[0]); data.append('partno', partnos[0]);
if (partnos.length > 1) if (partnos.length > 1)
data.append('partnoalt', partnos[1]); data.append('partnoalt', partnos[1]);
else
data.append('partnoalt', '');
if(partnos.length > 2) if(partnos.length > 2)
data.append('partnoalt2', partnos[2]); data.append('partnoalt2', partnos[2]);
else
data.append('partnoalt2', '');
data.append('description', description_v); data.append('description', description_v);
data.append('quantity', quantity_v); data.append('quantity', quantity_v);
data.append('notes', notes_v); data.append('notes', notes_v);

Loading…
Cancel
Save