Format name differently
[misc/kostenrechnung] / masks / overview_mitarbeiter.php
1 <?php
2
3 include_once($_SESSION['sys']['basedir'].'/lib/overview_utils.php');
4
5 if (empty($_SESSION['overview_mitarbeiter.year'])) $_SESSION['overview_mitarbeiter.year'] = 0;
6
7 $mask = array(
8               'table' => 'einsatz',
9               'title' => 'Gesamtstundenaufwand pro Mitarbeiter',
10               'join' => array('personal ON einsatz.personal = personal.id',
11                               'arbeitsarten ON einsatz.arbeiten = arbeitsarten.id',
12                               ),
13               'where' => "arbeitsarten.arbeitsart <> 'Urlaub' AND arbeitsarten.arbeitsart <> 'Krank' AND arbeitsarten.arbeitsart <> 'Sonstige Fehltage'"
14                        . " AND date_part('year', datum) = " . $_SESSION['overview_mitarbeiter.year'],
15               'select' => array(
16                                 'title' => 'Auswahl',
17                                 'options' => discover_years(),
18                                 'default' => 'Jahr w√§hlen',
19                                 'selected' => $_SESSION['overview_mitarbeiter.year'],
20                                 'onchange' => "setvar(this,'year',select_year_calback,select_year_status)",
21                                 ),
22               'variables' => array(
23                                    'year' => array(),
24                                    ),
25               'list' => array(
26                               'id' => array(
27                                             'name' => 'ID',
28                                             'visible' => false,
29                                             'sql' => 'einsatz.id',
30                                             ),
31                               'datum' => array(
32                                             'name' => 'Datum',
33                                             'type' => 'date',
34                                             'width' => 70,
35                                             ),
36                               'personal' => array(
37                                             'name' => 'Mitarbeiter',
38                                             'sql' => "personal.name || ', ' || personal.vorname",
39                                             'width' => 150,
40                                             'specs' => "filterUI: 's'",
41                                             ),
42                               'arbeitsarten' => array(
43                                             'name' => 'Arbeiten',
44                                             'sql' => "arbeitsarten.arbeitsart",
45                                             'width' => 150,
46                                             'specs' => "filterUI: 's'",
47                                             ),
48                               'stunden' => array(
49                                             'name' => 'Stunden',
50                                             'type' => 'number',
51                                             'specs' => "decPlaces: 2, ClassName: 'alignright', suffix: '&nbsp;', canSort: false",
52                                             'width' => 60,
53                                             ),
54                               ),
55               );
56
57 ?>