diff --git a/.docker/images/nginx/conf.d/default.conf b/.docker/images/nginx/conf.d/default.conf index 77b7845f0..914a4c63a 100644 --- a/.docker/images/nginx/conf.d/default.conf +++ b/.docker/images/nginx/conf.d/default.conf @@ -64,6 +64,11 @@ server { try_files $uri @sfFront; } + # location /w2p/ { + # proxy_pass http://tp:8080/w2p/; + # proxy_temp_path /tmp/proxy; + #} + location @sfFront { # Symfony if ($request_method = 'OPTIONS') { add_header 'Access-Control-Allow-Origin' '*'; diff --git a/src/new/assets/controllers.json b/src/new/assets/controllers.json index b3e65cf75..6d45fb171 100755 --- a/src/new/assets/controllers.json +++ b/src/new/assets/controllers.json @@ -25,6 +25,12 @@ "@symfony/ux-live-component/dist/live.min.css": true } } + }, + "@symfony/ux-vue": { + "vue": { + "enabled": true, + "fetch": "eager" + } } }, "entrypoints": [] diff --git a/src/new/assets/tailwind/backend.js b/src/new/assets/tailwind/backend.js index 1e7795ccc..5f7f6d755 100644 --- a/src/new/assets/tailwind/backend.js +++ b/src/new/assets/tailwind/backend.js @@ -7,6 +7,8 @@ import { initTabs } from 'david-ai'; // Initialize tabs functionality initTabs(); +import { registerVueControllerComponents } from '@symfony/ux-vue'; +registerVueControllerComponents() import { startStimulusApp } from '@symfony/stimulus-bundle'; const app = startStimulusApp(); Alpine.plugin(persist) diff --git a/src/new/assets/vue/controllers/PackageSearch.js b/src/new/assets/vue/controllers/PackageSearch.js new file mode 100644 index 000000000..60863fe3b --- /dev/null +++ b/src/new/assets/vue/controllers/PackageSearch.js @@ -0,0 +1,41 @@ +/** + | Single-File Components - e.g. PackageSearch.vue - + | are supported when using Webpack Encore. + */ +import { ref, computed } from 'vue'; +import PackageList from "./components/PackageList.js"; + +export default { + components: { + PackageList + }, + props: ['news'], + setup(props) { + const search = ref(''); + + const filteredPackages = computed(() => { + return props.packages.filter( + uxPackage => uxPackage.humanName.toLowerCase().includes(search.value.toLowerCase()) + ); + }); + + return { + search, + filteredPackages + } + }, + template: ` +
+ + +
+PackageList +
+
+ ` +}; diff --git a/src/new/assets/vue/controllers/components/PackageList.js b/src/new/assets/vue/controllers/components/PackageList.js new file mode 100644 index 000000000..7fc72294a --- /dev/null +++ b/src/new/assets/vue/controllers/components/PackageList.js @@ -0,0 +1,21 @@ +export default { + props: ['packages'], + template: ` +
+ No packages found. Sad trombone... +
+ +
+ +
+
+ +
+

+ {{ package.humanName }} +

