I have array like this:
// array of moderator code
Array
(
[0] => M1
[1] => M2
[2] => M3
[3] => M1
)
// array of commission amount and status based on the above array
Array
(
[10] => Paid
[20] => Due
[30] => Cancelled
[40] => Paid
)
If any of the moderator logs in, he should see only his commission details and not of others. For example, if M1 logs in, he should see like this in his my account:
OrderCode PaidAmount CancelledAmount DueAmount Action
1 50.00 (40 + 10) 0.00 0.00 View
And similarly for other moderators also.
How do I achieve this ?
P.S.: The above arrays are just an example I am trying to understand in order to build my application. In reality, the order will contain any x number of moderators and it's corresponding commission amount and status and are going to be retrieved from the database.