-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #10 from wfp/develop
develop
- Loading branch information
Showing
13 changed files
with
1,038 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
vendor |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,47 @@ | ||
# Survey Manager | ||
Module for managing third-party surveys in Drupal 8. | ||
|
||
# Installation | ||
|
||
Download and enable it as a regular module. | ||
|
||
# How it works | ||
This module uses Block API, every survey is just a specific type of block. | ||
|
||
This gives you flexibility of block visibility settings. You can control how, where and who will see the survey. | ||
|
||
|
||
There are 2 types of surveys: | ||
|
||
## Embed survey | ||
This is a type of survey where you can put/embed third party JS scripts (e.g. SurveyMonkey). | ||
You put Embed surveys in some region but they wont appear in any of them, their contents of embed code will be printed at the bottom of the page as a script. | ||
|
||
|
||
## HTML Survey | ||
This is just a regular block, it has a field for storing whatever HTML you want and it will be printed out as a regular block in regions or as a filter in any content. | ||
|
||
|
||
# Usage | ||
After installing this module you will see Survey Manger link under Structure menu. This is where all your surveys reside. | ||
|
||
You can create or edit surveys from that page. | ||
|
||
## Usage of filter [survey:id] | ||
This module implements filter for text formatters, you can enable this filter from your text formmatter configuration page. | ||
After enabling this filter you can use it in your content. e.g [survey:123] where 123 is the id of the survey you want to embed in your content. | ||
This Filter works fro HTML Surveys. | ||
|
||
|
||
# Developer Guideline | ||
|
||
``` | ||
# Install development dependencies | ||
composer install | ||
# Run PHP code audits | ||
composer run phpcs | ||
# Run PHP Copy-Paste detector | ||
composer run phpcpd | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
{ | ||
"name": "drupal/survey_manager", | ||
"type": "drupal-module", | ||
"description": "Manage third-party surveys", | ||
"authors": [ | ||
{ | ||
"name": "Otar Zakalashvili", | ||
"email": "oto.zakalashvili@gmail.com", | ||
"homepage": "http://otarza.space" | ||
} | ||
], | ||
"keywords": [ | ||
"survey" | ||
], | ||
"license": "GPL-2.0+", | ||
"homepage": "http://drupal.org/project/survey_manager", | ||
"require": { | ||
"php": ">=5.5.9" | ||
}, | ||
"require-dev": { | ||
"drupal/coder": "8.2.5", | ||
"andrewholgate/drupalstrict": "0.1.1", | ||
"sebastian/phpcpd": "2.0.2" | ||
}, | ||
"scripts": { | ||
"phpcs": "./vendor/bin/phpcs --standard=Drupal,DrupalPractice,DrupalStrict --extensions=php,module,install,profile,drush.inc,test,admin.inc,yml,js,css --report-width=4 --colors --ignore=vendor/ ./", | ||
"phpcpd": "./vendor/bin/phpcpd --names *.php,*.module,*.profile,*.install,*.drush.inc,*.test --min-lines 6 --min-tokens 10 --fuzzy --exclude=vendor ./", | ||
"audit": "composer run phpcs && composer run phpcpd", | ||
"post-install-cmd": [ | ||
"[ -f ./vendor/bin/phpcs ]; ./vendor/bin/phpcs --config-set installed_paths ../../drupal/coder/coder_sniffer,../../andrewholgate/drupalstrict" | ||
] | ||
} | ||
} |
Oops, something went wrong.