# CentronNexus ServiceBoard Ticket Metadata - Complete Field Analysis

## Document Overview
Comprehensive extraction of ALL ticket metadata fields, properties, and editable fields from the CentronNexus/ServiceBoard codebase. Analysis based on:
- Entity definitions (Helpdesk.cs)
- Data Transfer Objects (HelpdeskDTO, HelpdeskPreviewDTO, TicketTagDTO)
- UI Component rendering (TicketDetailsPage.razor)
- Service update methods (ICentronService, UpdateHelpdeskWebServiceBL)
- Change tracking properties (UpdatedTicketProperties)

## PRIMARY METADATA FIELDS

### Ticket Identity & Numbers
- **Number** | Type: int | Editable: No | Required: Yes | Display identifier for the ticket
- **ShortDescription** | Type: string | Editable: Yes | Required: Yes | Brief title/subject
- **I3D** | Type: int | Editable: No | Required: Yes | Primary key (auto-generated IDENTITY)

### Ticket Core Status Information
- **HelpdeskStatusI3D** | Type: int? | Editable: Yes | Required: No | Reference to status enum
- **HelpdeskStatusCaption** | Type: string | Editable: No | Required: No | Display name of status
- **HelpdeskState** (Entity) | Type: HelpdeskState | Editable: Yes | Required: No | Full status object
- **HelpdeskMarked** | Type: bool | Editable: Yes | Required: No | Flag/marking indicator
- **IsOnlyInternalVisible** | Type: bool | Editable: Yes | Required: No | Internal-only visibility flag

### Ticket Type & Priority
- **HelpdeskTypeI3D** | Type: int? | Editable: Yes | Required: No | Reference to ticket type
- **HelpdeskTypeCaption** | Type: string | Editable: No | Required: No | Display name of type
- **HelpdeskType** (Entity) | Type: HelpdeskType | Editable: Yes | Required: No | Full type object
- **HelpdeskPriorityI3D** | Type: int? | Editable: Yes | Required: No | Reference to priority
- **HelpdeskPriorityCaption** | Type: string | Editable: No | Required: No | Display name of priority
- **HelpdeskPriority** (Entity) | Type: HelpdeskPriority | Editable: Yes | Required: No | Full priority object
- **OutlookPriority** | Type: int | Editable: No | Required: No | Outlook integration priority

### Descriptions & Notes
- **Description** | Type: string | Editable: Yes | Required: No | Full ticket description/body
- **InternalNote** | Type: string | Editable: Yes | Required: No | Internal notes (not visible to customer)
- **FreeText1** | Type: string | Editable: No | Required: No | Additional free text field

## SECONDARY METADATA FIELDS

### Categories
- **MainCategoryI3D** | Type: int? | Editable: No (Read-only) | Required: No | Primary category reference
- **MainCategoryCaption** | Type: string | Editable: No | Required: No | Primary category name
- **MainCategory** (Entity) | Type: HelpdeskCategory | Editable: No | Required: No | Full category object
- **SubCategory1I3D** | Type: int? | Editable: No | Required: No | Sub-category 1 reference
- **SubCategory1Caption** | Type: string | Editable: No | Required: No | Sub-category 1 name
- **SubCategory1** (Entity) | Type: HelpdeskCategory | Editable: No | Required: No | Full sub-category 1 object
- **SubCategory2I3D** | Type: int? | Editable: No | Required: No | Sub-category 2 reference
- **SubCategory2Caption** | Type: string | Editable: No | Required: No | Sub-category 2 name
- **SubCategory2** (Entity) | Type: HelpdeskCategory | Editable: No | Required: No | Full sub-category 2 object

### Responsible Parties
- **ResponsiblePersonI3D** (DTO) | Type: int? | Editable: Yes | Required: No | ID of responsible employee
- **ResponsiblePerson** (Entity) | Type: EmployeeCompact | Editable: Yes | Required: No | Full employee object
- **Editors** | Type: List<HelpdeskEditor> | Editable: Yes | Required: Yes (min 1) | List of ticket editors/processors
- **CreatedByI3D** (Standard) | Type: int | Editable: No | Required: Yes | ID of creator
- **CreatedBy** | Type: EmployeePreviewDTO | Editable: No | Required: Yes | Creator information

