If a node has a Rules-based (automatic) moderation-state change that is triggered by manual moderation-state change, the automated change appears below the manual change on the Moderate tab for that node. This is inconsistent with the standard ordering of events on the page; chronological dexcending. E.g.

Annotated screenshot showing the incorrectly ordered events on the moderate tab.

Both events get recorded into the workbench_moderation_node_history table with the same timestamp, REQUEST_TIME; see from line 1482 in workbench_moderation_moderate() in workbench_moderation.module. This is good practice and should not change.

The attached patch fixes the bug by adding an additional sort order to the query that gets the node's workbench_moderation_node_history table data to ORDER BY hid DESC.

CommentFileSizeAuthor
history-event-order.patch486 bytesBevan
Example.png69.69 KBBevan

Comments

dave reid’s picture

Status: Needs review » Reviewed & tested by the community

Makes complete sense to me.

dave reid’s picture

Status: Reviewed & tested by the community » Fixed
Bevan’s picture

Thanks for the quick turnaround! :)

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.