Use calibration_required property to conditionally render z cal step
This commit is contained in:
parent
5875abbceb
commit
f68515b17d
5 changed files with 50 additions and 12 deletions
|
|
@ -28,7 +28,7 @@
|
|||
<script>
|
||||
import singleStepTask from "./calibrationWizardComponents/singleStepTask.vue";
|
||||
import welcomeStep from "./calibrationWizardComponents/welcomeStep.vue";
|
||||
import zMotorDirectionStep from "./calibrationWizardComponents/zMotorDirectionStep.vue";
|
||||
import zMotorCalibrationTask from "./calibrationWizardComponents/zMotorCalibrationTask.vue";
|
||||
import cameraCalibrationTask from "./calibrationWizardComponents/cameraCalibrationTask.vue";
|
||||
import cameraStageMappingTask from "./calibrationWizardComponents/cameraStageMappingTask.vue";
|
||||
import finalStep from "./calibrationWizardComponents/finalStep.vue";
|
||||
|
|
@ -69,6 +69,7 @@ export default {
|
|||
this.$refs["calibrationModalEl"].addEventListener("hidden", this.onHide);
|
||||
// Check which Things are available on mount.
|
||||
const allCalibrationTasks = {
|
||||
stage: markRaw(zMotorCalibrationTask),
|
||||
camera: markRaw(cameraCalibrationTask),
|
||||
camera_stage_mapping: markRaw(cameraStageMappingTask),
|
||||
};
|
||||
|
|
@ -121,15 +122,6 @@ export default {
|
|||
});
|
||||
}
|
||||
|
||||
// Ask which way the z motor turns, right after the welcome screen but before any
|
||||
// other tasks, so the stage is correctly oriented before anything else runs.
|
||||
if (this.thingAvailable("stage") && this.thingDescription("stage").title != "DummyStage") {
|
||||
tasks.push({
|
||||
component: markRaw(singleStepTask),
|
||||
props: { title: "Stage Calibration", stepComponent: zMotorDirectionStep },
|
||||
});
|
||||
}
|
||||
|
||||
// Add calibration task for each thing
|
||||
for (const thing of thingsToCal) {
|
||||
const taskComponent = this.availableCalibrationTasks[thing];
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue