Commit Graph

99 Commits

Author SHA1 Message Date
Saophalkun Ponlu
1ec7c4e523 Fix lint error 2017-05-16 11:53:23 +12:00
Saophalkun Ponlu
a975b88661 Pass autofocus flag to front-end 2017-05-16 11:53:23 +12:00
Daniel Hensby
e741af9127
Merge branch 'pull/6905' 2017-05-12 12:21:02 +01:00
Ralph Slooten
43a122cc36 Fix for meta closing tags
Prevent html errors when FormField::create_tag('meta') is called from $MetaTags() so
```
<meta name="generator" content="SilverStripe - http://silverstripe.org"></meta>
```
becomes
```
<meta name="generator" content="SilverStripe - http://silverstripe.org" />
```

Add all void elements to list
2017-05-12 08:49:15 +12:00
Christopher Joe
edcb220e4a Enhancement add EmailLink form factory server-side 2017-05-11 09:57:55 +12:00
Christopher Joe
c58dc97d39 Fix optional $id param because of how methodSchema passes a parameter 2017-05-11 09:57:55 +12:00
Christopher Joe
2ee0d99806 Enhancement switch FormFactories to use RequestHandler instead of Controller 2017-05-11 09:57:55 +12:00
Christopher Joe
403f4db14d Fix change titles to return schema values in schema
Enhancement Add EditorExternalLink call for toolbar
2017-05-11 09:57:55 +12:00
Aaron Carlino
4af71b9ed7 Pulls/4/remove reliance on admin dir (#6876)
* Stop relying on external constants

* Revise getTinyMCEPath method to throw exception when no path can be computed

* Throw exception on no gzip, better admin module check
2017-05-10 13:18:44 +12:00
Saophalkun Ponlu
fd51f35bc2 Update tests 2017-05-09 16:52:32 +12:00
Saophalkun Ponlu
97dac7028c De-couple schema type and type attribute 2017-05-09 16:50:33 +12:00
Sam Minnée
33119a1f36 Merge branch 'master' into pulls/4.0/remove-deprecated-methods 2017-05-09 15:31:53 +12:00
Ingo Schommer
1d438d3fb5 API Remove deprecated FormAction::createTag() 2017-05-09 11:38:35 +12:00
Ingo Schommer
bbf15ab9f1 Allow type override in FormAction 2017-05-09 11:16:41 +12:00
Ingo Schommer
0d9b383631 API Removed legacy form fields (fixes #6099) 2017-05-09 11:16:41 +12:00
Aaron Carlino
afd1575267 ENHANCEMENT GridField passes in context for canCreate 2017-05-09 09:15:09 +12:00
Aaron Carlino
c99ed2d262 Reorganise i18n keys 2017-05-08 23:34:39 +12:00
Uncle Cheese
d51c4891e2 New namespaced i18n keys 2017-04-28 14:59:42 +12:00
Uncle Cheese
494cbd1875 Ran upgrader for lang files 2017-04-28 14:59:42 +12:00
Ingo Schommer
22f232ed4d Mark up <time> in validation errors
Allow better localisation of values in JS
2017-04-27 21:44:52 +12:00
Ingo Schommer
cbe534c675 Fixed component capitalisation 2017-04-27 15:36:18 +12:00
Ingo Schommer
94b49e3e28 Removed unused field 2017-04-27 15:36:11 +12:00
Ingo Schommer
60706c8efd Store $value in ISO and server timezone consistently, fix min/max timezone handling 2017-04-27 14:59:11 +12:00
Ingo Schommer
628fd216ad PHPDoc fixes 2017-04-27 11:56:23 +12:00
Ingo Schommer
f01a20d5c4 Only used normalised ISO on HTML5 2017-04-27 11:56:18 +12:00
Ingo Schommer
de8abe1167 API rename 2017-04-27 11:53:43 +12:00
Ingo Schommer
b852a76334 Consistent schema keys 2017-04-27 11:47:04 +12:00
Ingo Schommer
14b3468eee Removed setting format in getter
That’s already handled in getFormatter()
2017-04-27 11:09:59 +12:00
Ingo Schommer
655b047d80 Removed superfluous methods 2017-04-27 11:09:43 +12:00
Ingo Schommer
d3afa0c3b5 Remove array check since setSubmittedValue() no longer supports it 2017-04-27 10:59:44 +12:00
Ingo Schommer
958736502a Removed “T” str_replace, more comments 2017-04-27 10:32:22 +12:00
Ingo Schommer
1ec2abe75f Fixed timezone and normalised ISO handling
A few observations:
- ISO says “T” is optional (https://en.wikipedia.org/wiki/ISO_8601#cite_note-21),
- WHATWG says in the HTML5 spec that it’s optional (https://html.spec.whatwg.org/multipage/infrastructure.html#local-dates-and-times)
- W3C says it’s reqiured in 1997 (https://www.w3.org/TR/NOTE-datetime), but then later says it’s optional in its HTML5 spec (https://www.w3.org/TR/html5/infrastructure.html#floating-dates-and-times).
- Chrome doesn’t parse values with whitespace separators (requires "T")
- DataObject DBDatetime values and database columns use whitespace separators (and will have many devs relying on this format)
- MySQL only supports whitespace separators (https://dev.mysql.com/doc/refman/5.7/en/datetime.html)
- SQLite can parse both ways (https://sqlite.org/lang_datefunc.html)

So the goal here is to retain ORM/database compatibility with 3.x (whitespace separator),
while exposing "T" separators to the browser in HTML5 mode.

Regarding timezones, this fixes a regression where setValue() would not actually
apply the timezone (last $value assignment is ineffective now that sub fields are removed).
2017-04-26 22:55:29 +12:00
Ingo Schommer
e97783b057 Better second handling 2017-04-26 22:45:08 +12:00
Ingo Schommer
d2132e85db More specific localisations 2017-04-26 22:45:07 +12:00
Saophalkun Ponlu
dba1f61f13 Fix tests related to date time 2017-04-26 22:45:07 +12:00
Saophalkun Ponlu
9d7eef7cf3 Fix datetime field validation for the refactor 2017-04-26 22:45:07 +12:00
Saophalkun Ponlu
4a70662940 Pass html5 flag to front-end 2017-04-26 22:45:07 +12:00
Saophalkun Ponlu
9f8fe88eea Refactor DateTimeField not to use DateField and TimeField 2017-04-26 22:45:07 +12:00
Saophalkun Ponlu
81a21f68cd Add 'lang' attribute to front-end date field schema 2017-04-26 22:45:06 +12:00
Damian Mooyman
0791b387b8 API Update serialisation of JSON tree data
Update TreeDropdownField schema
2017-04-26 17:30:10 +12:00
Saophalkun Ponlu
68041f4265 Wrap selection group input in label 2017-04-26 13:54:06 +12:00
Damian Mooyman
136b67f597
API Major refactor of Hierarchy into MarkedSet 2017-04-13 16:27:13 +12:00
Damian Mooyman
f38ae1d837 Cleanup phpdocs on DatetimeField 2017-04-13 14:00:30 +12:00
Damian Mooyman
e61257c27b API Update embed/embed to 3.0
API Better shortcode generation for embed shortcodes
2017-04-04 10:20:08 +12:00
Christopher Joe
2c5e482de0 Add LabelField component definition 2017-04-04 10:20:08 +12:00
Ingo Schommer
e3fbd1dcac Fixed coding conventions 2017-04-03 20:54:25 +12:00
Ingo Schommer
3b94d14e42 MERGE 2017-04-03 12:11:21 +12:00
Ingo Schommer
326aa37ea4 API HTML5 date/time fields, remove member prefs (fixes #6626) 2017-03-31 15:21:47 +13:00
Ingo Schommer
ac6d4f3038 Move DateField->placeholders to subclass
It’s only used there
2017-03-31 14:15:21 +13:00
Damian Mooyman
a07a9bffc4
API Add FormRequestHandler::forTemplate() for backwards compatibility 2017-03-13 12:51:37 +13:00