Skip to content

updating previous content to HasDrafts #30

Answered by oddvalue
retosteffen asked this question in Q&A
Discussion options

You must be logged in to vote

Hi @retosteffen,

Thanks for the suggestion. It's a bit tricky to do since there's no way of knowing what the publisher should be automatically. Your best bet is to set the data manually in the database if you know what you want the values to be.
Regarding the uuid, you can fill them in for existing models like this:

Model::query()->whereNull('uuid')->each(function (Model $record): void {
    $record->generateUuid();
    $record->save();
});

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by oddvalue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants