Версия:
Description of the Class/CO Profile Itself
Description
Profile settings allow shaping the system’s behavior when interacting with it. These are settings related to both the server side and settings for client components.
Fields of the Class Profile Itself
- name. Must match the key of the object describing this class.
- name_ru. Not necessarily in Russian. This is the title that will be displayed in client tables, and also used in system messages during manipulations with this object (e.g., “User added”).
- primary_key. System field, always
id. - parent_table and parent_key. Used by client components (tables located inside a form or frame). They allow finding the parent form, obtaining the
idof the parent record, and applying a filter to the table data.parent_keyis used either from this field or taken from the field profiles (the field that has theparent_keyflag set).
- server_parent_table and server_parent_key. Define the table’s dependency (direct hierarchy) on other tables. Multiple tables can be specified separated by commas. The number of keys must match the number of tables. Dependency on itself is allowed (e.g.,
d_locationord_storage).- Used to define dependencies during cascading deletion and cache clearing.
- server_parent_key_for_dynamic_fields. Not used.
- checkbox_where, checkbox_where_default_enabled, and checkbox_where_title. Allow displaying a checkbox in the table header, which when activated applies an additional condition to the data (as a JSON array of
IOneWherecondition objects).- For the current date,
NOW_DATEsubstitution is provided (format DD.MM.YYYY). - The initial state of the checkbox and its label can be specified.
- For the current date,
- param_checkbox (and additional fields). Not used.
- ending. Used for inflecting system messages (e.g., for feminine gender “a” in the word “changed” in Russian).
- default_order_by. Default sorting (e.g.,
id desc). - default_where. Default conditions (JSON string with an
IOneWhere[]array). Applied to any request.- Can be canceled on the server by passing
doNotUseDefaultWhere=trueinrParams.
- Can be canceled on the server by passing
- open_form_client_object. Name of the client object (form) that will open from the table’s context menu. Requires the
new_by_modal_commandflag. - child_client_object. Usage status not confirmed.
- rows_max_num_list and rows_max_num. Configuration of the number of rows displayed in the table. Default:
10, 20, 50, 100. - new_command, modify_command, remove_command. Checkboxes that determine the possibility of creating, modifying, and deleting data. Checked on both the client and the server.
- editable. If
false, prohibits any actions with the data by the client (checked on the server). - additional_functionality. Allows connecting a client JS file of the same name to extend the table’s functionality.
- distinct_columns. Names of fields separated by commas to add
DISTINCTto the query. - use_cache. Possibility to disable caching for the class (used for system tables).
- check_company_access. Obsolete/Not implemented (another mechanism is used).
- count_large. Obsolete.
- like_type.
LIKEmode for search (%like,like,like%). Default islike. - hierarchical_table and do_not_set_deep. Determine the table’s hierarchy (self-reference). Fields
node_deep,parents_count,children_countare automatically added.- Methods
getTree,getParentIds,getChildIdsare available.
- Methods
- do_not_use_cache_client. Obsolete.
- child_class. Allows specifying a child class (and CO via a dot) to build a complex hierarchy of several entities in
getTree. - command_get, command_add, command_modify, command_remove. Allow overriding standard commands. In the current version, implemented only for
command_getin forms.