Fakultas Ilmu Komputer UI

Commit 28d696be authored by Zamil Majdy's avatar Zamil Majdy
Browse files

Add footer on the main menuu

parent be062533
...@@ -23,9 +23,9 @@ background-color: #EEEEEE; ...@@ -23,9 +23,9 @@ background-color: #EEEEEE;
} }
.create-lowongan{ .create-lowongan{
padding-bottom: 7%; padding-bottom: 7%;
padding-left:15%; padding-left:15%;
padding-right:15%; padding-right:15%;
} }
.ui.segment.form-segment{ .ui.segment.form-segment{
...@@ -36,8 +36,8 @@ padding-right:15%; ...@@ -36,8 +36,8 @@ padding-right:15%;
background: #fff; background: #fff;
border: 1px solid #e5e5e5; border: 1px solid #e5e5e5;
border-radius: 3px; border-radius: 3px;
margin: 3% 7% 30px; margin: 0 7%;
margin-top: 1%; display: block;
} }
.tabs__labels { .tabs__labels {
margin: 0; margin: 0;
...@@ -197,8 +197,9 @@ card .formRegis{ ...@@ -197,8 +197,9 @@ card .formRegis{
#react-app{ #react-app{
position: relative; /* needed for footer positioning*/ position: relative; /* needed for footer positioning*/
height: auto !important; /* real browsers */ /*height: 100% !important; !* real browsers *!*/
min-height: 100%; /* real browsers */ min-height: 100%; /* real browsers */
box-sizing: border-box;
background-color: #EEEEEE; background-color: #EEEEEE;
} }
...@@ -206,11 +207,18 @@ card .formRegis{ ...@@ -206,11 +207,18 @@ card .formRegis{
padding-bottom: 5%; padding-bottom: 5%;
} }
.mainContent{
padding-bottom: 40px;
}
.footer{ .footer{
background-color: #031634; background-color: #031634;
position: absolute; position: absolute;
right: 0;
bottom: 0; bottom: 0;
left: 0;
width: 100%; width: 100%;
height: 25px;
padding: 1%; padding: 1%;
} }
...@@ -218,9 +226,9 @@ card .formRegis{ ...@@ -218,9 +226,9 @@ card .formRegis{
color:white; color:white;
} }
.profilePage{ .profilePage{
margin-bottom:40px;
margin-left:5%; margin-left:5%;
margin-right:5%; margin-right:5%;
margin-bottom: auto;
} }
.ui.segment.segmentProfileCompany{ .ui.segment.segmentProfileCompany{
......
...@@ -9,7 +9,7 @@ export default class CompanyProfile extends React.Component { ...@@ -9,7 +9,7 @@ export default class CompanyProfile extends React.Component {
}; };
render() { render() {
const defaultLogo = 'http://semantic-ui.com/images/wireframe/square-image.png'; const defaultLogo = 'https://semantic-ui.com/images/wireframe/square-image.png';
const data = TopMenu.getInfo(this.props.user); const data = TopMenu.getInfo(this.props.user);
console.log(data); console.log(data);
return ( return (
......
import React from 'react'; import React from 'react';
import TopMenu from './components/TopMenu'; import TopMenu from './components/TopMenu';
import Footer from './components/Footer';
export default class Dashboard extends React.Component { export default class Dashboard extends React.Component {
static propTypes = { static propTypes = {
...@@ -20,7 +21,10 @@ export default class Dashboard extends React.Component { ...@@ -20,7 +21,10 @@ export default class Dashboard extends React.Component {
render = () => ( render = () => (
<div> <div>
<TopMenu user={this.props.user} /> <TopMenu user={this.props.user} />
{this.props.children} <div className="mainContent">
{this.props.children}
</div>
<Footer />
</div> </div>
) )
} }
......
...@@ -172,7 +172,7 @@ export default class ProfilePage extends React.Component { ...@@ -172,7 +172,7 @@ export default class ProfilePage extends React.Component {
} }
render() { render() {
const defaultPicture = 'http://semantic-ui.com/images/wireframe/square-image.png'; const defaultPicture = 'https://semantic-ui.com/images/wireframe/square-image.png';
return ( return (
<div className="profilePage"> <div className="profilePage">
<Segment className="biodata-section" > <Segment className="biodata-section" >
......
...@@ -157,12 +157,16 @@ export default class VacancyPage extends React.Component { ...@@ -157,12 +157,16 @@ export default class VacancyPage extends React.Component {
render() { render() {
return ( return (
<div className="applicant"> <div className="applicant">
<div className="administrationButtons" style={{ display: 'inline-block' }}> {this.props.user.role === 'student' || (
{ this.companyHeader() } <div className="administrationButtons" style={{ display: 'inline-block' }}>
{(this.props.user.role === 'admin' || this.props.user.role === 'supervisor') && { this.companyHeader() }
<Button as={Link} to="/rekap" icon="dashboard" labelPosition="left" color="facebook" content="Rekap Pendaftaran"/> {(this.props.user.role === 'admin' || this.props.user.role === 'supervisor') &&
} <Button
</div> as={Link} to="/rekap" icon="dashboard" labelPosition="left" color="facebook"
content="Rekap Pendaftaran"
/>}
</div>
)}
{ this.generateVacancies() } { this.generateVacancies() }
</div> </div>
); );
......
...@@ -32,7 +32,7 @@ export default class AdminVacancy extends React.Component { ...@@ -32,7 +32,7 @@ export default class AdminVacancy extends React.Component {
} }
render() { render() {
const defaultImage = 'http://semantic-ui.com/images/wireframe/image.png'; const defaultImage = 'https://semantic-ui.com/images/wireframe/image.png';
return ( return (
<Item className="adminItems"> <Item className="adminItems">
<Item.Image src={this.props.data.company.logo ? this.props.data.company.logo : defaultImage} size="small" /> <Item.Image src={this.props.data.company.logo ? this.props.data.company.logo : defaultImage} size="small" />
......
...@@ -4,7 +4,7 @@ import Server from '../lib/Server'; ...@@ -4,7 +4,7 @@ import Server from '../lib/Server';
import ModalAlert from './ModalAlert'; import ModalAlert from './ModalAlert';
import ApproveModal from './ApproveModal'; import ApproveModal from './ApproveModal';
const defaultImage = 'http://semantic-ui.com/images/wireframe/image.png'; const defaultImage = 'https://semantic-ui.com/images/wireframe/image.png';
export default class Applicant extends React.Component { export default class Applicant extends React.Component {
static propTypes = { static propTypes = {
......
...@@ -4,7 +4,7 @@ import Server from '../lib/Server'; ...@@ -4,7 +4,7 @@ import Server from '../lib/Server';
import ModalAlert from './ModalAlert'; import ModalAlert from './ModalAlert';
import Storage from './../lib/Storage'; import Storage from './../lib/Storage';
const defaultImage = 'http://semantic-ui.com/images/wireframe/image.png'; const defaultImage = 'https://semantic-ui.com/images/wireframe/image.png';
export default class Company extends React.Component { export default class Company extends React.Component {
static propTypes = { static propTypes = {
......
...@@ -4,7 +4,7 @@ import { Button, Icon, Item, Grid } from 'semantic-ui-react'; ...@@ -4,7 +4,7 @@ import { Button, Icon, Item, Grid } from 'semantic-ui-react';
import { Link } from 'react-router'; import { Link } from 'react-router';
import Server from '../lib/Server'; import Server from '../lib/Server';
const defaultImage = 'http://semantic-ui.com/images/wireframe/image.png'; const defaultImage = 'https://semantic-ui.com/images/wireframe/image.png';
export default class CompanyVacancy extends React.Component { export default class CompanyVacancy extends React.Component {
static propTypes = { static propTypes = {
......
...@@ -74,33 +74,24 @@ export default class TopMenu extends React.Component { ...@@ -74,33 +74,24 @@ export default class TopMenu extends React.Component {
</div> </div>
)} )}
<Menu color="blue" pointing secondary> <Menu color="blue" pointing secondary>
<Image as="a" size="small" src="/assets/img/logo.png" href="/" /> <Image as={Link} size="small" src="/assets/img/logo.png" to="/home" />
<Menu.Menu position="right"> <Menu.Menu position="right">
{ !this.props.user.data.is_staff &&
<Menu.Item as={Link} to="/home" name="Beranda" active={activeItem === 'Beranda'} onClick={this.handleItemClick} /> <Menu.Item as={Link} to="/home" name="Beranda" active={activeItem === 'Beranda'} onClick={this.handleItemClick} />
}
{ this.props.user.role === 'student' && { this.props.user.role === 'student' &&
<Menu.Item as={Link} to="/profil" name="Profil" active={activeItem === 'Profil'} onClick={this.handleItemClick} /> } <Menu.Item as={Link} to="/profil" name="Profil" active={activeItem === 'Profil'} onClick={this.handleItemClick} /> }
{ this.props.user.data.is_staff && { this.props.user.data.is_staff &&
<Menu.Item as={Link} to="/perusahaan" name="Perusahaan" active={activeItem === 'Perusahaan' || activeItem === 'Beranda'} onClick={this.handleItemClick} /> }
{ this.props.user.data.is_staff &&
<Menu.Item as={Link} to="/lowongan" name="Lowongan" active={activeItem === 'Lowongan'} onClick={this.handleItemClick} /> } <Menu.Item as={Link} to="/lowongan" name="Lowongan" active={activeItem === 'Lowongan'} onClick={this.handleItemClick} /> }
<Menu.Item> <Menu.Item>
<Popup <Popup
trigger={<Image trigger={<Image src={(this.props.user.role === 'company' ? data.logo : data.photo) || defaultPicture} avatar />}
src={(this.props.user.role === 'company' ? data.logo : data.photo) || defaultPicture} avatar flowing hoverable
/>}
flowing
hoverable
> >
<Card <Card
header={data.name} header={data.name}
description={data.user.email} description={data.user.email}
/> />
<Button as={Link} onClick={this.logout} loading={this.state.logoutLoading} name="logout" color="blue" size="tiny">Keluar</Button> <Button as={Link} onClick={this.logout} loading={this.state.logoutLoading} name="logout" color="blue" size="tiny">Keluar</Button>
</Popup> </Popup>
</Menu.Item> </Menu.Item>
</Menu.Menu> </Menu.Menu>
</Menu> </Menu>
......
...@@ -6,7 +6,7 @@ import Server from '../lib/Server'; ...@@ -6,7 +6,7 @@ import Server from '../lib/Server';
import ConfirmationModal from './ConfirmationModal'; import ConfirmationModal from './ConfirmationModal';
import ModalAlert from './ModalAlert'; import ModalAlert from './ModalAlert';
const defaultImage = 'http://semantic-ui.com/images/wireframe/image.png'; const defaultImage = 'https://semantic-ui.com/images/wireframe/image.png';
export default class Vacancy extends React.Component { export default class Vacancy extends React.Component {
static propTypes = { static propTypes = {
......
...@@ -11,7 +11,6 @@ ...@@ -11,7 +11,6 @@
<link rel="stylesheet" href="{% static 'css/custom.css' %}"/> <link rel="stylesheet" href="{% static 'css/custom.css' %}"/>
<link rel="stylesheet" href="../../../node_modules/react-quill/dist/quill.snow.css"> <link rel="stylesheet" href="../../../node_modules/react-quill/dist/quill.snow.css">
<script src="https://cdn.ckeditor.com/4.6.2/standard/ckeditor.js"></script> <script src="https://cdn.ckeditor.com/4.6.2/standard/ckeditor.js"></script>
<!--<script src="https://cloud.tinymce.com/stable/tinymce.min.js"></script>-->
<link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/semantic-ui/2.2.2/semantic.min.css"/> <link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/semantic-ui/2.2.2/semantic.min.css"/>
<link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/react-datepicker/0.44.0/react-datepicker.min.css"/> <link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/react-datepicker/0.44.0/react-datepicker.min.css"/>
<link rel="icon" type="image/png" href="{% static 'img/logo-sm.png'%}" sizes="32x32" /> <link rel="icon" type="image/png" href="{% static 'img/logo-sm.png'%}" sizes="32x32" />
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment