? Failure

User tests: Successful: Unsuccessful:

avatar fastslack
fastslack
25 Feb 2018

Summary of Changes

This change add the possibility to save multiple values of FieldList as JSON.

Testing Instructions

Create using JForm a list with multiple value enabled like:

    <field multiple="true" name="options" type="list" label="COM_TEST_FORM_LBL_OPTIONS" description="COM_TEST_FORM_DESC_OPTIONS" hint="COM_TEST_FORM_LBL_OPTIONS">
      <option value="0">COM_TEST_PRODUCTS_OPTIONS_0</option>
      <option value="1">COM_TEST_PRODUCTS_OPTIONS_1</option>
      <option value="2">COM_TEST_PRODUCTS_OPTIONS_2</option>
    </field>

Then add into save() function in models:

    $data['options'] = json_encode($data['options']);

Expected result

You can save multiple values as JSON into database

avatar fastslack fastslack - open - 25 Feb 2018
avatar fastslack fastslack - change - 25 Feb 2018
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 25 Feb 2018
Category Libraries
avatar laoneo
laoneo - comment - 23 Mar 2022

Sorry that it took so long to respond. While this is a nice addition for Joomla, it should be added to version 4 as it is a new feature. Can you rebase it to the 4.2-dev branch? In the meantime I'm closing the pr, when ready please reopen so we can properly test it. Thanks for your contribution, making Joomla better.

avatar laoneo laoneo - close - 23 Mar 2022
avatar laoneo laoneo - change - 23 Mar 2022
Status Pending Closed
Closed_Date 0000-00-00 00:00:00 2022-03-23 09:52:52
Closed_By laoneo
Labels Added: ?
Removed: ?

Add a Comment

Login with GitHub to post a comment