Opened 6 years ago

Closed 6 years ago

Last modified 6 years ago

#17103 closed defect (fixed)

BUG: dojox.form.CheckedMultiSelect combobox empty and menu doesn't have checkboxes

Reported by: alexandre Owned by: Ed Chatelain
Priority: undecided Milestone: 1.7.6
Component: DojoX Form Version: 1.9.0
Keywords: Cc:
Blocked By: Blocking:

Description

There is a problem with dojox.form.CheckedMultiSelect?, when try load the combobox came empty and when try select items, the checkbox is hidden.

How to test? Visit: /dojox/form/tests/test_CheckedMultiSelectDropDown.html or http://archive.dojotoolkit.org/nightly/dojotoolkit/dojox/form/tests/test_CheckedMultiSelectDropDown.html

Vitorelli

Change History (23)

comment:1 Changed 6 years ago by George Sexton

Null comment to add myself to CC list.

comment:2 Changed 6 years ago by alexandre

The problem persists on version 1.9.1.

Vitorelli.

Last edited 6 years ago by alexandre (previous) (diff)

comment:3 Changed 6 years ago by alexandre

The same problem occurs now on version 1.7.5 and 1.8.5.

Vitorelli

Last edited 6 years ago by alexandre (previous) (diff)

comment:4 Changed 6 years ago by bill

Owner: changed from dante to Ed Chatelain
Status: newassigned
Summary: BUG: dojox.form.CheckedMultiSelectBUG: dojox.form.CheckedMultiSelect combobox empty and menu doesn't have checkboxes

Started with 60443e413c710860cf70b16302a8ed98b1ac5e92 change to dijit.

comment:5 Changed 6 years ago by bill

#16189 is a duplicate of this ticket.

comment:6 Changed 6 years ago by Becca Stewart

Work around: set .dojoxCheckedMultiSelectMenuCheckBoxItemIcon to 'display:block'

http://jsfiddle.net/down_quark/cNATk/

Version 0, edited 6 years ago by Becca Stewart (next)

comment:7 Changed 6 years ago by Ed Chatelain

down_quark thanks for the jsfiddle, but it looks like this gets around the problem with the display of the checkboxes in the dropdown, but not the initial display of the CheckedMultiSelect? with the empty combobox. It should have 0 item(s) selected initially.

comment:8 Changed 6 years ago by Ed Chatelain

It looks like the change bill mentioned above "Started with 60443e413c710860cf70b16302a8ed98b1ac5e92 change to dijit." broke the setting of the label into the combobox. But it does not look to me like the checkboxes were displaying when dropDown is set to true before the change above. I assume the checkboxes are supposed to be displayed in the dropdown list.

comment:9 Changed 6 years ago by Ed Chatelain

The fix for the empty label would be to change dijit/form/_FormSelectWidget.js to add this line into postCreate: aspect.after(this, "startup", lang.hitch(this, "_loadChildren"));

And remove the call to _loadChildren from startup: (actually the entire startup: function should be removed)

/* this._loadChildren(); */

The change needed to fix the mvc problem was to setup the store in postCreate instead of startup, the moving of the call to _loadChildren into startup was not needed.

I will work on the display of the checkboxes before I do a pull request.

Last edited 6 years ago by Ed Chatelain (previous) (diff)

comment:10 Changed 6 years ago by Ed Chatelain

It looks like the fix for the display of the checkboxes is to update dojox/form/CheckedMultiSelect.js to change the formCheckedMultiSelectMenuItem to set iconClass: "", instead of setting _iconClass: "",

I will create a pull request for these updates.

comment:11 Changed 6 years ago by Ed Chatelain

Here are the two pull requests, I will wait to see if there are any comments or concerns before I merge and backport these.

https://github.com/dojo/dijit/pull/2

https://github.com/dojo/dojox/pull/18

comment:12 Changed 6 years ago by Ed Chatelain

After Bill's comment that the label problem could also be fixed in dojox/form/CheckedMultiSelect.js I have closed the two previous pull requests and created a new pull request which will fix both problems in dojox/form/CheckedMultiSelect.js.