### Dates & Timings
- **DueDate** | Type: DateTime? | Editable: Yes | Required: No | Deadline for ticket
- **CreatedDate** | Type: DateTime? | Editable: No | Required: Yes | Creation timestamp
- **ChangedDate** | Type: DateTime? | Editable: No | Required: Yes | Last modification timestamp
- **ClosedDate** | Type: DateTime? | Editable: No | Required: No | Date ticket was closed
- **ClosedAt** (Entity) | Type: DateTime? | Editable: No | Required: No | Closure timestamp
- **WorkStartDate** (Entity) | Type: DateTime? | Editable: Yes | Required: No | Work start date (internal)
- **WorkEndDate** (Entity) | Type: DateTime? | Editable: Yes | Required: No | Work end date (internal)
- **EditStartDate** | Type: DateTime? | Editable: Yes | Required: No | Editing start date (UI property)
- **EditEndDate** | Type: DateTime? | Editable: Yes | Required: No | Editing end date (UI property)
- **LastCommentDate** | Type: DateTime? | Editable: No | Required: No | Date of last comment
- **LastEmailDate** | Type: DateTime? | Editable: No | Required: No | Date of last email

### Time & Duration Tracking
- **PlannedDurationInHours** | Type: float? | Editable: Yes | Required: No | Estimated hours needed
- **TotalTimer** | Type: int | Editable: No | Required: No | Total recorded time (seconds)
- **CalculableTimesInSeconds** | Type: int | Editable: No | Required: No | Billable time
- **NotCalculableTimesInSeconds** | Type: int | Editable: No | Required: No | Non-billable time
- **PlannedTimesInSeconds** | Type: int | Editable: No | Required: No | Planned time
- **CalculableNotPlannedTimesInSeconds** | Type: int | Editable: No | Required: No | Billable unplanned time
- **NotCalculableNotPlannedTimesInSeconds** | Type: int | Editable: No | Required: No | Non-billable unplanned time
- **NotBilledCalculableNotPlannedTimesInSeconds** | Type: int | Editable: No | Required: No | Unbilled billable unplanned
- **BilledCalculableNotPlannedTimesInSeconds** | Type: int | Editable: No | Required: No | Billed billable unplanned
- **CalcuableTimersCount** | Type: int | Editable: No | Required: No | Count of billable timers
- **TimersCount** | Type: int | Editable: No | Required: No | Total timer count
- **HistoryCount** | Type: int | Editable: No | Required: No | Number of history entries

### Customer Related
- **CustomerI3D** | Type: int | Editable: No | Required: Yes | Customer reference ID
- **CustomerName** | Type: string | Editable: No | Required: No | Customer display name
- **CustomerStreet** | Type: string | Editable: No | Required: No | Customer address street
- **CustomerZip** | Type: string | Editable: No | Required: No | Customer postal code
- **CustomerCity** | Type: string | Editable: No | Required: No | Customer city
- **CustomerPostCode** (Entity) | Type: string | Editable: No | Required: No | Postal code
- **Customer** (Entity) | Type: CustomerCompact | Editable: No | Required: Yes | Full customer object
- **CustomerAdviser1** | Type: string | Editable: No | Required: No | Customer adviser 1
- **CustomerAdviser2** | Type: string | Editable: No | Required: No | Customer adviser 2
- **CustomerAdviser3** | Type: string | Editable: No | Required: No | Customer adviser 3
- **CustomerAdviser4** | Type: string | Editable: No | Required: No | Customer adviser 4
- **CustomerOrderProcessingContractState** | Type: OrderProcessingContractState? | Editable: No | Required: No | DSGVO contract state

