Completed
Push — develop ( f6b321...a05a5f )
by Abdelrahman
14:27
created

GeoipsDataTable::getBuilderParameters()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 14
Code Lines 10

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
dl 0
loc 14
rs 9.4285
c 1
b 0
f 0
cc 1
eloc 10
nc 1
nop 0
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Cortex\Statistics\DataTables\Adminarea;
6
7
use Rinvex\Statistics\Models\Geoip;
8
use Cortex\Foundation\DataTables\AbstractDataTable;
9
10
class GeoipsDataTable extends AbstractDataTable
11
{
12
    /**
13
     * {@inheritdoc}
14
     */
15
    protected $model = Geoip::class;
16
17
    /**
18
     * {@inheritdoc}
19
     */
20
    protected $createButton = false;
21
22
    /**
23
     * Get columns.
24
     *
25
     * @return array
26
     */
27
    protected function getColumns(): array
28
    {
29
        return [
30
            'client_ip' => ['title' => trans('cortex/statistics::common.client_ip'), 'responsivePriority' => 0],
31
            'latitude' => ['title' => trans('cortex/statistics::common.latitude')],
32
            'longitude' => ['title' => trans('cortex/statistics::common.longitude')],
33
            'country_code' => ['title' => trans('cortex/statistics::common.country_code')],
34
            'client_ips' => ['title' => trans('cortex/statistics::common.client_ips'), 'visible' => false],
35
            'is_from_trusted_proxy' => ['title' => trans('cortex/statistics::common.is_from_trusted_proxy')],
36
            'division_code' => ['title' => trans('cortex/statistics::common.division_code')],
37
            'postal_code' => ['title' => trans('cortex/statistics::common.postal_code')],
38
            'timezone' => ['title' => trans('cortex/statistics::common.timezone')],
39
            'city' => ['title' => trans('cortex/statistics::common.city')],
40
            'count' => ['title' => trans('cortex/statistics::common.count')],
41
        ];
42
    }
43
}
44