Description
Use this filter to add/remove column from Inbox page.
Usage
add_filter( 'owf_manage_inbox_column_headers', 'modify_inbox_column_headers', 10, 1 ); add_filter( 'owf_manage_inbox_column_content', 'modify_inbox_column_content', 10, 2 );
Parameters
- $inbox_column_headers – an array of inbox table column header names.
- $inbox_item – inbox task item.
Example
add_filter( 'owf_manage_inbox_column_headers', 'modify_inbox_column_headers', 10, 1 ); add_filter( 'owf_manage_inbox_column_content', 'modify_inbox_column_content', 10, 2 ); function modify_inbox_column_headers( $inbox_column_headers ) { // Remove category column unset($inbox_column_headers['category']); // Add last modified date $inbox_column_headers['last_modified_date'] = '<th>' . __( 'Last Modified Date', 'oasisworkflow' ) . '</th>'; return $inbox_column_headers; } function modify_inbox_column_content( $inbox_column_headers, $inbox_item ) { if ( array_key_exists( 'last_modified_date', $inbox_column_headers ) ) { $post = get_post( $inbox_item->post_id ); echo "<td data-colname='LastModifiedDate' class='column-last-modified-date'>{$post->post_date}</td>"; } }
Source Code
The filter is located in oasis-workflow-pro/includes/class-ow-inbox-service.php
Didn't find what you are looking for? Submit a Query
Filter Users In The StepHide Attributes By User Roles
Filter Users In The StepHide Attributes By User Roles