2017 © Pedro Peláez
 

symfony-bundle qcm-core-bundle

QCM Core bundle for Symfony2

image

avoo/qcm-core-bundle

QCM Core bundle for Symfony2

  • Wednesday, September 20, 2017
  • by avoo
  • Repository
  • 1 Watchers
  • 0 Stars
  • 165 Installations
  • PHP
  • 2 Dependents
  • 0 Suggesters
  • 1 Forks
  • 1 Open issues
  • 5 Versions
  • 0 % Grown

The README.md

QcmCoreBundle

Latest Stable Version License Build Status Scrutinizer Code Quality, (*1)

The core bundle includes the basic functionalities of qcm based on SyliusResourceBundle concept and implement QcmComponent, (*2)

Installation

Require avoo/qcm-core-bundle into your composer.json file:, (*3)

``` json { "require": { "avoo/qcm-core-bundle": "@dev-master" } }, (*4)


Register the bundle in `app/AppKernel.php`: ``` php // app/AppKernel.php public function registerBundles() { return array( // ... new FOS\RestBundle\FOSRestBundle(), new JMS\SerializerBundle\JMSSerializerBundle($this), new Sylius\Bundle\ResourceBundle\SyliusResourceBundle(), new WhiteOctober\PagerfantaBundle\WhiteOctoberPagerfantaBundle(), new Qcm\Bundle\CoreBundle\QcmCoreBundle(), ); }

In app/config.yml, (*5)

``` yml imports: - { resource: parameters.yml } - { resource: security.yml } - { resource: @QcmCoreBundle/Resources/config/core.yml }, (*6)


Security default configuration ------------------------------ You can use the default register/login process: In `app/config/routing.yml` ``` yml qcm_core: prefix: / resource: "@QcmCoreBundle/Resources/config/routing.yml"

Add default user provider, firewall and access control in app/config/security.yml:, (*7)

``` yml security: encoders: Qcm\Component\User\Model\UserInterface: sha512 providers: qcm_corebundle: id: qcm_core.user_provider.username firewalls: login_firewall: pattern: ^/security/login$ anonymous: ~ secured_area: pattern: ^/ anonymous: ~ form_login: provider: qcm_corebundle login_path: qcm_core_security_login check_path: qcm_core_security_login_check remember_me: true default_target_path: you_homepage_route logout: path: qcm_core_security_logout access_control: - { path: "^/security/login", roles: IS_AUTHENTICATED_ANONYMOUSLY } - { path: "^/", roles: ROLE_USER }, (*8)


QCM Configuration ----------------- You can override de default questionnaire configuration in `app/config/config.yml` ``` yml qcm_core: website_name: Qcm Demo // The website name configuration: max_questions: 40 //Questions number max by questionnaire question_level: ["beginner", "senior", "jedi"] //Determine the level for each question answers_max: 5 //Number of answers max by question timeout: 2400 //Total time of the questionnaire (in seconds) time_per_question: 60 //Time per question, if you choose this value, the timeout will be disabled

Override service

For statistics class:, (*9)

yml qcm_core: service: statistics: class: MyBundle\Statistics\Class // For better compatibility extends the Model\QuestionnaireStatistics template: MyBundle\Answers\Template\Class // You need to implements the qcm TemplateInterface, (*10)

Credits

License

This bundle is released under the MIT license. See the complete license in the bundle:, (*11)

License, (*12)

The Versions

20/09 2017

dev-master

9999999-dev

QCM Core bundle for Symfony2

  Sources   Download

MIT

The Requires

 

The Development Requires

by Jérémy Jégou

07/09 2016

1.0.3

1.0.3.0

QCM Core bundle for Symfony2

  Sources   Download

MIT

The Requires

 

The Development Requires

by Jérémy Jégou

23/04 2015

1.0.2

1.0.2.0

QCM Core bundle for Symfony2

  Sources   Download

MIT

The Requires

 

The Development Requires

by Jérémy Jégou

23/04 2015

1.0.1

1.0.1.0

QCM Core bundle for Symfony2

  Sources   Download

MIT

The Requires

 

The Development Requires

by Jérémy Jégou

22/04 2015

1.0.0

1.0.0.0

QCM Core bundle for Symfony2

  Sources   Download

MIT

The Requires

 

The Development Requires

by Jérémy Jégou