hr.activities
Schema: hr
English table: hr.activities
Italian original table: hr.attivita
Description: Activities (tasks/notifications) associated with people, companies and employment relationships.
Overview
- Columns: 18
- Primary key: id
- Outgoing foreign keys: 1
- Incoming foreign keys: 0
- Indexes: 9
Columns
| English column | Italian original column | Type | Null | Default / Generated | Description |
|---|---|---|---|---|---|
id | id | integer | NO | Surrogate primary key. | |
act_activity_id | att_id | integer | NO | Tenant-scoped activity identifier. | |
act_activity_type_id | att_tipatt_id | integer | NO | Reference to the activity type. | |
act_user_id | att_ut_id | character varying(50) | NO | User identifier related to the activity (e.g., creator/assignee). | |
act_employment_relationship_id | att_rap_id | integer | NO | Reference to the employment relationship linked to the activity. | |
act_source_code | att_provenienza | character varying(3) | NO | 3-character code identifying the activity source/origin. | |
act_source_table_id | att_tabella_provenienza_id | integer | NO | Identifier of the originating table/entity for the activity. | |
act_due_on | att_data_scadenza | date | NO | Due date for the activity. | |
act_scheduled_on | att_data_pianificazione | date | NO | Planned/scheduled date for the activity. | |
act_executed_on | att_data_esecuzione | date | NO | Execution/completion date for the activity. | |
act_outcome_code | att_esito | numeric(2,0) | NO | Outcome/status code for the activity. | |
act_notes | att_note | text | NO | Additional notes for the activity. | |
act_is_notified | att_notificata | boolean | NO | Whether the activity has been notified. | |
act_person_id | att_ana_id | integer | NO | Reference to the person associated with the activity. | |
act_company_id | att_az_id | integer | NO | Reference to the company associated with the activity. | |
tenant_id | tenant_id | integer | YES | Tenant identifier. | |
colcustom | colcustom | jsonb | YES | '{}'::jsonb | Custom fields in JSON format. |
_deleted | _deleted | boolean | YES | false | Soft delete flag. |
Relationships
Outgoing foreign keys
| Constraint | Local columns | References | Referenced columns | On update | On delete |
|---|---|---|---|---|---|
fk_activities_tenant_id | tenant_id | cloud.tenants | ten_internal_id | RESTRICT | CASCADE |
Referenced by
No incoming foreign keys found.
Constraints
- Primary key:
pk_activities→id - Unique:
uk_act_tenant_activity_id→act_activity_id, tenant_id
Indexes
| Name | Unique | Method | Columns / expression |
|---|---|---|---|
idx_act_tenant | NO | btree | tenant_id |
idx_act_tenant_activity_id | NO | btree | tenant_id, act_activity_id) WHERE (_deleted = false |
idx_act_tenant_activity_type | NO | btree | tenant_id, act_activity_type_id) WHERE (_deleted = false |
idx_act_tenant_company | NO | btree | tenant_id, act_company_id) WHERE (_deleted = false |
idx_act_tenant_due_on | NO | btree | tenant_id, act_due_on) WHERE (_deleted = false |
idx_act_tenant_employment_rel | NO | btree | tenant_id, act_employment_relationship_id) WHERE (_deleted = false |
idx_act_tenant_person | NO | btree | tenant_id, act_person_id) WHERE (_deleted = false |
idx_act_tenant_source_table | NO | btree | tenant_id, act_source_table_id) WHERE (_deleted = false |
idx_act_tenant_user | NO | btree | tenant_id, act_user_id) WHERE (_deleted = false |
Navigation
- Back to main index
- [Back to
hrindex]../)