Ugly progress commit

This commit is contained in:
Timothy Warren 2019-07-23 10:31:06 -04:00
parent 37e9726588
commit 9fe4411a77
13 changed files with 1490 additions and 660 deletions

View File

@ -7,7 +7,9 @@
"symfony/debug-pack": "^1.0",
"symfony/form": "^4.0",
"symfony/maker-bundle": "^1.0",
"symfony/orm-pack": "^1.0"
"symfony/orm-pack": "^1.0",
"symfony/translation": "^4.3",
"symfony/validator": "^4.3"
},
"require-dev": {
"roave/security-advisories": "dev-master",

1830
composer.lock generated

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,3 @@
framework:
validation:
not_compromised_password: false

View File

@ -0,0 +1,6 @@
framework:
default_locale: 'en'
translator:
default_path: '%kernel.project_dir%/translations'
fallbacks:
- '%locale%'

View File

@ -0,0 +1,8 @@
framework:
validation:
email_validation_mode: html5
# Enables validator auto-mapping support.
# For instance, basic validation constraints will be inferred from Doctrine's metadata.
#auto_mapping:
# App\Entity\: []

View File

@ -14,13 +14,18 @@ class MoneyType extends Type {
return 'MONEY';
}
public function convertToPHPValue($value, AbstractPlatform $platform)
public function convertToPHPValue($value, AbstractPlatform $platform): float
{
return (float)(new Money($value))->__toString();
return (float) (string)new Money($value);
}
public function getName(): string
{
return 'money';
}
public function requiresSQLCommentHint(AbstractPlatform $platform): bool
{
return TRUE;
}
}

View File

@ -98,9 +98,6 @@
"psr/log": {
"version": "1.0.2"
},
"psr/simple-cache": {
"version": "1.0.0"
},
"roave/security-advisories": {
"version": "dev-master"
},
@ -116,6 +113,9 @@
"symfony/cache": {
"version": "v3.3.13"
},
"symfony/cache-contracts": {
"version": "v1.1.1"
},
"symfony/config": {
"version": "v3.3.13"
},
@ -128,9 +128,6 @@
"ref": "9f94d3ea453cd8a3b95db7f82592d7344fe3a76a"
}
},
"symfony/contracts": {
"version": "v1.0.0"
},
"symfony/debug": {
"version": "v3.3.13"
},
@ -158,6 +155,9 @@
"symfony/event-dispatcher": {
"version": "v3.3.13"
},
"symfony/event-dispatcher-contracts": {
"version": "v1.1.1"
},
"symfony/filesystem": {
"version": "v3.3.13"
},
@ -206,6 +206,9 @@
"ref": "fadbfe33303a76e25cb63401050439aa9b1a9c7f"
}
},
"symfony/mime": {
"version": "v4.3.0"
},
"symfony/monolog-bridge": {
"version": "v4.1.1"
},
@ -230,12 +233,18 @@
"symfony/polyfill-intl-icu": {
"version": "v1.6.0"
},
"symfony/polyfill-intl-idn": {
"version": "v1.11.0"
},
"symfony/polyfill-mbstring": {
"version": "v1.6.0"
},
"symfony/polyfill-php72": {
"version": "v1.8.0"
},
"symfony/polyfill-php73": {
"version": "v1.11.0"
},
"symfony/profiler-pack": {
"version": "v1.0.3"
},
@ -251,9 +260,28 @@
"ref": "a249484db698d1a847a30291c8f732414ac47e25"
}
},
"symfony/service-contracts": {
"version": "v1.1.2"
},
"symfony/stopwatch": {
"version": "v4.1.1"
},
"symfony/translation": {
"version": "3.3",
"recipe": {
"repo": "github.com/symfony/recipes",
"branch": "master",
"version": "3.3",
"ref": "1fb02a6e1c8f3d4232cce485c9afa868d63b115a"
},
"files": [
"config/packages/translation.yaml",
"translations/.gitignore"
]
},
"symfony/translation-contracts": {
"version": "v1.1.2"
},
"symfony/twig-bridge": {
"version": "v4.0.0"
},
@ -266,6 +294,19 @@
"ref": "f75ac166398e107796ca94cc57fa1edaa06ec47f"
}
},
"symfony/validator": {
"version": "4.3",
"recipe": {
"repo": "github.com/symfony/recipes",
"branch": "master",
"version": "4.3",
"ref": "d902da3e4952f18d3bf05aab29512eb61cabd869"
},
"files": [
"config/packages/test/validator.yaml",
"config/packages/validator.yaml"
]
},
"symfony/var-dumper": {
"version": "v4.1.1"
},

