- prettier format checking
Some checks failed
CI Pipeline / japa-tests (push) Failing after 54s

- added the possibility to delete 'inprogress' dataset again for the submitter
- concat run commands insider Dockerfile for better docker image
- npm updates
- add own Exception classes HttpException.ts and InternalServerException.ts
This commit is contained in:
Kaimbacher 2023-09-05 18:18:42 +02:00
parent b6b1c90ff8
commit 6fa22aad9b
18 changed files with 473 additions and 251 deletions

View File

@ -12,7 +12,11 @@ RUN apt update \
&& mkdir -p /home/node/app && chown node:node /home/node/app \ && mkdir -p /home/node/app && chown node:node /home/node/app \
&& mkdir -p /var/lib/clamav \ && mkdir -p /var/lib/clamav \
&& mkdir /usr/local/share/clamav \ && mkdir /usr/local/share/clamav \
&& chown -R node:clamav /var/lib/clamav /usr/local/share/clamav /etc/clamav && chown -R node:clamav /var/lib/clamav /usr/local/share/clamav /etc/clamav \
# permissions
&& mkdir /var/run/clamav \
&& chown node:clamav /var/run/clamav \
&& chmod 750 /var/run/clamav
# ----------------------------------------------- # -----------------------------------------------
# --- ClamAV & FeshClam ------------------------- # --- ClamAV & FeshClam -------------------------
# ----------------------------------------------- # -----------------------------------------------
@ -28,10 +32,10 @@ RUN apt update \
# Configure Clam AV... # Configure Clam AV...
COPY --chown=node:clamav ./*.conf /etc/clamav/ COPY --chown=node:clamav ./*.conf /etc/clamav/
# permissions # # permissions
RUN mkdir /var/run/clamav && \ # RUN mkdir /var/run/clamav && \
chown node:clamav /var/run/clamav && \ # chown node:clamav /var/run/clamav && \
chmod 750 /var/run/clamav # chmod 750 /var/run/clamav
# Setting the working directory # Setting the working directory
WORKDIR /home/node/app WORKDIR /home/node/app
# Changing the current active user to "node" # Changing the current active user to "node"

View File

@ -18,15 +18,7 @@ export default class HomeController {
// .orderBy('server_date_published'); // .orderBy('server_date_published');
const datasets = await Database.from('documents as doc') const datasets = await Database.from('documents as doc')
.select([ .select(['publish_id', 'server_date_published', Database.raw(`date_part('year', server_date_published) as pub_year`)])
'publish_id',
'server_date_published',
Database.raw(`date_part('year', server_date_published) as pub_year`)
],
// Database
// .raw('select "ip_address" from "user_logins" where "users.id" = "user_logins.user_id" limit 1')
// .wrap('(', ')')
)
.where('server_state', serverState) .where('server_state', serverState)
.innerJoin('link_documents_persons as ba', 'doc.id', 'ba.document_id') .innerJoin('link_documents_persons as ba', 'doc.id', 'ba.document_id')
.andWhereRaw(`date_part('year', server_date_published) = ?`, [from]) .andWhereRaw(`date_part('year', server_date_published) = ?`, [from])

View File

@ -8,8 +8,6 @@ import Description from 'App/Models/Description';
import Language from 'App/Models/Language'; import Language from 'App/Models/Language';
import Coverage from 'App/Models/Coverage'; import Coverage from 'App/Models/Coverage';
import Collection from 'App/Models/Collection'; import Collection from 'App/Models/Collection';
// import CreateUserValidator from 'App/Validators/CreateUserValidator';
// import UpdateUserValidator from 'App/Validators/UpdateUserValidator';
import { schema, CustomMessages, rules } from '@ioc:Adonis/Core/Validator'; import { schema, CustomMessages, rules } from '@ioc:Adonis/Core/Validator';
import dayjs from 'dayjs'; import dayjs from 'dayjs';
import Person from 'App/Models/Person'; import Person from 'App/Models/Person';
@ -17,13 +15,23 @@ import Database from '@ioc:Adonis/Lucid/Database';
import { TransactionClientContract } from '@ioc:Adonis/Lucid/Database'; import { TransactionClientContract } from '@ioc:Adonis/Lucid/Database';
import Subject from 'App/Models/Subject'; import Subject from 'App/Models/Subject';
import CreateDatasetValidator from 'App/Validators/CreateDatasetValidator'; import CreateDatasetValidator from 'App/Validators/CreateDatasetValidator';
import { TitleTypes, DescriptionTypes, ContributorTypes, PersonNameTypes, ReferenceIdentifierTypes, RelationTypes } from 'Contracts/enums'; import {
TitleTypes,
DescriptionTypes,
ContributorTypes,
PersonNameTypes,
ReferenceIdentifierTypes,
RelationTypes,
DatasetTypes,
} from 'Contracts/enums';
import type { ModelQueryBuilderContract } from '@ioc:Adonis/Lucid/Orm'; import type { ModelQueryBuilderContract } from '@ioc:Adonis/Lucid/Orm';
import DatasetReference from 'App/Models/DatasetReference'; import DatasetReference from 'App/Models/DatasetReference';
import { cuid } from '@ioc:Adonis/Core/Helpers'; import { cuid } from '@ioc:Adonis/Core/Helpers';
import File from 'App/Models/File'; import File from 'App/Models/File';
import ClamScan from 'clamscan'; import ClamScan from 'clamscan';
import { ValidationException } from '@ioc:Adonis/Core/Validator'; import { ValidationException } from '@ioc:Adonis/Core/Validator';
import Drive from '@ioc:Adonis/Core/Drive';
import { Exception } from '@adonisjs/core/build/standalone';
export default class DatasetController { export default class DatasetController {
public async index({ auth, request, inertia }: HttpContextContract) { public async index({ auth, request, inertia }: HttpContextContract) {
@ -98,30 +106,21 @@ export default class DatasetController {
const projects = await Project.query().pluck('label', 'id'); const projects = await Project.query().pluck('label', 'id');
const doctypes = { // const doctypes = {
analysisdata: { label: 'Analysis', value: 'analysisdata' }, // analysisdata: { label: 'Analysis', value: 'analysisdata' },
measurementdata: { label: 'Measurements', value: 'measurementdata' }, // measurementdata: { label: 'Measurements', value: 'measurementdata' },
monitoring: 'Monitoring', // monitoring: 'Monitoring',
remotesensing: 'Remote Sensing', // remotesensing: 'Remote Sensing',
gis: 'GIS', // gis: 'GIS',
models: 'Models', // models: 'Models',
mixedtype: 'Mixed Type', // mixedtype: 'Mixed Type',
vocabulary: 'Vocabulary' // vocabulary: 'Vocabulary',
};
// const titletypes = {
// Sub: 'Sub',
// Alternative: 'Alternative',
// Translated: 'Translated',
// Other: 'Other',
// }; // };
// let test = Object.entries(TitleTypes).map(([key, value]) => ({id: key, value: value}))
// const languages = await Database.from('languages').select('*').where('active', true); // const languages = await Database.from('languages').select('*').where('active', true);
return inertia.render('Submitter/Dataset/Create', { return inertia.render('Submitter/Dataset/Create', {
licenses: licenses, licenses: licenses,
doctypes: doctypes, doctypes: DatasetTypes,
titletypes: Object.entries(TitleTypes) titletypes: Object.entries(TitleTypes)
.filter(([value]) => value !== 'Main') .filter(([value]) => value !== 'Main')
.map(([key, value]) => ({ value: key, label: value })), .map(([key, value]) => ({ value: key, label: value })),
@ -293,7 +292,6 @@ export default class DatasetController {
// node ace make:validator CreateDataset // node ace make:validator CreateDataset
try { try {
// Step 2 - Validate request body against the schema // Step 2 - Validate request body against the schema
// await request.validate(CreateUserValidator);
// await request.validate({ schema: newDatasetSchema, messages: this.messages }); // await request.validate({ schema: newDatasetSchema, messages: this.messages });
await request.validate(CreateDatasetValidator); await request.validate(CreateDatasetValidator);
// console.log({ payload }); // console.log({ payload });
@ -755,4 +753,79 @@ export default class DatasetController {
doctypes, doctypes,
}); });
} }
public async delete({ request, inertia, response, session }) {
const id = request.param('id');
try {
const dataset = await Dataset.query()
.preload('user', (builder) => {
builder.select('id', 'login');
})
.preload('files')
.where('id', id)
.firstOrFail();
const validStates = ['inprogress', 'rejected_editor'];
if (!validStates.includes(dataset.server_state)) {
// session.flash('errors', 'Invalid server state!');
return response
.flash(
'warning',
`Invalid server state. Dataset with id ${id} cannot be deleted. Datset has server state ${dataset.server_state}.`,
)
.redirect()
.toRoute('dataset.list');
}
return inertia.render('Submitter/Dataset/Delete', {
dataset,
});
} catch (error) {
if (error.code == 'E_ROW_NOT_FOUND') {
session.flash({ warning: 'Dataset is not found in database' });
} else {
session.flash({ warning: 'general error occured, you cannot delete the dataset' });
}
return response.redirect().toRoute('dataset.list');
}
}
public async deleteUpdate({ params, session, response }) {
try {
const dataset = await Dataset.query().where('id', params.id).preload('files').firstOrFail();
const validStates = ['inprogress', 'rejected_editor'];
if (validStates.includes(dataset.server_state)) {
if (dataset.files && dataset.files.length > 0) {
for (const file of dataset.files) {
if (file.pathName) {
// delete file from filesystem
await Drive.delete(file.pathName);
}
}
}
// delete dataset wirh relation from db
await dataset.delete();
session.flash({ message: 'You have deleted 1 dataset!' });
return response.redirect().toRoute('dataset.list');
} else {
session.flash({
warning: `You cannot delete this dataset! The status of this dataset is "${dataset.server_state}"!`,
});
return response.redirect().back();
}
} catch (error) {
if (error instanceof ValidationException) {
// Validation exception handling
throw error;
} else if (error instanceof Exception) {
// General exception handling
return response
.flash({ errors: { error: error.message } })
.redirect()
.back();
} else {
session.flash({ error: 'An error occurred while deleting the dataset.' });
return response.redirect().back();
}
}
}
} }

View File

@ -0,0 +1,12 @@
class HTTPException extends Error {
public status: number;
public message: string;
constructor(status: number, message: string) {
super(message);
this.status = status;
this.message = message;
}
}
export default HTTPException;

View File

@ -0,0 +1,10 @@
import { StatusCodes } from 'http-status-codes';
import HTTPException from './HttpException';
class InternalServerErrorException extends HTTPException {
constructor(message?: string) {
super(StatusCodes.INTERNAL_SERVER_ERROR, message || 'Server Error');
this.stack = '';
}
}
export default InternalServerErrorException;

View File

@ -56,6 +56,4 @@ export default class DatasetReference extends BaseModel {
foreignKey: 'related_document_id', foreignKey: 'related_document_id',
}) })
public new_dataset: BelongsTo<typeof Dataset>; public new_dataset: BelongsTo<typeof Dataset>;
} }

4
components.d.ts vendored
View File

@ -7,7 +7,7 @@ export {};
declare module '@vue/runtime-core' { declare module '@vue/runtime-core' {
export interface GlobalComponents { export interface GlobalComponents {
NButton: typeof import('naive-ui')['NButton']; NButton: (typeof import('naive-ui'))['NButton'];
NInput: typeof import('naive-ui')['NInput']; NInput: (typeof import('naive-ui'))['NInput'];
} }
} }

View File

@ -1,13 +1,14 @@
// ./contracts/enums.ts // ./contracts/enums.ts
export enum DatasetTypes { export enum DatasetTypes {
analysisdata = 'analysisdata', analysisdata = 'Analysis',
measurementdata = 'measurementdata', measurementdata = 'Measurements',
monitoring = 'monitoring', monitoring = 'Monitoring',
remotesensing = 'remotesensing', remotesensing = 'Remote Sensing',
gis = 'gis', gis = 'GIS',
models = 'models', models = 'Models',
mixedtype = 'mixedtype', mixedtype = 'Mixed Type',
vocabulary = 'Vocabulary',
} }
export enum ServerStates { export enum ServerStates {

View File

@ -31,7 +31,7 @@ export default class Documents extends BaseSchema {
.foreign('account_id', 'documents_account_id_foreign') .foreign('account_id', 'documents_account_id_foreign')
.references('id') .references('id')
.inTable('accounts') .inTable('accounts')
.onDelete('NO ACTION') // don't delete this when account is deleted .onDelete('NO ACTION') // don't delete this doc when account is deleted
.onUpdate('NO ACTION'); .onUpdate('NO ACTION');
table.integer('editor_id'); table.integer('editor_id');
table.integer('reviewer_id'); table.integer('reviewer_id');

348
package-lock.json generated
View File

@ -784,21 +784,21 @@
} }
}, },
"node_modules/@babel/core": { "node_modules/@babel/core": {
"version": "7.22.11", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/core/-/core-7.22.11.tgz", "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.22.15.tgz",
"integrity": "sha512-lh7RJrtPdhibbxndr6/xx0w8+CVlY5FJZiaSz908Fpy+G0xkBFTvwLcKJFF4PJxVfGhVWNebikpWGnOoC71juQ==", "integrity": "sha512-PtZqMmgRrvj8ruoEOIwVA3yoF91O+Hgw9o7DAUTNBA6Mo2jpu31clx9a7Nz/9JznqetTR6zwfC4L3LAjKQXUwA==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@ampproject/remapping": "^2.2.0", "@ampproject/remapping": "^2.2.0",
"@babel/code-frame": "^7.22.10", "@babel/code-frame": "^7.22.13",
"@babel/generator": "^7.22.10", "@babel/generator": "^7.22.15",
"@babel/helper-compilation-targets": "^7.22.10", "@babel/helper-compilation-targets": "^7.22.15",
"@babel/helper-module-transforms": "^7.22.9", "@babel/helper-module-transforms": "^7.22.15",
"@babel/helpers": "^7.22.11", "@babel/helpers": "^7.22.15",
"@babel/parser": "^7.22.11", "@babel/parser": "^7.22.15",
"@babel/template": "^7.22.5", "@babel/template": "^7.22.15",
"@babel/traverse": "^7.22.11", "@babel/traverse": "^7.22.15",
"@babel/types": "^7.22.11", "@babel/types": "^7.22.15",
"convert-source-map": "^1.7.0", "convert-source-map": "^1.7.0",
"debug": "^4.1.0", "debug": "^4.1.0",
"gensync": "^1.0.0-beta.2", "gensync": "^1.0.0-beta.2",
@ -823,12 +823,12 @@
} }
}, },
"node_modules/@babel/generator": { "node_modules/@babel/generator": {
"version": "7.22.10", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.22.10.tgz", "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.22.15.tgz",
"integrity": "sha512-79KIf7YiWjjdZ81JnLujDRApWtl7BxTqWD88+FFdQEIOG8LJ0etDOM7CXuIgGJa55sGOwZVwuEsaLEm0PJ5/+A==", "integrity": "sha512-Zu9oWARBqeVOW0dZOjXc3JObrzuqothQ3y/n1kUtrjCoCPLkXUwMvOo/F/TCfoHMbWIFlWwpZtkZVb9ga4U2pA==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/types": "^7.22.10", "@babel/types": "^7.22.15",
"@jridgewell/gen-mapping": "^0.3.2", "@jridgewell/gen-mapping": "^0.3.2",
"@jridgewell/trace-mapping": "^0.3.17", "@jridgewell/trace-mapping": "^0.3.17",
"jsesc": "^2.5.1" "jsesc": "^2.5.1"
@ -850,25 +850,25 @@
} }
}, },
"node_modules/@babel/helper-builder-binary-assignment-operator-visitor": { "node_modules/@babel/helper-builder-binary-assignment-operator-visitor": {
"version": "7.22.10", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/helper-builder-binary-assignment-operator-visitor/-/helper-builder-binary-assignment-operator-visitor-7.22.10.tgz", "resolved": "https://registry.npmjs.org/@babel/helper-builder-binary-assignment-operator-visitor/-/helper-builder-binary-assignment-operator-visitor-7.22.15.tgz",
"integrity": "sha512-Av0qubwDQxC56DoUReVDeLfMEjYYSN1nZrTUrWkXd7hpU73ymRANkbuDm3yni9npkn+RXy9nNbEJZEzXr7xrfQ==", "integrity": "sha512-QkBXwGgaoC2GtGZRoma6kv7Szfv06khvhFav67ZExau2RaXzy8MpHSMO2PNoP2XtmQphJQRHFfg77Bq731Yizw==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/types": "^7.22.10" "@babel/types": "^7.22.15"
}, },
"engines": { "engines": {
"node": ">=6.9.0" "node": ">=6.9.0"
} }
}, },
"node_modules/@babel/helper-compilation-targets": { "node_modules/@babel/helper-compilation-targets": {
"version": "7.22.10", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.22.10.tgz", "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.22.15.tgz",
"integrity": "sha512-JMSwHD4J7SLod0idLq5PKgI+6g/hLD/iuWBq08ZX49xE14VpVEojJ5rHWptpirV2j020MvypRLAXAO50igCJ5Q==", "integrity": "sha512-y6EEzULok0Qvz8yyLkCvVX+02ic+By2UdOhylwUOvOn9dvYc9mKICJuuU1n1XBI02YWsNsnrY1kc6DVbjcXbtw==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/compat-data": "^7.22.9", "@babel/compat-data": "^7.22.9",
"@babel/helper-validator-option": "^7.22.5", "@babel/helper-validator-option": "^7.22.15",
"browserslist": "^4.21.9", "browserslist": "^4.21.9",
"lru-cache": "^5.1.1", "lru-cache": "^5.1.1",
"semver": "^6.3.1" "semver": "^6.3.1"
@ -887,15 +887,15 @@
} }
}, },
"node_modules/@babel/helper-create-class-features-plugin": { "node_modules/@babel/helper-create-class-features-plugin": {
"version": "7.22.11", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.22.11.tgz", "resolved": "https://registry.npmjs.org/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.22.15.tgz",
"integrity": "sha512-y1grdYL4WzmUDBRGK0pDbIoFd7UZKoDurDzWEoNMYoj1EL+foGRQNyPWDcC+YyegN5y1DUsFFmzjGijB3nSVAQ==", "integrity": "sha512-jKkwA59IXcvSaiK2UN45kKwSC9o+KuoXsBDvHvU/7BecYIp8GQ2UwrVvFgJASUT+hBnwJx6MhvMCuMzwZZ7jlg==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/helper-annotate-as-pure": "^7.22.5", "@babel/helper-annotate-as-pure": "^7.22.5",
"@babel/helper-environment-visitor": "^7.22.5", "@babel/helper-environment-visitor": "^7.22.5",
"@babel/helper-function-name": "^7.22.5", "@babel/helper-function-name": "^7.22.5",
"@babel/helper-member-expression-to-functions": "^7.22.5", "@babel/helper-member-expression-to-functions": "^7.22.15",
"@babel/helper-optimise-call-expression": "^7.22.5", "@babel/helper-optimise-call-expression": "^7.22.5",
"@babel/helper-replace-supers": "^7.22.9", "@babel/helper-replace-supers": "^7.22.9",
"@babel/helper-skip-transparent-expression-wrappers": "^7.22.5", "@babel/helper-skip-transparent-expression-wrappers": "^7.22.5",
@ -919,9 +919,9 @@
} }
}, },
"node_modules/@babel/helper-create-regexp-features-plugin": { "node_modules/@babel/helper-create-regexp-features-plugin": {
"version": "7.22.9", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.22.9.tgz", "resolved": "https://registry.npmjs.org/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.22.15.tgz",
"integrity": "sha512-+svjVa/tFwsNSG4NEy1h85+HQ5imbT92Q5/bgtS7P0GTQlP8WuFdqsiABmQouhiFGyV66oGxZFpeYHza1rNsKw==", "integrity": "sha512-29FkPLFjn4TPEa3RE7GpW+qbE8tlsu3jntNYNfcGsc49LphF1PQIiD+vMZ1z1xVOKt+93khA9tc2JBs3kBjA7w==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/helper-annotate-as-pure": "^7.22.5", "@babel/helper-annotate-as-pure": "^7.22.5",
@ -995,40 +995,40 @@
} }
}, },
"node_modules/@babel/helper-member-expression-to-functions": { "node_modules/@babel/helper-member-expression-to-functions": {
"version": "7.22.5", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.22.5.tgz", "resolved": "https://registry.npmjs.org/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.22.15.tgz",
"integrity": "sha512-aBiH1NKMG0H2cGZqspNvsaBe6wNGjbJjuLy29aU+eDZjSbbN53BaxlpB02xm9v34pLTZ1nIQPFYn2qMZoa5BQQ==", "integrity": "sha512-qLNsZbgrNh0fDQBCPocSL8guki1hcPvltGDv/NxvUoABwFq7GkKSu1nRXeJkVZc+wJvne2E0RKQz+2SQrz6eAA==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/types": "^7.22.5" "@babel/types": "^7.22.15"
}, },
"engines": { "engines": {
"node": ">=6.9.0" "node": ">=6.9.0"
} }
}, },
"node_modules/@babel/helper-module-imports": { "node_modules/@babel/helper-module-imports": {
"version": "7.22.5", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.22.5.tgz", "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.22.15.tgz",
"integrity": "sha512-8Dl6+HD/cKifutF5qGd/8ZJi84QeAKh+CEe1sBzz8UayBBGg1dAIJrdHOcOM5b2MpzWL2yuotJTtGjETq0qjXg==", "integrity": "sha512-0pYVBnDKZO2fnSPCrgM/6WMc7eS20Fbok+0r88fp+YtWVLZrp4CkafFGIp+W0VKw4a22sgebPT99y+FDNMdP4w==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/types": "^7.22.5" "@babel/types": "^7.22.15"
}, },
"engines": { "engines": {
"node": ">=6.9.0" "node": ">=6.9.0"
} }
}, },
"node_modules/@babel/helper-module-transforms": { "node_modules/@babel/helper-module-transforms": {
"version": "7.22.9", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.22.9.tgz", "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.22.15.tgz",
"integrity": "sha512-t+WA2Xn5K+rTeGtC8jCsdAH52bjggG5TKRuRrAGNM/mjIbO4GxvlLMFOEz9wXY5I2XQ60PMFsAG2WIcG82dQMQ==", "integrity": "sha512-l1UiX4UyHSFsYt17iQ3Se5pQQZZHa22zyIXURmvkmLCD4t/aU+dvNWHatKac/D9Vm9UES7nvIqHs4jZqKviUmQ==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/helper-environment-visitor": "^7.22.5", "@babel/helper-environment-visitor": "^7.22.5",
"@babel/helper-module-imports": "^7.22.5", "@babel/helper-module-imports": "^7.22.15",
"@babel/helper-simple-access": "^7.22.5", "@babel/helper-simple-access": "^7.22.5",
"@babel/helper-split-export-declaration": "^7.22.6", "@babel/helper-split-export-declaration": "^7.22.6",
"@babel/helper-validator-identifier": "^7.22.5" "@babel/helper-validator-identifier": "^7.22.15"
}, },
"engines": { "engines": {
"node": ">=6.9.0" "node": ">=6.9.0"
@ -1138,18 +1138,18 @@
} }
}, },
"node_modules/@babel/helper-validator-identifier": { "node_modules/@babel/helper-validator-identifier": {
"version": "7.22.5", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.22.5.tgz", "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.22.15.tgz",
"integrity": "sha512-aJXu+6lErq8ltp+JhkJUfk1MTGyuA4v7f3pA+BJ5HLfNC6nAQ0Cpi9uOquUj8Hehg0aUiHzWQbOVJGao6ztBAQ==", "integrity": "sha512-4E/F9IIEi8WR94324mbDUMo074YTheJmd7eZF5vITTeYchqAi6sYXRLHUVsmkdmY4QjfKTcB2jB7dVP3NaBElQ==",
"dev": true, "dev": true,
"engines": { "engines": {
"node": ">=6.9.0" "node": ">=6.9.0"
} }
}, },
"node_modules/@babel/helper-validator-option": { "node_modules/@babel/helper-validator-option": {
"version": "7.22.5", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/helper-validator-option/-/helper-validator-option-7.22.5.tgz", "resolved": "https://registry.npmjs.org/@babel/helper-validator-option/-/helper-validator-option-7.22.15.tgz",
"integrity": "sha512-R3oB6xlIVKUnxNUxbmgq7pKjxpru24zlimpE8WK47fACIlM0II/Hm1RS8IaOI7NgCr6LNS+jl5l75m20npAziw==", "integrity": "sha512-bMn7RmyFjY/mdECUbgn9eoSY4vqvacUnS9i9vGAGttgFWesO6B4CYWA7XlpbWgBt71iv/hfbPlynohStqnu5hA==",
"dev": true, "dev": true,
"engines": { "engines": {
"node": ">=6.9.0" "node": ">=6.9.0"
@ -1170,14 +1170,14 @@
} }
}, },
"node_modules/@babel/helpers": { "node_modules/@babel/helpers": {
"version": "7.22.11", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.22.11.tgz", "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.22.15.tgz",
"integrity": "sha512-vyOXC8PBWaGc5h7GMsNx68OH33cypkEDJCHvYVVgVbbxJDROYVtexSk0gK5iCF1xNjRIN2s8ai7hwkWDq5szWg==", "integrity": "sha512-7pAjK0aSdxOwR+CcYAqgWOGy5dcfvzsTIfFTb2odQqW47MDfv14UaJDY6eng8ylM2EaeKXdxaSWESbkmaQHTmw==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/template": "^7.22.5", "@babel/template": "^7.22.15",
"@babel/traverse": "^7.22.11", "@babel/traverse": "^7.22.15",
"@babel/types": "^7.22.11" "@babel/types": "^7.22.15"
}, },
"engines": { "engines": {
"node": ">=6.9.0" "node": ">=6.9.0"
@ -1198,9 +1198,9 @@
} }
}, },
"node_modules/@babel/parser": { "node_modules/@babel/parser": {
"version": "7.22.14", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.22.14.tgz", "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.22.15.tgz",
"integrity": "sha512-1KucTHgOvaw/LzCVrEOAyXkr9rQlp0A1HiHRYnSUE9dmb8PvPW7o5sscg+5169r54n3vGlbx6GevTE/Iw/P3AQ==", "integrity": "sha512-RWmQ/sklUN9BvGGpCDgSubhHWfAx24XDTDObup4ffvxaYsptOg2P3KG0j+1eWKLxpkX0j0uHxmpq2Z1SP/VhxA==",
"bin": { "bin": {
"parser": "bin/babel-parser.js" "parser": "bin/babel-parser.js"
}, },
@ -1209,9 +1209,9 @@
} }
}, },
"node_modules/@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression": { "node_modules/@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression": {
"version": "7.22.5", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression/-/plugin-bugfix-safari-id-destructuring-collision-in-function-expression-7.22.5.tgz", "resolved": "https://registry.npmjs.org/@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression/-/plugin-bugfix-safari-id-destructuring-collision-in-function-expression-7.22.15.tgz",
"integrity": "sha512-NP1M5Rf+u2Gw9qfSO4ihjcTGW5zXTi36ITLd4/EoAcEhIZ0yjMqmftDNl3QC19CX7olhrjpyU454g/2W7X0jvQ==", "integrity": "sha512-FB9iYlz7rURmRJyXRKEnalYPPdn87H5no108cyuQQyMwlpJ2SJtpIUBI27kdTin956pz+LPypkPVPUTlxOmrsg==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/helper-plugin-utils": "^7.22.5" "@babel/helper-plugin-utils": "^7.22.5"
@ -1224,14 +1224,14 @@
} }
}, },
"node_modules/@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining": { "node_modules/@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining": {
"version": "7.22.5", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining/-/plugin-bugfix-v8-spread-parameters-in-optional-chaining-7.22.5.tgz", "resolved": "https://registry.npmjs.org/@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining/-/plugin-bugfix-v8-spread-parameters-in-optional-chaining-7.22.15.tgz",
"integrity": "sha512-31Bb65aZaUwqCbWMnZPduIZxCBngHFlzyN6Dq6KAJjtx+lx6ohKHubc61OomYi7XwVD4Ol0XCVz4h+pYFR048g==", "integrity": "sha512-Hyph9LseGvAeeXzikV88bczhsrLrIZqDPxO+sSmAunMPaGrBGhfMWzCPYTtiW9t+HzSE2wtV8e5cc5P6r1xMDQ==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/helper-plugin-utils": "^7.22.5", "@babel/helper-plugin-utils": "^7.22.5",
"@babel/helper-skip-transparent-expression-wrappers": "^7.22.5", "@babel/helper-skip-transparent-expression-wrappers": "^7.22.5",
"@babel/plugin-transform-optional-chaining": "^7.22.5" "@babel/plugin-transform-optional-chaining": "^7.22.15"
}, },
"engines": { "engines": {
"node": ">=6.9.0" "node": ">=6.9.0"
@ -1258,12 +1258,12 @@
} }
}, },
"node_modules/@babel/plugin-proposal-decorators": { "node_modules/@babel/plugin-proposal-decorators": {
"version": "7.22.10", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/plugin-proposal-decorators/-/plugin-proposal-decorators-7.22.10.tgz", "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-decorators/-/plugin-proposal-decorators-7.22.15.tgz",
"integrity": "sha512-KxN6TqZzcFi4uD3UifqXElBTBNLAEH1l3vzMQj6JwJZbL2sZlThxSViOKCYY+4Ah4V4JhQ95IVB7s/Y6SJSlMQ==", "integrity": "sha512-kc0VvbbUyKelvzcKOSyQUSVVXS5pT3UhRB0e3c9An86MvLqs+gx0dN4asllrDluqSa3m9YyooXKGOFVomnyFkg==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/helper-create-class-features-plugin": "^7.22.10", "@babel/helper-create-class-features-plugin": "^7.22.15",
"@babel/helper-plugin-utils": "^7.22.5", "@babel/helper-plugin-utils": "^7.22.5",
"@babel/helper-replace-supers": "^7.22.9", "@babel/helper-replace-supers": "^7.22.9",
"@babel/helper-split-export-declaration": "^7.22.6", "@babel/helper-split-export-declaration": "^7.22.6",
@ -1584,9 +1584,9 @@
} }
}, },
"node_modules/@babel/plugin-transform-async-generator-functions": { "node_modules/@babel/plugin-transform-async-generator-functions": {
"version": "7.22.11", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/plugin-transform-async-generator-functions/-/plugin-transform-async-generator-functions-7.22.11.tgz", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-async-generator-functions/-/plugin-transform-async-generator-functions-7.22.15.tgz",
"integrity": "sha512-0pAlmeRJn6wU84zzZsEOx1JV1Jf8fqO9ok7wofIJwUnplYo247dcd24P+cMJht7ts9xkzdtB0EPHmOb7F+KzXw==", "integrity": "sha512-jBm1Es25Y+tVoTi5rfd5t1KLmL8ogLKpXszboWOTTtGFGz2RKnQe2yn7HbZ+kb/B8N0FVSGQo874NSlOU1T4+w==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/helper-environment-visitor": "^7.22.5", "@babel/helper-environment-visitor": "^7.22.5",
@ -1634,9 +1634,9 @@
} }
}, },
"node_modules/@babel/plugin-transform-block-scoping": { "node_modules/@babel/plugin-transform-block-scoping": {
"version": "7.22.10", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.22.10.tgz", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.22.15.tgz",
"integrity": "sha512-1+kVpGAOOI1Albt6Vse7c8pHzcZQdQKW+wJH+g8mCaszOdDVwRXa/slHPqIw+oJAJANTKDMuM2cBdV0Dg618Vg==", "integrity": "sha512-G1czpdJBZCtngoK1sJgloLiOHUnkb/bLZwqVZD8kXmq0ZnVfTTWUcs9OWtp0mBtYJ+4LQY1fllqBkOIPhXmFmw==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/helper-plugin-utils": "^7.22.5" "@babel/helper-plugin-utils": "^7.22.5"
@ -1682,18 +1682,18 @@
} }
}, },
"node_modules/@babel/plugin-transform-classes": { "node_modules/@babel/plugin-transform-classes": {
"version": "7.22.6", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/plugin-transform-classes/-/plugin-transform-classes-7.22.6.tgz", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-classes/-/plugin-transform-classes-7.22.15.tgz",
"integrity": "sha512-58EgM6nuPNG6Py4Z3zSuu0xWu2VfodiMi72Jt5Kj2FECmaYk1RrTXA45z6KBFsu9tRgwQDwIiY4FXTt+YsSFAQ==", "integrity": "sha512-VbbC3PGjBdE0wAWDdHM9G8Gm977pnYI0XpqMd6LrKISj8/DJXEsWqgRuTYaNE9Bv0JGhTZUzHDlMk18IpOuoqw==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/helper-annotate-as-pure": "^7.22.5", "@babel/helper-annotate-as-pure": "^7.22.5",
"@babel/helper-compilation-targets": "^7.22.6", "@babel/helper-compilation-targets": "^7.22.15",
"@babel/helper-environment-visitor": "^7.22.5", "@babel/helper-environment-visitor": "^7.22.5",
"@babel/helper-function-name": "^7.22.5", "@babel/helper-function-name": "^7.22.5",
"@babel/helper-optimise-call-expression": "^7.22.5", "@babel/helper-optimise-call-expression": "^7.22.5",
"@babel/helper-plugin-utils": "^7.22.5", "@babel/helper-plugin-utils": "^7.22.5",
"@babel/helper-replace-supers": "^7.22.5", "@babel/helper-replace-supers": "^7.22.9",
"@babel/helper-split-export-declaration": "^7.22.6", "@babel/helper-split-export-declaration": "^7.22.6",
"globals": "^11.1.0" "globals": "^11.1.0"
}, },
@ -1721,9 +1721,9 @@
} }
}, },
"node_modules/@babel/plugin-transform-destructuring": { "node_modules/@babel/plugin-transform-destructuring": {
"version": "7.22.10", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/plugin-transform-destructuring/-/plugin-transform-destructuring-7.22.10.tgz", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-destructuring/-/plugin-transform-destructuring-7.22.15.tgz",
"integrity": "sha512-dPJrL0VOyxqLM9sritNbMSGx/teueHF/htMKrPT7DNxccXxRDPYqlgPFFdr8u+F+qUZOkZoXue/6rL5O5GduEw==", "integrity": "sha512-HzG8sFl1ZVGTme74Nw+X01XsUTqERVQ6/RLHo3XjGRzm7XD6QTtfS3NJotVgCGy8BzkDqRjRBD8dAyJn5TuvSQ==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/helper-plugin-utils": "^7.22.5" "@babel/helper-plugin-utils": "^7.22.5"
@ -1815,9 +1815,9 @@
} }
}, },
"node_modules/@babel/plugin-transform-for-of": { "node_modules/@babel/plugin-transform-for-of": {
"version": "7.22.5", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.22.5.tgz", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.22.15.tgz",
"integrity": "sha512-3kxQjX1dU9uudwSshyLeEipvrLjBCVthCgeTp6CzE/9JYrlAIaeekVxRpCWsDDfYTfRZRoCeZatCQvwo+wvK8A==", "integrity": "sha512-me6VGeHsx30+xh9fbDLLPi0J1HzmeIIyenoOQHuw2D4m2SAU3NrspX5XxJLBpqn5yrLzrlw2Iy3RA//Bx27iOA==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/helper-plugin-utils": "^7.22.5" "@babel/helper-plugin-utils": "^7.22.5"
@ -1925,12 +1925,12 @@
} }
}, },
"node_modules/@babel/plugin-transform-modules-commonjs": { "node_modules/@babel/plugin-transform-modules-commonjs": {
"version": "7.22.11", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.22.11.tgz", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.22.15.tgz",
"integrity": "sha512-o2+bg7GDS60cJMgz9jWqRUsWkMzLCxp+jFDeDUT5sjRlAxcJWZ2ylNdI7QQ2+CH5hWu7OnN+Cv3htt7AkSf96g==", "integrity": "sha512-jWL4eh90w0HQOTKP2MoXXUpVxilxsB2Vl4ji69rSjS3EcZ/v4sBmn+A3NpepuJzBhOaEBbR7udonlHHn5DWidg==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/helper-module-transforms": "^7.22.9", "@babel/helper-module-transforms": "^7.22.15",
"@babel/helper-plugin-utils": "^7.22.5", "@babel/helper-plugin-utils": "^7.22.5",
"@babel/helper-simple-access": "^7.22.5" "@babel/helper-simple-access": "^7.22.5"
}, },
@ -2039,16 +2039,16 @@
} }
}, },
"node_modules/@babel/plugin-transform-object-rest-spread": { "node_modules/@babel/plugin-transform-object-rest-spread": {
"version": "7.22.11", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/plugin-transform-object-rest-spread/-/plugin-transform-object-rest-spread-7.22.11.tgz", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-object-rest-spread/-/plugin-transform-object-rest-spread-7.22.15.tgz",
"integrity": "sha512-nX8cPFa6+UmbepISvlf5jhQyaC7ASs/7UxHmMkuJ/k5xSHvDPPaibMo+v3TXwU/Pjqhep/nFNpd3zn4YR59pnw==", "integrity": "sha512-fEB+I1+gAmfAyxZcX1+ZUwLeAuuf8VIg67CTznZE0MqVFumWkh8xWtn58I4dxdVf080wn7gzWoF8vndOViJe9Q==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/compat-data": "^7.22.9", "@babel/compat-data": "^7.22.9",
"@babel/helper-compilation-targets": "^7.22.10", "@babel/helper-compilation-targets": "^7.22.15",
"@babel/helper-plugin-utils": "^7.22.5", "@babel/helper-plugin-utils": "^7.22.5",
"@babel/plugin-syntax-object-rest-spread": "^7.8.3", "@babel/plugin-syntax-object-rest-spread": "^7.8.3",
"@babel/plugin-transform-parameters": "^7.22.5" "@babel/plugin-transform-parameters": "^7.22.15"
}, },
"engines": { "engines": {
"node": ">=6.9.0" "node": ">=6.9.0"
@ -2090,9 +2090,9 @@
} }
}, },
"node_modules/@babel/plugin-transform-optional-chaining": { "node_modules/@babel/plugin-transform-optional-chaining": {
"version": "7.22.12", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/plugin-transform-optional-chaining/-/plugin-transform-optional-chaining-7.22.12.tgz", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-optional-chaining/-/plugin-transform-optional-chaining-7.22.15.tgz",
"integrity": "sha512-7XXCVqZtyFWqjDsYDY4T45w4mlx1rf7aOgkc/Ww76xkgBiOlmjPkx36PBLHa1k1rwWvVgYMPsbuVnIamx2ZQJw==", "integrity": "sha512-ngQ2tBhq5vvSJw2Q2Z9i7ealNkpDMU0rGWnHPKqRZO0tzZ5tlaoz4hDvhXioOoaE0X2vfNss1djwg0DXlfu30A==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/helper-plugin-utils": "^7.22.5", "@babel/helper-plugin-utils": "^7.22.5",
@ -2107,9 +2107,9 @@
} }
}, },
"node_modules/@babel/plugin-transform-parameters": { "node_modules/@babel/plugin-transform-parameters": {
"version": "7.22.5", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/plugin-transform-parameters/-/plugin-transform-parameters-7.22.5.tgz", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-parameters/-/plugin-transform-parameters-7.22.15.tgz",
"integrity": "sha512-AVkFUBurORBREOmHRKo06FjHYgjrabpdqRSwq6+C7R5iTCZOsM4QbcB27St0a4U6fffyAOqh3s/qEfybAhfivg==", "integrity": "sha512-hjk7qKIqhyzhhUvRT683TYQOFa/4cQKwQy7ALvTpODswN40MljzNDa0YldevS6tGbxwaEKVn502JmY0dP7qEtQ==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/helper-plugin-utils": "^7.22.5" "@babel/helper-plugin-utils": "^7.22.5"
@ -2202,12 +2202,12 @@
} }
}, },
"node_modules/@babel/plugin-transform-runtime": { "node_modules/@babel/plugin-transform-runtime": {
"version": "7.22.10", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/plugin-transform-runtime/-/plugin-transform-runtime-7.22.10.tgz", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-runtime/-/plugin-transform-runtime-7.22.15.tgz",
"integrity": "sha512-RchI7HePu1eu0CYNKHHHQdfenZcM4nz8rew5B1VWqeRKdcwW5aQ5HeG9eTUbWiAS1UrmHVLmoxTWHt3iLD/NhA==", "integrity": "sha512-tEVLhk8NRZSmwQ0DJtxxhTrCht1HVo8VaMzYT4w6lwyKBuHsgoioAUA7/6eT2fRfc5/23fuGdlwIxXhRVgWr4g==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/helper-module-imports": "^7.22.5", "@babel/helper-module-imports": "^7.22.15",
"@babel/helper-plugin-utils": "^7.22.5", "@babel/helper-plugin-utils": "^7.22.5",
"babel-plugin-polyfill-corejs2": "^0.4.5", "babel-plugin-polyfill-corejs2": "^0.4.5",
"babel-plugin-polyfill-corejs3": "^0.8.3", "babel-plugin-polyfill-corejs3": "^0.8.3",
@ -2307,13 +2307,13 @@
} }
}, },
"node_modules/@babel/plugin-transform-typescript": { "node_modules/@babel/plugin-transform-typescript": {
"version": "7.22.11", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/plugin-transform-typescript/-/plugin-transform-typescript-7.22.11.tgz", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-typescript/-/plugin-transform-typescript-7.22.15.tgz",
"integrity": "sha512-0E4/L+7gfvHub7wsbTv03oRtD69X31LByy44fGmFzbZScpupFByMcgCJ0VbBTkzyjSJKuRoGN8tcijOWKTmqOA==", "integrity": "sha512-1uirS0TnijxvQLnlv5wQBwOX3E1wCFX7ITv+9pBV2wKEk4K+M5tqDaoNXnTH8tjEIYHLO98MwiTWO04Ggz4XuA==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/helper-annotate-as-pure": "^7.22.5", "@babel/helper-annotate-as-pure": "^7.22.5",
"@babel/helper-create-class-features-plugin": "^7.22.11", "@babel/helper-create-class-features-plugin": "^7.22.15",
"@babel/helper-plugin-utils": "^7.22.5", "@babel/helper-plugin-utils": "^7.22.5",
"@babel/plugin-syntax-typescript": "^7.22.5" "@babel/plugin-syntax-typescript": "^7.22.5"
}, },
@ -2388,17 +2388,17 @@
} }
}, },
"node_modules/@babel/preset-env": { "node_modules/@babel/preset-env": {
"version": "7.22.14", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/preset-env/-/preset-env-7.22.14.tgz", "resolved": "https://registry.npmjs.org/@babel/preset-env/-/preset-env-7.22.15.tgz",
"integrity": "sha512-daodMIoVo+ol/g+//c/AH+szBkFj4STQUikvBijRGL72Ph+w+AMTSh55DUETe8KJlPlDT1k/mp7NBfOuiWmoig==", "integrity": "sha512-tZFHr54GBkHk6hQuVA8w4Fmq+MSPsfvMG0vPnOYyTnJpyfMqybL8/MbNCPRT9zc2KBO2pe4tq15g6Uno4Jpoag==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/compat-data": "^7.22.9", "@babel/compat-data": "^7.22.9",
"@babel/helper-compilation-targets": "^7.22.10", "@babel/helper-compilation-targets": "^7.22.15",
"@babel/helper-plugin-utils": "^7.22.5", "@babel/helper-plugin-utils": "^7.22.5",
"@babel/helper-validator-option": "^7.22.5", "@babel/helper-validator-option": "^7.22.15",
"@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression": "^7.22.5", "@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression": "^7.22.15",
"@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining": "^7.22.5", "@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining": "^7.22.15",
"@babel/plugin-proposal-private-property-in-object": "7.21.0-placeholder-for-preset-env.2", "@babel/plugin-proposal-private-property-in-object": "7.21.0-placeholder-for-preset-env.2",
"@babel/plugin-syntax-async-generators": "^7.8.4", "@babel/plugin-syntax-async-generators": "^7.8.4",
"@babel/plugin-syntax-class-properties": "^7.12.13", "@babel/plugin-syntax-class-properties": "^7.12.13",
@ -2419,39 +2419,39 @@
"@babel/plugin-syntax-top-level-await": "^7.14.5", "@babel/plugin-syntax-top-level-await": "^7.14.5",
"@babel/plugin-syntax-unicode-sets-regex": "^7.18.6", "@babel/plugin-syntax-unicode-sets-regex": "^7.18.6",
"@babel/plugin-transform-arrow-functions": "^7.22.5", "@babel/plugin-transform-arrow-functions": "^7.22.5",
"@babel/plugin-transform-async-generator-functions": "^7.22.11", "@babel/plugin-transform-async-generator-functions": "^7.22.15",
"@babel/plugin-transform-async-to-generator": "^7.22.5", "@babel/plugin-transform-async-to-generator": "^7.22.5",
"@babel/plugin-transform-block-scoped-functions": "^7.22.5", "@babel/plugin-transform-block-scoped-functions": "^7.22.5",
"@babel/plugin-transform-block-scoping": "^7.22.10", "@babel/plugin-transform-block-scoping": "^7.22.15",
"@babel/plugin-transform-class-properties": "^7.22.5", "@babel/plugin-transform-class-properties": "^7.22.5",
"@babel/plugin-transform-class-static-block": "^7.22.11", "@babel/plugin-transform-class-static-block": "^7.22.11",
"@babel/plugin-transform-classes": "^7.22.6", "@babel/plugin-transform-classes": "^7.22.15",
"@babel/plugin-transform-computed-properties": "^7.22.5", "@babel/plugin-transform-computed-properties": "^7.22.5",
"@babel/plugin-transform-destructuring": "^7.22.10", "@babel/plugin-transform-destructuring": "^7.22.15",
"@babel/plugin-transform-dotall-regex": "^7.22.5", "@babel/plugin-transform-dotall-regex": "^7.22.5",
"@babel/plugin-transform-duplicate-keys": "^7.22.5", "@babel/plugin-transform-duplicate-keys": "^7.22.5",
"@babel/plugin-transform-dynamic-import": "^7.22.11", "@babel/plugin-transform-dynamic-import": "^7.22.11",
"@babel/plugin-transform-exponentiation-operator": "^7.22.5", "@babel/plugin-transform-exponentiation-operator": "^7.22.5",
"@babel/plugin-transform-export-namespace-from": "^7.22.11", "@babel/plugin-transform-export-namespace-from": "^7.22.11",
"@babel/plugin-transform-for-of": "^7.22.5", "@babel/plugin-transform-for-of": "^7.22.15",
"@babel/plugin-transform-function-name": "^7.22.5", "@babel/plugin-transform-function-name": "^7.22.5",
"@babel/plugin-transform-json-strings": "^7.22.11", "@babel/plugin-transform-json-strings": "^7.22.11",
"@babel/plugin-transform-literals": "^7.22.5", "@babel/plugin-transform-literals": "^7.22.5",
"@babel/plugin-transform-logical-assignment-operators": "^7.22.11", "@babel/plugin-transform-logical-assignment-operators": "^7.22.11",
"@babel/plugin-transform-member-expression-literals": "^7.22.5", "@babel/plugin-transform-member-expression-literals": "^7.22.5",
"@babel/plugin-transform-modules-amd": "^7.22.5", "@babel/plugin-transform-modules-amd": "^7.22.5",
"@babel/plugin-transform-modules-commonjs": "^7.22.11", "@babel/plugin-transform-modules-commonjs": "^7.22.15",
"@babel/plugin-transform-modules-systemjs": "^7.22.11", "@babel/plugin-transform-modules-systemjs": "^7.22.11",
"@babel/plugin-transform-modules-umd": "^7.22.5", "@babel/plugin-transform-modules-umd": "^7.22.5",
"@babel/plugin-transform-named-capturing-groups-regex": "^7.22.5", "@babel/plugin-transform-named-capturing-groups-regex": "^7.22.5",
"@babel/plugin-transform-new-target": "^7.22.5", "@babel/plugin-transform-new-target": "^7.22.5",
"@babel/plugin-transform-nullish-coalescing-operator": "^7.22.11", "@babel/plugin-transform-nullish-coalescing-operator": "^7.22.11",
"@babel/plugin-transform-numeric-separator": "^7.22.11", "@babel/plugin-transform-numeric-separator": "^7.22.11",
"@babel/plugin-transform-object-rest-spread": "^7.22.11", "@babel/plugin-transform-object-rest-spread": "^7.22.15",
"@babel/plugin-transform-object-super": "^7.22.5", "@babel/plugin-transform-object-super": "^7.22.5",
"@babel/plugin-transform-optional-catch-binding": "^7.22.11", "@babel/plugin-transform-optional-catch-binding": "^7.22.11",
"@babel/plugin-transform-optional-chaining": "^7.22.12", "@babel/plugin-transform-optional-chaining": "^7.22.15",
"@babel/plugin-transform-parameters": "^7.22.5", "@babel/plugin-transform-parameters": "^7.22.15",
"@babel/plugin-transform-private-methods": "^7.22.5", "@babel/plugin-transform-private-methods": "^7.22.5",
"@babel/plugin-transform-private-property-in-object": "^7.22.11", "@babel/plugin-transform-private-property-in-object": "^7.22.11",
"@babel/plugin-transform-property-literals": "^7.22.5", "@babel/plugin-transform-property-literals": "^7.22.5",
@ -2467,7 +2467,7 @@
"@babel/plugin-transform-unicode-regex": "^7.22.5", "@babel/plugin-transform-unicode-regex": "^7.22.5",
"@babel/plugin-transform-unicode-sets-regex": "^7.22.5", "@babel/plugin-transform-unicode-sets-regex": "^7.22.5",
"@babel/preset-modules": "0.1.6-no-external-plugins", "@babel/preset-modules": "0.1.6-no-external-plugins",
"@babel/types": "^7.22.11", "@babel/types": "^7.22.15",
"babel-plugin-polyfill-corejs2": "^0.4.5", "babel-plugin-polyfill-corejs2": "^0.4.5",
"babel-plugin-polyfill-corejs3": "^0.8.3", "babel-plugin-polyfill-corejs3": "^0.8.3",
"babel-plugin-polyfill-regenerator": "^0.5.2", "babel-plugin-polyfill-regenerator": "^0.5.2",
@ -2505,16 +2505,16 @@
} }
}, },
"node_modules/@babel/preset-typescript": { "node_modules/@babel/preset-typescript": {
"version": "7.22.11", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/preset-typescript/-/preset-typescript-7.22.11.tgz", "resolved": "https://registry.npmjs.org/@babel/preset-typescript/-/preset-typescript-7.22.15.tgz",
"integrity": "sha512-tWY5wyCZYBGY7IlalfKI1rLiGlIfnwsRHZqlky0HVv8qviwQ1Uo/05M6+s+TcTCVa6Bmoo2uJW5TMFX6Wa4qVg==", "integrity": "sha512-HblhNmh6yM+cU4VwbBRpxFhxsTdfS1zsvH9W+gEjD0ARV9+8B4sNfpI6GuhePti84nuvhiwKS539jKPFHskA9A==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/helper-plugin-utils": "^7.22.5", "@babel/helper-plugin-utils": "^7.22.5",
"@babel/helper-validator-option": "^7.22.5", "@babel/helper-validator-option": "^7.22.15",
"@babel/plugin-syntax-jsx": "^7.22.5", "@babel/plugin-syntax-jsx": "^7.22.5",
"@babel/plugin-transform-modules-commonjs": "^7.22.11", "@babel/plugin-transform-modules-commonjs": "^7.22.15",
"@babel/plugin-transform-typescript": "^7.22.11" "@babel/plugin-transform-typescript": "^7.22.15"
}, },
"engines": { "engines": {
"node": ">=6.9.0" "node": ">=6.9.0"
@ -2530,9 +2530,9 @@
"dev": true "dev": true
}, },
"node_modules/@babel/runtime": { "node_modules/@babel/runtime": {
"version": "7.22.11", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.22.11.tgz", "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.22.15.tgz",
"integrity": "sha512-ee7jVNlWN09+KftVOu9n7S8gQzD/Z6hN/I8VBRXW4P1+Xe7kJGXMwu8vds4aGIMHZnNbdpSWCfZZtinytpcAvA==", "integrity": "sha512-T0O+aa+4w0u06iNmapipJXMV4HoUir03hpx3/YqXXhu9xim3w+dVphjFWl1OH8NbZHw5Lbm9k45drDkgq2VNNA==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"regenerator-runtime": "^0.14.0" "regenerator-runtime": "^0.14.0"
@ -2542,33 +2542,33 @@
} }
}, },
"node_modules/@babel/template": { "node_modules/@babel/template": {
"version": "7.22.5", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/template/-/template-7.22.5.tgz", "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.22.15.tgz",
"integrity": "sha512-X7yV7eiwAxdj9k94NEylvbVHLiVG1nvzCV2EAowhxLTwODV1jl9UzZ48leOC0sH7OnuHrIkllaBgneUykIcZaw==", "integrity": "sha512-QPErUVm4uyJa60rkI73qneDacvdvzxshT3kksGqlGWYdOTIUOwJ7RDUL8sGqslY1uXWSL6xMFKEXDS3ox2uF0w==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/code-frame": "^7.22.5", "@babel/code-frame": "^7.22.13",
"@babel/parser": "^7.22.5", "@babel/parser": "^7.22.15",
"@babel/types": "^7.22.5" "@babel/types": "^7.22.15"
}, },
"engines": { "engines": {
"node": ">=6.9.0" "node": ">=6.9.0"
} }
}, },
"node_modules/@babel/traverse": { "node_modules/@babel/traverse": {
"version": "7.22.11", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.22.11.tgz", "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.22.15.tgz",
"integrity": "sha512-mzAenteTfomcB7mfPtyi+4oe5BZ6MXxWcn4CX+h4IRJ+OOGXBrWU6jDQavkQI9Vuc5P+donFabBfFCcmWka9lQ==", "integrity": "sha512-DdHPwvJY0sEeN4xJU5uRLmZjgMMDIvMPniLuYzUVXj/GGzysPl0/fwt44JBkyUIzGJPV8QgHMcQdQ34XFuKTYQ==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/code-frame": "^7.22.10", "@babel/code-frame": "^7.22.13",
"@babel/generator": "^7.22.10", "@babel/generator": "^7.22.15",
"@babel/helper-environment-visitor": "^7.22.5", "@babel/helper-environment-visitor": "^7.22.5",
"@babel/helper-function-name": "^7.22.5", "@babel/helper-function-name": "^7.22.5",
"@babel/helper-hoist-variables": "^7.22.5", "@babel/helper-hoist-variables": "^7.22.5",
"@babel/helper-split-export-declaration": "^7.22.6", "@babel/helper-split-export-declaration": "^7.22.6",
"@babel/parser": "^7.22.11", "@babel/parser": "^7.22.15",
"@babel/types": "^7.22.11", "@babel/types": "^7.22.15",
"debug": "^4.1.0", "debug": "^4.1.0",
"globals": "^11.1.0" "globals": "^11.1.0"
}, },
@ -2577,13 +2577,13 @@
} }
}, },
"node_modules/@babel/types": { "node_modules/@babel/types": {
"version": "7.22.11", "version": "7.22.15",
"resolved": "https://registry.npmjs.org/@babel/types/-/types-7.22.11.tgz", "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.22.15.tgz",
"integrity": "sha512-siazHiGuZRz9aB9NpHy9GOs9xiQPKnMzgdr493iI1M67vRXpnEq8ZOOKzezC5q7zwuQ6sDhdSp4SD9ixKSqKZg==", "integrity": "sha512-X+NLXr0N8XXmN5ZsaQdm9U2SSC3UbIYq/doL++sueHOTisgZHoKaQtZxGuV2cUPQHMfjKEfg/g6oy7Hm6SKFtA==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@babel/helper-string-parser": "^7.22.5", "@babel/helper-string-parser": "^7.22.5",
"@babel/helper-validator-identifier": "^7.22.5", "@babel/helper-validator-identifier": "^7.22.15",
"to-fast-properties": "^2.0.0" "to-fast-properties": "^2.0.0"
}, },
"engines": { "engines": {
@ -3810,15 +3810,15 @@
"integrity": "sha512-lOGyCnw+2JVPKU3wIV0srU0NyALwTBJlVSx5DfMQOFuuohA8y9S8orImpuIQikZ0uIQ8gehrRjxgQC1rLRi11w==" "integrity": "sha512-lOGyCnw+2JVPKU3wIV0srU0NyALwTBJlVSx5DfMQOFuuohA8y9S8orImpuIQikZ0uIQ8gehrRjxgQC1rLRi11w=="
}, },
"node_modules/@types/chai": { "node_modules/@types/chai": {
"version": "4.3.5", "version": "4.3.6",
"resolved": "https://registry.npmjs.org/@types/chai/-/chai-4.3.5.tgz", "resolved": "https://registry.npmjs.org/@types/chai/-/chai-4.3.6.tgz",
"integrity": "sha512-mEo1sAde+UCE6b2hxn332f1g1E8WfYRu6p5SvTKr2ZKC1f7gFJXk4h5PyGP9Dt6gCaG8y8XhwnXWC6Iy2cmBng==", "integrity": "sha512-VOVRLM1mBxIRxydiViqPcKn6MIxZytrbMpd6RJLIWKxUNr3zux8no0Oc7kJx0WAPIitgZ0gkrDS+btlqQpubpw==",
"dev": true "dev": true
}, },
"node_modules/@types/clamscan": { "node_modules/@types/clamscan": {
"version": "2.0.4", "version": "2.0.5",
"resolved": "https://registry.npmjs.org/@types/clamscan/-/clamscan-2.0.4.tgz", "resolved": "https://registry.npmjs.org/@types/clamscan/-/clamscan-2.0.5.tgz",
"integrity": "sha512-NpD+EmE+ZK5WRJOAmeDuSYJIv15BUnc4PxQA+m3QNkutaPBZ7bmLDTvqBu2iDchs7YKQjiEQEwEMvsdwtdtImA==", "integrity": "sha512-bFqdscswqBia3yKEJZVVWELOVvWKHUR1dCmH4xshYwu0T9YSfZd35Q8Z9jYW0ygxqGlHjLXMb2/7C6CJITbDgg==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@types/node": "*", "@types/node": "*",
@ -3835,18 +3835,18 @@
} }
}, },
"node_modules/@types/connect": { "node_modules/@types/connect": {
"version": "3.4.35", "version": "3.4.36",
"resolved": "https://registry.npmjs.org/@types/connect/-/connect-3.4.35.tgz", "resolved": "https://registry.npmjs.org/@types/connect/-/connect-3.4.36.tgz",
"integrity": "sha512-cdeYyv4KWoEgpBISTxWvqYsVy444DOqehiF3fM3ne10AmJ62RSyNkUnxMJXHQWRQQX2eR94m5y1IZyDwBjV9FQ==", "integrity": "sha512-P63Zd/JUGq+PdrM1lv0Wv5SBYeA2+CORvbrXbngriYY0jzLUWfQMQQxOhjONEz/wlHOAxOdY7CY65rgQdTjq2w==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@types/node": "*" "@types/node": "*"
} }
}, },
"node_modules/@types/connect-history-api-fallback": { "node_modules/@types/connect-history-api-fallback": {
"version": "1.5.0", "version": "1.5.1",
"resolved": "https://registry.npmjs.org/@types/connect-history-api-fallback/-/connect-history-api-fallback-1.5.0.tgz", "resolved": "https://registry.npmjs.org/@types/connect-history-api-fallback/-/connect-history-api-fallback-1.5.1.tgz",
"integrity": "sha512-4x5FkPpLipqwthjPsF7ZRbOv3uoLUFkTA9G9v583qi4pACvq0uTELrB8OLUzPWUI4IJIyvM85vzkV1nyiI2Lig==", "integrity": "sha512-iaQslNbARe8fctL5Lk+DsmgWOM83lM+7FzP0eQUJs1jd3kBE8NWqBTIT2S8SqQOJjxvt2eyIjpOuYeRXq2AdMw==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@types/express-serve-static-core": "*", "@types/express-serve-static-core": "*",
@ -6082,9 +6082,9 @@
} }
}, },
"node_modules/caniuse-lite": { "node_modules/caniuse-lite": {
"version": "1.0.30001525", "version": "1.0.30001527",
"resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001525.tgz", "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001527.tgz",
"integrity": "sha512-/3z+wB4icFt3r0USMwxujAqRvaD/B7rvGTsKhbhSQErVrJvkZCLhgNLJxU8MevahQVH6hCU9FsHdNUFbiwmE7Q==", "integrity": "sha512-YkJi7RwPgWtXVSgK4lG9AHH57nSzvvOp9MesgXmw4Q7n0C3H04L0foHqfxcmSAm5AcWb8dW9AYj2tR7/5GnddQ==",
"dev": true, "dev": true,
"funding": [ "funding": [
{ {
@ -6752,9 +6752,9 @@
"dev": true "dev": true
}, },
"node_modules/cosmiconfig": { "node_modules/cosmiconfig": {
"version": "8.3.3", "version": "8.3.4",
"resolved": "https://registry.npmjs.org/cosmiconfig/-/cosmiconfig-8.3.3.tgz", "resolved": "https://registry.npmjs.org/cosmiconfig/-/cosmiconfig-8.3.4.tgz",
"integrity": "sha512-/VY+0IvFoE47hwgKHu8feeBFIb1Z1mcJFiLrNwaJpLoLa9qwLVquMGMr2OUwQmhpJDtsSQSasg/TMv1imec9xA==", "integrity": "sha512-SF+2P8+o/PTV05rgsAjDzL4OFdVXAulSfC/L19VaeVT7+tpOOSscCt2QLxDZ+CLxF2WOiq6y1K5asvs8qUJT/Q==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"import-fresh": "^3.3.0", "import-fresh": "^3.3.0",
@ -15962,9 +15962,9 @@
} }
}, },
"node_modules/terser": { "node_modules/terser": {
"version": "5.19.3", "version": "5.19.4",
"resolved": "https://registry.npmjs.org/terser/-/terser-5.19.3.tgz", "resolved": "https://registry.npmjs.org/terser/-/terser-5.19.4.tgz",
"integrity": "sha512-pQzJ9UJzM0IgmT4FAtYI6+VqFf0lj/to58AV0Xfgg0Up37RyPG7Al+1cepC6/BVuAxR9oNb41/DL4DEoHJvTdg==", "integrity": "sha512-6p1DjHeuluwxDXcuT9VR8p64klWJKo1ILiy19s6C9+0Bh2+NWTX6nD9EPppiER4ICkHDVB1RkVpin/YW2nQn/g==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@jridgewell/source-map": "^0.3.3", "@jridgewell/source-map": "^0.3.3",

View File

@ -3,6 +3,8 @@ import { computed, ref } from 'vue';
// import { MainService } from '@/Stores/main'; // import { MainService } from '@/Stores/main';
import { StyleService } from '@/Stores/style'; import { StyleService } from '@/Stores/style';
import { mdiTrashCan } from '@mdi/js'; import { mdiTrashCan } from '@mdi/js';
import { mdiDragVariant } from '@mdi/js';
import BaseIcon from '@/Components/BaseIcon.vue';
// import CardBoxModal from '@/Components/CardBoxModal.vue'; // import CardBoxModal from '@/Components/CardBoxModal.vue';
// import TableCheckboxCell from '@/Components/TableCheckboxCell.vue'; // import TableCheckboxCell from '@/Components/TableCheckboxCell.vue';
import BaseLevel from '@/Components/BaseLevel.vue'; import BaseLevel from '@/Components/BaseLevel.vue';
@ -118,6 +120,7 @@ const removeAuthor = (key) => {
<thead> <thead>
<tr> <tr>
<!-- <th v-if="checkable" /> --> <!-- <th v-if="checkable" /> -->
<th />
<th scope="col">Sort</th> <th scope="col">Sort</th>
<th class="hidden lg:table-cell"></th> <th class="hidden lg:table-cell"></th>
<th>Name</th> <th>Name</th>
@ -133,6 +136,7 @@ const removeAuthor = (key) => {
<draggable id="galliwasery" tag="tbody" v-model="items" item-key="id"> <draggable id="galliwasery" tag="tbody" v-model="items" item-key="id">
<template #item="{ index, element }"> <template #item="{ index, element }">
<tr> <tr>
<td class="drag-icon"><BaseIcon :path="mdiDragVariant"/></td>
<td scope="row">{{ index + 1 }}</td> <td scope="row">{{ index + 1 }}</td>
<!-- <TableCheckboxCell v-if="checkable" @checked="checked($event, client)" /> --> <!-- <TableCheckboxCell v-if="checkable" @checked="checked($event, client)" /> -->
<td class="border-b-0 lg:w-6 before:hidden hidden lg:table-cell"> <td class="border-b-0 lg:w-6 before:hidden hidden lg:table-cell">

View File

@ -0,0 +1,131 @@
<script setup lang="ts">
import LayoutAuthenticated from '@/Layouts/LayoutAuthenticated.vue';
import SectionMain from '@/Components/SectionMain.vue';
import SectionTitleLineWithButton from '@/Components/SectionTitleLineWithButton.vue';
import { useForm, Head, usePage } from '@inertiajs/vue3';
import { computed, Ref } from 'vue';
import CardBox from '@/Components/CardBox.vue';
import BaseButton from '@/Components/BaseButton.vue';
import BaseButtons from '@/Components/BaseButtons.vue';
import { stardust } from '@eidellev/adonis-stardust/client';
import { mdiArrowLeftBoldOutline, mdiDeleteForever, mdiTrashCan } from '@mdi/js';
import FormValidationErrors from '@/Components/FormValidationErrors.vue';
const props = defineProps({
dataset: {
type: Object,
default: () => ({}),
},
});
const flash: Ref<any> = computed(() => {
return usePage().props.flash;
});
const errors: Ref<any> = computed(() => {
return usePage().props.errors;
});
const form = useForm({
preferred_reviewer: '',
preferred_reviewer_email: '',
preferation: 'yes_preferation',
// preferation: '',
// isPreferationRequired: false,
});
const handleSubmit = async (e) => {
e.preventDefault();
await form.put(stardust.route('dataset.deleteUpdate', [props.dataset.id]));
};
</script>
<template>
<LayoutAuthenticated>
<Head title="Delete dataset" />
<SectionMain>
<SectionTitleLineWithButton :icon="mdiDeleteForever" title="Delete Dataset" main>
<BaseButton :route-name="stardust.route('dataset.list')" :icon="mdiArrowLeftBoldOutline" label="Back"
color="white" rounded-full small />
</SectionTitleLineWithButton>
<CardBox form @submit.prevent="handleSubmit">
<FormValidationErrors v-bind:errors="errors" />
<!-- Modal Content -->
<div class="modal-content py-4 text-left px-6">
<!-- Modal Title -->
<div class="text-xl font-bold mb-4">Confirm Deletion</div>
<!-- Modal Body -->
<p>Are you sure you want to delete the dataset from Tethys Data Research Repository?
Also the following files will be deleted:
</p>
<ul class="mt-4 space-y-4 text-left text-gray-500 dark:text-gray-400">
<li class="flex items-center space-x-3" v-for="file in dataset.files" :key="file.id">
<svg class="flex-shrink-0 w-3.5 h-3.5 text-green-500 dark:text-green-400" aria-hidden="true"
xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 16 12">
<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2"
d="M1 5.917 5.724 10.5 15 1.5" />
</svg>
<span>{{ file.label }} with mime-type
<span class="font-semibold text-gray-900 dark:text-white">
{{ file.mime_type }}
</span>
</span>
</li>
<!-- <li class="flex items-center space-x-3">
<svg class="flex-shrink-0 w-3.5 h-3.5 text-green-500 dark:text-green-400" aria-hidden="true"
xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 16 12">
<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2"
d="M1 5.917 5.724 10.5 15 1.5" />
</svg>
<span>No setup, or hidden fees</span>
</li>
<li class="flex items-center space-x-3">
<svg class="flex-shrink-0 w-3.5 h-3.5 text-green-500 dark:text-green-400" aria-hidden="true"
xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 16 12">
<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2"
d="M1 5.917 5.724 10.5 15 1.5" />
</svg>
<span>Team size: <span class="font-semibold text-gray-900 dark:text-white">1
developer</span></span>
</li>
<li class="flex items-center space-x-3">
<svg class="flex-shrink-0 w-3.5 h-3.5 text-green-500 dark:text-green-400" aria-hidden="true"
xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 16 12">
<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2"
d="M1 5.917 5.724 10.5 15 1.5" />
</svg>
<span>Premium support: <span class="font-semibold text-gray-900 dark:text-white">6
months</span></span>
</li>
<li class="flex items-center space-x-3">
<svg class="flex-shrink-0 w-3.5 h-3.5 text-green-500 dark:text-green-400" aria-hidden="true"
xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 16 12">
<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2"
d="M1 5.917 5.724 10.5 15 1.5" />
</svg>
<span>Free updates: <span class="font-semibold text-gray-900 dark:text-white">6
months</span></span>
</li> -->
</ul>
</div>
<div v-if="flash && flash.warning" class="flex flex-col mt-6 animate-fade-in">
<div class="bg-yellow-500 border-l-4 border-orange-400 text-white p-4" role="alert">
<p class="font-bold">Be Warned</p>
<p>{{ flash.warning }}</p>
</div>
</div>
<template #footer>
<BaseButtons>
<BaseButton type="submit" color="danger" :icon="mdiTrashCan" :small="true"
:class="{ 'opacity-25': form.processing }" :disabled="form.processing" label="Confirm Delete" />
</BaseButtons>
</template>
</CardBox>
</SectionMain>
</LayoutAuthenticated>
</template>

View File

@ -64,6 +64,7 @@ const flash: ComputedRef<any> = computed(() => {
<template> <template>
<LayoutAuthenticated> <LayoutAuthenticated>
<Head title="Submit Dataset" /> <Head title="Submit Dataset" />
<SectionMain> <SectionMain>
<!-- <FormValidationErrors v-bind:errors="errors" /> --> <!-- <FormValidationErrors v-bind:errors="errors" /> -->
@ -85,7 +86,7 @@ const flash: ComputedRef<any> = computed(() => {
</th> </th>
<th> <th>
<!-- <Sort label="Email" attribute="email" :search="form.search" /> --> <!-- <Sort label="Email" attribute="email" :search="form.search" /> -->
<th>Server State</th> <th>Server State</th>
</th> </th>
<th>Date of last modification</th> <th>Date of last modification</th>
<th v-if="can.edit || can.delete">Actions</th> <th v-if="can.edit || can.delete">Actions</th>
@ -104,33 +105,25 @@ const flash: ComputedRef<any> = computed(() => {
</td> </td>
<td> <td>
{{ dataset.server_state }} {{ dataset.server_state }}
</td> </td>
<td data-label="Created" class="lg:w-1 whitespace-nowrap"> <td data-label="Created" class="lg:w-1 whitespace-nowrap">
<small class="text-gray-500 dark:text-slate-400" :title="dataset.server_date_modified">{{ dataset.updated_at }}</small> <small class="text-gray-500 dark:text-slate-400" :title="dataset.server_date_modified">{{
dataset.updated_at }}</small>
</td> </td>
<td v-if="can.edit || can.delete" class="before:hidden lg:w-1 whitespace-nowrap"> <td v-if="can.edit || can.delete" class="before:hidden lg:w-1 whitespace-nowrap">
<BaseButtons type="justify-start lg:justify-end" no-wrap> <BaseButtons type="justify-start lg:justify-end" no-wrap>
<!-- release created dataset --> <!-- release created dataset -->
<BaseButton <BaseButton v-if="can.edit"
v-if="can.edit" :route-name="stardust.route('dataset.release', [dataset.id])" color="info"
:route-name="stardust.route('dataset.release', [dataset.id])" :icon="mdiLockOpen" :label="'Release'" small />
color="info"
:icon="mdiLockOpen"
:label="'Release'"
small
/>
<!-- && (dataset.server_state === 'inprogress' || dataset.server_state === 'rejected_editor')" --> <!-- && (dataset.server_state === 'inprogress' || dataset.server_state === 'rejected_editor')" -->
<BaseButton <BaseButton v-if="can.edit" :route-name="stardust.route('dataset.edit', [dataset.id])"
v-if="can.edit" color="info" :icon="mdiSquareEditOutline" :label="'Edit'" small />
:route-name="stardust.route('dataset.edit', [dataset.id])"
color="info"
:icon="mdiSquareEditOutline"
:label="'Edit'"
small
/>
<!-- @click="destroy(dataset.id)" --> <!-- @click="destroy(dataset.id)" -->
<BaseButton v-if="can.delete" color="danger" :icon="mdiTrashCan" small /> <BaseButton v-if="can.delete" color="danger"
:route-name="stardust.route('dataset.delete', [dataset.id])" :icon="mdiTrashCan"
small />
</BaseButtons> </BaseButtons>
</td> </td>
</tr> </tr>

View File

@ -168,6 +168,10 @@ Route.group(() => {
.as('dataset.edit') .as('dataset.edit')
.where('id', Route.matchers.number()) .where('id', Route.matchers.number())
.middleware(['auth', 'can:dataset-submit']); .middleware(['auth', 'can:dataset-submit']);
Route.get('/dataset/:id/delete', 'DatasetController.delete').as('dataset.delete').middleware(['auth', 'can:dataset-delete']);
Route.put('/dataset/:id/deleteupdate', 'DatasetController.deleteUpdate')
.as('dataset.deleteUpdate')
.middleware(['auth', 'can:dataset-delete']);
// Route.get('/user/:id', 'UsersController.show').as('user.show').where('id', Route.matchers.number()); // Route.get('/user/:id', 'UsersController.show').as('user.show').where('id', Route.matchers.number());
// Route.get('/user/:id/edit', 'UsersController.edit').as('user.edit').where('id', Route.matchers.number()); // Route.get('/user/:id/edit', 'UsersController.edit').as('user.edit').where('id', Route.matchers.number());