Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 68dbf4a4

Von Sven Schöling vor fast 10 Jahren hinzugefügt

  • ID 68dbf4a4cb26b9554a23f076438109d7fc2d861c
  • Vorgänger 0d710c06
  • Nachfolger 4ee1cfb0

Layout Aufräumaktion:

- Admin und V3 Menü entflochten. Benutzen jetzt beide das neue CssMenu
als sub_layout
- Top-Klone aus V3 und Javascript herausoperiert und als sub_layout
eingebunden
- Neues Layout AdminLogin für die Loginmaske im Adminbereich (d'oh)
- Inputfelder im frame_header kleiner gemacht, Frickelfox ignoriert mal
wieder css Vorgaben und inheritet font-size nicht.
- Beschreibung in Placeholder verschoben. Ja das ist html5. Benutz halt
nicht IE6.
- javascript für Ansprechpartnersuche gefixt und ausgelagert.
- Login, Classic und V3 sind top level Layouts und brauchen nicht
sub_layoutbar sein. Macht den Code einfacher.

Unterschiede anzeigen:

SL/Controller/Admin.pm
15 15
use SL::Locale::String qw(t8);
16 16
use SL::System::InstallationLock;
17 17
use SL::User;
18
use SL::Layout::AdminLogin;
18 19

  
19 20
use Rose::Object::MakeMethods::Generic
20 21
(
......
585 586

  
586 587
sub login_form {
587 588
  my ($self, %params) = @_;
589
  $::request->layout(SL::Layout::AdminLogin->new);
588 590
  my $version         = $::form->read_version;
589
  $::request->layout->no_menu(1);
590 591
  $self->render('admin/adminlogin', title => t8('kivitendo v#1 administration', $version), %params, version => $version);
591 592
}
592 593

  
SL/Layout/Admin.pm
1 1
package SL::Layout::Admin;
2 2

  
3 3
use strict;
4
use parent qw(SL::Layout::V3);
4
use parent qw(SL::Layout::None);
5 5

  
6 6
use SL::Menu;
7

  
8
use Rose::Object::MakeMethods::Generic (
9
  scalar => [ qw(no_menu) ],
10
);
11

  
12

  
13
sub init_menu {
14
  Menu->new('menus/admin.ini');
7
use SL::Layout::None;
8
use SL::Layout::Top;
9
use SL::Layout::CssMenu;
10

  
11
sub init_sub_layouts {
12
  [
13
    SL::Layout::None->new,
14
    SL::Layout::CssMenu->new(menu => Menu->new('menus/admin.ini')),
15
  ]
15 16
}
16 17

  
17 18
sub start_content {
18 19
  "<div id='admin' class='admin'>\n";
19 20
}
20 21

  
21
sub render {
22
  my ($self) = @_;
23

  
24
  $self->presenter->render(
25
    'menu/menuv3',
26
    force_ul_width    => 1,
27
    skip_frame_header => 1,
28
    menu              => $self->no_menu ? '' : $self->print_menu,
29
  );
22
sub end_content {
23
  "</div>\n";
30 24
}
31 25

  
26

  
32 27
1;
SL/Layout/AdminLogin.pm
1
package SL::Layout::AdminLogin;
2

  
3
use strict;
4
use parent qw(SL::Layout::None);
5

  
6
sub start_content {
7
  "<div id='admin' class='admin'>\n";
8
}
9

  
10
sub end_content {
11
  "</div>\n";
12
}
13

  
14
1;
SL/Layout/CssMenu.pm
1
package SL::Layout::CssMenu;
2

  
3
use strict;
4
use parent qw(SL::Layout::Base);
5

  
6
use URI;
7

  
8
sub print_menu {
9
  my ($self, $parent, $depth) = @_;
10

  
11
  my $html;
12

  
13
  die if ($depth * 1 > 5);
14

  
15
  my @menuorder;
16
  my $menu = $self->menu;
17

  
18
  @menuorder = $menu->access_control(\%::myconfig, $parent);
19

  
20
  $parent .= "--" if ($parent);
21

  
22
  foreach my $item (@menuorder) {
23
    substr($item, 0, length($parent)) = "";
24
    next if (($item eq "") || ($item =~ /--/));
25

  
26
    my $menu_item = $menu->{"${parent}${item}"};
27
    my $menu_title = $::locale->text($item);
28
    my $menu_text = $menu_title;
29

  
30
    if ($menu_item->{"submenu"} || !defined($menu_item->{"module"}) && !defined($menu_item->{href})) {
31

  
32
      my $h = $self->print_menu("${parent}${item}", $depth * 1 + 1)."\n";
33
      if (!$parent) {
34
        $html .= qq|<ul><li><h2>${menu_text}</h2><ul>${h}</ul></li></ul>\n|;
35
      } else {
36
        $html .= qq|<li><div class="x">${menu_text}</div><ul>${h}</ul></li>\n|;
37
      }
38
    } else {
39
      if ($self->{sub_class} && $depth > 1) {
40
        $html .= qq|<li class='sub'>|;
41
      } else {
42
        $html .= qq|<li>|;
43
      }
44
      $html .= $self->menuitem_v3("${parent}$item", { "title" => $menu_title });
45
      $html .= qq|${menu_text}</a></li>\n|;
46
    }
47
  }
48

  
49
  return $html;
50
}
51

  
52
sub menuitem_v3 {
53
  $main::lxdebug->enter_sub();
54

  
55
  my ($self, $item, $other) = @_;
56
  my $menuitem = $self->menu->{$item};
57

  
58
  my $action = "section_menu";
59
  my $module;
60

  
61
  if ($menuitem->{module}) {
62
    $module = $menuitem->{module};
63
  }
64
  if ($menuitem->{action}) {
65
    $action = $menuitem->{action};
66
  }
67

  
68
  my $level  = $::form->escape($item);
69

  
70
  my @vars;
71
  my $target = $menuitem->{target} ? qq| target="| . $::form->escape($menuitem->{target}) . '"' : '';
72
  my $str    = qq|<a${target} href="|;
73

  
74
  if ($menuitem->{href}) {
75
    $main::lxdebug->leave_sub();
76
    return $str . $menuitem->{href} . '">';
77
  }
78

  
79
  $str .= qq|$module?action=| . $::form->escape($action);
80

  
81
  map { delete $menuitem->{$_} } qw(module action target href);
82

  
83
  # add other params
84
  foreach my $key (keys %{ $menuitem }) {
85
    $str .= "&amp;" . $::form->escape($key, 1) . "=";
86
    my ($value, $conf) = split(/=/, $menuitem->{$key}, 2);
87
    $value = $::myconfig{$value} . "/$conf" if ($conf);
88
    $str .= $::form->escape($value, 1);
89
  }
90

  
91
  $str .= '"';
92

  
93
  if ($other) {
94
    foreach my $key (keys(%{$other})) {
95
      $str .= qq| ${key}="| . $::form->quote($other->{$key}) . qq|"|;
96
    }
97
  }
98

  
99
  $str .= ">";
100

  
101
  $main::lxdebug->leave_sub();
102

  
103
  return $str;
104
}
105

  
106
sub use_stylesheet {
107
  qw(icons16.css frame_header/header.css),
108
}
109

  
110
sub pre_content {
111
  $_[0]->presenter->render('menu/menuv3',
112
    menu           => $_[0]->print_menu,
113
  );
114
}
115

  
116
1;
SL/Layout/Dispatcher.pm
3 3
use strict;
4 4

  
5 5
use SL::Layout::Admin;
6
use SL::Layout::AdminLogin;
6 7
use SL::Layout::Login;
7 8
use SL::Layout::Classic;
8 9
use SL::Layout::V3;
......
15 16
  return SL::Layout::V3->new         if $params{style} eq 'v3';
16 17
  return SL::Layout::Javascript->new if $params{style} eq 'neu';
17 18
  return SL::Layout::Admin->new      if $params{style} eq 'admin';
19
  return SL::Layout::AdminLogin->new if $params{style} eq 'admin_login';
18 20
  return SL::Layout::Login->new      if $params{style} eq 'login';
19 21
  return SL::Layout::None->new;
20 22
}
SL/Layout/Javascript.pm
7 7
use URI;
8 8

  
9 9
sub init_sub_layouts {
10
  [ SL::Layout::None->new ]
10
  [
11
    SL::Layout::None->new,
12
    SL::Layout::Top->new,
13
  ]
11 14
}
12 15

  
13 16
sub use_javascript {
14 17
  my $self = shift;
15 18
  qw(
16
    js/quicksearch_input.js
19
    js/dhtmlsuite/menu-for-applications.js
17 20
  ),
18 21
  $self->SUPER::use_javascript(@_);
19 22
}
20 23

  
21 24
sub pre_content {
25
  $_[0]->SUPER::pre_content .
22 26
  &display
23 27
}
24 28

  
......
43 47

  
44 48
sub display {
45 49
  my ($self) = @_;
46
  my $form     = $main::form;
47

  
48
  my $callback            = $form->unescape($form->{callback});
49
  $callback               = URI->new($callback)->rel($callback) if $callback;
50
  $callback               = "login.pl?action=company_logo"      if $callback =~ /^(\.\/)?$/;
51 50

  
52 51
  $self->presenter->render("menu/menunew",
53 52
    force_ul_width  => 1,
54
    date            => $self->clock_line,
55 53
    menu_items      => $self->acc_menu,
56
    callback        => $callback,
57 54
  );
58 55
}
59 56

  
60
sub clock_line {
61
  my $form     = $main::form;
62

  
63
  my ($Sekunden, $Minuten,   $Stunden,   $Monatstag, $Monat,
64
      $Jahr,     $Wochentag, $Jahrestag, $Sommerzeit)
65
    = localtime(time);
66
  $Monat     += 1;
67
  $Jahrestag += 1;
68
  $Monat     = $Monat < 10     ? $Monat     = "0" . $Monat     : $Monat;
69
  $Monatstag = $Monatstag < 10 ? $Monatstag = "0" . $Monatstag : $Monatstag;
70
  $Jahr += 1900;
71
  my @Wochentage = ("Sonntag",    "Montag",  "Dienstag", "Mittwoch",
72
                    "Donnerstag", "Freitag", "Samstag");
73
  my @Monatsnamen = ("",       "Januar",    "Februar", "M&auml;rz",
74
                     "April",  "Mai",       "Juni",    "Juli",
75
                     "August", "September", "Oktober", "November",
76
                     "Dezember");
77
  return
78
      $Wochentage[$Wochentag] . ", der "
79
    . $Monatstag . "."
80
    . $Monat . "."
81
    . $Jahr . " - ";
82
}
83

  
84 57
sub acc_menu {
85 58
  my ($self) = @_;
86 59

  
SL/Layout/Login.pm
1 1
package SL::Layout::Login;
2 2

  
3 3
use strict;
4
use parent qw(SL::Layout::Base);
5

  
6
sub new {
7
  my ($class, @slurp) = @_;
8

  
9
  my $self = $class->SUPER::new(@slurp);
10

  
11
  $self->add_sub_layouts([
12
    SL::Layout::None->new,
13
  ]);
14

  
15
  $self;
16
}
4
use parent qw(SL::Layout::None);
17 5

  
18 6
sub start_content {
19 7
  "<div id='login' class='login'>\n";
SL/Layout/MenuLeft.pm
13 13

  
14 14
sub javascripts_inline {
15 15
  my $self = shift;
16
  $self->SUPER::javascripts_inline;
17 16
  my $sections = [ section_menu($self->menu) ];
18 17
  $self->presenter->render('menu/menu',
19 18
    sections  => $sections,
SL/Layout/Top.pm
7 7
  my ($self) = @_;
8 8

  
9 9
  $self->presenter->render('menu/header',
10
                now        => DateTime->now_local,
11
                is_fastcgi => scalar($::dispatcher->interface_type =~ /fastcgi/i),
12
                is_links   => scalar($ENV{HTTP_USER_AGENT}         =~ /links/i));
10
    now        => DateTime->now_local,
11
    is_fastcgi => scalar($::dispatcher->interface_type =~ /fastcgi/i),
12
    is_links   => scalar($ENV{HTTP_USER_AGENT}         =~ /links/i),
13
  );
13 14
}
14 15

  
15 16
sub stylesheets {
16 17
 'frame_header/header.css';
17 18
}
18 19

  
20
sub javascripts {
21
  ('js/quicksearch_input.js') x!! $::auth->assert('customer_vendor_edit', 1),
22
  ('js/glquicksearch.js')     x!! $::auth->assert('general_ledger', 1)
23
}
24

  
19 25
1;
20 26

  
21 27
__END__
SL/Layout/V3.pm
3 3
use strict;
4 4
use parent qw(SL::Layout::Base);
5 5

  
6
use URI;
7

  
8
sub clock_line {
9
  my ($Sekunden, $Minuten,   $Stunden,   $Monatstag, $Monat,
10
      $Jahr,     $Wochentag, $Jahrestag, $Sommerzeit)
11
    = localtime(time);
12
  $Monat     += 1;
13
  $Jahrestag += 1;
14
  $Monat     = $Monat < 10     ? $Monat     = "0" . $Monat     : $Monat;
15
  $Monatstag = $Monatstag < 10 ? $Monatstag = "0" . $Monatstag : $Monatstag;
16
  $Jahr += 1900;
17
  my @Wochentage = ("Sonntag",    "Montag",  "Dienstag", "Mittwoch",
18
                    "Donnerstag", "Freitag", "Samstag");
19
  my @Monatsnamen = ("",       "Januar",    "Februar", "M&auml;rz",
20
                     "April",  "Mai",       "Juni",    "Juli",
21
                     "August", "September", "Oktober", "November",
22
                     "Dezember");
23
  return
24
      $Wochentage[$Wochentag] . ", der "
25
    . $Monatstag . "."
26
    . $Monat . "."
27
    . $Jahr . " - ";
28
}
29

  
30
sub print_menu {
31
  my ($self, $parent, $depth) = @_;
32

  
33
  my $html;
34

  
35
  die if ($depth * 1 > 5);
36

  
37
  my @menuorder;
38
  my $menu = $self->menu;
39

  
40
  @menuorder = $menu->access_control(\%::myconfig, $parent);
41

  
42
  $parent .= "--" if ($parent);
43

  
44
  foreach my $item (@menuorder) {
45
    substr($item, 0, length($parent)) = "";
46
    next if (($item eq "") || ($item =~ /--/));
47

  
48
    my $menu_item = $menu->{"${parent}${item}"};
49
    my $menu_title = $::locale->text($item);
50
    my $menu_text = $menu_title;
51

  
52
    if ($menu_item->{"submenu"} || !defined($menu_item->{"module"}) && !defined($menu_item->{href})) {
53

  
54
      my $h = $self->print_menu("${parent}${item}", $depth * 1 + 1)."\n";
55
      if (!$parent) {
56
        $html .= qq|<ul><li><h2>${menu_text}</h2><ul>${h}</ul></li></ul>\n|;
57
      } else {
58
        $html .= qq|<li><div class="x">${menu_text}</div><ul>${h}</ul></li>\n|;
59
      }
60
    } else {
61
      if ($self->{sub_class} && $depth > 1) {
62
        $html .= qq|<li class='sub'>|;
63
      } else {
64
        $html .= qq|<li>|;
65
      }
66
      $html .= $self->menuitem_v3("${parent}$item", { "title" => $menu_title });
67
      $html .= qq|${menu_text}</a></li>\n|;
68
    }
69
  }
70

  
71
  return $html;
72
}
73

  
74
sub menuitem_v3 {
75
  $main::lxdebug->enter_sub();
76

  
77
  my ($self, $item, $other) = @_;
78
  my $menuitem = $self->menu->{$item};
79

  
80
  my $action = "section_menu";
81
  my $module;
82

  
83
  if ($menuitem->{module}) {
84
    $module = $menuitem->{module};
85
  }
86
  if ($menuitem->{action}) {
87
    $action = $menuitem->{action};
88
  }
89

  
90
  my $level  = $::form->escape($item);
91

  
92
  my @vars;
93
  my $target = $menuitem->{target} ? qq| target="| . $::form->escape($menuitem->{target}) . '"' : '';
94
  my $str    = qq|<a${target} href="|;
95

  
96
  if ($menuitem->{href}) {
97
    $main::lxdebug->leave_sub();
98
    return $str . $menuitem->{href} . '">';
99
  }
100

  
101
  $str .= qq|$module?action=| . $::form->escape($action);
102

  
103
  map { delete $menuitem->{$_} } qw(module action target href);
104

  
105
  # add other params
106
  foreach my $key (keys %{ $menuitem }) {
107
    $str .= "&amp;" . $::form->escape($key, 1) . "=";
108
    my ($value, $conf) = split(/=/, $menuitem->{$key}, 2);
109
    $value = $::myconfig{$value} . "/$conf" if ($conf);
110
    $str .= $::form->escape($value, 1);
111
  }
112

  
113
  $str .= '"';
114

  
115
  if ($other) {
116
    foreach my $key (keys(%{$other})) {
117
      $str .= qq| ${key}="| . $::form->quote($other->{$key}) . qq|"|;
118
    }
119
  }
120

  
121
  $str .= ">";
122

  
123
  $main::lxdebug->leave_sub();
124

  
125
  return $str;
126
}
6
use SL::Layout::None;
7
use SL::Layout::Top;
8
use SL::Layout::CssMenu;
127 9

  
128 10
sub init_sub_layouts {
129
  [ SL::Layout::None->new ]
130
}
131

  
132
sub use_stylesheet {
133
  my $self = shift;
134
  qw(
135
   icons16.css frame_header/header.css
136
  ),
137
  $self->SUPER::use_stylesheet(@_);
138
}
139

  
140
sub use_javascript {
141
  my $self = shift;
142
  qw(
143
    js/quicksearch_input.js
144
  ),
145
  $self->SUPER::use_javascript(@_);
146
}
147

  
148
sub pre_content {
149
  $_[0]->render;
11
  [
12
    SL::Layout::None->new,
13
    SL::Layout::Top->new,
14
    SL::Layout::CssMenu->new,
15
  ]
150 16
}
151 17

  
152 18
sub start_content {
......
157 23
  "</div>\n";
158 24
}
159 25

  
160
sub render {
161
  my ($self) = @_;
162

  
163
  my $callback            = $::form->unescape($::form->{callback});
164
  $callback               = URI->new($callback)->rel($callback) if $callback;
165
  $callback               = "login.pl?action=company_logo"      if $callback =~ /^(\.\/)?$/;
166

  
167
  $self->presenter->render('menu/menuv3',
168
    force_ul_width => 1,
169
    date           => $self->clock_line,
170
    menu           => $self->print_menu,
171
    callback       => $callback,
172
  );
173
}
174

  
175 26
1;
css/common.css
50 50
.row2-cvars-table tr { vertical-align: top }
51 51
.row2-cvars-table th { text-align: right; padding-left: 15px; padding-right: 0 }
52 52
.row2-cvars-table td, .row2-cvars-table th { padding-top: 10px }
53

  
54
input.grow_on_focus {
55
  width: 20px;
56
  transition:         width 0.1s;
57
  -moz-transition:    width 0.1s;
58
  -webkit-transition: width 0.1s;
59
  -o-transition:      width 0.1s;
60
}
61
input.grow_on_focus:focus { width: 150px }
62

  
css/kivitendo/frame_header/header.css
33 33
  vertical-align: middle;
34 34
}
35 35

  
36
#frame-header .frame-header-right {
37
  margin-top: 3px;
38
}
39

  
36 40
#frame-header #ajax-spinner {
37 41
  margin-top: 2px;
38 42
  margin-right: 10px;
39 43
  display: none;
40 44
}
45

  
46
#frame-header input {
47
  font-size: 12px;
48
}
css/lx-office-erp/frame_header/header.css
38 38
  vertical-align: middle;
39 39
}
40 40

  
41
#frame-header .frame-header-right {
42
  margin-top: 3px;
