Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision f134996a

Von Sven Schöling vor etwa 15 Jahren hinzugefügt

  • ID f134996afb100bedaefba9a4176a9fbcc715a83c
  • Vorgänger dc55d385
  • Nachfolger 999fdf7d

Syntaxkorrekturen.

Unterschiede anzeigen:

bin/mozilla/ic.pl
46 46
#use warnings;
47 47

  
48 48
# global imports
49
our ($form, $locale, %myconfig, $lxdebug);
49
our ($form, $locale, %myconfig, $lxdebug, $auth);
50 50

  
51 51
require "bin/mozilla/io.pl";
52 52
require "bin/mozilla/invoice_io.pl";
......
140 140
  $auth->assert('part_service_assembly_edit');
141 141

  
142 142
  my @errors      = ();
143
  my $value_found = false;
143
  my $value_found = undef;
144 144

  
145 145
  foreach my $idx (qw(sellprice listprice), (1..$form->{price_rows})) {
146 146
    my $name      = $idx =~ m/\d/ ? $form->{"pricegroup_${idx}"}      : $idx eq 'sellprice' ? $locale->text('Sell Price') : $locale->text('List Price');
......
1023 1023
  $form->{title} =~ s/ys$/ies/;
1024 1024
  $form->{title} = $locale->text($form->{title});
1025 1025

  
1026
  my $revers     = $form->{revers};
1027
  my $lastsort   = $form->{lastsort};
1026
  $revers     = $form->{revers};
1027
  $lastsort   = $form->{lastsort};
1028 1028

  
1029 1029
  # sorting and direction of sorting
1030 1030
  # ToDO: change this to the simpler field+direction method
......
1510 1510

  
1511 1511
  $auth->assert('part_service_assembly_edit');
1512 1512

  
1513
  $form->{eur}              = $eur; # config dumps into namespace - yuck
1513
  $form->{eur}              = $main::eur; # config dumps into namespace - yuck
1514 1514
  $form->{pg_keys}          = sub { "$_[0]->{partsgroup}--$_[0]->{id}" };
1515 1515
  $form->{description_area} = ($form->{rows} = $form->numtextrows($form->{description}, 40)) > 1;
1516 1516
  $form->{notes_rows}       =  max 4, $form->numtextrows($form->{notes}, 40), $form->numtextrows($form->{formel}, 40);
......
1529 1529
  # use JavaScript Calendar or not (yes!)
1530 1530
  $form->{jsscript} = 1;
1531 1531

  
1532
  $units = AM->retrieve_units(\%myconfig, $form);
1532
  my $units = AM->retrieve_units(\%myconfig, $form);
1533 1533
  $form->{ALL_UNITS} = [ map +{ name => $_ }, sort { $units->{$a}{sortkey} <=> $units->{$b}{sortkey} } keys %$units ];
1534 1534

  
1535 1535
  $form->{defaults} = AM->get_defaults();
......
1577 1577
  my (@column_index);
1578 1578
  my ($nochange, $callback, $previousform, $linetotal, $line_purchase_price, $href);
1579 1579

  
1580
  our ($deliverydate); # ToDO: cjeck if this indeed comes from global context
1580
  our ($deliverydate); # ToDO: check if this indeed comes from global context
1581 1581

  
1582 1582
  @column_index = qw(runningnumber qty unit bom partnumber description partsgroup lastcost total);
1583 1583

  
......
1596 1596

  
1597 1597
    # save form variables in a previousform variable
1598 1598
    $previousform = $form->escape($form->escape(join '&', map {
1599
      sprintf "%s=%s", Q($_), /^listprice|lastcost|sellprice$/ ? $form->format_amount(\%myconfig, $form->{$key}) : $form->{$key}
1599
      sprintf "%s=%s", Q($_), /^listprice|lastcost|sellprice$/ ? $form->format_amount(\%myconfig, $form->{$_}) : $form->{$_}
1600 1600
    } grep { ref $form->{$_} eq '' && $form->{$_} } grep { !/^select/ } sort keys %$form ));
1601 1601

  
1602 1602
    $form->{callback} = $callback;
......
1968 1968

  
1969 1969
  $auth->assert('part_service_assembly_edit');
1970 1970

  
1971
  our ($onload);
1971
  our ($onload, $callback);
1972 1972

  
1973 1973
  my $languages = IC->retrieve_languages(\%myconfig, $form);
1974 1974

  
1975 1975
  if ($form->{language_values} ne "") {
1976
    foreach $item (split(/---\+\+\+---/, $form->{language_values})) {
1976
    foreach my $item (split(/---\+\+\+---/, $form->{language_values})) {
1977 1977
      my ($language_id, $translation, $longdescription) = split(/--\+\+--/, $item);
1978 1978

  
1979 1979
      foreach my $language (@{ $languages }) {

Auch abrufbar als: Unified diff