What you see in the edit post columns is controlled by manage_posts_columns
filter.
By playlist_id
i assume you are looking for the post_id
(since you mentioned playlists are simply custom post types). You can do so by using this code in your theme’s functions.php
file:
if ( !function_exists('add_playlist_id_to_column') && function_exists('add_theme_support') ) {
// Add our own column
function add_playlist_id_to_column($cols) {
$cols['playlist_id'] = __('PlayList ID','text-domain');
return $cols;
}
// Get the post's ID
function add_playlist_value($column_name, $post_id) {
// If there is a post_id set, output it. Otherwise, print NONE.
if ( $post_id ) {
echo $post_id;
} else {
echo __('None','text-domain');
}
}
// Hook to `manage_posts_columns` to run our function
add_filter( 'manage_posts_columns', 'add_playlist_id_to_column' );
add_action( 'manage_posts_custom_column', 'add_playlist_value', 10, 2 );
}