Updated via schema editor on 2025-08-25 01:17
This commit is contained in:
parent
4df8d3139d
commit
f1cada4bd7
File diff suppressed because one or more lines are too long
38
backend/src/db/migrations/1756084585894.js
Normal file
38
backend/src/db/migrations/1756084585894.js
Normal file
@ -0,0 +1,38 @@
|
||||
module.exports = {
|
||||
/**
|
||||
* @param {QueryInterface} queryInterface
|
||||
* @param {Sequelize} Sequelize
|
||||
* @returns {Promise<void>}
|
||||
*/
|
||||
async up(queryInterface, Sequelize) {
|
||||
/**
|
||||
* @type {Transaction}
|
||||
*/
|
||||
const transaction = await queryInterface.sequelize.transaction();
|
||||
try {
|
||||
|
||||
await transaction.commit();
|
||||
} catch (err) {
|
||||
await transaction.rollback();
|
||||
throw err;
|
||||
}
|
||||
},
|
||||
/**
|
||||
* @param {QueryInterface} queryInterface
|
||||
* @param {Sequelize} Sequelize
|
||||
* @returns {Promise<void>}
|
||||
*/
|
||||
async down(queryInterface, Sequelize) {
|
||||
/**
|
||||
* @type {Transaction}
|
||||
*/
|
||||
const transaction = await queryInterface.sequelize.transaction();
|
||||
try {
|
||||
|
||||
await transaction.commit();
|
||||
} catch (err) {
|
||||
await transaction.rollback();
|
||||
throw err;
|
||||
}
|
||||
}
|
||||
};
|
||||
@ -17,10 +17,6 @@ const { parse } = require('json2csv');
|
||||
* type: object
|
||||
* properties:
|
||||
|
||||
* name:
|
||||
* type: string
|
||||
* default: name
|
||||
|
||||
*/
|
||||
|
||||
/**
|
||||
@ -276,7 +272,7 @@ router.get('/', wrapAsync(async (req, res) => {
|
||||
req.query, { currentUser }
|
||||
);
|
||||
if (filetype && filetype === 'csv') {
|
||||
const fields = ['id','name',
|
||||
const fields = ['id',
|
||||
|
||||
];
|
||||
const opts = { fields };
|
||||
|
||||
@ -61,15 +61,6 @@ const CardPermissions = ({
|
||||
</div>
|
||||
<dl className='divide-y dark:divide-dark-700 px-6 py-4 text-sm leading-6 h-64 overflow-y-auto'>
|
||||
|
||||
<div className='flex justify-between gap-x-4 py-3'>
|
||||
<dt className='text-gray-500 dark:text-dark-600'>Name</dt>
|
||||
<dd className='flex items-start gap-x-2'>
|
||||
<div className='font-medium line-clamp-4'>
|
||||
{ item.name }
|
||||
</div>
|
||||
</dd>
|
||||
</div>
|
||||
|
||||
</dl>
|
||||
</li>
|
||||
))}
|
||||
|
||||
@ -35,11 +35,6 @@ const ListPermissions = ({ permissions, loading, onDelete, currentPage, numPages
|
||||
}
|
||||
>
|
||||
|
||||
<div className={'flex-1 px-3'}>
|
||||
<p className={'text-xs text-gray-500'}>Name</p>
|
||||
<p className={'line-clamp-2'}>{ item.name }</p>
|
||||
</div>
|
||||
|
||||
</Link>
|
||||
<ListActionsPopover
|
||||
onDelete={onDelete}
|
||||
|
||||
@ -27,19 +27,6 @@ export const loadColumns = async (
|
||||
}
|
||||
return [
|
||||
|
||||
{
|
||||
field: 'name',
|
||||
headerName: 'Name',
|
||||
flex: 1,
|
||||
minWidth: 120,
|
||||
filterable: false,
|
||||
headerClassName: 'datagrid--header',
|
||||
cellClassName: 'datagrid--cell',
|
||||
|
||||
editable: true,
|
||||
|
||||
},
|
||||
|
||||
{
|
||||
field: 'actions',
|
||||
type: 'actions',
|
||||
|
||||
@ -32,8 +32,6 @@ const EditPermissions = () => {
|
||||
const dispatch = useAppDispatch()
|
||||
const initVals = {
|
||||
|
||||
'name': '',
|
||||
|
||||
}
|
||||
const [initialValues, setInitialValues] = useState(initVals)
|
||||
|
||||
@ -84,15 +82,6 @@ const EditPermissions = () => {
|
||||
>
|
||||
<Form>
|
||||
|
||||
<FormField
|
||||
label="Name"
|
||||
>
|
||||
<Field
|
||||
name="name"
|
||||
placeholder="Name"
|
||||
/>
|
||||
</FormField>
|
||||
|
||||
<BaseDivider />
|
||||
<BaseButtons>
|
||||
<BaseButton type="submit" color="info" label="Submit" />
|
||||
|
||||
@ -33,8 +33,6 @@ const EditPermissionsPage = () => {
|
||||
const dispatch = useAppDispatch()
|
||||
const initVals = {
|
||||
|
||||
'name': '',
|
||||
|
||||
}
|
||||
const [initialValues, setInitialValues] = useState(initVals)
|
||||
|
||||
@ -82,15 +80,6 @@ const EditPermissionsPage = () => {
|
||||
>
|
||||
<Form>
|
||||
|
||||
<FormField
|
||||
label="Name"
|
||||
>
|
||||
<Field
|
||||
name="name"
|
||||
placeholder="Name"
|
||||
/>
|
||||
</FormField>
|
||||
|
||||
<BaseDivider />
|
||||
<BaseButtons>
|
||||
<BaseButton type="submit" color="info" label="Submit" />
|
||||
|
||||
@ -22,7 +22,7 @@ const PermissionsTablesPage = () => {
|
||||
|
||||
const dispatch = useAppDispatch();
|
||||
|
||||
const [filters] = useState([{label: 'Name', title: 'name'},
|
||||
const [filters] = useState([
|
||||
|
||||
]);
|
||||
const addFilter = () => {
|
||||
|
||||
@ -25,8 +25,6 @@ import { useRouter } from 'next/router'
|
||||
|
||||
const initialValues = {
|
||||
|
||||
name: '',
|
||||
|
||||
}
|
||||
|
||||
const PermissionsNew = () => {
|
||||
@ -55,15 +53,6 @@ const PermissionsNew = () => {
|
||||
>
|
||||
<Form>
|
||||
|
||||
<FormField
|
||||
label="Name"
|
||||
>
|
||||
<Field
|
||||
name="name"
|
||||
placeholder="Name"
|
||||
/>
|
||||
</FormField>
|
||||
|
||||
<BaseDivider />
|
||||
<BaseButtons>
|
||||
<BaseButton type="submit" color="info" label="Submit" />
|
||||
|
||||
@ -22,7 +22,7 @@ const PermissionsTablesPage = () => {
|
||||
|
||||
const dispatch = useAppDispatch();
|
||||
|
||||
const [filters] = useState([{label: 'Name', title: 'name'},
|
||||
const [filters] = useState([
|
||||
|
||||
]);
|
||||
const addFilter = () => {
|
||||
|
||||
@ -49,11 +49,6 @@ const PermissionsView = () => {
|
||||
</SectionTitleLineWithButton>
|
||||
<CardBox>
|
||||
|
||||
<div className={'mb-4'}>
|
||||
<p className={'block font-bold mb-2'}>Name</p>
|
||||
<p>{permissions?.name}</p>
|
||||
</div>
|
||||
|
||||
<BaseDivider />
|
||||
|
||||
<BaseButton
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user