Loading ui/src/components/ImpressionRequestProcessComponent.vue +6 −4 Original line number Diff line number Diff line Loading @@ -163,6 +163,9 @@ export default { }, position_text() { return this.position == -1 ? "":"Position dans la queue: "+this.position }; gcode_upload_progress() { return this.gcode_upload_progress_value } // request_object () { // console.log(this.$store.state.admin_requests_dict[this.id]) Loading Loading @@ -259,14 +262,13 @@ export default { gcode_changed () { this.is_uploading_gcode = true this.gcode_upload_progress = 0 this.gcode_upload_progress_value = 0 let req_id = parseInt(this.id) var formData = new FormData(); var progressHandler = function(progressEvent) { var percentCompleted = Math.round((progressEvent.loaded * 100) / progressEvent.total) console.log(percentCompleted) this.gcode_upload_progress = percentCompleted this.gcode_upload_progress_value = percentCompleted } formData.append("file", document.querySelector('#file').files[0]); Loading Loading @@ -295,7 +297,7 @@ export default { return { queue: null, gcode_upload_progress: 0, gcode_upload_progress_value: 0, is_uploading_gcode: false, position: -1, title: '', Loading Loading
ui/src/components/ImpressionRequestProcessComponent.vue +6 −4 Original line number Diff line number Diff line Loading @@ -163,6 +163,9 @@ export default { }, position_text() { return this.position == -1 ? "":"Position dans la queue: "+this.position }; gcode_upload_progress() { return this.gcode_upload_progress_value } // request_object () { // console.log(this.$store.state.admin_requests_dict[this.id]) Loading Loading @@ -259,14 +262,13 @@ export default { gcode_changed () { this.is_uploading_gcode = true this.gcode_upload_progress = 0 this.gcode_upload_progress_value = 0 let req_id = parseInt(this.id) var formData = new FormData(); var progressHandler = function(progressEvent) { var percentCompleted = Math.round((progressEvent.loaded * 100) / progressEvent.total) console.log(percentCompleted) this.gcode_upload_progress = percentCompleted this.gcode_upload_progress_value = percentCompleted } formData.append("file", document.querySelector('#file').files[0]); Loading Loading @@ -295,7 +297,7 @@ export default { return { queue: null, gcode_upload_progress: 0, gcode_upload_progress_value: 0, is_uploading_gcode: false, position: -1, title: '', Loading