This forum has moved to a new location and is in read-only mode. Please visit talk.octobercms.com to access the new location.

gergo85
gergo85

I added the repeater field to my form and I got the following error message, when I tried to save the form:

"Unexpected type of array, should attribute "fieldname" be jsonable" on line 1064 of ../vendor/october/rain/src/Database/Model.php

What is wrong? Are there any special options for repeater field?

Scott
Scott

Just do as the error message says and set your model attribute to jsonable http://octobercms.com/docs/database/model#attribute-modifiers


class Whatever extends Model
{
    protected $jsonable = [
        'repeater',
    ];
}
gergo85
gergo85

Thank you very much!

antonreshetov
antonreshetov

Hi, how to add in repeater unique images? I have created a repeater, where there is two fields (controls), text and file upload (image). Text field is working fine, displays a unique record for loop, but the image is always the same old

Last updated

gergo85
gergo85

What is your code?

Gbaumeister
Gbaumeister

Not a fix for the missing(?) File-Upload support, but a workaround. Use the "Media-Finder" Form-Field instead...

1-6 of 6

You cannot edit posts or make replies: the forum has moved to talk.octobercms.com.