? Failure
Related to # 4778

User tests: Successful: Unsuccessful:

avatar joomdonation
joomdonation
17 Oct 2014

PR summary

This PR fixes the issue #4778 reported by @apurvaduduskar. Basically, when you are on Joomla group edit screen, if you press "Save as Copy" button to create a new group without changing title, the system will throws an error message and doesn't create a copy group as expected.

I also fixed two ridiculous blocks of code at https://github.com/joomla/joomla-cms/blob/staging/administrator/components/com_users/models/group.php#L163 and https://github.com/joomla/joomla-cms/blob/staging/administrator/components/com_users/models/group.php#L201

How to test:

Testing this PR is simple. You just need to login to administrator area of your site, then go to Users -> Groups, click on a group to edit (don't change group title), then press "Save as Copy" button in the toolbar:

  1. Before patch: The system doesn't create the new group and throw an error message

  2. After patch: The new group is created without error message. The title of the new group is created based on title of the original group and append an increment number: Group (2), Group (3)...

avatar joomdonation joomdonation - open - 17 Oct 2014
avatar jissues-bot jissues-bot - change - 17 Oct 2014
Labels Added: ?
avatar brianteeman brianteeman - change - 17 Oct 2014
Category Administration
avatar brianteeman brianteeman - change - 17 Oct 2014
Title
Fix "Save as copy" button of User Group #4778
Fix "Save as copy" button of User Group
Rel_Number 4778
Relation Type Related to
avatar 1apweb 1apweb - test_item - 17 Oct 2014 - Tested unsuccessfully
avatar 1apweb
1apweb - comment - 17 Oct 2014

Notice when I click on a group :

Strict standards: Declaration of UsersModelGroup::generateNewTitle() should be compatible with JModelAdmin::generateNewTitle($category_id, $alias, $title) in C:\UwAmp\www\pizzabug\administrator\components\com_users\models\group.php on line 18
Call Stack

Time Memory Function Location

1 0.0000 142976 {main}( ) ..\index.php:0
2 0.0600 2128984 JApplicationCms->execute( ) ..\index.php:42
3 0.0600 2129072 JApplicationAdministrator->doExecute( ) ..\cms.php:251
4 0.1200 3407752 JApplicationAdministrator->dispatch( ) ..\administrator.php:152
5 0.1200 3447592 JComponentHelper::renderComponent( ) ..\administrator.php:98
6 0.1300 3504304 JComponentHelper::executeComponent( ) ..\helper.php:332
7 0.1300 3526152 require_once( 'C:\UwAmp\www\pizzabug\administrator\components\com_users\users.php' ) ..\helper.php:352
8 0.1500 4120008 JControllerLegacy->execute( ) ..\users.php:21
9 0.1500 4120064 UsersController->display( ) ..\legacy.php:730
10 0.1600 4203816 JControllerLegacy->display( ) ..\controller.php:109
11 0.1600 4315328 JControllerLegacy->getModel( ) ..\legacy.php:650
12 0.1600 4315512 JControllerLegacy->createModel( ) ..\legacy.php:756
13 0.1600 4315656 JModelLegacy::getInstance( ) ..\legacy.php:570
14 0.1600 4352192 require_once( 'C:\UwAmp\www\pizzabug\administrator\components\com_users\models\group.php' ) ..\legacy.php:186

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

avatar joomlamarco joomlamarco - test_item - 17 Oct 2014 - Tested successfully
avatar joomdonation
joomdonation - comment - 17 Oct 2014

Thanks @1apweb for testing. I updated the PR to solve that notice error. Please help testing it again :).

avatar joomlamarco
joomlamarco - comment - 17 Oct 2014

test was successful after installing patch
using php 5.4.19, mysql 5.5.32 j3.3.6

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

avatar 1apweb 1apweb - test_item - 17 Oct 2014 - Tested successfully
avatar 1apweb
1apweb - comment - 17 Oct 2014

Hi,

Great, is ok now ! Thanks

De : Tuan Pham Ngoc [mailto:notifications@github.com]
Envoyé : vendredi 17 octobre 2014 19:13
À : joomla/joomla-cms
Cc : 1apweb
Objet : Re: [joomla-cms] Fix "Save as copy" button of User Group (#4798)

Thanks @1apweb https://github.com/1apweb for testing. I updated the PR to solve that notice error. Please help testing it again :).


Reply to this email directly or view it on GitHub #4798 (comment) .Image supprimée par l'expéditeur.

avatar joomdonation
joomdonation - comment - 17 Oct 2014

Thanks for both of you for your help :).

avatar brianteeman
brianteeman - comment - 17 Oct 2014

Setting to RTC - thanks

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

avatar brianteeman brianteeman - change - 17 Oct 2014
Status Pending Ready to Commit
avatar wingchunneil
wingchunneil - comment - 17 Oct 2014

I get a 400 bad request error when applying this patch.

Browser message:
Bad Request
Your browser sent a request that this server could not understand.

Browser : Chrome

Joomla version:3.3.6

avatar N6REJ
N6REJ - comment - 17 Oct 2014

@test patch works as described ( tested via patch tester )

avatar brianteeman brianteeman - alter_testresult - 17 Oct 2014 - n6nrj: Tested successfully
avatar nicksavov nicksavov - change - 17 Oct 2014
Labels Added: ?
avatar jissues-bot jissues-bot - change - 17 Oct 2014
Labels Added: ?
avatar mtmeyrick mtmeyrick - test_item - 17 Oct 2014 - Tested successfully
avatar joomdonation
joomdonation - comment - 18 Oct 2014

@wingchunneil: That might be something related to patch tester component.

@All : Thanks for help testing

@Committer : Travis Failed, however it is not related to this PR, so this one can be merged.

avatar phproberto phproberto - close - 18 Oct 2014
avatar phproberto phproberto - change - 18 Oct 2014
Status Ready to Commit Closed
Closed_Date 0000-00-00 00:00:00 2014-10-18 03:33:58

Add a Comment

Login with GitHub to post a comment