Opened 15 years ago

Closed 15 years ago

#2441 closed enhancement (wontfix)

Allow empty values for inline edit box

Reported by: [email protected] Owned by: Douglas Hays
Priority: high Milestone: 0.9
Component: Dijit Version: 0.4.1
Keywords: inlineEditBox Cc:
Blocked By: Blocking:


Currently, the inlineEditBox widget does not allow for empty values. Most of the time, this is desired, but sometimes, it is not. I altered my copy of dojo to have a 'required' variable with a default of true. Then altered the 'saveEdit' and 'checkForValueChange' functions accordingly. That way I can set it to false when i want to allow empty values.

You can see my edits here:

Also, it would be nice if it checked the return value on the onSave handler. This would allow people to validate the new value.

Change History (4)

comment:1 Changed 15 years ago by [email protected]

I made the changes to cancel the save if onSave returns false:

On the webpage, instead of "event.connect(inlineEditBoxNode,'onSave',saveFunc)" I had to overwrite the onSave function with "inlineEditBoxNode.onSave = saveFunc"

comment:3 Changed 15 years ago by bill

Component: WidgetsDijit
Milestone: 0.9
Owner: changed from bill to Douglas Hays

comment:4 Changed 15 years ago by Douglas Hays

Resolution: wontfix
Status: newclosed

The InlineEditBox? widget was rewritten for 0.9. Empty values are allowed now. An ampty value is displayed as a single ? so that it can be clicked and edited. All widgets that inherit from Textbox can be used as the editing widget and they all support the required attribute. Ths change will not be backported to 0.4.x.

Note: See TracTickets for help on using tickets.