WC_Admin_Dashboard_Setup::render()
Render meta box output.
Метод класса: WC_Admin_Dashboard_Setup{}
Хуков нет.
Возвращает
null
. Ничего (null).
Использование
$WC_Admin_Dashboard_Setup = new WC_Admin_Dashboard_Setup(); $WC_Admin_Dashboard_Setup->render();
Код WC_Admin_Dashboard_Setup::render() WC Admin Dashboard Setup::render WC 9.2.3
public function render() { $version = Constants::get_constant( 'WC_VERSION' ); wp_enqueue_style( 'wc-dashboard-setup', WC()->plugin_url() . '/assets/css/dashboard-setup.css', array(), $version ); $task = $this->get_next_task(); if ( ! $task ) { return; } $button_link = $this->get_button_link( $task ); $completed_tasks_count = $this->get_completed_tasks_count(); $step_number = $this->get_completed_tasks_count() + 1; $tasks_count = count( $this->get_tasks() ); // Given 'r' (circle element's r attr), dashoffset = ((100-$desired_percentage)/100) * PI * (r*2). $progress_percentage = ( $completed_tasks_count / $tasks_count ) * 100; $circle_r = 6.5; $circle_dashoffset = ( ( 100 - $progress_percentage ) / 100 ) * ( pi() * ( $circle_r * 2 ) ); include __DIR__ . '/views/html-admin-dashboard-setup.php'; }