PHP Class Inpsyde\MultilingualPress\Widget\Dashboard\UntranslatedPosts\TranslationCompletedSettingUpdater

Since: 3.0.0
Show file Open project: inpsyde/multilingual-press

Public Methods

Method Description
__construct ( Inpsyde\MultilingualPress\Widget\Dashboard\UntranslatedPosts\PostRepository $post_repository, Inpsyde\MultilingualPress\Common\Nonce\Nonce $nonce ) Constructor. Sets up the properties.
update_setting ( integer $post_id, WP_Post $post ) : boolean Updates the translation completed setting of the post with the given ID.

Method Details

__construct() public method

Constructor. Sets up the properties.
Since: 3.0.0
public __construct ( Inpsyde\MultilingualPress\Widget\Dashboard\UntranslatedPosts\PostRepository $post_repository, Inpsyde\MultilingualPress\Common\Nonce\Nonce $nonce )
$post_repository Inpsyde\MultilingualPress\Widget\Dashboard\UntranslatedPosts\PostRepository Untranslated posts repository object.
$nonce Inpsyde\MultilingualPress\Common\Nonce\Nonce Nonce object.

update_setting() public method

Updates the translation completed setting of the post with the given ID.
Since: 3.0.0
public update_setting ( integer $post_id, WP_Post $post ) : boolean
$post_id integer Post ID.
$post WP_Post Post object.
return boolean Whether or not the translation completed setting was updated successfully.