codevdesign 1.0.36 → 1.0.37
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/composants/csqcAide.vue +55 -55
- package/composants/csqcAlerteErreur.vue +87 -87
- package/composants/csqcChaise/chaiseConteneur.vue +367 -367
- package/composants/csqcChaise/chaiseItem.vue +54 -54
- package/composants/csqcCodeBudgetaireGenerique.vue +336 -336
- package/composants/csqcConfirmation.vue +75 -75
- package/composants/csqcDate.vue +57 -57
- package/composants/csqcDialogue.vue +118 -118
- package/composants/csqcEditeurTexteRiche.vue +380 -380
- package/composants/csqcEntete.vue +163 -163
- package/composants/csqcImportCSV.vue +125 -125
- package/composants/csqcModaleSaisie.vue +98 -95
- package/composants/csqcOptionSwitch.vue +120 -120
- package/composants/csqcRecherche.vue +213 -213
- package/composants/csqcSnackbar.vue +88 -88
- package/composants/csqcTable/csqcTable.vue +383 -383
- package/composants/csqcTable/csqcTableModaleChoixColonnes.vue +586 -586
- package/composants/csqcTexteBilingue.vue +175 -175
- package/composants/csqcTiroir.vue +156 -156
- package/composants/gabarit/csqcMenu.vue +281 -281
- package/composants/gabarit/pivEntete.vue +205 -205
- package/index.ts +75 -75
- package/modeles/composants/csqcMenuModele.ts +18 -18
- package/modeles/composants/datatableColonne.ts +31 -31
- package/outils/appAxios.ts +116 -116
- package/outils/rafraichisseurToken.ts +187 -187
- package/package.json +1 -1
|
@@ -1,95 +1,98 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<csqcDialogue
|
|
3
|
-
ref="modale"
|
|
4
|
-
:titre="titre"
|
|
5
|
-
activator="supprimer"
|
|
6
|
-
v-bind="$attrs"
|
|
7
|
-
:largeur="largeur"
|
|
8
|
-
@ok="confirmer"
|
|
9
|
-
@annuler="annuler"
|
|
10
|
-
>
|
|
11
|
-
<v-form
|
|
12
|
-
ref="form"
|
|
13
|
-
@submit.prevent
|
|
14
|
-
>
|
|
15
|
-
<v-row>
|
|
16
|
-
<v-col
|
|
17
|
-
cols="12"
|
|
18
|
-
class="pa-0 ma-0"
|
|
19
|
-
>
|
|
20
|
-
<span v-html="texte"></span>
|
|
21
|
-
</v-col>
|
|
22
|
-
</v-row>
|
|
23
|
-
|
|
24
|
-
<v-row>
|
|
25
|
-
<v-col
|
|
26
|
-
cols="12"
|
|
27
|
-
class="pa-0 ma-0"
|
|
28
|
-
>
|
|
29
|
-
<v-text-field
|
|
30
|
-
v-if="!multiligne"
|
|
31
|
-
v-model="reponse"
|
|
32
|
-
autofocus
|
|
33
|
-
@keyup.enter="confirmer"
|
|
34
|
-
/>
|
|
35
|
-
<v-textarea
|
|
36
|
-
v-if="multiligne"
|
|
37
|
-
v-model="reponse"
|
|
38
|
-
:rows="3"
|
|
39
|
-
autofocus
|
|
40
|
-
/>
|
|
41
|
-
</v-col>
|
|
42
|
-
</v-row>
|
|
43
|
-
</v-form>
|
|
44
|
-
</csqcDialogue>
|
|
45
|
-
</template>
|
|
46
|
-
|
|
47
|
-
<script lang="ts" setup>
|
|
48
|
-
import { ref } from 'vue'
|
|
49
|
-
import csqcDialogue from './csqcDialogue.vue'
|
|
50
|
-
|
|
51
|
-
const modale = ref<InstanceType<typeof csqcDialogue> | null>(null)
|
|
52
|
-
const utilisateurATermine = ref(false)
|
|
53
|
-
const reponse = ref<string | null>(null)
|
|
54
|
-
const texte = ref('')
|
|
55
|
-
const titre = ref('')
|
|
56
|
-
const largeur = ref('525px')
|
|
57
|
-
const multiligne = ref(false)
|
|
58
|
-
|
|
59
|
-
const ouvrir = async (
|
|
60
|
-
titreParam: string,
|
|
61
|
-
message: string,
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
1
|
+
<template>
|
|
2
|
+
<csqcDialogue
|
|
3
|
+
ref="modale"
|
|
4
|
+
:titre="titre"
|
|
5
|
+
activator="supprimer"
|
|
6
|
+
v-bind="$attrs"
|
|
7
|
+
:largeur="largeur"
|
|
8
|
+
@ok="confirmer"
|
|
9
|
+
@annuler="annuler"
|
|
10
|
+
>
|
|
11
|
+
<v-form
|
|
12
|
+
ref="form"
|
|
13
|
+
@submit.prevent
|
|
14
|
+
>
|
|
15
|
+
<v-row>
|
|
16
|
+
<v-col
|
|
17
|
+
cols="12"
|
|
18
|
+
class="pa-0 ma-0"
|
|
19
|
+
>
|
|
20
|
+
<span v-html="texte"></span>
|
|
21
|
+
</v-col>
|
|
22
|
+
</v-row>
|
|
23
|
+
|
|
24
|
+
<v-row>
|
|
25
|
+
<v-col
|
|
26
|
+
cols="12"
|
|
27
|
+
class="pa-0 ma-0"
|
|
28
|
+
>
|
|
29
|
+
<v-text-field
|
|
30
|
+
v-if="!multiligne"
|
|
31
|
+
v-model="reponse"
|
|
32
|
+
autofocus
|
|
33
|
+
@keyup.enter="confirmer"
|
|
34
|
+
/>
|
|
35
|
+
<v-textarea
|
|
36
|
+
v-if="multiligne"
|
|
37
|
+
v-model="reponse"
|
|
38
|
+
:rows="3"
|
|
39
|
+
autofocus
|
|
40
|
+
/>
|
|
41
|
+
</v-col>
|
|
42
|
+
</v-row>
|
|
43
|
+
</v-form>
|
|
44
|
+
</csqcDialogue>
|
|
45
|
+
</template>
|
|
46
|
+
|
|
47
|
+
<script lang="ts" setup>
|
|
48
|
+
import { ref } from 'vue'
|
|
49
|
+
import csqcDialogue from './csqcDialogue.vue'
|
|
50
|
+
|
|
51
|
+
const modale = ref<InstanceType<typeof csqcDialogue> | null>(null)
|
|
52
|
+
const utilisateurATermine = ref(false)
|
|
53
|
+
const reponse = ref<string | null>(null)
|
|
54
|
+
const texte = ref('')
|
|
55
|
+
const titre = ref('')
|
|
56
|
+
const largeur = ref('525px')
|
|
57
|
+
const multiligne = ref(false)
|
|
58
|
+
|
|
59
|
+
const ouvrir = async (
|
|
60
|
+
titreParam: string,
|
|
61
|
+
message: string,
|
|
62
|
+
valeurDefaut: string | null = null,
|
|
63
|
+
multiligneParam: boolean = false,
|
|
64
|
+
largeurParam = '525px',
|
|
65
|
+
) => {
|
|
66
|
+
texte.value = message
|
|
67
|
+
titre.value = titreParam
|
|
68
|
+
reponse.value = valeurDefaut
|
|
69
|
+
multiligne.value = multiligneParam
|
|
70
|
+
largeur.value = largeurParam
|
|
71
|
+
utilisateurATermine.value = false
|
|
72
|
+
modale.value?.ouvrir()
|
|
73
|
+
|
|
74
|
+
while (!utilisateurATermine.value) {
|
|
75
|
+
await new Promise(resolve => setTimeout(resolve, 100)) // Attendre 100ms
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
return reponse.value
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
const confirmer = (): void => {
|
|
82
|
+
utilisateurATermine.value = true
|
|
83
|
+
fermer()
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
const annuler = (): void => {
|
|
87
|
+
reponse.value = null
|
|
88
|
+
utilisateurATermine.value = true
|
|
89
|
+
fermer()
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
const fermer = (): void => {
|
|
93
|
+
modale.value?.fermer()
|
|
94
|
+
reponse.value = null
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
defineExpose({ ouvrir, fermer })
|
|
98
|
+
</script>
|
|
@@ -1,120 +1,120 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div>
|
|
3
|
-
<v-row dense>
|
|
4
|
-
<v-col
|
|
5
|
-
cols="9"
|
|
6
|
-
md="8"
|
|
7
|
-
lg="6"
|
|
8
|
-
class="d-flex align-end"
|
|
9
|
-
>
|
|
10
|
-
<div class="labelSwitchSiSwitchApres">{{ texte }}</div>
|
|
11
|
-
</v-col>
|
|
12
|
-
<v-col
|
|
13
|
-
cols="2"
|
|
14
|
-
class="d-flex align-end justify-end"
|
|
15
|
-
>
|
|
16
|
-
<v-switch
|
|
17
|
-
v-model="maValeur"
|
|
18
|
-
:disabled="desactiver"
|
|
19
|
-
density="compact"
|
|
20
|
-
inset
|
|
21
|
-
v-bind="$attrs"
|
|
22
|
-
hide-details
|
|
23
|
-
@update:model-value="sauvegarder"
|
|
24
|
-
/>
|
|
25
|
-
</v-col>
|
|
26
|
-
</v-row>
|
|
27
|
-
<v-row dense>
|
|
28
|
-
<v-col
|
|
29
|
-
cols="9"
|
|
30
|
-
md="8"
|
|
31
|
-
>
|
|
32
|
-
<span v-html="texteDetaille"></span>
|
|
33
|
-
</v-col>
|
|
34
|
-
</v-row>
|
|
35
|
-
</div>
|
|
36
|
-
</template>
|
|
37
|
-
<script setup lang="ts">
|
|
38
|
-
import { ref, watch, onMounted, type PropType } from 'vue'
|
|
39
|
-
|
|
40
|
-
// Définition des props
|
|
41
|
-
const props = defineProps({
|
|
42
|
-
valeurInverse: {
|
|
43
|
-
type: Boolean,
|
|
44
|
-
default: false,
|
|
45
|
-
},
|
|
46
|
-
desactiver: {
|
|
47
|
-
type: Boolean,
|
|
48
|
-
default: false,
|
|
49
|
-
},
|
|
50
|
-
modelValue: {
|
|
51
|
-
type: Boolean,
|
|
52
|
-
required: true,
|
|
53
|
-
},
|
|
54
|
-
texte: {
|
|
55
|
-
type: String,
|
|
56
|
-
required: true,
|
|
57
|
-
},
|
|
58
|
-
texteDetaille: {
|
|
59
|
-
type: String,
|
|
60
|
-
required: true,
|
|
61
|
-
},
|
|
62
|
-
})
|
|
63
|
-
|
|
64
|
-
// Définition de l'événement
|
|
65
|
-
const emit = defineEmits(['update:modelValue'])
|
|
66
|
-
|
|
67
|
-
// Référence pour la valeur interne
|
|
68
|
-
const maValeur = ref<boolean>(false)
|
|
69
|
-
|
|
70
|
-
// Montée du composant
|
|
71
|
-
onMounted(() => {
|
|
72
|
-
if (props.valeurInverse) {
|
|
73
|
-
maValeur.value = !props.modelValue
|
|
74
|
-
} else {
|
|
75
|
-
maValeur.value = props.modelValue
|
|
76
|
-
}
|
|
77
|
-
})
|
|
78
|
-
|
|
79
|
-
// Watcher pour suivre les changements de la prop 'value'
|
|
80
|
-
watch(
|
|
81
|
-
() => props.modelValue,
|
|
82
|
-
newValue => {
|
|
83
|
-
if (props.valeurInverse) {
|
|
84
|
-
maValeur.value = !newValue
|
|
85
|
-
} else {
|
|
86
|
-
maValeur.value = newValue
|
|
87
|
-
}
|
|
88
|
-
},
|
|
89
|
-
)
|
|
90
|
-
|
|
91
|
-
watch(
|
|
92
|
-
() => props.valeurInverse,
|
|
93
|
-
newValue => {
|
|
94
|
-
if (props.valeurInverse) {
|
|
95
|
-
maValeur.value = newValue
|
|
96
|
-
} else {
|
|
97
|
-
maValeur.value = !newValue
|
|
98
|
-
}
|
|
99
|
-
},
|
|
100
|
-
)
|
|
101
|
-
|
|
102
|
-
// Méthode pour sauvegarder la valeur
|
|
103
|
-
const sauvegarder = () => {
|
|
104
|
-
if (props.valeurInverse) {
|
|
105
|
-
emit('update:modelValue', !maValeur.value)
|
|
106
|
-
} else {
|
|
107
|
-
emit('update:modelValue', maValeur.value)
|
|
108
|
-
}
|
|
109
|
-
}
|
|
110
|
-
</script>
|
|
111
|
-
|
|
112
|
-
<style lang="css" scoped>
|
|
113
|
-
.labelSwitchSiSwitchApres {
|
|
114
|
-
font-weight: bold;
|
|
115
|
-
margin-top: 25px;
|
|
116
|
-
}
|
|
117
|
-
.v-switch {
|
|
118
|
-
margin-bottom: -10px; /* aligner le switch avec son texte*/
|
|
119
|
-
}
|
|
120
|
-
</style>
|
|
1
|
+
<template>
|
|
2
|
+
<div>
|
|
3
|
+
<v-row dense>
|
|
4
|
+
<v-col
|
|
5
|
+
cols="9"
|
|
6
|
+
md="8"
|
|
7
|
+
lg="6"
|
|
8
|
+
class="d-flex align-end"
|
|
9
|
+
>
|
|
10
|
+
<div class="labelSwitchSiSwitchApres">{{ texte }}</div>
|
|
11
|
+
</v-col>
|
|
12
|
+
<v-col
|
|
13
|
+
cols="2"
|
|
14
|
+
class="d-flex align-end justify-end"
|
|
15
|
+
>
|
|
16
|
+
<v-switch
|
|
17
|
+
v-model="maValeur"
|
|
18
|
+
:disabled="desactiver"
|
|
19
|
+
density="compact"
|
|
20
|
+
inset
|
|
21
|
+
v-bind="$attrs"
|
|
22
|
+
hide-details
|
|
23
|
+
@update:model-value="sauvegarder"
|
|
24
|
+
/>
|
|
25
|
+
</v-col>
|
|
26
|
+
</v-row>
|
|
27
|
+
<v-row dense>
|
|
28
|
+
<v-col
|
|
29
|
+
cols="9"
|
|
30
|
+
md="8"
|
|
31
|
+
>
|
|
32
|
+
<span v-html="texteDetaille"></span>
|
|
33
|
+
</v-col>
|
|
34
|
+
</v-row>
|
|
35
|
+
</div>
|
|
36
|
+
</template>
|
|
37
|
+
<script setup lang="ts">
|
|
38
|
+
import { ref, watch, onMounted, type PropType } from 'vue'
|
|
39
|
+
|
|
40
|
+
// Définition des props
|
|
41
|
+
const props = defineProps({
|
|
42
|
+
valeurInverse: {
|
|
43
|
+
type: Boolean,
|
|
44
|
+
default: false,
|
|
45
|
+
},
|
|
46
|
+
desactiver: {
|
|
47
|
+
type: Boolean,
|
|
48
|
+
default: false,
|
|
49
|
+
},
|
|
50
|
+
modelValue: {
|
|
51
|
+
type: Boolean,
|
|
52
|
+
required: true,
|
|
53
|
+
},
|
|
54
|
+
texte: {
|
|
55
|
+
type: String,
|
|
56
|
+
required: true,
|
|
57
|
+
},
|
|
58
|
+
texteDetaille: {
|
|
59
|
+
type: String,
|
|
60
|
+
required: true,
|
|
61
|
+
},
|
|
62
|
+
})
|
|
63
|
+
|
|
64
|
+
// Définition de l'événement
|
|
65
|
+
const emit = defineEmits(['update:modelValue'])
|
|
66
|
+
|
|
67
|
+
// Référence pour la valeur interne
|
|
68
|
+
const maValeur = ref<boolean>(false)
|
|
69
|
+
|
|
70
|
+
// Montée du composant
|
|
71
|
+
onMounted(() => {
|
|
72
|
+
if (props.valeurInverse) {
|
|
73
|
+
maValeur.value = !props.modelValue
|
|
74
|
+
} else {
|
|
75
|
+
maValeur.value = props.modelValue
|
|
76
|
+
}
|
|
77
|
+
})
|
|
78
|
+
|
|
79
|
+
// Watcher pour suivre les changements de la prop 'value'
|
|
80
|
+
watch(
|
|
81
|
+
() => props.modelValue,
|
|
82
|
+
newValue => {
|
|
83
|
+
if (props.valeurInverse) {
|
|
84
|
+
maValeur.value = !newValue
|
|
85
|
+
} else {
|
|
86
|
+
maValeur.value = newValue
|
|
87
|
+
}
|
|
88
|
+
},
|
|
89
|
+
)
|
|
90
|
+
|
|
91
|
+
watch(
|
|
92
|
+
() => props.valeurInverse,
|
|
93
|
+
newValue => {
|
|
94
|
+
if (props.valeurInverse) {
|
|
95
|
+
maValeur.value = newValue
|
|
96
|
+
} else {
|
|
97
|
+
maValeur.value = !newValue
|
|
98
|
+
}
|
|
99
|
+
},
|
|
100
|
+
)
|
|
101
|
+
|
|
102
|
+
// Méthode pour sauvegarder la valeur
|
|
103
|
+
const sauvegarder = () => {
|
|
104
|
+
if (props.valeurInverse) {
|
|
105
|
+
emit('update:modelValue', !maValeur.value)
|
|
106
|
+
} else {
|
|
107
|
+
emit('update:modelValue', maValeur.value)
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
</script>
|
|
111
|
+
|
|
112
|
+
<style lang="css" scoped>
|
|
113
|
+
.labelSwitchSiSwitchApres {
|
|
114
|
+
font-weight: bold;
|
|
115
|
+
margin-top: 25px;
|
|
116
|
+
}
|
|
117
|
+
.v-switch {
|
|
118
|
+
margin-bottom: -10px; /* aligner le switch avec son texte*/
|
|
119
|
+
}
|
|
120
|
+
</style>
|