mirror of
https://github.com/silverstripe/recipe-cms.git
synced 2024-10-22 08:05:52 +02:00
Compare commits
1 Commits
4
...
1.0.0-beta
Author | SHA1 | Date | |
---|---|---|---|
|
7efa75355b |
@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"github-slug": "silverstripe/recipe-cms",
|
"github-slug": "silverstripe/recipe-cms",
|
||||||
"child-stability-inherit": true,
|
"child-stability-inherit": true,
|
||||||
"dependency-constraint": "loose",
|
"dependency-constraint": "exact",
|
||||||
"vendors": [
|
"vendors": [
|
||||||
"silverstripe"
|
"silverstripe"
|
||||||
],
|
],
|
||||||
|
11
.github/workflows/ci.yml
vendored
11
.github/workflows/ci.yml
vendored
@ -1,11 +0,0 @@
|
|||||||
name: CI
|
|
||||||
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
pull_request:
|
|
||||||
workflow_dispatch:
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
ci:
|
|
||||||
name: CI
|
|
||||||
uses: silverstripe/gha-ci/.github/workflows/ci.yml@v1
|
|
16
.github/workflows/dispatch-ci.yml
vendored
16
.github/workflows/dispatch-ci.yml
vendored
@ -1,16 +0,0 @@
|
|||||||
name: Dispatch CI
|
|
||||||
|
|
||||||
on:
|
|
||||||
# At 2:10 PM UTC, only on Thursday and Friday
|
|
||||||
schedule:
|
|
||||||
- cron: '10 14 * * 4,5'
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
dispatch-ci:
|
|
||||||
name: Dispatch CI
|
|
||||||
# Only run cron on the silverstripe account
|
|
||||||
if: (github.event_name == 'schedule' && github.repository_owner == 'silverstripe') || (github.event_name != 'schedule')
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Dispatch CI
|
|
||||||
uses: silverstripe/gha-dispatch-ci@v1
|
|
17
.github/workflows/keepalive.yml
vendored
17
.github/workflows/keepalive.yml
vendored
@ -1,17 +0,0 @@
|
|||||||
name: Keepalive
|
|
||||||
|
|
||||||
on:
|
|
||||||
workflow_dispatch:
|
|
||||||
# The 4th of every month at 10:50am UTC
|
|
||||||
schedule:
|
|
||||||
- cron: '50 10 4 * *'
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
keepalive:
|
|
||||||
name: Keepalive
|
|
||||||
# Only run cron on the silverstripe account
|
|
||||||
if: (github.event_name == 'schedule' && github.repository_owner == 'silverstripe') || (github.event_name != 'schedule')
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Keepalive
|
|
||||||
uses: silverstripe/gha-keepalive@v1
|
|
24
.gitignore
vendored
24
.gitignore
vendored
@ -1,6 +1,26 @@
|
|||||||
|
# ignore cache folder
|
||||||
/silverstripe-cache/
|
/silverstripe-cache/
|
||||||
|
|
||||||
|
# ignore .env file
|
||||||
/.env
|
/.env
|
||||||
|
|
||||||
|
# ignore build tools
|
||||||
|
/tools/phing-metadata
|
||||||
|
|
||||||
|
# ignore composer vendor folder
|
||||||
/vendor/
|
/vendor/
|
||||||
|
|
||||||
|
# ignore default modules from composer
|
||||||
|
/asset-admin/
|
||||||
|
/campaign-admin/
|
||||||
|
/cms/
|
||||||
|
/framework/
|
||||||
|
/graphql/
|
||||||
|
/reports/
|
||||||
|
/silverstripe-admin/
|
||||||
|
/silverstripe-assets/
|
||||||
|
/silverstripe-errorpage/
|
||||||
|
/siteconfig/
|
||||||
/themes/simple/
|
/themes/simple/
|
||||||
/resources/
|
/versioned/
|
||||||
/public/resources/
|
/testsession/
|
||||||
|
2
LICENSE
2
LICENSE
@ -1,6 +1,6 @@
|
|||||||
BSD 3-Clause License
|
BSD 3-Clause License
|
||||||
|
|
||||||
Copyright (c) 2018, SilverStripe Ltd.
|
Copyright (c) 2017, SilverStripe Ltd.
|
||||||
All rights reserved.
|
All rights reserved.
|
||||||
|
|
||||||
Redistribution and use in source and binary forms, with or without
|
Redistribution and use in source and binary forms, with or without
|
||||||
|
13
README.md
13
README.md
@ -1,9 +1,6 @@
|
|||||||
## Silverstripe CMS Recipe
|
## SilverStripe CMS Recipe
|
||||||
|
|
||||||
[![CI](https://github.com/silverstripe/recipe-cms/actions/workflows/ci.yml/badge.svg)](https://github.com/silverstripe/recipe-cms/actions/workflows/ci.yml)
|
Base page and asset content-editing recipe for a SilverStripe ([http://silverstripe.org](http://silverstripe.org))
|
||||||
[![Silverstripe supported module](https://img.shields.io/badge/silverstripe-supported-0071C4.svg)](https://www.silverstripe.org/software/addons/silverstripe-commercially-supported-module-list/)
|
|
||||||
|
|
||||||
Base page and asset content-editing recipe for a Silverstripe ([http://silverstripe.org](http://silverstripe.org))
|
|
||||||
installation. This includes the modules:
|
installation. This includes the modules:
|
||||||
|
|
||||||
Provided by [silverstripe/recipe-core]:
|
Provided by [silverstripe/recipe-core]:
|
||||||
@ -17,17 +14,15 @@ Provided by [silverstripe/recipe-cms]:
|
|||||||
* [admin](http://github.com/silverstripe/silverstripe-admin)
|
* [admin](http://github.com/silverstripe/silverstripe-admin)
|
||||||
* [asset-admin](http://github.com/silverstripe/silverstripe-asset-admin)
|
* [asset-admin](http://github.com/silverstripe/silverstripe-asset-admin)
|
||||||
* [campaign-admin](http://github.com/silverstripe/silverstripe-campaign-admin)
|
* [campaign-admin](http://github.com/silverstripe/silverstripe-campaign-admin)
|
||||||
* [versioned-admin](http://github.com/silverstripe/silverstripe-versioned-admin)
|
|
||||||
* [cms](http://github.com/silverstripe/silverstripe-cms)
|
* [cms](http://github.com/silverstripe/silverstripe-cms)
|
||||||
* [errorpage](http://github.com/silverstripe/silverstripe-errorpage)
|
* [errorpage](http://github.com/silverstripe/silverstripe-errorpage)
|
||||||
* [reports](http://github.com/silverstripe/silverstripe-reports)
|
* [reports](http://github.com/silverstripe/silverstripe-reports)
|
||||||
* [graphql](http://github.com/silverstripe/silverstripe-graphql)
|
* [graphql](http://github.com/silverstripe/silverstripe-graphql)
|
||||||
* [session-manager](http://github.com/silverstripe/silverstripe-session-manager)
|
|
||||||
* [siteconfig](http://github.com/silverstripe/silverstripe-siteconfig)
|
* [siteconfig](http://github.com/silverstripe/silverstripe-siteconfig)
|
||||||
* [versioned](http://github.com/silverstripe/silverstripe-versioned)
|
* [versioned](http://github.com/silverstripe/silverstripe-versioned)
|
||||||
|
|
||||||
This can be either added to an existing project or used as a project base for creating a
|
This can be either added to an existing project or used as a project base for creating a
|
||||||
fully featured Silverstripe CMS project.
|
fully featured SilverStripe CMS project.
|
||||||
|
|
||||||
See the [recipe plugin](https://github.com/silverstripe/recipe-plugin) page for instructions on how
|
See the [recipe plugin](https://github.com/silverstripe/recipe-plugin) page for instructions on how
|
||||||
Silverstripe recipes work.
|
SilverStripe recipes work.
|
||||||
|
@ -1,13 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace {
|
|
||||||
|
|
||||||
use SilverStripe\CMS\Model\SiteTree;
|
|
||||||
|
|
||||||
class Page extends SiteTree
|
|
||||||
{
|
|
||||||
private static $db = [];
|
|
||||||
|
|
||||||
private static $has_one = [];
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,33 +0,0 @@
|
|||||||
<?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,29 +5,25 @@
|
|||||||
"homepage": "http://silverstripe.org",
|
"homepage": "http://silverstripe.org",
|
||||||
"license": "BSD-3-Clause",
|
"license": "BSD-3-Clause",
|
||||||
"require": {
|
"require": {
|
||||||
"php": "^7.4 || ^8.0",
|
"silverstripe/recipe-plugin": ">=0.1@dev <1.0",
|
||||||
"silverstripe/recipe-plugin": "^1.7",
|
"silverstripe/recipe-core": "1.0.0-beta4",
|
||||||
"silverstripe/recipe-core": "4.x-dev",
|
"silverstripe/admin": "1.0.0-beta4",
|
||||||
"silverstripe/admin": "1.x-dev",
|
"silverstripe/asset-admin": "1.0.0-beta4",
|
||||||
"silverstripe/asset-admin": "1.x-dev",
|
"silverstripe/campaign-admin": "1.0.0-beta4",
|
||||||
"silverstripe/campaign-admin": "1.x-dev",
|
"silverstripe/cms": "4.0.0-beta4",
|
||||||
"silverstripe/versioned-admin": "1.x-dev",
|
"silverstripe/errorpage": "1.0.0-beta4",
|
||||||
"silverstripe/cms": "4.x-dev",
|
"silverstripe/graphql": "0.2.7@stable",
|
||||||
"silverstripe/errorpage": "1.x-dev",
|
"silverstripe/reports": "4.0.0-beta4",
|
||||||
"silverstripe/reports": "4.x-dev",
|
"silverstripe/siteconfig": "4.0.0-beta4",
|
||||||
"silverstripe/siteconfig": "4.x-dev",
|
"silverstripe/versioned": "1.0.0-beta4"
|
||||||
"silverstripe/versioned": "1.x-dev",
|
|
||||||
"silverstripe/graphql": "3.x-dev || 4.x-dev",
|
|
||||||
"silverstripe/session-manager": "1.x-dev"
|
|
||||||
},
|
},
|
||||||
"require-dev": {
|
"require-dev": {
|
||||||
"phpunit/phpunit": "^9.5"
|
"phpunit/PHPUnit": "^5.7"
|
||||||
},
|
},
|
||||||
"extra": {
|
"extra": {
|
||||||
"project-files": [
|
"project-files": [
|
||||||
"app/src/*"
|
"mysite/code/*"
|
||||||
],
|
]
|
||||||
"resources-dir": "_resources"
|
|
||||||
},
|
},
|
||||||
"config": {
|
"config": {
|
||||||
"process-timeout": 600
|
"process-timeout": 600
|
||||||
|
12
mysite/code/Page.php
Executable file
12
mysite/code/Page.php
Executable file
@ -0,0 +1,12 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
use SilverStripe\CMS\Model\SiteTree;
|
||||||
|
|
||||||
|
class Page extends SiteTree
|
||||||
|
{
|
||||||
|
private static $db = array(
|
||||||
|
);
|
||||||
|
|
||||||
|
private static $has_one = array(
|
||||||
|
);
|
||||||
|
}
|
32
mysite/code/PageController.php
Normal file
32
mysite/code/PageController.php
Normal file
@ -0,0 +1,32 @@
|
|||||||
|
<?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>
|
||||||
|
* array (
|
||||||
|
* '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 = array(
|
||||||
|
|
||||||
|
);
|
||||||
|
|
||||||
|
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/
|
||||||
|
}
|
||||||
|
}
|
@ -1,18 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<phpunit bootstrap="vendor/silverstripe/cms/tests/bootstrap.php" colors="true">
|
|
||||||
<testsuites>
|
|
||||||
<testsuite name="recipe-cms">
|
|
||||||
<directory>vendor/silverstripe/admin/tests</directory>
|
|
||||||
<directory>vendor/silverstripe/asset-admin/tests</directory>
|
|
||||||
<directory>vendor/silverstripe/campaign-admin/tests</directory>
|
|
||||||
<directory>vendor/silverstripe/cms/tests</directory>
|
|
||||||
<directory>vendor/silverstripe/errorpage/tests</directory>
|
|
||||||
<directory>vendor/silverstripe/graphql/tests</directory>
|
|
||||||
<directory>vendor/silverstripe/reports/tests</directory>
|
|
||||||
<directory>vendor/silverstripe/session-manager/tests</directory>
|
|
||||||
<directory>vendor/silverstripe/siteconfig/tests</directory>
|
|
||||||
<directory>vendor/silverstripe/versioned/tests</directory>
|
|
||||||
<directory>vendor/silverstripe/versioned-admin/tests</directory>
|
|
||||||
</testsuite>
|
|
||||||
</testsuites>
|
|
||||||
</phpunit>
|
|
1
public/.gitignore
vendored
1
public/.gitignore
vendored
@ -1 +0,0 @@
|
|||||||
/resources/
|
|
Loading…
Reference in New Issue
Block a user