+
+ +
+ ` +}; diff --git a/src/new/composer.json b/src/new/composer.json index 2537d9c55..793f39e7b 100755 --- a/src/new/composer.json +++ b/src/new/composer.json @@ -94,6 +94,7 @@ "symfony/ux-chartjs": "^2.19", "symfony/ux-live-component": "^2.12", "symfony/ux-twig-component": "^2.12", + "symfony/ux-vue": "^2.23", "symfony/validator": "*", "symfony/web-link": "*", "symfony/yaml": "*", diff --git a/src/new/composer.lock b/src/new/composer.lock index e5e523b61..0fe3ba9df 100755 --- a/src/new/composer.lock +++ b/src/new/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "da8eba6c1fa5f895ee29628551ab79ce", + "content-hash": "a020910e9bff4a83b3f41207f9ff93ce", "packages": [ { "name": "azuyalabs/yasumi", @@ -1106,29 +1106,29 @@ }, { "name": "doctrine/collections", - "version": "2.2.2", + "version": "2.3.0", "source": { "type": "git", "url": "https://github.com/doctrine/collections.git", - "reference": "d8af7f248c74f195f7347424600fd9e17b57af59" + "reference": "2eb07e5953eed811ce1b309a7478a3b236f2273d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/collections/zipball/d8af7f248c74f195f7347424600fd9e17b57af59", - "reference": "d8af7f248c74f195f7347424600fd9e17b57af59", + "url": "https://api.github.com/repos/doctrine/collections/zipball/2eb07e5953eed811ce1b309a7478a3b236f2273d", + "reference": "2eb07e5953eed811ce1b309a7478a3b236f2273d", "shasum": "" }, "require": { "doctrine/deprecations": "^1", - "php": "^8.1" + "php": "^8.1", + "symfony/polyfill-php84": "^1.30" }, "require-dev": { "doctrine/coding-standard": "^12", "ext-json": "*", "phpstan/phpstan": "^1.8", "phpstan/phpstan-phpunit": "^1.0", - "phpunit/phpunit": "^10.5", - "vimeo/psalm": "^5.11" + "phpunit/phpunit": "^10.5" }, "type": "library", "autoload": { @@ -1172,7 +1172,7 @@ ], "support": { "issues": "https://github.com/doctrine/collections/issues", - "source": "https://github.com/doctrine/collections/tree/2.2.2" + "source": "https://github.com/doctrine/collections/tree/2.3.0" }, "funding": [ { @@ -1188,7 +1188,7 @@ "type": "tidelift" } ], - "time": "2024-04-18T06:56:21+00:00" + "time": "2025-03-22T10:17:19+00:00" }, { "name": "doctrine/common", @@ -2425,16 +2425,16 @@ }, { "name": "egulias/email-validator", - "version": "4.0.3", + "version": "4.0.4", "source": { "type": "git", "url": "https://github.com/egulias/EmailValidator.git", - "reference": "b115554301161fa21467629f1e1391c1936de517" + "reference": "d42c8731f0624ad6bdc8d3e5e9a4524f68801cfa" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/egulias/EmailValidator/zipball/b115554301161fa21467629f1e1391c1936de517", - "reference": "b115554301161fa21467629f1e1391c1936de517", + "url": "https://api.github.com/repos/egulias/EmailValidator/zipball/d42c8731f0624ad6bdc8d3e5e9a4524f68801cfa", + "reference": "d42c8731f0624ad6bdc8d3e5e9a4524f68801cfa", "shasum": "" }, "require": { @@ -2480,7 +2480,7 @@ ], "support": { "issues": "https://github.com/egulias/EmailValidator/issues", - "source": "https://github.com/egulias/EmailValidator/tree/4.0.3" + "source": "https://github.com/egulias/EmailValidator/tree/4.0.4" }, "funding": [ { @@ -2488,7 +2488,7 @@ "type": "github" } ], - "time": "2024-12-27T00:36:43+00:00" + "time": "2025-03-06T22:45:56+00:00" }, { "name": "ezyang/htmlpurifier", @@ -3257,27 +3257,30 @@ }, { "name": "horstoeko/stringmanagement", - "version": "v1.0.11", + "version": "v1.0.12", "source": { "type": "git", "url": "https://github.com/horstoeko/stringmanagement.git", - "reference": "57f0c2bae4cba941902a02d8166d1f03fb52d08a" + "reference": "d304a094e34c39d35f275bccf4944176dd8f1722" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/horstoeko/stringmanagement/zipball/57f0c2bae4cba941902a02d8166d1f03fb52d08a", - "reference": "57f0c2bae4cba941902a02d8166d1f03fb52d08a", + "url": "https://api.github.com/repos/horstoeko/stringmanagement/zipball/d304a094e34c39d35f275bccf4944176dd8f1722", + "reference": "d304a094e34c39d35f275bccf4944176dd8f1722", "shasum": "" }, "require": { - "php": "^7.3|^7.4|^8.0|^8.1|^8.2|^8.3" + "php": ">=7.3" }, "require-dev": { + "nette/php-generator": "*", "pdepend/pdepend": "^2", + "phpdocumentor/reflection-docblock": "^5", "phploc/phploc": "^7", "phpmd/phpmd": "^2", - "phpstan/phpstan": "^1.8", + "phpstan/phpstan": "^1|^2", "phpunit/phpunit": "^9", + "rector/rector": "*", "sebastian/phpcpd": "^6", "squizlabs/php_codesniffer": "^3" }, @@ -3305,22 +3308,22 @@ ], "support": { "issues": "https://github.com/horstoeko/stringmanagement/issues", - "source": "https://github.com/horstoeko/stringmanagement/tree/v1.0.11" + "source": "https://github.com/horstoeko/stringmanagement/tree/v1.0.12" }, - "time": "2023-02-12T14:16:40+00:00" + "time": "2025-03-15T09:04:46+00:00" }, { "name": "horstoeko/zugferd", - "version": "v1.0.106", + "version": "v1.0.112", "source": { "type": "git", "url": "https://github.com/horstoeko/zugferd.git", - "reference": "e575f67aaf08f670e435ba01d188b6faa62655a0" + "reference": "74e6f51aa4ec893ce88f37ba07206a1d39034393" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/horstoeko/zugferd/zipball/e575f67aaf08f670e435ba01d188b6faa62655a0", - "reference": "e575f67aaf08f670e435ba01d188b6faa62655a0", + "url": "https://api.github.com/repos/horstoeko/zugferd/zipball/74e6f51aa4ec893ce88f37ba07206a1d39034393", + "reference": "74e6f51aa4ec893ce88f37ba07206a1d39034393", "shasum": "" }, "require": { @@ -3379,9 +3382,9 @@ ], "support": { "issues": "https://github.com/horstoeko/zugferd/issues", - "source": "https://github.com/horstoeko/zugferd/tree/v1.0.106" + "source": "https://github.com/horstoeko/zugferd/tree/v1.0.112" }, - "time": "2025-02-03T13:26:12+00:00" + "time": "2025-03-30T08:55:45+00:00" }, { "name": "imagine/imagine", @@ -3504,16 +3507,16 @@ }, { "name": "jean85/pretty-package-versions", - "version": "2.1.0", + "version": "2.1.1", "source": { "type": "git", "url": "https://github.com/Jean85/pretty-package-versions.git", - "reference": "3c4e5f62ba8d7de1734312e4fff32f67a8daaf10" + "reference": "4d7aa5dab42e2a76d99559706022885de0e18e1a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Jean85/pretty-package-versions/zipball/3c4e5f62ba8d7de1734312e4fff32f67a8daaf10", - "reference": "3c4e5f62ba8d7de1734312e4fff32f67a8daaf10", + "url": "https://api.github.com/repos/Jean85/pretty-package-versions/zipball/4d7aa5dab42e2a76d99559706022885de0e18e1a", + "reference": "4d7aa5dab42e2a76d99559706022885de0e18e1a", "shasum": "" }, "require": { @@ -3523,8 +3526,9 @@ "require-dev": { "friendsofphp/php-cs-fixer": "^3.2", "jean85/composer-provided-replaced-stub-package": "^1.0", - "phpstan/phpstan": "^1.4", + "phpstan/phpstan": "^2.0", "phpunit/phpunit": "^7.5|^8.5|^9.6", + "rector/rector": "^2.0", "vimeo/psalm": "^4.3 || ^5.0" }, "type": "library", @@ -3557,9 +3561,9 @@ ], "support": { "issues": "https://github.com/Jean85/pretty-package-versions/issues", - "source": "https://github.com/Jean85/pretty-package-versions/tree/2.1.0" + "source": "https://github.com/Jean85/pretty-package-versions/tree/2.1.1" }, - "time": "2024-11-18T16:19:46+00:00" + "time": "2025-03-19T14:43:43+00:00" }, { "name": "jms/metadata", @@ -4979,27 +4983,23 @@ }, { "name": "mongodb/mongodb", - "version": "1.21.0", + "version": "1.21.1", "source": { "type": "git", "url": "https://github.com/mongodb/mongo-php-library.git", - "reference": "d216a5bfc62c9b63ba3523565a35856ab91f78d9" + "reference": "37bc8df3a67ddf8380704a5ba5dbd00e92ec1f6a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/mongodb/mongo-php-library/zipball/d216a5bfc62c9b63ba3523565a35856ab91f78d9", - "reference": "d216a5bfc62c9b63ba3523565a35856ab91f78d9", + "url": "https://api.github.com/repos/mongodb/mongo-php-library/zipball/37bc8df3a67ddf8380704a5ba5dbd00e92ec1f6a", + "reference": "37bc8df3a67ddf8380704a5ba5dbd00e92ec1f6a", "shasum": "" }, "require": { "composer-runtime-api": "^2.0", - "ext-hash": "*", - "ext-json": "*", "ext-mongodb": "^1.21.0", "php": "^8.1", - "psr/log": "^1.1.4|^2|^3", - "symfony/polyfill-php80": "^1.27", - "symfony/polyfill-php81": "^1.27" + "psr/log": "^1.1.4|^2|^3" }, "replace": { "mongodb/builder": "*" @@ -5053,9 +5053,9 @@ ], "support": { "issues": "https://github.com/mongodb/mongo-php-library/issues", - "source": "https://github.com/mongodb/mongo-php-library/tree/1.21.0" + "source": "https://github.com/mongodb/mongo-php-library/tree/1.21.1" }, - "time": "2025-02-28T11:14:09+00:00" + "time": "2025-02-28T17:24:20+00:00" }, { "name": "monolog/monolog", @@ -8357,16 +8357,16 @@ }, { "name": "smalot/pdfparser", - "version": "v2.11.0", + "version": "v2.12.0", "source": { "type": "git", "url": "https://github.com/smalot/pdfparser.git", - "reference": "ac8e6678b0940e4b2ccd5caadd3fb18e68093be6" + "reference": "8440edbf58c8596074e78ada38dcb0bd041a5948" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/smalot/pdfparser/zipball/ac8e6678b0940e4b2ccd5caadd3fb18e68093be6", - "reference": "ac8e6678b0940e4b2ccd5caadd3fb18e68093be6", + "url": "https://api.github.com/repos/smalot/pdfparser/zipball/8440edbf58c8596074e78ada38dcb0bd041a5948", + "reference": "8440edbf58c8596074e78ada38dcb0bd041a5948", "shasum": "" }, "require": { @@ -8402,9 +8402,9 @@ ], "support": { "issues": "https://github.com/smalot/pdfparser/issues", - "source": "https://github.com/smalot/pdfparser/tree/v2.11.0" + "source": "https://github.com/smalot/pdfparser/tree/v2.12.0" }, - "time": "2024-08-16T06:48:03+00:00" + "time": "2025-03-31T13:16:09+00:00" }, { "name": "sofort/sofortlib-php", @@ -8523,16 +8523,16 @@ }, { "name": "symfony/asset-mapper", - "version": "v6.4.18", + "version": "v6.4.20", "source": { "type": "git", "url": "https://github.com/symfony/asset-mapper.git", - "reference": "9ec7ea222381fa63aefde98d5076b99df2fba927" + "reference": "a499f1ccb647833ae68ddceba9a60da652e505eb" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/asset-mapper/zipball/9ec7ea222381fa63aefde98d5076b99df2fba927", - "reference": "9ec7ea222381fa63aefde98d5076b99df2fba927", + "url": "https://api.github.com/repos/symfony/asset-mapper/zipball/a499f1ccb647833ae68ddceba9a60da652e505eb", + "reference": "a499f1ccb647833ae68ddceba9a60da652e505eb", "shasum": "" }, "require": { @@ -8582,7 +8582,7 @@ "description": "Maps directories of assets & makes them available in a public directory with versioned filenames.", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/asset-mapper/tree/v6.4.18" + "source": "https://github.com/symfony/asset-mapper/tree/v6.4.20" }, "funding": [ { @@ -8598,20 +8598,20 @@ "type": "tidelift" } ], - "time": "2025-01-25T08:10:40+00:00" + "time": "2025-02-26T00:25:36+00:00" }, { "name": "symfony/cache", - "version": "v6.4.19", + "version": "v6.4.20", "source": { "type": "git", "url": "https://github.com/symfony/cache.git", - "reference": "342e87b15ac02e4b4f0924ddc368e75d5262aab3" + "reference": "95af448bb7c3d8db02f7b4f5cbf3cb7a6ff1e432" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/cache/zipball/342e87b15ac02e4b4f0924ddc368e75d5262aab3", - "reference": "342e87b15ac02e4b4f0924ddc368e75d5262aab3", + "url": "https://api.github.com/repos/symfony/cache/zipball/95af448bb7c3d8db02f7b4f5cbf3cb7a6ff1e432", + "reference": "95af448bb7c3d8db02f7b4f5cbf3cb7a6ff1e432", "shasum": "" }, "require": { @@ -8678,7 +8678,7 @@ "psr6" ], "support": { - "source": "https://github.com/symfony/cache/tree/v6.4.19" + "source": "https://github.com/symfony/cache/tree/v6.4.20" }, "funding": [ { @@ -8694,7 +8694,7 @@ "type": "tidelift" } ], - "time": "2025-02-26T09:12:57+00:00" + "time": "2025-03-08T15:51:34+00:00" }, { "name": "symfony/cache-contracts", @@ -8923,16 +8923,16 @@ }, { "name": "symfony/console", - "version": "v6.4.17", + "version": "v6.4.20", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "799445db3f15768ecc382ac5699e6da0520a0a04" + "reference": "2e4af9c952617cc3f9559ff706aee420a8464c36" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/799445db3f15768ecc382ac5699e6da0520a0a04", - "reference": "799445db3f15768ecc382ac5699e6da0520a0a04", + "url": "https://api.github.com/repos/symfony/console/zipball/2e4af9c952617cc3f9559ff706aee420a8464c36", + "reference": "2e4af9c952617cc3f9559ff706aee420a8464c36", "shasum": "" }, "require": { @@ -8997,7 +8997,7 @@ "terminal" ], "support": { - "source": "https://github.com/symfony/console/tree/v6.4.17" + "source": "https://github.com/symfony/console/tree/v6.4.20" }, "funding": [ { @@ -9013,20 +9013,20 @@ "type": "tidelift" } ], - "time": "2024-12-07T12:07:30+00:00" + "time": "2025-03-03T17:16:38+00:00" }, { "name": "symfony/dependency-injection", - "version": "v6.4.19", + "version": "v6.4.20", "source": { "type": "git", "url": "https://github.com/symfony/dependency-injection.git", - "reference": "b343c3b2f1539fe41331657b37d5c96c1d1ea842" + "reference": "c49796a9184a532843e78e50df9e55708b92543a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/dependency-injection/zipball/b343c3b2f1539fe41331657b37d5c96c1d1ea842", - "reference": "b343c3b2f1539fe41331657b37d5c96c1d1ea842", + "url": "https://api.github.com/repos/symfony/dependency-injection/zipball/c49796a9184a532843e78e50df9e55708b92543a", + "reference": "c49796a9184a532843e78e50df9e55708b92543a", "shasum": "" }, "require": { @@ -9034,7 +9034,7 @@ "psr/container": "^1.1|^2.0", "symfony/deprecation-contracts": "^2.5|^3", "symfony/service-contracts": "^2.5|^3.0", - "symfony/var-exporter": "^6.2.10|^7.0" + "symfony/var-exporter": "^6.4.20|^7.2.5" }, "conflict": { "ext-psr": "<1.1|>=2", @@ -9078,7 +9078,7 @@ "description": "Allows you to standardize and centralize the way objects are constructed in your application", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/dependency-injection/tree/v6.4.19" + "source": "https://github.com/symfony/dependency-injection/tree/v6.4.20" }, "funding": [ { @@ -9094,7 +9094,7 @@ "type": "tidelift" } ], - "time": "2025-02-20T10:02:49+00:00" + "time": "2025-03-13T09:55:08+00:00" }, { "name": "symfony/deprecation-contracts", @@ -9165,16 +9165,16 @@ }, { "name": "symfony/doctrine-bridge", - "version": "v6.4.19", + "version": "v6.4.20", "source": { "type": "git", "url": "https://github.com/symfony/doctrine-bridge.git", - "reference": "22df1e858b8b00647c67fc201dfbea65c0fdab15" + "reference": "7205dbc642bac2ecbf108fadbf9a04aa08290a2a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/doctrine-bridge/zipball/22df1e858b8b00647c67fc201dfbea65c0fdab15", - "reference": "22df1e858b8b00647c67fc201dfbea65c0fdab15", + "url": "https://api.github.com/repos/symfony/doctrine-bridge/zipball/7205dbc642bac2ecbf108fadbf9a04aa08290a2a", + "reference": "7205dbc642bac2ecbf108fadbf9a04aa08290a2a", "shasum": "" }, "require": { @@ -9253,7 +9253,7 @@ "description": "Provides integration for Doctrine with various Symfony components", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/doctrine-bridge/tree/v6.4.19" + "source": "https://github.com/symfony/doctrine-bridge/tree/v6.4.20" }, "funding": [ { @@ -9269,7 +9269,7 @@ "type": "tidelift" } ], - "time": "2025-02-18T08:43:25+00:00" + "time": "2025-02-28T20:55:44+00:00" }, { "name": "symfony/dotenv", @@ -9347,16 +9347,16 @@ }, { "name": "symfony/error-handler", - "version": "v6.4.19", + "version": "v6.4.20", "source": { "type": "git", "url": "https://github.com/symfony/error-handler.git", - "reference": "3d4e55cd2b8f1979a65eba9ab749d6466c316f71" + "reference": "aa3bcf4f7674719df078e61cc8062e5b7f752031" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/error-handler/zipball/3d4e55cd2b8f1979a65eba9ab749d6466c316f71", - "reference": "3d4e55cd2b8f1979a65eba9ab749d6466c316f71", + "url": "https://api.github.com/repos/symfony/error-handler/zipball/aa3bcf4f7674719df078e61cc8062e5b7f752031", + "reference": "aa3bcf4f7674719df078e61cc8062e5b7f752031", "shasum": "" }, "require": { @@ -9402,7 +9402,7 @@ "description": "Provides tools to manage errors and ease debugging PHP code", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/error-handler/tree/v6.4.19" + "source": "https://github.com/symfony/error-handler/tree/v6.4.20" }, "funding": [ { @@ -9418,7 +9418,7 @@ "type": "tidelift" } ], - "time": "2025-02-02T20:16:33+00:00" + "time": "2025-03-01T13:00:38+00:00" }, { "name": "symfony/event-dispatcher", @@ -9772,16 +9772,16 @@ }, { "name": "symfony/flex", - "version": "v1.21.8", + "version": "v1.22.0", "source": { "type": "git", "url": "https://github.com/symfony/flex.git", - "reference": "bda5f869ac51c8e985a6fe9f964c4cb78228a369" + "reference": "5cc985971b1a700cb74bedd9e01cfa93eb4747f7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/flex/zipball/bda5f869ac51c8e985a6fe9f964c4cb78228a369", - "reference": "bda5f869ac51c8e985a6fe9f964c4cb78228a369", + "url": "https://api.github.com/repos/symfony/flex/zipball/5cc985971b1a700cb74bedd9e01cfa93eb4747f7", + "reference": "5cc985971b1a700cb74bedd9e01cfa93eb4747f7", "shasum": "" }, "require": { @@ -9820,7 +9820,7 @@ "description": "Composer plugin for Symfony", "support": { "issues": "https://github.com/symfony/flex/issues", - "source": "https://github.com/symfony/flex/tree/v1.21.8" + "source": "https://github.com/symfony/flex/tree/v1.22.0" }, "funding": [ { @@ -9836,20 +9836,20 @@ "type": "tidelift" } ], - "time": "2024-10-07T08:51:39+00:00" + "time": "2025-03-03T07:50:24+00:00" }, { "name": "symfony/form", - "version": "v6.4.13", + "version": "v6.4.20", "source": { "type": "git", "url": "https://github.com/symfony/form.git", - "reference": "0fe17f90af23908ddc11dc23507db98e66572046" + "reference": "3929e2a60a828f39df6765fb49d224cc629fa529" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/form/zipball/0fe17f90af23908ddc11dc23507db98e66572046", - "reference": "0fe17f90af23908ddc11dc23507db98e66572046", + "url": "https://api.github.com/repos/symfony/form/zipball/3929e2a60a828f39df6765fb49d224cc629fa529", + "reference": "3929e2a60a828f39df6765fb49d224cc629fa529", "shasum": "" }, "require": { @@ -9917,7 +9917,7 @@ "description": "Allows to easily create, process and reuse HTML forms", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/form/tree/v6.4.13" + "source": "https://github.com/symfony/form/tree/v6.4.20" }, "funding": [ { @@ -9933,20 +9933,20 @@ "type": "tidelift" } ], - "time": "2024-10-09T08:40:40+00:00" + "time": "2025-03-27T10:21:45+00:00" }, { "name": "symfony/framework-bundle", - "version": "v6.4.19", + "version": "v6.4.20", "source": { "type": "git", "url": "https://github.com/symfony/framework-bundle.git", - "reference": "078a6f11cb34d208d6efc74003d77f66a09fa3c2" + "reference": "51418a20079cb25af3fcb8fa8ae1ed82f7fdd1ce" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/framework-bundle/zipball/078a6f11cb34d208d6efc74003d77f66a09fa3c2", - "reference": "078a6f11cb34d208d6efc74003d77f66a09fa3c2", + "url": "https://api.github.com/repos/symfony/framework-bundle/zipball/51418a20079cb25af3fcb8fa8ae1ed82f7fdd1ce", + "reference": "51418a20079cb25af3fcb8fa8ae1ed82f7fdd1ce", "shasum": "" }, "require": { @@ -10066,7 +10066,7 @@ "description": "Provides a tight integration between Symfony components and the Symfony full-stack framework", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/framework-bundle/tree/v6.4.19" + "source": "https://github.com/symfony/framework-bundle/tree/v6.4.20" }, "funding": [ { @@ -10082,7 +10082,7 @@ "type": "tidelift" } ], - "time": "2025-02-26T07:27:07+00:00" + "time": "2025-03-23T16:46:24+00:00" }, { "name": "symfony/http-client", @@ -10334,16 +10334,16 @@ }, { "name": "symfony/http-kernel", - "version": "v6.4.19", + "version": "v6.4.20", "source": { "type": "git", "url": "https://github.com/symfony/http-kernel.git", - "reference": "88f2c9f7feff86bb7b9105c5151bc2c1404cd64c" + "reference": "6be6db31bc74693ce5516e1fd5e5ff1171005e37" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-kernel/zipball/88f2c9f7feff86bb7b9105c5151bc2c1404cd64c", - "reference": "88f2c9f7feff86bb7b9105c5151bc2c1404cd64c", + "url": "https://api.github.com/repos/symfony/http-kernel/zipball/6be6db31bc74693ce5516e1fd5e5ff1171005e37", + "reference": "6be6db31bc74693ce5516e1fd5e5ff1171005e37", "shasum": "" }, "require": { @@ -10428,7 +10428,7 @@ "description": "Provides a structured process for converting a Request into a Response", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/http-kernel/tree/v6.4.19" + "source": "https://github.com/symfony/http-kernel/tree/v6.4.20" }, "funding": [ { @@ -10444,7 +10444,7 @@ "type": "tidelift" } ], - "time": "2025-02-26T10:51:37+00:00" + "time": "2025-03-28T13:27:10+00:00" }, { "name": "symfony/intl", @@ -11854,17 +11854,93 @@ "time": "2024-09-09T11:45:10+00:00" }, { - "name": "symfony/process", - "version": "v6.4.19", + "name": "symfony/polyfill-php84", + "version": "v1.31.0", "source": { "type": "git", - "url": "https://github.com/symfony/process.git", - "reference": "7a1c12e87b08ec9c97abdd188c9b3f5a40e37fc3" + "url": "https://github.com/symfony/polyfill-php84.git", + "reference": "e5493eb51311ab0b1cc2243416613f06ed8f18bd" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/process/zipball/7a1c12e87b08ec9c97abdd188c9b3f5a40e37fc3", - "reference": "7a1c12e87b08ec9c97abdd188c9b3f5a40e37fc3", + "url": "https://api.github.com/repos/symfony/polyfill-php84/zipball/e5493eb51311ab0b1cc2243416613f06ed8f18bd", + "reference": "e5493eb51311ab0b1cc2243416613f06ed8f18bd", + "shasum": "" + }, + "require": { + "php": ">=7.2" + }, + "type": "library", + "extra": { + "thanks": { + "url": "https://github.com/symfony/polyfill", + "name": "symfony/polyfill" + } + }, + "autoload": { + "files": [ + "bootstrap.php" + ], + "psr-4": { + "Symfony\\Polyfill\\Php84\\": "" + }, + "classmap": [ + "Resources/stubs" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill backporting some PHP 8.4+ features to lower PHP versions", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "polyfill", + "portable", + "shim" + ], + "support": { + "source": "https://github.com/symfony/polyfill-php84/tree/v1.31.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-09-09T12:04:04+00:00" + }, + { + "name": "symfony/process", + "version": "v6.4.20", + "source": { + "type": "git", + "url": "https://github.com/symfony/process.git", + "reference": "e2a61c16af36c9a07e5c9906498b73e091949a20" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/process/zipball/e2a61c16af36c9a07e5c9906498b73e091949a20", + "reference": "e2a61c16af36c9a07e5c9906498b73e091949a20", "shasum": "" }, "require": { @@ -11896,7 +11972,7 @@ "description": "Executes commands in sub-processes", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/process/tree/v6.4.19" + "source": "https://github.com/symfony/process/tree/v6.4.20" }, "funding": [ { @@ -11912,7 +11988,7 @@ "type": "tidelift" } ], - "time": "2025-02-04T13:35:48+00:00" + "time": "2025-03-10T17:11:00+00:00" }, { "name": "symfony/property-access", @@ -13237,16 +13313,16 @@ }, { "name": "symfony/twig-bridge", - "version": "v6.4.19", + "version": "v6.4.20", "source": { "type": "git", "url": "https://github.com/symfony/twig-bridge.git", - "reference": "d6aecb7196bf610e63ebb64f937c33878d5d03b1" + "reference": "bb423dfaa51b6d88b1d64197ae695a0c8ac73778" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/twig-bridge/zipball/d6aecb7196bf610e63ebb64f937c33878d5d03b1", - "reference": "d6aecb7196bf610e63ebb64f937c33878d5d03b1", + "url": "https://api.github.com/repos/symfony/twig-bridge/zipball/bb423dfaa51b6d88b1d64197ae695a0c8ac73778", + "reference": "bb423dfaa51b6d88b1d64197ae695a0c8ac73778", "shasum": "" }, "require": { @@ -13277,7 +13353,7 @@ "symfony/dependency-injection": "^5.4|^6.0|^7.0", "symfony/expression-language": "^5.4|^6.0|^7.0", "symfony/finder": "^5.4|^6.0|^7.0", - "symfony/form": "^6.4|^7.0", + "symfony/form": "^6.4.20|^7.2.5", "symfony/html-sanitizer": "^6.1|^7.0", "symfony/http-foundation": "^5.4|^6.0|^7.0", "symfony/http-kernel": "^6.4|^7.0", @@ -13326,7 +13402,7 @@ "description": "Provides integration for Twig with various Symfony components", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/twig-bridge/tree/v6.4.19" + "source": "https://github.com/symfony/twig-bridge/tree/v6.4.20" }, "funding": [ { @@ -13342,7 +13418,7 @@ "type": "tidelift" } ], - "time": "2025-02-14T09:54:06+00:00" + "time": "2025-03-28T13:08:36+00:00" }, { "name": "symfony/twig-bundle", @@ -13776,17 +13852,97 @@ "time": "2025-01-25T02:19:26+00:00" }, { - "name": "symfony/validator", - "version": "v6.4.19", + "name": "symfony/ux-vue", + "version": "v2.23.0", "source": { "type": "git", - "url": "https://github.com/symfony/validator.git", - "reference": "f3e853dffe7c5db675686b8216d6d890dad8c885" + "url": "https://github.com/symfony/ux-vue.git", + "reference": "d96995ea2214591114c7f76e807ae0ce34b439a5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/validator/zipball/f3e853dffe7c5db675686b8216d6d890dad8c885", - "reference": "f3e853dffe7c5db675686b8216d6d890dad8c885", + "url": "https://api.github.com/repos/symfony/ux-vue/zipball/d96995ea2214591114c7f76e807ae0ce34b439a5", + "reference": "d96995ea2214591114c7f76e807ae0ce34b439a5", + "shasum": "" + }, + "require": { + "php": ">=8.1", + "symfony/stimulus-bundle": "^2.9.1" + }, + "require-dev": { + "symfony/asset-mapper": "^6.3|^7.0", + "symfony/finder": "^5.4|^6.0|^7.0", + "symfony/framework-bundle": "^5.4|^6.0|^7.0", + "symfony/phpunit-bridge": "^5.4|^6.0|^7.0", + "symfony/twig-bundle": "^5.4|^6.0|^7.0", + "symfony/var-dumper": "^5.4|^6.0|^7.0" + }, + "type": "symfony-bundle", + "extra": { + "thanks": { + "url": "https://github.com/symfony/ux", + "name": "symfony/ux" + } + }, + "autoload": { + "psr-4": { + "Symfony\\UX\\Vue\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Titouan Galopin", + "email": "galopintitouan@gmail.com" + }, + { + "name": "Thibault Richard", + "email": "thibault.richard62@gmail.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Integration of Vue.js in Symfony", + "homepage": "https://symfony.com", + "keywords": [ + "symfony-ux" + ], + "support": { + "source": "https://github.com/symfony/ux-vue/tree/v2.23.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-12-05T14:25:02+00:00" + }, + { + "name": "symfony/validator", + "version": "v6.4.20", + "source": { + "type": "git", + "url": "https://github.com/symfony/validator.git", + "reference": "9314555aceb8d8ce8abda81e1e47e439258d9309" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/validator/zipball/9314555aceb8d8ce8abda81e1e47e439258d9309", + "reference": "9314555aceb8d8ce8abda81e1e47e439258d9309", "shasum": "" }, "require": { @@ -13854,7 +14010,7 @@ "description": "Provides tools to validate values", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/validator/tree/v6.4.19" + "source": "https://github.com/symfony/validator/tree/v6.4.20" }, "funding": [ { @@ -13870,7 +14026,7 @@ "type": "tidelift" } ], - "time": "2025-02-19T13:12:02+00:00" + "time": "2025-03-14T14:22:58+00:00" }, { "name": "symfony/var-dumper", @@ -13959,16 +14115,16 @@ }, { "name": "symfony/var-exporter", - "version": "v6.4.19", + "version": "v6.4.20", "source": { "type": "git", "url": "https://github.com/symfony/var-exporter.git", - "reference": "be6e71b0c257884c1107313de5d247741cfea172" + "reference": "998df255e9e6a15a36ae35e9c6cd818c17cf92a2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/var-exporter/zipball/be6e71b0c257884c1107313de5d247741cfea172", - "reference": "be6e71b0c257884c1107313de5d247741cfea172", + "url": "https://api.github.com/repos/symfony/var-exporter/zipball/998df255e9e6a15a36ae35e9c6cd818c17cf92a2", + "reference": "998df255e9e6a15a36ae35e9c6cd818c17cf92a2", "shasum": "" }, "require": { @@ -14016,7 +14172,7 @@ "serialize" ], "support": { - "source": "https://github.com/symfony/var-exporter/tree/v6.4.19" + "source": "https://github.com/symfony/var-exporter/tree/v6.4.20" }, "funding": [ { @@ -14032,7 +14188,7 @@ "type": "tidelift" } ], - "time": "2025-02-13T09:33:32+00:00" + "time": "2025-03-13T09:55:08+00:00" }, { "name": "symfony/web-link", @@ -14119,16 +14275,16 @@ }, { "name": "symfony/yaml", - "version": "v6.4.18", + "version": "v6.4.20", "source": { "type": "git", "url": "https://github.com/symfony/yaml.git", - "reference": "bf598c9d9bb4a22f495a4e26e4c4fce2f8ecefc5" + "reference": "28ee818fce4a73ac1474346b94e4b966f665c53f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/yaml/zipball/bf598c9d9bb4a22f495a4e26e4c4fce2f8ecefc5", - "reference": "bf598c9d9bb4a22f495a4e26e4c4fce2f8ecefc5", + "url": "https://api.github.com/repos/symfony/yaml/zipball/28ee818fce4a73ac1474346b94e4b966f665c53f", + "reference": "28ee818fce4a73ac1474346b94e4b966f665c53f", "shasum": "" }, "require": { @@ -14171,7 +14327,7 @@ "description": "Loads and dumps YAML files", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/yaml/tree/v6.4.18" + "source": "https://github.com/symfony/yaml/tree/v6.4.20" }, "funding": [ { @@ -14187,7 +14343,7 @@ "type": "tidelift" } ], - "time": "2025-01-07T09:44:41+00:00" + "time": "2025-02-27T20:15:30+00:00" }, { "name": "symfonycasts/dynamic-forms", @@ -15811,16 +15967,16 @@ }, { "name": "phpstan/phpstan", - "version": "1.12.19", + "version": "1.12.23", "source": { "type": "git", "url": "https://github.com/phpstan/phpstan.git", - "reference": "c42ba9bab7a940ed00092ecb1c77bad98896d789" + "reference": "29201e7a743a6ab36f91394eab51889a82631428" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpstan/phpstan/zipball/c42ba9bab7a940ed00092ecb1c77bad98896d789", - "reference": "c42ba9bab7a940ed00092ecb1c77bad98896d789", + "url": "https://api.github.com/repos/phpstan/phpstan/zipball/29201e7a743a6ab36f91394eab51889a82631428", + "reference": "29201e7a743a6ab36f91394eab51889a82631428", "shasum": "" }, "require": { @@ -15865,7 +16021,7 @@ "type": "github" } ], - "time": "2025-02-19T15:42:21+00:00" + "time": "2025-03-23T14:57:32+00:00" }, { "name": "phpunit/php-code-coverage", @@ -17309,16 +17465,16 @@ }, { "name": "squizlabs/php_codesniffer", - "version": "3.11.3", + "version": "3.12.0", "source": { "type": "git", "url": "https://github.com/PHPCSStandards/PHP_CodeSniffer.git", - "reference": "ba05f990e79cbe69b9f35c8c1ac8dca7eecc3a10" + "reference": "2d1b63db139c3c6ea0c927698e5160f8b3b8d630" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/PHPCSStandards/PHP_CodeSniffer/zipball/ba05f990e79cbe69b9f35c8c1ac8dca7eecc3a10", - "reference": "ba05f990e79cbe69b9f35c8c1ac8dca7eecc3a10", + "url": "https://api.github.com/repos/PHPCSStandards/PHP_CodeSniffer/zipball/2d1b63db139c3c6ea0c927698e5160f8b3b8d630", + "reference": "2d1b63db139c3c6ea0c927698e5160f8b3b8d630", "shasum": "" }, "require": { @@ -17385,11 +17541,11 @@ "type": "open_collective" }, { - "url": "https://thanks.dev/phpcsstandards", + "url": "https://thanks.dev/u/gh/phpcsstandards", "type": "thanks_dev" } ], - "time": "2025-01-23T17:04:15+00:00" + "time": "2025-03-18T05:04:51+00:00" }, { "name": "symfony/browser-kit", @@ -17837,82 +17993,6 @@ ], "time": "2023-01-01T08:36:10+00:00" }, - { - "name": "symfony/polyfill-php84", - "version": "v1.31.0", - "source": { - "type": "git", - "url": "https://github.com/symfony/polyfill-php84.git", - "reference": "e5493eb51311ab0b1cc2243416613f06ed8f18bd" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php84/zipball/e5493eb51311ab0b1cc2243416613f06ed8f18bd", - "reference": "e5493eb51311ab0b1cc2243416613f06ed8f18bd", - "shasum": "" - }, - "require": { - "php": ">=7.2" - }, - "type": "library", - "extra": { - "thanks": { - "url": "https://github.com/symfony/polyfill", - "name": "symfony/polyfill" - } - }, - "autoload": { - "files": [ - "bootstrap.php" - ], - "psr-4": { - "Symfony\\Polyfill\\Php84\\": "" - }, - "classmap": [ - "Resources/stubs" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony polyfill backporting some PHP 8.4+ features to lower PHP versions", - "homepage": "https://symfony.com", - "keywords": [ - "compatibility", - "polyfill", - "portable", - "shim" - ], - "support": { - "source": "https://github.com/symfony/polyfill-php84/tree/v1.31.0" - }, - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], - "time": "2024-09-09T12:04:04+00:00" - }, { "name": "symfony/stopwatch", "version": "v6.4.19", diff --git a/src/new/config/bundles.php b/src/new/config/bundles.php index 71fcf58db..aa4ee9e65 100755 --- a/src/new/config/bundles.php +++ b/src/new/config/bundles.php @@ -62,5 +62,6 @@ return [ Symfony\UX\Chartjs\ChartjsBundle::class => ['all' => true], Symfonycasts\TailwindBundle\SymfonycastsTailwindBundle::class => ['all' => true], Symfonycasts\SassBundle\SymfonycastsSassBundle::class => ['all' => true], - Dunglas\DoctrineJsonOdm\Bundle\DunglasDoctrineJsonOdmBundle::class => ['all' => true] + Dunglas\DoctrineJsonOdm\Bundle\DunglasDoctrineJsonOdmBundle::class => ['all' => true], + Symfony\UX\Vue\VueBundle::class => ['all' => true], ]; diff --git a/src/new/importmap.php b/src/new/importmap.php index 5a2ad0998..9d128c252 100644 --- a/src/new/importmap.php +++ b/src/new/importmap.php @@ -334,4 +334,52 @@ return [ 'version' => '3.1.2', 'type' => 'css', ], + 'vue' => [ + 'version' => '3.5.13', + ], + '@vue/runtime-dom' => [ + 'version' => '3.5.13', + ], + '@vue/compiler-dom' => [ + 'version' => '3.5.13', + ], + '@vue/shared' => [ + 'version' => '3.5.13', + ], + '@vue/runtime-core' => [ + 'version' => '3.5.13', + ], + '@vue/compiler-core' => [ + 'version' => '3.5.13', + ], + '@vue/reactivity' => [ + 'version' => '3.5.13', + ], + '@symfony/ux-vue' => [ + 'path' => './vendor/symfony/ux-vue/assets/dist/loader.js', + ], + 'pinia' => [ + 'version' => '3.0.1', + ], + '@vue/devtools-api' => [ + 'version' => '7.7.2', + ], + '@vue/devtools-kit' => [ + 'version' => '7.7.2', + ], + '@vue/devtools-shared' => [ + 'version' => '7.7.2', + ], + 'perfect-debounce' => [ + 'version' => '1.0.0', + ], + 'hookable' => [ + 'version' => '5.5.3', + ], + 'birpc' => [ + 'version' => '0.2.19', + ], + 'splitpanes' => [ + 'version' => '4.0.3', + ], ]; diff --git a/src/new/src/PSC/Shop/EntityBundle/Document/Product.php b/src/new/src/PSC/Shop/EntityBundle/Document/Product.php index 40db74227..3b33263a9 100755 --- a/src/new/src/PSC/Shop/EntityBundle/Document/Product.php +++ b/src/new/src/PSC/Shop/EntityBundle/Document/Product.php @@ -32,6 +32,9 @@ class Product #[Field(type: 'string')] protected $ansprechPartner; + #[Field(type: 'boolean')] + protected bool $rawText = false; + /** * @var \DateTime $ablaufDatum; */ @@ -250,7 +253,6 @@ class Product /** * @var boolean $uploadFromLatestOrder; - * */ #[Field(type: 'bool')] protected $uploadFromLatestOrder; @@ -263,7 +265,6 @@ class Product /** * @var boolean $uploadProvided; - * */ #[Field(type: 'bool')] protected $uploadProvided; @@ -274,7 +275,6 @@ class Product /** * @var string $uploadProvidedFile; - * */ #[Field(type: 'string')] protected $uploadProvidedFile; @@ -1021,4 +1021,14 @@ class Product { $this->uploadProvidedDownload = $uploadProvidedDownload; } + + public function isRawText(): bool + { + return (bool)$this->rawText; + } + + public function setRawText(bool $var): void + { + $this->rawText = $var; + } } diff --git a/src/new/src/PSC/Shop/EntityBundle/Entity/Product.php b/src/new/src/PSC/Shop/EntityBundle/Entity/Product.php index e3f8eeeb0..7c50e26a7 100755 --- a/src/new/src/PSC/Shop/EntityBundle/Entity/Product.php +++ b/src/new/src/PSC/Shop/EntityBundle/Entity/Product.php @@ -52,6 +52,7 @@ class Product protected $extraSettings; protected $availability; protected $weight; + protected $rawText = false; protected $text; /** * @var integer @@ -3132,4 +3133,13 @@ class Product { $this->noIndex = $noIndex; } + public function isRawText(): bool + { + return (bool)$this->rawText; + } + + public function setRawText(bool $rawText): void + { + $this->rawText = $rawText; + } } diff --git a/src/new/src/PSC/Shop/NewsBundle/Resources/views/components/NewsForm.html.twig b/src/new/src/PSC/Shop/NewsBundle/Resources/views/components/NewsForm.html.twig index 4aa1da9c0..eab687ebc 100644 --- a/src/new/src/PSC/Shop/NewsBundle/Resources/views/components/NewsForm.html.twig +++ b/src/new/src/PSC/Shop/NewsBundle/Resources/views/components/NewsForm.html.twig @@ -65,6 +65,9 @@
+
+ Loading... +
{{ form_row(form.introduction)}}
diff --git a/src/new/src/PSC/Shop/ProductBundle/Controller/Backend/Product/EditController.php b/src/new/src/PSC/Shop/ProductBundle/Controller/Backend/Product/EditController.php index ba140f7a7..64dc2e740 100755 --- a/src/new/src/PSC/Shop/ProductBundle/Controller/Backend/Product/EditController.php +++ b/src/new/src/PSC/Shop/ProductBundle/Controller/Backend/Product/EditController.php @@ -95,9 +95,9 @@ class EditController extends AbstractController /** * edit * - * @param Request $request - * @param EntityManagerInterface $entityManager - * @param $uid + * @param Request $request + * @param EntityManagerInterface $entityManager + * @param $uid * @return JsonResponse */ #[Route(path: '/edit/add/lang/data/{uid}', name: 'backend_production_product_edit_add_lang_data')] @@ -124,9 +124,9 @@ class EditController extends AbstractController /** * edit * - * @param Request $request - * @param EntityManagerInterface $entityManager - * @param $uid + * @param Request $request + * @param EntityManagerInterface $entityManager + * @param $uid * @return JsonResponse */ #[Route(path: '/edit/fetch/lang/data/{uid}', name: 'backend_production_product_edit_fetch_lang_data')] @@ -158,17 +158,19 @@ class EditController extends AbstractController /** * edit * - * @param Request $request - * @param EntityManagerInterface $entityManager - * @param \PSC\System\SettingsBundle\Service\Shop $shopService - * @param $url + * @param Request $request + * @param EntityManagerInterface $entityManager + * @param \PSC\System\SettingsBundle\Service\Shop $shopService + * @param $url * @return JsonResponse * @throws \Doctrine\ORM\ORMException */ #[Route(path: '/edit/check/url/{url}', name: 'backend_production_product_check_url')] public function checkUrlAction(Request $request, EntityManagerInterface $entityManager, \PSC\System\SettingsBundle\Service\Shop $shopService, $url) { - /** @var \PSC\Shop\EntityBundle\Entity\Shop $selectedShop */ + /** + * @var \PSC\Shop\EntityBundle\Entity\Shop $selectedShop +*/ $selectedShop = $shopService->getSelectedShop(); $products = $entityManager @@ -176,7 +178,9 @@ class EditController extends AbstractController if (count($products) > 0) { $tmp = array(); - /** @var Product $product */ + /** + * @var Product $product +*/ foreach ($products as $product) { $tmp[] = $product->getTitle(); } @@ -191,13 +195,13 @@ class EditController extends AbstractController * * @template() * - * @param Request $request Request - * @param Field $fieldService - * @param EntityManagerInterface $entityManager - * @param \PSC\System\SettingsBundle\Service\Shop $shopService - * @param DocumentManager $documentManager - * @param SessionInterface $session - * @param $type + * @param Request $request Request + * @param Field $fieldService + * @param EntityManagerInterface $entityManager + * @param \PSC\System\SettingsBundle\Service\Shop $shopService + * @param DocumentManager $documentManager + * @param SessionInterface $session + * @param $type * @return array|\Symfony\Component\HttpFoundation\RedirectResponse * @throws \Doctrine\ODM\MongoDB\MongoDBException * @throws \Doctrine\ORM\ORMException @@ -215,10 +219,14 @@ class EditController extends AbstractController $customFields = $fieldService->getFields(\PSC\System\PluginBundle\Form\Interfaces\Field::Product); $customGroups = $fieldService->getGroups(\PSC\System\PluginBundle\Form\Interfaces\Field::Product); - /** @var \PSC\Shop\EntityBundle\Entity\Shop $selectedShop */ + /** + * @var \PSC\Shop\EntityBundle\Entity\Shop $selectedShop +*/ $selectedShop = $shopService->getSelectedShop(); - /** @var Shop $shop */ + /** + * @var Shop $shop +*/ $shop = $documentManager ->getRepository('PSC\Shop\EntityBundle\Document\Shop') ->findOneBy(array('uid' => (string) $selectedShop->getUid())); @@ -229,7 +237,9 @@ class EditController extends AbstractController $customProductFields = $fieldService->getProductFields(\PSC\System\PluginBundle\Form\Interfaces\Field::Product, $type); $customProductGroups = $fieldService->getProductGroups(\PSC\System\PluginBundle\Form\Interfaces\Field::Product, $type); - /** @var Domain[] $domains */ + /** + * @var Domain[] $domains +*/ $domains = $entityManager ->getRepository('PSC\Shop\EntityBundle\Entity\Domain')->getAllByShopId($selectedShop); @@ -290,6 +300,7 @@ class EditController extends AbstractController $productDoc->setCustomTabEnable($product->isCustomTabEnable()); $productDoc->setHintEnable($product->isHintEnable()); $productDoc->setAsRequest($product->isAsRequest()); + $productDoc->setRawText($product->isRawText()); $documentManager->persist($productDoc); $documentManager->flush(); @@ -321,16 +332,16 @@ class EditController extends AbstractController * * @template() * - * @param Request $request Request - * @param Field $fieldService - * @param EntityManagerInterface $entityManager - * @param DocumentManager $documentManager - * @param PaginatorInterface $paginator - * @param SessionInterface $session + * @param Request $request Request + * @param Field $fieldService + * @param EntityManagerInterface $entityManager + * @param DocumentManager $documentManager + * @param PaginatorInterface $paginator + * @param SessionInterface $session * @param \PSC\System\SettingsBundle\Service\Shop $shopService - * @param Status $statusService - * @param \PSC\Shop\OrderBundle\Service\Order $orderService - * @param string $uuid Uuid + * @param Status $statusService + * @param \PSC\Shop\OrderBundle\Service\Order $orderService + * @param string $uuid Uuid * * @return array * @throws \Doctrine\ODM\MongoDB\MongoDBException @@ -352,19 +363,27 @@ class EditController extends AbstractController $customFields = $fieldService->getFields(\PSC\System\PluginBundle\Form\Interfaces\Field::Product); $customGroups = $fieldService->getGroups(\PSC\System\PluginBundle\Form\Interfaces\Field::Product); - /** @var \PSC\Shop\EntityBundle\Entity\Shop $selectedShop */ + /** + * @var \PSC\Shop\EntityBundle\Entity\Shop $selectedShop +*/ $selectedShop = $shopService->getSelectedShop(); - /** @var Shop $shop */ + /** + * @var Shop $shop +*/ $shop = $documentManager ->getRepository('PSC\Shop\EntityBundle\Document\Shop') ->findOneBy(array('uid' => (string) $selectedShop->getUid())); - /** @var Product $product */ + /** + * @var Product $product +*/ $product = $entityManager ->getRepository('PSC\Shop\EntityBundle\Entity\Product')->findOneBy(array('uuid' => $uuid, 'shop' => $selectedShop)); - /** @var \PSC\Shop\EntityBundle\Document\Product $productDoc */ + /** + * @var \PSC\Shop\EntityBundle\Document\Product $productDoc +*/ $productDoc = $documentManager ->getRepository('PSC\Shop\EntityBundle\Document\Product') ->findOneBy(array('uid' => (string) $product->getUid())); @@ -422,6 +441,7 @@ class EditController extends AbstractController $product->setCustomTabEnable($productDoc->isCustomTabEnable()); $product->setHintEnable($productDoc->isHintEnable()); $product->setAsRequest($productDoc->isAsRequest()); + $product->setRawText($productDoc->isRawText()); } elseif (!$productDoc) { $productDoc = new \PSC\Shop\EntityBundle\Document\Product(); $productDoc->setAblaufDatum($product->getAblaufDatum()); @@ -468,6 +488,7 @@ class EditController extends AbstractController $productDoc->setHintEnable($product->isHintEnable()); $productDoc->setAsRequest($product->isAsRequest()); $productDoc->setNoIndex($product->isNoIndex()); + $productDoc->setRawText($product->isRawText()); $documentManager->persist($productDoc); $documentManager->flush(); @@ -515,6 +536,7 @@ class EditController extends AbstractController $product->setCustomTabEnable($productDoc->isCustomTabEnable()); $product->setHintEnable($productDoc->isHintEnable()); $product->setAsRequest($productDoc->isAsRequest()); + $product->setRawText($productDoc->isRawText()); } if ($request->isMethod('POST') && $productDoc) { @@ -568,6 +590,7 @@ class EditController extends AbstractController $productDoc->setCustomTabEnable($product->isCustomTabEnable()); $productDoc->setHintEnable($product->isHintEnable()); $productDoc->setAsRequest($product->isAsRequest()); + $productDoc->setRawText($product->isRawText()); $this->historyService->createHistoryEntry(new PSCHistory((string)$product->getUID()), $product, $productDoc); $entityManager->persist($product); @@ -583,7 +606,9 @@ class EditController extends AbstractController $this->logService->createLogEntry($selectedShop, $this->getUser(), LogEntry::INFO, PSCShopProductBundle::class, $product->getTitle(), "Product has been updated"); } - /** @var Domain[] $domains */ + /** + * @var Domain[] $domains +*/ $domains = $entityManager ->getRepository('PSC\Shop\EntityBundle\Entity\Domain')->getAllByShopId($selectedShop); @@ -645,11 +670,11 @@ class EditController extends AbstractController } /** - * @param Request $request - * @param \PSC\System\SettingsBundle\Service\Shop $shopService - * @param EntityManagerInterface $entityManager - * @param SessionInterface $session - * @param $uuid + * @param Request $request + * @param \PSC\System\SettingsBundle\Service\Shop $shopService + * @param EntityManagerInterface $entityManager + * @param SessionInterface $session + * @param $uuid * @return array|Response|\Symfony\Component\HttpFoundation\RedirectResponse * @throws \Doctrine\ORM\ORMException */ @@ -663,10 +688,14 @@ class EditController extends AbstractController SessionInterface $session, $uuid ) { - /** @var \PSC\Shop\EntityBundle\Entity\Shop $selectedShop */ + /** + * @var \PSC\Shop\EntityBundle\Entity\Shop $selectedShop +*/ $selectedShop = $shopService->getSelectedShop(); - /** @var Product $product */ + /** + * @var Product $product +*/ $product = $entityManager ->getRepository('PSC\Shop\EntityBundle\Entity\Product')->findOneBy(array('uuid' => $uuid, 'shop' => $selectedShop)); @@ -706,12 +735,11 @@ class EditController extends AbstractController /** * Copy Seite * - * - * @param Request $request - * @param \PSC\System\SettingsBundle\Service\Shop $shopService - * @param \PSC\Shop\ProductBundle\Service\Product $productService - * @param EntityManagerInterface $entityManager - * @param $uuid + * @param Request $request + * @param \PSC\System\SettingsBundle\Service\Shop $shopService + * @param \PSC\Shop\ProductBundle\Service\Product $productService + * @param EntityManagerInterface $entityManager + * @param $uuid * @return array|\Symfony\Component\HttpFoundation\RedirectResponse * @throws \Doctrine\ORM\ORMException * @throws \Doctrine\ORM\OptimisticLockException @@ -723,10 +751,14 @@ class EditController extends AbstractController $obj = ['which' => 1]; - /** @var \PSC\Shop\EntityBundle\Entity\Shop $selectedShop */ + /** + * @var \PSC\Shop\EntityBundle\Entity\Shop $selectedShop +*/ $selectedShop = $shopService->getSelectedShop(); - /** @var Product $product */ + /** + * @var Product $product +*/ $product = $entityManager ->getRepository('PSC\Shop\EntityBundle\Entity\Product')->findOneBy(array('uuid' => $uuid, 'shop' => $selectedShop)); diff --git a/src/new/src/PSC/Shop/ProductBundle/Form/Backend/Product/ProductType.php b/src/new/src/PSC/Shop/ProductBundle/Form/Backend/Product/ProductType.php index 8b9a4c58a..b0285c5ba 100755 --- a/src/new/src/PSC/Shop/ProductBundle/Form/Backend/Product/ProductType.php +++ b/src/new/src/PSC/Shop/ProductBundle/Form/Backend/Product/ProductType.php @@ -16,6 +16,7 @@ namespace PSC\Shop\ProductBundle\Form\Backend\Product; use Doctrine\ORM\EntityManagerInterface; use Doctrine\ORM\EntityRepository; use PSC\Backend\DashboardBundle\Form\Type\DatePickerType; +use PSC\Libraries\AceEditorBundle\Form\Extension\AceEditorType; use PSC\Shop\EntityBundle\Entity\Productgroup; use PSC\Shop\MediaBundle\Form\Type\MediaType; use PSC\System\PluginBundle\Form\Chain\Field; @@ -42,10 +43,14 @@ use Symfony\Component\OptionsResolver\OptionsResolver; class ProductType extends AbstractType { protected $shop = null; - /** @var Status */ + /** + * @var Status + */ protected $statusService = null; - /** @var Field */ + /** + * @var Field + */ protected $fields; protected $formFactory; @@ -88,6 +93,7 @@ class ProductType extends AbstractType ->add('title', TextType::class) ->add('subTitle', TextType::class, ['required' => false, 'label' => 'subTitle']) ->add('createdAt', DatePickerType::class, array('disabled' => true)) + ->add('rawText', CheckboxType::class, ['label' => 'rawText', 'required' => false]) ->add('image1', MediaType::class, array()) ->add('image2', MediaType::class, array()) ->add('image3', MediaType::class, array()) @@ -108,42 +114,94 @@ class ProductType extends AbstractType ->add('zusatzAbmessung', TextType::class, array('required' => false, 'label' => 'Additionaldimension')) ->add('zusatzDesigner', TextType::class, array('required' => false, 'label' => 'Additiondesigner')) ->add('zusatzShipping', TextType::class, array('required' => false, 'label' => 'Additionalshippinginformation')) - ->add('extraSettings', TextareaType::class, array('required' => false, 'label' => 'Extrasettings')) - ->add('description', TextareaType::class, array( + ->add('extraSettings', TextareaType::class, array('required' => false, 'label' => 'Extrasettings')); + + if ($options['data']->isRawText()) { + $builder->add( + 'description', AceEditorType::class, array( + 'label' => 'description', + 'wrapper_attr' => array(), // aceeditor wrapper html attributes. + 'width' => '90%', + 'height' => '500', + 'font_size' => 14, + 'mode' => 'ace/mode/html', // every single default mode must have ace/mode/* prefix + 'theme' => 'ace/theme/monokai', // every single default theme must have ace/theme/* prefix + 'tab_size' => null, + 'read_only' => null, + 'use_soft_tabs' => null, + 'use_wrap_mode' => null, + 'show_print_margin' => null, + 'required' => false, + 'highlight_active_line' => null + ) + ) + ->add( + 'text', AceEditorType::class, array( + 'label' => 'text', + 'wrapper_attr' => array(), // aceeditor wrapper html attributes. + 'width' => '90%', + 'height' => '500', + 'font_size' => 14, + 'mode' => 'ace/mode/html', // every single default mode must have ace/mode/* prefix + 'theme' => 'ace/theme/monokai', // every single default theme must have ace/theme/* prefix + 'tab_size' => null, + 'read_only' => null, + 'use_soft_tabs' => null, + 'use_wrap_mode' => null, + 'show_print_margin' => null, + 'required' => false, + 'highlight_active_line' => null + ) + ); + }else{ + $builder->add( + 'description', TextareaType::class, array( + 'label' => 'description', + 'required' => false + ) + ) + ->add( + 'text', TextareaType::class, array( + 'label' => 'Additionaldescription', + 'required' => false + ) + ); + } + + $builder->add( + 'hintText', TextareaType::class, array( 'label' => 'description', 'required' => false - )) - ->add('text', TextareaType::class, array( - 'label' => 'Additionaldescription', - 'required' => false - )) - ->add('hintText', TextareaType::class, array( - 'label' => 'description', - 'required' => false - )) - ->add('customTabEnable', CheckboxType::class, array('required' => false, 'label' => 'Active')) - ->add('customTabTitle', TextType::class, array('required' => false, 'label' => 'Tabname')) - ->add('customTabText', TextareaType::class, array( - 'label' => 'Tabtext', - 'required' => false - )) - ->add('product_groups', EntityType::class, array( - 'class' => 'PSC\Shop\EntityBundle\Entity\Productgroup', - 'choice_label' => function (Productgroup $choice, $key, $value) { - if ($choice->isEnable()) { - return $choice->getTitle(); - } else { - return $choice->getTitle() . ' (disabled)'; + ) + ) + ->add('customTabEnable', CheckboxType::class, array('required' => false, 'label' => 'Active')) + ->add('customTabTitle', TextType::class, array('required' => false, 'label' => 'Tabname')) + ->add( + 'customTabText', TextareaType::class, array( + 'label' => 'Tabtext', + 'required' => false + ) + ) + ->add( + 'product_groups', EntityType::class, array( + 'class' => 'PSC\Shop\EntityBundle\Entity\Productgroup', + 'choice_label' => function (Productgroup $choice, $key, $value) { + if ($choice->isEnable()) { + return $choice->getTitle(); + } else { + return $choice->getTitle() . ' (disabled)'; + } + }, + 'multiple' => true, + 'required' => false, + 'query_builder' => function (EntityRepository $er) { + return $er->createQueryBuilder('u') + ->where('u.shop = :shop')->setParameter('shop', $this->shop->getSelectedShop()->getId()); } - }, - 'multiple' => true, - 'required' => false, - 'query_builder' => function (EntityRepository $er) { - return $er->createQueryBuilder('u') - ->where('u.shop = :shop')->setParameter('shop', $this->shop->getSelectedShop()->getId()); - } - )) - ->add('releatedProducts', EntityType::class, array( + ) + ) + ->add( + 'releatedProducts', EntityType::class, array( 'class' => 'PSC\Shop\EntityBundle\Entity\Product', 'choice_label' => 'title', 'multiple' => true, @@ -152,8 +210,10 @@ class ProductType extends AbstractType return $er->createQueryBuilder('u') ->where('u.shop = :shop AND u.originalProduct = 0')->setParameter('shop', $this->shop->getSelectedShop()->getId()); } - )) - ->add('language', ChoiceType::class, array( + ) + ) + ->add( + 'language', ChoiceType::class, array( 'choices' => array( 'Alle' => 'all', 'de_DE' => 'de_DE', @@ -163,15 +223,18 @@ class ProductType extends AbstractType 'il_IL' => 'il_IL', ), 'label' => 'language' - )) - ->add('availability', ChoiceType::class, array( + ) + ) + ->add( + 'availability', ChoiceType::class, array( 'choices' => array( 'instock' => 'in_stock', 'outofstock' => 'out_of_stock', 'preorder' => 'preorder' ), 'label' => 'Availability' - )) + ) + ) ->add('videoId', TextType::class, ['required' => false, 'label' => 'VideoId']) ->add('metaKeywords', TextType::class, ['required' => false, 'label' => 'Keywords']) ->add('metaDescription', TextareaType::class, ['required' => false, 'label' => 'description']) @@ -206,111 +269,153 @@ class ProductType extends AbstractType ->add('custom11', TextType::class, ['required' => false, 'label' => 'Custom 11']) ->add('custom12', TextType::class, ['required' => false, 'label' => 'Custom 12']) ->add('uploadProduct', CheckboxType::class, ['required' => false, 'label' => 'Activate']) - ->add("uploadProductInitalStatus", ChoiceType::class, array( + ->add( + "uploadProductInitalStatus", ChoiceType::class, array( 'required' => true, 'label' => 'Initialstatus', 'choices' => $this->statusService->getPositionStatusAsArray(), 'translation_domain' => 'posstatus' - )) + ) + ) ->add('uploadFromLatestOrder', CheckboxType::class, ['required' => false, 'label' => 'Activate']) - ->add("uploadFromLatestOrderInitalStatus", ChoiceType::class, array( + ->add( + "uploadFromLatestOrderInitalStatus", ChoiceType::class, array( 'required' => true, 'label' => 'Initialstatus', 'choices' => $this->statusService->getPositionStatusAsArray(), 'translation_domain' => 'posstatus' - )) - ->add("initialStatus", ChoiceType::class, array( + ) + ) + ->add( + "initialStatus", ChoiceType::class, array( 'required' => true, 'label' => 'Masterinitialstatus', 'choices' => $this->statusService->getPositionStatusAsArray(), 'translation_domain' => 'posstatus' - )) + ) + ) ->add('uploadPost', CheckboxType::class, ['required' => false, 'label' => 'Activate']) - ->add("uploadPostInitalStatus", ChoiceType::class, array( + ->add( + "uploadPostInitalStatus", ChoiceType::class, array( 'required' => true, 'label' => 'Initialstatus', 'choices' => $this->statusService->getPositionStatusAsArray(), 'translation_domain' => 'posstatus' - )) + ) + ) ->add('uploadEmail', CheckboxType::class, ['required' => false, 'label' => 'Activate']) - ->add("uploadEmailInitalStatus", ChoiceType::class, array( + ->add( + "uploadEmailInitalStatus", ChoiceType::class, array( 'required' => true, 'label' => 'Initialstatus', 'choices' => $this->statusService->getPositionStatusAsArray(), 'translation_domain' => 'posstatus' - )) + ) + ) ->add('uploadProvided', CheckboxType::class, ['required' => false, 'label' => 'Activate']) ->add('uploadProvidedFile', MediaType::class, array('label' => 'Datei')) - ->add("uploadProvidedInitalStatus", ChoiceType::class, array( + ->add( + "uploadProvidedInitalStatus", ChoiceType::class, array( 'required' => true, 'label' => 'Initalstatus', 'choices' => $this->statusService->getPositionStatusAsArray(), 'translation_domain' => 'posstatus' - )) + ) + ) ->add('uploadProvidedDownload', CheckboxType::class, ['required' => false, 'label' => 'Download']) ->add('uploadCenter', CheckboxType::class, ['required' => false, 'label' => 'Activate']) - ->add("uploadCenterInitalStatus", ChoiceType::class, array( + ->add( + "uploadCenterInitalStatus", ChoiceType::class, array( 'required' => true, 'label' => 'Initialstatus', 'choices' => $this->statusService->getPositionStatusAsArray(), 'translation_domain' => 'posstatus' - )); + ) + ); - /** @var \PSC\System\PluginBundle\Form\Interfaces\Field $field */ + /** + * @var \PSC\System\PluginBundle\Form\Interfaces\Field $field +*/ foreach ($this->fields->getFields(\PSC\System\PluginBundle\Form\Interfaces\Field::Product) as $field) { $builder->add($field->buildForm($this->formFactory->createNamedBuilder($field->getGroup()), $options)); } - /** @var \PSC\System\PluginBundle\Form\Interfaces\Field $field */ + /** + * @var \PSC\System\PluginBundle\Form\Interfaces\Field $field +*/ foreach ($this->fields->getProductFields(\PSC\System\PluginBundle\Form\Interfaces\Field::Product, $options['productType']) as $field) { $builder->add($field->buildForm($this->formFactory->createNamedBuilder($field->getGroup()), $options)); } $builder->add('save', SubmitType::class, array('label' => 'save')); - $builder->addEventListener(FormEvents::PRE_SET_DATA, function (FormEvent $event) use ($options) { - /** @var \PSC\System\PluginBundle\Form\Interfaces\Field $field */ - foreach ($this->fields->getFields(\PSC\System\PluginBundle\Form\Interfaces\Field::Product) as $field) { - $field->formPreSetData($event); + $builder->addEventListener( + FormEvents::PRE_SET_DATA, function (FormEvent $event) use ($options) { + /** + * @var \PSC\System\PluginBundle\Form\Interfaces\Field $field + */ + foreach ($this->fields->getFields(\PSC\System\PluginBundle\Form\Interfaces\Field::Product) as $field) { + $field->formPreSetData($event); + } + /** + * @var \PSC\System\PluginBundle\Form\Interfaces\Field $field + */ + foreach ($this->fields->getProductFields(\PSC\System\PluginBundle\Form\Interfaces\Field::Product, $options['productType']) as $field) { + $field->formPreSetData($event); + } } - /** @var \PSC\System\PluginBundle\Form\Interfaces\Field $field */ - foreach ($this->fields->getProductFields(\PSC\System\PluginBundle\Form\Interfaces\Field::Product, $options['productType']) as $field) { - $field->formPreSetData($event); - } - }); + ); - $builder->addEventListener(FormEvents::POST_SET_DATA, function (FormEvent $event) use ($options) { - /** @var \PSC\System\PluginBundle\Form\Interfaces\Field $field */ - foreach ($this->fields->getFields(\PSC\System\PluginBundle\Form\Interfaces\Field::Product) as $field) { - $field->formPostSetData($event); + $builder->addEventListener( + FormEvents::POST_SET_DATA, function (FormEvent $event) use ($options) { + /** + * @var \PSC\System\PluginBundle\Form\Interfaces\Field $field + */ + foreach ($this->fields->getFields(\PSC\System\PluginBundle\Form\Interfaces\Field::Product) as $field) { + $field->formPostSetData($event); + } + /** + * @var \PSC\System\PluginBundle\Form\Interfaces\Field $field + */ + foreach ($this->fields->getProductFields(\PSC\System\PluginBundle\Form\Interfaces\Field::Product, $options['productType']) as $field) { + $field->formPostSetData($event); + } } - /** @var \PSC\System\PluginBundle\Form\Interfaces\Field $field */ - foreach ($this->fields->getProductFields(\PSC\System\PluginBundle\Form\Interfaces\Field::Product, $options['productType']) as $field) { - $field->formPostSetData($event); - } - }); + ); - $builder->addEventListener(FormEvents::POST_SUBMIT, function (FormEvent $event) use ($options) { - /** @var \PSC\System\PluginBundle\Form\Interfaces\Field $field */ - foreach ($this->fields->getFields(\PSC\System\PluginBundle\Form\Interfaces\Field::Product) as $field) { - $field->formPostSubmit($event); + $builder->addEventListener( + FormEvents::POST_SUBMIT, function (FormEvent $event) use ($options) { + /** + * @var \PSC\System\PluginBundle\Form\Interfaces\Field $field + */ + foreach ($this->fields->getFields(\PSC\System\PluginBundle\Form\Interfaces\Field::Product) as $field) { + $field->formPostSubmit($event); + } + /** + * @var \PSC\System\PluginBundle\Form\Interfaces\Field $field + */ + foreach ($this->fields->getProductFields(\PSC\System\PluginBundle\Form\Interfaces\Field::Product, $options['productType']) as $field) { + $field->formPostSubmit($event); + } } - /** @var \PSC\System\PluginBundle\Form\Interfaces\Field $field */ - foreach ($this->fields->getProductFields(\PSC\System\PluginBundle\Form\Interfaces\Field::Product, $options['productType']) as $field) { - $field->formPostSubmit($event); - } - }); + ); - $builder->addEventListener(FormEvents::PRE_SUBMIT, function (FormEvent $event) use ($options) { - /** @var \PSC\System\PluginBundle\Form\Interfaces\Field $field */ - foreach ($this->fields->getFields(\PSC\System\PluginBundle\Form\Interfaces\Field::Product) as $field) { - $field->formPreSubmit($event); + $builder->addEventListener( + FormEvents::PRE_SUBMIT, function (FormEvent $event) use ($options) { + /** + * @var \PSC\System\PluginBundle\Form\Interfaces\Field $field + */ + foreach ($this->fields->getFields(\PSC\System\PluginBundle\Form\Interfaces\Field::Product) as $field) { + $field->formPreSubmit($event); + } + /** + * @var \PSC\System\PluginBundle\Form\Interfaces\Field $field + */ + foreach ($this->fields->getProductFields(\PSC\System\PluginBundle\Form\Interfaces\Field::Product, $options['productType']) as $field) { + $field->formPreSubmit($event); + } } - /** @var \PSC\System\PluginBundle\Form\Interfaces\Field $field */ - foreach ($this->fields->getProductFields(\PSC\System\PluginBundle\Form\Interfaces\Field::Product, $options['productType']) as $field) { - $field->formPreSubmit($event); - } - }); + ); } public function getName() @@ -320,12 +425,14 @@ class ProductType extends AbstractType public function configureOptions(OptionsResolver $resolver) { - $resolver->setDefaults(array( + $resolver->setDefaults( + array( 'data_class' => 'PSC\Shop\EntityBundle\Entity\Product', 'productType' => 0, 'product' => null, 'productDoc' => null, 'translation_domain' => 'core_product_edit' - )); + ) + ); } } diff --git a/src/new/src/PSC/Shop/ProductBundle/Resources/views/backend/product/edit/edit.html.twig b/src/new/src/PSC/Shop/ProductBundle/Resources/views/backend/product/edit/edit.html.twig index cae741965..cd5094416 100755 --- a/src/new/src/PSC/Shop/ProductBundle/Resources/views/backend/product/edit/edit.html.twig +++ b/src/new/src/PSC/Shop/ProductBundle/Resources/views/backend/product/edit/edit.html.twig @@ -431,13 +431,30 @@ a[href^="#formlayouter"] {display:none;} +
+
+
+ {{ form_label(form.rawText) }} +
+ {{ form_widget(form.rawText) }} +
+
+
+
{{ 'description'|trans }}
+ + {% if product.rawText %} + {{ form_widget(form.description) }} + {% else %} {{ form_widget(form.description, {attr: {'class': 'form-control summernote'}}) }} - + {% endif %}
{{ 'Additionaldescription'|trans }}
- + {% if product.rawText %} + {{ form_widget(form.text) }} + {% else %} {{ form_widget(form.text, {attr: {'class': 'form-control summernote'}}) }} + {% endif %}
diff --git a/src/new/symfony.lock b/src/new/symfony.lock index 1ac49b8c5..41e3434da 100755 --- a/src/new/symfony.lock +++ b/src/new/symfony.lock @@ -940,6 +940,18 @@ "symfony/ux-twig-component": { "version": "v2.12.0" }, + "symfony/ux-vue": { + "version": "2.23", + "recipe": { + "repo": "github.com/symfony/recipes", + "branch": "main", + "version": "2.9", + "ref": "7a6b5e211acc7b10b7190e704b40f6d2bca01adf" + }, + "files": [ + "assets/vue/controllers/Hello.vue" + ] + }, "symfony/validator": { "version": "4.3", "recipe": { diff --git a/src/new/var/plugins/Custom/PSC/R2_Pitchprint/Api/Base.php b/src/new/var/plugins/Custom/PSC/R2_Pitchprint/Api/Base.php index a61a9d914..cbb08b651 100755 --- a/src/new/var/plugins/Custom/PSC/R2_Pitchprint/Api/Base.php +++ b/src/new/var/plugins/Custom/PSC/R2_Pitchprint/Api/Base.php @@ -6,7 +6,8 @@ use Symfony\Contracts\HttpClient\HttpClientInterface; use function array_merge; -abstract class Base { +abstract class Base +{ private string $apiUrl = 'https://api.print.app/v1/'; diff --git a/src/new/var/plugins/Custom/PSC/R2_Pitchprint/Controller/Backend/DesignController.php b/src/new/var/plugins/Custom/PSC/R2_Pitchprint/Controller/Backend/DesignController.php index 87b65973f..06d7c1753 100755 --- a/src/new/var/plugins/Custom/PSC/R2_Pitchprint/Controller/Backend/DesignController.php +++ b/src/new/var/plugins/Custom/PSC/R2_Pitchprint/Controller/Backend/DesignController.php @@ -33,13 +33,14 @@ class DesignController extends AbstractController { $selectedShop = $shopService->getSelectedShop(); - /** @var Product $product */ + /** + * @var Product $product +*/ $product = $entityManager ->getRepository('PSC\Shop\EntityBundle\Entity\Product')->findOneBy(array('uuid' => $uuid, 'shop' => $selectedShop)); $output = $design->getDesigns($folder); - $data = ['folders' => [], 'designs' => []]; if (isset($output['root']) && isset($output['root']['id']) && $output['root']['id'] == 'root') { foreach ($output['root']['items'] as $item) { diff --git a/src/new/var/plugins/Custom/PSC/R2_Pitchprint/Resources/views/backend/design/edit.html.twig b/src/new/var/plugins/Custom/PSC/R2_Pitchprint/Resources/views/backend/design/edit.html.twig index 396c2b5c7..99f0a8720 100755 --- a/src/new/var/plugins/Custom/PSC/R2_Pitchprint/Resources/views/backend/design/edit.html.twig +++ b/src/new/var/plugins/Custom/PSC/R2_Pitchprint/Resources/views/backend/design/edit.html.twig @@ -18,7 +18,7 @@
{{design.title}} title
- +
{% endfor %}
- + {% endblock %} diff --git a/src/new/var/plugins/Custom/PSC/R2_Pitchprint/Resources/views/form/field/backend.html.twig b/src/new/var/plugins/Custom/PSC/R2_Pitchprint/Resources/views/form/field/backend.html.twig index ee155f1ca..dc98e4fd5 100755 --- a/src/new/var/plugins/Custom/PSC/R2_Pitchprint/Resources/views/form/field/backend.html.twig +++ b/src/new/var/plugins/Custom/PSC/R2_Pitchprint/Resources/views/form/field/backend.html.twig @@ -63,7 +63,7 @@ -