Opened 8 years ago

Closed 8 years ago

#14741 closed defect (wontfix)

Missing argument in EnhancedGrid _Plugin.js

Reported by: fredfortier Owned by: fredfortier
Priority: undecided Milestone: tbd
Component: DojoX Grid Version: 1.7.1
Keywords: Cc:
Blocked By: Blocking:

Description

I am trying to load the EnhancedGrid? with Dojo 1.7.1 on a site that also runs Dojo 1.3.2. So I namespaced the Dojo 1.7.1 packages.

When running the enhanced grid with the pagination plug-in, I got an error coming from _Plugin.js "dojox.grid undefined".

When looking at the class definition, I realize that dojox is not mapped to an argument. So I added these two parameters which has resolved this particular issue.

define([
	"dojo/_base/kernel",
	"dojox/main", //<--This was not here. But dojox is referenced in the code. Not good when namespacing dojox.
	"dojo/_base/lang",
	"dojo/_base/declare",
	"dojo/_base/array",
	"dojo/_base/connect",
    "../EnhancedGrid"
], function(dojo, dojox, //<--This was not here either.
    lang, declare, array, connect){

Change History (6)

comment:1 Changed 8 years ago by Evan

Can you provide a test case or some detail usages? Would like to figure out the exact cause.

The test cases are running well with me. And this scenario exist for many Grid files, are they all not working in your case?

comment:2 Changed 8 years ago by Evan

Owner: changed from Evan to fredfortier
Status: newpending

comment:3 Changed 8 years ago by fredfortier

Status: pendingnew

The issue occurs when using the pagination plug-in specifically. The EnhancedGrid? alone works fine. I am using programmatic syntax within a templated widget.

I am using two version of Dojo on the same page.

comment:4 in reply to:  3 Changed 8 years ago by Evan

Replying to fredfortier:

The issue occurs when using the pagination plug-in specifically. The EnhancedGrid? alone works fine. I am using programmatic syntax within a templated widget.

I am using two version of Dojo on the same page.

Could you post your test case or some detail usages so that I can have a quick fix/verify?

comment:5 Changed 8 years ago by fredfortier

Sorry, I would but I have opted for dGrid instead of enhanced grid so this code is gone. You should be able to reproduce in any environment that has multiple version of dojox per page. In my application for instance, I have a packagemap like this as I want to direct my application components to a specific version of dojox (1.7.1)

name : 'lcsDojox', location : '/lcsdojo/js/dojo-release-1.7.1-LCS/dojox', packageMap : {

dojo : 'lcsDojo', dijit : 'lcsDijit', dojox : 'lcsDojox'

}

Without the hack above, the dojox reference in the Plugin js was directed to the other version of dojox in my page (the one without the package map). As soon as I specifically scoped dojox to "dojox/main", things started to work and I could see the "correct" dojox being referenced.

comment:6 Changed 8 years ago by bill

Resolution: wontfix
Status: newclosed

Presumably this is a wontfix, given that enhanced grid is being superceded by gridx and dgrid.

Note: See TracTickets for help on using tickets.