HGustavs / LenaSYS

Code Viewer and Course Organization System used in some courses at University of Skövde
57 stars 31 forks source link

The button to show/hide hidden items in sectioned.php doesn't work #16181

Open a22chrfa opened 1 month ago

a22chrfa commented 1 month ago

image

It seems this button has the intention to be a toggle-function for hidden items. As of now, the hidden items are always displayed and the button doesn't actually do anything.

Explore if this button can be activated in order to toggle the hidden items

a22chrfa commented 1 month ago

In reference to the commit that was just made, here's some useful information to anyone looking to improve or alter the code in the future. (some of this is still beyond my understanding).

The tables are generated with javascript, which uses the draggable function of jquery. This seems to make the element dynamic and therefore does not exist when the document is fully loaded. Even though we know it exists by looking in the browser.

image image

They do exist within the function that creates them though, so we can add logic there, which is what I did in the commit.

I've also noted that the ID's in the list are based on type and position, so an item doesn't really have a static ID. It gets a generated ID depending on its position. This might require some extra functionality later on...