### Contact Information
- **ContactPersonI3D** (DTO) | Type: int? | Editable: Yes | Required: No | Contact person reference
- **ContactPerson** (Entity) | Type: ContactPerson | Editable: Yes | Required: No | Full contact person object
- **AddressI3D** | Type: int? | Editable: Yes | Required: No | Associated address reference
- **Address** (Entity) | Type: Address | Editable: Yes | Required: No | Full address object
- **AdressContactI3D** (DTO) | Type: int? | Editable: Yes | Required: No | Address contact reference (note: spelling variant)
- **ContactTitle** | Type: string | Editable: No | Required: No | Contact title/salutation
- **ContactName** | Type: string | Editable: No | Required: No | Contact person name
- **ContactEmail** | Type: string | Editable: No | Required: No | Contact email address
- **ContactEMail** (Entity) | Type: string | Editable: No | Required: No | Contact email (variant)
- **CustomerEMail** (Entity) | Type: string | Editable: No | Required: No | Customer email
- **ContactTelephoneNumber** | Type: string | Editable: No | Required: No | Phone number
- **ContactPhone** (Entity) | Type: string | Editable: No | Required: No | Phone (variant)
- **ContactFax** (Entity) | Type: string | Editable: No | Required: No | Fax number

### Contract & Billing
- **ContractId** | Type: int | Editable: Yes | Required: No | Associated contract ID
- **ContractI3D** | Type: int? (in UpdatedContractProperties) | Editable: Yes | Required: No | Contract reference
- **ContractName** | Type: string | Editable: No | Required: No | Contract display name
- **ContractCaption** (DTO) | Type: string | Editable: No | Required: No | Contract caption
- **ContractNumber** | Type: int? | Editable: No | Required: No | Contract number
- **ContractTypeCaption** | Type: string | Editable: No | Required: No | Contract type name
- **IsSlaContract** | Type: bool | Editable: No | Required: No | Whether contract is SLA
- **ArticleWorkItemI3D** | Type: int? | Editable: Yes | Required: No | MSP article/work item reference
- **ArticleWorkItemCaption** | Type: string | Editable: No | Required: No | Work item description
- **IsCalculable** | Type: bool | Editable: No | Required: No | Whether time is billable

### Additional Text Fields
- **Version** | Type: string | Editable: Yes | Required: No | Version/AdditionalText1 field
- **AdditionalText2** | Type: string | Editable: Yes | Required: No | Custom additional field 2
- **ProjectNumber** | Type: string | Editable: Yes | Required: No | CRM project reference number
- **SerialNumber** | Type: string | Editable: No | Required: No | Device serial number

### Tags & Classification
- **TicketTags** | Type: List<TicketTagDTO> | Editable: Yes | Required: No | Associated tags collection
  - **HelpdeskI3D** | Type: int | Part of tag | Ticket reference
  - **TagI3D** | Type: int | Part of tag | Tag ID
  - **Caption** | Type: string | Part of tag | Tag display name

### Device Association
- **ConnectedDeviceNames** | Type: List<string> | Editable: Yes | Required: No | Associated device names/IDs
- **DeviceI3Ds** (UpdatedTicketProperties) | Type: IEnumerable<int>? | Editable: Yes | Required: No | Device IDs in update

## TERTIARY METADATA FIELDS

### System & Integration Fields
- **CreatedFrom** | Type: int | Editable: No | Required: No | Source of creation (0=manual, 1=email, etc.)
- **CreatedFromObjectI3D** | Type: int? | Editable: No | Required: No | Creating object reference
- **CreatedFromObjectKind** | Type: CentronObjectKindNumeric? | Editable: No | Required: No | Type of creating object
- **CreatedFromTicketPatternI3D** | Type: int? | Editable: No | Required: No | Ticket pattern used for creation
- **InFAQ** | Type: int | Editable: No | Required: No | FAQ reference
- **IsTemplate** | Type: int | Editable: No | Required: No | Whether is template
- **TemplateI3D** | Type: int | Editable: No | Required: No | Template reference
- **TemplatePos** | Type: int | Editable: No | Required: No | Position in template
- **OutlookModule** | Type: string | Editable: No | Required: No | Outlook integration module
- **OutlookPriority** | Type: int | Editable: No | Required: No | Outlook priority mapping
- **CentronFingerprint** | Type: string | Editable: No | Required: No | Unique fingerprint

