J4 Issue ?
avatar brianteeman
brianteeman
5 Jun 2019

While working on #23737 I can't see how or where administrator\components\com_fields\Field\Modal\FieldField.php is used. Can anyone enlighten me?

avatar brianteeman brianteeman - open - 5 Jun 2019
avatar joomla-cms-bot joomla-cms-bot - change - 5 Jun 2019
Labels Added: ?
avatar joomla-cms-bot joomla-cms-bot - labeled - 5 Jun 2019
avatar franz-wohlkoenig franz-wohlkoenig - change - 5 Jun 2019
Labels Added: J4 Issue
avatar franz-wohlkoenig franz-wohlkoenig - labeled - 5 Jun 2019
avatar franz-wohlkoenig franz-wohlkoenig - change - 5 Jun 2019
Status New Discussion
avatar Quy
Quy - comment - 7 Jun 2019

I assume it is for the Field button in the editor.

editor-field

avatar brianteeman
brianteeman - comment - 7 Jun 2019

@Quy thanks for the answer but I don't think that's it. Deleting the file has no impact on that button or the resulting modal

avatar Quy
Quy - comment - 7 Jun 2019

You're right. I think it is safe to delete. In it there are untranslated language strings.

avatar infograf768
infograf768 - comment - 7 Jun 2019

That kind of modal is used when there are associations that can be set when editing an item.
For example modal_article for com_content:
https://github.com/joomla/joomla-cms/blob/4.0-dev/administrator/components/com_content/Model/ArticleModel.php#L1107-L1137

  1. There is no code to associate fields in the preprocess form of FieldModel
  2. I don't even know if it makes sense to associate fields.

ATM, the field type is not used.

avatar infograf768
infograf768 - comment - 7 Jun 2019

As for the Field displaying in the TinyMCE CMS Content dropdown, it depends on the Button - Field editor-xtd and I wonder what it is used for as we can't select a field in the modal produced but only displays the existing fields. Normally though, looking at the $link, it should use that modal.
$link = 'index.php?option=com_fields&view=fields&layout=modal&tmpl=component&context=' . $context . '&editor=' . $name . '&' . Session::getFormToken() . '=1';

avatar Quy
Quy - comment - 7 Jun 2019

It works in J3, but not in J4.

From the Content - Fields plugin:

This plugin allows you to display a custom field which has been inserted with the 'Button - Fields' plugin or using Syntax: {field #} directly into the editor area.
Possible Syntax:

    {field 1} will display the field with the ID 1
    {field 1,foo} will display the selected field using the alternative layout 'foo'.
    {fieldgroup 2} will display all fields within the fieldgroup with the ID 2.
avatar joomla-cms-bot joomla-cms-bot - change - 7 Jun 2019
Closed_Date 2019-06-07 20:58:02 2019-06-07 20:58:03
Closed_By Quy joomla-cms-bot
avatar joomla-cms-bot joomla-cms-bot - close - 7 Jun 2019
avatar Quy Quy - change - 7 Jun 2019
Status Discussion Closed
Closed_Date 0000-00-00 00:00:00 2019-06-07 20:58:02
Closed_By Quy
avatar joomla-cms-bot
joomla-cms-bot - comment - 7 Jun 2019

Set to "closed" on behalf of @Quy by The JTracker Application at issues.joomla.org/joomla-cms/25125

avatar Quy
Quy - comment - 7 Jun 2019

Please test PR #25139.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/25125.

avatar Quy
Quy - comment - 7 Jun 2019

Please test PR #25139.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/25125.

Add a Comment

Login with GitHub to post a comment