Changeset 07f4e8b for frontend/src/Components/Listings
- Timestamp:
- 01/24/24 17:42:28 (10 months ago)
- Branches:
- master
- Children:
- 0f5aa27
- Parents:
- 5528b99
- Location:
- frontend/src/Components/Listings
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
frontend/src/Components/Listings/HotelListing.js
r5528b99 r07f4e8b 80 80 }} 81 81 > 82 {/* {props.data.hotelRating} */} 83 9.1 82 {(props.data.hotelReviews.reduce((sum, r) => sum + r.numStar, 0) / props.data.hotelReviews.length).toFixed(1)} 84 83 </span> 85 84 </Col> -
frontend/src/Components/Listings/SortButton.js
r5528b99 r07f4e8b 3 3 import { BsSortUp } from "react-icons/bs" 4 4 5 const SortButton = ( ) => {5 const SortButton = (props) => { 6 6 return ( 7 <Dropdown> 7 <Dropdown onSelect={(event, x) => { 8 console.log(event) 9 props.setSortingArg(event) 10 }}> 8 11 <Dropdown.Toggle variant="success" id="dropdown-basic" size="lg"> 9 12 <span className="ikona my-1"><BsSortUp/></span> … … 11 14 </Dropdown.Toggle> 12 15 13 <Dropdown.Menu >14 <Dropdown.Item href="#/action-1">Цена растечки</Dropdown.Item>15 <Dropdown.Item href="#/action-2">Цена опаѓачки</Dropdown.Item>16 <Dropdown.Item href="#/action-3">Име растечки</Dropdown.Item>17 <Dropdown.Item href="#/action-3">Име опаѓачки</Dropdown.Item>16 <Dropdown.Menu > 17 {props.type !== 'restaurant' && <Dropdown.Item eventKey={'priceDesc'}>Цена растечки</Dropdown.Item>} 18 {props.type !== 'restaurant' && <Dropdown.Item eventKey={'priceAsc'}>Цена опаѓачки</Dropdown.Item>} 19 {props.type !== 'transport' && <Dropdown.Item eventKey={'nameAsc'}>Име растечки</Dropdown.Item>} 20 {props.type !== 'transport' && <Dropdown.Item eventKey={'nameDesc'}>Име опаѓачки</Dropdown.Item>} 18 21 </Dropdown.Menu> 19 22 </Dropdown> -
frontend/src/Components/Listings/TransportListing.js
r5528b99 r07f4e8b 9 9 10 10 const TransportListing = (props) => { 11 11 12 12 13 13 … … 56 56 }} 57 57 > 58 9.158 {(props.data.reviews.reduce((sum, r) => sum + r.numStar, 0) / props.data.reviews.length).toFixed(1)} 59 59 </span> 60 60 </Col>
Note:
See TracChangeset
for help on using the changeset viewer.