This implementation will introduce bulk actions qbank
plugins which can grab the selected question and perform
actions according to the selected option from dropdown
in the base view.
Co-Authored-By: Safat Shahin <safatshahin@catalyst-au.net>
Co-Authored-By: Matt Porritt <mattp@catalyst-au.net>
It's important to say that this bug apparently (till now) only happens
when an *incorrect* instalation of a site happens, reusing the dataroot
from another existing site.
When that happens, the localcache/bootstrap.php file from the old
site is reused, setting siteidentifier and SYSCONTEXTID when it's not
time for them to be defined yet.
Their existenece leads to reusing some other structures from the old
dataroot (that, again, should have been changed or wiped!), ultimately
leading to all sort of errors about non-existent tables (course,
context...).
With this change we ensure that:
1) Whenever any change to the database configuration (prefix, user,
type..) happens, it's detected and immediately the information
in the localcache/bootstrap.php is discarded and the file removed.
This should fix problems like MDL-73098 itself.
2) We only set SYSCONTEXTID if the file is not stale. Main reason
for doing that check within the localcache/bootstrap.php file
itself is that we cannot "undefine" it @ setup.php. This should
prevent errros like MDL-72888 to happen.
3) Finally, little detail, we only define SYSCONTEXTID if it has
not been defined earlier. In the past, it was recommended to
define it in config.php (exactly to save one DB read) and, sites
having them will face "already defined" warnings.
- Revert unnecessary primary_active_tab setters
- Modify the navigation nodes to never change text based on default homepage
- Make sure a tab is set active
This option allows report creators to avoid duplicate data being
displayed in their report. It is applied only when no columns in the
report currently have aggregation methods applied.
The format_string() function does half html escaping. It escapes < and >
characters, but does not escape ". Therefore, it put us in a situation
where neither {{}}, nor {{{}}} are suitable in templates. If we use {{}}
for an attribute (like title or aria-label), then < and > characters
will be double escaped. On the other hand, if we use {{{}}} there, a
double quote character will break HTML when it is used in an attribute.
Therefore, neither {{}}, nore {{{}}} are usable in html attributes.
Moreover, The title attribute here was redundant because it had the same
value as the link's text.
The new get_safe_orderby() and get_safe_orderby_multiple() methods
provide a centralised safe way for user submitted sorting values to be
incorporated into SQL ORDER BY. They do this by removing the need for
user submitted data to pass in any SQL and not allowing arbitrary
column values, instead using string keys which map to a predefined
list of allowed sortable columns.
Checks if a form element has attributes before
trying to get the default value. This fixes
an error when trying to get the default value
for a frozen group which does not have the
attributes array.
- new 'set_columns_attributes' method created to add column attributes included in every column cell.
- new 'get_row_cells_html' method created from 'get_row_html', so it can be overriden individually.