403Webshell
Server IP : 43.130.17.34  /  Your IP : 216.73.217.6
Web Server : nginx/1.28.0
System : Linux VM-4-12-opencloudos 6.6.92-34.1.oc9.x86_64 #1 SMP PREEMPT_DYNAMIC Wed Jun 25 21:32:13 CST 2025 x86_64
User : www ( 1000)
PHP Version : 8.0.26
Disable Function : passthru,exec,system,putenv,chroot,chgrp,chown,shell_exec,popen,proc_open,pcntl_exec,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,imap_open,apache_setenv
MySQL : OFF  |  cURL : ON  |  WGET : OFF  |  Perl : OFF  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /www/wwwroot/yespkg.com/wp-content/plugins/admin-columns-pro.5.1.3/classes/Sorting/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /www/wwwroot/yespkg.com/wp-content/plugins/admin-columns-pro.5.1.3/classes/Sorting/Addon.php
<?php

namespace ACP\Sorting;

use AC;
use AC\Asset\Location;
use AC\ListScreenRepository\Storage;
use ACP\Sorting\Admin;
use ACP\Sorting\Controller;

/**
 * Sorting Addon class
 * @since 1.0
 */
class Addon implements AC\Registrable {

	/**
	 * @var Storage
	 */
	private $storage;

	/**
	 * @var Location\Absolute
	 */
	private $location;

	/**
	 * @var AC\Admin
	 */
	private $admin;

	public function __construct( Storage $storage, Location\Absolute $location, AC\Admin $admin ) {
		$this->storage = $storage;
		$this->location = $location;
		$this->admin = $admin;
	}

	public function register() {
		add_action( 'ac/table/list_screen', [ $this, 'init_table' ], 11 ); // After filtering
		add_action( 'ac/column/settings', [ $this, 'register_column_settings' ] );

		$services = [
			new Controller\ResetSorting(),
			new Controller\AjaxResetSorting( $this->storage ),
		];

		foreach ( $services as $service ) {
			if ( $service instanceof AC\Registrable ) {
				$service->register();
			}
		}

		$this->register_admin_elements();
	}

	private function register_admin_elements() {
		$this->admin->get_page( 'settings' )->add_section( new Admin\Section\ResetSorting() );

		/** @var AC\Admin\Section\General $general */
		$general = $this->admin->get_page( 'settings' )->get_section( 'general' );
		$general->add_option( new Admin\ShowAllResults() );
	}

	/**
	 * @param AC\ListScreen $list_screen
	 */
	public function init_table( AC\ListScreen $list_screen ) {
		$table = new Table\Screen( $list_screen, $this->location );
		$table->register();
	}

	/**
	 * Register field settings for sorting
	 *
	 * @param AC\Column $column
	 */
	public function register_column_settings( $column ) {
		// Custom columns
		if ( $column instanceof Sortable ) {
			$column->sorting()->register_settings();
		}

		// Native columns
		$native = new NativeSortables( $column->get_list_screen() );

		if ( $native->is_sortable( $column->get_type() ) ) {

			$setting = new Settings( $column );
			$setting->set_default( 'on' );

			$column->add_setting( $setting );
		}
	}

	/**
	 * Hide or show empty results
	 * @return boolean
	 * @since      4.0
	 * @deprecated 5.1
	 */
	public function show_all_results() {
		_deprecated_function( __METHOD__, '5.1', 'acp_sorting_show_all_results()' );

		return acp_sorting_show_all_results();
	}

}

Youez - 2016 - github.com/yon3zu
LinuXploit