Feature RTC Language Change PR-5.1-dev Pending

User tests: Successful: Unsuccessful:

avatar alikon
alikon
5 Feb 2024

Pull Request for Issue # .

Summary of Changes

control max results and max render from fancy-select by xml

Testing Instructions

Create an SQL field.

Use a query that returns more than 10 values that share the same portion of text for "text," for example:

SELECT 1 AS value, 'month-January' AS text
UNION ALL
SELECT 2 AS value, 'month-February' AS text
UNION ALL
SELECT 3 AS value, 'month-March' AS text
UNION ALL
SELECT 4 AS value, 'month-April' AS text
UNION ALL
SELECT 5 AS value, 'month-May' AS text
UNION ALL
SELECT 6 AS value, 'month-June' AS text
UNION ALL
SELECT 7 AS value, 'month-July' AS text
UNION ALL
SELECT 8 AS value, 'month-August' AS text
UNION ALL
SELECT 9 AS value, 'month-September' AS text
UNION ALL
SELECT 10 AS value, 'month-October' AS text
UNION ALL
SELECT 11 AS value, 'month-November' AS text
UNION ALL
SELECT 12 AS value, 'month-December' AS text;

In the Form Layout set as a view "Enhanced Select".

Actual result BEFORE applying this Pull Request

When you try to search for "month" as a value in the field, you only display 10 results as per choice.js default

Expected result AFTER applying this Pull Request

When you try to search for "month" as a value in the field, the number of values returned is governed by the parameters in the Field -> General
image

Link to documentations

Please select:

  • Documentation link for docs.joomla.org:

  • No documentation changes for docs.joomla.org needed

  • Pull Request link for manual.joomla.org:

  • No documentation changes for manual.joomla.org needed

Votes

# of Users Experiencing Issue
2/2
Average Importance Score
4.50

avatar alikon alikon - open - 5 Feb 2024
avatar alikon alikon - change - 5 Feb 2024
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 5 Feb 2024
Category Administration Language & Strings Front End Plugins
avatar alikon alikon - change - 5 Feb 2024
Labels Added: Language Change PR-5.1-dev
8f185f5 10 Feb 2024 avatar alikon xml
69a2e2a 11 Feb 2024 avatar alikon xml
avatar alikon alikon - change - 11 Feb 2024
The description was changed
avatar alikon alikon - edited - 11 Feb 2024
avatar alikon alikon - change - 11 Feb 2024
The description was changed
avatar alikon alikon - edited - 11 Feb 2024
4e528f9 14 Feb 2024 avatar alikon cs
3a8bfb7 14 Feb 2024 avatar alikon cs
avatar brianteeman
brianteeman - comment - 16 Feb 2024

why does max-render have JALL but maxresults only have J500

avatar alikon
alikon - comment - 16 Feb 2024

if i read correctly choice.js code there is no -1 for for max-results
but i could be wrong

avatar brianteeman
brianteeman - comment - 16 Feb 2024

maybe so but both fields are the same type and layout

avatar alikon
alikon - comment - 16 Feb 2024

not sure to get your point
but 500 max search results are far better than 10
or not ?

avatar brianteeman
brianteeman - comment - 16 Feb 2024

I am just querying why we have different settings

avatar Razzo1987
Razzo1987 - comment - 18 Feb 2024

I am just querying why we have different settings

The current JS setting (without the options) is:

  • Max Result = 10
  • Max Render = -1 (ALL)

Max Result does not support -1 (ALL) so it cannot be included in the list because it would not work.
Taking -1 (ALL) out of the Max Render list would limit the number of elements to a maximum of 500, so it would be a loss of functionality.
The only solution I see is to leave the 2 different lists.

avatar brianteeman
brianteeman - comment - 18 Feb 2024

Thank you for a logical answer

avatar ceford ceford - test_item - 23 Feb 2024 - Tested successfully
avatar ceford
ceford - comment - 23 Feb 2024

I have tested this item ✅ successfully on 760c029


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

avatar robertolongo robertolongo - test_item - 24 Feb 2024 - Tested successfully
avatar robertolongo
robertolongo - comment - 24 Feb 2024

I have tested this item ✅ successfully on 760c029

OK, it works.


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

