+ :data-label-preparing="$t('data_label_preparing')"
+ :data-label-quiet-button="$t('data_label_quiet_button')"
+ :data-label-ready="$t('data_label_ready')"
+ :data-dict-file-too-big="$t('data_dict_file_too_big')"
+ :data-dict-default-message="$t('data_dict_default_message')"
+ :data-dict-remove-file="$t('data_dict_remove_file')"
+ :data-dict-max-files-exceeded="$t('data_dict_max_files_exceeded')"
+ :data-dict-cancel-upload="$t('data_dict_cancel_upload')"
+ :data-dict-cancel-upload-confirm="$t('data_dict_cancel_upload_confirm')"
+ :data-dict-upload-canceled="$t('data_dict_upload_canceled')"
+ :data-dict-remove="$t('data_dict_remove')"
+ :data-allow-remove="!options.required"
+ data-temp-url-generator="/asyncupload/temp_url/generate/GET">
- modal-footer
+
@@ -66,15 +69,36 @@
import Modal from 'ChillMainAssets/vuejs/_components/Modal';
import { searchForZones } from '../../module/async_upload/uploader';
+const i18n = {
+ messages: {
+ fr: {
+ upload_a_document: "Téléversez un document",
+ data_label_preparing: "Chargement...",
+ data_label_quiet_button: "Téléchargez le fichier existant",
+ data_label_ready: "Prêt à montrer",
+ data_dict_file_too_big: "Fichier trop volumineux",
+ data_dict_default_message: "Glissez votre fichier ou cliquez ici",
+ data_dict_remove_file: "Enlevez votre fichier pour en téléversez un autre",
+ data_dict_max_files_exceeded: "Nombre maximum de fichiers atteint. Enlevez les fichiers précédents",
+ data_dict_cancel_upload: "Annulez le téléversement",
+ data_dict_cancel_upload_confirm: "Êtes-vous sûr·e de vouloir annuler ce téléversement?",
+ data_dict_upload_canceled: "Téléversement annulé",
+ data_dict_remove: "Enlevez le fichier existant",
+ }
+ }
+};
+
export default {
name: "AddAsyncUpload",
components: {
Modal
},
+ i18n,
props: [
'buttonTitle',
'options'
],
+ emits: ['addDocument'],
data() {
return {
modal: {
@@ -88,9 +112,6 @@ export default {
searchForZones(this.$refs.dropZoneWrapper);
}
},
- // mounted() {
- // console.log(this.options)
- // },
methods: {
openModal() {
this.modal.showModal = true;
diff --git a/src/Bundle/ChillPersonBundle/Resources/public/vuejs/AccompanyingCourseWorkEdit/components/FormEvaluation.vue b/src/Bundle/ChillPersonBundle/Resources/public/vuejs/AccompanyingCourseWorkEdit/components/FormEvaluation.vue
index aa4b7278b..bde815e66 100644
--- a/src/Bundle/ChillPersonBundle/Resources/public/vuejs/AccompanyingCourseWorkEdit/components/FormEvaluation.vue
+++ b/src/Bundle/ChillPersonBundle/Resources/public/vuejs/AccompanyingCourseWorkEdit/components/FormEvaluation.vue
@@ -166,7 +166,8 @@ export default {
template: null,
asyncUploadOptions: {
maxFiles: 1,
- maxPostSize: 15000000
+ maxPostSize: 15000000,
+ required: false,
}
}
},