? Success

User tests: Successful: Unsuccessful:

avatar dgt41
dgt41
7 Apr 2016

This is a redo of #4294

Summary of Changes

Right now if you want to include some custom fields in your template you need to include a custom field path in the relative xml file, something like:

<fieldset addfieldpath="/templates/<template name>/field">

Documented here: https://docs.joomla.org/Creating_a_custom_form_field_type

This PR leverages this, so custom fields will happily reside inside a folder named field

Why field and not fields?
Singular word help us transition to autoload and namespace

Testing Instructions

Apply this patch with patch tester
edit administrator/templates/isis/templateDetails.xml and paste at line 49

                <field name="testone" class="" type="testone" default="0"
                       label="test one"
                       description="test one" />

Create a folder named field inside administrator/templates/isis
copy testone.php to the folder you just created from https://gist.github.com/dgt41/ec0e2afe879c5d07ffadd2c8a639e1a7

Go to Edit Style for Isis and check if the first field is like the one from the image below
screen shot 2016-04-07 at 23 40 27

If so you have a successful test!

B/C

No backwards compatibility break

Performance

We just add one more folder check to the whole stack, so performance degradation should be unnoticeable. (Joomla itself does that hundreds of times for core libraries)

avatar dgt41 dgt41 - open - 7 Apr 2016
avatar dgt41 dgt41 - change - 7 Apr 2016
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 7 Apr 2016
Labels Added: ?
6408672 7 Apr 2016 avatar dgt41 init
avatar brianteeman brianteeman - change - 7 Apr 2016
Category Fields Templates (site)
avatar brianteeman brianteeman - change - 7 Apr 2016
Category Fields Templates (site) Fields Templates (admin) Templates (site)
avatar brianteeman
brianteeman - comment - 7 Apr 2016

In your test instructions it says create a file called testing.php. Shouldnt that be testone.php?


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

avatar dgt41
dgt41 - comment - 7 Apr 2016

yup!, Thanks

avatar dgt41 dgt41 - change - 7 Apr 2016
The description was changed
avatar brianteeman brianteeman - test_item - 7 Apr 2016 - Tested successfully
avatar brianteeman
brianteeman - comment - 7 Apr 2016

I have tested this item :white_check_mark: successfully on 6408672


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

avatar MATsxm MATsxm - test_item - 8 Apr 2016 - Tested successfully
avatar MATsxm
MATsxm - comment - 8 Apr 2016

I have tested this item :white_check_mark: successfully on 6408672

Thanks


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

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

RTC - leaving it to the maintainers to decide the milestone


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

avatar joomla-cms-bot joomla-cms-bot - change - 8 Apr 2016
Labels Added: ?
avatar wilsonge wilsonge - change - 8 Apr 2016
Milestone Added:
avatar wilsonge
wilsonge - comment - 9 Apr 2016

Merged into 3.6.x with 2b8f134 - thanks @dgt41

avatar wilsonge wilsonge - change - 9 Apr 2016
Status Ready to Commit Closed
Closed_Date 0000-00-00 00:00:00 2016-04-09 13:56:45
Closed_By wilsonge
avatar wilsonge wilsonge - close - 9 Apr 2016
avatar joomla-cms-bot joomla-cms-bot - close - 9 Apr 2016
avatar joomla-cms-bot joomla-cms-bot - change - 9 Apr 2016
Labels Removed: ?

Add a Comment

Login with GitHub to post a comment