avatar faustonenci faustonenci - test_item - 24 Feb 2024 - Tested successfully
avatar faustonenci
faustonenci - comment - 24 Feb 2024

I have tested this item ✅ successfully on 760c029

all right


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

avatar crimle crimle - test_item - 24 Feb 2024 - Tested unsuccessfully
avatar crimle
crimle - comment - 24 Feb 2024

I have tested this item ? unsuccessfully on 760c029

Changing firefox to dark mode immediately changes to dark mode in Joomla as well. With or without this patch.


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

avatar richard67
richard67 - comment - 24 Feb 2024

I have tested this item ? unsuccessfully on 760c029Changing firefox to dark mode immediately changes to dark mode in Joomla as well. With or without this patch.

@crimle Are you sure you posted your test result for the right pull request (PR)? I don't see how this PR here is related to dark mode. Please check and report back, and either alter your test result back to "not tested" or ask us to do so for you. Thanks in advance.

avatar crimle crimle - test_item - 24 Feb 2024 - Not tested
avatar crimle
crimle - comment - 24 Feb 2024

I have not tested this item.


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

avatar richard67 richard67 - change - 24 Feb 2024
Status Pending Ready to Commit
avatar richard67
richard67 - comment - 24 Feb 2024

RTC


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

avatar bembelimen
bembelimen - comment - 27 Feb 2024

I wonder, why did you rename the field name? How do you take care about the "old" values, isn't this a B/C break then?

avatar alikon
alikon - comment - 28 Feb 2024

iirc i didn't want to touch com_fields
to limit the impact surface of the pr

avatar Razzo1987
Razzo1987 - comment - 28 Feb 2024

I wonder, why did you rename the field name? How do you take care about the "old" values, isn't this a B/C break then?

Leaving form_layout and binding the 2 options to that tag does not work.
data-* options are loaded only with layout, this xml tag is also documented here, when the limit to fancy was introduced.

To make it work with form_layout com_fields has to be rewritten, which was not intended to be the goal of this PR

avatar Fedik Fedik - change - 5 Mar 2024
Status Ready to Commit Pending
avatar Fedik
Fedik - comment - 5 Mar 2024

Not ready


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

avatar Fedik
Fedik - comment - 5 Mar 2024

The PR is not finished.
It can go in 5.x, if done properly there no b/c break.

Current XML modifications should be reverted. As we talked with @Razzo1987
And some more changes still need to be done.

avatar Fedik
Fedik - comment - 5 Mar 2024

I would add, that the changes should be done for list field first, and then copyed to sql field.
Because sql field extends the list field.

avatar Razzo1987
Razzo1987 - comment - 5 Mar 2024

Hi @Fedik, the problem stems from the fact that to fix the bug and continue using form_layout the change on com_fields should be made. If I understand correctly from @alikon he does not feel confident in touching that part. If you can give him support I am also confident that using form_layout avoids b/c breaks.

avatar alikon
alikon - comment - 5 Mar 2024

i would like to make this happen for 5.x not 6.x, let's join together the effort then, the pr it's already open, better,
let's schedule a meet via mattermost on the weekend ? if you can

avatar alikon alikon - change - 5 Mar 2024
Title
[5.1] sql custom field - max results from xml
[5.x] list custom field - max results from xml
avatar alikon alikon - edited - 5 Mar 2024
avatar alikon alikon - change - 5 Mar 2024
Title
[5.x] list custom field - max results from xml
[5] RFC list custom field - max results from xml
avatar alikon alikon - edited - 5 Mar 2024
avatar Fedik
Fedik - comment - 9 Mar 2024

@alikon I made a PR to fix stuff alikon#49

avatar alikon alikon - change - 9 Mar 2024
Labels Added: Feature Updates Requested
avatar joomla-cms-bot joomla-cms-bot - change - 9 Mar 2024
Category Administration Language & Strings Front End Plugins Administration com_fields Language & Strings Front End Plugins
avatar alikon
alikon - comment - 9 Mar 2024

thank you @Fedik

avatar alikon alikon - change - 9 Mar 2024
Title
[5] RFC list custom field - max results from xml
[5] list custom field - max results from xml
avatar alikon alikon - edited - 9 Mar 2024
avatar alikon alikon - change - 10 Mar 2024
Labels Removed: Updates Requested
avatar Razzo1987 Razzo1987 - test_item - 13 Mar 2024 - Tested successfully
avatar Razzo1987
Razzo1987 - comment - 13 Mar 2024

