-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathBuyPage.js
31 lines (27 loc) · 1.32 KB
/
BuyPage.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
let rotate = document.getElementById("spinner");
setTimeout(() => {
rotate.style.display = "none";
fetch("https://apartment-booking.onrender.com/api/getAllHotel")
.then((data) => {
return data.json();
})
.then((completedata) => {
let data1 = "";
completedata.data.map((values) => {
data1 += ` <div class="PopularRow">
<img class="PopularImg" src="/images/luxury-bedroom-hotel.jpg" alt="">
<div class="imgDetals">
<p><b>${values.hotelName}</b></p>
<p style="font-family: 'Trebuchet MS', 'Lucida Sans Unicode', 'Lucida Grande', 'Lucida Sans', Arial, sans-serif;">${values.hotelAddress}</p>
<p style="font-family: Cambria, Cochin, Georgia, Times, 'Times New Roman', serif;">${values.hotelDescription}</p>
<div class="PopularDetails">
<i class="fa fa-bed"><span style="font-family: 'Franklin Gothic Medium', 'Arial Narrow', Arial, sans-serif;"> 4 Beds</span></i>
<i class="fa fa-bath"><span style="font-family: 'Franklin Gothic Medium', 'Arial Narrow', Arial, sans-serif;"> 4 Baths</span></i>
<i class="fa fa-restroom"><span style="font-family: 'Franklin Gothic Medium', 'Arial Narrow', Arial, sans-serif;"> 5 Toilets</span></i>
</div>
</div>
</div>`;
});
document.querySelector(".RowFlex").innerHTML = data1;
});
}, 2000);