Commit 4faee133 authored by Björn Bartels's avatar Björn Bartels

tabs 2 spaces

parent 369dda8a
......@@ -4,112 +4,112 @@
*
* BaseApp
*
* @package [MyApplication]
* @package BB's Zend Framework 2 Components
* @package BaseApp
* @author Björn Bartels <development@bjoernbartels.earth>
* @link https://gitlab.bjoernbartels.earth/groups/zf2
* @license http://www.apache.org/licenses/LICENSE-2.0 Apache License, Version 2.0
* @copyright copyright (c) 2016 Björn Bartels <development@bjoernbartels.earth>
* @package [MyApplication]
* @package BB's Zend Framework 2 Components
* @package BaseApp
* @author Björn Bartels <development@bjoernbartels.earth>
* @link https://gitlab.bjoernbartels.earth/groups/zf2
* @license http://www.apache.org/licenses/LICENSE-2.0 Apache License, Version 2.0
* @copyright copyright (c) 2016 Björn Bartels <development@bjoernbartels.earth>
*/
return array(
'app' => array(
'title' => '[MyApplication]',
'short_title' => 'MyApp',
'favicon' => 'img/favicon.ico',
'apple_touch_icon' => 'img/apple-touch-icon.png',
'logo' => 'img/zf2-logo.png',
'app' => array(
'title' => '[MyApplication]',
'short_title' => 'MyApp',
'favicon' => 'img/favicon.ico',
'apple_touch_icon' => 'img/apple-touch-icon.png',
'logo' => 'img/zf2-logo.png',
'css' => array(
),
'js' => array(
),
),
// This should be an array of module namespaces used in the application.
'modules' => array(
'Application',
'ZfcBase',
'ZfcUser',
'SlmLocale',
'OrgHeiglPiwik',
'ZeTheme',
'css' => array(
),
'js' => array(
),
),
// This should be an array of module namespaces used in the application.
'modules' => array(
'Application',
'ZfcBase',
'ZfcUser',
'SlmLocale',
'OrgHeiglPiwik',
'ZeTheme',
'UIComponents',
'Admin',
),
// These are various options for the listeners attached to the ModuleManager
'module_listener_options' => array(
// This should be an array of paths in which modules reside.
// If a string key is provided, the listener will consider that a module
// namespace, the value of that key the specific path to that module's
// Module class.
'module_paths' => array(
'./public/themes',
'./module',
'./vendor',
'UIComponents',
'Admin',
),
// These are various options for the listeners attached to the ModuleManager
'module_listener_options' => array(
// This should be an array of paths in which modules reside.
// If a string key is provided, the listener will consider that a module
// namespace, the value of that key the specific path to that module's
// Module class.
'module_paths' => array(
'./public/themes',
'./module',
'./vendor',
//'UIComponents' => '../module-uicomponents/',
//'Admin' => '../module-admin/',
),
//'UIComponents' => '../module-uicomponents/',
//'Admin' => '../module-admin/',
),
// An array of paths from which to glob configuration files after
// modules are loaded. These effectively override configuration
// provided by modules themselves. Paths may use GLOB_BRACE notation.
'config_glob_paths' => array(
'config/autoload/{,*.}{global,local}.php',
),
// An array of paths from which to glob configuration files after
// modules are loaded. These effectively override configuration
// provided by modules themselves. Paths may use GLOB_BRACE notation.
'config_glob_paths' => array(
'config/autoload/{,*.}{global,local}.php',
),
// Whether or not to enable a configuration cache.
// If enabled, the merged configuration will be cached and used in
// subsequent requests.
//'config_cache_enabled' => $booleanValue,
// Whether or not to enable a configuration cache.
// If enabled, the merged configuration will be cached and used in
// subsequent requests.
//'config_cache_enabled' => $booleanValue,
// The key used to create the configuration cache file name.
//'config_cache_key' => $stringKey,
// The key used to create the configuration cache file name.
//'config_cache_key' => $stringKey,
// Whether or not to enable a module class map cache.
// If enabled, creates a module class map cache which will be used
// by in future requests, to reduce the autoloading process.
//'module_map_cache_enabled' => $booleanValue,
// Whether or not to enable a module class map cache.
// If enabled, creates a module class map cache which will be used
// by in future requests, to reduce the autoloading process.
//'module_map_cache_enabled' => $booleanValue,
// The key used to create the class map cache file name.
//'module_map_cache_key' => $stringKey,
// The key used to create the class map cache file name.
//'module_map_cache_key' => $stringKey,
// The path in which to cache merged configuration.
//'cache_dir' => $stringPath,
// The path in which to cache merged configuration.
//'cache_dir' => $stringPath,
// Whether or not to enable modules dependency checking.
// Enabled by default, prevents usage of modules that depend on other modules
// that weren't loaded.
// 'check_dependencies' => true,
),
// Whether or not to enable modules dependency checking.
// Enabled by default, prevents usage of modules that depend on other modules
// that weren't loaded.
// 'check_dependencies' => true,
),
// Used to create an own service manager. May contain one or more child arrays.
//'service_listener_options' => array(
// array(
// 'service_manager' => $stringServiceManagerName,
// 'config_key' => $stringConfigKey,
// 'interface' => $stringOptionalInterface,
// 'method' => $stringRequiredMethodName,
// ),
// )
// Used to create an own service manager. May contain one or more child arrays.
//'service_listener_options' => array(
// array(
// 'service_manager' => $stringServiceManagerName,
// 'config_key' => $stringConfigKey,
// 'interface' => $stringOptionalInterface,
// 'method' => $stringRequiredMethodName,
// ),
// )
// Initial configuration with which to seed the ServiceManager.
// Should be compatible with Zend\ServiceManager\Config.
// 'service_manager' => array(),
'view_helper_config' => array(
'flashmessenger' => array(
'message_open_format' => '<div%s><button type="button" class="close-button close" data-dismiss="alert" aria-hidden="true">&times;</button><span>',
'message_close_string' => '</span></div>',
'message_separator_string' => '</span><br /><span>'
)
),
'view_helper_config' => array(
'flashmessenger' => array(
'message_open_format' => '<div%s><button type="button" class="close-button close" data-dismiss="alert" aria-hidden="true">&times;</button><span>',
'message_close_string' => '</span></div>',
'message_separator_string' => '</span><br /><span>'
)
),
);
......@@ -12,28 +12,28 @@
*/
return array(
/**
* global database setup
**/
'db' => array(
'driver' => 'PdoMysql',
'hostname' => 'database.host', // with some system configurations try IP instead of a hostname
'database' => 'dbname',
'username' => 'dbuser',
'password' => 'dbpassword',
),
'service_manager' => array(
'factories' => array(
'Zend\Db\Adapter\Adapter' => 'Zend\Db\Adapter\AdapterServiceFactory',
),
),
/**
* cache configuration, un-comment when enabled in your system/php/host-setup
**/
/*'caches' => array(
'CacheService' => array(
/**
* global database setup
**/
'db' => array(
'driver' => 'PdoMysql',
'hostname' => 'database.host', // with some system configurations try IP instead of a hostname
'database' => 'dbname',
'username' => 'dbuser',
'password' => 'dbpassword',
),
'service_manager' => array(
'factories' => array(
'Zend\Db\Adapter\Adapter' => 'Zend\Db\Adapter\AdapterServiceFactory',
),
),
/**
* cache configuration, un-comment when enabled in your system/php/host-setup
**/
/*'caches' => array(
'CacheService' => array(
'adapter' => array(
'name' =>'memcached',
'ttl' => 3600,
......@@ -59,61 +59,61 @@ return array(
),
),
),
),*/
/**
* SMTP configuration
**/
'zfcuser_smtp' => array(
'name' => 'example.com',
'host' => '127.0.0.1',
'port' => 587, // Notice port change for TLS is 587
'connection_class' => 'plain',
'connection_config' => array(
'username' => 'user',
'password' => 'pass',
),
),
/**
* HTTP basepath in email links
**/
'zfcuser_mail_http_basepath' => "http://".$_SERVER["HTTP_HOST"],
/**
* registration redirect route to go upon successful user registration,
* user's confirmation and admin's activation
**/
'zfcuser_registration_redirect_route' => 'home',
/**
* user must confirm new registration via mail
**/
'zfcuser_user_must_confirm' => true,
/**
* email adress to send confirmation mail from
**/
'zfcuser_admin_from_email' => 'no-reply@example.com',
/**
* email subject for confirmation mail
**/
'zfcuser_confirm_subject' => "[myApplication] Benutzer-Bestätigung",
/**
* admin must active new user via notification mail
**/
'zfcuser_admin_must_activate' => true,
/**
* admin's email adress to recieve activation mail
**/
'zfcuser_admin_to_email' => 'useradmin@example.com',
/**
* email subject for activation mail
**/
'zfcuser_activate_subject' => "[myApplication] Benutzer-Aktivierung",
),*/
/**
* SMTP configuration
**/
'zfcuser_smtp' => array(
'name' => 'example.com',
'host' => '127.0.0.1',
'port' => 587, // Notice port change for TLS is 587
'connection_class' => 'plain',
'connection_config' => array(
'username' => 'user',
'password' => 'pass',
),
),
/**
* HTTP basepath in email links
**/
'zfcuser_mail_http_basepath' => "http://".$_SERVER["HTTP_HOST"],
/**
* registration redirect route to go upon successful user registration,
* user's confirmation and admin's activation
**/
'zfcuser_registration_redirect_route' => 'home',
/**
* user must confirm new registration via mail
**/
'zfcuser_user_must_confirm' => true,
/**
* email adress to send confirmation mail from
**/
'zfcuser_admin_from_email' => 'no-reply@example.com',
/**
* email subject for confirmation mail
**/
'zfcuser_confirm_subject' => "[myApplication] Benutzer-Bestätigung",
/**
* admin must active new user via notification mail
**/
'zfcuser_admin_must_activate' => true,
/**
* admin's email adress to recieve activation mail
**/
'zfcuser_admin_to_email' => 'useradmin@example.com',
/**
* email subject for activation mail
**/
'zfcuser_activate_subject' => "[myApplication] Benutzer-Aktivierung",
);
<?php
return array(
'db' => array( // global database setup
'driver' => 'PdoMysql',
'hostname' => '_MYSQL_HOST_',
'database' => '_MYSQL_DATABASE_',
'username' => '_MYSQL_USER_',
'password' => '_MYSQL_PASSWORD_',
),
'service_manager' => array(
'factories' => array(
'Zend\Db\Adapter\Adapter' => 'Zend\Db\Adapter\AdapterServiceFactory',
),
),
'db' => array( // global database setup
'driver' => 'PdoMysql',
'hostname' => '_MYSQL_HOST_',
'database' => '_MYSQL_DATABASE_',
'username' => '_MYSQL_USER_',
'password' => '_MYSQL_PASSWORD_',
),
'service_manager' => array(
'factories' => array(
'Zend\Db\Adapter\Adapter' => 'Zend\Db\Adapter\AdapterServiceFactory',
),
),
);
\ No newline at end of file
......@@ -12,5 +12,5 @@
*/
return array(
// ...
// ...
);
......@@ -6,70 +6,70 @@
* drop this config file in it and change the values as you wish.
*/
$settings = array(
/**
* Default locale
*
* Some good description here. Default is something
*
* Accepted is something else
*/
'default' => 'en_US',
/**
* Default locale
*
* Some good description here. Default is something
*
* Accepted is something else
*/
'default' => 'en_US',
/**
* Supported locales
*
* Some good description here. Default is something
*
* Accepted is something else
*/
'supported' => array('de_DE', 'en_US', 'fr_FR'),
/**
* Supported locales
*
* Some good description here. Default is something
*
* Accepted is something else
*/
'supported' => array('de_DE', 'en_US', 'fr_FR'),
'aliases' => array(
'de' => 'de_DE',
'en' => 'en_US',
'fr' => 'fr_FR',
'es' => 'es_ES',
'nl' => 'nl_NL',
'it' => 'it_IT',
),
'aliases' => array(
'de' => 'de_DE',
'en' => 'en_US',
'fr' => 'fr_FR',
'es' => 'es_ES',
'nl' => 'nl_NL',
'it' => 'it_IT',
),
/**
* Strategies
*
* Some good description here. Default is something
*
* Accepted is something else
*/
'strategies' => array(
/* array(
'name' => 'host',
'options' => array(
'domain' => 'www.example.:locale',
'aliases' => array('com' => 'en_US', 'net' => 'en_US', 'de' => 'de_DE'),
),
), */
array(
'name' => 'uripath',
'options' => array(
'aliases' => array('de' => 'de_DE', 'en' => 'en_US', 'fr' => 'fr_FR'),
),
'priority' => 1
),
array(
'name' => 'acceptlanguage',
'priority' => 0.5
)
),
/**
* Strategies
*
* Some good description here. Default is something
*
* Accepted is something else
*/
'strategies' => array(
/* array(
'name' => 'host',
'options' => array(
'domain' => 'www.example.:locale',
'aliases' => array('com' => 'en_US', 'net' => 'en_US', 'de' => 'de_DE'),
),
), */
array(
'name' => 'uripath',
'options' => array(
'aliases' => array('de' => 'de_DE', 'en' => 'en_US', 'fr' => 'fr_FR'),
),
'priority' => 1
),
array(
'name' => 'acceptlanguage',
'priority' => 0.5
)
),
/**
* End of SlmLocale configuration
*/
/**
* End of SlmLocale configuration
*/
);
/**
* You do not need to edit below this line
*/
return array(
'slm_locale' => $settings
'slm_locale' => $settings
);
......@@ -4,57 +4,57 @@
*
* BaseApp
*
* @package [MyApplication]
* @package BB's Zend Framework 2 Components
* @package BaseApp
* @author Björn Bartels <development@bjoernbartels.earth>
* @link https://gitlab.bjoernbartels.earth/groups/zf2
* @license http://www.apache.org/licenses/LICENSE-2.0 Apache License, Version 2.0
* @copyright copyright (c) 2016 Björn Bartels <development@bjoernbartels.earth>
* @package [MyApplication]
* @package BB's Zend Framework 2 Components
* @package BaseApp
* @author Björn Bartels <development@bjoernbartels.earth>
* @link https://gitlab.bjoernbartels.earth/groups/zf2
* @license http://www.apache.org/licenses/LICENSE-2.0 Apache License, Version 2.0
* @copyright copyright (c) 2016 Björn Bartels <development@bjoernbartels.earth>
*/
return array(
'navigation' => array(
'default' => array(
'home' => array(
'label' => 'home',
'icon' => 'home',
'route' => 'home',
'order' => 0,
'pages' => array(
),
),
'help' => array(
'label' => 'help',
'icon' => 'question-circle',
'route' => 'application/default',
'controller' => 'index',
'action' => 'notimplementedyet',
'order' => 99999,
'pages' => array(
array(
'label' => 'help',
'icon' => 'question-circle',
'route' => 'application/default',
'controller' => 'index',
'action' => 'help',
),
array(
'label' => 'support',
'icon' => 'envelope',
'route' => 'application/default',
'controller' => 'index',
'action' => 'support',
),
array(
'label' => 'about',
'icon' => 'info-circle',
'route' => 'application/default',
'controller' => 'index',
'action' => 'about',
),
),
),
),
),
'navigation' => array(
'default' => array(
'home' => array(
'label' => 'home',
'icon' => 'home',
'route' => 'home',
'order' => 0,
'pages' => array(
),
),
'help' => array(
'label' => 'help',
'icon' => 'question-circle',
'route' => 'application/default',
'controller' => 'index',
'action' => 'notimplementedyet',
'order' => 99999,
'pages' => array(
array(
'label' => 'help',
'icon' => 'question-circle',
'route' => 'application/default',
'controller' => 'index',
'action' => 'help',
),
array(
'label' => 'support',
'icon' => 'envelope',
'route' => 'application/default',
'controller' => 'index',
'action' => 'support',
),
array(
'label' => 'about',
'icon' => 'info-circle',
'route' => 'application/default',
'controller' => 'index',
'action' => 'about',
),
),
),
),
),
);
\ No newline at end of file
<?php
return array(
'ze_theme' => array(
'default_theme' => "bootstrap",
'custom_theme_path' => true,
'theme_paths' => array(
__DIR__ . "/../../public/themes/{theme}/",
),
'routes' => array(
// 'theme_name' => array('route_names'),
),
'adapters' => array(
"ZeTheme\Adapter\Configuration",
//"ZeTheme\Adapter\Route",
//"ZeTheme\Adapter\Session",
),
),
'ze_theme' => array(
'default_theme' => "bootstrap",
'custom_theme_path' => true,
'theme_paths' => array(
__DIR__ . "/../../public/themes/{theme}/",
),
'routes' => array(
// 'theme_name' => array('route_names'),
),
'adapters' => array(
"ZeTheme\Adapter\Configuration",
//"ZeTheme\Adapter\Route",
//"ZeTheme\Adapter\Session",
),
),
);
\ No newline at end of file
This diff is collapsed.
......@@ -79,9 +79,9 @@ class Module implements AutoloaderProviderInterface, ServiceLocatorAwareInterfac
$serviceManager = $application->getServiceManager();
static::$services = $serviceManager;
/*$serviceManager->addInitializer(function ($instance) use ($serviceManager) {
if ($instance instanceof ServiceLocatorAwareInterface) {
$instance->setServiceLocator($serviceManager);
}
if ($instance instanceof ServiceLocatorAwareInterface) {
$instance->setServiceLocator($serviceManager);
}
});*/
/**
......@@ -244,12 +244,12 @@ class Module implements AutoloaderProviderInterface, ServiceLocatorAwareInterfac
public static function getService($name)
{
try {
$serviceManager = static::$services;
return $serviceManager->get($name);
} catch (\Exception $e) {
}
return (null);
try {
$serviceManager = static::$services;
return $serviceManager->get($name);
} catch (\Exception $e) {
}
return (null);
}
public function getConsoleUsage(Console $console)
......
......@@ -97,7 +97,7 @@ return array(
'router' => array(
'routes' => array(
'update-db' => array(
//'type' => 'simple',
//'type' => 'simple',
'options' => array(
'route' => 'update-db [--test] [--verbose|-v]:verbose',
'defaults' => array(
......