View File

@ -117,7 +117,13 @@
<td>{{ camera.filmFormat }}</td>
<td>{{ camera.cropFactor }}</td>
<td>{{ camera.serial }}</td>
<td class="text-center">{% if camera.formerlyOwned %}{% else %}&#10007;{% endif %}</td>
<td class="text-center">
{% if camera.formerlyOwned %}
<span class='small callout success'>✔</span>
{% else %}
<span class='small callout alert'>&#10007;</span>
{% endif %}
</td>
<td>${{ camera.purchasePrice }}</td>
<td>{{ camera.batteryType }}</td>
<td>{{ camera.notes }}</td>
@ -165,7 +171,13 @@
<td>{{ camera.filmFormat }}</td>
<td>{{ camera.cropFactor }}</td>
<td>{{ camera.serial }}</td>
<td class="text-center">{% if camera.formerlyOwned %}{% else %}&#10007;{% endif %}</td>
<td class="text-center">
{% if camera.formerlyOwned %}
<span class='small callout success'>✔</span>
{% else %}
<span class='small callout alert'>&#10007;</span>
{% endif %}
</td>
<td>${{ camera.purchasePrice }}</td>
<td>{{ camera.batteryType }}</td>
<td>{{ camera.notes }}</td>

View File

@ -48,7 +48,13 @@
</tr>
<tr>
<th>Is Digital?</th>
<td>{% if camera.isDigital %}Yes{% else %}No{% endif %}</td>
<td>
{% if camera.isDigital %}
<span class='small callout success'>Yes</span>
{% else %}
<span class='small callout alert'>No</span>
{% endif %}
</td>
</tr>
<tr>
<th>Crop Factor</th>
@ -56,7 +62,13 @@
</tr>
<tr>
<th>Is Working?</th>
<td>{% if camera.isWorking %}Yes{% else %}No{% endif %}</td>
<td>
{% if camera.isWorking %}
<span class='small callout success'>Yes</span>
{% else %}
<span class='small callout alert'>No</span>
{% endif %}
</td>
</tr>
<tr>
<th>Notes</th>
@ -68,7 +80,13 @@
</tr>
<tr>
<th>Formerly Owned?</th>
<td>{% if camera.formerlyOwned %}Yes{% else %}No{% endif %}</td>
<td>
{% if camera.formerlyOwned %}
<span class='small callout success'>Yes</span>
{% else %}
<span class='small callout alert'>No</span>
{% endif %}
</td>
</tr>
<tr>
<th>Purchase Price</th>

View File

@ -77,10 +77,22 @@
<td class="text-right">${{ lens.purchasePrice }}</td>
<td>{{ lens.mount }}</td>
<td>{{ lens.imageSize }}</td>
<td class="text-center">{% if lens.formerlyOwned %}{% else %}&#10007;{% endif %}</td>
<td class="text-center">
{% if lens.formerlyOwned %}
<span class='small callout success'>✔</span>
{% else %}
<span class='small callout alert'>&#10007;</span>
{% endif %}
</td>
<td>{{ lens.frontFilterSize }}</td>
<td>{{ lens.rearFilterSize }}</td>
<td class="text-center">{% if lens.isTeleconverter %}{% else %}&#10007;{% endif %}</td>
<td class="text-center">
{% if lens.isTeleconverter %}
<span class='small callout success'>✔</span>
{% else %}
<span class='small callout alert'>&#10007;</span>
{% endif %}
</td>
<td>{{ lens.designElements }} / {{ lens.designGroups }}</td>
<td>{{ lens.apertureBlades }}</td>
<td>{{ lens.notes }}</td>
@ -137,9 +149,21 @@
<td class="text-right">${{ lens.purchasePrice }}</td>
<td>{{ lens.mount }}</td>
<td>{{ lens.imageSize }}</td>
<td class="text-center">{% if lens.formerlyOwned %}{% else %}&#10007;{% endif %}</td>
<td class="text-center">
{% if lens.formerlyOwned %}
<span class='small callout success'>✔</span>
{% else %}
<span class='small callout alert'>&#10007;</span>
{% endif %}
</td>
<td>{{ lens.frontFilterSize }} / {{ lens.rearFilterSize }}</td>
<td class="text-center">{% if lens.isTeleconverter %}{% else %}&#10007;{% endif %}</td>
<td class="text-center">
{% if lens.isTeleconverter %}
<span class='small callout success'>✔</span>
{% else %}
<span class='small callout alert'>&#10007;</span>
{% endif %}
</td>
<td>{{ lens.designElements }} / {{ lens.designGroups }}</td>
<td>{{ lens.apertureBlades }}</td>
<td>{{ lens.notes }}</td>

