feat: enhance user management, mimetype creation, and validation
Some checks failed
CI Pipeline / japa-tests (push) Failing after 1m8s

- **AdminuserController.ts**: enable editing `first_name` and `last_name` for user creation and updates
- **MimetypeController.ts**: add creation support for mimetypes with selectable extensions
- **Models**: add `Mimetype` model (mime_type.ts); add `SnakeCaseNamingStrategy` for User model
- **Validators**:
  - **updateDatasetValidator**: increase title length to 255 and description length to 2500
  - **User Validators**: refine `createUserValidator` and `updateUserValidator` to include `first_name` and `last_name`
- **vanilla_error_reporter**: improve error reporting for wildcard fields
- **SKOS Query**: refine keyword request in `SearchCategoryAutocomplete.vue`
- **UI Enhancements**:
  - improve icon design in wizard (Wizard.vue)
  - add components for mimetype creation (Create.vue and button in Index.vue)
- **Routes**: update `routes.ts` to include new AdonisJS routes
This commit is contained in:
Kaimbacher 2024-10-31 11:02:36 +01:00
parent 2235f3905a
commit 49bd96ee77
24 changed files with 1548 additions and 945 deletions

View file

@ -92,7 +92,7 @@ const formatServerState = (state: string) => {
<!-- table -->
<CardBox class="mb-6" has-table>
<table class="">
<table class="w-full table-fixed">
<thead>
<tr>
<th scope="col" class="py-3 text-left text-xs font-medium uppercase tracking-wider">
@ -114,13 +114,13 @@ const formatServerState = (state: string) => {
<tbody class="bg-white divide-y divide-gray-200">
<tr v-for="dataset in props.datasets.data" :key="dataset.id" :class="getRowClass(dataset)">
<td data-label="Login" class="py-4 whitespace-nowrap text-gray-700 dark:text-white">
<td data-label="Login" class="py-4 whitespace-nowrap text-gray-700 dark:text-white table-title">
<!-- <Link v-bind:href="stardust.route('settings.user.show', [user.id])"
class="no-underline hover:underline text-cyan-600 dark:text-cyan-400">
{{ user.login }}
</Link> -->
<!-- {{ user.id }} -->
{{ dataset.main_title }}
{{ dataset.main_title }}
</td>
<td class="py-4 whitespace-nowrap text-gray-700 dark:text-white">
{{ formatServerState(dataset.server_state) }}
@ -156,44 +156,55 @@ const formatServerState = (state: string) => {
</LayoutAuthenticated>
</template>
<!-- <style scoped lang="css">
.pure-table tr.released {
background-color: rgb(52 211 153);
color: gray;
<style scoped lang="css">
.table-title {
max-width: 200px; /* set a maximum width */
overflow: hidden; /* hide overflow */
text-overflow: ellipsis; /* show ellipsis for overflowed text */
white-space: nowrap; /* prevent wrapping */
}
.table-fixed {
table-layout: fixed;
}
.pure-table tr.inprogress {
/* .pure-table tr.released {
background-color: rgb(52 211 153);
color: gray;
} */
/* .pure-table tr.inprogress {
padding: 0.8em;
background-color: rgb(94 234 212);
color: gray;
}
} */
.pure-table tr.editor_accepted {
/* .pure-table tr.editor_accepted {
background-color: rgb(125 211 252);
color: gray;
}
} */
.pure-table tr.rejected_reviewer {
/* .pure-table tr.rejected_reviewer {
padding: 0.8em;
background-color: orange;
color: gray;
}
} */
.pure-table tr.rejected_editor {
/* .pure-table tr.rejected_editor {
background-color: orange;
color: gray;
}
} */
.pure-table tr.reviewed {
/* .pure-table tr.reviewed {
background-color: yellow;
color: gray;
}
} */
.pure-table tr.approved {
/* .pure-table tr.approved {
background-color: rgb(86, 86, 241);
color: whitesmoke;
color: whitesmoke;
}
}*/
</style> -->
</style>