Feature RTC PR-5.3-dev Pending

User tests: Successful: Unsuccessful:

avatar Fedik
Fedik
28 Jul 2024

Summary of Changes

Replace control inputs hardcoded into the form layout with an API which allows to add this fields programaticaly.

Before PR (the form layout):

<input type="hidden" name="task" value="">
<input type="hidden" name="return" value="<?php echo $input->getBase64('return'); ?>">
<input type="hidden" name="forcedLanguage" value="<?php echo $input->get('forcedLanguage', '', 'cmd'); ?>">
<?php echo HTMLHelper::_('form.token'); ?>

After PR:

// In Controller/View
$this->form
  ->addControlField('task', '')
  ->addControlField('return', $input->getBase64('return', ''))
  ->addControlField('forcedLanguage', $forcedLanguage);

// In the form layout
echo $this->form->renderControlFields();

For now I have updated following forms:

  • Article
  • Category
  • Menu

Will update more, when there will be a positive feedbacks.

Testing Instructions

Code review.
Create/edit Article, Category, Menu item. All should work as before.

Actual result BEFORE applying this Pull Request

Works

Expected result AFTER applying this Pull Request

Works

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: joomla/Manual#322
  • No documentation changes for manual.joomla.org needed
avatar Fedik Fedik - open - 28 Jul 2024
avatar Fedik Fedik - change - 28 Jul 2024
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 28 Jul 2024
Category Administration com_categories com_content com_menus Front End Libraries
avatar Fedik Fedik - change - 28 Jul 2024
Title
[5.x] Form control fields
[5.x] Form control fields, new API
avatar Fedik Fedik - edited - 28 Jul 2024
avatar Frostholm7 Frostholm7 - test_item - 9 Aug 2024 - Tested successfully
avatar Frostholm7
Frostholm7 - comment - 9 Aug 2024

I have tested this item ✅ successfully on 5cfe985

A long life in IT, I have learned that everything changes.
A wise controller, from Italy, whom I once met, said that we should remember that we did not invent solutions to problems that we did not have! Extra testing, modifying working code, and so on.

The code does as described, it is as such ok.

I miss a use case for this change. What is it that is being tried to solve?
It could just be that I just haven't seen it.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/43857.
avatar Frostholm7
Frostholm7 - comment - 9 Aug 2024

PS. testet on
Wampserver install version 3.3.2 installed on 2024-04-03
Updated to 3.3.6 on 2024-08-04
MySQL 8.2.0 Port 3306
Apache 2.4.62
PHP 8.3.10
error_reporting = E_ALL
Display Errors = on

With

2024-08-09
5.2 dev
a9980fe


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

avatar Frostholm7
Frostholm7 - comment - 9 Aug 2024

version a9980fe


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

avatar Frostholm7
Frostholm7 - comment - 9 Aug 2024

It's weird that my text disappears or gets changed.


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

avatar Fedik Fedik - change - 17 Aug 2024
Labels Added: Feature PR-5.2-dev
avatar superd0ll superd0ll - test_item - 24 Aug 2024 - Tested successfully
avatar superd0ll
superd0ll - comment - 24 Aug 2024

I have tested this item ✅ successfully on c24da87

Tested successfully


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

avatar exlemor exlemor - test_item - 24 Aug 2024 - Tested successfully
avatar exlemor
exlemor - comment - 24 Aug 2024

I have tested this item ✅ successfully on c24da87

I was able to test successfully :)


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

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

RTC


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

avatar HLeithner
HLeithner - comment - 2 Sep 2024

This pull request has been automatically rebased to 5.3-dev.

avatar HLeithner HLeithner - change - 2 Sep 2024
Title
[5.x] Form control fields, new API
[5.3] Form control fields, new API
avatar HLeithner HLeithner - edited - 2 Sep 2024
avatar HLeithner HLeithner - change - 16 Oct 2024
Status Ready to Commit Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2024-10-16 18:30:42
Closed_By HLeithner
Labels Added: RTC PR-5.3-dev
Removed: PR-5.2-dev
avatar HLeithner HLeithner - close - 16 Oct 2024
avatar HLeithner HLeithner - merge - 16 Oct 2024
avatar HLeithner
HLeithner - comment - 16 Oct 2024

thanks, first step for form renderer

avatar Fedik Fedik - change - 20 Oct 2024
The description was changed
avatar Fedik Fedik - edited - 20 Oct 2024

Add a Comment

Login with GitHub to post a comment