PublicCorporaTab.vue 1.12 KB
Newer Older
1
2
3
4
5
6
7
<template>
  <v-card outlined height=8em>
    <v-card-text
      class="justify-center text-center"
    > 
      <v-select 
        :items="test_common_corpus"
Quentin David's avatar
Quentin David committed
8
        :item-text="name"
9
10
11
12
13
14
15
16
17
18
19
20
21
        v-model="publicCorpus"
        :label="$t('shared-corpus-label')"
        outlined
        @change="updateValue()"
      >
      </v-select>
    </v-card-text>
  </v-card>
</template>
<script>
export default {
  data: () => ({
    publicCorpus: null,
Quentin David's avatar
Quentin David committed
22
23
24
25
26
27
    test_common_corpus: [
      { text: "CommonCorpus1", value:1 },
      { text: "LIPN_Articles", value:2 },
      { text: "Sequoia", value:3 },
      { text: "LaVoixDuNord_Solr", value: 4}
    ],
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
  }),
  props: ['isSelectedTab'],
  watch: {
    isSelectedTab: function() {
      if (!this.isSelectedTab) {
        this.publicCorpus = null;
        this.updateValue();
      }
    }
  },
  methods: {
    updateValue: function() {
      this.$emit('public-corpora-update', this.publicCorpus);
    }
  }
}
</script>
<i18n>
{
  "fr":{
    "shared-corpus-label":"Choisissez le corpus que vous voulez traiter"
  },
  "en":{
    "shared-corpus-label":"Chose the corpus you want to process"
  }
}
</i18n>