feat: complete relative api route integration and container build
This commit is contained in:
@@ -13,7 +13,7 @@ export const GoogleConnectButton: React.FC<GoogleConnectButtonProps> = ({ ownerI
|
||||
const handleConnect = async () => {
|
||||
setIsLoading(true);
|
||||
try {
|
||||
const response = await fetch(`http://localhost:3005/api/auth/google/url?dentistId=${ownerId}`);
|
||||
const response = await fetch(`/api/auth/google/url?dentistId=${ownerId}`);
|
||||
const { url } = await response.json();
|
||||
|
||||
// Abrir em popup para manter o contexto
|
||||
@@ -48,7 +48,7 @@ export const GoogleConnectButton: React.FC<GoogleConnectButtonProps> = ({ ownerI
|
||||
|
||||
setIsLoading(true);
|
||||
try {
|
||||
await fetch(`http://localhost:3005/api/auth/google/${ownerId}`, { method: 'DELETE' });
|
||||
await fetch(`/api/auth/google/${ownerId}`, { method: 'DELETE' });
|
||||
if (onStatusChange) onStatusChange();
|
||||
} catch (error) {
|
||||
console.error('Erro ao desconectar:', error);
|
||||
|
||||
Reference in New Issue
Block a user