### RMA & Escalation
- **IsRMA** | Type: bool | Editable: No | Required: No | Return Merchandise Authorization
- **RMANumber** | Type: int? | Editable: No | Required: No | RMA number reference
- **IsTicketRefused** | Type: bool? | Editable: No | Required: No | Ticket refusal flag
- **EscalationLevel** | Type: int | Editable: No | Required: No | Escalation tier (0-N)

### Hierarchical Relationships
- **ParentHelpdeskI3D** | Type: int? | Editable: No | Required: No | Parent ticket reference
- **ProjectHelpdeskI3D** | Type: int? | Editable: No | Required: No | Project ticket reference
- **LatestHistoryI3D** | Type: int | Editable: No | Required: No | Most recent history entry ID

### Workflow State
- **CFlowStateI3D** | Type: int? | Editable: No | Required: No | Custom flow state ID

### Solution & Documentation
- **HelpdeskSolution** (Entity) | Type: HelpdeskSolution | Editable: No | Required: No | Solution reference
- **Documentation** | Type: string | Editable: No | Required: No | Documentation content
- **LastAction** | Type: string | Editable: No | Required: No | Description of last action

### Linking & Connections
- **ConnectionNumber** | Type: int | Editable: No (via dialog) | Required: No | Ticket connection number for grouping
- **TodoI3D** | Type: int | Editable: No | Required: No | Associated to-do ID
- **ScanDocI3D** | Type: int | Editable: No | Required: No | Scanned document reference
- **RechPosI3D** | Type: int | Editable: No | Required: No | Receipt position reference
- **LizenzKopfI3D** | Type: int | Editable: No | Required: No | License reference
- **ErrorNumber** | Type: int | Editable: No | Required: No | Error code reference
- **AssetRequest** | Type: int | Editable: No | Required: No | Asset request reference
- **Classification** | Type: int | Editable: No | Required: No | Classification code

### Branch & Organization
- **BranchI3D** | Type: int? | Editable: No | Required: No | Branch/Filiale reference
- **BranchName** | Type: string | Editable: No | Required: No | Branch display name
- **Branch** (Entity) | Type: Branch | Editable: No | Required: No | Full branch object
- **hlpdsk_GruppenI3D** | Type: int | Editable: No | Required: No | Helpdesk group reference

### Locking & Editing
- **LockUser** (Entity) | Type: Employee | Editable: No | Required: No | User editing ticket
- **LockUserName** | Type: string | Editable: No | Required: No | Name of editing user
- **WorkingOnDescriptionI3D** (Component state) | Type: int? | Editable: No | Required: No | Employee currently editing description
- **WorkingOnInternalNoteI3D** (Component state) | Type: int? | Editable: No | Required: No | Employee currently editing internal note

### Display & UI Properties
- **Matchcode** | Type: string | Editable: No | Required: No | Search code
- **Calculated** | Type: bool | Editable: No | Required: No | Whether values calculated
- **IsCalculable** | Type: bool | Editable: No | Required: No | Whether billable
- **LastAction** | Type: string | Editable: No | Required: No | Last action description

### Metadata Fields
- **ContractType** | Type: int | Editable: No | Required: No | Contract type code
- **EditorsSingleLine** | Type: string | Editable: No | Required: No | Editors as single string
- **EditorI3Ds** | Type: string | Editable: No | Required: No | Editor IDs as string

## CALCULATED & READ-ONLY FIELDS

### Automatically Calculated
- **EditStartDate** | Calculated from WorkStartDate | Special handling for year <= 1900
- **EditEndDate** | Calculated from WorkEndDate | Special handling for year <= 1900
- **ContingentValue** | Calculated from contract | Hours or currency based on contract
- **ContingentBooked** | Calculated from contract | Booked contingent amount
- **ContingentUsed** | Calculated from contract | Used contingent amount
- **ContingentReserved** | Calculated from contract | Reserved contingent amount
- **ContingentRest** | Calculated from contract | Remaining contingent
- **ContingentTakeOver** | Calculated from contract | Taken over amount

