Commit 2f4cacc7 authored by Deni Rinaldi's avatar Deni Rinaldi

Merge branch 'faisal' into 'master'

ubah bahasa

See merge request !150
parents a47520cf 6a3e2e13
...@@ -90,7 +90,7 @@ export default class Perusahaan extends Component { ...@@ -90,7 +90,7 @@ export default class Perusahaan extends Component {
let columns = [ let columns = [
"Data Ke-", "Data Ke-",
{ {
name: "Nama Perusahaan", name: "Company Name",
options: { options: {
customBodyRender: (val, tableMeta) => { customBodyRender: (val, tableMeta) => {
let check = null let check = null
...@@ -247,7 +247,7 @@ export default class Perusahaan extends Component { ...@@ -247,7 +247,7 @@ export default class Perusahaan extends Component {
if (response.data.status == 'success') { if (response.data.status == 'success') {
let data = response.data.data let data = response.data.data
let listData = data.sort((a, b) => a.company_id - b.company_id).map((item, index) => { let listData = data.sort((a, b) => a.company_id - b.company_id).map((item, index) => {
return [index, item.company_id, item.company_name, item.parent_name, item.business_unit_name, item.total_report, item.status] return [index, item.company_id, item.company_name, item.parent_name, item.business_unit_name, item.status]
}) })
this.setState({ dataTable: listData, listData: response.data.data }) this.setState({ dataTable: listData, listData: response.data.data })
} else { } else {
...@@ -283,7 +283,7 @@ export default class Perusahaan extends Component { ...@@ -283,7 +283,7 @@ export default class Perusahaan extends Component {
if (response.data.status == 'success') { if (response.data.status == 'success') {
let data = response.data.data let data = response.data.data
let listData = data.map((item, index) => { let listData = data.map((item, index) => {
return [index, item.company_id, item.company_name, item.parent_name, item.business_unit_name, item.total_report, item.status] return [index, item.company_id, item.company_name, item.parent_name, item.business_unit_name, item.status]
}) })
this.setState({ dataTable: listData, listData: response.data.data }) this.setState({ dataTable: listData, listData: response.data.data })
} else { } else {
...@@ -405,18 +405,18 @@ export default class Perusahaan extends Component { ...@@ -405,18 +405,18 @@ export default class Perusahaan extends Component {
customBodyRender: (val, tableMeta) => { customBodyRender: (val, tableMeta) => {
return ( return (
<div style={{ display: 'flex' }}> <div style={{ display: 'flex' }}>
<span style={{ color: tableMeta.rowData[6] === "Aktif" ? "#656565" : 'rgba(0, 0, 0, 0.25)' }}>{val}</span> <span style={{ color: tableMeta.rowData[5] === "Aktif" ? "#656565" : 'rgba(0, 0, 0, 0.25)' }}>{val}</span>
</div > </div >
); );
} }
} }
}, { }, {
name: "Nama Perusahaan", name: "Company Name",
options: { options: {
customBodyRender: (val, tableMeta) => { customBodyRender: (val, tableMeta) => {
return ( return (
<div style={{ display: 'flex' }}> <div style={{ display: 'flex' }}>
<span style={{ color: tableMeta.rowData[6] === "Aktif" ? "#656565" : 'rgba(0, 0, 0, 0.25)' }}>{val}</span> <span style={{ color: tableMeta.rowData[5] === "Aktif" ? "#656565" : 'rgba(0, 0, 0, 0.25)' }}>{val}</span>
</div > </div >
); );
} }
...@@ -427,29 +427,18 @@ export default class Perusahaan extends Component { ...@@ -427,29 +427,18 @@ export default class Perusahaan extends Component {
customBodyRender: (val, tableMeta) => { customBodyRender: (val, tableMeta) => {
return ( return (
<div style={{ display: 'flex' }}> <div style={{ display: 'flex' }}>
<span style={{ color: tableMeta.rowData[6] === "Aktif" ? "#656565" : 'rgba(0, 0, 0, 0.25)' }}>{val}</span> <span style={{ color: tableMeta.rowData[5] === "Aktif" ? "#656565" : 'rgba(0, 0, 0, 0.25)' }}>{val}</span>
</div > </div >
); );
} }
} }
}, { }, {
name: "Unit Bisnis", name: "Business Unit",
options: {
customBodyRender: (val, tableMeta) => {
return (
<div style={{ display: 'flex' }}>
<span style={{ color: tableMeta.rowData[6] === "Aktif" ? "#656565" : 'rgba(0, 0, 0, 0.25)' }}>{val}</span>
</div >
);
}
}
}, {
name: "Jumlah Laporan",
options: { options: {
customBodyRender: (val, tableMeta) => { customBodyRender: (val, tableMeta) => {
return ( return (
<div style={{ display: 'flex' }}> <div style={{ display: 'flex' }}>
<span style={{ color: tableMeta.rowData[6] === "Aktif" ? "#656565" : 'rgba(0, 0, 0, 0.25)' }}>{val}</span> <span style={{ color: tableMeta.rowData[5] === "Aktif" ? "#656565" : 'rgba(0, 0, 0, 0.25)' }}>{val}</span>
</div > </div >
); );
} }
...@@ -460,7 +449,7 @@ export default class Perusahaan extends Component { ...@@ -460,7 +449,7 @@ export default class Perusahaan extends Component {
customBodyRender: (val, tableMeta) => { customBodyRender: (val, tableMeta) => {
return ( return (
<div style={{ display: 'flex' }}> <div style={{ display: 'flex' }}>
<span style={{ color: tableMeta.rowData[6] === "Aktif" ? "#656565" : 'rgba(0, 0, 0, 0.25)' }}>{val}</span> <span style={{ color: tableMeta.rowData[5] === "Aktif" ? "#656565" : 'rgba(0, 0, 0, 0.25)' }}>{val === "Aktif" ? "Active" : "Inactive"}</span>
</div > </div >
); );
} }
...@@ -485,7 +474,7 @@ export default class Perusahaan extends Component { ...@@ -485,7 +474,7 @@ export default class Perusahaan extends Component {
{this.state.visiblePerusahaan === true ? {this.state.visiblePerusahaan === true ?
<div> <div>
<div style={{ display: 'flex', flexDirection: 'row', justifyContent: 'space-between', paddingRight: 25, paddingLeft: 25, marginTop: -150 }}> <div style={{ display: 'flex', flexDirection: 'row', justifyContent: 'space-between', paddingRight: 25, paddingLeft: 25, marginTop: -150 }}>
<label style={{ color: 'white', fontSize: 16, alignSelf: 'center', width: '20%', }}>Master Data - Perusahaan</label> <label style={{ color: 'white', fontSize: 16, alignSelf: 'center', width: '20%', }}>Master Data - Company</label>
<div style={{ color: 'white', width: '50%', height: 37, display: 'flex', backgroundColor: 'white', borderWidth: 2, alignItems: 'center', borderRadius: 6, paddingLeft: 5, paddingRight: 5, alignSelf: 'center' }}> <div style={{ color: 'white', width: '50%', height: 37, display: 'flex', backgroundColor: 'white', borderWidth: 2, alignItems: 'center', borderRadius: 6, paddingLeft: 5, paddingRight: 5, alignSelf: 'center' }}>
<img src={Images.searchBlack} style={{ marginRight: 10 }} /> <img src={Images.searchBlack} style={{ marginRight: 10 }} />
<InputBase <InputBase
...@@ -539,7 +528,7 @@ export default class Perusahaan extends Component { ...@@ -539,7 +528,7 @@ export default class Perusahaan extends Component {
</button> </button>
</a> </a>
<ReactTooltip border={true} id="download" place="bottom" type="light" effect="solid" /> <ReactTooltip border={true} id="download" place="bottom" type="light" effect="solid" />
<a data-tip={'Visualisasi'} data-for="visual"> <a data-tip={'Visualization'} data-for="visual">
<button <button
style={{ style={{
backgroundColor: 'transparent', backgroundColor: 'transparent',
...@@ -553,7 +542,7 @@ export default class Perusahaan extends Component { ...@@ -553,7 +542,7 @@ export default class Perusahaan extends Component {
</button> </button>
</a> </a>
<ReactTooltip border={true} id="visual" place="bottom" type="light" effect="solid" /> <ReactTooltip border={true} id="visual" place="bottom" type="light" effect="solid" />
<a data-tip={'Tambah'} data-for="create"> <a data-tip={'Add'} data-for="create">
<button <button
style={{ style={{
backgroundColor: 'transparent', backgroundColor: 'transparent',
......
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