+=item depend_insert OTHER_JOBNUM
+
+Inserts a dependancy for this job. If there is an error, returns the error,
+otherwise returns false.
+
+When using job dependancies, you should wrap the insertion of jobs in a
+database transaction.
+
+=cut
+
+sub depend_insert {
+ my($self, $other_jobnum) = @_;
+ my $queue_depend = new FS::queue_depend (
+ 'jobnum' => $self->jobnum,
+ 'depend_jobnum' => $other_jobnum,
+ );
+ $queue_depend->insert;
+}
+
+=back
+
+=head1 SUBROUTINES
+
+=over 4
+