### Audit Trail
- **ChangedByI3D** (Standard column) | Type: int | Editable: No | Required: Yes | ID of last modifier
- **DeletedByI3D** (Standard column) | Type: int | Editable: No | Required: No | ID of deleting user
- **DeletedDate** (Standard column) | Type: DateTime? | Editable: No | Required: No | Soft delete timestamp
- **IsDeleted** (Standard column) | Type: bit | Editable: No | Required: Yes | Soft delete flag

## UPDATE RETURN PROPERTIES

When updating certain fields, the system returns additional computed properties:

### UpdatedPriorityProperties (returned by HelpdeskUpdatePriority)
- **PriorityI3D** | Type: int?
- **DueDate** | Type: DateTime? (auto-calculated from SLA)

### UpdatedArticleWorkItemProperties (returned by HelpdeskUpdateArticleWorkItem)
- **ArticleWorkItemI3D** | Type: int?
- **MasterDataI3D** | Type: int?
- **ContractI3D** | Type: int? (derived from article work item)
- **PriorityI3D** | Type: int? (derived from article work item)
- **DueDate** | Type: DateTime? (derived from SLA)

### UpdatedContractProperties (returned by HelpdeskUpdateContract)
- **ContractI3D** | Type: int?
- **PriorityI3D** | Type: int? (from contract SLA)
- **DueDate** | Type: DateTime? (from SLA)
- **IsSlaContract** | Type: bool

### UpdatedEditorsProperties (returned by HelpdeskUpdateEditors)
- **HelpdeskStateI3D** | Type: int? (may change based on editors)
- **EditorI3Ds** | Type: List<int>

## FIELD CATEGORIES BY EDITABILITY

### Always Editable (User can change directly)
- ShortDescription
- Description
- InternalNote
- Version
- AdditionalText2
- PlannedDurationInHours
- DueDate
- EditStartDate (WorkStartDate)
- EditEndDate (WorkEndDate)
- HelpdeskMarked
- IsOnlyInternalVisible
- ProjectNumber
- ResponsiblePersonI3D
- Editors (add/remove)
- Tags (add/remove)
- ContractId
- ArticleWorkItemI3D
- StatusI3D (via status update)
- TypeI3D (via type update)
- PriorityI3D (via priority update, may auto-adjust DueDate)
- MainCategoryI3D (via category update)
- AddressI3D (via address update)
- AdressContactI3D (via contact update)
- ConnectionNumber (via connect dialog)
- ConnectedDeviceNames (via device dialog)

### Read-Only (Cannot edit directly, derived/calculated)
- Number
- I3D
- HelpdeskStatusCaption
- HelpdeskTypeCaption
- HelpdeskPriorityCaption
- MainCategoryCaption
- SubCategory1Caption
- SubCategory2Caption
- CustomerName, CustomerStreet, CustomerZip, CustomerCity
- ContactTitle, ContactName, ContactEmail, ContactPhone, ContactFax
- CreatedDate, ChangedDate, ClosedDate, LastCommentDate, LastEmailDate
- TotalTimer, CalculableTimesInSeconds, NotCalculableTimesInSeconds, etc.
- ContractName, ContractNumber, ContractTypeCaption
- ArticleWorkItemCaption
- CreatedBy, LockUser
- HelpdeskStatusCaption, HelpdeskTypeCaption, HelpdeskPriorityCaption
- WorkingOnDescriptionI3D, WorkingOnInternalNoteI3D (realtime only)
- Contingent values (calculated from contract)
- LastAction
- IsCalculable
- HistoryCount, TimersCount, CalcuableTimersCount
- EscalationLevel
- CreatedFrom, CreatedFromObjectI3D, CreatedFromObjectKind
- IsRMA, IsTicketRefused
- Documentation
- OutlookPriority, OutlookModule
- CentronFingerprint
- EditorsSingleLine, EditorI3Ds

## REST API ENDPOINTS FOR UPDATES

All updates use the pattern: `HelpdeskUpdate{FieldName}(UpdateHelpdeskRequest<T>)`

