Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 69a5907e

Von Moritz Bunkus vor mehr als 10 Jahren hinzugefügt

  • ID 69a5907ea17e23532ad5cf2bd41da87d42d86466
  • Vorgänger cced2d9f
  • Nachfolger 806db9c0

Pflichtenhefttextblöcke: Nach Anlegen weitere Anlege-Form anzeigen

Unterschiede anzeigen:

SL/Controller/RequirementSpecTextBlock.pm
69 69
    $self->js->html('#column-content', $html);
70 70
  }
71 71

  
72
  $self->add_new_text_block_form(output_position => $new_where, insert_after_id => $::form->{id});
72
  $self->add_new_text_block_form(output_position => $new_where, insert_after_id => $::form->{id}, requirement_spec_id => $::form->{requirement_spec_id});
73 73

  
74 74
  $self->invalidate_version->render($self);
75 75
}
......
117 117
  $self->invalidate_version
118 118
    ->replaceWith('#' . $::form->{form_prefix} . '_form', $html)
119 119
    ->jstree->create_node('#tree', $insert_after ? ('#tb-' . $insert_after, 'after') : ('#tb-' . ($attributes->{output_position} == 0 ? 'front' : 'back'), 'last'), $node)
120
    ->jstree->select_node('#tree', '#tb-' . $self->text_block->id)
120
    ->jstree->select_node('#tree', '#tb-' . $self->text_block->id);
121
  $self->add_new_text_block_form(output_position => $self->text_block->output_position, insert_after_id => $self->text_block->id, requirement_spec_id => $self->text_block->requirement_spec_id)
121 122
    ->render($self);
122 123
}
123 124

  
......
324 325
sub add_new_text_block_form {
325 326
  my ($self, %params) = @_;
326 327

  
327
  croak "Missing parameter output_position" unless defined($params{output_position}) && ($params{output_position} ne '');
328
  croak "Missing parameter output_position"     unless defined($params{output_position}) && ($params{output_position} ne '');
329
  croak "Missing parameter requirement_spec_id" unless $params{requirement_spec_id};
328 330

  
329 331
  $self->text_block(SL::DB::RequirementSpecTextBlock->new(
330
    requirement_spec_id => $::form->{requirement_spec_id},
332
    requirement_spec_id => $params{requirement_spec_id},
331 333
    output_position     => $params{output_position},
332 334
  ));
333 335

  

Auch abrufbar als: Unified diff