chore: Update copyright year from 2025 to 2026 across core files

- Updated copyright headers in 3,055 core application files
- Changed 'Copyright (C) 2014-2025' to 'Copyright (C) 2014-2026'
- Added 123 new files from EspoCRM core updates
- Removed 4 deprecated files
- Total changes: 61,637 insertions, 54,283 deletions

This is a routine maintenance update for the new year 2026.
This commit is contained in:
2026-02-07 16:05:21 +01:00
parent 6a8a4a2882
commit 127fa6503b
6468 changed files with 564781 additions and 31179 deletions

View File

@@ -3,7 +3,7 @@
* This file is part of EspoCRM.
*
* EspoCRM Open Source CRM application.
* Copyright (C) 2014-2025 EspoCRM, Inc.
* Copyright (C) 2014-2026 EspoCRM, Inc.
* Website: https://www.espocrm.com
*
* This program is free software: you can redistribute it and/or modify
@@ -29,6 +29,8 @@
namespace Espo\Tools\Kanban;
use Espo\Core\Exceptions\Error;
use Espo\Core\Exceptions\ForbiddenSilent;
use Espo\Core\Utils\Id\RecordIdGenerator;
use Espo\Entities\KanbanOrder;
use Espo\Core\ORM\EntityManager;
@@ -50,7 +52,8 @@ class OrdererProcessor
public function __construct(
private EntityManager $entityManager,
private Metadata $metadata,
private RecordIdGenerator $idGenerator
private RecordIdGenerator $idGenerator,
private MetadataProvider $metadataProvider,
) {}
public function setEntityType(string $entityType): self
@@ -89,6 +92,9 @@ class OrdererProcessor
/**
* @param string[] $ids
*
* @throws ForbiddenSilent
* @throws Error
*/
public function order(array $ids): void
{
@@ -194,21 +200,25 @@ class OrdererProcessor
->commit();
}
/**
* @throws Error
* @throws ForbiddenSilent
*/
private function validate(): void
{
if (! $this->entityType) {
if (!$this->entityType) {
throw new LogicException("No entity type.");
}
if (! $this->group) {
if (!$this->group) {
throw new LogicException("No group.");
}
if (! $this->userId) {
if (!$this->userId) {
throw new LogicException("No user ID.");
}
if (! $this->metadata->get(['scopes', $this->entityType, 'object'])) {
if (!$this->metadata->get(['scopes', $this->entityType, 'object'])) {
throw new LogicException("Not allowed entity type.");
}
@@ -218,17 +228,16 @@ class OrdererProcessor
throw new LogicException("Order is disabled.");
}
$statusField = $this->metadata->get(['scopes', $this->entityType, 'statusField']);
$statusField = $this->metadataProvider->getStatusField($this->entityType);
if (! $statusField) {
if (!$statusField) {
throw new LogicException("Not status field.");
}
$statusList = $this->metadata
->get(['entityDefs', $this->entityType, 'fields', $statusField, 'options']) ?? [];
$statusList = $this->metadataProvider->getStatusList($this->entityType);
if (!in_array($this->group, $statusList)) {
throw new LogicException("Group is not available in status list.");
throw new ForbiddenSilent("Group is not available in status list.");
}
}
}