You are here

function theme_workflow_history_table_row in Workflow 7

Same name and namespace in other branches
  1. 5.2 workflow.module \theme_workflow_history_table_row()
  2. 6.2 workflow.pages.inc \theme_workflow_history_table_row()
  3. 6 workflow.pages.inc \theme_workflow_history_table_row()
  4. 7.2 workflow.pages.inc \theme_workflow_history_table_row()
1 theme call to theme_workflow_history_table_row()
workflow_tab_page in ./workflow.pages.inc
Menu callback. Display workflow summary of a node.

File

./workflow.pages.inc, line 143
Provide user interface for changing workflow state.

Code

function theme_workflow_history_table_row($variables) {
  $row = array();
  $old_state_name = $variables['old_state_name'];
  $state_name = $variables['state_name'];
  $transition = $variables['transition'];
  $account = user_load($transition->uid);
  $row = array(
    'data' => array(
      array(
        'data' => format_date($transition->stamp),
        'class' => array(
          'timestamp',
        ),
      ),
      array(
        'data' => $old_state_name,
        'class' => array(
          'previous-state-name',
        ),
      ),
      array(
        'data' => $state_name,
        'class' => array(
          'state-name',
        ),
      ),
      array(
        'data' => theme('username', array(
          'account' => $account,
        )),
        'class' => array(
          'user-name',
        ),
      ),
      array(
        'data' => filter_xss($transition->comment),
        'class' => array(
          'log-comment',
        ),
      ),
    ),
    'class' => array(
      'workflow_history_row',
    ),
  );
  if (!empty($variables['extra'])) {
    $row['data'][] = $variables['extra'];
  }
  return $row;
}