Loading...

Staff staffTimetableFull

Request Description

Using the supplied person id and effective date returns the full timetable for the member of staff, including: Day, period, class_id, description, room, subject, current lesson. Class_id is useful for other API requests such as class lists whereas CURRENT will either be 1 or 0 - 0 for not the current class, 1 being (based on time and date) the current class the member of staff is teaching in at the time of the request.


Request Information

Response Format:JSON
Requires Authentication:Yes
Cached:No
Cache Duration:N/A

Parameters

user_idPerson ID to lookup against
effective_date
Optional
Effective date to check against in format of YYYY-MM-DD. If not specified, request will assume todays date.

Example Request

$a = $api->sendRequest(
  array( 
    'controller'      => 'Staff',  
    'action'          => 'staffTimetableFull',
    'user_id'         => '12345',
    'effective_date'  => '2015-05-26'
  )
  );

Example Result

Array
(
    [result] => Success
    [data] => Array
        (
            [Mon] => Array
                (
                    [5] => Array
                        (
                            [PERIOD] => 5
                            [CLASS_ID] => 151232
                            [CLASS_DESC] => 7A/Hi
                            [SUBJECT_DESC] => History
                            [ROOM] => 7
                            [CURRENT] => 0
                        )

                    [6] => Array
                        (
                            [PERIOD] => 6
                            [CLASS_ID] => 151232
                            [CLASS_DESC] => 7B/Hi
                            [SUBJECT_DESC] => History
                            [ROOM] => 8
                            [CURRENT] => 0
                        )

                )

            [Tue] => Array
                (

                    [3] => Array
                        (
                            [PERIOD] => 3
                            [CLASS_ID] => 119370
                            [CLASS_DESC] => 10C/Pd
                            [SUBJECT_DESC] => Citizenship
                            [ROOM] => 36
                            [CURRENT] => 1
                        )

                    [6] => Array
                        (
                            [PERIOD] => 6
                            [CLASS_ID] => 140471
                            [CLASS_DESC] => 8D/Fr
                            [SUBJECT_DESC] => French
                            [ROOM] => 28
                            [CURRENT] => 0
                        )

                )

        )

    [current] => Array(
                    [PERIOD] => 3
                    [CLASS_ID] => 119370
                    [CLASS_DESC] => 10C/Pd
                    [SUBJECT_DESC] => Citizenship
                    [ROOM] => 36
                    [CURRENT] => 1
    )
)