Feature Request -- Dynamic Get -- Group #404

Closed
opened 2019-04-05 00:28:09 +00:00 by mwweb · 5 comments
mwweb commented 2019-04-05 00:28:09 +00:00 (Migrated from github.com)

Steps to reproduce the issue

I have a field in a table that doesn't have a separate joined table. In my instance, county. I want to create a list of items from only a single county.

I can create a dynamic get, but the list view will create a row for every instance of counties. For example, if there were 10 rows with county=County1, 5 rows with county=County2, the list view would show 15 rows, because that it what it correctly found.

If we had the addition of "Group By" in the Tweak tab, with only the table key, then I could enter a.county.

On compile, if group by has values, then a row similar to the following would be added along with where and order queries:

$query->group('a.county');

Currently I can add that code via custom code, but having a built in option would be cleaner.

Expected result

Have the ability to group rows.

Actual result

No option

System information (as much as possible)

  • OS Name & Version: 14.04.1-Ubuntu
  • MySql Version: 5.5.5-10.1.34-MariaDB-1~trusty
  • Apache Version: Apache/2.4.33 (Ubuntu)
  • PHP Version: 7.1.18-1+ubuntu14.04.1+deb.sury.org+1
  • Joomla Version: 3.9.11
  • JCB Version: 2.9.8
  • Browser: Firefox and Chrome

Additional comments

### Steps to reproduce the issue I have a field in a table that doesn't have a separate joined table. In my instance, county. I want to create a list of items from only a single county. I can create a dynamic get, but the list view will create a row for every instance of counties. For example, if there were 10 rows with county=County1, 5 rows with county=County2, the list view would show 15 rows, because that it what it correctly found. If we had the addition of "Group By" in the Tweak tab, with only the table key, then I could enter a.county. On compile, if group by has values, then a row similar to the following would be added along with where and order queries: $query->group('a.county'); Currently I can add that code via custom code, but having a built in option would be cleaner. ### Expected result Have the ability to group rows. ### Actual result No option ### System information (as much as possible) - OS Name & Version: 14.04.1-Ubuntu - MySql Version: 5.5.5-10.1.34-MariaDB-1~trusty - Apache Version: Apache/2.4.33 (Ubuntu) - PHP Version: 7.1.18-1+ubuntu14.04.1+deb.sury.org+1 - Joomla Version: 3.9.11 - JCB Version: 2.9.8 - Browser: Firefox and Chrome ### Additional comments

Why did you close this again?

Why did you close this again?
mwweb commented 2019-04-05 17:07:58 +00:00 (Migrated from github.com)

I was debating whether it would be a worthwhile suggestion, or just something that would be rarely used.

I was debating whether it would be a worthwhile suggestion, or just something that would be rarely used.
mwweb commented 2019-04-05 19:53:08 +00:00 (Migrated from github.com)

I just reopened it. None of what I was trying was working, then today I finally got it working. So, I do think that this may be a good option. I'm not sure how many people would use it, but grouping items might be a good feature to have available.

I just reopened it. None of what I was trying was working, then today I finally got it working. So, I do think that this may be a good option. I'm not sure how many people would use it, but grouping items might be a good feature to have available.

Okay so the feature has been added, please test it from the staging branch, and let me know.

Okay so the feature has been added, please test it from the staging branch, and let me know.
mwweb commented 2019-04-10 19:47:15 +00:00 (Migrated from github.com)

It looks like it did good:

$query->order('a.county ASC'); $query->group('a.county');

It looks like it did good: ` $query->order('a.county ASC'); $query->group('a.county'); `
Sign in to join this conversation.
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: joomla/Component-Builder#404
No description provided.