AllDayEvent.php
977 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
<?php
namespace ACA\EC\Column\Event;
use ACA\EC\Column\Meta;
use ACA\EC\Editing;
use ACA\EC\Export;
use ACA\EC\Filtering;
use ACP;
class AllDayEvent extends Meta
implements ACP\Export\Exportable, ACP\Search\Searchable {
public function __construct() {
$this->set_type( 'column-ec-event_alldayevent' );
$this->set_label( __( 'All Day Event', 'the-events-calendar' ) );
parent::__construct();
}
public function get_meta_key() {
return '_EventAllDay';
}
public function get_value( $id ) {
return ac_helper()->icon->yes_or_no( '1' === $this->get_raw_value( $id ) );
}
public function editing() {
return new Editing\Service\Event\AllDayEvent();
}
public function filtering() {
return new Filtering\Event\AllDayEvent( $this );
}
public function export() {
return new Export\Model\Event\AllDayEvent( $this );
}
public function search() {
return new ACP\Search\Comparison\Meta\Checkmark( $this->get_meta_key(), $this->get_meta_type() );
}
}