I have tested this item ✅ successfully on d736c88

Successfully tested with both List and SQL.

Tested with the example of the 12 months of the year and used the combinations:

  • Max Results: 10, Max Render: ALL: He behaves as he always has
  • Max Results: 100, Max Render: ALL: Show the 12 months by searching "month" (there are less than 100)
  • Max Results: 5, Max Render: 5: Show only 5 months, also by searching "month"
  • Max Results: 100, Max Render: 5: Show only 5 months, by search it show all the 12 months

Another test: if I set the fancy layout before applying the patch now it is retained. Thanks @Fedik

However, I propose to include j500 in the options.
For some cases 100 options might be few and we cannot put a consideration for ALL. J500 is 5x the current maximum and seems to me a good compromise.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/42765.
avatar Fedik
Fedik - comment - 14 Mar 2024

However, I propose to include j500 in the options.

It will have a huge performance and usability issue, I think anything more than 20-30 is already to much.

avatar Quy Quy - test_item - 14 Mar 2024 - Tested successfully
avatar Quy
Quy - comment - 14 Mar 2024

I have tested this item ✅ successfully on cdc2480


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

avatar Razzo1987
Razzo1987 - comment - 15 Mar 2024

However, I propose to include j500 in the options.

It will have a huge performance and usability issue, I think anything more than 20-30 is already to much.

I'll try to do a video, but I really don't think it changes much in terms of performance.
I have a SQL field that extracts 1500+ records and the latency is related to the query not the limits imposed by the fancy-select

avatar viocassel viocassel - test_item - 15 Mar 2024 - Tested successfully
avatar viocassel
viocassel - comment - 15 Mar 2024

I have tested this item ✅ successfully on cdc2480


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

avatar richard67 richard67 - change - 15 Mar 2024
Status Pending Ready to Commit
avatar richard67
richard67 - comment - 15 Mar 2024

RTC


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

avatar Razzo1987
Razzo1987 - comment - 16 Mar 2024

Performance test

Create a SQL field with multiple values, for example:

SELECT concat(`TABLE_SCHEMA`, '-', `TABLE_NAME`, '-', `COLUMN_NAME`) AS value,
               concat(`TABLE_SCHEMA`, '.', `TABLE_NAME`, '.', `COLUMN_NAME`) AS text
FROM `information_schema`.`COLUMNS`

Test 1: Form Layout = HTML Select

HTML-Select.mp4

Test 2: Form Layout = Enhanced Select, Max Result = 10, Max Render = All

Enhanced-Select-10-ALL_1.mp4

Test 3: Form Layout = Enhanced Select, Max Result = 500, Max Render = All

Enhanced-Select-500-ALL_2.mp4

Personally, I do not observe significant performance changes in user experience between 10 and 500

avatar Razzo1987
Razzo1987 - comment - 16 Mar 2024

@alikon I think is missing the new option on plugins/fields/list/list.xml.
I have done alikon#54 on your branch ;)
Before merge check if the name must be "form_layout" or "layout" (in my PR and in this one)

avatar Fedik
Fedik - comment - 16 Mar 2024

Sorry @Razzo1987 , but 6 second for the form rendering I would call it disaster ?
And imagine User add multiple of this fields?

Note: changes in this PR does not affect SQL limit, only the rendering limit for choices.js

avatar Razzo1987
Razzo1987 - comment - 16 Mar 2024

Sorry @Razzo1987 , but 6 second for the form rendering I would call it disaster ? And imagine User add multiple of this fields?

Note: changes in this PR does not affect SQL limit, only the rendering limit for choices.js

Correct, but the 6 seconds is because the form loads 1500+ items in the list.
In fact even with HTML Select the time is that. the fact that I set the search limit to 500 did not affect with other lag

avatar Fedik
Fedik - comment - 16 Mar 2024

Correct, but the 6 seconds is because the form loads 1500+ items in the list.

And that what you should never do, ever ?
You may have fast PC, but someone have older, and it may take a minutes just to render.

the fact that I set the search limit to 500 did not affect with other lag

Yeah, well, but I still do not like it, it just unusable, and fancy-layout allows to search already ?

