rename original gangsta to gang

This commit is contained in:
Bilal
2020-10-07 18:26:59 +03:00
parent b5a70a6e42
commit e0c5f60c68
13 changed files with 67 additions and 63 deletions

View File

@@ -7,7 +7,7 @@ import {errorToast} from "../common/errorHelpers";
const CashFlow = (props) => {
const { homie_id } = useParams();
const originalGangsta = props.originalGangsta;
const gang = props.gang;
const [cashFlow, setCashFlow] = useState([]);
@@ -35,7 +35,7 @@ const CashFlow = (props) => {
<div>{ dateBlock(singleFlowData['created_at']) }</div>
</div>
<div className={`flex-center ${singleFlowData.amount > 0 ? 'amount-green' : ''}`}>{ formatMoney(singleFlowData.amount, originalGangsta) }</div>
<div className={`flex-center ${singleFlowData.amount > 0 ? 'amount-green' : ''}`}>{ formatMoney(singleFlowData.amount, gang) }</div>
</div>
</div>
</li>
@@ -58,7 +58,7 @@ const CashFlow = (props) => {
<strong>{`${totalCount} Records`}</strong><span className="grey-text">{` ${fromDate} - ${toDate}`}</span>
</div>
<div className="col s6 right-align">
<span className="grey-text">Total cash flow:</span> <strong>{formatMoney(totalFlow, originalGangsta)}</strong>
<span className="grey-text">Total cash flow:</span> <strong>{formatMoney(totalFlow, gang)}</strong>
</div>
</div>
</div>

View File

@@ -7,7 +7,7 @@ import WorkFlow from "./WorkFlow";
const Flow = (props) => {
const [flowType, setFlowType] = useState('cash');
const originalGangsta = props.originalGangsta;
const gang = props.gang;
return (
<div className="container">
@@ -19,7 +19,7 @@ const Flow = (props) => {
/>
</div>
{ flowType === 'cash' && <CashFlow originalGangsta={originalGangsta} /> }
{ flowType === 'cash' && <CashFlow gang={gang} /> }
{ flowType === 'work' && <WorkFlow /> }
</div>