new (require("nmodule/webEditors/rc/wb/mgr/model/columns/IconMgrColumn"))()
API Status: Development
Subclass of the IconColumn
type, for displaying an icon in a manager
table.
Extends:
Methods
-
buildCell(row, dom)
-
Build the dom for the cell. This overrides the buildCell() function
provided by MgrColumn to directly call the base class, which will
build a field editor for the icon.Parameters:
Name Type Description row
module:nmodule/webEditors/rc/wb/table/model/Row dom
JQuery Returns:
A promise resolved with the img element added to the dom.
- Type
- Promise
-
destroyCell(row, dom)
-
Destroy the IconEditor that was created for this cell.
Parameters:
Name Type Description row
module:nmodule/webEditors/rc/wb/table/model/Row dom
JQuery Returns:
- Type
- Promise
-
getColumnIcon()
-
Returns a URI for an icon representing this column. Returns
null
by
default; override as needed in subclasses.- Inherited From:
Returns:
a URI for an icon to be shown for this column.
- Type
- String
-
getFlags()
-
Get the flags set on this column.
- Inherited From:
Returns:
- Type
- Number
-
getName()
-
Get the column name or
null
if none was given.- Inherited From:
Returns:
- Type
- String
-
getValueFor(row)
-
Get the icon for the row. If a type column has a new selected type
that has not been committed yet, this will return the icon for the
new type, assuming the row has an icon defined. If the row has no
icon, a new type's icon will not be considered.Parameters:
Name Type Description row
module:nmodule/webEditors/rc/wb/table/model/Row Returns:
- Type
- baja.Icon
-
hasFlags(flags)
-
Return true if the column has all of the given flags.
Parameters:
Name Type Description flags
Number flags to check for
- Inherited From:
Returns:
- Type
- Boolean
-
isEditable()
-
Return true if the column is editable.
- Inherited From:
Returns:
- Type
- Boolean
-
isHidable()
-
Return true if the column should available in the table's show/hide context menu.
Defaults to true.- Inherited From:
Returns:
- Type
- Boolean
-
isReadonly()
-
Return true if the column is readonly.
- Inherited From:
Returns:
- Type
- Boolean
-
isSortable()
-
Returns a boolean indicating whether the column should not be sortable via the table headings.
Defaults to true.- Inherited From:
Returns:
- Type
- Boolean
-
isUnseen()
-
Return true if the column is unseen.
- Inherited From:
Returns:
- Type
- Boolean
-
setEditable(editable)
-
Set or unset the column's
EDITABLE
flag. Emits aflagsChanged
event.Parameters:
Name Type Description editable
boolean - Inherited From:
-
setFlags(flags)
-
Set the column's flags.
Parameters:
Name Type Description flags
Number - Inherited From:
Throws:
-
if a non-Number given
- Type
- Error
-
setHidable(hidable)
-
Set or unset whether the column should be allowed to be hidden or shown by the table's
show/hide context menu.Parameters:
Name Type Description hidable
boolean - Inherited From:
-
setReadonly(readonly)
-
Set or unset the column's
READONLY
flag. Emits aflagsChanged
event.Parameters:
Name Type Description readonly
boolean - Inherited From:
-
setSortable(sortable)
-
Set or unset whether the column should be allowed to be sorted by the table heading.
Parameters:
Name Type Description sortable
boolean - Inherited From:
-
setUnseen(unseen)
-
Set or unset the column's
UNSEEN
flag. Emits aflagsChanged
event.Parameters:
Name Type Description unseen
boolean - Inherited From:
-
toDisplayName()
-
Resolves a display name for this column.
- Inherited From:
Returns:
promise to be resolved when the element's display name
has been fully built. It's also acceptable for overrides of this function
to complete synchronously without returning a promise, so be sure to wrap
calls to this function inPromise.resolve()
when appropriate.- Type
- Promise | *