ajout nom entreprise liste client + opti css dark theme

master
Maxence LANONE 3 years ago
parent 4406df563e
commit 0553f6df03

@ -165,8 +165,8 @@ app.put('/User/Update/:id', (req, res) => {
//Api pour les contacts de la page repertoire
app.get('/Contact/All', (req, res) => {
let sql = 'SELECT * FROM contacts ORDER BY idcontact';
app.get('/Contact/AllWithCustomerName', (req, res) => {
let sql = 'SELECT c.*, cu.name FROM contacts c, customers cu WHERE cu.idCustomer = c.idCustomer ORDER BY idcontact';
db.query(sql, (err, result) => {
if (err) throw err;
console.log(result);

@ -22,8 +22,9 @@ function Repertoire() {
const [SearchResults, setSearchResults] = useState([]);
const [customers, setCustomers] = useState([]);
useEffect(() => {
api.get('/Contact/All').then((response) => {
api.get('/Contact/AllWithCustomerName').then((response) => {
setContacts(response.data);
setSearchTerm(response.data[0].idcontact);
});
@ -70,7 +71,7 @@ function Repertoire() {
<TableCell>Photo</TableCell>
<TableCell>Nom</TableCell>
<TableCell>Prénom</TableCell>
<TableCell>Entreprise</TableCell>
</TableRow>
</TableHead>
<TableBody>
@ -79,6 +80,7 @@ function Repertoire() {
<TableCell><img className="photoContact" src={user} /></TableCell>
<TableCell>{contact.lastname}</TableCell>
<TableCell>{contact.firstname}</TableCell>
<TableCell>{contact.name}</TableCell>
</TableRow>
))}
</TableBody>

@ -1,7 +1,4 @@
.dark{
background-color: $xiketic;
color: white;
}
body {

@ -1,7 +1,4 @@
.dark{
background-color: $xiketic;
color: white;
}
body {

@ -1,7 +1,4 @@
.dark{
background-color: $xiketic;
color: white;
}
body {

@ -1,7 +1,3 @@
.dark{
background-color: $xiketic;
color: white;
}
body {
.page_connexion {

@ -1,7 +1,4 @@
.dark{
background-color: $xiketic;
color: white;
}
body {
.page_dashboard {

@ -1,8 +1,3 @@
.dark{
background-color: $xiketic;
color: white;
}
body {
background-color: $alice-blue;
color: black;

@ -14,19 +14,7 @@ $rufous: #9b2915ff;
$xiketic: #020114ff;
$beau-blue: #b1c5d2;
/* SCSS HSL */
$alice-blue: hsla(204, 28%, 93%, 1);
$blue-munsell: hsla(190, 100%, 32%, 1);
$malachite: hsla(142, 80%, 55%, 1);
$rufous: hsla(9, 76%, 35%, 1);
$xiketic: hsla(243, 90%, 4%, 1);
/* SCSS RGB */
$alice-blue: rgba(232, 238, 242, 1);
$blue-munsell: rgba(0, 136, 163, 1);
$malachite: rgba(50, 232, 117, 1);
$rufous: rgba(155, 41, 21, 1);
$xiketic: rgb(21, 18, 75);
/* SCSS Gradient */
$gradient-top: linear-gradient(0deg, #e8eef2ff, #0088a3ff, #32e875ff, #9b2915ff, #020114ff);
@ -60,3 +48,8 @@ body {
li {
list-style-type: none;
}
.dark{
background-color: $xiketic;
color: white;
}
Loading…
Cancel
Save