release 2.0 beta 2 (#3757)

* do not traverse into invoice template subdirectories (#3735)
* fix security open api definition
* fix currency can be null, removed fluent interface
* merged release 1.30.3
* allow to pre-fill timesheet metafields via URL
* fix api description
* added test accounts with simpler names and password
* upgrade to Symfony 6.2
* removed FrameworkExtraBundle (by Sensio) and replaced with new native SF annotations
* fixed symfony 6.2 deprecations
* fixed #3768
This commit is contained in:
Kevin Papst
2023-01-18 14:47:48 +01:00
committed by GitHub
parent 6e0500972e
commit 0e91dd886e
141 changed files with 1600 additions and 1415 deletions

View File

@@ -16,7 +16,7 @@ final class ColorChoices extends Constraint
public const COLOR_CHOICES_ERROR = 'ui5hffg-dsfef3-1234-5678-2g8jkfr56d84';
public const COLOR_CHOICES_NAME_ERROR = 'ui5hffg-dsfef3-1234-5679-2g8jkfr56d84';
protected static $errorNames = [
protected const ERROR_NAMES = [
self::COLOR_CHOICES_ERROR => 'COLOR_CHOICES_ERROR',
self::COLOR_CHOICES_NAME_ERROR => 'COLOR_CHOICES_NAME_ERROR',
];

View File

@@ -15,7 +15,7 @@ final class DateTimeFormat extends Constraint
{
public const INVALID_FORMAT = 'kimai-datetime-00';
protected static $errorNames = [
protected const ERROR_NAMES = [
self::INVALID_FORMAT => 'The given value is not a valid datetime format.',
];

View File

@@ -16,7 +16,7 @@ final class HexColor extends Constraint
{
public const HEX_COLOR_ERROR = 'xd5hffg-dsfef3-426a-83d7-2g8jkfr56d84';
protected static $errorNames = [
protected const ERROR_NAMES = [
self::HEX_COLOR_ERROR => 'HEX_COLOR_ERROR',
];

View File

@@ -16,7 +16,7 @@ final class Project extends Constraint
{
public const END_BEFORE_BEGIN_ERROR = 'kimai-project-00';
protected static $errorNames = [
protected const ERROR_NAMES = [
self::END_BEFORE_BEGIN_ERROR => 'End date must not be earlier then start date.',
];

View File

@@ -16,7 +16,7 @@ final class Role extends Constraint
{
public const ROLE_ERROR = 'xd5hffg-dsfef3-426a-83d7-1f2d33hs5d84';
protected static $errorNames = [
protected const ERROR_NAMES = [
self::ROLE_ERROR => 'ROLE_ERROR',
];

View File

@@ -16,7 +16,7 @@ final class RoleName extends Constraint
{
public const ROLE_NAME_ERROR = 'xd5hffg-dsfef3-426a-83d7-1f2d33hs5d85';
protected static $errorNames = [
protected const ERROR_NAMES = [
self::ROLE_NAME_ERROR => 'ROLE_NAME_ERROR',
];

View File

@@ -16,7 +16,7 @@ final class Team extends Constraint
{
public const MISSING_TEAMLEAD = 'kimai-team-001';
protected static $errorNames = [
protected const ERROR_NAMES = [
self::MISSING_TEAMLEAD => 'At least one team leader must be assigned to the team.',
];

View File

@@ -15,7 +15,7 @@ final class TimeFormat extends Constraint
{
public const INVALID_FORMAT = 'kimai-time-00';
protected static $errorNames = [
protected const ERROR_NAMES = [
self::INVALID_FORMAT => 'The given value is not a valid time.',
];

View File

@@ -23,7 +23,7 @@ final class TimesheetBasic extends TimesheetConstraint
public const PROJECT_ALREADY_ENDED = 'kimai-timesheet-92';
public const PROJECT_DISALLOWS_GLOBAL_ACTIVITY = 'kimai-timesheet-93';
protected static $errorNames = [
protected const ERROR_NAMES = [
self::MISSING_BEGIN_ERROR => 'You must submit a begin date.',
self::END_BEFORE_BEGIN_ERROR => 'End date must not be earlier then start date.',
self::MISSING_ACTIVITY_ERROR => 'An activity needs to be selected.',

View File

@@ -13,7 +13,7 @@ final class TimesheetExported extends TimesheetConstraint
{
public const TIMESHEET_EXPORTED = 'kimai-timesheet-exported-01';
protected static $errorNames = [
protected const ERROR_NAMES = [
self::TIMESHEET_EXPORTED => 'This timesheet is already exported.',
];

View File

@@ -10,7 +10,7 @@
namespace App\Validator\Constraints;
use App\Entity\Timesheet as TimesheetEntity;
use Symfony\Component\Security\Core\Security;
use Symfony\Bundle\SecurityBundle\Security;
use Symfony\Component\Validator\Constraint;
use Symfony\Component\Validator\ConstraintValidator;
use Symfony\Component\Validator\Exception\UnexpectedTypeException;

View File

@@ -13,7 +13,7 @@ final class TimesheetFutureTimes extends TimesheetConstraint
{
public const BEGIN_IN_FUTURE_ERROR = 'kimai-timesheet-future-times-01';
protected static $errorNames = [
protected const ERROR_NAMES = [
self::BEGIN_IN_FUTURE_ERROR => 'The begin date cannot be in the future.',
];

View File

@@ -13,7 +13,7 @@ final class TimesheetLockdown extends TimesheetConstraint
{
public const PERIOD_LOCKED = 'kimai-timesheet-lockdown-01';
protected static $errorNames = [
protected const ERROR_NAMES = [
self::PERIOD_LOCKED => 'This period is locked, please choose a later date.',
];

View File

@@ -11,7 +11,7 @@ namespace App\Validator\Constraints;
use App\Entity\Timesheet as TimesheetEntity;
use App\Timesheet\LockdownService;
use Symfony\Component\Security\Core\Security;
use Symfony\Bundle\SecurityBundle\Security;
use Symfony\Component\Validator\Constraint;
use Symfony\Component\Validator\ConstraintValidator;
use Symfony\Component\Validator\Exception\UnexpectedTypeException;

View File

@@ -14,7 +14,7 @@ final class TimesheetLongRunning extends TimesheetConstraint
public const LONG_RUNNING = 'kimai-timesheet-long-running-01';
public const MAXIMUM = 'kimai-timesheet-long-running-02';
protected static $errorNames = [
protected const ERROR_NAMES = [
self::LONG_RUNNING => 'TIMESHEET_LONG_RUNNING',
self::MAXIMUM => 'MAXIMUM',
];

View File

@@ -22,7 +22,7 @@ final class TimesheetMultiUpdate extends Constraint
public const DISABLED_CUSTOMER_ERROR = 'ts-multi-update-89';
public const HOURLY_RATE_FIXED_RATE = 'ts-multi-update-90';
protected static $errorNames = [
protected const ERROR_NAMES = [
self::MISSING_ACTIVITY_ERROR => 'You need to choose an activity, if the project should be changed.',
self::MISSING_PROJECT_ERROR => 'A project needs to be selected.',
self::ACTIVITY_PROJECT_MISMATCH_ERROR => 'Project mismatch: chosen project does not match the activity project.',

View File

@@ -16,7 +16,7 @@ final class TimesheetMultiUser extends Constraint
{
public const MISSING_USER_OR_TEAM = 'ts-multi-user-01';
protected static $errorNames = [
protected const ERROR_NAMES = [
self::MISSING_USER_OR_TEAM => 'You must select at least one user or team.',
];

View File

@@ -13,7 +13,7 @@ final class TimesheetOverlapping extends TimesheetConstraint
{
public const RECORD_OVERLAPPING = 'kimai-timesheet-overlapping-01';
protected static $errorNames = [
protected const ERROR_NAMES = [
self::RECORD_OVERLAPPING => 'You already have an entry for this time.',
];

View File

@@ -13,7 +13,7 @@ final class TimesheetRestart extends TimesheetConstraint
{
public const START_DISALLOWED = 'kimai-timesheet-restart-01';
protected static $errorNames = [
protected const ERROR_NAMES = [
self::START_DISALLOWED => 'You are not allowed to start this timesheet record.',
];

View File

@@ -11,7 +11,7 @@ namespace App\Validator\Constraints;
use App\Entity\Timesheet as TimesheetEntity;
use App\Timesheet\TrackingModeService;
use Symfony\Component\Security\Core\Security;
use Symfony\Bundle\SecurityBundle\Security;
use Symfony\Component\Validator\Constraint;
use Symfony\Component\Validator\ConstraintValidator;
use Symfony\Component\Validator\Exception\UnexpectedTypeException;

View File

@@ -13,7 +13,7 @@ final class TimesheetZeroDuration extends TimesheetConstraint
{
public const ZERO_DURATION_ERROR = 'kimai-timesheet-zero-duration-01';
protected static $errorNames = [
protected const ERROR_NAMES = [
self::ZERO_DURATION_ERROR => 'Duration cannot be zero.',
];

View File

@@ -19,7 +19,7 @@ final class User extends Constraint
public const USER_EXISTING_EMAIL_AS_NAME = 'kimai-user-02';
public const USER_EXISTING_NAME_AS_EMAIL = 'kimai-user-03';
protected static $errorNames = [
protected const ERROR_NAMES = [
self::USER_EXISTING_EMAIL => 'The email is already used.',
self::USER_EXISTING_NAME => 'The username is already used.',
self::USER_EXISTING_EMAIL_AS_NAME => 'An equal username is already used.',