quickhac / qhac-ios

Native iOS app to allow checking of grades, based on the QuickHAC Chrome extension.
0 stars 0 forks source link

Store data availability info in the course, rather than the district object #17

Closed tristanseifert closed 10 years ago

tristanseifert commented 10 years ago

Storing this data with the district object creates issues with the user switching if there is no connection present, as there must first be a request made to the server to fetch these hashes and build the table, which will fail if the user is offline.

Instead, add a 32-bit integer field to the SQUCourse object, with each bit set representing data is available for that cycle, and updating it based on data fetched by the district object, and referring to this for information. The district object would still keep an internal table of hashes, which is only used for network requests, and thus will only be accessed if the network connection is active.

tristanseifert commented 10 years ago

This is already implemented in the form of the hasDataInGradebook BOOL on the SQUCycle object, but doesn't seem to work properly for some reason. There is probably some form of issue in the grade overview controller not interpreting this correctly.

tristanseifert commented 10 years ago

This has mostly been somewhat fixed.