You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Oct 6, 2022. It is now read-only.
I tried this again, to make sure this is not due to another plugin or my complicated blueprints, but I can recreate it, even with a plainkit setup. So I'm pretty sure this is actually a bug. How to reproduce:
Set up new plainkit project
Add a new structure field to blueprint, e.g. default.yml
title: Default Pagepreset: pagefields:
text:
label: Texttype: textareasize: largemydata:
label: Addressestype: structuretranslate: falsefields:
firstname:
label: First Nametype: textlastname:
label: Last Nametype: text
Add new entry to structure via the panel, so content file looks something like this:
Title: Test
----
Text: asd
----
Mydata:
-
firstname: Michael
lastname: Meyers
Install the plugin
Add to config.php
'bnomei.autoid.generator' => function () {
return (new \Bnomei\IncrementingGenerator(0))->generate();
},
Add autoid field to blueprint:
title: Default Page
preset: page
fields:
text:
label: Text
type: textarea
size: large
mydata:
label: Addresses
type: structure
translate: false
fields:
autoid:
type: hidden
translate: false
firstname:
label: First Name
type: text
lastname:
label: Last Name
type: text
Add new item to structure, save page
Autoid in content file starts with "2"
Title: Test
----
Text: asd
----
Mydata:
-
autoid: "2"
firstname: Michael
lastname: Meyers
-
autoid: "3"
firstname: Peter
lastname: Mueller
I used the Autoid on otherpages with the regular generator but on the homepage I use the increment generator and it starts by 14. I have no clue if the generator switch is a problem.
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
This is a minor bug, but it's annoying because the AutoIDs don't match the default row enumerations in the Kirby panel for structure fields.
To reproduce:
IncrementingGenerator
type: autoid
to an existing structure fieldThe text was updated successfully, but these errors were encountered: