replicate(); $clone_quote->status_id = quote::STATUS_DRAFT; $clone_quote->number = null; $clone_quote->date = null; $clone_quote->due_date = null; $clone_quote->partial_due_date = null; $clone_quote->user_id = $user_id; $clone_quote->balance = $quote->amount; $clone_quote->amount = $quote->amount; $clone_quote->line_items = $quote->line_items; return $clone_quote; } }