bug bei id
This commit is contained in:
parent
e8bcb38cca
commit
3d2dc1f6a8
|
|
@ -242,12 +242,9 @@
|
|||
//Anlegen der Standarddateien
|
||||
function rebuildingStandards(id){
|
||||
$("#cloud_process_standards").show();
|
||||
if(ncfiledata[0] == false)
|
||||
{
|
||||
|
||||
ncfiledata[0] = ['standardid', id];
|
||||
console.log("LOADING NC FILES");
|
||||
$.ajax({
|
||||
ncfiledata[0] = ['standardid', id];
|
||||
console.log("LOADING NC FILES");
|
||||
$.ajax({
|
||||
url: "{% url 'api:apiswitchstandardsprepare' %}",
|
||||
dataType: 'json',
|
||||
data: {
|
||||
|
|
@ -257,90 +254,41 @@
|
|||
{
|
||||
ncfiledata.push(data);
|
||||
console.log(ncfiledata);
|
||||
rebuildingStandards(id);
|
||||
}
|
||||
});
|
||||
}
|
||||
else
|
||||
{
|
||||
ncfiledata[0] = ['standardid', id];
|
||||
console.log(ncfiledata);
|
||||
console.log("NC FILES LOADED, STARTING REBUILDING STANDARDS");
|
||||
$.ajax({
|
||||
url: "{% url 'api:apiswitchstandards' %}",
|
||||
dataType: 'json',
|
||||
data: JSON.stringify(ncfiledata),
|
||||
success: function(data){
|
||||
if(data['status'] == "OK"){
|
||||
standardcounter += 1;
|
||||
if(standardcounter < standards.length){
|
||||
console.log("STANDARD " + id + " OK");
|
||||
rebuildingStandards(standards[standardcounter]);
|
||||
}
|
||||
else{
|
||||
console.log("STANDARD " + id + " OK");
|
||||
$("#migfinished").show();
|
||||
}
|
||||
}
|
||||
else{
|
||||
standardcounter += 1;
|
||||
console.log("FEHLER BEI STANDARD " + data['status'] + " ID " + id);
|
||||
if(standardcounter < standards.length){
|
||||
rebuildingStandards(standards[standardcounter]);
|
||||
console.log("NC FILES LOADED, STARTING REBUILDING STANDARDS");
|
||||
$.ajax({
|
||||
url: "{% url 'api:apiswitchstandards' %}",
|
||||
dataType: 'json',
|
||||
data: JSON.stringify(ncfiledata),
|
||||
success: function(data){
|
||||
if(data['status'] == "OK"){
|
||||
standardcounter += 1;
|
||||
if(standardcounter < standards.length){
|
||||
console.log("STANDARD " + id + " OK");
|
||||
rebuildingStandards(standards[standardcounter]);
|
||||
}
|
||||
else{
|
||||
console.log("STANDARD " + id + " OK");
|
||||
$("#migfinished").show();
|
||||
}
|
||||
}
|
||||
else{
|
||||
standardcounter += 1;
|
||||
console.log("FEHLER BEI STANDARD " + data['status'] + " ID " + id);
|
||||
$("#migfinished").show();
|
||||
if(standardcounter < standards.length){
|
||||
rebuildingStandards(standards[standardcounter]);
|
||||
}
|
||||
else{
|
||||
console.log("FEHLER BEI STANDARD " + data['status'] + " ID " + id);
|
||||
$("#migfinished").show();
|
||||
}
|
||||
}
|
||||
},
|
||||
error: function(e){
|
||||
console.log(e);
|
||||
}
|
||||
},
|
||||
error: function(e){
|
||||
console.log(e);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/*
|
||||
$.ajax({
|
||||
url: "{% url 'api:apiswitchstandards' %}",
|
||||
dataType: 'json',
|
||||
data: {
|
||||
'standardid' : id,
|
||||
},
|
||||
success: function(data){
|
||||
if(data['status'] == "OK"){
|
||||
standardcounter += 1;
|
||||
if(standardcounter < standards.length){
|
||||
console.log("STANDARD " + id + " OK");
|
||||
rebuildingStandards(standards[standardcounter]);
|
||||
}
|
||||
else{
|
||||
console.log("STANDARD " + id + " OK");
|
||||
$("#migfinished").show();
|
||||
}
|
||||
}
|
||||
else{
|
||||
standardcounter += 1;
|
||||
console.log("FEHLER BEI STANDARD " + data['status'] + " ID " + id);
|
||||
if(standardcounter < standards.length){
|
||||
rebuildingStandards(standards[standardcounter]);
|
||||
}
|
||||
else{
|
||||
console.log("FEHLER BEI STANDARD " + data['status'] + " ID " + id);
|
||||
$("#migfinished").show();
|
||||
}
|
||||
}
|
||||
},
|
||||
error: function(e){
|
||||
console.log(e);
|
||||
});
|
||||
}
|
||||
});
|
||||
*/
|
||||
}
|
||||
</script>
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Reference in New Issue