-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 1434b89
Showing
9 changed files
with
455 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,46 @@ | ||
# Eclipse Files | ||
/.classpath | ||
/.buildpath | ||
/.project | ||
/.settings/ | ||
|
||
# Cache and logs (Symfony2) | ||
/app/cache/* | ||
/app/logs/* | ||
!app/cache/.gitkeep | ||
!app/logs/.gitkeep | ||
|
||
# Cache and logs (Symfony3) | ||
/var/cache/* | ||
/var/logs/* | ||
!var/cache/.gitkeep | ||
!var/logs/.gitkeep | ||
|
||
# Parameters | ||
/app/config/parameters.yml | ||
/app/config/parameters.ini | ||
|
||
# Managed by Composer | ||
/app/bootstrap.php.cache | ||
/var/bootstrap.php.cache | ||
/bin/* | ||
!bin/console | ||
!bin/symfony_requirements | ||
/vendor/ | ||
|
||
# Assets and user uploads | ||
/web/bundles/ | ||
/web/uploads/ | ||
|
||
# PHPUnit | ||
/app/phpunit.xml | ||
/phpunit.xml | ||
|
||
# Build data | ||
/build/ | ||
|
||
# Composer PHAR | ||
/composer.phar | ||
|
||
# Composer lock | ||
/composer.lock |
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,21 @@ | ||
The MIT License (MIT) | ||
|
||
Copyright (c) 2016 Salah Abdelkader Seif Eddine | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
|
||
The above copyright notice and this permission notice shall be included in all | ||
copies or substantial portions of the Software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
SOFTWARE. |
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,4 @@ | ||
sasedev/mpdf-bundle | ||
========================= | ||
|
||
Mpdf Bundle for Symfony2 (3.0) |
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,36 @@ | ||
{ | ||
"name" : "sasedev/mpdf-bundle", | ||
"description" : "Mpdf for Symfony2 (3.0)", | ||
"require" : { | ||
"php" : ">=5.5", | ||
"mpdf/mpdf" : "6.0.*", | ||
"symfony/twig-bridge" : "~2.8|~3.0", | ||
"symfony/monolog-bridge" : "~2.8|~3.0", | ||
"symfony/http-foundation" : "~2.8|~3.0", | ||
"symfony/config" : "~2.8|~3.0", | ||
"symfony/dependency-injection" : "~2.8|~3.0", | ||
"symfony/yaml" : "~2.8|~3.0", | ||
"symfony/http-kernel" : "~2.8|~3.0" | ||
}, | ||
"license" : "MIT", | ||
"keywords" : [ | ||
"symfony2", | ||
"form" | ||
], | ||
"extra" : { | ||
"branch-alias" : { | ||
"dev-master" : "1.0.x-dev" | ||
} | ||
}, | ||
"autoload" : { | ||
"psr-4" : { | ||
"" : "src" | ||
} | ||
}, | ||
"type" : "symfony-bundle", | ||
"authors" : [{ | ||
"name" : "Salah Abdelkader Seif Eddine", | ||
"email" : "[email protected]" | ||
} | ||
] | ||
} |
35 changes: 35 additions & 0 deletions
35
src/Sasedev/MpdfBundle/DependencyInjection/Configuration.php
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,35 @@ | ||
<?php | ||
|
||
namespace Sasedev\MpdfBundle\DependencyInjection; | ||
|
||
use Symfony\Component\Config\Definition\Builder\TreeBuilder; | ||
use Symfony\Component\Config\Definition\ConfigurationInterface; | ||
|
||
/** | ||
* This is the class that validates and merges configuration from your app/config files. | ||
* To learn more see {@link http://symfony.com/doc/current/cookbook/bundles/configuration.html} | ||
*/ | ||
class Configuration implements ConfigurationInterface | ||
{ | ||
|
||
/** | ||
* | ||
* {@inheritdoc} | ||
* | ||
*/ | ||
public function getConfigTreeBuilder() | ||
{ | ||
|
||
$treeBuilder = new TreeBuilder(); | ||
// $rootNode = $treeBuilder->root('sasedev_mpdf'); | ||
$treeBuilder->root('sasedev_mpdf'); | ||
|
||
// Here you should define the parameters that are allowed to | ||
// configure your bundle. See the documentation linked above for | ||
// more information on that topic. | ||
|
||
return $treeBuilder; | ||
|
||
} | ||
|
||
} |
35 changes: 35 additions & 0 deletions
35
src/Sasedev/MpdfBundle/DependencyInjection/SasedevMpdfExtension.php
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,35 @@ | ||
<?php | ||
|
||
namespace Sasedev\MpdfBundle\DependencyInjection; | ||
|
||
use Symfony\Component\DependencyInjection\ContainerBuilder; | ||
use Symfony\Component\Config\FileLocator; | ||
use Symfony\Component\HttpKernel\DependencyInjection\Extension; | ||
use Symfony\Component\DependencyInjection\Loader; | ||
|
||
/** | ||
* This is the class that loads and manages your bundle configuration. | ||
* | ||
* @link http://symfony.com/doc/current/cookbook/bundles/extension.html | ||
*/ | ||
class SasedevMpdfExtension extends Extension | ||
{ | ||
|
||
/** | ||
* | ||
* {@inheritdoc} | ||
* | ||
*/ | ||
public function load(array $configs, ContainerBuilder $container) | ||
{ | ||
|
||
$configuration = new Configuration(); | ||
// $config = $this->processConfiguration($configuration, $configs); | ||
$this->processConfiguration($configuration, $configs); | ||
|
||
$loader = new Loader\YamlFileLoader($container, new FileLocator(__DIR__ . '/../Resources/config')); | ||
$loader->load('services.yml'); | ||
|
||
} | ||
|
||
} |
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,7 @@ | ||
parameters: | ||
sasedev_mpdf.class: Sasedev\MpdfBundle\Service\MpdfService | ||
|
||
services: | ||
sasedev_mpdf: | ||
class: "%sasedev_mpdf.class%" | ||
arguments: ["@templating", "@logger", "%kernel.cache_dir%"] |
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,9 @@ | ||
<?php | ||
|
||
namespace Sasedev\MpdfBundle; | ||
|
||
use Symfony\Component\HttpKernel\Bundle\Bundle; | ||
|
||
class SasedevMpdfBundle extends Bundle | ||
{ | ||
} |
Oops, something went wrong.