Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 8a2d9daf

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

  • ID 8a2d9daf01083e1271cf6118591bb2c242734261
  • Vorgänger 6bda747d
  • Nachfolger 77c873db

gelöschte Benutzer in ar/search ausblenden

Unterschiede anzeigen:

bin/mozilla/ar.pl
1346 1346
  $form->get_lists("projects"       => { "key" => "ALL_PROJECTS", "all" => 1 },
1347 1347
                   "departments"    => "ALL_DEPARTMENTS",
1348 1348
                   "customers"      => "ALL_VC",
1349
                   "employees"    => "ALL_EMPLOYEES",
1350
                   "salesmen"     => "ALL_SALESMEN",
1351 1349
                   "business_types" => "ALL_BUSINESS_TYPES");
1350
  $form->{ALL_EMPLOYEES} = SL::DB::Manager::Employee->get_all(query => [ deleted => 0 ]);
1352 1351
  $form->{SHOW_BUSINESS_TYPES} = scalar @{ $form->{ALL_BUSINESS_TYPES} } > 0;
1353 1352

  
1354 1353
  # constants and subs for template
1355 1354
  $form->{jsscript}  = 1;
1356 1355
  $form->{vc_keys}   = sub { "$_[0]->{name}--$_[0]->{id}" };
1357
  $form->{employee_labels} = sub { $_[0]->{"name"} || $_[0]->{"login"} };
1358
  $form->{salesman_labels} = $form->{employee_labels};
1359 1356

  
1360 1357
  $form->header;
1361 1358
  print $form->parse_html_template('ar/search', { %myconfig });
templates/webpages/ar/search.html
1 1
[%- USE T8 %]
2
[%- USE L %]
2 3
<body>
3 4

  
4 5
 <form method=post name="search" action=[% script %]>
......
51 52
     </tr>
52 53
     <tr>
53 54
      <th align="right">[% 'Employee' | $T8 %]</th>
54
      <td>
55
             [%- INCLUDE 'generic/multibox.html'
56
                  name          = 'employee_id',
57
                  style         = 'width: 250px',
58
                  DATA          =  ALL_EMPLOYEES,
59
                  id_key        = 'id',
60
                  label_sub     = 'employee_labels',
61
                  limit         = vclimit,
62
                  show_empty    = 1,
63
                  allow_textbox = 0,
64
                  default       = ' ',
65
             -%]
66
      </td>
55
      <td>[% L.select_tag('employee_id', L.options_for_select(ALL_EMPLOYEES, title='safe_name', with_empty=1), style='width:250px') %]</td>
67 56
     </tr>
68 57
    <tr>
69 58
     <th align="right">[% 'Salesman' | $T8 %]</th>
70
     <td>
71
            [%- INCLUDE 'generic/multibox.html'
72
                 name          = 'salesman_id',
73
                 style         = 'width: 250px',
74
                 DATA          =  ALL_SALESMEN,
75
                 id_key        = 'id',
76
                 label_sub     = 'salesman_labels',
77
                 limit         = vclimit,
78
                 show_empty    = 1,
79
                 allow_textbox = 0,
80
            -%]
81
     </td>
59
     <td>[% L.select_tag('salesman_id', L.options_for_select(ALL_EMPLOYEES, title='safe_name', with_empty=1), style='width:250px') %]</td>
82 60
     </tr>
83 61
     <tr>
84 62
      <th align=right nowrap>[% 'Transaction description' | $T8 %]</th>

Auch abrufbar als: Unified diff