1 | <?php |
||
10 | class Archive extends Settings |
||
11 | { |
||
12 | /** |
||
13 | * @var string |
||
14 | */ |
||
15 | CONST ID = 'archives'; |
||
16 | |||
17 | public static $current; |
||
18 | |||
19 | public $hooks = []; |
||
20 | |||
21 | /** |
||
22 | * {@inheritdoc} |
||
23 | */ |
||
24 | public function init() |
||
37 | |||
38 | /** |
||
39 | * @return string |
||
40 | * @filter pollux/{static::ID}/before/instructions |
||
41 | */ |
||
42 | public function filterBeforeInstructions() |
||
50 | |||
51 | /** |
||
52 | * @param string $instruction |
||
53 | * @return string |
||
54 | * @action pollux/{static::ID}/instruction |
||
55 | */ |
||
56 | public function filterInstruction( $instruction, array $field, array $metabox ) |
||
60 | |||
61 | /** |
||
62 | * @return array |
||
63 | * @action pollux/{static::ID}/metabox/submit |
||
64 | */ |
||
65 | public function filterSubmitMetaBox( array $args ) |
||
70 | |||
71 | /** |
||
72 | * @todo: Use gatekeeper to check capability, wp_die(-1) on fail; |
||
|
|||
73 | * @return string|null |
||
74 | * @action wp_ajax_pollux/archives/featured/html |
||
75 | */ |
||
76 | public function getFeaturedImageHtml() |
||
84 | |||
85 | /** |
||
86 | * @param string $key |
||
87 | * @param mixed $fallback |
||
88 | * @param string $group |
||
89 | * @return string|array |
||
90 | */ |
||
91 | public function getMetaValue( $key, $fallback = '', $group = '' ) |
||
95 | |||
96 | /** |
||
97 | * @return void |
||
98 | * @action current_screen |
||
99 | */ |
||
100 | public function register() |
||
108 | |||
109 | /** |
||
110 | * @return void |
||
111 | * @action pollux/archives/init |
||
112 | */ |
||
113 | public function registerFeaturedImageMetaBox() |
||
118 | |||
119 | /** |
||
120 | * @return void |
||
121 | * @action admin_menu |
||
122 | */ |
||
123 | public function registerPage() |
||
137 | |||
138 | /** |
||
139 | * @return void |
||
140 | * @action pollux/archives/editor |
||
141 | */ |
||
142 | public function renderEditor( $content, $type ) |
||
157 | |||
158 | /** |
||
159 | * @return void |
||
160 | * @callback add_meta_box |
||
161 | */ |
||
162 | public function renderFeaturedImageMetaBox( $imageId = null ) |
||
183 | |||
184 | /** |
||
185 | * @return void |
||
186 | * @callback add_submenu_page |
||
187 | */ |
||
188 | public function renderPage() |
||
202 | |||
203 | /** |
||
204 | * @return array |
||
205 | */ |
||
206 | protected function getDefaults() |
||
210 | |||
211 | /** |
||
212 | * @return string |
||
213 | */ |
||
214 | protected function getPostType() |
||
222 | |||
223 | /** |
||
224 | * @return array |
||
225 | */ |
||
226 | protected function getPostTypesWithArchive() |
||
233 | |||
234 | /** |
||
235 | * @return array |
||
236 | */ |
||
237 | protected function getSettings() |
||
241 | } |
||
242 |
This check looks
TODO
comments that have been left in the code.``TODO``s show that something is left unfinished and should be attended to.