Commit 42fd1790 authored by d.arizona's avatar d.arizona

update

parent 56a6e542
...@@ -170,6 +170,11 @@ const create = (baseURL = 'https://tia.eksad.com/tia-reporting-dev/public/') => ...@@ -170,6 +170,11 @@ const create = (baseURL = 'https://tia.eksad.com/tia-reporting-dev/public/') =>
const getSubmission = (body) => api.post('transaction/get_submission_id', body) const getSubmission = (body) => api.post('transaction/get_submission_id', body)
const checkUploadMB = (body) => api.post('transaction/master_budget/check_import', body) const checkUploadMB = (body) => api.post('transaction/master_budget/check_import', body)
const getAllOperatingInd = (body) => api.post('/transaction/get_all_operating_indicator_report', body)
const getOperatingIndDetail = (body) => api.post('/transaction/operating_indicator/get_operating_indicator_report_hierarki', body)
const createOpetaingInd = (body) => api.post('/transaction/operating_indicator/create_submission_report', body)
//Template //Template
const downloadTemplate = (fileName, fileType) => api.get(`attachment/download_file?fileName=${fileName}&&fileType=${fileType}`) const downloadTemplate = (fileName, fileType) => api.get(`attachment/download_file?fileName=${fileName}&&fileType=${fileType}`)
...@@ -293,7 +298,10 @@ const create = (baseURL = 'https://tia.eksad.com/tia-reporting-dev/public/') => ...@@ -293,7 +298,10 @@ const create = (baseURL = 'https://tia.eksad.com/tia-reporting-dev/public/') =>
downloadDocument, downloadDocument,
createSubmitReport, createSubmitReport,
getSubmission, getSubmission,
checkUploadMB checkUploadMB,
getAllOperatingInd,
getOperatingIndDetail,
createOpetaingInd
} }
} }
......
...@@ -3,11 +3,33 @@ import { Typography, MuiThemeProvider, createMuiTheme } from '@material-ui/core' ...@@ -3,11 +3,33 @@ import { Typography, MuiThemeProvider, createMuiTheme } from '@material-ui/core'
import MUIDataTable from "mui-datatables"; import MUIDataTable from "mui-datatables";
import Images from '../assets/Images'; import Images from '../assets/Images';
import DonutChart from 'react-d3-donut'; import DonutChart from 'react-d3-donut';
import Constant from '../library/Constant';
import api from '../api';
var ct = require("../library/CustomTable"); var ct = require("../library/CustomTable");
const getMuiTheme = () => createMuiTheme(ct.customTable()); const getMuiTheme = () => createMuiTheme(ct.customTable());
class HomePage extends Component { class HomePage extends Component {
constructor(props) {
super(props)
this.state = {
userData: null
}
}
componentDidMount() {
let userId = localStorage.getItem(Constant.USER)
api.create().getDetailUser(userId).then((response) => {
if (response.data) {
if (response.data.status == 'success') {
this.setState({userData: response.data.data}, () => {
console.log(this.state.userData)
})
}
}
})
}
render() { render() {
const columns = ["#", "Nama Perusahaan", "Revisi", "Status", { const columns = ["#", "Nama Perusahaan", "Revisi", "Status", {
name: "Action", name: "Action",
...@@ -89,7 +111,7 @@ class HomePage extends Component { ...@@ -89,7 +111,7 @@ class HomePage extends Component {
return ( return (
<div style={{ flex: 1, backgroundColor: '#f8f8f8' }}> <div style={{ flex: 1, backgroundColor: '#f8f8f8' }}>
<div className={"main-color"} style={{ height: 78, flex: 1, display: 'flex', alignItems: 'center', paddingLeft: 20 }}> <div className={"main-color"} style={{ height: 78, flex: 1, display: 'flex', alignItems: 'center', paddingLeft: 20 }}>
<Typography style={{ fontSize: '24px', color: 'white' }}>Selamat Datang, John!</Typography> <Typography style={{ fontSize: '24px', color: 'white' }}>{this.state.userData == null? '' : `Selamat Datang, ${this.state.userData.fullname} !`}</Typography>
</div> </div>
<div style={{ flex: 1, padding: 20, width: '100%' }}> <div style={{ flex: 1, padding: 20, width: '100%' }}>
<div style={{ display: 'flex' }}> <div style={{ display: 'flex' }}>
......
This diff is collapsed.
...@@ -12,7 +12,7 @@ import ReportItems from '../container/MasterData/ReportItems' ...@@ -12,7 +12,7 @@ import ReportItems from '../container/MasterData/ReportItems'
import DashboardCAT from '../container/Laporan/DashboardCAT' import DashboardCAT from '../container/Laporan/DashboardCAT'
import BudgetTahunan from '../container/BudgetTahunan'; import BudgetTahunan from '../container/BudgetTahunan';
import RollingOutlook from '../container/RollingOutlook'; import RollingOutlook from '../container/RollingOutlook';
import OperatingIndicator from '../container/OperatingIndicator' import OperatingIndicator from '../container/OprIndicator/OperatingIndicator'
import MonthlyReport from '../container/MonthlyReport'; import MonthlyReport from '../container/MonthlyReport';
import DocumentManagement from '../container/DocumentManagement/DocumentManagement'; import DocumentManagement from '../container/DocumentManagement/DocumentManagement';
......
Markdown is supported
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