How are they implemented in the database?
See the Database references table below. When you approve a Flagged Revision, a record is appended in tiki_objects_attributes, with itemId=tiki_history.historyId, type="wiki history", attribute="tiki.history.moderation", and value="OK". Then follow table.fields tiki_objects_attributes. itemId => tiki_history.historyId => tiki_history.pageName and tiki_history.version, which are two fields which match those in tabe tiki_pages.
There is no way to list all current pending Flagged Revisions.
A simple way to implement that might be to modify tiki-listpages.php by adding another Filter, very similar and following the tiki-listpages.php and tikilib.php code paths of "exact_match", selectable by a checkbox, labeled something like "Flagged Revisions pending approval". See tikilib.php function list_pages(). Need to define $mid = "where" clause, and "elseif ($type == 'flaggedrev_pending')".
Database references
Table
Relevant Fields
tiki_pages
page_id(=14) pageName(=Procedures) version(=2) data(=latest content, may or may not yet be approved)
When you save an edit to a wiki page, a new record is appended to tiki_history database table, with an incremented version number. The new current wiki content is stuffed in the data blob field (easily readable in a text editor). tiki-pagehistory.php?page=PageName will list each saved edit separately, but those that have been approved contain the text "(approved)" in the "Information" column; so where is that "(approved)" stored or calculated?
So, after all this review, I think we can implement a listing of wiki pages pending flagged-revision approval by adding, on tiki-listpages.php, to the Type: dropdown, which currently has only an option for "Pages not in structure", a new option called "Pages Pending Approval".
Reference Notes, Ignore
TPL files
tiki-flaggedrev_approval_header.tpl
{if $prefs.flaggedrev_approval eq 'y' and $revision_approval}
{if ($revision_approved or $revision_displayed) and $revision_approved neq $lastVersion}
{if $lastVersion eq $revision_displayed}
if 'approve'" class="wiki wikinew text-danger tips isset">$_REQUEST'approve' {
$targetFlag = 'OK';
$targetVersion = (int) $_REQUEST'approve';
$targetFlag is what is pushed into the "value" field in database table tiki_object_attributes.
page_ref_id is a wiki Structure page reference. Interestingly, tiki-editpage.php?page=PageName&page_ref_id=5 has both a "page=" and a "page_ref_id=".
Is it possible to create a search like in tiki-search_replace.php, $results = $wikilib->get_pages_contains() that instead lists pages with pending approvals?
By selecting the appropriate checkboxes here , tiki-listpages.php can list "Last ver." and "Vers.", which are usually the same, but sometimes different, but, at the moment don't make sense to my test page pending Flagged Revisions, dangit. Also, at the bottom, it has a "Perform action with checked:" dropdown that could include an option to approve the pending Flagged Revisions, someday.
Tiki7 revamp
LPH is revamping this feature in Tiki7
Needs to handle i18n
workflow
0- Live
1- Draft (one language is edited)
2- Ready for content approval
3- Content it approved, ready for translation
4- Translation is done, both languages ready to go live
0- Live
Notes for Tiki6
"There is a staging page (not yet approved) for this page." -> A link should be added for people with perms
The following is a list of keywords that should serve as hubs for navigation within the Tiki development and should correspond to documentation keywords.
Each feature in Tiki has a wiki page which regroups all the bugs, requests for enhancements, etc. It is somewhat a form of wiki-based project management. You can also express your interest in a feature by adding it to your profile. You can also try out the Dynamic filter.