? PR-4.3-dev Pending

User tests: Successful: Unsuccessful:

avatar joomdonation
joomdonation
5 Mar 2023

Pull Request for Issue # .

Summary of Changes

This PR makes some minor clean up to Step model from guided tours component :

  1. Simplify code of canEditState method. We do not have to set tour_id for the record before checking the permission. The only case we have to do that is when adding a new step, but this is already being taken care by getItem method
  2. Simplify save method. We do not have get tour_id from session and set it for step. The value for that field is already passed from hidden variable on step form (and we already validate and make sure it's available when a step is being added/editted)
  3. Remove some one time used variable
  4. Rename variable $tourID to $tourId to follow camel case naming convention

Testing Instructions

  1. Use Joomla 4.3 nightly build or a Joomla 4.3 installation which is having Tours Guided available
  2. Apply patch. Try to add/edit step for a tour, make sure nothing is broken

Actual result BEFORE applying this Pull Request

Works

Expected result AFTER applying this Pull Request

Works with cleaner code

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

avatar joomla-cms-bot joomla-cms-bot - change - 5 Mar 2023
Category Administration
avatar joomdonation joomdonation - open - 5 Mar 2023
avatar joomdonation joomdonation - change - 5 Mar 2023
Status New Pending
avatar joomdonation joomdonation - change - 5 Mar 2023
Labels Added: PR-4.3-dev
avatar obuisard obuisard - test_item - 9 Mar 2023 - Not tested
avatar obuisard obuisard - test_item - 9 Mar 2023 - Tested successfully
avatar obuisard
obuisard - comment - 9 Mar 2023

I have not tested this item.


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

avatar obuisard
obuisard - comment - 9 Mar 2023

I have tested this item successfully on efe058d


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

avatar khu5h1 khu5h1 - test_item - 9 Mar 2023 - Tested successfully
avatar khu5h1
khu5h1 - comment - 9 Mar 2023

I have tested this item successfully on efe058d


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

avatar Quy Quy - change - 9 Mar 2023
Status Pending Ready to Commit
avatar Quy
Quy - comment - 9 Mar 2023

RTC


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

avatar obuisard obuisard - change - 9 Mar 2023
Labels Added: ?
avatar obuisard obuisard - change - 9 Mar 2023
Status Ready to Commit Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2023-03-09 20:51:31
Closed_By obuisard
avatar obuisard obuisard - close - 9 Mar 2023
avatar obuisard obuisard - merge - 9 Mar 2023
avatar obuisard
obuisard - comment - 9 Mar 2023

Thank you Tuan @joomdonation, appreciated!

Add a Comment

Login with GitHub to post a comment