mirror of
https://github.com/silverstripe/recipe-cms.git
synced 2024-10-22 08:05:52 +02:00
Merge remote-tracking branch 'origin/1'
# Conflicts: # composer.json
This commit is contained in:
commit
47b47ef932
@ -1,2 +1,2 @@
|
|||||||
RewriteEngine On
|
RewriteEngine On
|
||||||
RewriteRule .* public/%1
|
RewriteRule ^(.*)$ public/$1
|
||||||
|
13
app/src/Page.php
Executable file
13
app/src/Page.php
Executable file
@ -0,0 +1,13 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
namespace {
|
||||||
|
|
||||||
|
use SilverStripe\CMS\Model\SiteTree;
|
||||||
|
|
||||||
|
class Page extends SiteTree
|
||||||
|
{
|
||||||
|
private static $db = [];
|
||||||
|
|
||||||
|
private static $has_one = [];
|
||||||
|
}
|
||||||
|
}
|
33
app/src/PageController.php
Normal file
33
app/src/PageController.php
Normal file
@ -0,0 +1,33 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
namespace {
|
||||||
|
|
||||||
|
use SilverStripe\CMS\Controllers\ContentController;
|
||||||
|
|
||||||
|
class PageController extends ContentController
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* An array of actions that can be accessed via a request. Each array element should be an action name, and the
|
||||||
|
* permissions or conditions required to allow the user to access it.
|
||||||
|
*
|
||||||
|
* <code>
|
||||||
|
* [
|
||||||
|
* 'action', // anyone can access this action
|
||||||
|
* 'action' => true, // same as above
|
||||||
|
* 'action' => 'ADMIN', // you must have ADMIN permissions to access this action
|
||||||
|
* 'action' => '->checkAction' // you can only access this action if $this->checkAction() returns true
|
||||||
|
* ];
|
||||||
|
* </code>
|
||||||
|
*
|
||||||
|
* @var array
|
||||||
|
*/
|
||||||
|
private static $allowed_actions = [];
|
||||||
|
|
||||||
|
protected function init()
|
||||||
|
{
|
||||||
|
parent::init();
|
||||||
|
// You can include any CSS or JS required by your project here.
|
||||||
|
// See: https://docs.silverstripe.org/en/developer_guides/templates/requirements/
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
@ -5,7 +5,7 @@
|
|||||||
"homepage": "http://silverstripe.org",
|
"homepage": "http://silverstripe.org",
|
||||||
"license": "BSD-3-Clause",
|
"license": "BSD-3-Clause",
|
||||||
"require": {
|
"require": {
|
||||||
"silverstripe/recipe-plugin": "^1",
|
"silverstripe/recipe-plugin": "^1.2",
|
||||||
"silverstripe/recipe-core": "2.x-dev",
|
"silverstripe/recipe-core": "2.x-dev",
|
||||||
"silverstripe/admin": "2.x-dev",
|
"silverstripe/admin": "2.x-dev",
|
||||||
"silverstripe/asset-admin": "2.x-dev",
|
"silverstripe/asset-admin": "2.x-dev",
|
||||||
@ -22,7 +22,7 @@
|
|||||||
},
|
},
|
||||||
"extra": {
|
"extra": {
|
||||||
"project-files": [
|
"project-files": [
|
||||||
"mysite/code/*"
|
"app/src/*"
|
||||||
],
|
],
|
||||||
"branch-alias": {
|
"branch-alias": {
|
||||||
"dev-master": "2.x-dev"
|
"dev-master": "2.x-dev"
|
||||||
|
@ -1,10 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
use SilverStripe\CMS\Model\SiteTree;
|
|
||||||
|
|
||||||
class Page extends SiteTree
|
|
||||||
{
|
|
||||||
private static $db = [];
|
|
||||||
|
|
||||||
private static $has_one = [];
|
|
||||||
}
|
|
@ -1,30 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
use SilverStripe\CMS\Controllers\ContentController;
|
|
||||||
|
|
||||||
class PageController extends ContentController
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* An array of actions that can be accessed via a request. Each array element should be an action name, and the
|
|
||||||
* permissions or conditions required to allow the user to access it.
|
|
||||||
*
|
|
||||||
* <code>
|
|
||||||
* [
|
|
||||||
* 'action', // anyone can access this action
|
|
||||||
* 'action' => true, // same as above
|
|
||||||
* 'action' => 'ADMIN', // you must have ADMIN permissions to access this action
|
|
||||||
* 'action' => '->checkAction' // you can only access this action if $this->checkAction() returns true
|
|
||||||
* ];
|
|
||||||
* </code>
|
|
||||||
*
|
|
||||||
* @var array
|
|
||||||
*/
|
|
||||||
private static $allowed_actions = [];
|
|
||||||
|
|
||||||
protected function init()
|
|
||||||
{
|
|
||||||
parent::init();
|
|
||||||
// You can include any CSS or JS required by your project here.
|
|
||||||
// See: https://docs.silverstripe.org/en/developer_guides/templates/requirements/
|
|
||||||
}
|
|
||||||
}
|
|
Loading…
Reference in New Issue
Block a user