Revision 2f4be233
Von Sven Schöling vor etwa 3 Jahren hinzugefügt
SL/Controller/DeliveryOrder.pm | ||
---|---|---|
53 | 53 |
|
54 | 54 |
|
55 | 55 |
# safety |
56 |
__PACKAGE__->run_before('check_auth'); |
|
56 |
__PACKAGE__->run_before('check_auth', |
|
57 |
except => [ qw(pack_stock_information) ]); |
|
57 | 58 |
|
58 | 59 |
__PACKAGE__->run_before('get_unalterable_data', |
59 | 60 |
only => [ qw(save save_as_new save_and_delivery_order save_and_invoice save_and_ap_transaction |
... | ... | |
906 | 907 |
part => $part, |
907 | 908 |
do_qty => $qty, |
908 | 909 |
do_unit => $unit, |
910 |
delivered => $self->order->delivered, |
|
909 | 911 |
); |
912 |
} |
|
913 |
|
|
914 |
# we're using the old YAML based stock packing, but don't want to do this in |
|
915 |
# the frontend so we're doing a tiny roundtrip to the backend, back the info in |
|
916 |
# perl, serve it back to the frontend and store it in the DOM there |
|
917 |
sub action_pack_stock_information { |
|
918 |
my ($self) = @_; |
|
919 |
|
|
920 |
my $stock_info = $::form->{stock_info}; |
|
921 |
my $yaml = SL::YAML::Dump($stock_info); |
|
910 | 922 |
|
923 |
$self->render(\$yaml, { layout => 0, process => 0 }); |
|
911 | 924 |
} |
912 | 925 |
|
913 | 926 |
sub merge_stock_data { |
Auch abrufbar als: Unified diff
DeliveryOrder: serialize stock to yaml