? ? ? Success

User tests: Successful: Unsuccessful:

avatar andrepereiradasilva
andrepereiradasilva
18 Apr 2016

Pull Request for Improvement.

Summary of Changes

This PR adds the counting columns like the ones that exist in categories and menus to the com_banners clients view.

Also does some minor changes in code.

Before PR

image

After PR

image

Testing Instructions

  1. Use latest staging and apply this patch
  2. Go to Extensions -> Banners -> Clients and create some banner clients
  3. Go to Extensions -> Banners -> Banners, create some banners and associate then to the clients created in 2.
  4. Go again to Extensions -> Banners -> Clients and test the counting and their links.
avatar andrepereiradasilva andrepereiradasilva - open - 18 Apr 2016
avatar andrepereiradasilva andrepereiradasilva - change - 18 Apr 2016
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 18 Apr 2016
Labels Added: ? ?
avatar andrepereiradasilva andrepereiradasilva - change - 18 Apr 2016
Title
[com_banners] Clients banners counting
[com_banners] clients view: Banners counting
avatar brianteeman brianteeman - change - 19 Apr 2016
Category Components UI/UX
avatar brianteeman brianteeman - change - 19 Apr 2016
Labels
avatar brianteeman brianteeman - change - 19 Apr 2016
Category Components UI/UX Components Language & Strings UI/UX
avatar brianteeman brianteeman - change - 19 Apr 2016
Labels
avatar brianteeman brianteeman - test_item - 19 Apr 2016 - Tested successfully
avatar brianteeman
brianteeman - comment - 19 Apr 2016

I have tested this item :white_check_mark: successfully on 31ad9c3


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

avatar richard67 richard67 - test_item - 19 Apr 2016 - Tested unsuccessfully
avatar richard67
richard67 - comment - 19 Apr 2016

I have tested this item :red_circle: unsuccessfully on 31ad9c3

I tested with testing data and found following bug:

Because each client only had 1 banner, I copied one banner and saved it with a new name.

Result: One unpublished and one published counted for this client => OK.

Then I published the copied banner.

Result: Still one published only, and zero unpublished => Wrong for published.

Reason: You count the distinct number of client ids, but you have to count the banners with the particular client IDs.

Means you have to change in your query in line 225 the "->select('cid, COUNT(DISTINCT cid) AS count_published')" to "->select('cid, COUNT(cid) AS count_published')", i.e. just remove the "DISTINCT".

Since I am an Oracle SQL expert on guru level you can trust me.


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

avatar richard67
richard67 - comment - 19 Apr 2016
avatar andrepereiradasilva andrepereiradasilva - change - 19 Apr 2016
Labels
avatar joomla-cms-bot
joomla-cms-bot - comment - 19 Apr 2016

This PR has received new commits.

CC: @brianteeman, @richard67


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

avatar richard67
richard67 - comment - 19 Apr 2016

@brianteeman How did you test this? With 1 banner of each status, so the count always would correctly show 1?


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

avatar andrepereiradasilva
andrepereiradasilva - comment - 19 Apr 2016

ok @richard67 thanks for the hint. solved the question. please retest

avatar brianteeman
brianteeman - comment - 19 Apr 2016

yes - retesting it now

On 19 April 2016 at 10:39, Richard Fath notifications@github.com wrote:

@brianteeman https://github.com/brianteeman How did you test this? With

1 banner of each status, so the count always would correctly show 1?

This comment was created with the J!Tracker Application
https://github.com/joomla/jissues at issues.joomla.org/joomla-cms/9976
https://issues.joomla.org/tracker/joomla-cms/9976.


You are receiving this because you were mentioned.
Reply to this email directly or view it on GitHub
#9976 (comment)

Brian Teeman
Co-founder Joomla! and OpenSourceMatters Inc.
http://brian.teeman.net/

avatar andrepereiradasilva
andrepereiradasilva - comment - 19 Apr 2016

ups sorry there seems also be a problem with archived. wait a sec

avatar joomla-cms-bot
joomla-cms-bot - comment - 19 Apr 2016

This PR has received new commits.

CC: @brianteeman, @richard67


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

avatar andrepereiradasilva
andrepereiradasilva - comment - 19 Apr 2016

ok archived solved too.

avatar richard67
richard67 - comment - 19 Apr 2016

@andrepereiradasilva If you find time, please correct the code comments, too: They contain "menu" where it should be "banners", e.g.

// Get the unpublished menu counts.

I assume this could be also the case for your other recent PRs?


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

avatar richard67
richard67 - comment - 19 Apr 2016

Or

// Get the menu types of menus in the list.


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

avatar andrepereiradasilva
andrepereiradasilva - comment - 19 Apr 2016

That was a copy paste problem. will correct. thanks

no, this is the only PR that use counts.
The other ones are just for adding the max level filters.

avatar richard67
richard67 - comment - 19 Apr 2016

Ah yes sorry, was confused it seems. Sure, only this one. I will test anyway because is only a comments problem.

avatar joomla-cms-bot
joomla-cms-bot - comment - 19 Apr 2016

This PR has received new commits.

CC: @brianteeman, @richard67


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

avatar andrepereiradasilva
andrepereiradasilva - comment - 19 Apr 2016

ok, comments also corrected. sorry for that guys.
please retest.

avatar brianteeman brianteeman - test_item - 19 Apr 2016 - Tested successfully
avatar brianteeman
brianteeman - comment - 19 Apr 2016

I have tested this item :white_check_mark: successfully on a4501d6


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

avatar richard67 richard67 - test_item - 19 Apr 2016 - Tested successfully
avatar richard67
richard67 - comment - 19 Apr 2016

I have tested this item :white_check_mark: successfully on a4501d6


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

avatar andrepereiradasilva
andrepereiradasilva - comment - 19 Apr 2016

@richard67 @brianteeman thanks for testing!

avatar brianteeman brianteeman - change - 19 Apr 2016
Status Pending Ready to Commit
Labels
avatar brianteeman
brianteeman - comment - 19 Apr 2016

RTC


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

avatar joomla-cms-bot joomla-cms-bot - change - 19 Apr 2016
Labels Added: ?
avatar brianteeman brianteeman - change - 19 Apr 2016
Milestone Added:
avatar rdeutz
rdeutz - comment - 19 Apr 2016

technically this is a new feature and it doesn't fix a bug so it has to go into 3.6.0

avatar rdeutz rdeutz - change - 19 Apr 2016
Milestone Added:
avatar rdeutz rdeutz - change - 19 Apr 2016
Milestone Removed:
avatar brianteeman
brianteeman - comment - 19 Apr 2016

It fixes a bug in that the counting is present elsewhere but not in this
component ;)

avatar andrepereiradasilva
andrepereiradasilva - comment - 19 Apr 2016

IMHO sometimes a "new feature" is created to solve a logical inconsistency (bug).
But, of course, i leave to you maintainers to decide that.

avatar rdeutz rdeutz - change - 2 May 2016
Labels Added: ?
avatar rdeutz rdeutz - change - 2 May 2016
Status Ready to Commit Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2016-05-02 06:14:34
Closed_By rdeutz
avatar brianteeman brianteeman - change - 11 May 2016
Labels Removed: ?

Add a Comment

Login with GitHub to post a comment