Commit Graph

294 Commits

Author SHA1 Message Date
Ingo Schommer
6cff9671d4 FIX Privilege escalation through Group and Member CSV upload (SS-2013-004)
See http://www.silverstripe.org/ss-2013-004-privilege-escalation-through-group-and-member-csv-upload/
2013-09-12 15:42:43 +02:00
Ingo Schommer
00ffe72944 Translations: Switch to Transifex format
- Based on new (last) translation download from getlocalization.com
- Removed untranslated strings. Getlocalization started including those at some point
which is highly annoying, unnecessary and breaks the new transfix system,
since it'll mark all of the english strings as actual translations
- Avoid dots in entities. It confuses the Transifex YML parser
- Removed some locales unknown to Transifex which didn't have any translations anyway
- Removed "lolcat" locale, uses custom notation (en@lolcal)
  which SilverStripe's i18n system can't handle
  (needs mapping from SS naming to Zend naming)
- Renamed "Te Reo/Maori" locale from "mi_NZ" to "mi" (Transifex/CLDR notation)
- Namespaced all entities used in templates (deprecated usage)
- Converted dots to underscores where template filenames are used for namespaces,
since Transifex YML parsing handles them as separate YML keys otherwise
- Removed whitespace in entity names, SilverStripe i18n can't handle it
- Only allow selection of locales registered through i18n::$all_locales to avoid
  issues with unknown locales in Zend's CLDR database
