[add] notify when receiving results
This commit is contained in:
@@ -159,6 +159,8 @@ $( document ).ready( () => {
|
||||
$('#a280_submit').hide();
|
||||
$('#pcb442_submit').hide();
|
||||
$('#dsj1000_submit').hide();
|
||||
$("#submit_name").val('');
|
||||
$("#submit_desc").val('');
|
||||
doAjax();
|
||||
});
|
||||
})
|
||||
@@ -255,6 +257,13 @@ function doAjax() {
|
||||
console.log('Emit build request')
|
||||
socket.emit('build', {});
|
||||
$("#uploadfile").fileinput('clear');
|
||||
$("#ulysses16_your").text("-");
|
||||
$("#att48_your").text("-");
|
||||
$("#st70_your").text("-");
|
||||
$("#a280_your").text("-");
|
||||
$("#pcb442_your").text("-");
|
||||
$("#dsj1000_your").text("-");
|
||||
|
||||
$("#exampleModal").modal('show');
|
||||
},
|
||||
error: (e) => {
|
||||
|
||||
@@ -38,9 +38,9 @@ socket.on('users_count', (clients) => {
|
||||
|
||||
// Server running algorithms
|
||||
socket.on('start', () => {
|
||||
console.log('Building start');
|
||||
console.log('Running');
|
||||
Snackbar.show({
|
||||
text: 'Building start, please wait for your result.',
|
||||
text: 'Running, please wait for your result.',
|
||||
pos: 'bottom-right',
|
||||
duration: 60000
|
||||
});
|
||||
@@ -129,6 +129,9 @@ function update_your_res(tsp_file, fitness) {
|
||||
|
||||
// Update personal result
|
||||
socket.on('result', (res) => {
|
||||
|
||||
$("#resultModal").modal('show');
|
||||
|
||||
res = JSON.parse(res);
|
||||
$('#submission_info').show();
|
||||
res.forEach(e => {
|
||||
|
||||
Reference in New Issue
Block a user