Skip to content

Recurring Invoices Break When Creating or Updating #3315

@imhayatunnabi

Description

@imhayatunnabi

Akaunting version

3.1.19

PHP version

8.2

Operating system

macOS Version 15.6 (24G84)

Steps to reproduce

Create or edit a recurring invoice from the admin UI (or hit the corresponding /recurring-invoices API endpoint).
Submit the form with valid data.

Expected result

Recurring invoice saves successfully and retains all supplied fields (contact, items, schedule, etc.)

Actual result

Job receives an empty payload, so the document is stored without the submitted attributes, yielding validation/database errors or a corrupted recurring invoice record.

Additional comments

Merge the overridden dates first, then pass the actual request instance into the job:

$request->merge(['issued_at' => $request->get('recurring_started_at')]);

$response = $this->ajaxDispatch(new CreateDocument($request));

Apply the same pattern in update().

Relevant log output

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions