- added @adonisjs/mail

- mail_settings_controller for setting smtp settings
- added view ror rjecting dataset for editor
- added new model AppConfig for stroing appwide config values
- better validate_chesum.ts command with process chunking
- added vue3 apps 'BasicSettings' like email, profile settings
- started with 2 multilingual capabilities
- npm updates
This commit is contained in:
Kaimbacher 2024-09-16 17:59:46 +02:00
parent 010bead723
commit b06ccae603
67 changed files with 7820 additions and 1463 deletions

View file

@ -2,7 +2,7 @@
import { Head, useForm, usePage } from '@inertiajs/vue3';
import { ref, watch, computed, ComputedRef } from 'vue';
import FormValidationErrors from '@/Components/FormValidationErrors.vue';
import { Dataset, Description, Title, Subject } from '@/Dataset';
import { Dataset, Title, Subject } from '@/Dataset';
import {
mdiDatabasePlus,
mdiMinusCircle,
@ -44,6 +44,7 @@ import { LayerOptions } from '@/Components/Map/LayerOptions';
import TableKeywords from '@/Components/TableKeywords.vue';
import NotificationBar from '@/Components/NotificationBar.vue';
import FileUploadComponent from '@/Components/FileUpload.vue';
import Person from '#models/person';
const props = defineProps({
licenses: {
@ -276,7 +277,7 @@ const mapId = 'test';
// };
const nextStep = async () => {
let route;
let route ="";
if (formStep.value == 1) {
route = stardust.route('dataset.first.step');
} else if (formStep.value == 2) {
@ -381,7 +382,7 @@ const addTitle = () => {
//this.dataset.files.push(uploadedFiles[i]);
form.titles.push(newTitle);
};
const removeTitle = (key) => {
const removeTitle = (key: number) => {
form.titles.splice(key, 1);
};
@ -390,11 +391,11 @@ const addDescription = () => {
//this.dataset.files.push(uploadedFiles[i]);
form.descriptions.push(newDescription);
};
const removeDescription = (key) => {
const removeDescription = (key: number) => {
form.descriptions.splice(key, 1);
};
const onAddAuthor = (person) => {
const onAddAuthor = (person: Person) => {
if (form.authors.filter((e) => e.id === person.id).length > 0) {
notify({ type: 'warning', title: 'Warning', text: 'person is already defined as author' }, 4000);
} else if (form.contributors.filter((e) => e.id === person.id).length > 0) {
@ -404,7 +405,7 @@ const onAddAuthor = (person) => {
notify({ type: 'info', text: 'person has been successfully added as author' });
}
};
const onAddContributor = (person) => {
const onAddContributor = (person: Person) => {
if (form.contributors.filter((e) => e.id === person.id).length > 0) {
notify({ type: 'warning', title: 'Warning', text: 'person is already defined as contributor' }, 4000);
} else if (form.authors.filter((e) => e.id === person.id).length > 0) {
@ -417,7 +418,7 @@ const onAddContributor = (person) => {
}
};
// const onMapInitializedEvent = "onMapInitializedEvent";
const onMapInitialized = (newItem) => {
const onMapInitialized = (newItem: any) => {
// notify({ type: 'info', text: message });
console.log(newItem);
};
@ -439,7 +440,7 @@ const addReference = () => {
/*
Removes a selected reference
*/
const removeReference = (key) => {
const removeReference = (key: number) => {
form.references.splice(key, 1);
};
/*
@ -593,8 +594,8 @@ Removes a selected keyword
<FormField label="Main Title *" help="required: main title"
:class="{ 'text-red-400': form.errors['titles.0.value'] }"
class="w-full mx-2 flex-1">
<FormControl required v-model="form.titles[0].value" type="text"
placeholder="[enter main title]">
<FormControl required v-model="form.titles[0].value" type="textarea"
placeholder="[enter main title]" :show-char-count="true" :max-input-length="255">
<div class="text-red-400 text-sm"
v-if="form.errors['titles.0.value'] && Array.isArray(form.errors['titles.0.value'])">
{{ form.errors['titles.0.value'].join(', ') }}
@ -739,7 +740,7 @@ Removes a selected keyword
</CardBox>
<!-- authors -->
<CardBox class="mb-6 shadow" has-table title="Authors" :icon="mdiBookOpenPageVariant">
<CardBox class="mb-6 shadow" has-table title="Creators" :icon="mdiBookOpenPageVariant">
<SearchAutocomplete source="/api/persons" :response-property="'first_name'"
placeholder="search in person table...." v-on:person="onAddAuthor"></SearchAutocomplete>