First start for CSV file import.

This commit is contained in:
James Cole
2018-05-06 20:42:30 +02:00
parent a4524b3c2c
commit 1209f3b39a
13 changed files with 663 additions and 420 deletions

View File

@@ -63,6 +63,9 @@ function reportJobJSONDone(data) {
// redirect user to configuration for this job.
window.location.replace(jobConfigurationUri);
break;
case 'error':
reportJobError();
break;
case 'provider_finished':
// call routine to store stuff:
sendJobPOSTStore();
@@ -226,6 +229,24 @@ function reportJobPOSTFailure(xhr, status, error) {
// show error box.
}
/**
* Show error to user.
*/
function reportJobError() {
console.log('In reportJobError()');
// cancel checking again for job status:
clearTimeout(timeOutId);
// hide status boxes:
$('.statusbox').hide();
// show fatal error box:
$('.fatal_error').show();
$('.fatal_error_txt').text('Job reports error. Please start again. Apologies.');
// show error box.
}
function reportJobPOSTDone(data) {
console.log('In function reportJobPOSTDone() with status "' + data.status + '"');
if (data.status === 'NOK') {