steirico / kirby-plugin-custom-add-fields

Custom fields for Kirby's add dialog.
MIT License
36 stars 4 forks source link

Default Values not loaded #55

Open hariom147 opened 2 years ago

hariom147 commented 2 years ago

First of all: Thanks for this great plugin and for updating it to Kirby 3.6! I noticed that default values are not loaded into the fields, when opening the page add dialog. I have the following code in blueprints, but neither is the date set to now (current date) nor is the toggle field set to true (on).

addFields:
  date:
    label: Datum
    type: date
    default: now
    width: 2/3
    required: true
    help: "{{page.date.toDate('l')}}"
  templatetoggle:
    label: ohne Vorlage
    type: toggle
    width: 1/3
    default: true
steirico commented 2 years ago

@hariom147 Thank you for the kind words.

The core of the problem seems to be related to kirby. Therefore, I filed this issue.

hariom147 commented 2 years ago

Thanks finding the cause and letting the Kirby team know.