Opened 13 years ago
Closed 13 years ago
#5257 closed enhancement (fixed)
QueryReadStore: getLabel (from FileItemReadStore)
Reported by: | guest | Owned by: | Jared Jurkiewicz |
---|---|---|---|
Priority: | high | Milestone: | 1.1 |
Component: | DojoX Data | Version: | 1.0 |
Keywords: | Cc: | [email protected]… | |
Blocked By: | Blocking: |
Description
Even though it clearly says in QueryReadStore?'s getLabel-function: "Override it to return whatever the label shall be, see Read-API.", I feel that a default implementation would be valuable. Plus, it's relatively simple to implement by recycling FileItemReadStore?. FileItemReadStore? allows setting label just like the identifier - in response data object.
The getLabel-function:
getLabel: function(/* item */ item){ if(this._labelAttr && this.isItem(item)){ return this.getValue(item,this._labelAttr); //String } return undefined; //undefined },
In addition, it would require setting label somewhere in _fetchItems:
this._labelAttr = data.label;
Attachments (1)
Change History (6)
comment:1 Changed 13 years ago by
Milestone: | 1.0.2 → 1.1 |
---|
comment:2 Changed 13 years ago by
Owner: | changed from Jared Jurkiewicz to wolfram |
---|
Changed 13 years ago by
Attachment: | patch5257.patch added |
---|
comment:4 Changed 13 years ago by
comment:5 Changed 13 years ago by
Resolution: | → fixed |
---|---|
Status: | new → closed |
Tested on:
Firefox 2.0.0.12 Safari B3: IE 6 Seamonkey 1.1.2 IE 7
Passed.
Closing as fixed.
Note: See
TracTickets for help on using
tickets.
implemented label functions and tests, fixed getAttributes() test, which i had screwed by modifying the PHP file last time