Skip to content

Commit

Permalink
Merge branch '5.0'
Browse files Browse the repository at this point in the history
* 5.0:
  Update changelog for 5.0.12 release
  Changes for upcoming travis-ci infra migration (#2180)
  [Docs] Fix slack channel link (#2178)
  [AdminBundle] Fix icons CKeditor (#2174)
  Apply styleci codestyle changes
  Backport styleci fixes to 5.0 branch
  fix gulp dependency (#2172)
  null config for older branches (#2151)
  remove unnecessary roles on dom nodes (#2170)
  [NodeBundle] fix issue finding disctinct classes for deleted files (#2148)
  Translate pagepart type name in delete modal (#2160)
  [TranslatorBundle] fix non-unique locales in configurator (#2156)
  [AdminListBundle] use datepicker for DateTimeType filters (#2159)
  [Docs] Fix the links in the github contributing.md file (#2166)
  Remove duplicate set in template (#2168)
  Fixed issue where a date (and time) in the past could be selected when publishing later (#2163)
  Improved error shown when a page does not have a view location (#2162)
  [AdminListBundle] Feature/sortable adminlist (#2143)
  [AdminBundle] revert ckeditor to original version - manual clone - no npm version available (#2134)
  [NodeBundle] Revert "Fix bug in NodeChoiceType (#2115)" (#2133)

 Conflicts:
	README.md
	TestListener.php
	composer.json
	src/Kunstmaan/AdminBundle/Command/ApplyAclCommand.php
	src/Kunstmaan/AdminBundle/Command/ExceptionCommand.php
	src/Kunstmaan/AdminBundle/Command/UpdateAclCommand.php
	src/Kunstmaan/AdminBundle/DependencyInjection/KunstmaanAdminExtension.php
	src/Kunstmaan/AdminBundle/Entity/AbstractEntity.php
	src/Kunstmaan/AdminBundle/Helper/AdminPanel/DefaultAdminPanelAdaptor.php
	src/Kunstmaan/AdminBundle/Helper/AdminRouteHelper.php
	src/Kunstmaan/AdminBundle/Helper/VersionCheck/VersionChecker.php
	src/Kunstmaan/AdminBundle/KunstmaanAdminBundle.php
	src/Kunstmaan/AdminBundle/Tests/Entity/TestEntity.php
	src/Kunstmaan/AdminBundle/Tests/Form/MediaTokenTransformerTest.php
	src/Kunstmaan/AdminBundle/Tests/Mocks/StatementMock.php
	src/Kunstmaan/AdminBundle/Tests/unit/Entity/AbstractEntityTest.php
	src/Kunstmaan/AdminBundle/Tests/unit/Entity/AclChangesetTest.php
	src/Kunstmaan/AdminBundle/Tests/unit/Entity/GroupTest.php
	src/Kunstmaan/AdminBundle/Tests/unit/Entity/RoleTest.php
	src/Kunstmaan/AdminBundle/Tests/unit/Entity/UserTest.php
	src/Kunstmaan/AdminBundle/Tests/unit/Helper/DomainConfigurationTest.php
	src/Kunstmaan/AdminBundle/Tests/unit/Helper/Menu/MenuItemTest.php
	src/Kunstmaan/AdminBundle/Tests/unit/Helper/Security/Acl/AclHelperTest.php
	src/Kunstmaan/AdminBundle/Tests/unit/Helper/Security/Acl/AclNativeHelperTest.php
	src/Kunstmaan/AdminBundle/Tests/unit/Helper/Security/Acl/Permission/MaskBuilderTest.php
	src/Kunstmaan/AdminBundle/Tests/unit/Helper/Security/Acl/Permission/PermissionAdminTest.php
	src/Kunstmaan/AdminBundle/Tests/unit/Helper/Security/Acl/Permission/PermissionDefinitionTest.php
	src/Kunstmaan/AdminBundle/Tests/unit/Helper/Security/Acl/Permission/PermissionMapTest.php
	src/Kunstmaan/AdminBundle/Twig/MultiDomainAdminTwigExtension.php
	src/Kunstmaan/AdminListBundle/Controller/AdminListController.php
	src/Kunstmaan/AdminListBundle/Tests/AdminList/ExportListTest.php
	src/Kunstmaan/AdminListBundle/Tests/AdminList/FilterType/ORM/ORMFilterTypeTestCase.php
	src/Kunstmaan/AdminListBundle/Tests/AdminList/ItemAction/SimpleItemActionTest.php
	src/Kunstmaan/AdminListBundle/Tests/unit/AdminList/AdminListFactoryTest.php
	src/Kunstmaan/AdminListBundle/Tests/unit/AdminList/FieldTest.php
	src/Kunstmaan/AdminListBundle/Tests/unit/AdminList/FilterBuilderTest.php
	src/Kunstmaan/AdminListBundle/Tests/unit/AdminList/FilterTest.php
	src/Kunstmaan/AdminListBundle/Tests/unit/AdminList/FilterType/DBAL/AbstractDBALFilterTypeTest.php
	src/Kunstmaan/AdminListBundle/Tests/unit/AdminList/FilterType/DBAL/BooleanFilterTypeTest.php
	src/Kunstmaan/AdminListBundle/Tests/unit/AdminList/FilterType/DBAL/DateFilterTypeTest.php
	src/Kunstmaan/AdminListBundle/Tests/unit/AdminList/FilterType/DBAL/DateTimeFilterTypeTest.php
	src/Kunstmaan/AdminListBundle/Tests/unit/AdminList/FilterType/DBAL/EnumerationFilterTypeTest.php
	src/Kunstmaan/AdminListBundle/Tests/unit/AdminList/FilterType/DBAL/NumberFilterTypeTest.php
	src/Kunstmaan/AdminListBundle/Tests/unit/AdminList/FilterType/DBAL/StringFilterTypeTest.php
	src/Kunstmaan/AdminListBundle/Tests/unit/AdminList/FilterType/ORM/AbstractORMFilterTypeTest.php
	src/Kunstmaan/AdminListBundle/Tests/unit/AdminList/FilterType/ORM/BooleanFilterTypeTest.php
	src/Kunstmaan/AdminListBundle/Tests/unit/AdminList/FilterType/ORM/DateFilterTypeTest.php
	src/Kunstmaan/AdminListBundle/Tests/unit/AdminList/FilterType/ORM/DateTimeFilterTypeTest.php
	src/Kunstmaan/AdminListBundle/Tests/unit/AdminList/FilterType/ORM/EnumerationFilterTypeTest.php
	src/Kunstmaan/AdminListBundle/Tests/unit/AdminList/FilterType/ORM/NumberFilterTypeTest.php
	src/Kunstmaan/AdminListBundle/Tests/unit/AdminList/FilterType/ORM/StringFilterTypeTest.php
	src/Kunstmaan/AdminListBundle/Tests/unit/Service/EntityVersionLockServiceTest.php
	src/Kunstmaan/ArticleBundle/Twig/ArticleTwigExtension.php
	src/Kunstmaan/ConfigBundle/Controller/ConfigController.php
	src/Kunstmaan/DashboardBundle/Command/DashboardCommand.php
	src/Kunstmaan/DashboardBundle/Command/GoogleAnalyticsConfigFlushCommand.php
	src/Kunstmaan/DashboardBundle/Command/GoogleAnalyticsDataFlushCommand.php
	src/Kunstmaan/DashboardBundle/Entity/AnalyticsOverview.php
	src/Kunstmaan/FormBundle/Controller/FormSubmissionsController.php
	src/Kunstmaan/FormBundle/Form/ChoiceFormSubmissionType.php
	src/Kunstmaan/FormBundle/Helper/FormMailer.php
	src/Kunstmaan/FormBundle/Tests/AdminList/FormPageAdminListConfiguratorTest.php
	src/Kunstmaan/FormBundle/Tests/Entity/FormSubmissionFieldTypes/FileFormSubmissionFieldTest.php
	src/Kunstmaan/FormBundle/Tests/Stubs/TestConfiguration.php
	src/Kunstmaan/FormBundle/Tests/Stubs/TestRepository.php
	src/Kunstmaan/FormBundle/Tests/unit/Entity/AbstractFormPageTest.php
	src/Kunstmaan/FormBundle/Tests/unit/Entity/FormSubmissionFieldTest.php
	src/Kunstmaan/FormBundle/Tests/unit/Entity/FormSubmissionFieldTypes/ChoiceFormSubmissionFieldTest.php
	src/Kunstmaan/FormBundle/Tests/unit/Entity/FormSubmissionFieldTypes/EmailFormSubmissionFieldTest.php
	src/Kunstmaan/FormBundle/Tests/unit/Entity/FormSubmissionFieldTypes/StringFormSubmissionFieldTest.php
	src/Kunstmaan/FormBundle/Tests/unit/Entity/FormSubmissionFieldTypes/TextFormSubmissionFieldTest.php
	src/Kunstmaan/FormBundle/Tests/unit/Entity/FormSubmissionTest.php
	src/Kunstmaan/FormBundle/Tests/unit/Entity/PageParts/AbstractFormPagePartTest.php
	src/Kunstmaan/FormBundle/Tests/unit/Entity/PageParts/ChoicePagePartTest.php
	src/Kunstmaan/FormBundle/Tests/unit/Entity/PageParts/EmailPagePartTest.php
	src/Kunstmaan/FormBundle/Tests/unit/Entity/PageParts/FileUploadPagePartTest.php
	src/Kunstmaan/FormBundle/Tests/unit/Entity/PageParts/MultiLineTextPagePartTest.php
	src/Kunstmaan/FormBundle/Tests/unit/Entity/PageParts/SingleLineTextPagePartTest.php
	src/Kunstmaan/FormBundle/Tests/unit/Entity/PageParts/SubmitButtonPagePartTest.php
	src/Kunstmaan/GeneratorBundle/Generator/FormPageGenerator.php
	src/Kunstmaan/GeneratorBundle/Resources/SensioGeneratorBundle/skeleton/layout/groundcontrol/package.json
	src/Kunstmaan/GeneratorBundle/Tests/unit/Generator/DefaultSiteGeneratorTest.php
	src/Kunstmaan/GeneratorBundle/Tests/unit/Helper/GeneratorUtilsTest.php
	src/Kunstmaan/MediaBundle/AdminList/MediaAdminListConfigurator.php
	src/Kunstmaan/MediaBundle/Command/CleanDeletedMediaCommand.php
	src/Kunstmaan/MediaBundle/Command/CreatePdfPreviewCommand.php
	src/Kunstmaan/MediaBundle/Command/RenameSoftDeletedCommand.php
	src/Kunstmaan/MediaBundle/Controller/MediaController.php
	src/Kunstmaan/MediaBundle/Form/FolderType.php
	src/Kunstmaan/MediaBundle/Tests/unit/Entity/FolderTest.php
	src/Kunstmaan/MediaBundle/Tests/unit/Entity/MediaTest.php
	src/Kunstmaan/MediaBundle/Tests/unit/Helper/File/FileHelperTest.php
	src/Kunstmaan/MediaBundle/Tests/unit/Helper/File/PdfHandlerTest.php
	src/Kunstmaan/MediaBundle/Tests/unit/Helper/FolderManagerTest.php
	src/Kunstmaan/MediaBundle/Tests/unit/Helper/MediaManagerTest.php
	src/Kunstmaan/MediaBundle/Tests/unit/Helper/RemoteAudio/RemoteAudioHelperTest.php
	src/Kunstmaan/MediaBundle/Tests/unit/Helper/RemoteSlide/RemoteSlideHelperTest.php
	src/Kunstmaan/MediaBundle/Tests/unit/Helper/RemoteVideo/RemoteVideoHelperTest.php
	src/Kunstmaan/MediaBundle/Tests/unit/Helper/Transformer/PdfTransformerTest.php
	src/Kunstmaan/MediaPagePartBundle/Tests/Controller/DefaultControllerTest.php
	src/Kunstmaan/MediaPagePartBundle/Tests/unit/Entity/DownloadPagePartTest.php
	src/Kunstmaan/MediaPagePartBundle/Tests/unit/Entity/ImagePagePartTest.php
	src/Kunstmaan/MediaPagePartBundle/Tests/unit/Entity/SlidePagePartTest.php
	src/Kunstmaan/MediaPagePartBundle/Tests/unit/Entity/VideoPagePartTest.php
	src/Kunstmaan/MultiDomainBundle/Tests/Router/DomainBasedLocaleRouterTest.php
	src/Kunstmaan/MultiDomainBundle/Tests/unit/Helper/AdminPanel/SitesAdminPanelAdaptorTest.php
	src/Kunstmaan/MultiDomainBundle/Tests/unit/Helper/DomainConfigurationTest.php
	src/Kunstmaan/MultiDomainBundle/Tests/unit/Helper/HostOverrideCleanupHandlerTest.php
	src/Kunstmaan/NodeBundle/Command/CronUpdateNodeCommand.php
	src/Kunstmaan/NodeBundle/Command/InitAclCommand.php
	src/Kunstmaan/NodeBundle/EventListener/RenderContextListener.php
	src/Kunstmaan/NodeBundle/Form/EventListener/URLChooserFormSubscriber.php
	src/Kunstmaan/NodeBundle/Helper/Menu/ActionsMenuBuilder.php
	src/Kunstmaan/NodeBundle/Helper/Menu/PageMenuAdaptor.php
	src/Kunstmaan/NodeBundle/Helper/PagesConfiguration.php
	src/Kunstmaan/NodeBundle/KunstmaanNodeBundle.php
	src/Kunstmaan/NodeBundle/Router/SlugRouter.php
	src/Kunstmaan/NodeBundle/Tests/Entity/TestEntity.php
	src/Kunstmaan/NodeBundle/Tests/Stubs/TestRepository.php
	src/Kunstmaan/NodeBundle/Tests/unit/Entity/NodeTest.php
	src/Kunstmaan/NodeBundle/Tests/unit/Entity/NodeTranslationTest.php
	src/Kunstmaan/NodeBundle/Tests/unit/Entity/NodeVersionTest.php
	src/Kunstmaan/NodeBundle/Tests/unit/Helper/Menu/ActionsMenuBuilderTest.php
	src/Kunstmaan/NodeBundle/Tests/unit/Router/SlugRouterTest.php
	src/Kunstmaan/NodeSearchBundle/DependencyInjection/KunstmaanNodeSearchExtension.php
	src/Kunstmaan/PagePartBundle/Tests/Form/TextPagePartAdminTypeTest.php
	src/Kunstmaan/PagePartBundle/Tests/unit/Entity/HeaderPagePartTest.php
	src/Kunstmaan/PagePartBundle/Tests/unit/Entity/LinePagePartTest.php
	src/Kunstmaan/PagePartBundle/Tests/unit/Entity/LinkPagePartTest.php
	src/Kunstmaan/PagePartBundle/Tests/unit/Entity/RawHTMLPagePartTest.php
	src/Kunstmaan/PagePartBundle/Tests/unit/Entity/TextPagePartTest.php
	src/Kunstmaan/PagePartBundle/Tests/unit/Entity/ToTopPagePartTest.php
	src/Kunstmaan/PagePartBundle/Tests/unit/Entity/TocPagePartTest.php
	src/Kunstmaan/PagePartBundle/Tests/unit/EventListener/CloneListenerTest.php
	src/Kunstmaan/PagePartBundle/Tests/unit/Form/HeaderPagePartAdminTypeTest.php
	src/Kunstmaan/PagePartBundle/Tests/unit/Form/LinePagePartAdminTypeTest.php
	src/Kunstmaan/PagePartBundle/Tests/unit/Form/LinkPagePartAdminTypeTest.php
	src/Kunstmaan/PagePartBundle/Tests/unit/Form/RawHTMLPagePartAdminTypeTest.php
	src/Kunstmaan/PagePartBundle/Tests/unit/Form/ToTopPagePartAdminTypeTest.php
	src/Kunstmaan/PagePartBundle/Tests/unit/Form/TocPagePartAdminTypeTest.php
	src/Kunstmaan/RedirectBundle/Tests/Entity/RedirectTest.php
	src/Kunstmaan/RedirectBundle/Tests/unit/AdminList/RedirectAdminListConfiguratorTest.php
	src/Kunstmaan/RedirectBundle/Tests/unit/Form/RedirectAdminTypeTest.php
	src/Kunstmaan/RedirectBundle/Tests/unit/Router/RedirectRouterTest.php
	src/Kunstmaan/SearchBundle/Command/SetupIndexCommand.php
	src/Kunstmaan/SearchBundle/Tests/unit/DependencyInjection/Configuration/SearchConfigurationChainTest.php
	src/Kunstmaan/SeoBundle/Tests/unit/Entity/SeoTest.php
	src/Kunstmaan/SeoBundle/Tests/unit/Twig/TwigExtensionTests.php
	src/Kunstmaan/TaggingBundle/Entity/TagManager.php
	src/Kunstmaan/TranslatorBundle/Command/ExportTranslationsCommand.php
	src/Kunstmaan/TranslatorBundle/Command/ImportTranslationsCommand.php
	src/Kunstmaan/TranslatorBundle/Command/TranslationCacheCommand.php
	src/Kunstmaan/TranslatorBundle/Controller/TranslatorController.php
	src/Kunstmaan/TranslatorBundle/Entity/Translation.php
	src/Kunstmaan/TranslatorBundle/Service/Command/Importer/ImportCommandHandler.php
	src/Kunstmaan/TranslatorBundle/Service/Command/Importer/Importer.php
	src/Kunstmaan/TranslatorBundle/Service/Translator/Translator.php
	src/Kunstmaan/TranslatorBundle/Tests/BaseTestCase.php
	src/Kunstmaan/TranslatorBundle/Tests/TestListener.php
	src/Kunstmaan/TranslatorBundle/Tests/unit/DependencyInjection/KunstmaanTranslatorExtensionTest.php
	src/Kunstmaan/TranslatorBundle/Tests/unit/Repository/TranslationRepositoryTest.php
	src/Kunstmaan/TranslatorBundle/Toolbar/TranslatorDataCollector.php
	src/Kunstmaan/UserManagementBundle/Controller/GroupsController.php
	src/Kunstmaan/UserManagementBundle/Controller/RolesController.php
	src/Kunstmaan/UserManagementBundle/Controller/UsersController.php
	src/Kunstmaan/UtilitiesBundle/Helper/Shell/Shell.php
	src/Kunstmaan/UtilitiesBundle/Tests/Helper/ClassLookupTest.php
	src/Kunstmaan/UtilitiesBundle/Tests/Helper/DummyClass.php
	src/Kunstmaan/UtilitiesBundle/Tests/unit/Helper/Cipher/CipherTest.php
	src/Kunstmaan/VotingBundle/Tests/Services/RepositoryResolverTest.php
	src/Kunstmaan/VotingBundle/Tests/unit/DependencyInjection/KunstmaanVotingExtensionTest.php
	src/Kunstmaan/VotingBundle/Tests/unit/EventListener/Security/MaxNumberByIpEventListenerTest.php
  • Loading branch information
acrobat committed Nov 29, 2018
2 parents 32630e9 + b6eeb10 commit d4921b0
Show file tree
Hide file tree
Showing 835 changed files with 4,317 additions and 4,419 deletions.
12 changes: 9 additions & 3 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@

We follow most of the procedures for contributions from the [Symfony](http://symfony.com/doc/current/contributing/index.html) and [Sylius](http://sylius.org) project, as such much of this info will look familiar as it embodies current best practices.

* [Reporting a bug or a security issue](../docs/99-01-reporting-issues.md)
* [Submitting pull requests](../docs/99-02-pull-requests.md)
* [Coding standards](../docs/99-03-coding-standards.md)
* [Reporting a bug or a security issue](../docs/contributing/reporting-issues.md)
* [Submitting pull requests](../docs/contributing/pull-requests.md)
* [Coding standards](../docs/contributing/coding-standards.md)
* [Preparing a new release](../docs/contributing/preparing-a-new-release.md)
* [Roadmap](../docs/contributing/roadmap.md)
* [Community bundles](../docs/contributing/community-bundles.md)
* [Release process](../docs/contributing/release-process.md)
* [Translations](../docs/contributing/contributing-translations.md)
* [Ground Control](../docs/contributing/groundcontrol.md)
18 changes: 18 additions & 0 deletions .php_cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<?php

$finder = PhpCsFixer\Finder::create()
->exclude('src/Kunstmaan/GeneratorBundle/Resources/SensioGeneratorBundle')
->in(__DIR__)
;

return PhpCsFixer\Config::create()
->setRiskyAllowed(false)
->setRules([
'@Symfony' => true,
'yoda_style' => false,
'phpdoc_summary' => false,
'class_attributes_separation' => ['elements' => ['method', 'property']],
'concat_space' => ['spacing' => 'one'],
])
->setFinder($finder)
;
16 changes: 16 additions & 0 deletions .styleci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
preset: symfony
risky: false

disabled:
- yoda_style
- concat_without_spaces
- phpdoc_summary
- const_separation

finder:
exclude:
- 'src/Kunstmaan/GeneratorBundle/Resources/SensioGeneratorBundle'
not-path:
- "TranslatorBundle/Tests/app2"
- "TranslatorBundle/Tests/app"
- "vendor_bower"
2 changes: 0 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
language: php

sudo: false

cache:
directories:
- $HOME/.composer/cache/files
Expand Down
14 changes: 14 additions & 0 deletions CHANGELOG-5.X.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,19 @@
# Changelog

## 5.0.12 / 2018-11-29

* [AllBundles] Changes for upcoming travis-ci infra migration [#2180](https://github.com/Kunstmaan/KunstmaanBundlesCMS/pull/2180) ([@acrobat](https://github.com/acrobat))
* [Docs] Fix slack channel link [#2178](https://github.com/Kunstmaan/KunstmaanBundlesCMS/pull/2178) ([@diskwriter](https://github.com/diskwriter))
* [AllBundles] Backport styleci fixes to 5.0 [#2175](https://github.com/Kunstmaan/KunstmaanBundlesCMS/pull/2175) ([@acrobat](https://github.com/acrobat))
* [AdminBundle] Fix icons ckeditor again [#2174](https://github.com/Kunstmaan/KunstmaanBundlesCMS/pull/2174) ([@dbeerten](https://github.com/dbeerten))
* [GeneratorBundle] fix gulp dependency [#2172](https://github.com/Kunstmaan/KunstmaanBundlesCMS/pull/2172) ([@diskwriter](https://github.com/diskwriter))
* [GeneratorBundle] Remove unnecessary roles on dom nodes [#2170](https://github.com/Kunstmaan/KunstmaanBundlesCMS/pull/2170) ([@diskwriter](https://github.com/diskwriter))
* [AdminListBundle] use datepicker for DateTimeType filters [#2159](https://github.com/Kunstmaan/KunstmaanBundlesCMS/pull/2159) ([@dbeerten](https://github.com/dbeerten))
* [TranslatorBundle] fix non-unique locales in TranslationAdminConfigurator [#2156](https://github.com/Kunstmaan/KunstmaanBundlesCMS/pull/2156) ([@treeleaf](https://github.com/treeleaf))
* [AllBundles] Disable styleci checks for 5.0 [#2151](https://github.com/Kunstmaan/KunstmaanBundlesCMS/pull/2151) ([@acrobat](https://github.com/acrobat))
* [AdminBundle] revert CKeditor to original version [#2134](https://github.com/Kunstmaan/KunstmaanBundlesCMS/pull/2134) ([@dbeerten](https://github.com/dbeerten))
* [NodeBundle] Revert "Fix bug in NodeChoiceType (#2115)" [#2133](https://github.com/Kunstmaan/KunstmaanBundlesCMS/pull/2133) ([@deZinc](https://github.com/deZinc))

## 5.0.11 / 2018-09-12

* [NodeSearchBunde] [SearchBundle] Add parameters for ES authentication and use them in version check [#2120](https://github.com/Kunstmaan/KunstmaanBundlesCMS/pull/2120) ([@wesleylancel](https://github.com/wesleylancel))
Expand Down
3 changes: 1 addition & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@ documentation and be sure to read our [Coding Standards](http://kunstmaanbundles
### Community
Want to talk to fellow contributors? There's always people eager to chat in our slack channel!

[![Join our slack channel](https://bundles.kunstmaan.be/uploads/media/5ae3807f4f548/slacklogo-small.png?production-87162ce) Join our Slack Channel!](https://join.slack.com/t/kunstmaancms/shared_invite/enQtMzU0Mjg4MjUzODczLTg5NTExMzIxZmI2OTgyNzI4YjdmNjdiZWM1NDI3ZDM3NmRiMjVkMmQ0MjhkYWU3YTMwNTU0ZjM3YmIyNTc5MjI)

[![Join our slack channel](https://bundles.kunstmaan.be/uploads/media/5ae3807f4f548/slacklogo-small.png?production-87162ce) Join our Slack Channel!](https://join.slack.com/t/kunstmaancms/shared_invite/enQtNDg0MzE0NDQ3MjU0LTIxMmY4YTRkMDBmYzE5MjFiMzBjOGI5NjczMjEyNDdlNDlmYjBiZDA3OWRjM2NhZjRjZjBlYmM0OWJhNWU2ZGM)

### Browser support

Expand Down
3 changes: 2 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,8 @@
"matthiasnoback/symfony-config-test": "2.2.0",
"matthiasnoback/symfony-dependency-injection-test": "1.2.0",
"ekino/newrelic-bundle": "^1.4",
"codeception/codeception": "^2.4"
"codeception/codeception": "^2.4",
"friendsofphp/php-cs-fixer": "^2.13"
},
"replace": {
"kunstmaan/admin-bundle": "self.version",
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@
"test": "gulp test",
"build": "gulp buildOptimized",
"testAndBuild": "gulp testAndBuildOptimized",
"buildGroundControlSkeleton": "gulp buildGroundControlSkeleton"
"buildGroundControlSkeleton": "gulp buildGroundControlSkeleton",
"postinstall": "git clone -b full/4.5.3 --single-branch https://github.com/ckeditor/ckeditor-releases.git node_modules/ckeditor"
},
"author": "Kunstmaan",
"license": "ISC",
Expand Down Expand Up @@ -53,7 +54,6 @@
"babel-polyfill": "^6.26.0",
"bootstrap-sass": "^3.3.7",
"cargobay": "Kunstmaan/cargobay#0.8.6-support",
"ckeditor": "ckeditor/ckeditor-releases.git#full/4.5.11",
"eonasdan-bootstrap-datetimepicker": "^4.17.47",
"fuse.js": "^3.1.0",
"jstree": "^3.3.3",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,12 +57,12 @@ public function buildItemActions()
{
$this->addItemAction(
new SimpleItemAction(
function(Exception $row) {
function (Exception $row) {
return [
'path' => 'kunstmaanadminbundle_admin_exception_toggle_resolve',
'params' => [
'id' => $row->getId()
]
'id' => $row->getId(),
],
];
},
null,
Expand Down Expand Up @@ -112,5 +112,4 @@ public function getEntityName()
{
return 'Exception';
}

}
6 changes: 2 additions & 4 deletions src/Kunstmaan/AdminBundle/Command/ApplyAclCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
*/
class ApplyAclCommand extends ContainerAwareCommand
{

/**
* @var EntityManager
*/
Expand Down Expand Up @@ -60,7 +59,7 @@ protected function configure()

$this->setName('kuma:acl:apply')
->setDescription('Apply ACL changeset.')
->setHelp("The <info>kuma:acl:apply</info> can be used to apply an ACL changeset recursively, changesets are fetched from the database.");
->setHelp('The <info>kuma:acl:apply</info> can be used to apply an ACL changeset recursively, changesets are fetched from the database.');
}

/**
Expand Down Expand Up @@ -92,7 +91,7 @@ protected function execute(InputInterface $input, OutputInterface $output)
}

/**
* @return boolean
* @return bool
*/
private function isRunning()
{
Expand All @@ -111,5 +110,4 @@ private function isRunning()

return false;
}

}
4 changes: 1 addition & 3 deletions src/Kunstmaan/AdminBundle/Command/CreateGroupCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,7 @@
use Kunstmaan\AdminBundle\Entity\Role;
use Symfony\Bundle\FrameworkBundle\Command\ContainerAwareCommand;
use Symfony\Component\Console\Input\InputArgument;

use Symfony\Component\Console\Input\InputInterface;

use Symfony\Component\Console\Input\InputOption;
use Symfony\Component\Console\Output\OutputInterface;

Expand Down Expand Up @@ -59,7 +57,7 @@ protected function configure()
new InputArgument('group', InputArgument::REQUIRED, 'The group'),
new InputOption('role', null, InputOption::VALUE_OPTIONAL, 'Role(s) (comma separated list if you want to specifiy multiple roles)'),
))
->setHelp(<<<EOT
->setHelp(<<<'EOT'
The <info>kuma:group:create</info> command creates a group:
<info>php bin/console kuma:group:create Administrators</info>
Expand Down
4 changes: 1 addition & 3 deletions src/Kunstmaan/AdminBundle/Command/CreateRoleCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,7 @@
use Kunstmaan\AdminBundle\Entity\Role;
use Symfony\Bundle\FrameworkBundle\Command\ContainerAwareCommand;
use Symfony\Component\Console\Input\InputArgument;

use Symfony\Component\Console\Input\InputInterface;

use Symfony\Component\Console\Output\OutputInterface;

/**
Expand Down Expand Up @@ -53,7 +51,7 @@ protected function configure()
->setDefinition(array(
new InputArgument('role', InputArgument::REQUIRED, 'The role'),
))
->setHelp(<<<EOT
->setHelp(<<<'EOT'
The <info>kuma:role:create</info> command creates a role:
<info>php bin/console kuma:role:create ROLE_ADMIN</info>
Expand Down
27 changes: 11 additions & 16 deletions src/Kunstmaan/AdminBundle/Command/CreateUserCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ protected function configure()
new InputOption('super-admin', null, InputOption::VALUE_NONE, 'Set the user as super admin'),
new InputOption('inactive', null, InputOption::VALUE_NONE, 'Set the user as inactive'),
))
->setHelp(<<<EOT
->setHelp(<<<'EOT'
The <info>kuma:user:create</info> command creates a user:
<info>php bin/console kuma:user:create matthieu --group=Users</info>
Expand Down Expand Up @@ -102,11 +102,10 @@ protected function initialize(InputInterface $input, OutputInterface $output)
$this->groups = $this->getGroups();
}


/**
* Executes the current command.
*
* @param InputInterface $input The input
* @param InputInterface $input The input
* @param OutputInterface $output The output
*
* @return int
Expand Down Expand Up @@ -150,13 +149,12 @@ protected function execute(InputInterface $input, OutputInterface $output)
// Attach groups
$groupOutput = [];


foreach (explode(',', $groupOption) as $groupId) {

if ((int)$groupId === 0) {
if ((int) $groupId === 0) {
foreach ($this->groups as $value) {
if ($groupId === $value->getName()) {
$group = $value;

break;
}
}
Expand Down Expand Up @@ -188,17 +186,15 @@ protected function execute(InputInterface $input, OutputInterface $output)
/**
* Interacts with the user.
*
* @param InputInterface $input The input
* @param InputInterface $input The input
* @param OutputInterface $output The output
*
* @throws \InvalidArgumentException
*
* @return void
*/
protected function interact(InputInterface $input, OutputInterface $output)
{
if (!$input->getArgument('username')) {
$question = New Question('Please choose a username:');
$question = new Question('Please choose a username:');
$question->setValidator(function ($username) {
if (null === $username) {
throw new \InvalidArgumentException('Username can not be empty');
Expand All @@ -215,7 +211,7 @@ protected function interact(InputInterface $input, OutputInterface $output)
}

if (!$input->getArgument('email')) {
$question = New Question('Please choose an email:');
$question = new Question('Please choose an email:');
$question->setValidator(function ($email) {
if (null === $email) {
throw new \InvalidArgumentException('Email can not be empty');
Expand All @@ -232,8 +228,7 @@ protected function interact(InputInterface $input, OutputInterface $output)
}

if (!$input->getArgument('password')) {

$question = New Question('Please choose a password:');
$question = new Question('Please choose a password:');
$question->setHidden(true);
$question->setHiddenFallback(false);
$question->setValidator(function ($password) {
Expand Down Expand Up @@ -269,14 +264,13 @@ protected function interact(InputInterface $input, OutputInterface $output)
);
$question->setMultiselect(true);
$question->setValidator(function ($groupsInput) {

if (!$this->groups) {
throw new \RuntimeException('No user group(s) could be found');
}

// Validate that the chosen group options exist in the available groups
$groupNames = array_unique(explode(',', $groupsInput));
if (count(array_intersect_key(array_flip($groupNames),$this->groups)) !== count($groupNames)) {
if (count(array_intersect_key(array_flip($groupNames), $this->groups)) !== count($groupNames)) {
throw new InvalidArgumentException('You have chosen non existing group(s)');
}

Expand All @@ -285,6 +279,7 @@ protected function interact(InputInterface $input, OutputInterface $output)
'Group(s) must be of type integer and can not be empty'
);
}

return $groupsInput;
});

Expand All @@ -301,7 +296,7 @@ private function getGroups()

// reindexing the array, using the db id as the key
$newGroups = [];
foreach($groups as $group) {
foreach ($groups as $group) {
$newGroups[$group->getId()] = $group;
}

Expand Down
12 changes: 6 additions & 6 deletions src/Kunstmaan/AdminBundle/Command/ExceptionCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,13 +46,13 @@ protected function configure()
->setDescription('Remove resolved exceptions based on days.')
->setDefinition(
[
new InputArgument('days', InputArgument::OPTIONAL, 'Days', 7)
new InputArgument('days', InputArgument::OPTIONAL, 'Days', 7),
]
);
}

/**
* @param InputInterface $input
* @param InputInterface $input
* @param OutputInterface $output
*/
protected function execute(InputInterface $input, OutputInterface $output)
Expand All @@ -62,7 +62,7 @@ protected function execute(InputInterface $input, OutputInterface $output)
}

$days = (int) $input->getArgument('days');
if ( $days <= 0 ) {
if ($days <= 0) {
$output->writeln('<bg=red;options=bold>Days number must be higher than 0</>');
}

Expand All @@ -73,10 +73,10 @@ protected function execute(InputInterface $input, OutputInterface $output)

$cp = 0;
$exceptions = $this->em->getRepository(Exception::class)->findAllHigherThanDays($convertDate);
if ( $exceptions ) {
foreach ( $exceptions as $exception ) {
if ($exceptions) {
foreach ($exceptions as $exception) {
$this->em->remove($exception);
$cp++;
++$cp;
}
$this->em->flush();
}
Expand Down
5 changes: 2 additions & 3 deletions src/Kunstmaan/AdminBundle/Command/UpdateAclCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,8 @@ protected function configure()

$this->setName('kuma:acl:update')
->setDescription('Permissions update of ACL entries for all nodes for given role')
->setHelp("The <info>kuma:acl:update</info> will update ACL entries for the nodes of the current project" .
"with given role and permissions");
->setHelp('The <info>kuma:acl:update</info> will update ACL entries for the nodes of the current project' .
'with given role and permissions');
}

/**
Expand Down Expand Up @@ -107,5 +107,4 @@ protected function execute(InputInterface $input, OutputInterface $output)

$output->writeln(count($nodes) . ' nodes processed.');
}

}
Loading

0 comments on commit d4921b0

Please sign in to comment.