mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
Merge branch '3'
This commit is contained in:
commit
45736ef2db
@ -439,7 +439,7 @@ class HTTPRequest implements ArrayAccess {
|
||||
$response = new HTTPResponse($fileData);
|
||||
$response->addHeader("Content-Type", "$mimeType; name=\"" . addslashes($fileName) . "\"");
|
||||
// Note a IE-only fix that inspects this header in HTTP::add_cache_headers().
|
||||
$response->addHeader("Content-Disposition", "attachment; filename=" . addslashes($fileName));
|
||||
$response->addHeader("Content-Disposition", "attachment; filename=\"" . addslashes($fileName) . "\"");
|
||||
$response->addHeader("Content-Length", strlen($fileData));
|
||||
|
||||
return $response;
|
||||
|
@ -17,6 +17,7 @@ use SilverStripe\Forms\HiddenField;
|
||||
use SilverStripe\Forms\FileField;
|
||||
use SilverStripe\Forms\LiteralField;
|
||||
use SilverStripe\Forms\CheckboxField;
|
||||
use SilverStripe\Forms\DatetimeField;
|
||||
use SilverStripe\Forms\GridField\GridFieldExportButton;
|
||||
use SilverStripe\Forms\GridField\GridFieldConfig_RecordEditor;
|
||||
use SilverStripe\Forms\GridField\GridFieldPrintButton;
|
||||
@ -247,6 +248,13 @@ abstract class ModelAdmin extends LeftAndMain {
|
||||
$params = ArrayLib::array_map_recursive('trim', $params);
|
||||
}
|
||||
|
||||
// Parse all DateFields to handle user input non ISO 8601 dates
|
||||
foreach($context->getFields() as $field) {
|
||||
if($field instanceof DatetimeField) {
|
||||
$params[$field->getName()] = date('Y-m-d', strtotime($params[$field->getName()]));
|
||||
}
|
||||
}
|
||||
|
||||
$list = $context->getResults($params);
|
||||
|
||||
$this->extend('updateList', $list);
|
||||
|
@ -7,11 +7,11 @@ includes common functionality and default behaviors easily complemented with add
|
||||
themes.
|
||||
|
||||
SilverStripe includes a myriad of extension API's such as *Extension Hooks* and support for programming patterns
|
||||
such Dependency Injection. Allowing developers to tailor the framework to their needs without modifying the core
|
||||
such as *Dependency Injection*. Allowing developers to tailor the framework to their needs without modifying the core
|
||||
framework.
|
||||
|
||||
[CHILDREN Exclude="How_Tos"]
|
||||
|
||||
## How to's
|
||||
|
||||
[CHILDREN Folder="How_Tos"]
|
||||
[CHILDREN Folder="How_Tos"]
|
||||
|
Loading…
Reference in New Issue
Block a user