2013-08-07 00:25:16 +02:00
Simon Welsh
b506eb1b29 Use httpError() instead of non-existent HTTPResponse_Exception class 2013-07-10 12:30:27 +12:00
g4b0
f033321adc Solved json obj to array issue 2013-03-28 22:06:37 +01:00
Ingo Schommer
52ffb307a7 Fixed ValidationException handling in LeftAndMain
getResult() isn't always available, and has the same content
as the native Exception->getMessage() anyway
2013-03-19 14:02:28 +01:00
Ingo Schommer
dd6f33ab37 FIX Respect tree node limits, fix search result node display
- Renamed $minNodeCount to more accurate $nodeCountThreshold
- The $minNodeCount attribute wasn't properly respected
during actual querying, so SilverStripe would always traverse
the entire tree (and load all objects into memory),
before then marking nodes as "unexpanded", which prevents
them from actually being rendered.
- Fixes nodes on search results to be expanded by default
- Fixes nodes on search results to correctly ajax-expand
2013-03-19 00:05:14 +01:00
Ingo Schommer
b81f39aee5 API Handle uncaught ValidationException on CMS controller execution
This removes the need for a lot of boilerplate code
around DataObject->write() logic, and avoids generic 500 errors
on user-level failures. This should really be a per-project choice,
but at the moment request handling doesn't allow to configure
custom exception handling.
2013-03-08 12:55:30 +01:00
Ingo Schommer
2b6d735182 Using composer.lock for LeftAndMain->CMSVersion()
See https://github.com/silverstripe/silverstripe-cms/pull/289 for context
2013-02-28 13:38:19 +01:00
Ingo Schommer
f7c8778466 Breadcrumb/back nav in ModelAdmin now retains search params 2013-01-21 12:04:20 +01:00
Nicolaas
7523fe4ef7 Update admin/code/ModelAdmin.php
Changed "Clear Database before import" - which is incorrect (not the whole database gets wiped, only the data in the model at hand) with the simpler: "replace data".
2013-01-19 22:38:55 +13:00
Simon Welsh
fc5dd2994c Add codesniffer that ensures indentation is with tabs. 2012-12-12 00:12:11 +13:00
Loz Calver
ea2dc9da0e ENHANCEMENT: Add ability to change URL for SS logo in CMS Menu 2012-11-09 11:06:04 +01:00
Sean Harvey
aec59de955 Adding title to CMSProfileController so translations get default 2012-11-07 11:41:48 +13:00
Ingo Schommer
ff39f9ad38 Upgrade jQuery UI to 1.9
- Fixed jQuery.tabs remote tabs loading behaviour (see http://forum.jquery.com/topic/tabs-api-redesign)
2012-11-06 19:45:56 +01:00
Sean Harvey
3451da001a BUG Fixing session keep alive for non-ADMIN users
SecurityAdmin isn't always available for CMS users, as they might
not have permission to view that section. This fixes the problem
with session keep alive by moving the ping to Security/ping, which
is available for all users.
2012-11-05 15:41:10 +13:00
Sean Harvey
7a7c1a6857 BUG Escape tree title 2012-11-05 13:19:02 +13:00
Simon Welsh
0b279a2cbc Changes ping to POST and clears Requirements for ping
GET requests can, and do, get cached. Using POST forces them not to.
Clears requirements so that the SecurityAdmin JS isn't injected.
2012-11-01 21:15:43 +13:00
Ingo Schommer
bcbf4636fc BUG Remove .ss-tabset class from CMS tabs to prevent rogue ajax load (#7980)
The existence of .ss-tabset triggers JS which applies $.tabs(),
and in turn interprets the first available link as the tab navigation.
jQuery UI subsequently tries to ajax-load this link, which is not
desired. Instead, $.tabs() should *only* be applied to a container
DOM element with .cms-tabset applied.
2012-11-01 00:25:13 +01:00
Sam Minnee
1f7fc1f76a FIX Remove instances of lines longer than 120c
The entire framework repo (with the exception of system-generated files) has been amended to respect the 120c line-length limit.  This is in preparation for the enforcement of this rule with PHP_CodeSniffer.
2012-09-30 17:18:13 +13:00
Simon Erkelens
f991401a52 Translation possible for clear before import
I couldn't figure out why it wouldn't translate...
2012-09-28 09:45:16 +03:00
Ingo Schommer
e2f073f38a Method visibility according to coding conventions 2012-09-20 10:46:59 +02:00
Ingo Schommer
2f643817a4 LeftAndMain::$session_namespace
More fine-grained control over session storage,
particularly when reusing the "current page" state.
2012-08-29 15:10:05 +02:00
martimiz
82500dd4c4 NEW Custom menu icons for the CMS main menu
Add optional custom menu icons to the CMS main menu for every class
extending LeftAndMain (ModelAdmin). Works by setting optional static
$menu_icon = '/path/to/image' and providing custom styling for added
icons. Works for the menu as well as icon in the right-side (GridField) pane header.
2012-08-29 13:14:59 +02:00
Hamish Friedlander
05fade3249 FIX 7763 TreeDropdownField needs to refresh after CMS edit form save 2012-08-29 10:52:56 +12:00
Kirk Mayo
3e351bc421 BUG: open ticket 7812 correcting filter syntax on a DataObject used by function updatetreenodes 2012-08-27 14:41:07 +12:00
Ingo Schommer
2fab657fce i18n for CMS section titles (see #7798) 2012-08-26 23:58:31 +02:00
Hamish Friedlander
b560d258d3 Re-enable Entwine Inspector in CMS & document 2012-08-20 11:26:11 +12:00
Ingo Schommer
c7fd9a6605 CMS Localization 2012-08-10 00:17:34 +02:00
Ingo Schommer
77d939f0b2 CMS Localization 2012-08-09 23:55:30 +02:00
Hamish Friedlander
22d6c7afa4 BUG Updating node would position wrong, Sort isnt === offset 2012-07-23 22:15:11 +12:00
Ingo Schommer
120de7cba2 NEW Tree node updates after save (fixes #7450, #7389)
- Updates icon, badges, title, and position in hierarchy
- New LeftAndMain_TreeNode API to allow rendering of single tree nodes
without their hierarchy, extracted from LeftAndMain->getSiteTreeFor()
- New LeftAndMain->updatetreenodes() endpoint to request updated state
for one or more nodes. Triggered on demand by form refreshes.
2012-07-23 17:21:49 +12:00
Ingo Schommer
faff2c122d Localized CMS breadcrumbs title 2012-07-18 13:51:12 +02:00
Ingo Schommer
d4b8db27af Marking fake LeftAndMain->redirect() responses as finished
Introduce new LeftAndMain_HTTPResponse class for this purpose,
to mark a response as finished regardless of HTTP status.
This is required for ajax responses which do redirects on app layer
rather than HTTP (to avoid double processing).

Specifically required to decorate LeftAndMain->init()
in the 'translatable' module (TranslatableCMSMainExtension),
which marks the response as finished through its redirect,
avoiding further processing after init().
2012-07-16 23:30:59 +02:00
Ingo Schommer
712f28bc78 Scoped deprecation messages (fixes #7645) 2012-07-13 11:37:35 +02:00
Simon Welsh
8d670283c9 FIX Santise model classes in ModelAdmin
As ModelAdmin puts classes directly into links, a namespaced class
has its \s turned into /s, breaking the links. This escapes them by
converting each \ to a -, then converting them back when loading.
2012-06-29 13:52:33 +12:00
Ingo Schommer
ba9c3c7b8e BUGFIX Type checking in CMS URL params (fixes #7187)
Nasty issue where nested requests to sub-controllers within LeftAndMain->EditForm() would fail because of
LeftAndMain->currentPageID() being taken from the URL, even though it was a field action name.
Example: POST /admin/pages/edit/EditForm/field/MyGridField/item/1/ItemEditForm/field/MyUploadField/upload
The current ID would be detected as "field" in this case.
Bug was previously fixed for AssetAdmin.
2012-06-22 17:47:45 +02:00
Hamish Friedlander
03469230ff BUGFIX: Add batch handler status messages (fixes #7427)
7427 was mostly fixed by Ingos previous patch. But two batch actions, delete from draft site and delete from published site werent returning
status messages. Abstracted out the status preperation code that the batch actions that were returning status messages were using, and
used that to add status messages to the problem two
2012-06-22 13:59:08 +12:00
Sam Minnée
7ce7ac406e Merge pull request #528 from mango9/master
Ticket #5578
2012-06-14 16:43:20 -07:00
Hamish Friedlander
21e7ec61f4 ENHANCEMENT: In dev mode, include some basic leak detection functions in the admin panel 2012-06-15 01:19:19 +02:00
Ingo Schommer
c81d0e1222 MINOR Only set X-Pjax header in redirections if it doesn't already exist in the response 2012-06-14 20:20:29 +02:00
Paul Meyrick
882b4267cb BUGFIX: Ticket #5578 SiteTree->CanCreateTopLevel() doesn't change dragged tree nodes or ParentID changes 2012-06-14 17:17:27 +12:00
Andrew Short
d9c7bb8eb9 ENHANCEMENT: Implemented help text for form fields.
The title attribute is extracted from form fields and displayed inline
below the field.
2012-06-13 13:19:12 +02:00
Ingo Schommer
ce3d48e310 MINOR Supressed dependencies of tree logic on SiteTree elements (not properly isolated to work well with Folder objects) 2012-06-13 00:51:53 +02:00
Ingo Schommer
b1d95cffac BUGFIX Passing existing SS_HTTPResponse to PjaxResponseNegotiator in LeftAndMain so state like X-Status HTTP headers are retained (fixes #7427) 2012-06-13 00:27:03 +02:00
Ingo Schommer
ed9c856442 ENHANCEMENT Strikethrough styling for deleted tree nodes, adding status classes to tree node <li> in addition to the existing <span class="badge"> (fixes #7410) 2012-06-12 15:53:38 +02:00
Sam Minnee
267f41bdf4 ENHANCEMENT: Point userhelp link at a new userhelp instance. (#7430) 2012-06-07 13:46:47 +12:00
Ingo Schommer
b3164eb2a9 MINOR Disabled jQuery.entwine inspector in dev mode, as it causes side effects due to document.write() before other scripts are loaded 2012-06-06 11:49:32 +02:00
Ingo Schommer
12f2e1e176 Merge branch 'pjax-multiple' 2012-06-05 14:01:18 +02:00
Ingo Schommer
31a66e0424 MINOR Returning at least some error feedback when admin/* route isn't found (fixes #7409) 2012-06-03 22:46:16 +02:00
Ingo Schommer
5178954311 UNFINISHED Processing multiple PJAX responses on CMS JavaScript, introducing data-pjax-fragment attribute to identify reloadable template parts 2012-05-30 15:07:13 +02:00