DefineTreatment.vue 1.4 KB
Newer Older
1
2
3
4
<template>
  <v-container class="my-5">
    <v-card outlined class="px-6 mb-5">
      <v-card-title class="justify-center py-6">
Quentin David's avatar
Quentin David committed
5
        <h1 class="display-3"> {{ $t('module-choice') }} </h1>
6
      </v-card-title>
7
      <DefinePreTreatment />
Quentin David's avatar
Quentin David committed
8
      <DefinePipeline class="my-5" @add-module="updateChain" />
Quentin David's avatar
Quentin David committed
9
10
11
12
      <ModuleChain class="my-5" 
        v-if="chain.length > 0"
        @delete-module="deleteModuleFromChain" 
        :added_modules="chain"/>
13
    </v-card>
14
    <v-btn block color="success" to="/prevalidation"> {{ $t('treatment-validation') }} </v-btn>
15
16
17
18
19
  </v-container>
</template>

<script>
  import DefinePipeline from '@/components/DefineTreatment/DefinePipeline'
Quentin David's avatar
Quentin David committed
20
  import ModuleChain from '@/components/DefineTreatment/ModuleChain'
21
  import DefinePreTreatment from '@/components/DefineTreatment/DefinePreTreatment'
22
23
24
25
  export default {
    name: 'Treatment',
    components: {
      DefinePipeline,
Quentin David's avatar
Quentin David committed
26
      ModuleChain,
27
      DefinePreTreatment,
28
    },
Quentin David's avatar
Quentin David committed
29
30
31
32
33
34
35
36
37
38
39
    data: () => ({
      chain: [],
    }),
    methods: {
      updateChain: function(module) {
        this.chain.push(module);
      },
      deleteModuleFromChain: function(index) {
        this.chain.splice(index, 1);
      }
    }
40
  }
Quentin David's avatar
Quentin David committed
41
42
43
44
45
46
47
48
49
50
51
52
53
</script>
<i18n>
{
  "fr":{
    "module-choice":"Choix des modules",
    "treatment-validation":"Lancer le traitement"
  },
  "en":{
    "module-choice":"Choice of modules",
    "treatment-validation":"Start treatment"
  }
}
</i18n>