-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refaccionats els components, funcions i control·ladors de rutes relat…
…ius a les acceptacions Eliminades les restes de funcions marcades com a obsoletes
- Loading branch information
1 parent
551892a
commit 2a6a8d4
Showing
14 changed files
with
59 additions
and
320 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 3 additions & 7 deletions
10
client/src/components/avis-acceptacio/hooks/use-avis-acceptacio.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,22 +1,18 @@ | ||
import { useEffect, useState } from "react"; | ||
|
||
/** | ||
* @param {number} idAvis | ||
* @returns {[Object, boolean]} | ||
*/ | ||
export default (idAvis) => { | ||
export default (nameAvis) => { | ||
const [textAvisAcceptacio, setTextAvisAcceptacio] = useState({}); | ||
const [loading, setLoading] = useState(false); | ||
|
||
useEffect(() => { | ||
setLoading(true); | ||
fetch(`/api/associacio/avisos/${idAvis}`) | ||
fetch(`/api/associacio/avisos/${nameAvis}`) | ||
.then((res) => res.json()) | ||
.then((data) => { | ||
setTextAvisAcceptacio(data); | ||
setLoading(false); | ||
}); | ||
}, [idAvis]); | ||
}, [nameAvis]); | ||
|
||
return [textAvisAcceptacio, loading]; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 0 additions & 1 deletion
1
client/src/pages-tauler/perfil-soci/components/soci-tab-associacio/hooks/index.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1 @@ | ||
export { default as useAcceptacions } from "./use-acceptacions"; | ||
export { default as useAcceptaDretsImatge } from "./use-accepta-drets-imatge"; |
34 changes: 0 additions & 34 deletions
34
...pages-tauler/perfil-soci/components/soci-tab-associacio/hooks/use-accepta-drets-imatge.js
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.