Problem/Motivation
When on a project backlog page I get the following error...
TypeError: once is not a function
This prevents me from dragging tasks up or down and when I send the task to the board I get a post error.
Steps to reproduce
Add tasks to a project backlog and try to drag tasks or to post tasks
Visit the console in the code inspector and see the error message
/**
* @file
* Contains burndown.backlog.js.
*/
(function ($, Drupal, drupalSettings) {
Drupal.behaviors.burndownBacklog = {
attach: function (context, settings) {
// Only do setup once.
$('body').once('setupBacklog').each(function () {
// Update sprint data on load.
updateSprints();
// We debounce the postback that saves the new sort
// order, since users can change the order several
// times in a row before getting it the way they want
// it (and we only really need the final ordering).
var reorder = debounce(function() {
postSortOrder();
}, 2000);
Line:9 burndown.backlog.js
$('body').once('setupBacklog').each(function () {
TypeError: once is not a function
TypeError: $(...).once is not a function
attac /modules/contrib/burndown/js/burndown.backlog.js?v=10.0.7:9
Drupal.attachBehaviors/</core/misc/drupal.js?v=10.0.7:166
forEachself-hosted:203
Drupal.attachBehaviors/core/misc/drupal.js?v=10.0.7:162
<anonymous>/core/misc/drupal.init.js?v=10.0.7:32
listener/core/misc/drupal.init.js?v=10.0.7:20
domReady/core/misc/drupal.init.js?v=10.0.7:26
<anonymous>/core/misc/drupal.init.js?v=10.0.7:31
<anonymous>/core/misc/drupal.init.js?v=10.0.7:34
My Setup
Drupal Version
10.0.7
PHP Version
8.1.18
Database Version
5.7.36
Web Server
Apache/2.4.51 (Win64)
| Comment | File | Size | Author |
|---|---|---|---|
| #4 | 3366162.patch | 7.3 KB | prabuela |
Issue fork burndown-3366162
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
vlooi vlerke commentedThe same issue is on the project board page
Comment #3
prabuela commentedComment #4
prabuela commentedComment #5
prabuela commentedComment #6
jeremylichtman commentedHi @prabuEla, if you create the fix as a PR, I will merge it in.
Note that this will effect downwards compatibility. I will have to mark the project as 9.3 upwards as a result of this fix.
Comment #9
bharath-kondeti commented@jeremylichtman Updated the patch to PR. Please check.
Comment #11
jeremylichtman commentedMerged the PR and created 1.0.32.
Note that this means the module is compatible with 9.3+ as a result.