mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-05-24 02:14:21 -04:00
email report template
This commit is contained in:
parent
01e232cad2
commit
3bf0f642e1
@ -67,7 +67,45 @@ class EmailReport
|
||||
*/
|
||||
public string $end_date = '';
|
||||
|
||||
/******************************* Parameters **********************************/
|
||||
|
||||
/** @var string $report_name */
|
||||
|
||||
public string $report_name = '';
|
||||
|
||||
/**
|
||||
* Optional array of report keys for
|
||||
* filter the columns of the report
|
||||
*
|
||||
* @var array $report_keys
|
||||
*
|
||||
* */
|
||||
public array $report_keys = [];
|
||||
|
||||
/** Profit Loss Parameters */
|
||||
public bool $is_income_billed = true;
|
||||
|
||||
public bool $is_expense_billed = true;
|
||||
|
||||
public bool $include_tax = true;
|
||||
|
||||
/**
|
||||
* Comma separated string of statuses for filtering the Invoice report
|
||||
*
|
||||
* all
|
||||
* draft
|
||||
* sent
|
||||
* paid
|
||||
* unpaid
|
||||
* overdue
|
||||
* viewed
|
||||
*
|
||||
* */
|
||||
public string $status = '';
|
||||
|
||||
/**
|
||||
* Comma separated list of product.product_keys
|
||||
* to filter the report by
|
||||
*/
|
||||
public string $product_key = ''
|
||||
}
|
||||
|
@ -22,7 +22,10 @@ class ProfitLossRequest extends Request
|
||||
*/
|
||||
public function authorize() : bool
|
||||
{
|
||||
return auth()->user()->isAdmin();
|
||||
/** @var \App\Models\User $user */
|
||||
$user = auth()->user();
|
||||
|
||||
return $user->isAdmin();
|
||||
}
|
||||
|
||||
public function rules()
|
||||
|
@ -47,7 +47,7 @@ class StoreSchedulerRequest extends Request
|
||||
'parameters.end_date' => ['bail', 'sometimes', 'date:Y-m-d', 'required_if:parameters.date_rate,custom', 'after_or_equal:parameters.start_date'],
|
||||
'parameters.entity' => ['bail', 'sometimes', 'string', 'in:invoice,credit,quote,purchase_order'],
|
||||
'parameters.entity_id' => ['bail', 'sometimes', 'string'],
|
||||
'parameters.report_name' => ['bail','sometimes', 'string', 'required_if:template,email_report', 'in:ar_detailed,ar_summary,client_balance,tax_summary,profitloss,client_sales,user_sales,product_sales,clients,client_contacts,credits,documents,expenses,invoices,invoice_items,quotes,quote_items,recurring_invoices,payments,products,tasks'],
|
||||
'parameters.report_name' => ['bail','sometimes', 'string', 'required_if:template,email_report','in:ar_detailed,ar_summary,client_balance,tax_summary,profitloss,client_sales,user_sales,product_sales,clients,client_contacts,credits,documents,expenses,invoices,invoice_items,quotes,quote_items,recurring_invoices,payments,products,tasks'],
|
||||
'parameters.date_key' => ['bail','sometimes', 'string'],
|
||||
];
|
||||
|
||||
|
@ -14,8 +14,6 @@ return new class extends Migration {
|
||||
if(!Gateway::find(61) && Ninja::isHosted()) {
|
||||
|
||||
$fields = new \stdClass;
|
||||
$fields->clientId = "";
|
||||
$fields->secret = "";
|
||||
$fields->testMode = false;
|
||||
|
||||
$paypal = new Gateway;
|
||||
|
Loading…
x
Reference in New Issue
Block a user