Since the activation hook only will be called when activating the plugin, you will instead need to call register_post_type()
on some hook which is triggered every time you access the administration pages. You could use the init
hook for this:
add_action('init', array($this, 'register_custom_type'));
You also need to make the register_custom_type()
method public for this to work:
public function register_custom_type()
{
// call register_post_type()
}
Documentation
Note: Post type registrations should not be hooked before the ‘init’
action. Also, any taxonomy connections should be registered via the
$taxonomies argument to ensure consistency when hooks such as
‘parse_query’ or ‘pre_get_posts’ are used.