Interface iviewAttribute

structure of the view attribute description

interface iviewAttribute {
    UIdataEl?: object;
    UIdataElType?: IntUIdataElType;
    _enabled?: boolean;
    _hint?: string;
    _readonly?: boolean;
    _tooltip?: string;
    _translation?: string;
    _visible: boolean;
    a?: string;
    buttons?: string[];
    dataAttr: iDataAttribute;
    editable?: string;
    enabled?: string | boolean;
    eval?: string;
    hidden?: boolean;
    icon?: string;
    label?: string | boolean;
    name: string;
    oper?: string;
    order?: string;
    placeholder?: string;
    readonly?: string | boolean;
    right?: string;
    short?: boolean;
    shortcut?: string;
    small?: boolean;
    source?: iobjAttrDataSource;
    strangeEval?: string;
    style?: object;
    type?: iattrDataViewType;
    view?: string;
    visible?: string | boolean;
}

Hierarchy (view full)

Properties

UIdataEl?: object
UIdataElType?: IntUIdataElType

type of the element in the UIdateEl - internal, never loaded

_enabled?: boolean

internal represetnation of the disabled field

_hint?: string
_readonly?: boolean

readonly status calculated from readonly (Note: not calculated for list views, only for detail)

_tooltip?: string
_translation?: string
_visible: boolean

visibility status calculated from visible - use ths value to hide or show columns

a?: string

action that is started by click or self-defined view command

  • When used together with the field in the list, system creates a button that activates operation
  • When used in the detail with the item of the view type, it is used instead of view defition in view. Here can be used any a... command.
    • Link can freely defined and even evaluated by fval. When evaluated by fval, it allow total control over the attributes, but it does not get default attributes!
    • @example: object linked if the tskReminder
    • It can manage readonly settings and e.g. allow to have view item editable even when master object is readonly
    • @example: tskRelTaskUser linked in tskTask
buttons?: string[]
dataAttr: iDataAttribute
editable?: string

command evaluated in order to check if user can edit field. Negation of the readonly. Has lower priority and is disregarded in case that readonly is defined. Do not use both of them

enabled?: string | boolean

Optional attributes says that attributes should be totally ignored and view behaves as as attribute doesn't exists Use when extneding object should ignore some attributes from parent object WARNING: Curently implemented only for listView, detail does not yet supported it

eval?: string

Iptional evaluation string - field can be evaluated before it is placed to the field; Should contain string evaluated with fields from row; supported by list and detail - for detail it make sense with readonly:true or some other type of content ocntrol

hidden?: boolean

user settings to hide the column - used only for list view - user can change this value and value is stored in the browser memory

icon?: string
label?: string | boolean

Optinonal commands about label false - no label is printed string - string to translate (used instead of fieldname) true - does not affects functionality (useless) evaluaated - (=obj.enumVal('x')) --- should return translated value, result is not translated. Remember that obj is empty (nevertheless defined) for new object

name: string
oper?: string

Name of the operation linked with the attribute; used in the list (or lately also detail view attributes) Not supported in detail. User buttons:[] in detail Allowed content is:

  • name of the operation defined in object (e.g. tunEtwas), (for detail not yet implemented)
  • openSelfDetail, openSelfClip, openSelfModalDetail - only list
  • form.object.viewtype....., other operation except form are not allowed - only list
order?: string

Optional order string used to order attributes

placeholder?: string

optional placeholder text in the field Always translated, not evaluated

readonly?: string | boolean

Visible but not editable - used in the json defition file and converted to the _readonly according to the data. Do not use it with the data processing in the view

right?: string

The same as visible

short?: boolean

When true it says the input is for short - up to 5 digits and field could be also short Makes sense only for text-like fields like string and number and listbox

shortcut?: string

Optional shortcut

small?: boolean

Optional attribute source

strangeEval?: string

Optional eval values used for strange object; eval is never used for strange Used only in list table

style?: object

optional style for element See style option for boxElements for more details about the field

__Warning: supported currently only for view, image and some text fields;

  • Explicitly not supported for any object/file picker and event not for markdown editor

Optional view type that describes, how to present value

view?: string

optional atribute that allows specify clip to open. @example: oper:"form.sysUser" view:"sysUser.clip." @example: "view":"form.tskDefUserTask.detail.default(readonly:viewDef=true,location=modalSecond)"

visible?: string | boolean

system setting, that the row is necessary but not visible to allow e.g. keys for detail open - user cannot change this value; do not use the value, but use _visible instead of that