Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Comparing changes

Choose two branches to see what's changed or to start a new pull request. If you need to, you can also compare across forks.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also compare across forks.
  • 2 commits
  • 3 files changed
  • 0 commit comments
  • 1 contributor
View
2  README.md
@@ -10,7 +10,7 @@ My aims were to have both a skeleton file/directory structure and to simplify an
I started off following the general pattern outlined in this most excellent how-to:
[How-To: Build a Single-Page Powered Editing Interface for concrete5 Pages](http://www.concrete5.org/documentation/how-tos/developers/build-a-single-page-powered-editing-interface-for-concrete5/), then added a few libraries to smooth out the rough edges -- routing/rendering/redirecting, basic database CRUD operations, and form/data validation:
- * `libraries/better_controller.php`: overrides render(), redirect(), and url() methods of the base Controller class to make them easier to call (fewer and shorter arguments), and provides simple "flash message" functionality for displaying a message after a redirect.
+ * `libraries/crud_controller.php`: overrides render(), redirect(), and url() methods of the base Controller class to make them easier to call (fewer and shorter arguments), and provides simple "flash message" functionality for displaying a message after a redirect.
* `libraries/basic_crud_model.php`: a super basic data model class you can build your own models on top of -- provides automatic INSERT/UPDATE, DELETE, and 'SELECT ONE' functionality, and that's it! All it does is allow you easily perform single record inserts/updates/deletes/selects -- because I've found that everything else always requires custom queries anyway, so why bother abstracting it (there's nothing wrong with SQL, as long as you can keep it DRY).
* `libraries/kohana_validation.php`: provides a *much* more robust set of validation rules than C5's built-in validation helpers. (Ported from the awesome Kohana 2.3.4 framework, hence the name.)
View
4 controllers/dashboard/boilerplate_crud.php
@@ -1,7 +1,7 @@
<?php defined('C5_EXECUTE') or die(_("Access Denied."));
-Loader::library('better_controller', 'boilerplate_crud'); //Superset of Concrete5's Controller class -- provides simpler interface and some extra useful features.
-class DashboardBoilerplateCrudController extends BetterController {
+Loader::library('crud_controller', 'boilerplate_crud'); //Superset of Concrete5's Controller class -- provides simpler interface and some extra useful features.
+class DashboardBoilerplateCrudController extends CrudController {
public $helpers = array('form'); //Makes form helper automatically available to all views
View
2  libraries/better_controller.php → libraries/crud_controller.php
@@ -2,7 +2,7 @@
//Provides some improved convenience methods for our single_page controllers
-class BetterController extends Controller {
+class CrudController extends Controller {
public function __construct() {
parent::__construct();

No commit comments for this range

Something went wrong with that request. Please try again.