Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 6c6a8d01

Von Bernd Bleßmann vor etwa 1 Jahr hinzugefügt

  • ID 6c6a8d01a04b14824dd695d71a0ec6a432778f55
  • Vorgänger 15672788
  • Nachfolger f251540d

Erzwungener Layout-Stil: Benutzereinstellung

Desktop, Mobil, automatisch oder aus Mandantenkonfig

Unterschiede anzeigen:

SL/AM.pm
561 561
  SL::Helper::UserPreferences::DisplayPreferences->new()->get_longdescription_dialog_size_percentage();
562 562
}
563 563

  
564
sub layout_style {
565
  SL::Helper::UserPreferences::DisplayPreferences->new()->get_layout_style();
566
}
567

  
564 568
sub save_preferences {
565 569
  $main::lxdebug->enter_sub();
566 570

  
......
604 608
  if (exists $form->{longdescription_dialog_size_percentage}) {
605 609
    SL::Helper::UserPreferences::DisplayPreferences->new()->store_longdescription_dialog_size_percentage($form->{longdescription_dialog_size_percentage})
606 610
  }
611
  if (exists $form->{layout_style}) {
612
    SL::Helper::UserPreferences::DisplayPreferences->new()->store_layout_style($form->{layout_style})
613
  }
607 614

  
608 615
  $main::lxdebug->leave_sub();
609 616

  
SL/Helper/UserPreferences/DisplayPreferences.pm
31 31
    return;
32 32
  }
33 33

  
34
  if ( !($style eq 'desktop' || $style eq 'mobile') ) {
34
  if ( !($style eq 'desktop' || $style eq 'mobile' || $style eq 'auto') ) {
35 35
    die "unknown layout style '$style'";
36 36
  }
37 37

  
bin/mozilla/am.pl
665 665
  $form->{positions_show_update_button}           = AM->positions_show_update_button();
666 666
  $form->{time_recording_use_duration}            = AM->time_recording_use_duration();
667 667
  $form->{longdescription_dialog_size_percentage} = AM->longdescription_dialog_size_percentage();
668
  $form->{layout_style}                           = AM->layout_style();
668 669

  
669 670
  $myconfig{show_form_details} = 1 unless (defined($myconfig{show_form_details}));
670 671
  $form->{CAN_CHANGE_PASSWORD} = $main::auth->can_change_password();
templates/design40_webpages/am/config.html
106 106
      <th>[% 'Language' | $T8 %]</th>
107 107
      <td>[% L.select_tag('countrycode', COUNTRYCODES, value_key = 'value', title_key = 'name', class='wi-lightwide') %]</td>
108 108
    </tr>
109
    <tr>
110
      <th>[% 'Forced Layout Style' | $T8 %]</th>
111
      <td>
112
        [% L.select_tag('layout_style', [['', LxERP.t8('Use settings from client configuration')], ['auto', LxERP.t8('Automatic')], ['mobile', LxERP.t8('mobile version')], ['desktop', LxERP.t8('desktop version')]], default=layout_style, with_empty=0, class='wi-lightwide') %]
113
      </td>
114
    </tr>
109 115
    <tr>
110 116
      <th>[% 'Stylesheet' | $T8 %]</th>
111 117
      <td>[% L.select_tag('usestylesheet', STYLESHEETS, value_key = 'value', title_key = 'name', class='wi-lightwide') %]</td>
templates/design40_webpages/client_config/_features.html
571 571
    <tr><th class="caption">[% 'Forced Layout Style' | $T8 %]</th></tr>
572 572
    <tr>
573 573
      <th>[% 'Force a layout style' | $T8 %]</th>
574
      <td>[% L.select_tag('defaults.layout_style', [['', LxERP.t8('Automatic')], ['mobile', LxERP.t8('mobile version')], ['desktop', LxERP.t8('desktop version')]], default=SELF.defaults.layout_style, with_empty=0, style="width: 200px") %]</td>
574
      <td>[% L.select_tag('defaults.layout_style', [['', LxERP.t8('Automatic')], ['mobile', LxERP.t8('mobile version')], ['desktop', LxERP.t8('desktop version')]], default=SELF.defaults.layout_style, with_empty=0) %]</td>
575 575
      <td class="long-desc">[% 'The layout style normally is choosen by the user agent string the browser sends. Here you can force the desktop or mobile version. Users can override this setting in their user preferences.' | $T8 %]</td>
576 576
    </tr>
577 577
  </tbody>
templates/webpages/am/config.html
132 132
      </td>
133 133
     </tr>
134 134

  
135
     <tr>
136
      <th align="right">[% 'Forced Layout Style' | $T8 %]</th>
137
      <td>
138
        [% L.select_tag('layout_style', [['', LxERP.t8('Use settings from client configuration')], ['auto', LxERP.t8('Automatic')], ['mobile', LxERP.t8('mobile version')], ['desktop', LxERP.t8('desktop version')]], default=layout_style, with_empty=0) %]
139
      </td>
140
     </tr>
141

  
135 142
     <tr>
136 143
      <th align="right">[% 'Stylesheet' | $T8 %]</th>
137 144
      <td>

Auch abrufbar als: Unified diff