invoice->status_id <= 2 && $this->invoice->is_deleted == false && $this->invoice->deleted_at == NULL) return true; return false; } public function invoiceCancellable() :bool { if($this->invoice->status_id == 3 && $this->invoice->is_deleted == false && $this->invoice->deleted_at == NULL) return true; return false; } public function invoiceReversable() :bool { if(($this->invoice->status_id == 3 || $this->invoice->status_id == 4) && $this->invoice->is_deleted == false && $this->invoice->deleted_at == NULL) return true; return false; } }