avatar alikon alikon - change - 17 Mar 2024
Labels Added: RTC
avatar Razzo1987 Razzo1987 - test_item - 17 Mar 2024 - Tested successfully
avatar Razzo1987
Razzo1987 - comment - 17 Mar 2024

I have tested this item ✅ successfully on 058087f

Successfully tested with both List and SQL.

Tested with the example of the 12 months of the year and used the combinations:

  • Max Results: 10, Max Render: ALL: He behaves as he always has
  • Max Results: 100, Max Render: ALL: Show the 12 months by searching "month" (there are less than 100)
  • Max Results: 5, Max Render: 5: Show only 5 months, also by searching "month"
  • Max Results: 100, Max Render: 5: Show only 5 months, by search it show all the 12 months

Another test: if I set the fancy layout before applying the patch now it is retained.


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

avatar Quy Quy - alter_testresult - 18 Mar 2024 - Quy: Not tested
avatar robertolongo robertolongo - test_item - 20 Mar 2024 - Tested successfully
avatar robertolongo
robertolongo - comment - 20 Mar 2024

I have tested this item ✅ successfully on eb1af78


I made the following tests (using the SQL query with months):

  • Max Results: 10 - Max Render: ALL - Search string: empty --> I see the list complete
  • Max Results: 10 - Max Render: 5 - Search string: empty --> I see the first 5 elements in the list
  • Max Results: 10 - Max Render: ALL - Search string: "month"--> I see the first 10 elements in the list
  • Max Results: 25 - Max Render: ALL - Search string: "month" --> I see the list complete

I changed the query to obtain a resultset with 26 elements:

  • Max Results: 25 - Max Render: ALL - Search string: "month" -->I see the first 25 elements in the list
  • Max Results: 25 - Max Render: 10- Search string: empty -->I see the the first 10 elements in the list
  • Max Results: 100 - Max Render: ALL - Search string: "month" -->I see the list complete

The patch worked as expected.


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

avatar robertolongo
robertolongo - comment - 20 Mar 2024

I made the following tests (using the SQL query with months):

  • Max Results: 10 - Max Render: ALL - Search string: empty --> I see the list complete
  • Max Results: 10 - Max Render: 5 - Search string: empty --> I see the first 5 elements in the list
  • Max Results: 10 - Max Render: ALL - Search string: "month"--> I see the first 10 elements in the list
  • Max Results: 25 - Max Render: ALL - Search string: "month" --> I see the list complete

I changed the query to obtain a resultset with 26 elements:

  • Max Results: 25 - Max Render: ALL - Search string: "month" -->I see the first 25 elements in the list
  • Max Results: 25 - Max Render: 10- Search string: empty -->I see the the first 10 elements in the list
  • Max Results: 100 - Max Render: ALL - Search string: "month" -->I see the list complete

The patch worked as expected.


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

avatar richard67 richard67 - alter_testresult - 20 Mar 2024 - Razzo1987: Tested successfully
avatar richard67
richard67 - comment - 20 Mar 2024

I've restored @Razzo1987 's test result in the issue tracker since the commit which invalidated the test counter was just a clean branch update.

@Quy If you update the branch of a PR which has human test results and the branch update is clean without any merge conflicts to be solved, could you then restore the test results of the users by using the "Alter test" button in the issue tracker? Thanks in advance.

avatar richard67
richard67 - comment - 20 Mar 2024

Ah I just see it was ready to commit already.

avatar Razzo1987
Razzo1987 - comment - 20 Mar 2024

Ah I just see it was ready to commit already.

Yes, it had remained in RTC even after the changes 3 days ago, I don't know why.
I wrote to Roberto today if he could redo the tests that have done during PBF ;)

avatar richard67
richard67 - comment - 20 Mar 2024

Well we have now 2 tests again which are valid, so RTC is again valid.

avatar alikon
alikon - comment - 11 Apr 2024

as there is no interest

avatar alikon alikon - close - 11 Apr 2024
avatar alikon alikon - change - 11 Apr 2024
Status Ready to Commit Closed
Closed_Date 0000-00-00 00:00:00 2024-04-11 19:09:17
Closed_By alikon
avatar alikon
alikon - comment - 27 Jan 2025

redone and rebased on 5.3 pr #44794

Add a Comment

Login with GitHub to post a comment