View Issue Details
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0027122||mantisbt||plug-ins||public||2020-08-03 12:35||2020-08-09 08:17|
|Target Version||2.25.0||Fixed in Version||2.25.0|
|Summary||0027122: 3rd-party plugins cannot use chart.js library bundled with MantisGraph|
When the MantisGraph plugin was modified to rely on chart.js as part of 2.0 release, the library was loaded on every single page.
While not very efficient, this allowed 3rd-party plugins to use the chart.js library to display their own graphs.
From MantisBT 2.8.0, the MantisGraph Plugin only loads chart.js for its own pages (see 0023446), which broke the above-mentioned plugins, as they could no longer access chart.js resources, unless they bundled the library themselves, which is also inefficient and could lead to compatibility conflicts due to version mismatch.
|Tags||No tags attached.|
MantisBT: master a1453788
2020-05-25 12:42:31Details Diff
|MantisGraph: new method to load chart.js resources
Since MantisBT 2.8.0, MantisGraph only loads chart.js for its own pages.
This prevents other plugins from accessing these resources to publish
their own charts, unless they bundle chart.js themselves.
This commit exposes a dedicated public method include_chartjs() to
include the library, separately from the plugin's standard resources()
|mod - plugins/MantisGraph/MantisGraph.php||Diff File|