https://github.com/dojo/dojox/pull/19

comment:13 Changed 6 years ago by Ed Chatelain <ed.chatelain@…>

Resolution: fixed
Status: assignedclosed

In 1a7a9849a0d17d88854fca05c589dee97aa13353/dojox:

Error: Processor CommitTicketReference failed
Unsupported version control system "git": Can't find an appropriate component, maybe the corresponding plugin was not enabled? 

comment:14 Changed 6 years ago by Ed Chatelain <ed.chatelain@…>

In 0761a3361ed050bc3b7ecc572955449f80db7bb4/dojox:

Error: Processor CommitTicketReference failed
Unsupported version control system "git": Can't find an appropriate component, maybe the corresponding plugin was not enabled? 

comment:15 Changed 6 years ago by Ed Chatelain

Milestone: tbd1.9.2

comment:16 Changed 6 years ago by Ed Chatelain <ed.chatelain@…>

In 065eed31cfa31cc749907999562fea7b3e4f0995/dojox:

Error: Processor CommitTicketReference failed
Unsupported version control system "git": Can't find an appropriate component, maybe the corresponding plugin was not enabled? 

comment:17 Changed 6 years ago by Ed Chatelain

Milestone: 1.9.21.7.6

Backported to 1.7

comment:18 Changed 6 years ago by Becca Stewart

I'm not seeing the fix for #17103 in 1.9.2 for programmatic and modern declarative instantiation. I updated this fiddle which is running on the nightly http://jsfiddle.net/down_quark/cNATk/58/ Let me know if the ways I've instantiated CheckedMultiSelect? are incorrect. Sorry I waited so long to check this.

comment:19 Changed 6 years ago by bill

Checkboxes *in drop downs* work for claro, but not for tundra, and probably not for soria or nihilo either. This shouldn't be surprising when you noticed that CheckedMultSelect?.css has 10 lines for tundra and 150 lines for claro. You can reproduce this by editing test_CheckedMultiSelectDropDown.html and changing claro to tundra. You are using tundra.

Claro support was implemented in f32630552c5e39802632969765fac9fa0735e5c9.

You can open a ticket about tundra not working if you like. Maybe edchat would want to implement it.

comment:20 Changed 6 years ago by Becca Stewart

Bill, are you saying the problem I'm seeing is due to lack of tundra support in the #12683 fix?

Is it common practice for a ticket to be closed even if the bug is only fixed in the claro theme?

I have a workaround that corrects this bug in tundra that doesn't involve adding any tundra specific CSS. But I won't make any guarantees that my workaround is the correct/most efficient way to fix this.

    array.forEach(select._getChildren(), function (item) {
        item.set('iconClass', 'dijitCheckBox');
        item.onChange = function () {
            domClass.toggle(item.iconNode, 'dijitCheckBoxChecked dijitChecked');
        };
    });

http://jsfiddle.net/cNATk/61/

comment:21 in reply to:  20 Changed 6 years ago by bill

Replying to down_quark:

Bill, are you saying the problem I'm seeing is due to lack of tundra support in the #12683 fix?

Yes.

Is it common practice for a ticket to be closed even if the bug is only fixed in the claro theme?

No.

comment:22 Changed 6 years ago by Ed Chatelain

I can take a look at the problem with tundra when I have some free time. I am just back from vacation so I have a lot of email to catch up on, and other higher priority work items to get done before I will be able to work on this one.

Of course you are welcome to submit a pull request with a fix following the contribution guidelines here if you would like a fix sooner: https://github.com/dojo/dojo/blob/master/CONTRIBUTING.md

comment:23 Changed 6 years ago by Ed Chatelain

down_quark, if you want a work around for the problem with the checkbox not showing up for CheckedMultiSelect? in a dropdown with tundra you can add the follow to your css and that should show it.

.tundra .dojoxCheckedMultiSelectCheckBoxInput {

opacity: 1;

}

Note: See TracTickets for help on using tickets.