mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-11-06 03:02:34 +01:00
4c23d43138
* Refactor designs to remove whitespace * enable dummy data for templating * Insert faker data into templates * Fixes for user deletion * Documentation on User controller: * Working on app setup * Files for app setup * Working on Setup * Final fixes for setup controller * Fixes for setup * Fixes for first install * Minor fixes
63 lines
1.1 KiB
PHP
63 lines
1.1 KiB
PHP
<?php
|
|
/**
|
|
* Invoice Ninja (https://invoiceninja.com)
|
|
*
|
|
* @link https://github.com/invoiceninja/invoiceninja source repository
|
|
*
|
|
* @copyright Copyright (c) 2020. Invoice Ninja LLC (https://invoiceninja.com)
|
|
*
|
|
* @license https://opensource.org/licenses/AAL
|
|
*/
|
|
|
|
namespace App\Utils\Traits;
|
|
|
|
trait BulkOptions
|
|
{
|
|
/**
|
|
* Store method in requests.
|
|
*
|
|
* @var string
|
|
*/
|
|
public static $STORE_METHOD = 'create';
|
|
|
|
/**
|
|
* Default chunk size.
|
|
*
|
|
* @var int
|
|
*/
|
|
public static $CHUNK_SIZE = 100;
|
|
|
|
/**
|
|
* Default queue for bulk processing.
|
|
*
|
|
* @var string
|
|
*/
|
|
public static $DEFAULT_QUEUE = 'bulk_processing';
|
|
|
|
/**
|
|
* Available bulk options - used in requests (eg. BulkClientRequests)
|
|
*
|
|
* @return array
|
|
* @var array
|
|
*/
|
|
public function getBulkOptions()
|
|
{
|
|
return [
|
|
'create', 'edit', 'view',
|
|
];
|
|
}
|
|
|
|
/**
|
|
* Shared rules for bulk requests.
|
|
*
|
|
* @return array
|
|
* @var array
|
|
*/
|
|
public function getGlobalRules()
|
|
{
|
|
return [
|
|
'action' => ['required'],
|
|
];
|
|
}
|
|
}
|