Commit Graph

629 Commits

Author SHA1 Message Date
Stig Lindqvist a0f537142f Merge pull request #127 from mateusz/refactor-access
BUG Refactor the access checks and initial subsite redirections.
2013-12-04 12:37:30 -08:00
Mateusz Uzdowski 58b926af25 BUG Refactor the access checks and initial subsite redirections.
Remove the special AJAX handling to simplify the code. Now redirection
will be forced on any request that changes the subsite to re-synchronise
with the frontend.

Introduce canAccess method, and add it to alternateAccessCheck to make
sure this subsite-specific chceck is also done in situations that are
not captured by onBeforeInit.
2013-12-04 17:34:27 +13:00
Stig Lindqvist e6f054f55b Merge pull request #126 from mateusz/session-fix
Do not change the session-stored subsite, if session is not enabled.
2013-11-25 16:35:57 -08:00
Mateusz Uzdowski a771e2239b Do not change the session-stored subsite, if session is not enabled.
This causes issues with Security::findAnAdmistrator which incorrectly
forces the current session-stored subsite to 0 - it uses
Subsite::currentSubsiteID before the session support is enabled, and
hence obtains wrong value.
2013-11-26 13:12:17 +13:00
Mateusz U c04208ed79 Merge pull request #121 from stojg/pr/cleanup
Minor cleanup of subsite code
2013-11-25 16:10:55 -08:00
Damian Mooyman d21881d7b4 Merge pull request #123 from stojg/make-subsite-domain-decoratable
SubsiteDomain don't call decorators updateCMSFields
2013-11-17 11:51:08 -08:00
Ingo Schommer 51e8d98707 Fixed translation namespacing
The TEMPLATE.ss.ENTITY wording stuffs up the YAML
parser in transifex, which made most translations
invisible to SilverStripe since they're indented wrongly.
Also removed empty FR file since Transifex complains about it on upload.
2013-11-14 23:18:01 +01:00
Stig Lindqvist ff7328ea94 Adding docblocks to SubsiteDomain 2013-11-15 09:50:21 +13:00
Stig Lindqvist b7f1c66de7 Make SubsiteDomain#getCMSFields extendable 2013-11-15 09:50:15 +13:00
Stig Lindqvist 859bde1257 Reorder methods and variables to follow the SS coding conventions
The coding conventions is mentioned here http://doc.silverstripe.org/framework/en/trunk/misc/coding-conventions#class-member-ordering
2013-11-11 12:09:27 +13:00
Stig Lindqvist 7bb36eae7b Adding docblocks and visibility keywords to methods 2013-11-11 11:56:02 +13:00
Stig Lindqvist dc7a0560fb Removed Subsite::set_allowed_domains()
Removed documentation and code since the method has been throwing user error since 2010-03-01
2013-11-11 11:56:02 +13:00
Stig Lindqvist cc0349026e Removed unused variable 2013-11-11 11:34:52 +13:00
Stig Lindqvist 6fb36eab9f Merge pull request #120 from mateusz/subsite-model-switch
BUG Prevent session-interface mismatch.
2013-11-07 15:06:16 -08:00
Mateusz Uzdowski aacaee08cd BUG Prevent session-interface mismatch.
Disables transparent subsite switch on AJAX requests.

Makes sure the subsite is appropriately set up when opening up the CMS
with a link to subsited object.
2013-11-08 11:37:10 +13:00
Ingo Schommer c26a405d83 Updated Arabic/Teo Reo/Chinese translations 2013-11-06 12:13:02 +01:00
Ingo Schommer 5ff3b691d7 More globalisation 2013-10-30 13:44:06 +01:00
Ingo Schommer dcae115723 Renamed en_US.yml to en.yml
More consistent with transifex source file mapping
2013-10-30 00:19:21 +01:00
Mateusz U 97c2db6386 Merge pull request #117 from mateusz/translations
Update pl_PL translation from transifex.
2013-10-24 19:43:21 -07:00
Mateusz Uzdowski af5bdaf367 Update pl_PL translation from transifex. 2013-10-25 15:42:12 +13:00
Mateusz U da9aa30859 Merge pull request #116 from mateusz/translations
Add transifex config file. Add missing files and merge translations.
2013-10-24 16:58:33 -07:00
Mateusz Uzdowski 43036854c5 Add transifex config file. Add missing files and merge translations. 2013-10-25 12:45:32 +13:00
Ingo Schommer c0e6d1ad38 Added unit test around "forbidden section" redirection
See https://github.com/silverstripe/silverstripe-subsites/pull/115
2013-10-23 01:50:55 +02:00
Ingo Schommer 8b5a1c92b2 Hide subsites dropdown for collapsed sidebar
Its cut off otherwise, and not really operational.
This is consistent with hiding the "hi <user>" string
as default CMS behaviour.
2013-10-23 01:38:17 +02:00
Ingo Schommer 7c100f90d2 Merge pull request #115 from mateusz/admin-access
Fix CMS Admin access issues
2013-10-23 01:34:30 +02:00
Mateusz Uzdowski d85412adf7 Fix the test coverage for the subsite access changes. 2013-10-18 11:58:11 +13:00
Mateusz Uzdowski 5b00ba352f API Refactor to always redirect to accessible Admin location.
Tries to find an accessible section in the current site, falls back to
searching across all sites and all sections.

