mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-06-20 17:15:51 +02:00
Forbid users to select dates after 2038 on 32-bit systems to prevent errors caused by Year2038 bug
See discussion #548 and #549
This commit is contained in:
parent
18c697f472
commit
206bcebdb7
8 changed files with 167 additions and 36 deletions
|
@ -25,7 +25,7 @@
|
||||||
CustomLog ${APACHE_LOG_DIR}/access.log combined
|
CustomLog ${APACHE_LOG_DIR}/access.log combined
|
||||||
|
|
||||||
# Pass the configuration from the docker env to the PHP environment (here you should list all .env options)
|
# Pass the configuration from the docker env to the PHP environment (here you should list all .env options)
|
||||||
PassEnv APP_ENV APP_DEBUG APP_SECRET REDIRECT_TO_HTTPS
|
PassEnv APP_ENV APP_DEBUG APP_SECRET REDIRECT_TO_HTTPS DISABLE_YEAR2038_BUG_CHECK
|
||||||
PassEnv TRUSTED_PROXIES TRUSTED_HOSTS LOCK_DSN
|
PassEnv TRUSTED_PROXIES TRUSTED_HOSTS LOCK_DSN
|
||||||
PassEnv DATABASE_URL ENFORCE_CHANGE_COMMENTS_FOR DATABASE_MYSQL_USE_SSL_CA DATABASE_MYSQL_SSL_VERIFY_CERT
|
PassEnv DATABASE_URL ENFORCE_CHANGE_COMMENTS_FOR DATABASE_MYSQL_USE_SSL_CA DATABASE_MYSQL_SSL_VERIFY_CERT
|
||||||
PassEnv DEFAULT_LANG DEFAULT_TIMEZONE BASE_CURRENCY INSTANCE_NAME ALLOW_ATTACHMENT_DOWNLOADS USE_GRAVATAR MAX_ATTACHMENT_FILE_SIZE DEFAULT_URI CHECK_FOR_UPDATES ATTACHMENT_DOWNLOAD_BY_DEFAULT
|
PassEnv DEFAULT_LANG DEFAULT_TIMEZONE BASE_CURRENCY INSTANCE_NAME ALLOW_ATTACHMENT_DOWNLOADS USE_GRAVATAR MAX_ATTACHMENT_FILE_SIZE DEFAULT_URI CHECK_FOR_UPDATES ATTACHMENT_DOWNLOAD_BY_DEFAULT
|
||||||
|
|
2
.env
2
.env
|
@ -248,6 +248,8 @@ BANNER=""
|
||||||
APP_ENV=prod
|
APP_ENV=prod
|
||||||
APP_SECRET=a03498528f5a5fc089273ec9ae5b2849
|
APP_SECRET=a03498528f5a5fc089273ec9ae5b2849
|
||||||
|
|
||||||
|
# Set this to zero, if you want to disable the year 2038 bug check on 32-bit systems (it will cause errors with current 32-bit PHP versions)
|
||||||
|
DISABLE_YEAR2038_BUG_CHECK=0
|
||||||
|
|
||||||
# Set the trusted IPs here, when using an reverse proxy
|
# Set the trusted IPs here, when using an reverse proxy
|
||||||
#TRUSTED_PROXIES=127.0.0.0/8,::1,10.0.0.0/8,172.16.0.0/12,192.168.0.0/16
|
#TRUSTED_PROXIES=127.0.0.0/8,::1,10.0.0.0/8,172.16.0.0/12,192.168.0.0/16
|
||||||
|
|
|
@ -206,6 +206,10 @@ See the [information providers]({% link usage/information_provider_system.md %})
|
||||||
mode. (**You should not do this on a publicly accessible server, as it will leak sensitive information!**)
|
mode. (**You should not do this on a publicly accessible server, as it will leak sensitive information!**)
|
||||||
* `BANNER`: You can configure the text that should be shown as the banner on the homepage. Useful especially for docker
|
* `BANNER`: You can configure the text that should be shown as the banner on the homepage. Useful especially for docker
|
||||||
containers. In all other applications you can just change the `config/banner.md` file.
|
containers. In all other applications you can just change the `config/banner.md` file.
|
||||||
|
* `DISABLE_YEAR2038_BUG_CHECK`: If set to `1`, the year 2038 bug check is disabled on 32-bit systems, and dates after
|
||||||
|
2038 are no longer forbidden. However this will lead to 500 error messages when rendering dates after 2038 as all current
|
||||||
|
32-bit PHP versions can not format these dates correctly. This setting is for the case that future PHP versions will
|
||||||
|
handle this correctly on 32-bit systems. 64-bit systems are not affected by this bug, and the check is always disabled.
|
||||||
|
|
||||||
## Banner
|
## Banner
|
||||||
|
|
||||||
|
|
|
@ -37,6 +37,7 @@ use ApiPlatform\Metadata\Patch;
|
||||||
use ApiPlatform\Metadata\Post;
|
use ApiPlatform\Metadata\Post;
|
||||||
use ApiPlatform\Serializer\Filter\PropertyFilter;
|
use ApiPlatform\Serializer\Filter\PropertyFilter;
|
||||||
use App\ApiPlatform\Filter\LikeFilter;
|
use App\ApiPlatform\Filter\LikeFilter;
|
||||||
|
use App\Validator\Constraints\Year2038BugWorkaround;
|
||||||
use Doctrine\DBAL\Types\Types;
|
use Doctrine\DBAL\Types\Types;
|
||||||
use App\Entity\Base\AbstractDBElement;
|
use App\Entity\Base\AbstractDBElement;
|
||||||
use App\Entity\Base\TimestampTrait;
|
use App\Entity\Base\TimestampTrait;
|
||||||
|
@ -109,6 +110,7 @@ class PartLot extends AbstractDBElement implements TimeStampableInterface, Named
|
||||||
*/
|
*/
|
||||||
#[Groups(['extended', 'full', 'import', 'part_lot:read', 'part_lot:write'])]
|
#[Groups(['extended', 'full', 'import', 'part_lot:read', 'part_lot:write'])]
|
||||||
#[ORM\Column(name: 'expiration_date', type: Types::DATETIME_MUTABLE, nullable: true)]
|
#[ORM\Column(name: 'expiration_date', type: Types::DATETIME_MUTABLE, nullable: true)]
|
||||||
|
#[Year2038BugWorkaround]
|
||||||
protected ?\DateTimeInterface $expiration_date = null;
|
protected ?\DateTimeInterface $expiration_date = null;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -32,6 +32,7 @@ use App\Entity\Base\TimestampTrait;
|
||||||
use App\Entity\Contracts\TimeStampableInterface;
|
use App\Entity\Contracts\TimeStampableInterface;
|
||||||
use App\Repository\UserSystem\ApiTokenRepository;
|
use App\Repository\UserSystem\ApiTokenRepository;
|
||||||
use App\State\CurrentApiTokenProvider;
|
use App\State\CurrentApiTokenProvider;
|
||||||
|
use App\Validator\Constraints\Year2038BugWorkaround;
|
||||||
use Doctrine\DBAL\Types\Types;
|
use Doctrine\DBAL\Types\Types;
|
||||||
use Doctrine\ORM\Mapping as ORM;
|
use Doctrine\ORM\Mapping as ORM;
|
||||||
use Symfony\Bridge\Doctrine\Validator\Constraints\UniqueEntity;
|
use Symfony\Bridge\Doctrine\Validator\Constraints\UniqueEntity;
|
||||||
|
@ -76,6 +77,7 @@ class ApiToken implements TimeStampableInterface
|
||||||
|
|
||||||
#[ORM\Column(type: Types::DATETIME_MUTABLE, nullable: true)]
|
#[ORM\Column(type: Types::DATETIME_MUTABLE, nullable: true)]
|
||||||
#[Groups('token:read')]
|
#[Groups('token:read')]
|
||||||
|
#[Year2038BugWorkaround]
|
||||||
private ?\DateTimeInterface $valid_until;
|
private ?\DateTimeInterface $valid_until;
|
||||||
|
|
||||||
#[ORM\Column(length: 68, unique: true)]
|
#[ORM\Column(length: 68, unique: true)]
|
||||||
|
|
41
src/Validator/Constraints/Year2038BugWorkaround.php
Normal file
41
src/Validator/Constraints/Year2038BugWorkaround.php
Normal file
|
@ -0,0 +1,41 @@
|
||||||
|
<?php
|
||||||
|
/*
|
||||||
|
* This file is part of Part-DB (https://github.com/Part-DB/Part-DB-symfony).
|
||||||
|
*
|
||||||
|
* Copyright (C) 2019 - 2024 Jan Böhmer (https://github.com/jbtronics)
|
||||||
|
*
|
||||||
|
* This program is free software: you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU Affero General Public License as published
|
||||||
|
* by the Free Software Foundation, either version 3 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* This program is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU Affero General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU Affero General Public License
|
||||||
|
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
|
|
||||||
|
declare(strict_types=1);
|
||||||
|
|
||||||
|
|
||||||
|
namespace App\Validator\Constraints;
|
||||||
|
|
||||||
|
use Symfony\Component\Validator\Constraint;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Datetime interfaces properties with this constraint are limited to the year 2038 on 32-bit systems, to prevent a
|
||||||
|
* Year 2038 bug during rendering.
|
||||||
|
*
|
||||||
|
* Current PHP versions can not format dates after 2038 on 32-bit systems and throw an exception.
|
||||||
|
* (See https://github.com/Part-DB/Part-DB-server/discussions/548).
|
||||||
|
*
|
||||||
|
* This constraint does not fix that problem, but can prevent users from entering such invalid dates.
|
||||||
|
*/
|
||||||
|
#[\Attribute(\Attribute::TARGET_PROPERTY)]
|
||||||
|
class Year2038BugWorkaround extends Constraint
|
||||||
|
{
|
||||||
|
public string $message = 'validator.year_2038_bug_on_32bit';
|
||||||
|
}
|
74
src/Validator/Constraints/Year2038BugWorkaroundValidator.php
Normal file
74
src/Validator/Constraints/Year2038BugWorkaroundValidator.php
Normal file
|
@ -0,0 +1,74 @@
|
||||||
|
<?php
|
||||||
|
/*
|
||||||
|
* This file is part of Part-DB (https://github.com/Part-DB/Part-DB-symfony).
|
||||||
|
*
|
||||||
|
* Copyright (C) 2019 - 2024 Jan Böhmer (https://github.com/jbtronics)
|
||||||
|
*
|
||||||
|
* This program is free software: you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU Affero General Public License as published
|
||||||
|
* by the Free Software Foundation, either version 3 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* This program is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU Affero General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU Affero General Public License
|
||||||
|
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
|
|
||||||
|
declare(strict_types=1);
|
||||||
|
|
||||||
|
|
||||||
|
namespace App\Validator\Constraints;
|
||||||
|
|
||||||
|
use Symfony\Component\DependencyInjection\Attribute\Autowire;
|
||||||
|
use Symfony\Component\Validator\Constraint;
|
||||||
|
use Symfony\Component\Validator\ConstraintValidator;
|
||||||
|
use Symfony\Component\Validator\Exception\UnexpectedTypeException;
|
||||||
|
|
||||||
|
class Year2038BugWorkaroundValidator extends ConstraintValidator
|
||||||
|
{
|
||||||
|
|
||||||
|
public function __construct(
|
||||||
|
#[Autowire(env: "DISABLE_YEAR2038_BUG_CHECK")]
|
||||||
|
private readonly bool $disable_validation = false
|
||||||
|
)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
public function isActivated(): bool
|
||||||
|
{
|
||||||
|
//If we are on a 32 bit system and the validation is not disabled, we should activate the validation
|
||||||
|
return !$this->disable_validation && PHP_INT_SIZE === 4;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function validate(mixed $value, Constraint $constraint): void
|
||||||
|
{
|
||||||
|
if (!$this->isActivated()) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
//If the value is null, we don't need to validate it
|
||||||
|
if ($value === null) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
//Ensure that we check the correct constraint
|
||||||
|
if (!$constraint instanceof Year2038BugWorkaround) {
|
||||||
|
throw new \InvalidArgumentException('This validator can only validate Year2038Bug constraints');
|
||||||
|
}
|
||||||
|
|
||||||
|
//We can only validate DateTime objects
|
||||||
|
if (!$value instanceof \DateTimeInterface) {
|
||||||
|
throw new UnexpectedTypeException($value, \DateTimeInterface::class);
|
||||||
|
}
|
||||||
|
|
||||||
|
//If we reach here the validation is active and we should forbid any date after 2038.
|
||||||
|
if ($value->diff(new \DateTime('2038-01-19 03:14:06'))->invert === 1) {
|
||||||
|
$this->context->buildViolation($constraint->message)
|
||||||
|
->addViolation();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -37,7 +37,7 @@
|
||||||
<note priority="1">Part-DB1\src\Entity\UserSystem\Group.php:0</note>
|
<note priority="1">Part-DB1\src\Entity\UserSystem\Group.php:0</note>
|
||||||
<note priority="1">Part-DB1\src\Entity\UserSystem\User.php:0</note>
|
<note priority="1">Part-DB1\src\Entity\UserSystem\User.php:0</note>
|
||||||
</notes>
|
</notes>
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>part.master_attachment.must_be_picture</source>
|
<source>part.master_attachment.must_be_picture</source>
|
||||||
<target>The preview attachment must be a valid picture!</target>
|
<target>The preview attachment must be a valid picture!</target>
|
||||||
</segment>
|
</segment>
|
||||||
|
@ -82,7 +82,7 @@
|
||||||
<note priority="1">src\Entity\StructuralDBElement.php:0</note>
|
<note priority="1">src\Entity\StructuralDBElement.php:0</note>
|
||||||
<note priority="1">src\Entity\Supplier.php:0</note>
|
<note priority="1">src\Entity\Supplier.php:0</note>
|
||||||
</notes>
|
</notes>
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>structural.entity.unique_name</source>
|
<source>structural.entity.unique_name</source>
|
||||||
<target>An element with this name already exists on this level!</target>
|
<target>An element with this name already exists on this level!</target>
|
||||||
</segment>
|
</segment>
|
||||||
|
@ -102,7 +102,7 @@
|
||||||
<note category="file-source" priority="1">Part-DB1\src\Entity\Parameters\StorelocationParameter.php:0</note>
|
<note category="file-source" priority="1">Part-DB1\src\Entity\Parameters\StorelocationParameter.php:0</note>
|
||||||
<note category="file-source" priority="1">Part-DB1\src\Entity\Parameters\SupplierParameter.php:0</note>
|
<note category="file-source" priority="1">Part-DB1\src\Entity\Parameters\SupplierParameter.php:0</note>
|
||||||
</notes>
|
</notes>
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>parameters.validator.min_lesser_typical</source>
|
<source>parameters.validator.min_lesser_typical</source>
|
||||||
<target>Value must be lesser or equal the the typical value ({{ compared_value }}).</target>
|
<target>Value must be lesser or equal the the typical value ({{ compared_value }}).</target>
|
||||||
</segment>
|
</segment>
|
||||||
|
@ -122,7 +122,7 @@
|
||||||
<note category="file-source" priority="1">Part-DB1\src\Entity\Parameters\StorelocationParameter.php:0</note>
|
<note category="file-source" priority="1">Part-DB1\src\Entity\Parameters\StorelocationParameter.php:0</note>
|
||||||
<note category="file-source" priority="1">Part-DB1\src\Entity\Parameters\SupplierParameter.php:0</note>
|
<note category="file-source" priority="1">Part-DB1\src\Entity\Parameters\SupplierParameter.php:0</note>
|
||||||
</notes>
|
</notes>
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>parameters.validator.min_lesser_max</source>
|
<source>parameters.validator.min_lesser_max</source>
|
||||||
<target>Value must be lesser than the maximum value ({{ compared_value }}).</target>
|
<target>Value must be lesser than the maximum value ({{ compared_value }}).</target>
|
||||||
</segment>
|
</segment>
|
||||||
|
@ -142,7 +142,7 @@
|
||||||
<note category="file-source" priority="1">Part-DB1\src\Entity\Parameters\StorelocationParameter.php:0</note>
|
<note category="file-source" priority="1">Part-DB1\src\Entity\Parameters\StorelocationParameter.php:0</note>
|
||||||
<note category="file-source" priority="1">Part-DB1\src\Entity\Parameters\SupplierParameter.php:0</note>
|
<note category="file-source" priority="1">Part-DB1\src\Entity\Parameters\SupplierParameter.php:0</note>
|
||||||
</notes>
|
</notes>
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>parameters.validator.max_greater_typical</source>
|
<source>parameters.validator.max_greater_typical</source>
|
||||||
<target>Value must be greater or equal than the typical value ({{ compared_value }}).</target>
|
<target>Value must be greater or equal than the typical value ({{ compared_value }}).</target>
|
||||||
</segment>
|
</segment>
|
||||||
|
@ -152,7 +152,7 @@
|
||||||
<note category="file-source" priority="1">Part-DB1\src\Entity\UserSystem\User.php:0</note>
|
<note category="file-source" priority="1">Part-DB1\src\Entity\UserSystem\User.php:0</note>
|
||||||
<note priority="1">Part-DB1\src\Entity\UserSystem\User.php:0</note>
|
<note priority="1">Part-DB1\src\Entity\UserSystem\User.php:0</note>
|
||||||
</notes>
|
</notes>
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>validator.user.username_already_used</source>
|
<source>validator.user.username_already_used</source>
|
||||||
<target>A user with this name is already exisiting</target>
|
<target>A user with this name is already exisiting</target>
|
||||||
</segment>
|
</segment>
|
||||||
|
@ -162,7 +162,7 @@
|
||||||
<note category="file-source" priority="1">Part-DB1\src\Entity\UserSystem\User.php:0</note>
|
<note category="file-source" priority="1">Part-DB1\src\Entity\UserSystem\User.php:0</note>
|
||||||
<note priority="1">Part-DB1\src\Entity\UserSystem\User.php:0</note>
|
<note priority="1">Part-DB1\src\Entity\UserSystem\User.php:0</note>
|
||||||
</notes>
|
</notes>
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>user.invalid_username</source>
|
<source>user.invalid_username</source>
|
||||||
<target>The username must contain only letters, numbers, underscores, dots, pluses or minuses!</target>
|
<target>The username must contain only letters, numbers, underscores, dots, pluses or minuses!</target>
|
||||||
</segment>
|
</segment>
|
||||||
|
@ -171,7 +171,7 @@
|
||||||
<notes>
|
<notes>
|
||||||
<note category="state" priority="1">obsolete</note>
|
<note category="state" priority="1">obsolete</note>
|
||||||
</notes>
|
</notes>
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>validator.noneofitschild.self</source>
|
<source>validator.noneofitschild.self</source>
|
||||||
<target>An element can not be its own parent!</target>
|
<target>An element can not be its own parent!</target>
|
||||||
</segment>
|
</segment>
|
||||||
|
@ -180,166 +180,172 @@
|
||||||
<notes>
|
<notes>
|
||||||
<note category="state" priority="1">obsolete</note>
|
<note category="state" priority="1">obsolete</note>
|
||||||
</notes>
|
</notes>
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>validator.noneofitschild.children</source>
|
<source>validator.noneofitschild.children</source>
|
||||||
<target>You can not assign children element as parent (This would cause loops)!</target>
|
<target>You can not assign children element as parent (This would cause loops)!</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
<unit id="ayNr6QK" name="validator.select_valid_category">
|
<unit id="ayNr6QK" name="validator.select_valid_category">
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>validator.select_valid_category</source>
|
<source>validator.select_valid_category</source>
|
||||||
<target>Please select a valid category!</target>
|
<target>Please select a valid category!</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
<unit id="6vIlN5q" name="validator.part_lot.only_existing">
|
<unit id="6vIlN5q" name="validator.part_lot.only_existing">
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>validator.part_lot.only_existing</source>
|
<source>validator.part_lot.only_existing</source>
|
||||||
<target>Can not add new parts to this location as it is marked as "Only Existing"</target>
|
<target>Can not add new parts to this location as it is marked as "Only Existing"</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
<unit id="3xoKOIS" name="validator.part_lot.location_full.no_increase">
|
<unit id="3xoKOIS" name="validator.part_lot.location_full.no_increase">
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>validator.part_lot.location_full.no_increase</source>
|
<source>validator.part_lot.location_full.no_increase</source>
|
||||||
<target>Location is full. Amount can not be increased (new value must be smaller than {{ old_amount }}).</target>
|
<target>Location is full. Amount can not be increased (new value must be smaller than {{ old_amount }}).</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
<unit id="R6Ov4Yt" name="validator.part_lot.location_full">
|
<unit id="R6Ov4Yt" name="validator.part_lot.location_full">
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>validator.part_lot.location_full</source>
|
<source>validator.part_lot.location_full</source>
|
||||||
<target>Location is full. Can not add new parts to it.</target>
|
<target>Location is full. Can not add new parts to it.</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
<unit id="BNQk2e7" name="validator.part_lot.single_part">
|
<unit id="BNQk2e7" name="validator.part_lot.single_part">
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>validator.part_lot.single_part</source>
|
<source>validator.part_lot.single_part</source>
|
||||||
<target>This location can only contain a single part and it is already full!</target>
|
<target>This location can only contain a single part and it is already full!</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
<unit id="4gPskOG" name="validator.attachment.must_not_be_null">
|
<unit id="4gPskOG" name="validator.attachment.must_not_be_null">
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>validator.attachment.must_not_be_null</source>
|
<source>validator.attachment.must_not_be_null</source>
|
||||||
<target>You must select an attachment type!</target>
|
<target>You must select an attachment type!</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
<unit id="cDDVrWT" name="validator.orderdetail.supplier_must_not_be_null">
|
<unit id="cDDVrWT" name="validator.orderdetail.supplier_must_not_be_null">
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>validator.orderdetail.supplier_must_not_be_null</source>
|
<source>validator.orderdetail.supplier_must_not_be_null</source>
|
||||||
<target>You must select an supplier!</target>
|
<target>You must select an supplier!</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
<unit id="k5DDdB4" name="validator.measurement_unit.use_si_prefix_needs_unit">
|
<unit id="k5DDdB4" name="validator.measurement_unit.use_si_prefix_needs_unit">
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>validator.measurement_unit.use_si_prefix_needs_unit</source>
|
<source>validator.measurement_unit.use_si_prefix_needs_unit</source>
|
||||||
<target>To enable SI prefixes, you have to set a unit symbol!</target>
|
<target>To enable SI prefixes, you have to set a unit symbol!</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
<unit id="DuzIOCr" name="part.ipn.must_be_unique">
|
<unit id="DuzIOCr" name="part.ipn.must_be_unique">
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>part.ipn.must_be_unique</source>
|
<source>part.ipn.must_be_unique</source>
|
||||||
<target>The internal part number must be unique. {{ value }} is already in use!</target>
|
<target>The internal part number must be unique. {{ value }} is already in use!</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
<unit id="Z4Kuuo2" name="validator.project.bom_entry.name_or_part_needed">
|
<unit id="Z4Kuuo2" name="validator.project.bom_entry.name_or_part_needed">
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>validator.project.bom_entry.name_or_part_needed</source>
|
<source>validator.project.bom_entry.name_or_part_needed</source>
|
||||||
<target>You have to choose a part for a part BOM entry or set a name for a non-part BOM entry.</target>
|
<target>You have to choose a part for a part BOM entry or set a name for a non-part BOM entry.</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
<unit id="WF_v4ih" name="project.bom_entry.name_already_in_bom">
|
<unit id="WF_v4ih" name="project.bom_entry.name_already_in_bom">
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>project.bom_entry.name_already_in_bom</source>
|
<source>project.bom_entry.name_already_in_bom</source>
|
||||||
<target>There is already an BOM entry with this name!</target>
|
<target>There is already an BOM entry with this name!</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
<unit id="5v4p85H" name="project.bom_entry.part_already_in_bom">
|
<unit id="5v4p85H" name="project.bom_entry.part_already_in_bom">
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>project.bom_entry.part_already_in_bom</source>
|
<source>project.bom_entry.part_already_in_bom</source>
|
||||||
<target>This part already exists in the BOM!</target>
|
<target>This part already exists in the BOM!</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
<unit id="3lM32Tw" name="project.bom_entry.mountnames_quantity_mismatch">
|
<unit id="3lM32Tw" name="project.bom_entry.mountnames_quantity_mismatch">
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>project.bom_entry.mountnames_quantity_mismatch</source>
|
<source>project.bom_entry.mountnames_quantity_mismatch</source>
|
||||||
<target>The number of mountnames has to match the BOMs quantity!</target>
|
<target>The number of mountnames has to match the BOMs quantity!</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
<unit id="x47D5WT" name="project.bom_entry.can_not_add_own_builds_part">
|
<unit id="x47D5WT" name="project.bom_entry.can_not_add_own_builds_part">
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>project.bom_entry.can_not_add_own_builds_part</source>
|
<source>project.bom_entry.can_not_add_own_builds_part</source>
|
||||||
<target>You can not add a project's own builds part to the BOM.</target>
|
<target>You can not add a project's own builds part to the BOM.</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
<unit id="2x2XDI_" name="project.bom_has_to_include_all_subelement_parts">
|
<unit id="2x2XDI_" name="project.bom_has_to_include_all_subelement_parts">
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>project.bom_has_to_include_all_subelement_parts</source>
|
<source>project.bom_has_to_include_all_subelement_parts</source>
|
||||||
<target>The project BOM has to include all subprojects builds parts. Part %part_name% of project %project_name% missing!</target>
|
<target>The project BOM has to include all subprojects builds parts. Part %part_name% of project %project_name% missing!</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
<unit id="U9b1EzD" name="project.bom_entry.price_not_allowed_on_parts">
|
<unit id="U9b1EzD" name="project.bom_entry.price_not_allowed_on_parts">
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>project.bom_entry.price_not_allowed_on_parts</source>
|
<source>project.bom_entry.price_not_allowed_on_parts</source>
|
||||||
<target>Prices are not allowed on BOM entries associated with a part. Define the price on the part instead.</target>
|
<target>Prices are not allowed on BOM entries associated with a part. Define the price on the part instead.</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
<unit id="ID056SR" name="validator.project_build.lot_bigger_than_needed">
|
<unit id="ID056SR" name="validator.project_build.lot_bigger_than_needed">
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>validator.project_build.lot_bigger_than_needed</source>
|
<source>validator.project_build.lot_bigger_than_needed</source>
|
||||||
<target>You have selected more quantity to withdraw than needed! Remove unnecessary quantity.</target>
|
<target>You have selected more quantity to withdraw than needed! Remove unnecessary quantity.</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
<unit id="6hV5UqD" name="validator.project_build.lot_smaller_than_needed">
|
<unit id="6hV5UqD" name="validator.project_build.lot_smaller_than_needed">
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>validator.project_build.lot_smaller_than_needed</source>
|
<source>validator.project_build.lot_smaller_than_needed</source>
|
||||||
<target>You have selected less quantity to withdraw than needed for the build! Add additional quantity.</target>
|
<target>You have selected less quantity to withdraw than needed for the build! Add additional quantity.</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
<unit id="G9ZKt.4" name="part.name.must_match_category_regex">
|
<unit id="G9ZKt.4" name="part.name.must_match_category_regex">
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>part.name.must_match_category_regex</source>
|
<source>part.name.must_match_category_regex</source>
|
||||||
<target>The part name does not match the regular expression stated by the category: %regex%</target>
|
<target>The part name does not match the regular expression stated by the category: %regex%</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
<unit id="m8kMFhf" name="validator.attachment.name_not_blank">
|
<unit id="m8kMFhf" name="validator.attachment.name_not_blank">
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>validator.attachment.name_not_blank</source>
|
<source>validator.attachment.name_not_blank</source>
|
||||||
<target>Set a value here, or upload a file to automatically use its filename as name for the attachment.</target>
|
<target>Set a value here, or upload a file to automatically use its filename as name for the attachment.</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
<unit id="nwGaNBW" name="validator.part_lot.owner_must_match_storage_location_owner">
|
<unit id="nwGaNBW" name="validator.part_lot.owner_must_match_storage_location_owner">
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>validator.part_lot.owner_must_match_storage_location_owner</source>
|
<source>validator.part_lot.owner_must_match_storage_location_owner</source>
|
||||||
<target>The owner of this lot must match the owner of the selected storage location (%owner_name%)!</target>
|
<target>The owner of this lot must match the owner of the selected storage location (%owner_name%)!</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
<unit id="HXSz3nQ" name="validator.part_lot.owner_must_not_be_anonymous">
|
<unit id="HXSz3nQ" name="validator.part_lot.owner_must_not_be_anonymous">
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>validator.part_lot.owner_must_not_be_anonymous</source>
|
<source>validator.part_lot.owner_must_not_be_anonymous</source>
|
||||||
<target>A lot owner must not be the anonymous user!</target>
|
<target>A lot owner must not be the anonymous user!</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
<unit id="N8aA0Uh" name="validator.part_association.must_set_an_value_if_type_is_other">
|
<unit id="N8aA0Uh" name="validator.part_association.must_set_an_value_if_type_is_other">
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>validator.part_association.must_set_an_value_if_type_is_other</source>
|
<source>validator.part_association.must_set_an_value_if_type_is_other</source>
|
||||||
<target>If you set the type to "other", then you have to set a descriptive value for it!</target>
|
<target>If you set the type to "other", then you have to set a descriptive value for it!</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
<unit id="9VYNZ4v" name="validator.part_association.part_cannot_be_associated_with_itself">
|
<unit id="9VYNZ4v" name="validator.part_association.part_cannot_be_associated_with_itself">
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>validator.part_association.part_cannot_be_associated_with_itself</source>
|
<source>validator.part_association.part_cannot_be_associated_with_itself</source>
|
||||||
<target>A part can not be associated with itself!</target>
|
<target>A part can not be associated with itself!</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
<unit id="csc1PNn" name="validator.part_association.already_exists">
|
<unit id="csc1PNn" name="validator.part_association.already_exists">
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>validator.part_association.already_exists</source>
|
<source>validator.part_association.already_exists</source>
|
||||||
<target>The association with this part already exists!</target>
|
<target>The association with this part already exists!</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
<unit id="sfW4NYE" name="validator.part_lot.vendor_barcode_must_be_unique">
|
<unit id="sfW4NYE" name="validator.part_lot.vendor_barcode_must_be_unique">
|
||||||
<segment state="translated">
|
<segment>
|
||||||
<source>validator.part_lot.vendor_barcode_must_be_unique</source>
|
<source>validator.part_lot.vendor_barcode_must_be_unique</source>
|
||||||
<target>This vendor barcode value was already used in another lot. The barcode must be unique!</target>
|
<target>This vendor barcode value was already used in another lot. The barcode must be unique!</target>
|
||||||
</segment>
|
</segment>
|
||||||
</unit>
|
</unit>
|
||||||
|
<unit id="o1qmPUm" name="validator.year_2038_bug_on_32bit">
|
||||||
|
<segment>
|
||||||
|
<source>validator.year_2038_bug_on_32bit</source>
|
||||||
|
<target>Due to technical limitations, it is not possible to select dates after the 2038-01-19 on 32-bit systems!</target>
|
||||||
|
</segment>
|
||||||
|
</unit>
|
||||||
</file>
|
</file>
|
||||||
</xliff>
|
</xliff>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue