Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 21187f8b

Von Bernd Bleßmann vor fast 11 Jahren hinzugefügt

  • ID 21187f8b1b6904183bf887e8abed77bd807b4aa1
  • Vorgänger 865972a5
  • Nachfolger 0dfb1453

check_objects: Schleifen zusammengefasst.

Unterschiede anzeigen:

SL/Controller/CsvImport/Order.pm
244 244

  
245 245
    if ($entry->{raw_data}->{datatype} eq $self->_order_column) {
246 246
      $self->handle_order($entry);
247
    } elsif ($entry->{raw_data}->{datatype} eq $self->_item_column && $entry->{object}->can('part')) {
248
      $self->handle_item($entry);
247 249
    }
250

  
248 251
  } continue {
249 252
    $i++;
250 253
  }
......
257 260
  $self->add_columns($self->_order_column, 'globalproject_id') if exists $self->controller->data->[0]->{raw_data}->{globalprojectnumber};
258 261
  $self->add_columns($self->_order_column, 'cp_id')            if exists $self->controller->data->[0]->{raw_data}->{contact};
259 262

  
260
  foreach my $entry (@{ $self->controller->data }) {
261
    if ($entry->{raw_data}->{datatype} eq $self->_item_column && $entry->{object}->can('part')) {
262
      $self->handle_item($entry);
263
    }
264
  }
265

  
266 263
  $self->add_info_columns($self->_item_column,
267 264
                          { header => $::locale->text('Part Number'), method => 'partnumber' });
268 265
  # Todo: access via ->[1] ok? Better: search first item column and use this

Auch abrufbar als: Unified diff