update Modal
This commit is contained in:
parent
131fa9fbe2
commit
f88dd4fa80
@ -5,6 +5,7 @@ import TextField from '@mui/material/TextField';
|
|||||||
import Typography from '@mui/material/Typography';
|
import Typography from '@mui/material/Typography';
|
||||||
import React, { useState } from 'react'
|
import React, { useState } from 'react'
|
||||||
|
|
||||||
|
|
||||||
import Snackbar from '@mui/material/Snackbar';
|
import Snackbar from '@mui/material/Snackbar';
|
||||||
import MuiAlert, { AlertProps } from '@mui/material/Alert';
|
import MuiAlert, { AlertProps } from '@mui/material/Alert';
|
||||||
import ClientsTable from '../../../components/administrativeTables/ClientsTable';
|
import ClientsTable from '../../../components/administrativeTables/ClientsTable';
|
||||||
@ -100,6 +101,7 @@ export default function clients({clients}) {
|
|||||||
setOpenSnackError(true)
|
setOpenSnackError(true)
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
async function handleDeleteClient(id: any) {
|
async function handleDeleteClient(id: any) {
|
||||||
await id.map(client => {
|
await id.map(client => {
|
||||||
api.delete(`/user/${client}`).then(res => {
|
api.delete(`/user/${client}`).then(res => {
|
||||||
@ -191,15 +193,17 @@ export default function clients({clients}) {
|
|||||||
}} variant="outlined" />
|
}} variant="outlined" />
|
||||||
<InputUpload />
|
<InputUpload />
|
||||||
<br /><br />
|
<br /><br />
|
||||||
<FaqButton1 title='Cancelar' onClick={() => console.log()} />
|
<FaqButton1 title='Cancelar' onClick={() => {setOpen(false)}} />
|
||||||
<FaqButton2 title='Salvar' onClick={() => handleCreateClient(client)}/>
|
<FaqButton2 title='Salvar' onClick={() => handleCreateClient(client)}/>
|
||||||
</Box>
|
</Box>
|
||||||
</Modal>
|
</Modal>
|
||||||
|
|
||||||
<ConfirmModal open={openModalInativar} handleIsClose={(value) => {setOpenModalInativar(value)}}>
|
<ConfirmModal open={openModalInativar} handleIsClose={(value) => {setOpenModalInativar(value)}}>
|
||||||
<PageTitle title='Excluir Cliente' subtitle='deseja realmente excluir os clientes selecionadas?'/>
|
<PageTitle title='Excluir Cliente' subtitle='Deseja realmente excluir os clientes selecionadas?'/>
|
||||||
<ConfirmModalView>
|
<ConfirmModalView>
|
||||||
|
|
||||||
<BasicButton title='Confirmar' onClick={() => handleDeleteClient(selectedClients)}/>
|
<BasicButton title='Confirmar' onClick={() => handleDeleteClient(selectedClients)}/>
|
||||||
<BasicButton title='Cancelar' onClick={() => setOpenModalInativar(true)}/>
|
<BasicButton title='Cancelar' onClick={() => {setOpenModalInativar(false)}}/>
|
||||||
</ConfirmModalView>
|
</ConfirmModalView>
|
||||||
</ConfirmModal>
|
</ConfirmModal>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user