mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-09 03:14:30 -04:00
commit
5aed0e5024
@ -1 +1 @@
|
|||||||
5.5.88
|
5.5.89
|
@ -11,19 +11,26 @@
|
|||||||
|
|
||||||
namespace App\Services\Pdf;
|
namespace App\Services\Pdf;
|
||||||
|
|
||||||
use App\DataMapper\ClientSettings;
|
use App\Models\Quote;
|
||||||
use App\Models\Client;
|
use App\Models\Client;
|
||||||
|
use App\Models\Credit;
|
||||||
|
use App\Models\Design;
|
||||||
|
use App\Models\Vendor;
|
||||||
use App\Models\Company;
|
use App\Models\Company;
|
||||||
use App\Models\Country;
|
use App\Models\Country;
|
||||||
use App\Models\Credit;
|
|
||||||
use App\Models\Currency;
|
|
||||||
use App\Models\Design;
|
|
||||||
use App\Models\Invoice;
|
use App\Models\Invoice;
|
||||||
use App\Models\InvoiceInvitation;
|
use App\Models\Currency;
|
||||||
use App\Models\PurchaseOrder;
|
use App\Models\PurchaseOrder;
|
||||||
use App\Models\Quote;
|
use App\Models\QuoteInvitation;
|
||||||
use App\Models\Vendor;
|
|
||||||
use App\Utils\Traits\MakesHash;
|
use App\Utils\Traits\MakesHash;
|
||||||
|
use App\Models\CreditInvitation;
|
||||||
|
use App\Services\Pdf\PdfBuilder;
|
||||||
|
use App\Services\Pdf\PdfService;
|
||||||
|
use App\Models\InvoiceInvitation;
|
||||||
|
use App\Services\Pdf\PdfDesigner;
|
||||||
|
use App\DataMapper\ClientSettings;
|
||||||
|
use App\Services\Pdf\PdfConfiguration;
|
||||||
|
use App\Models\PurchaseOrderInvitation;
|
||||||
|
|
||||||
class PdfMock
|
class PdfMock
|
||||||
{
|
{
|
||||||
@ -81,23 +88,46 @@ class PdfMock
|
|||||||
|
|
||||||
public function initEntity(): mixed
|
public function initEntity(): mixed
|
||||||
{
|
{
|
||||||
match ($this->request['entity_type']) {
|
$settings = new \stdClass;
|
||||||
'invoice' => $entity = Invoice::factory()->make(),
|
$settings->entity = Client::class;
|
||||||
'quote' => $entity = Quote::factory()->make(),
|
$settings->currency_id = '1';
|
||||||
'credit' => $entity = Credit::factory()->make(),
|
$settings->industry_id = '';
|
||||||
'purchase_order' => $entity = PurchaseOrder::factory()->make(),
|
$settings->size_id = '';
|
||||||
default => $entity = Invoice::factory()->make()
|
|
||||||
};
|
|
||||||
|
|
||||||
if ($this->request['entity_type'] == PurchaseOrder::class) {
|
switch ($this->request['entity_type']) {
|
||||||
$entity->vendor = Vendor::factory()->make();
|
case 'invoice':
|
||||||
} else {
|
$entity = Invoice::factory()->make();
|
||||||
$entity->client = Client::factory()->make();
|
$entity->client = Client::factory()->make(['settings' => $settings]);
|
||||||
|
$entity->invitation = InvoiceInvitation::factory()->make();
|
||||||
|
break;
|
||||||
|
case 'quote':
|
||||||
|
$entity = Quote::factory()->make();
|
||||||
|
$entity->client = Client::factory()->make(['settings' => $settings]);
|
||||||
|
$entity->invitation = QuoteInvitation::factory()->make();
|
||||||
|
break;
|
||||||
|
case 'credit':
|
||||||
|
$entity = Credit::factory()->make();
|
||||||
|
$entity->client = Client::factory()->make(['settings' => $settings]);
|
||||||
|
$entity->invitation = CreditInvitation::factory()->make();
|
||||||
|
break;
|
||||||
|
case 'purchase_order':
|
||||||
|
$entity = PurchaseOrder::factory()->make();
|
||||||
|
$entity->client = Client::factory()->make(['settings' => $settings]);
|
||||||
|
$entity->invitation = PurchaseOrderInvitation::factory()->make();
|
||||||
|
break;
|
||||||
|
case PurchaseOrder::class:
|
||||||
|
$entity = PurchaseOrder::factory()->make();
|
||||||
|
$entity->invitation = PurchaseOrderInvitation::factory()->make();
|
||||||
|
$entity->vendor = Vendor::factory()->make();
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
# code...
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
$entity->tax_map = $this->getTaxMap();
|
$entity->tax_map = $this->getTaxMap();
|
||||||
$entity->total_tax_map = $this->getTotalTaxMap();
|
$entity->total_tax_map = $this->getTotalTaxMap();
|
||||||
$entity->invitation = InvoiceInvitation::factory()->make();
|
|
||||||
$entity->invitation->company = $this->company;
|
$entity->invitation->company = $this->company;
|
||||||
|
|
||||||
return $entity;
|
return $entity;
|
||||||
@ -182,7 +212,7 @@ class PdfMock
|
|||||||
'$client.public_notes' => ' ',
|
'$client.public_notes' => ' ',
|
||||||
'$company.postal_code' => $this->settings->postal_code,
|
'$company.postal_code' => $this->settings->postal_code,
|
||||||
'$client.billing_city' => 'Aufderharchester',
|
'$client.billing_city' => 'Aufderharchester',
|
||||||
'$secondary_font_name' => $this->settings->primary_font,
|
'$secondary_font_name' => isset($this->settings?->secondary_font) ? $this->settings->secondary_font : 'Roboto',
|
||||||
'$product.line_total' => '',
|
'$product.line_total' => '',
|
||||||
'$product.tax_amount' => '',
|
'$product.tax_amount' => '',
|
||||||
'$company.vat_number' => $this->settings->vat_number,
|
'$company.vat_number' => $this->settings->vat_number,
|
||||||
@ -417,7 +447,7 @@ EPD
|
|||||||
'$country_2' => 'AF',
|
'$country_2' => 'AF',
|
||||||
'$firstName' => 'Benedict',
|
'$firstName' => 'Benedict',
|
||||||
'$user.name' => 'Derrick Monahan DDS Erna Wunsch',
|
'$user.name' => 'Derrick Monahan DDS Erna Wunsch',
|
||||||
'$font_name' => 'Roboto',
|
'$font_name' => $this->settings?->primary_font ?: 'Roboto',
|
||||||
'$auto_bill' => 'This invoice will automatically be billed to your credit card on file on the due date.',
|
'$auto_bill' => 'This invoice will automatically be billed to your credit card on file on the due date.',
|
||||||
'$payments' => '',
|
'$payments' => '',
|
||||||
'$task.tax' => '',
|
'$task.tax' => '',
|
||||||
|
@ -14,8 +14,8 @@ return [
|
|||||||
'require_https' => env('REQUIRE_HTTPS', true),
|
'require_https' => env('REQUIRE_HTTPS', true),
|
||||||
'app_url' => rtrim(env('APP_URL', ''), '/'),
|
'app_url' => rtrim(env('APP_URL', ''), '/'),
|
||||||
'app_domain' => env('APP_DOMAIN', 'invoicing.co'),
|
'app_domain' => env('APP_DOMAIN', 'invoicing.co'),
|
||||||
'app_version' => '5.5.88',
|
'app_version' => '5.5.89',
|
||||||
'app_tag' => '5.5.88',
|
'app_tag' => '5.5.89',
|
||||||
'minimum_client_version' => '5.0.16',
|
'minimum_client_version' => '5.0.16',
|
||||||
'terms_version' => '1.0.1',
|
'terms_version' => '1.0.1',
|
||||||
'api_secret' => env('API_SECRET', ''),
|
'api_secret' => env('API_SECRET', ''),
|
||||||
|
@ -12,6 +12,7 @@
|
|||||||
namespace Database\Factories;
|
namespace Database\Factories;
|
||||||
|
|
||||||
use App\Models\Quote;
|
use App\Models\Quote;
|
||||||
|
use App\Factory\InvoiceItemFactory;
|
||||||
use Illuminate\Database\Eloquent\Factories\Factory;
|
use Illuminate\Database\Eloquent\Factories\Factory;
|
||||||
|
|
||||||
class QuoteFactory extends Factory
|
class QuoteFactory extends Factory
|
||||||
@ -39,7 +40,7 @@ class QuoteFactory extends Factory
|
|||||||
// 'custom_value4' => $this->faker->numberBetween(1, 4),
|
// 'custom_value4' => $this->faker->numberBetween(1, 4),
|
||||||
'is_deleted' => false,
|
'is_deleted' => false,
|
||||||
'po_number' => $this->faker->text(10),
|
'po_number' => $this->faker->text(10),
|
||||||
'line_items' => false,
|
'line_items' => InvoiceItemFactory::generate(5),
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -40,7 +40,7 @@ class VendorFactory extends Factory
|
|||||||
'postal_code' => $this->faker->postcode(),
|
'postal_code' => $this->faker->postcode(),
|
||||||
'country_id' => 4,
|
'country_id' => 4,
|
||||||
'vendor_hash' => Str::random(40),
|
'vendor_hash' => Str::random(40),
|
||||||
|
'currency_id' => 1,
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -12054,7 +12054,7 @@ paths:
|
|||||||
/api/v1/recurring_invoices:
|
/api/v1/recurring_invoices:
|
||||||
get:
|
get:
|
||||||
tags:
|
tags:
|
||||||
- recurring_invoices
|
- Recurring Invoices
|
||||||
summary: "List recurring invoices"
|
summary: "List recurring invoices"
|
||||||
description: |
|
description: |
|
||||||
Lists invoices with the option to chain multiple query parameters allowing fine grained filtering of the list.
|
Lists invoices with the option to chain multiple query parameters allowing fine grained filtering of the list.
|
||||||
@ -12125,7 +12125,7 @@ paths:
|
|||||||
$ref: "#/components/responses/default"
|
$ref: "#/components/responses/default"
|
||||||
post:
|
post:
|
||||||
tags:
|
tags:
|
||||||
- recurring_invoices
|
- Recurring Invoices
|
||||||
summary: "Create recurring invoice"
|
summary: "Create recurring invoice"
|
||||||
description: "Adds a Recurring Invoice to the system"
|
description: "Adds a Recurring Invoice to the system"
|
||||||
operationId: storeRecurringInvoice
|
operationId: storeRecurringInvoice
|
||||||
@ -12159,7 +12159,7 @@ paths:
|
|||||||
"/api/v1/recurring_invoices/{id}":
|
"/api/v1/recurring_invoices/{id}":
|
||||||
get:
|
get:
|
||||||
tags:
|
tags:
|
||||||
- recurring_invoices
|
- Recurring Invoices
|
||||||
summary: "Show recurring invoice"
|
summary: "Show recurring invoice"
|
||||||
description: "Displays an RecurringInvoice by id"
|
description: "Displays an RecurringInvoice by id"
|
||||||
operationId: showRecurringInvoice
|
operationId: showRecurringInvoice
|
||||||
@ -12199,7 +12199,7 @@ paths:
|
|||||||
$ref: "#/components/responses/default"
|
$ref: "#/components/responses/default"
|
||||||
put:
|
put:
|
||||||
tags:
|
tags:
|
||||||
- recurring_invoices
|
- Recurring Invoices
|
||||||
summary: "Update recurring invoice"
|
summary: "Update recurring invoice"
|
||||||
description: "Handles the updating of an RecurringInvoice by id"
|
description: "Handles the updating of an RecurringInvoice by id"
|
||||||
operationId: updateRecurringInvoice
|
operationId: updateRecurringInvoice
|
||||||
@ -12239,7 +12239,7 @@ paths:
|
|||||||
$ref: "#/components/responses/default"
|
$ref: "#/components/responses/default"
|
||||||
delete:
|
delete:
|
||||||
tags:
|
tags:
|
||||||
- recurring_invoices
|
- Recurring Invoices
|
||||||
summary: "Delete recurring invoice"
|
summary: "Delete recurring invoice"
|
||||||
description: "Handles the deletion of an RecurringInvoice by id"
|
description: "Handles the deletion of an RecurringInvoice by id"
|
||||||
operationId: deleteRecurringInvoice
|
operationId: deleteRecurringInvoice
|
||||||
@ -12276,7 +12276,7 @@ paths:
|
|||||||
"/api/v1/recurring_invoices/{id}/edit":
|
"/api/v1/recurring_invoices/{id}/edit":
|
||||||
get:
|
get:
|
||||||
tags:
|
tags:
|
||||||
- recurring_invoices
|
- Recurring Invoices
|
||||||
summary: "Edit recurring invoice"
|
summary: "Edit recurring invoice"
|
||||||
description: "Displays an RecurringInvoice by id"
|
description: "Displays an RecurringInvoice by id"
|
||||||
operationId: editRecurringInvoice
|
operationId: editRecurringInvoice
|
||||||
@ -12318,7 +12318,7 @@ paths:
|
|||||||
/api/v1/recurring_invoices/create:
|
/api/v1/recurring_invoices/create:
|
||||||
get:
|
get:
|
||||||
tags:
|
tags:
|
||||||
- recurring_invoices
|
- Recurring Invoices
|
||||||
summary: "Blank recurring invoice"
|
summary: "Blank recurring invoice"
|
||||||
description: "Returns a blank object with default values"
|
description: "Returns a blank object with default values"
|
||||||
operationId: getRecurringInvoicesCreate
|
operationId: getRecurringInvoicesCreate
|
||||||
@ -12351,25 +12351,52 @@ paths:
|
|||||||
/api/v1/recurring_invoices/bulk:
|
/api/v1/recurring_invoices/bulk:
|
||||||
post:
|
post:
|
||||||
tags:
|
tags:
|
||||||
- recurring_invoices
|
- Recurring Invoices
|
||||||
summary: "Bulk recurring invoice actions"
|
summary: "Bulk recurring invoice actions"
|
||||||
description: ""
|
description: |
|
||||||
|
There are multiple actions that are available including:
|
||||||
|
|
||||||
operationId: bulkRecurringInvoices
|
operationId: bulkRecurringInvoices
|
||||||
parameters:
|
parameters:
|
||||||
- $ref: "#/components/parameters/X-API-TOKEN"
|
- $ref: "#/components/parameters/X-API-TOKEN"
|
||||||
- $ref: "#/components/parameters/X-Requested-With"
|
- $ref: "#/components/parameters/X-Requested-With"
|
||||||
- $ref: "#/components/parameters/index"
|
- $ref: "#/components/parameters/index"
|
||||||
requestBody:
|
requestBody:
|
||||||
description: "Hashed IDs"
|
description: "Bulk action details"
|
||||||
required: true
|
required: true
|
||||||
content:
|
content:
|
||||||
application/json:
|
application/json:
|
||||||
schema:
|
schema:
|
||||||
type: array
|
type: object
|
||||||
items:
|
properties:
|
||||||
description: "Array of hashed IDs to be bulk 'actioned"
|
action:
|
||||||
type: integer
|
type: string
|
||||||
example: "[0,1,2,3]"
|
description: |
|
||||||
|
The action to be performed, options include:
|
||||||
|
- `start`
|
||||||
|
Starts (or restarts) the recurring invoice. **note** if the recurring invoice has been stopped for a long time, it will attempt to catch back up firing a new Invoice every hour per interval that has been missed.
|
||||||
|
If you do not wish to have the recurring invoice catch up, you should set the next_send_date to the correct date you wish the recurring invoice to commence from.
|
||||||
|
- `stop`
|
||||||
|
Stops the recurring invoice.
|
||||||
|
- `send_now`
|
||||||
|
Force sends the recurring invoice - this option is only available when the recurring invoice is in a draft state.
|
||||||
|
- `restore`
|
||||||
|
Restores the recurring invoice from an archived or deleted state.
|
||||||
|
- `archive`
|
||||||
|
Archives the recurring invoice. The recurring invoice will not fire in this state.
|
||||||
|
- `delete`
|
||||||
|
Deletes a recurring invoice.
|
||||||
|
|
||||||
|
required: true
|
||||||
|
ids:
|
||||||
|
required: true
|
||||||
|
type: array
|
||||||
|
items:
|
||||||
|
description: "Array of hashed IDs to be bulk 'actioned - ['D2J234DFA','D2J234DFA','D2J234DFA']"
|
||||||
|
type: string
|
||||||
|
example:
|
||||||
|
action: start
|
||||||
|
ids: "['D2J234DFA','D2J234DFA','D2J234DFA']"
|
||||||
responses:
|
responses:
|
||||||
200:
|
200:
|
||||||
description: "The RecurringInvoice response"
|
description: "The RecurringInvoice response"
|
||||||
@ -12396,7 +12423,7 @@ paths:
|
|||||||
get:
|
get:
|
||||||
deprecated: true
|
deprecated: true
|
||||||
tags:
|
tags:
|
||||||
- recurring_invoices
|
- Recurring Invoices
|
||||||
summary: "Custom recurring invoice action"
|
summary: "Custom recurring invoice action"
|
||||||
description: "Performs a custom action on an RecurringInvoice.\n\n The current range of actions are as follows\n - clone_to_RecurringInvoice\n - clone_to_quote\n - history\n - delivery_note\n - mark_paid\n - download\n - archive\n - delete\n - email"
|
description: "Performs a custom action on an RecurringInvoice.\n\n The current range of actions are as follows\n - clone_to_RecurringInvoice\n - clone_to_quote\n - history\n - delivery_note\n - mark_paid\n - download\n - archive\n - delete\n - email"
|
||||||
operationId: actionRecurringInvoice
|
operationId: actionRecurringInvoice
|
||||||
@ -12445,7 +12472,7 @@ paths:
|
|||||||
"/api/v1/recurring_invoice/{invitation_key}/download":
|
"/api/v1/recurring_invoice/{invitation_key}/download":
|
||||||
get:
|
get:
|
||||||
tags:
|
tags:
|
||||||
- recurring_invoices
|
- Recurring Invoices
|
||||||
summary: "Download recurring invoice PDF"
|
summary: "Download recurring invoice PDF"
|
||||||
description: "Downloads a specific invoice"
|
description: "Downloads a specific invoice"
|
||||||
operationId: downloadRecurringInvoice
|
operationId: downloadRecurringInvoice
|
||||||
@ -12482,7 +12509,7 @@ paths:
|
|||||||
"/api/v1/recurring_invoices/{id}/upload":
|
"/api/v1/recurring_invoices/{id}/upload":
|
||||||
put:
|
put:
|
||||||
tags:
|
tags:
|
||||||
- recurring_invoices
|
- Recurring Invoices
|
||||||
summary: "Add recurring invoice document"
|
summary: "Add recurring invoice document"
|
||||||
description: "Handles the uploading of a document to a recurring_invoice"
|
description: "Handles the uploading of a document to a recurring_invoice"
|
||||||
operationId: uploadRecurringInvoice
|
operationId: uploadRecurringInvoice
|
||||||
@ -17296,7 +17323,7 @@ tags:
|
|||||||
- name: invoices
|
- name: invoices
|
||||||
description: |
|
description: |
|
||||||
Endpoint definitions for interacting with invoices.
|
Endpoint definitions for interacting with invoices.
|
||||||
- name: recurring_invoices
|
- name: Recurring Invoices
|
||||||
description: |
|
description: |
|
||||||
Endpoint definitions for interacting with recurring_invoices.
|
Endpoint definitions for interacting with recurring_invoices.
|
||||||
- name: payments
|
- name: payments
|
||||||
|
@ -14,7 +14,7 @@ tags:
|
|||||||
- name: invoices
|
- name: invoices
|
||||||
description: |
|
description: |
|
||||||
Endpoint definitions for interacting with invoices.
|
Endpoint definitions for interacting with invoices.
|
||||||
- name: recurring_invoices
|
- name: Recurring Invoices
|
||||||
description: |
|
description: |
|
||||||
Endpoint definitions for interacting with recurring_invoices.
|
Endpoint definitions for interacting with recurring_invoices.
|
||||||
- name: payments
|
- name: payments
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
/api/v1/recurring_invoices:
|
/api/v1/recurring_invoices:
|
||||||
get:
|
get:
|
||||||
tags:
|
tags:
|
||||||
- recurring_invoices
|
- Recurring Invoices
|
||||||
summary: "List recurring invoices"
|
summary: "List recurring invoices"
|
||||||
description: |
|
description: |
|
||||||
Lists invoices with the option to chain multiple query parameters allowing fine grained filtering of the list.
|
Lists invoices with the option to chain multiple query parameters allowing fine grained filtering of the list.
|
||||||
@ -72,7 +72,7 @@
|
|||||||
$ref: "#/components/responses/default"
|
$ref: "#/components/responses/default"
|
||||||
post:
|
post:
|
||||||
tags:
|
tags:
|
||||||
- recurring_invoices
|
- Recurring Invoices
|
||||||
summary: "Create recurring invoice"
|
summary: "Create recurring invoice"
|
||||||
description: "Adds a Recurring Invoice to the system"
|
description: "Adds a Recurring Invoice to the system"
|
||||||
operationId: storeRecurringInvoice
|
operationId: storeRecurringInvoice
|
||||||
@ -106,7 +106,7 @@
|
|||||||
"/api/v1/recurring_invoices/{id}":
|
"/api/v1/recurring_invoices/{id}":
|
||||||
get:
|
get:
|
||||||
tags:
|
tags:
|
||||||
- recurring_invoices
|
- Recurring Invoices
|
||||||
summary: "Show recurring invoice"
|
summary: "Show recurring invoice"
|
||||||
description: "Displays an RecurringInvoice by id"
|
description: "Displays an RecurringInvoice by id"
|
||||||
operationId: showRecurringInvoice
|
operationId: showRecurringInvoice
|
||||||
@ -146,7 +146,7 @@
|
|||||||
$ref: "#/components/responses/default"
|
$ref: "#/components/responses/default"
|
||||||
put:
|
put:
|
||||||
tags:
|
tags:
|
||||||
- recurring_invoices
|
- Recurring Invoices
|
||||||
summary: "Update recurring invoice"
|
summary: "Update recurring invoice"
|
||||||
description: "Handles the updating of an RecurringInvoice by id"
|
description: "Handles the updating of an RecurringInvoice by id"
|
||||||
operationId: updateRecurringInvoice
|
operationId: updateRecurringInvoice
|
||||||
@ -186,7 +186,7 @@
|
|||||||
$ref: "#/components/responses/default"
|
$ref: "#/components/responses/default"
|
||||||
delete:
|
delete:
|
||||||
tags:
|
tags:
|
||||||
- recurring_invoices
|
- Recurring Invoices
|
||||||
summary: "Delete recurring invoice"
|
summary: "Delete recurring invoice"
|
||||||
description: "Handles the deletion of an RecurringInvoice by id"
|
description: "Handles the deletion of an RecurringInvoice by id"
|
||||||
operationId: deleteRecurringInvoice
|
operationId: deleteRecurringInvoice
|
||||||
@ -223,7 +223,7 @@
|
|||||||
"/api/v1/recurring_invoices/{id}/edit":
|
"/api/v1/recurring_invoices/{id}/edit":
|
||||||
get:
|
get:
|
||||||
tags:
|
tags:
|
||||||
- recurring_invoices
|
- Recurring Invoices
|
||||||
summary: "Edit recurring invoice"
|
summary: "Edit recurring invoice"
|
||||||
description: "Displays an RecurringInvoice by id"
|
description: "Displays an RecurringInvoice by id"
|
||||||
operationId: editRecurringInvoice
|
operationId: editRecurringInvoice
|
||||||
@ -265,7 +265,7 @@
|
|||||||
/api/v1/recurring_invoices/create:
|
/api/v1/recurring_invoices/create:
|
||||||
get:
|
get:
|
||||||
tags:
|
tags:
|
||||||
- recurring_invoices
|
- Recurring Invoices
|
||||||
summary: "Blank recurring invoice"
|
summary: "Blank recurring invoice"
|
||||||
description: "Returns a blank object with default values"
|
description: "Returns a blank object with default values"
|
||||||
operationId: getRecurringInvoicesCreate
|
operationId: getRecurringInvoicesCreate
|
||||||
@ -298,25 +298,52 @@
|
|||||||
/api/v1/recurring_invoices/bulk:
|
/api/v1/recurring_invoices/bulk:
|
||||||
post:
|
post:
|
||||||
tags:
|
tags:
|
||||||
- recurring_invoices
|
- Recurring Invoices
|
||||||
summary: "Bulk recurring invoice actions"
|
summary: "Bulk recurring invoice actions"
|
||||||
description: ""
|
description: |
|
||||||
|
There are multiple actions that are available including:
|
||||||
|
|
||||||
operationId: bulkRecurringInvoices
|
operationId: bulkRecurringInvoices
|
||||||
parameters:
|
parameters:
|
||||||
- $ref: "#/components/parameters/X-API-TOKEN"
|
- $ref: "#/components/parameters/X-API-TOKEN"
|
||||||
- $ref: "#/components/parameters/X-Requested-With"
|
- $ref: "#/components/parameters/X-Requested-With"
|
||||||
- $ref: "#/components/parameters/index"
|
- $ref: "#/components/parameters/index"
|
||||||
requestBody:
|
requestBody:
|
||||||
description: "Hashed IDs"
|
description: "Bulk action details"
|
||||||
required: true
|
required: true
|
||||||
content:
|
content:
|
||||||
application/json:
|
application/json:
|
||||||
schema:
|
schema:
|
||||||
type: array
|
type: object
|
||||||
items:
|
properties:
|
||||||
description: "Array of hashed IDs to be bulk 'actioned"
|
action:
|
||||||
type: integer
|
type: string
|
||||||
example: "[0,1,2,3]"
|
description: |
|
||||||
|
The action to be performed, options include:
|
||||||
|
- `start`
|
||||||
|
Starts (or restarts) the recurring invoice. **note** if the recurring invoice has been stopped for a long time, it will attempt to catch back up firing a new Invoice every hour per interval that has been missed.
|
||||||
|
If you do not wish to have the recurring invoice catch up, you should set the next_send_date to the correct date you wish the recurring invoice to commence from.
|
||||||
|
- `stop`
|
||||||
|
Stops the recurring invoice.
|
||||||
|
- `send_now`
|
||||||
|
Force sends the recurring invoice - this option is only available when the recurring invoice is in a draft state.
|
||||||
|
- `restore`
|
||||||
|
Restores the recurring invoice from an archived or deleted state.
|
||||||
|
- `archive`
|
||||||
|
Archives the recurring invoice. The recurring invoice will not fire in this state.
|
||||||
|
- `delete`
|
||||||
|
Deletes a recurring invoice.
|
||||||
|
|
||||||
|
required: true
|
||||||
|
ids:
|
||||||
|
required: true
|
||||||
|
type: array
|
||||||
|
items:
|
||||||
|
description: "Array of hashed IDs to be bulk 'actioned - ['D2J234DFA','D2J234DFA','D2J234DFA']"
|
||||||
|
type: string
|
||||||
|
example:
|
||||||
|
action: start
|
||||||
|
ids: "['D2J234DFA','D2J234DFA','D2J234DFA']"
|
||||||
responses:
|
responses:
|
||||||
200:
|
200:
|
||||||
description: "The RecurringInvoice response"
|
description: "The RecurringInvoice response"
|
||||||
@ -343,7 +370,7 @@
|
|||||||
get:
|
get:
|
||||||
deprecated: true
|
deprecated: true
|
||||||
tags:
|
tags:
|
||||||
- recurring_invoices
|
- Recurring Invoices
|
||||||
summary: "Custom recurring invoice action"
|
summary: "Custom recurring invoice action"
|
||||||
description: "Performs a custom action on an RecurringInvoice.\n\n The current range of actions are as follows\n - clone_to_RecurringInvoice\n - clone_to_quote\n - history\n - delivery_note\n - mark_paid\n - download\n - archive\n - delete\n - email"
|
description: "Performs a custom action on an RecurringInvoice.\n\n The current range of actions are as follows\n - clone_to_RecurringInvoice\n - clone_to_quote\n - history\n - delivery_note\n - mark_paid\n - download\n - archive\n - delete\n - email"
|
||||||
operationId: actionRecurringInvoice
|
operationId: actionRecurringInvoice
|
||||||
@ -392,7 +419,7 @@
|
|||||||
"/api/v1/recurring_invoice/{invitation_key}/download":
|
"/api/v1/recurring_invoice/{invitation_key}/download":
|
||||||
get:
|
get:
|
||||||
tags:
|
tags:
|
||||||
- recurring_invoices
|
- Recurring Invoices
|
||||||
summary: "Download recurring invoice PDF"
|
summary: "Download recurring invoice PDF"
|
||||||
description: "Downloads a specific invoice"
|
description: "Downloads a specific invoice"
|
||||||
operationId: downloadRecurringInvoice
|
operationId: downloadRecurringInvoice
|
||||||
@ -429,7 +456,7 @@
|
|||||||
"/api/v1/recurring_invoices/{id}/upload":
|
"/api/v1/recurring_invoices/{id}/upload":
|
||||||
put:
|
put:
|
||||||
tags:
|
tags:
|
||||||
- recurring_invoices
|
- Recurring Invoices
|
||||||
summary: "Add recurring invoice document"
|
summary: "Add recurring invoice document"
|
||||||
description: "Handles the uploading of a document to a recurring_invoice"
|
description: "Handles the uploading of a document to a recurring_invoice"
|
||||||
operationId: uploadRecurringInvoice
|
operationId: uploadRecurringInvoice
|
||||||
|
Loading…
x
Reference in New Issue
Block a user