0
translations/.gitignore vendored Normal file
View File

View File

@ -0,0 +1,68 @@
<?php
return [
'' => '',
'4x4' => '4x4cm',
'6x4.5' => '6x4.5cm',
'6x6' => '6x6cm',
'35mm' => '35mm',
'110' => '110',
'120' => '120',
'127' => '127',
'620' => '620',
'Aperture blades' => '# of Aperture Blades',
'APS-C' => 'APS-C',
'B & W' => 'B & W',
'Batteries' => 'Batteries',
'Battery type' => 'Battery Type',
'Brand' => 'Brand',
'C-41' => 'C-41',
'Cellulose Triacetate' => 'Cellulose Triacetate',
'Chemistry' => 'Film Chemistry',
'Coatings' => 'Coatings',
'Crop factor' => 'Crop Factor',
'Description' => 'Description',
'Design elements' => '# of Design Elements',
'Design groups' => '# of Design Groups',
'Developed rolls' => '# of Developed Rolls',
'E-6' => 'E-6',
'Film alias' => 'Film Alias',
'Film base' => 'Film Base',
'Film format' => 'Film Format',
'Film name' => 'Film Name',
'Film speed asa' => 'Film Speed (ASA)',
'Film speed din' => 'Film Speed (DIN)',
'Formerly owned' => 'Formerly Owned',
'Front filter size' => 'Front filter size (mm)',
'Guide number' => 'Guide Number',
'Image size' => 'Image Size',
'Is auto flash' => 'Is auto flash',
'Is digital' => 'Is Digital',
'Is p ttl' => 'Is P-TTL',
'Is teleconverter' => 'Is teleconverter',
'Is ttl' => 'Is TTL',
'Is working' => 'Is Working',
'Max f stop' => 'Max aperture (smallest f number)',
'Max focal length' => 'Max focal length (mm)',
'Medium Format' => 'Medium Format',
'Micro 4/3' => 'μ 4/3',
'Min f stop' => 'Min aperture (largest f number)',
'Min focal length' => 'Min focal length (mm)',
'Model' => 'Model',
'Mount' => 'Mount',
'Notes' => 'Notes',
'Other' => 'Other',
'P ttl type' => 'P-TTL Type',
'Polyester' => 'Polyester',
'Polyethylene Naphtalate' => 'Polyethylene Naphtalate',
'Product line' => 'Product Line',
'Purchase price' => 'Purchase Price',
'Rear filter size' => 'Rear filter size (mm)',
'Received' => 'Received',
'Rolls in camera' => '# of Rolls in a Camera',
'Serial' => 'Serial',
'Small Format' => 'Small Format',
'Ttl type' => 'TTL Type',
'Type' => 'Type',
'Unused rolls' => '# of Unused Rolls',
];

View File

