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
The check here is too simplistic, as Versioned can be applied in 2 ways - as the familiar publishing staged content variation (default), or as a simple history tracking variation (.versioned).
If one applies "history-only" variant, then there is no stage to track, and the default GridField extensions do not allow for this, showing "archived" as the state for all records e.g. in a ModelAdmin.
The highlighted check above should also include && $model->hasStages() in the evaluation.
The text was updated successfully, but these errors were encountered:
@NightJar Is this after you apply the extension to a pre-existing model? I have models using Versioned::class . '.versioned' and can’t reproduce this, but I do remember when I first applied versioning I had to go through and re-save them all. From memory if Version=0 in the “live” table, the archive flag shows
silverstripe-versioned/src/VersionedGridFieldState/VersionedGridFieldState.php
Line 84 in e9a7a6d
The check here is too simplistic, as Versioned can be applied in 2 ways - as the familiar publishing staged content variation (default), or as a simple history tracking variation (
.versioned
).If one applies "history-only" variant, then there is no stage to track, and the default GridField extensions do not allow for this, showing "archived" as the state for all records e.g. in a ModelAdmin.
The highlighted check above should also include
&& $model->hasStages()
in the evaluation.The text was updated successfully, but these errors were encountered: