twill icon indicating copy to clipboard operation
twill copied to clipboard

checkbox field in setting section forms will make server error 500

Open moathOSA opened this issue 2 years ago • 0 comments

Description

using checkbox field in setting pages will lead to server error

Steps to reproduce

lets say you have section called types in setting page and you wan't to add checkbox field in the page.blade.php like this

  @formField('checkbox', [
      'name' => 'featured',
      'label' => 'Featured'
  ])

if you add the checkbox field and you checked the checkbox on the update you will ends up with the 500 error page

Expected result

checkbox should works fine !

Actual result

error 500 page

THE REASON FROM MY POINT OF VIEW

the checkbox value is sent like this in the setting page section featured[1660232363991]: true the key is an integer instead of string

i think it's should look like this featured: true //this is how it's look in the release form that i created to test the checkbox field

moathOSA avatar Aug 11 '22 15:08 moathOSA