Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/apps.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBernhard Posselt <nukeawhale@gmail.com>2012-11-19 05:23:27 +0400
committerBernhard Posselt <nukeawhale@gmail.com>2012-11-19 05:23:27 +0400
commit9550d32b413d11420133752d224c8da6d1f1ed49 (patch)
tree739feff0f4cc1ae51dc240768f5d3bc72564f04f /apptemplate
parenta18208994d3d1eb7366fbc1111d02807e9efa7a7 (diff)
removed problematic constant
Diffstat (limited to 'apptemplate')
-rw-r--r--apptemplate/appinfo/app.php10
-rw-r--r--apptemplate/appinfo/bootstrap.php6
-rw-r--r--apptemplate/appinfo/routes.php4
3 files changed, 8 insertions, 12 deletions
diff --git a/apptemplate/appinfo/app.php b/apptemplate/appinfo/app.php
index 83c94a6f0..9160daeca 100644
--- a/apptemplate/appinfo/app.php
+++ b/apptemplate/appinfo/app.php
@@ -29,12 +29,12 @@
require_once \OC_App::getAppPath('apptemplate') . '/appinfo/bootstrap.php';
-OCP\App::registerAdmin(APP_NAME, 'admin/settings');
+OCP\App::registerAdmin('apptemplate', 'admin/settings');
OCP\App::addNavigationEntry( array(
- 'id' => APP_NAME,
+ 'id' => 'apptemplate',
'order' => 74,
- 'href' => \OC_Helper::linkToRoute(APP_NAME . '_index'),
- 'icon' => OCP\Util::imagePath(APP_NAME, 'example.png' ),
- 'name' => \OC_L10N::get(APP_NAME)->t('App Template')
+ 'href' => \OC_Helper::linkToRoute('apptemplate_index'),
+ 'icon' => OCP\Util::imagePath('apptemplate', 'example.png' ),
+ 'name' => \OC_L10N::get('apptemplate')->t('App Template')
));
diff --git a/apptemplate/appinfo/bootstrap.php b/apptemplate/appinfo/bootstrap.php
index 0e3f26c19..7928a906a 100644
--- a/apptemplate/appinfo/bootstrap.php
+++ b/apptemplate/appinfo/bootstrap.php
@@ -23,10 +23,6 @@
namespace OCA\AppTemplate;
-/* Config */
-DEFINE('APP_NAME', 'apptemplate');
-
-
/**
* Declare your classes and their include path so that they'll be automatically
* loaded once you instantiate them
@@ -53,7 +49,7 @@ function createDIContainer(){
* BASE
*/
$container['API'] = $container->share(function($c){
- return new API(APP_NAME);
+ return new API('apptemplate');
});
$container['Security'] = $container->share(function($c){
diff --git a/apptemplate/appinfo/routes.php b/apptemplate/appinfo/routes.php
index 12407db97..7ebf18389 100644
--- a/apptemplate/appinfo/routes.php
+++ b/apptemplate/appinfo/routes.php
@@ -64,7 +64,7 @@ function callController($controllerName, $methodName, $urlParams,
/**
* Normal Routes
*/
-$this->create(APP_NAME. '_index', '/')->action(
+$this->create('apptemplate_index', '/')->action(
function($params){
callController('IndexController', 'index', $params, true);
}
@@ -73,7 +73,7 @@ $this->create(APP_NAME. '_index', '/')->action(
/**
* Ajax Routes
*/
-$this->create(APP_NAME . '_ajax_setsystemvalue', '/setsystemvalue')->post()->action(
+$this->create('apptemplate_ajax_setsystemvalue', '/setsystemvalue')->post()->action(
function($params){
$container = createDIContainer();