Simon-Initiative / oli-torus

Next Generation OLI Authoring and Delivery Platform
https://proton.oli.cmu.edu
MIT License
83 stars 35 forks source link

[BUG FIX] [NG23-258] survey errors on stellarator server #4931

Closed eliknebel closed 3 months ago

eliknebel commented 3 months ago

https://eliterate.atlassian.net/browse/NG23-258

This PR implements a stop-gap measure to restore functionality to the surveys view in the chemistry course. However, there is likely more rework that needs to be done here in order to get this view working for all courses in a performant way. Currently any survey with a large amount of data has the possibility of crashing the browser page and this fix does not necessarily account for all the different activity types.

We also will likely want to rework some of the patterns in this LiveView so that instead of tacking on data to the content or transformed model to generate the rendered views using this Access.key!(:transformed_model) pattern, we are creating a new struct or data structure to capture all the information needed to generate the activity previews. This logic should probably live in the Oli context, instead of the LiveView itself.