new (require("nmodule/webEditors/rc/wb/mgr/model/columns/PropertyMgrColumn"))()
- Description:
API Status: Development
MgrColumnsubclass that allows individual property values to be edited
on a component.The column name will correspond directly to the slot name to modify.
- Source:
- Mixes In:
Extends:
Extends
Methods
buildCell(row, dom) → {Promise}
- Description:
Shows a display string of the desired property value of the row's
loaded Complex.
- Source:
- Inherited From:
Parameters:
| Name | Type | Description |
|---|---|---|
row |
module:nmodule/webEditors/rc/wb/table/model/Row | |
dom |
JQuery |
Returns:
resolves when the cell has been built
- Type
- Promise
commit(value, row, paramsopt) → {Promise}
- Description:
Sets/adds the property value on the row's
Componentsubject.
- Source:
Parameters:
| Name | Type | Attributes | Description | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
value |
baja.Value | ||||||||||
row |
module:nmodule/webEditors/rc/wb/table/model/Row | ||||||||||
params |
Object |
<optional> |
Properties
|
Returns:
promise to be resolved when the value has
been set on the backing Component
- Type
- Promise
destroyCell(row, dom) → {Promise|*}
- Description:
Called when the table is destroying the DOM element built for a cell in this column. This
gives aColumnimplementation the chance to clean up any resources that might have been
created during the earlier call to#buildCell, perhaps destroying a widget in the cell,
for example. As with#buildCell, if this completes synchronously and doesn't return a
Promise, the caller must wrap this in a call toPromise.resolve().
- Source:
- Inherited From:
Parameters:
| Name | Type | Description |
|---|---|---|
row |
module:nmodule/webEditors/rc/wb/table/model/Row | |
dom |
JQuery |
Returns:
- Type
- Promise | *
getColumnIcon() → {String}
- Description:
If a
typeparam was given, then return an icon for the given slot on
that type. Otherwise, return null.
- Source:
- Inherited From:
Returns:
- Type
- String
getConfigFor(rows) → {Object}
- Description:
If editing only one row, then the facets used to configure the field
editor will be taken from the component instance in that one row.If editing multiple rows, then the facets will be taken from the
appropriate frozen slot on the column's configured Type, if present.
- Source:
Parameters:
| Name | Type | Description |
|---|---|---|
rows |
Array.<module:nmodule/webEditors/rc/wb/table/model/Row> |
Returns:
config object for fe.makeFor, possibly including
properties derived from slot facets
- Type
- Object
getFlags() → {Number}
- Description:
Get the flags set on this column.
- Source:
- Inherited From:
Returns:
- Type
- Number
getName() → {String}
- Description:
Get the column name or
nullif none was given.
- Source:
- Inherited From:
Returns:
- Type
- String
getValueFor(row) → {baja.Value}
- Description:
Get the value of the Property specified in the constructor from the row's
loaded Complex.If the Complex does not have that Property:
If a
getDefaultValueparam was passed into this column's constructor, the
row's Complex will be passed into the function and the result will be
returned.If a
typeparam was passed into this column's constructor, the value
of the property from the default instance of the given type will be
returned.
- Source:
- Inherited From:
Parameters:
| Name | Type | Description |
|---|---|---|
row |
module:nmodule/webEditors/rc/wb/table/model/Row |
Throws:
-
if the row does not actually have a Complex loaded, or
does not have the specified Property (and type is unknown) - Type
- Error
Returns:
the Property value read from the Complex
- Type
- baja.Value
hasFlags(flags) → {Boolean}
- Description:
Return true if the column has all of the given flags.
- Source:
- Inherited From:
Parameters:
| Name | Type | Description |
|---|---|---|
flags |
Number | flags to check for |
Returns:
- Type
- Boolean
isEditable() → {Boolean}
- Description:
Return true if the column is editable.
- Source:
- Inherited From:
Returns:
- Type
- Boolean
isExportable() → {Boolean}
- Description:
Return true if the column should show up in export operations, e.g. to CSV.
- Source:
- Since:
- Niagara 4.8
- Inherited From:
Returns:
- Type
- Boolean
isHidable() → {Boolean}
- Description:
Return true if the column should available in the table's show/hide context menu.
Defaults to true.
- Source:
- Inherited From:
Returns:
- Type
- Boolean
isReadonly() → {Boolean}
- Description:
Return true if the column is readonly.
- Source:
- Inherited From:
Returns:
- Type
- Boolean
isSortable() → {Boolean}
- Description:
Returns a boolean indicating whether the column should not be sortable via the table headings.
Defaults to true.
- Source:
- Inherited From:
Returns:
- Type
- Boolean
isUnseen() → {Boolean}
- Description:
Return true if the column is unseen.
- Source:
- Inherited From:
Returns:
- Type
- Boolean
mixin(Ctor)
- Description:
Applies
MgrColumnfunctionality to an arbitraryColumnsubclass.
- Source:
- Mixes In:
Parameters:
| Name | Type | Description |
|---|---|---|
Ctor |
function |
setEditable(editable)
- Description:
Set or unset the column's
EDITABLEflag. Emits aflagsChangedevent.
- Source:
- Inherited From:
Parameters:
| Name | Type | Description |
|---|---|---|
editable |
boolean |
setExportable(exportable)
- Description:
Set or unset whether the column should show up in export operations.
- Source:
- Since:
- Niagara 4.8
- Inherited From:
Parameters:
| Name | Type | Description |
|---|---|---|
exportable |
boolean |
setFlags(flags)
- Description:
Set the column's flags.
- Source:
- Inherited From:
Parameters:
| Name | Type | Description |
|---|---|---|
flags |
Number |
Throws:
-
if a non-Number given
- Type
- Error
setHidable(hidable)
- Description:
Set or unset whether the column should be allowed to be hidden or shown by the table's
show/hide context menu.
- Source:
- Inherited From:
Parameters:
| Name | Type | Description |
|---|---|---|
hidable |
boolean |
setReadonly(readonly)
- Description:
Set or unset the column's
READONLYflag. Emits aflagsChangedevent.
- Source:
- Inherited From:
Parameters:
| Name | Type | Description |
|---|---|---|
readonly |
boolean |
setSortable(sortable)
- Description:
Set or unset whether the column should be allowed to be sorted by the table heading.
- Source:
- Inherited From:
Parameters:
| Name | Type | Description |
|---|---|---|
sortable |
boolean |
setUnseen(unseen)
- Description:
Set or unset the column's
UNSEENflag. Emits aflagsChangedevent.
- Source:
- Inherited From:
Parameters:
| Name | Type | Description |
|---|---|---|
unseen |
boolean |
toDisplayName() → {Promise}
- Description:
Resolves the display name of the property slot.
- Source:
- Inherited From:
Returns:
promise to be resolved with the display name
- Type
- Promise