* Addition of extend for newRowClasses
Allows for creation of extension of row classes in gridfield.
* Update GridField.php
Including suggestions by @tractorcow and @dhensby.
Required for REST URLs which require data to be populated on call.
For example, PUT admin/campaigns/set/:id/publish to publish a campaign.
At the time when createEndpointFetcher() is called, the ":id" parameter can not be resolved,
since the "data" argument is passed in once the returned function is evaluated (since the component using it).
Since the whole idea of createEndpointFetcher() is that components shouldn't know about the backend internals,
its not the right place to interpolate urls.
I'm sending through any payload data in addition to replacing URLs, to keep the API simple for the component.
Again, it shouldn't worry about the presence URL interpolation. The trade off here is that data will be submitted
both in the payload (in case of a POST, PUT or DELETE request), as well as (optionally) in the URL.
Tests were previously excluded from eslint calls. This leads to messier
code inside tests, and potentially errors.
Now they all meet the listing rules, and so we don’t need to ignore
tests in .eslintignore.
SilverStripeBackend now has a createEndpointFetcher method, described
in its docblock in more detail.
It’s based the asset-admin code for apiCallerFromEndpoint(). It’s
refactored and generalised into framework in order to provide a
general-purpose API for tying Javascript components to backend APIs.
@todo: tests
FIX: Ensure post has correct content-type header.
Exporting silverstripe-backend lets other modules (such as asset-admin)
use it.
In addition, the Content-type header of a post request of URL-encoded
data was being set to text/plain by default, which isn’t correct and
stopped PHP from interpreting it.
We've had a few failures where framework caused regressions in CMS,
so these builds are helpful. They'll increase the overall build
times on the "silverstripe" user because of Travis' build limitations.
The parallel per-build run times shouldn't increase, since
framework builds take longer than cms builds anyway:
CMS Behat build took 13:53 on last 3.3 run,
framework MySQL PDO build took 16:12.
Added a test for the forgot password email.
Improved the test for the change-password email.
Fixed issue where `SapphireTest::mailer` was cleared during `setUp` by moving instantiation of the mailer at the end of the `setUp` method.
No longer use deprecated i18n method in test-setup.
Replace potentially real Email Address with a fake one.