Multidimensional array to datatable

Multidimensional array to datatable

shi_roshi_ro Posts: 3Questions: 2Answers: 0

I have a html table which looks like this :smile:

I would like to convert it to a datatable , so that i can easily implement filters. But i have been having challenges because my dataset looks like this. Is there support for such a data structure?:

array( 
    'items' => array ( 
        '2020-08-04' => array ( 
            0 => array ( 
                0 => array ( 
                    'payment_name' =>'Cash',
                    'amount_paid' => "0"
                ), 
            ), 
            1 => 0, 
        ),
        '2020-08-05' => array ( 
            0 => array( 
                0 => array ( 
                    'payment_name' => 'Cash', 
                    'amount_paid' => "0"
                ),
                1 => array ( 
                    'payment_name' => 'Mpesa', 
                    'amount_paid' => "165" 
                ), 
            ), 
            1 => 165, 
        ), 

This question has an accepted answers - jump to answer

Answers

This discussion has been closed.