Updated via schema editor on 2025-09-02 23:05
This commit is contained in:
parent
166ee1b5bc
commit
12bcbe00bf
File diff suppressed because one or more lines are too long
36
backend/src/db/migrations/1756854338007.js
Normal file
36
backend/src/db/migrations/1756854338007.js
Normal file
@ -0,0 +1,36 @@
|
|||||||
|
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;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
};
|
||||||
@ -88,7 +88,9 @@ const CardPrenotazioni = ({
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div className='flex justify-between gap-x-4 py-3'>
|
<div className='flex justify-between gap-x-4 py-3'>
|
||||||
<dt className=' text-gray-500 dark:text-dark-600'>Gioco</dt>
|
<dt className=' text-gray-500 dark:text-dark-600'>
|
||||||
|
Giochi
|
||||||
|
</dt>
|
||||||
<dd className='flex items-start gap-x-2'>
|
<dd className='flex items-start gap-x-2'>
|
||||||
<div className='font-medium line-clamp-4'>
|
<div className='font-medium line-clamp-4'>
|
||||||
{dataFormatter.tavoliOneListFormatter(item.gioco)}
|
{dataFormatter.tavoliOneListFormatter(item.gioco)}
|
||||||
|
|||||||
@ -61,7 +61,7 @@ const ListPrenotazioni = ({
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div className={'flex-1 px-3'}>
|
<div className={'flex-1 px-3'}>
|
||||||
<p className={'text-xs text-gray-500 '}>Gioco</p>
|
<p className={'text-xs text-gray-500 '}>Giochi</p>
|
||||||
<p className={'line-clamp-2'}>
|
<p className={'line-clamp-2'}>
|
||||||
{dataFormatter.tavoliOneListFormatter(item.gioco)}
|
{dataFormatter.tavoliOneListFormatter(item.gioco)}
|
||||||
</p>
|
</p>
|
||||||
|
|||||||
@ -60,7 +60,7 @@ export const loadColumns = async (
|
|||||||
|
|
||||||
{
|
{
|
||||||
field: 'gioco',
|
field: 'gioco',
|
||||||
headerName: 'Gioco',
|
headerName: 'Giochi',
|
||||||
flex: 1,
|
flex: 1,
|
||||||
minWidth: 120,
|
minWidth: 120,
|
||||||
filterable: false,
|
filterable: false,
|
||||||
|
|||||||
@ -106,7 +106,7 @@ const EditPrenotazioni = () => {
|
|||||||
></Field>
|
></Field>
|
||||||
</FormField>
|
</FormField>
|
||||||
|
|
||||||
<FormField label='Gioco' labelFor='gioco'>
|
<FormField label='Giochi' labelFor='gioco'>
|
||||||
<Field
|
<Field
|
||||||
name='gioco'
|
name='gioco'
|
||||||
id='gioco'
|
id='gioco'
|
||||||
|
|||||||
@ -104,7 +104,7 @@ const EditPrenotazioniPage = () => {
|
|||||||
></Field>
|
></Field>
|
||||||
</FormField>
|
</FormField>
|
||||||
|
|
||||||
<FormField label='Gioco' labelFor='gioco'>
|
<FormField label='Giochi' labelFor='gioco'>
|
||||||
<Field
|
<Field
|
||||||
name='gioco'
|
name='gioco'
|
||||||
id='gioco'
|
id='gioco'
|
||||||
|
|||||||
@ -36,7 +36,7 @@ const PrenotazioniTablesPage = () => {
|
|||||||
|
|
||||||
{ label: 'Utente', title: 'utente' },
|
{ label: 'Utente', title: 'utente' },
|
||||||
|
|
||||||
{ label: 'Gioco', title: 'gioco' },
|
{ label: 'Giochi', title: 'gioco' },
|
||||||
]);
|
]);
|
||||||
|
|
||||||
const hasCreatePermission =
|
const hasCreatePermission =
|
||||||
|
|||||||
@ -77,7 +77,7 @@ const PrenotazioniNew = () => {
|
|||||||
></Field>
|
></Field>
|
||||||
</FormField>
|
</FormField>
|
||||||
|
|
||||||
<FormField label='Gioco' labelFor='gioco'>
|
<FormField label='Giochi' labelFor='gioco'>
|
||||||
<Field
|
<Field
|
||||||
name='gioco'
|
name='gioco'
|
||||||
id='gioco'
|
id='gioco'
|
||||||
|
|||||||
@ -36,7 +36,7 @@ const PrenotazioniTablesPage = () => {
|
|||||||
|
|
||||||
{ label: 'Utente', title: 'utente' },
|
{ label: 'Utente', title: 'utente' },
|
||||||
|
|
||||||
{ label: 'Gioco', title: 'gioco' },
|
{ label: 'Giochi', title: 'gioco' },
|
||||||
]);
|
]);
|
||||||
|
|
||||||
const hasCreatePermission =
|
const hasCreatePermission =
|
||||||
|
|||||||
@ -61,7 +61,7 @@ const PrenotazioniView = () => {
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div className={'mb-4'}>
|
<div className={'mb-4'}>
|
||||||
<p className={'block font-bold mb-2'}>Gioco</p>
|
<p className={'block font-bold mb-2'}>Giochi</p>
|
||||||
|
|
||||||
<p>{prenotazioni?.gioco?.posti_totali ?? 'No data'}</p>
|
<p>{prenotazioni?.gioco?.posti_totali ?? 'No data'}</p>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@ -77,7 +77,7 @@ const TavoliView = () => {
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<>
|
<>
|
||||||
<p className={'block font-bold mb-2'}>Prenotazioni Gioco</p>
|
<p className={'block font-bold mb-2'}>Prenotazioni Giochi</p>
|
||||||
<CardBox
|
<CardBox
|
||||||
className='mb-6 border border-gray-300 rounded overflow-hidden'
|
className='mb-6 border border-gray-300 rounded overflow-hidden'
|
||||||
hasTable
|
hasTable
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user