Commit ab404d04 authored by Dida Adams Arizona's avatar Dida Adams Arizona

Merge branch 'rifka' into 'master'

docman

See merge request !487
parents 7579513c eb38e8f7
...@@ -128,7 +128,9 @@ export default class TaxPlanning extends Component { ...@@ -128,7 +128,9 @@ export default class TaxPlanning extends Component {
item.tax_planning.total_current_year, item.tax_planning.total_current_year,
{ tbc: item.tax_planning.total_next_year.tbc, fcp: item.tax_planning.total_next_year.fcp, tbf: item.tax_planning.total_next_year.tbf }, { tbc: item.tax_planning.total_next_year.tbc, fcp: item.tax_planning.total_next_year.fcp, tbf: item.tax_planning.total_next_year.tbf },
{ tbc: item.tax_planning.total_more_year.tbc, fcp: item.tax_planning.total_more_year.fcp, tbf: item.tax_planning.total_more_year.tbf }, { tbc: item.tax_planning.total_more_year.tbc, fcp: item.tax_planning.total_more_year.fcp, tbf: item.tax_planning.total_more_year.tbf },
item.order item.order,
item.condition_it_should_be,
item.condition_if_wrong
]) ])
} }
if (item.children !== null) { if (item.children !== null) {
...@@ -168,7 +170,9 @@ export default class TaxPlanning extends Component { ...@@ -168,7 +170,9 @@ export default class TaxPlanning extends Component {
item.tax_planning.total_current_year, item.tax_planning.total_current_year,
{ tbc: item.tax_planning.total_next_year.tbc, fcp: item.tax_planning.total_next_year.fcp, tbf: item.tax_planning.total_next_year.tbf }, { tbc: item.tax_planning.total_next_year.tbc, fcp: item.tax_planning.total_next_year.fcp, tbf: item.tax_planning.total_next_year.tbf },
{ tbc: item.tax_planning.total_more_year.tbc, fcp: item.tax_planning.total_more_year.fcp, tbf: item.tax_planning.total_more_year.tbf }, { tbc: item.tax_planning.total_more_year.tbc, fcp: item.tax_planning.total_more_year.fcp, tbf: item.tax_planning.total_more_year.tbf },
item.order item.order,
item.condition_it_should_be,
item.condition_if_wrong
]) ])
if (item.children !== null) { if (item.children !== null) {
if (item.children.length > 0) { if (item.children.length > 0) {
...@@ -504,12 +508,14 @@ export default class TaxPlanning extends Component { ...@@ -504,12 +508,14 @@ export default class TaxPlanning extends Component {
tbf: Number(item.type_report_id.tbf) === 3 && item.total_more_year.tbf === "" ? "0" : item.total_more_year.tbf tbf: Number(item.type_report_id.tbf) === 3 && item.total_more_year.tbf === "" ? "0" : item.total_more_year.tbf
}, },
item.orders, item.orders,
item.condition_it_should_be,
item.condition_if_wrong,
item.error item.error
] ]
}) })
this.setState({ dataTable, dataLoaded: true, loading: false, buttonError: false, editable: true }, () => { this.setState({ dataTable, dataLoaded: true, loading: false, buttonError: false, editable: true }, () => {
this.state.dataTable.map(item => { this.state.dataTable.map(item => {
if (item[25].length > 0) { if (item[27].length > 0) {
console.log('masuk') console.log('masuk')
this.setState({ buttonError: true, errorPreview: true, editable: true }) this.setState({ buttonError: true, errorPreview: true, editable: true })
} }
...@@ -974,8 +980,8 @@ export default class TaxPlanning extends Component { ...@@ -974,8 +980,8 @@ export default class TaxPlanning extends Component {
customBodyRender: (val, tableMeta) => { customBodyRender: (val, tableMeta) => {
return ( return (
<div style={{ width: 300 }}> <div style={{ width: 300 }}>
{tableMeta.rowData[24] ? {tableMeta.rowData[27] ?
tableMeta.rowData[24].length > 0 ? tableMeta.rowData[27].length > 0 ?
<div style={{ paddingLeft: 20 * Number(tableMeta.rowData[4]) }}> <div style={{ paddingLeft: 20 * Number(tableMeta.rowData[4]) }}>
<LightTooltip title={"Report Items Not Registered"} arrow> <LightTooltip title={"Report Items Not Registered"} arrow>
<span style={{ fontSize: 12, color: 'red' }}>{tableMeta.rowData[0] === 4 ? "" : val}</span> <span style={{ fontSize: 12, color: 'red' }}>{tableMeta.rowData[0] === 4 ? "" : val}</span>
......
...@@ -34,6 +34,8 @@ export default class getAllDocument extends Component { ...@@ -34,6 +34,8 @@ export default class getAllDocument extends Component {
componentDidMount() { componentDidMount() {
this.getData() this.getData()
console.log(this.props.allsubcoEdit)
console.log(this.props.btnedit)
} }
componentWillReceiveProps(props) { componentWillReceiveProps(props) {
...@@ -238,7 +240,7 @@ export default class getAllDocument extends Component { ...@@ -238,7 +240,7 @@ export default class getAllDocument 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" />
{this.props.btnedit && this.props.allsubcoEdit && <span> {(this.props.allsubcoEdit || this.props.btnedit) && <span>
<a data-tip={'Edit'} data-for="edit"> <a data-tip={'Edit'} data-for="edit">
<button <button
style={{ style={{
......
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