- HelpdeskUpdateAddress(UpdateHelpdeskRequest<int>) -> AddressDTO
- HelpdeskUpdateAddressContact(UpdateHelpdeskRequest<int>) -> AddressContactDTO
- HelpdeskUpdateEditors(UpdateHelpdeskRequest<List<int>>) -> UpdatedEditorsProperties
- HelpdeskUpdateResponsiblePerson(UpdateHelpdeskRequest<int?>) -> int?
- HelpdeskUpdateShortDescription(UpdateHelpdeskRequest<string>) -> string
- HelpdeskUpdateDescription(UpdateHelpdeskRequest<string>) -> string
- HelpdeskUpdateInternalNote(UpdateHelpdeskRequest<string>) -> string
- HelpdeskUpdateHelpdeskMarked(UpdateHelpdeskRequest<bool>) -> bool
- HelpdeskUpdateIsOnlyInternalVisible(UpdateHelpdeskRequest<bool>) -> bool
- HelpdeskUpdateVersion(UpdateHelpdeskRequest<string>) -> string
- HelpdeskUpdateAdditionalText2(UpdateHelpdeskRequest<string>) -> string
- HelpdeskUpdateStatus(UpdateHelpdeskRequest<int>) -> int?
- HelpdeskUpdateType(UpdateHelpdeskRequest<int?>) -> int?
- HelpdeskUpdatePriority(UpdateHelpdeskRequest<int?>) -> UpdatedPriorityProperties
- HelpdeskUpdatePlannedDurationInHours(UpdateHelpdeskRequest<float?>) -> float?
- HelpdeskUpdateDueDate(UpdateHelpdeskRequest<DateTime?>) -> DateTime?
- HelpdeskUpdateEditStartDate(UpdateHelpdeskRequest<DateTime?>) -> DateTime?
- HelpdeskUpdateEditEndDate(UpdateHelpdeskRequest<DateTime?>) -> DateTime?
- HelpdeskUpdateCategory(UpdateHelpdeskRequest<int?>) -> int?
- HelpdeskUpdateArticleWorkItem(UpdateHelpdeskRequest<int?>) -> UpdatedArticleWorkItemProperties
- HelpdeskUpdateContract(UpdateHelpdeskRequest<int>) -> UpdatedContractProperties
- HelpdeskUpdateProjectNumber(UpdateHelpdeskRequest<string?>) -> string

## DATA TYPES REFERENCE

- **I3D** (int) - Primary Key, auto-incrementing identity
- **Enum IDs** (int?) - References to lookup tables (Status, Type, Priority, Category)
- **String** - Text fields (descriptions, names, codes)
- **DateTime?** - Date/time fields, nullable
- **float?** - Hours/decimal fields, nullable
- **bool/bit** - Flags
- **List<T>** - Collections (Editors, Tags, DeviceIds)
- **DTO objects** - Full data transfer objects with nested properties
- **Entity objects** - Full ORM entity objects with relationships

## KEY CONSTRAINTS & BUSINESS RULES

1. **Minimum Editors**: At least 1 editor required (cannot remove all)
2. **Status Validation**: Some status transitions may be restricted
3. **Priority Auto-Adjust**: Changing priority or contract may auto-adjust DueDate
4. **Category Read-Only**: Categories cannot be changed directly via UI (displayed read-only)
5. **Soft Delete**: Tickets use soft-delete pattern (IsDeleted flag)
6. **Audit Trail**: All standard columns required (CreatedBy, CreatedDate, ChangedBy, ChangedDate)
7. **Customer Lock**: CustomerI3D cannot be changed after creation
8. **Connection Grouping**: Multiple tickets can share a ConnectionNumber for grouping

## FILE LOCATIONS

- Entity: `/src/backend/Centron.Entities/Entities/CustomerArea/Support/Helpdesk.cs`
- DTO: `/src/webservice/Centron.WebServices.Core/Entities/Sales/Support/HelpdeskPreviewDTO.cs`
- UI: `/src/CentronNexus/ServiceBoard/TicketDetails/TicketDetailsPage.razor`
- Service: `/src/CentronNexus/Shared/Centron/CentronService.cs`
- BL: `/src/backend/Centron.BL/WebServices/Sales/Support/UpdateHelpdeskWebServiceBL.cs`
- Change Tracking: `/src/CentronNexus/Shared/Services/TicketUpdateService.cs`