43
}
44

  
41 45
#frame-header #ajax-spinner {
42 46
  margin-top: 2px;
43 47
  margin-right: 10px;
......
47 51
  min-width: 16px;
48 52
  min-height: 16px;
49 53
}
54

  
55
#frame-header input {
56
  font-size: 12px;
57
}
js/quicksearch_input.js
1
function on_keydown_quicksearch(element, event) {
1
function on_keydown_quicksearch(event) {
2 2
  var key;
3
  var element = $(this);
3 4

  
4 5
  if (window.event)
5 6
    key = window.event.keyCode;   // IE
......
16 17

  
17 18
  var url = "ct.pl?action=list_contacts&INPUT_ENCODING=utf-8&filter.status=active&search_term=" + encodeURIComponent(value);
18 19

  
19
  search_term.val('');
20 20
  window.location.href = url;
21 21

  
22 22
  return false;
23 23
}
24
$(function(){ $('#frame_header_contact_search').keydown(on_keydown_quicksearch) });
templates/webpages/menu/header.html
1 1
[%- USE T8 %][%- USE LxERP -%]
2
[%- UNLESS skip_frame_header %]
2 3
<div id="frame-header">
3
[% UNLESS is_links %]
4
[%- UNLESS is_links %]
4 5
 <span class="frame-header-element frame-header-left">
5
    [<a href="JavaScript:Switch_Menu();" title="[% 'Switch Menu on / off' | $T8 %]">[% 'Menu' | $T8 %]</a>]
6 6
    [<a href="controller.pl?action=LoginScreen/user_login" target="_blank" title="[% 'Open a further kivitendo window or tab' | $T8 %]">[% 'New window/tab' | $T8 %]</a>]
7 7
    [<a href="JavaScript:top.print();" title="[% 'Hardcopy' | $T8 %]">[% 'Print' | $T8 %]</a>]
8
    [<a href="Javascript:top.history.back();" title="[% 'Go one step back' | $T8 %]">[% 'Back' | $T8 %]</a>]
9
    [<a href="Javascript:top.history.forward();" title="[% 'Go one step forward' | $T8 %]">[% 'Fwd' | $T8 %]</a>]
10 8
[%- IF AUTH.assert('general_ledger', 1) %]
11
    [[% 'GL search' | $T8 %]: <input id="glquicksearch" name="glquicksearch" type="text" class="ui-widget" size="20" maxlength="20">]
9
    [ <input name="frame_header_contact_search" id="frame_header_contact_search" placeholder="[% 'Search contacts' | $T8 %]" size="14">]
10
[%- END %]
11
[%- IF AUTH.assert('general_ledger', 1) %]
12
    [<input id="glquicksearch" name="glquicksearch" type="text" class="ui-widget" placeholder="[% 'GL search' | $T8 %]" maxlength="20">]
12 13
[%- END %]
13 14
 </span>
14 15
[%- END %]
......
16 17
  [[% 'User' | $T8 %]: [% MYCONFIG.login | html %] -
17 18
   [% 'Client' | $T8 %]: [% AUTH.client.name | html %] -
18 19
   <a href="controller.pl?action=LoginScreen/logout" target="_top" title="[% 'Logout now' | $T8 %]">[% 'Logout' | $T8 %]</a>]
19
  [% now.to_lxoffice %] -
20
  [% now.hms %]
21 20
 </span>
22 21
 <span class="frame-header-element frame-header-right" id="ajax-spinner">
23 22
  <img src="image/[% IF MYCONFIG.stylesheet == 'lx-office-erp.css' %]spinner-blue.gif[% ELSE %]spinner-white.gif[% END %]" alt="[% LxERP.t8('Loading...') %]">
24 23
 </span>
25 24
</div>
26
[% IF AUTH.assert('general_ledger', 1) %]
27
 <script type="text/javascript" src="js/glquicksearch.js"></script>
28
[% END %]
25
[%- END %]
templates/webpages/menu/menunew.html
1 1
[%- USE T8 %]
2 2
[% USE HTML %][%- USE LxERP -%]
3
 <script type="text/javascript">
4
<!--
5
function clockon() {
6
  var now = new Date();
7
  var h = now.getHours();
8
  var m = now.getMinutes();
9
  document.getElementById('clock_id').innerHTML = (h<10?'0'+h:h)+":"+(m<10?'0'+m:m);
10
  var timer=setTimeout("clockon()", 10000);
11
}
12
$(clockon);
13
//-->
14
 </script>
15

  
16
 <script type="text/javascript" src="js/dhtmlsuite/menu-for-applications.js"></script>
17

  
18
 <div id="frame-header">
19
  <span class="frame-header-element frame-header-left">
20
   [<a href="login.pl?action=company_logo" target="_blank">[% 'new Window' | $T8 %]</a>]
21
   [<a href="JavaScript:top.print()">[% 'print' | $T8 %]</a>]
22
[%- IF AUTH.assert('general_ledger', 1) %]
23
    [[% 'GL search' | $T8 %]: <input id="glquicksearch" name="glquicksearch" type="text" class="ui-widget" size="20" maxlength="20">]
24
[%- END %]
25
  </span>
26
  <span class="frame-header-element frame-header-right">
27
   [[% 'User' | $T8 %]: [% MYCONFIG.login | html %] -
28
    [% 'Client' | $T8 %]: [% AUTH.client.name | html %] -
29
   <a href="controller.pl?action=LoginScreen/logout" target="_top">[% 'logout' | $T8 %]</a>]
30
   [% date %] <span id='clock_id' style='position:relative'></span>&nbsp;
31
  </span>
32
  <span class="frame-header-element frame-header-right" id="ajax-spinner">
33
   <img src="image/[% IF MYCONFIG.stylesheet == 'lx-office-erp.css' %]spinner-blue.gif[% ELSE %]spinner-white.gif[% END %]" alt="[% LxERP.t8('Loading...') %]">
34
  </span>
35
 </div>
36

  
37 3
 <div id="main_menu_div"></div>
38 4

  
39 5
 [%- SET main_id = '100' %]
......
100 66

  
101 67
    -->
102 68
 </script>
103
[% IF AUTH.assert('general_ledger', 1) %]
104
 <script type="text/javascript" src="js/glquicksearch.js"></script>
105
[% END %]
templates/webpages/menu/menuv3.html
1
[%- USE T8 %]
2
[% USE HTML %][%- USE LxERP -%]
3
[% UNLESS skip_frame_header %]
4
 <script type="text/javascript" src="js/quicksearch_input.js"></script>
5
 <script type="text/javascript">
6
 <!--
7
function clockon() {
8
  var now = new Date();
9
  var h = now.getHours();
10
  var m = now.getMinutes();
11
  document.getElementById('clock_id').innerHTML = (h<10?'0'+h:h)+":"+(m<10?'0'+m:m);
12
  var timer=setTimeout("clockon()", 10000);
13
}
14
$(clockon);
15
//-->
16
 </script>
17

  
18
<div id="frame-header">
19
 <span class="frame-header-element frame-header-left">
20
    [<a href="login.pl?action=company_logo" target="_blank">[% 'new Window' | $T8 %]</a>]
21
    [<a href="JavaScript:top.print()">[% 'print' | $T8 %]</a>]
22
    [[% 'Search contacts' | $T8 %] <input size="15" name="search_term" id="search_term" onkeydown="return on_keydown_quicksearch($('#search_term'), event)">]
23
[%- IF AUTH.assert('general_ledger', 1) %]
24
    [[% 'GL search' | $T8 %]: <input id="glquicksearch" name="glquicksearch" type="text" class="ui-widget" size="20" maxlength="20">]
25
[%- END %]
26
 </span>
27
 <span class="frame-header-element frame-header-right">
28
    [[% 'User' | $T8 %]: [% MYCONFIG.login | html %] -
29
     [% 'Client' | $T8 %]: [% AUTH.client.name | html %] -
30
    <a href="controller.pl?action=LoginScreen/logout" target="_top">[% 'logout' | $T8 %]</a>]
31
    [% date %] <span id='clock_id' style='position:relative'></span>&nbsp;
32
 </span>
33
 <span class="frame-header-element frame-header-right" id="ajax-spinner">
34
  <img src="image/[% IF MYCONFIG.stylesheet == 'lx-office-erp.css' %]spinner-blue.gif[% ELSE %]spinner-white.gif[% END %]" alt="[% LxERP.t8('Loading...') %]">
35
 </span>
36
</div>
37
[% END %]
38
 <div id="menuv3">
39

  
40
  [% menu %]
41

  
42
 </div>
1
 <div id="menuv3">[% menu %]</div>
43 2
 <div style="clear: both;"></div>
44
[% IF AUTH.assert('general_ledger', 1) %]
45
 <script type="text/javascript" src="js/glquicksearch.js"></script>
46
[% END %]

Auch abrufbar als: Unified diff