User tests: Successful: Unsuccessful:
Pull Request for Issue #14437.
Renames the property fields on the onContentPrepare
event to something more unique jcfields
.
Just create some custom fields for articles and open the article on the front.
Additionally you can in the file components/com_content/views/article/tmpl/default.php add on line 25 the following code snippet:
print_r($this->item);die;
All should work as expected, especially for 3rd party components which do have a fields property on their entities.
For the print_r test, an object with is printed which contains a property jcfields which contains the custom fields.
3rd party components which do have a fields property on their entities got changed to the com_fields.
An object with is printed which contains a property fields which contains the custom fields.
If the developer documentation is written, then it needs to be changed that the property fields will be renamed to jcfields.
Status | New | ⇒ | Pending |
Category | ⇒ | Front End Plugins |
Labels |
Added:
?
|
Title |
|
I think that has to be changed also in the rendering part:
https://github.com/joomla/joomla-cms/blob/staging/components/com_fields/layouts/fields/render.php#L44
and the special handling in contacts:
https://github.com/joomla/joomla-cms/blob/staging/components/com_contact/layouts/fields/render.php#L44
https://github.com/joomla/joomla-cms/blob/staging/components/com_contact/views/contact/view.html.php#L272-L275
https://github.com/joomla/joomla-cms/blob/staging/components/com_contact/views/contact/tmpl/default_user_custom_fields.php#L23
https://github.com/joomla/joomla-cms/blob/staging/templates/beez3/html/com_contact/contact/default_user_custom_fields.php#L22
And also in the search plugin:
https://github.com/joomla/joomla-cms/blob/staging/plugins/search/content/content.php#L328
There may be more places. That's just the ones I found while doing a search for "->fields "
Category | Front End Plugins | ⇒ | Front End com_contact com_fields Plugins Templates (site) |
True, changed it.
Applied the patch - fields are not being saved with article :(
Did you edit on the front end?
Nope in back-end.
Really strange, are you sure you are working on the latest staging? Did you get any error?
Opps, I was testing on beta3. No errors, I will try on staging.
I have tested this item
Content and contact fields are ok.
Why, com_fields was not released, so we can't break bc.
This should go into 3.7.0. Afterwards it would only be possible for 4.0 since it would break implementations
That's mainly just a test that the field has the right name which will be used for extensions. More important are that the rest is working as expected.
I have tested this item
Works as expected. Tested with article and contact page
RTC as there are 2 successfully Tests?
Status | Pending | ⇒ | Ready to Commit |
RTC
Status | Ready to Commit | ⇒ | Fixed in Code Base |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2017-03-25 19:42:32 |
Closed_By | ⇒ | rdeutz | |
Labels |
Added:
?
|
You'r right, fixed.