silverstripe/sapphire — pull request #713 by tractorcow (2012-08-08 22:27:24+00:00)
Title: FIXED: Compatibility issues with the Translatable module

Follow up to fb9e997

Fixes issue in the CMS when using the TreeDropddownField along side modules (such as Translatable) that add additional querystring arguments to page urls.

This fix resolves an issue where url generation wasn't robust enough to correctly respect querystring arguments in the data-url-tree attribute of tree nodes.

E.g. Ajax requests for sub-trees would be generated in the form /admin/pages/edit/EditForm/field/LinkedPageID/tree?locale=en_NZ/21&ajax=1. This fix correctly generates urls in the correct form. E.g. /admin/pages/edit/EditForm/field/LinkedPageID/tree/21?locale=en_NZ&ajax=1