21 lines
1007 B
C++
21 lines
1007 B
C++
// SPDX-License-Identifier: GPL-3.0-only
|
|
#pragma once
|
|
#include "modern/ui/news_catalog.hpp"
|
|
|
|
namespace bmh::modern_ui {
|
|
// Version2 keeps immutable facts, mutable read/folder flags and a durable
|
|
// ledger. Unknown historical owners are retained separately, never attributed
|
|
// to the person/team that happens to open an old checkpoint.
|
|
Json empty_news_journal();
|
|
bool valid_news_journal(const Json &);
|
|
bool migrate_news_journal(Json &);
|
|
Json bind_created_news(const Json &legacy_items, const Json &scope,
|
|
const Json &manager);
|
|
bool news_row_visible(const Json &row, const Json &scope);
|
|
Json news_row_text(const Json &row, const std::string &language = "de");
|
|
// The caller supplies an explicitly validated catalogue/event result, not a
|
|
// guessed engine fallback. Duplicate delivery is a completely write-free read.
|
|
Json publish_news_article(Json &journal, const NewsCatalog &,
|
|
const Json &article, const Json &owner = Json());
|
|
} // namespace bmh::modern_ui
|