diff --git a/README.md b/README.md index 478fcb19..28bf193d 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ ## SilverStripe CMS -[![Build Status](https://secure.travis-ci.org/silverstripe/silverstripe-cms.png)](http://travis-ci.org/silverstripe/silverstripe-cms) +[![Build Status](https://secure.travis-ci.org/silverstripe/silverstripe-cms.png?branch=3.0)](http://travis-ci.org/silverstripe/silverstripe-cms) PHP5 Content Management System (CMS), see [http://silverstripe.org](http://silverstripe.org). Requires the [`framework`](http://github.com/silverstripe/sapphire) module and a [`silverstripe-installer`](http://github.com/silverstripe/silverstripe-installer) base project. @@ -19,7 +19,7 @@ and [installation from source](http://doc.silverstripe.org/framework/en/installa ## License ## - Copyright (c) 2007-2011, SilverStripe Limited - www.silverstripe.com + Copyright (c) 2007-2012, SilverStripe Limited - www.silverstripe.com All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: diff --git a/code/controllers/AssetAdmin.php b/code/controllers/AssetAdmin.php index 8d8d46f2..e678a9cd 100644 --- a/code/controllers/AssetAdmin.php +++ b/code/controllers/AssetAdmin.php @@ -120,11 +120,17 @@ JS // Category filter if(isset($params['AppCategory'])) { - $exts = File::$app_categories[$params['AppCategory']]; + if(isset(File::$app_categories[$params['AppCategory']])) { + $exts = File::$app_categories[$params['AppCategory']]; + } else { + $exts = array(); + } $categorySQLs = array(); foreach($exts as $ext) $categorySQLs[] = '"File"."Name" LIKE \'%.' . $ext . '\''; // TODO Use DataList->filterAny() once OR connectives are implemented properly - $list = $list->where('(' . implode(' OR ', $categorySQLs) . ')'); + if (count($categorySQLs) > 0) { + $list = $list->where('(' . implode(' OR ', $categorySQLs) . ')'); + } } return $list; diff --git a/code/forms/SiteTreeURLSegmentField.php b/code/forms/SiteTreeURLSegmentField.php index 2da57893..3345b77c 100644 --- a/code/forms/SiteTreeURLSegmentField.php +++ b/code/forms/SiteTreeURLSegmentField.php @@ -27,6 +27,8 @@ class SiteTreeURLSegmentField extends TextField { public function Field($properties = array()) { Requirements::javascript(CMS_DIR . '/javascript/SiteTreeURLSegmentField.js'); + Requirements::add_i18n_javascript(CMS_DIR . '/javascript/lang', false, true); + Requirements::css(CMS_DIR . "/css/screen.css"); return parent::Field($properties); } diff --git a/code/model/SiteConfig.php b/code/model/SiteConfig.php index 4f5b38d5..0fff4f9f 100644 --- a/code/model/SiteConfig.php +++ b/code/model/SiteConfig.php @@ -44,7 +44,6 @@ class SiteConfig extends DataObject implements PermissionProvider { * @return FieldList */ public function getCMSFields() { - Requirements::javascript(CMS_DIR . "/javascript/SitetreeAccess.js"); $groupsMap = Group::get()->map('ID', 'Breadcrumbs')->toArray(); asort($groupsMap); diff --git a/composer.json b/composer.json index 4e8fbc59..f0959808 100644 --- a/composer.json +++ b/composer.json @@ -24,5 +24,8 @@ "branch-alias": { "dev-master": "3.1.x-dev" } + }, + "autoload": { + "classmap": ["tests/behat/"] } } \ No newline at end of file diff --git a/javascript/SiteTreeURLSegmentField.js b/javascript/SiteTreeURLSegmentField.js index 55599928..7971b934 100644 --- a/javascript/SiteTreeURLSegmentField.js +++ b/javascript/SiteTreeURLSegmentField.js @@ -166,7 +166,7 @@ // edit button editAction = $('