Also adds more powerful and generic functionss:
Subsites::all_sites - get the full list
Subsites::all_accessible_sites - get Member accessible list
LeftAndMainExtension::sectionSites - get section-specific list
2013-10-16 16:40:20 +13:00
Mateusz Uzdowski 91cca0c64d BUG Move the SubsiteList PJAX request to a dedicated Controller.
Currently the request cannot be made if one doesn't have access to the
SubsiteAdmin section, which often happens with subsite-specific admins.
2013-10-16 13:20:54 +13:00
Simon Welsh fc07486f9b Merge pull request #108 from adrexia/docs
Update Documentation
2013-09-11 21:15:04 -07:00
Simon Welsh 5c541358c9 Merge pull request #107 from spronkey/106-get-from-all-subsites
Fix for issue #106 get_from_all_subsites to force immediate eval instead of lazy with DataList
2013-09-11 20:38:12 -07:00
spronkey 23e9cd40a0 Better fix for #106 using DataQuery queryParams. Thanks simon_w 2013-09-12 15:33:18 +12:00
Naomi Guyer a76b3c7808 Update Documentation
* Updated graphics
* Updated information around global dropdown
* Added Information about supporting subsites in modeladmins
* Changed 'working.md' to 'working_with.md', for clearer menu naming
2013-09-12 14:42:00 +12:00
spronkey 586d88562c Added test case for subsites virtual page onAfterWrite issue, plus changed get_from_all_subsites method to immediately eval and return an ArrayList, instead of lazy eval DataList. Fixes #106 2013-09-12 14:23:42 +12:00
Mateusz U 110ce7751d Merge pull request #104 from adrexia/subsites-ui
API: Subsite support for menu of cms (hides admins that don't declare support) (fixes #101 and #89 )
2013-08-21 18:16:29 -07:00
Naomi Guyer 37843f447e API: Subsite support for menu of cms (hide admins that don't declare support) (fixes #101 and #89 )
* Hide admins without subsite support from subsites menu
* Add subsite support to default site areas
* Enable reloading of subsites switcher dropdown when navigating the
site, and when editing subsite areas

API Fix parallel pjax menu fetching for subsites.
- thanks Mateusz!

Delint LeftAndMain_Subsites.js
2013-08-22 13:02:46 +12:00
Mateusz Uzdowski 2d41dc62bf Change dependency versions to work for 3.1.0-rc1. 2013-08-13 12:05:30 +12:00
Simon Welsh 9192954596 Use correct jQuery variable 2013-07-11 17:31:59 +12:00
Ingo Schommer b49c86bd0b Require subsite title (fixes #26) 2013-07-10 16:28:08 +02:00
Ingo Schommer 6a9003e8df Less intrusive doSave() overwrite of GridFieldDetailForm
Fixes issues with valiation errors not showing due
to lack of PjaxResponseNegotiator support (parent implementation has changed).
2013-07-10 16:15:04 +02:00
Ingo Schommer 0e9c3344ac Removed disabled tests (#29)
They use all kinds of outdated APIs (in test system and CMS controllers),
and the function rename makes it unclear that they're actually disabled.
These kinds of tests should be performed through Behat anyway.
2013-07-10 15:55:16 +02:00
Ingo Schommer e6832aadca 3.1 allowed_actions fixes for SubsitesTreeDropdownField 2013-07-10 15:31:39 +02:00
Ingo Schommer 99d242f3ae Fixed JS indentation 2013-07-10 12:30:55 +02:00
Frank Mullenger 7bf6e89320 BUGFIX: Session var for active subsite out of sync with current subsite. Refs silverstripe/silverstripe-subsites#93. 2013-07-10 12:24:42 +02:00
Ingo Schommer ac507ddc7b $allowed_actions for GridField subclass
Taken from https://github.com/silverstripe/silverstripe-subsites/pull/94,
thanks @frankmullenger
2013-07-10 11:46:09 +02:00
Sean Harvey b17e49fcd0 Merge pull request #92 from adrexia/icon
Add custom menu-icon
2013-05-28 15:30:02 -07:00
Naomi Guyer c970889516 Add custom menu-icon 2013-05-29 10:15:17 +12:00
Sean Harvey b2ffb7c89e BUG Fixing "Add new" not adding the page to the correct subsite 2013-05-28 12:17:16 +12:00
Sean Harvey 1538e49e1b Merge pull request #90 from mateusz/previews-by-id
Change the preview iframe to use injected SubsiteID GET/POST params.
2013-05-25 18:29:59 -07:00
Mateusz Uzdowski 0fb49ba502 Change the preview iframe to use injected SubsiteID GET/POST params.
Use the CMS domain for fetching the preview content to avoid SSL
errors and single-origin violations on the iframe.
2013-05-26 13:18:52 +12:00
Sean Harvey beb913d8d0 Merge pull request #88 from adrexia/siteconfig
BUG: Subsite save SiteConfig overwrites MainSite SiteConfig (Issue #15)
2013-05-25 16:49:24 -07:00