We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 17249 ☆ A M B ☆
    • 165 Posts
    Hi Bruno;

    This is a follow-up from a previous work.
    I made progress on it and the fields are being injected dynamically to the form already and working good.
    The process is somehow similar to what you do with MIGX->generateTvTab();
    InputOptionValues are parsed dynamically for dropdowns, and TV types are being rendered correctly

    Now i need to bring the actual values to the field inputs and create a custom routine to save them when fields are updated by the editors.
    I tried with the Joins option in the config but as soon as i add a relation one-to-many to the array it stops working.

    Any advice on where to do this custom process and how to make the values appears in the generated fields?

    This question has been answered by Bruno17. See the first response.

    [ed. note: lithiumlab last edited this post 13 years, 3 months ago.]
    • discuss.answer
      • 4172
      • 5,888 Posts
      you can set all custom-values in a custom fields.php - processor.
        -------------------------------

        you can buy me a beer, if you like MIGX

        http://webcmsolutions.de/migx.html

        Thanks!
        • 17249 ☆ A M B ☆
        • 165 Posts
        Thanks Bruno;
        It was pretty easy:

        //Fill property values input fields
        $cp = $object->getMany('ContentProperties');
        foreach ($cp as $item) {
                $record['ContentProperties.p' . $item->get('property_id')] = $item->get('property_value');
        }
        }


        Properties values are loading in the correct place.

        Now i need some custom routine to save the results in update.php i guess.
        I'll figure it out. Thanks a lot for your help. [ed. note: lithiumlab last edited this post 13 years, 3 months ago.]