Commit Graph

64 Commits

Author SHA1 Message Date
Guy Sartorelli 635d13c6bb
Merge branch '2.10' into 2.11 2023-04-26 13:48:56 +12:00
Guy Sartorelli 158bc006a5
FIX Format value to string for readonly transformation
Co-authored-by: Werner Huber <w.huber@byro13.de>
2023-04-17 13:51:10 +12:00
Steve Boyd dc932bd72d API Stop using deprecated API 2022-11-24 17:39:57 +13:00
Steve Boyd 442d9d8f32 API Update deprecations 2022-11-16 11:55:46 +13:00
Roman Schmid 8da9f83cde fix: Fall back to the `ID` if no title is given 2022-07-26 10:47:13 +02:00
Roman Schmid 560a1398ab fix: Do not use `getField` to allow for field fallback values 2022-07-25 16:49:23 +02:00
Roman Schmid e34d6e4898 fix: Use the title-field for has_one DataObject relations 2022-07-04 16:10:02 +02:00
Roman Schmid bc7bf5265b fix: Deal with DataObjects or Int values, so that the correct value is shown with has_one 2022-06-28 09:29:32 +02:00
Will Rossiter 527c5b2224
FIX Selected tag is not shown when isMutliple is false (#201)
* doc: add note about `setTitleField` (Fixes #153)

* NEW Add support for saving tag value into has_one components

FIX Value not shown if isMultiple is false (#195)

* fix: don't default to ID column as pgsql throws an error if comparing string value
2022-06-07 13:00:12 +12:00
Steve Boyd 1b7dba124a ENH PHP 8.1 compatibility 2022-04-13 13:50:19 +12:00
Daniel Kliemsch 0a04e35825
ENH Make the write call of StringTagField::saveInto method configurable (#208)
* Make the immediate write call of StringTagField::saveInto method configurable
* Set immediate_write_enabled option in the class instead of config; add deprecation notice
* Add tests for the immediate write option
2022-04-04 20:27:49 +12:00
Michael van Schaik 07868abfb5
Adding `$schemaComponent` to make react render correct component
Fixes #198
2021-11-24 15:41:10 +01:00
Joseph Madden 55e03731bf
FIX Use existing source datalist if available before creating a new one
Fix for #171 - Issue when utilizing multiple of same parent class

Co-authored-by: Joe Madden <joe.madden@moosylvania.com>
2021-10-15 13:38:53 +13:00
Loz Calver debcd12b62 Fix missing CSS class for StringTagField initialisation (closes #148) 2021-07-26 09:49:05 +01:00
Loz Calver 325de9e94d Fix StringTagField initialisation (fixes #148) 2021-06-18 12:02:05 +01:00
Maxime Rainville ccca22c6fa Merge branch '2.4' into 2 2020-10-22 13:41:47 +13:00
Ingo Schommer 70d80920d7 FIX Preselect based on SS_List values 2020-07-16 17:45:04 +12:00
Damian Mooyman 748ef1a8f0
Actually save the values 2020-07-06 14:36:17 +12:00
Damian Mooyman 2790d7504a
PHP 5 compatibility 🙄 2020-07-06 14:33:09 +12:00
Damian Mooyman 5decfa39e1
Merge remote-tracking branch 'origin/2.4' into pulls/fix-react 2020-07-06 14:18:12 +12:00
Damian Mooyman a61612ec4b
BUG Resolve issue with react select values not being saved
Fixes #150
2020-07-06 14:17:08 +12:00
Sam Minnee d11b9474ed FIX: Fix readonly transformation of field with setTitleField()
If the title field was customised, this metadata was lost during a
readonly transformation. This can cause fatal errors in read-only views
such as history browsing.
2020-06-17 16:40:57 +12:00
Christopher Darling c538a231b7
FIX $record->hasMethod() should be called before getting the relation 2020-05-06 19:45:41 +01:00
Garion Herman 01e7f457a6 Merge branch '2.3' into 2.4 2020-02-13 15:42:44 +13:00
Garion Herman b7a2b3b1d7 Merge branch '2.1' into 2.2 2020-02-13 15:18:32 +13:00
Robbie Averill 804c6bac2f
Run automated phpcs linting 2019-07-25 12:27:29 +12:00
Guy Marriott bd84139b96
Code clean-up 2019-07-25 12:23:04 +12:00
Guy Marriott 61d3d04ed6
FIX Removing potentially breaking lower-case change (and fix tests) 2019-07-25 12:13:52 +12:00
Guy Marriott a1c57f664d
FIX redux-form can now control tag fields
This also fixes an issue where tags would be created and tags could not have the same name as the ID of an existing tag
And the react-select module is updated to the (current) latest 1.x version
And the tests are now working again after updating jest
2019-07-25 12:13:52 +12:00
Guy Marriott e97a82f0b7
FIX Ensure tagfield is compatible with both React and Entwine contexts 2019-07-25 12:13:50 +12:00
Will Rossiter 068e4c6a26
Setup TagField to work within AssetAdmin (Fixes #107) 2019-07-25 12:13:44 +12:00
Nivanka Fonseka 6276ad2aee php cs fixes 2019-04-29 06:37:31 +05:30
Nivanka Fonseka ead0fbac6b fixed the issue with filters being taken off from rendering values 2019-04-17 11:19:42 +05:30
Robbie Averill daf71e2fab FIX StringTagField now works with SS-2018-021/CVE-2019-5715 by serialising arrays before write 2019-02-19 11:20:13 +07:00
Robbie Averill 968a4f585e Merge branch '2.0' into 2.1 2019-02-19 11:15:39 +07:00
Robbie Averill 3ff72be24c FIX StringTagField now works with SS-2018-021/CVE-2019-5715 by serialising arrays before write 2019-02-19 11:09:02 +07:00
Hayden Shaw fd06a8da5f Add css and js to left and main
* Add yaml file
* Remove requirement calls from field constructors
2018-12-19 14:40:17 +13:00
Robbie Averill 9daa667415 FIX StringTagField now populates available options from its input, and works with React TagField
Suggesting options from a list of tags that are already set as values makes no sense. The
example code in the documentation shows that you provide an input array of options, so
that should be what is used to suggest options when lazy loading.
2018-11-15 22:59:08 +02:00
Robbie Averill dbc519ef31 Move schema data into getSchemaDataDefaults() from Field() 2018-11-15 21:48:46 +02:00
Robbie Averill 54b7d0ff72 Reference correct css and javascript bundles 2018-11-15 21:33:50 +02:00
Robbie Averill 204ef6df53 Update array syntax style, broken doc blocks and namespace imports 2018-11-15 21:33:38 +02:00
Robbie Averill 3ce41f60ec FIX Prevent FormField::Type() from adding "tag" class to TagField 2018-11-15 21:23:22 +02:00
Robbie Averill 1ad87eb374 FIX Replace Convert JSON methods with json_* methods, deprecated from SilverStripe 4.4 2018-10-28 21:42:26 +00:00
Damian Mooyman 77bad9b943
Use getShouldLazyLoad() accesser 2018-09-18 09:12:44 +12:00
Damian Mooyman ce8ba85182
Revert default argument change 2018-09-17 18:24:03 +12:00
Damian Mooyman 690f0cc793
BUG Fix for $source left null
BUG Fix missing imports
Semver compatible setSource()
2018-09-17 18:18:40 +12:00
Simon Gow 024e648e5a Added getSource() function to populate source inline with the api.
Source isn't populated to the parent because it's transformed directly
to an array. Instead we're lazy loading the source when it's requested.
2018-09-13 11:18:55 +12:00
Simon Gow fa754f3fd3
TagField lazy load shouldnt render Options
TagField should only render options if the lazy load value isn't set. Options from here come from subsequent POSTs, and rendering the options for every request significantly slows down both the form generation and render.
2018-09-07 17:28:05 +12:00
Simon Gow 3797049a31
Resolve Performance issues with TagField
TagField hydrates the entire result set because a parent class calls `toArray()` on the $source. 
This fix changes the source to an empty array, so no such manipulation can be made.
2018-09-06 18:16:06 +12:00
Guy Marriott cef407d53f
Adding tests & various feedback updates 2018-07-17 16:19:44 +12:00