Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 1f723230

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

  • ID 1f72323083c3ce8781da23526c0e77b927549b37
  • Vorgänger dd1ab30b
  • Nachfolger 76c47f0d

oe: actiobar nochmal umgestellt

Unterschiede anzeigen:

bin/mozilla/oe.pl
456 456
    $bar->add_actions([ t8('Update'),
457 457
      submit => [ '#form', { action_update         => 1 } ],
458 458
    ]);
459
    $bar->add_actions([ t8('Ship to'),
460
      submit => [ '#form', { action_ship_to        => 1 } ],
461
    ]);
462
    $bar->add_actions([ t8('Print'),
463
      submit => [ '#form', { action_print          => 1 } ],
464
      checks => [ qw(kivi.SalesPurchase.check_transaction_description) ],
465
    ]);
466
    $bar->add_actions([ t8('E Mail'),
467
      submit => [ '#form', { action_print          => 1 } ],
468
      checks => [ qw(kivi.SalesPurchase.check_transaction_description) ],
469
    ]);
470
    $bar->add_actions([ t8('Save'),
459
    $bar->add_actions("combobox");
460
    $bar->actions->[-1]->add_actions([ t8('Save'),
471 461
      submit => [ '#form', { action_save           => 1 } ],
472 462
      checks => [ qw(kivi.SalesPurchase.check_transaction_description) ],
473 463
      confirm => t8('Missing transport cost: #1  Are you sure?', $tpca_remainder),
474 464
      # optional warn_save_active_periodic_invoice,
475 465
    ]);
476
    $bar->add_actions([ t8('Save and Close'),
477
      submit => [ '#form', { action_save_and_close => 1 } ],
466
    $bar->actions->[-1]->add_actions([ t8('Save as new'),
467
      submit => [ '#form', { action_save_as_new    => 1 } ],
478 468
      checks => [ qw(kivi.SalesPurchase.check_transaction_description) ],
479
      confirm => t8('Missing transport cost: #1  Are you sure?', $tpca_remainder),
480
      # always, optional warn_save_active_periodic_invoice,
481
    ]);
482
    $bar->add_actions([ t8('Follow-Up'),
483
      function => [ 'follow_up_window' ],
484
      disabled => !$::form->{id},
485
    ]);
486
    $bar->add_actions([ t8('History'),
487
      function => [ 'set_history_window', $::form->{id} * 1, 'id' ],
488 469
      disabled => !$::form->{id},
489 470
    ]);
490
    $bar->add_actions([ t8('Save as new'),
491
      submit => [ '#form', { action_save_as_new    => 1 } ],
471
     $bar->actions->[-1]->add_actions([ t8('Save and Close'),
472
      submit => [ '#form', { action_save_and_close => 1 } ],
492 473
      checks => [ qw(kivi.SalesPurchase.check_transaction_description) ],
493
      disabled => !$::form->{id},
474
      confirm => t8('Missing transport cost: #1  Are you sure?', $tpca_remainder),
475
      # always, optional warn_save_active_periodic_invoice,
494 476
    ]);
495 477
    $bar->add_actions([ t8('Delete'),
496 478
      submit => [ '#form', { action_delete         => 1 } ],
497
      disabled => !$::form->{id},
498
    ]) if $::form->{id} && (!$is_sales_ord || $::instance_conf->get_sales_order_show_delete) && (!$is_pur_ord || $::instance_conf->get_purchase_order_show_delete);
499
    $bar->add_actions([ t8('Sales Order'),
479
      disabled => !$::form->{id}
480
               || ($is_sales_ord && !$::instance_conf->get_sales_order_show_delete)
481
               || ($is_pur_ord   && !$::instance_conf->get_purchase_order_show_delete),
482
    ]);
483
    $bar->add_actions([undef, actions => [] ]);
484
    $bar->actions->[-1]->add_actions([ t8('Sales Order'),
500 485
      submit => [ '#form', { action_sales_order    => 1 } ],
501 486
      disabled => !$::form->{id},
502 487
    ]) if $is_sales_quo;
503
    $bar->add_actions([ t8('Purchase Order'),
488
    $bar->actions->[-1]->add_actions([ t8('Purchase Order'),
504 489
      submit => [ '#form', { action_sales_order    => 1 } ],
505 490
      disabled => !$::form->{id},
506 491
    ]) if $is_req_quo;
507
    $bar->add_actions([ t8('Delivery Order'),
492
    $bar->actions->[-1]->add_actions([ t8('Delivery Order'),
508 493
      submit => [ '#form', { action_delivery_order => 1 } ],
509 494
      disabled => !$::form->{id},
510 495
    ]) if $is_sales_ord || $is_pur_ord;
511
    $bar->add_actions([ t8('Invoice'),
496
    $bar->actions->[-1]->add_actions([ t8('Invoice'),
512 497
      submit => [ '#form', { action_invoice        => 1 } ],
513 498
      disabled => !$::form->{id},
514 499
    ]) if $allow_invoice;
515
    $bar->add_actions([ t8('Quotation'),
500
    $bar->actions->[-1]->add_actions([ t8('Quotation'),
516 501
      submit => [ '#form', { action_quotation      => 1 } ],
517 502
      disabled => !$::form->{id},
518 503
    ]);
519
    $bar->add_actions([ t8('Request for Quotation'),
504
    $bar->actions->[-1]->add_actions([ t8('Request for Quotation'),
520 505
      submit => [ '#form', { action_reqest_for_quotation => 1 } ],
521 506
      disabled => !$::form->{id}
522 507
    ]);
508
    $bar->add_actions([ t8('Print'),
509
      submit => [ '#form', { action_print          => 1 } ],
510
      checks => [ qw(kivi.SalesPurchase.check_transaction_description) ],
511
    ]);
512
    $bar->add_actions([ t8('E Mail'),
513
      submit => [ '#form', { action_print          => 1 } ],
514
      checks => [ qw(kivi.SalesPurchase.check_transaction_description) ],
515
    ]);
516
    $bar->add_actions([ t8('Ship to'),
517
      submit => [ '#form', { action_ship_to        => 1 } ],
518
    ]);
519
    $bar->add_actions([ t8('History'),
520
      function => [ 'set_history_window', $::form->{id} * 1, 'id' ],
521
      disabled => !$::form->{id},
522
    ]);
523
    $bar->add_actions([ t8('Follow-Up'),
524
      function => [ 'follow_up_window' ],
525
      disabled => !$::form->{id},
526
    ]);
523 527
  }
524 528

  
525 529
  $form->header;

Auch abrufbar als: Unified diff