Fix missing RessourceList import.

This commit is contained in:
Stephan Porada 2020-09-17 11:12:08 +02:00
parent ad21fe178c
commit 269368e940

View File

@ -157,8 +157,9 @@
</div>
<script>
class InformationUpdater {
<script type="module">
import {RessourceList} from '../../static/js/nopaque.lists.js';
class InformationUpdater {
constructor(jobId, foreignJobFlag) {
this.jobId = jobId;
this.foreignJobFlag = foreignJobFlag;
@ -283,19 +284,19 @@
statusElement.dataset.status = status;
}
}
}
}
{% if job.creator == current_user %}
var informationUpdater = new InformationUpdater({{ job.id }}, false);
{% else %}
var informationUpdater = new InformationUpdater({{ job.id }}, true);
document.addEventListener("DOMContentLoaded", () => {
{% if job.creator == current_user %}
var informationUpdater = new InformationUpdater({{ job.id }}, false);
{% else %}
var informationUpdater = new InformationUpdater({{ job.id }}, true);
document.addEventListener("DOMContentLoaded", () => {
nopaque.socket.emit("foreign_user_data_stream_init", {{ job.user_id }});
});
{% endif %}
let jobInputsList = new RessourceList("inputs", null, "JobInput");
document.addEventListener("DOMContentLoaded", () => {
});
{% endif %}
let jobInputsList = new RessourceList("inputs", null, "JobInput");
document.addEventListener("DOMContentLoaded", () => {
jobInputsList._add({{ job_inputs|tojson|safe }});
});
});
</script>
{% endblock %}