- Timestamp:
- 09/17/22 01:24:24 (2 years ago)
- Branches:
- master
- Children:
- 5201690
- Parents:
- 775e15e
- Location:
- phonelux-frontend/src/components/PhoneOfferDetailsComponent
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
phonelux-frontend/src/components/PhoneOfferDetailsComponent/PhoneOfferDetailsComponent.css
r775e15e r7e88e46 19 19 .phone-offer-details-table-row{ 20 20 border: 1px solid gainsboro; 21 22 21 } 23 22 … … 67 66 .phone-offer-details-last-updated-wrapper{ 68 67 display: flex; 68 width: 100%; 69 69 justify-content: start; 70 align-items: center; 71 } 72 73 .phone-offer-details-edit-header{ 74 width: 100%; 75 margin-left: 20px; 76 padding-top: 10px; 77 border: 1px solid black; 78 background-color: rgb(232, 243, 121); 79 border-radius: 30px; 80 text-align: center; 81 padding: 10px; 82 } 83 84 .phone-offer-details-edit-header:hover{ 85 cursor: pointer; 86 background-color: rgb(212, 219, 140); 87 box-shadow: 0 12px 16px 0 rgba(0,0,0,0.24), 0 17px 50px 0 rgba(0,0,0,0.19); 88 transition: box-shadow 0.5s, background-color 0.5s ; 89 } 90 91 .link-offer-edit{ 92 width: 15%; 93 height: fit-content; 94 text-decoration: none; 95 display: flex; 70 96 } 71 97 -
phonelux-frontend/src/components/PhoneOfferDetailsComponent/PhoneOfferDetailsComponent.js
r775e15e r7e88e46 3 3 import './PhoneOfferDetailsComponent.css' 4 4 import HeaderComponent from '../HeaderComponent/HeaderComponent' 5 import UserContext from '../../context/UserContext' 6 import { Link } from 'react-router-dom' 5 7 6 8 … … 26 28 27 29 render() { 28 console.log(this.state)29 30 return ( 30 31 <div className='phone-offer-details-main'> … … 33 34 <h3 className='phone-offer-details-last-updated-header'>Последно ажурирана: {this.state.offer == null || 34 35 this.state.offer.last_updated == null ? '#' : this.state.offer.last_updated.split('T')[0]}</h3> 36 { 37 localStorage.getItem('token') && (this.context.role == 'ADMIN' || this.context.role == 'SUPERADMIN') ? 38 <Link className='link-offer-edit' style={{color:'black'}} to={'/admin/editoffer/'+this.state.offerId}> 39 <h3 className='phone-offer-details-edit-header'>Измени понуда</h3> 40 </Link> : <></> 41 } 35 42 </div> 36 43 <div className='phone-offer-details-table-wrapper'> … … 116 123 } 117 124 125 PhoneOfferDetailsComponent.contextType = UserContext 126 118 127 export default PhoneOfferDetailsComponent
Note:
See TracChangeset
for help on using the changeset viewer.