@ -0,0 +1,97 @@
<?php
return [
'This value should be false.' => 'This value should be false.',
'This value should be true.' => 'This value should be true.',
'This value should be of type {{ type }}.' => 'This value should be of type {{ type }}.',
'This value should be blank.' => 'This value should be blank.',
'The value you selected is not a valid choice.' => 'The value you selected is not a valid choice.',
'You must select at least {{ limit }} choice.|You must select at least {{ limit }} choices.' => 'You must select at least {{ limit }} choice.|You must select at least {{ limit }} choices.',
'You must select at most {{ limit }} choice.|You must select at most {{ limit }} choices.' => 'You must select at most {{ limit }} choice.|You must select at most {{ limit }} choices.',
'One or more of the given values is invalid.' => 'One or more of the given values is invalid.',
'This field was not expected.' => 'This field was not expected.',
'This field is missing.' => 'This field is missing.',
'This value is not a valid date.' => 'This value is not a valid date.',
'This value is not a valid datetime.' => 'This value is not a valid datetime.',
'This value is not a valid email address.' => 'This value is not a valid email address.',
'The file could not be found.' => 'The file could not be found.',
'The file is not readable.' => 'The file is not readable.',
'The file is too large ({{ size }} {{ suffix }}). Allowed maximum size is {{ limit }} {{ suffix }}.' => 'The file is too large ({{ size }} {{ suffix }}). Allowed maximum size is {{ limit }} {{ suffix }}.',
'The mime type of the file is invalid ({{ type }}). Allowed mime types are {{ types }}.' => 'The mime type of the file is invalid ({{ type }}). Allowed mime types are {{ types }}.',
'This value should be {{ limit }} or less.' => 'This value should be {{ limit }} or less.',
'This value is too long. It should have {{ limit }} character or less.|This value is too long. It should have {{ limit }} characters or less.' => 'This value is too long. It should have {{ limit }} character or less.|This value is too long. It should have {{ limit }} characters or less.',
'This value should be {{ limit }} or more.' => 'This value should be {{ limit }} or more.',
'This value is too short. It should have {{ limit }} character or more.|This value is too short. It should have {{ limit }} characters or more.' => 'This value is too short. It should have {{ limit }} character or more.|This value is too short. It should have {{ limit }} characters or more.',
'This value should not be blank.' => 'This value should not be blank.',
'This value should not be null.' => 'This value should not be null.',
'This value should be null.' => 'This value should be null.',
'This value is not valid.' => 'This value is not valid.',
'This value is not a valid time.' => 'This value is not a valid time.',
'This value is not a valid URL.' => 'This value is not a valid URL.',
'The two values should be equal.' => 'The two values should be equal.',
'The file is too large. Allowed maximum size is {{ limit }} {{ suffix }}.' => 'The file is too large. Allowed maximum size is {{ limit }} {{ suffix }}.',
'The file is too large.' => 'The file is too large.',
'The file could not be uploaded.' => 'The file could not be uploaded.',
'This value should be a valid number.' => 'This value should be a valid number.',
'This file is not a valid image.' => 'This file is not a valid image.',
'This is not a valid IP address.' => 'This is not a valid IP address.',
'This value is not a valid language.' => 'This value is not a valid language.',
'This value is not a valid locale.' => 'This value is not a valid locale.',
'This value is not a valid country.' => 'This value is not a valid country.',
'This value is already used.' => 'This value is already used.',
'The size of the image could not be detected.' => 'The size of the image could not be detected.',
'The image width is too big ({{ width }}px). Allowed maximum width is {{ max_width }}px.' => 'The image width is too big ({{ width }}px). Allowed maximum width is {{ max_width }}px.',
'The image width is too small ({{ width }}px). Minimum width expected is {{ min_width }}px.' => 'The image width is too small ({{ width }}px). Minimum width expected is {{ min_width }}px.',
'The image height is too big ({{ height }}px). Allowed maximum height is {{ max_height }}px.' => 'The image height is too big ({{ height }}px). Allowed maximum height is {{ max_height }}px.',
'The image height is too small ({{ height }}px). Minimum height expected is {{ min_height }}px.' => 'The image height is too small ({{ height }}px). Minimum height expected is {{ min_height }}px.',
'This value should be the user\'s current password.' => 'This value should be the user\'s current password.',
'This value should have exactly {{ limit }} character.|This value should have exactly {{ limit }} characters.' => 'This value should have exactly {{ limit }} character.|This value should have exactly {{ limit }} characters.',
'The file was only partially uploaded.' => 'The file was only partially uploaded.',
'No file was uploaded.' => 'No file was uploaded.',
'No temporary folder was configured in php.ini.' => 'No temporary folder was configured in php.ini, or the configured folder does not exist.',
'Cannot write temporary file to disk.' => 'Cannot write temporary file to disk.',
'A PHP extension caused the upload to fail.' => 'A PHP extension caused the upload to fail.',
'This collection should contain {{ limit }} element or more.|This collection should contain {{ limit }} elements or more.' => 'This collection should contain {{ limit }} element or more.|This collection should contain {{ limit }} elements or more.',
'This collection should contain {{ limit }} element or less.|This collection should contain {{ limit }} elements or less.' => 'This collection should contain {{ limit }} element or less.|This collection should contain {{ limit }} elements or less.',
'This collection should contain exactly {{ limit }} element.|This collection should contain exactly {{ limit }} elements.' => 'This collection should contain exactly {{ limit }} element.|This collection should contain exactly {{ limit }} elements.',
'Invalid card number.' => 'Invalid card number.',
'Unsupported card type or invalid card number.' => 'Unsupported card type or invalid card number.',
'This is not a valid International Bank Account Number (IBAN).' => 'This is not a valid International Bank Account Number (IBAN).',
'This value is not a valid ISBN-10.' => 'This value is not a valid ISBN-10.',
'This value is not a valid ISBN-13.' => 'This value is not a valid ISBN-13.',
'This value is neither a valid ISBN-10 nor a valid ISBN-13.' => 'This value is neither a valid ISBN-10 nor a valid ISBN-13.',
'This value is not a valid ISSN.' => 'This value is not a valid ISSN.',
'This value is not a valid currency.' => 'This value is not a valid currency.',
'This value should be equal to {{ compared_value }}.' => 'This value should be equal to {{ compared_value }}.',
'This value should be greater than {{ compared_value }}.' => 'This value should be greater than {{ compared_value }}.',
'This value should be greater than or equal to {{ compared_value }}.' => 'This value should be greater than or equal to {{ compared_value }}.',
'This value should be identical to {{ compared_value_type }} {{ compared_value }}.' => 'This value should be identical to {{ compared_value_type }} {{ compared_value }}.',
'This value should be less than {{ compared_value }}.' => 'This value should be less than {{ compared_value }}.',
'This value should be less than or equal to {{ compared_value }}.' => 'This value should be less than or equal to {{ compared_value }}.',
'This value should not be equal to {{ compared_value }}.' => 'This value should not be equal to {{ compared_value }}.',
'This value should not be identical to {{ compared_value_type }} {{ compared_value }}.' => 'This value should not be identical to {{ compared_value_type }} {{ compared_value }}.',
'The image ratio is too big ({{ ratio }}). Allowed maximum ratio is {{ max_ratio }}.' => 'The image ratio is too big ({{ ratio }}). Allowed maximum ratio is {{ max_ratio }}.',
'The image ratio is too small ({{ ratio }}). Minimum ratio expected is {{ min_ratio }}.' => 'The image ratio is too small ({{ ratio }}). Minimum ratio expected is {{ min_ratio }}.',
'The image is square ({{ width }}x{{ height }}px). Square images are not allowed.' => 'The image is square ({{ width }}x{{ height }}px). Square images are not allowed.',
'The image is landscape oriented ({{ width }}x{{ height }}px). Landscape oriented images are not allowed.' => 'The image is landscape oriented ({{ width }}x{{ height }}px). Landscape oriented images are not allowed.',
'The image is portrait oriented ({{ width }}x{{ height }}px). Portrait oriented images are not allowed.' => 'The image is portrait oriented ({{ width }}x{{ height }}px). Portrait oriented images are not allowed.',
'An empty file is not allowed.' => 'An empty file is not allowed.',
'The host could not be resolved.' => 'The host could not be resolved.',
'This value does not match the expected {{ charset }} charset.' => 'This value does not match the expected {{ charset }} charset.',
'This is not a valid Business Identifier Code (BIC).' => 'This is not a valid Business Identifier Code (BIC).',
'Error' => 'Error',
'This is not a valid UUID.' => 'This is not a valid UUID.',
'This value should be a multiple of {{ compared_value }}.' => 'This value should be a multiple of {{ compared_value }}.',
'This Business Identifier Code (BIC) is not associated with IBAN {{ iban }}.' => 'This Business Identifier Code (BIC) is not associated with IBAN {{ iban }}.',
'This value should be valid JSON.' => 'This value should be valid JSON.',
'This collection should contain only unique elements.' => 'This collection should contain only unique elements.',
'This value should be positive.' => 'This value should be positive.',
'This value should be either positive or zero.' => 'This value should be either positive or zero.',
'This value should be negative.' => 'This value should be negative.',
'This value should be either negative or zero.' => 'This value should be either negative or zero.',
'This value is not a valid timezone.' => 'This value is not a valid timezone.',
'This password has been leaked in a data breach, it must not be used. Please use another password.' => 'This password has been leaked in a data breach, it must not be used. Please use another password.',
'This form should not contain extra fields.' => 'This form should not contain extra fields.',
'The uploaded file was too large. Please try to upload a smaller file.' => 'The uploaded file was too large. Please try to upload a smaller file.',
'The CSRF token is invalid. Please try to resubmit the form.' => 'The CSRF token is invalid. Please try to resubmit the form.',
];