mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-05-24 02:14:21 -04:00
* Refactor pivot table accessors * Add select2 for client - country selector * Fixes for client contact update * implement ctrans() function across application * Increase custom fields to 4 across the application * Refactor: remove repos calling other repos, implement 4 custom values across application * include querying the custom values in the client list * Fix null custom value labels * Scaffold for client - show view * Working on Client Show
42 lines
773 B
PHP
42 lines
773 B
PHP
<?php
|
|
|
|
namespace App\DataMapper;
|
|
|
|
use App\Models\Client;
|
|
|
|
class DefaultSettings
|
|
{
|
|
|
|
public static $per_page = 25;
|
|
|
|
public static function userSettings() : \stdClass
|
|
{
|
|
return (object)[
|
|
class_basename(Client::class) => self::clientSettings(),
|
|
];
|
|
}
|
|
|
|
private static function clientSettings() : \stdClass
|
|
{
|
|
|
|
return (object)[
|
|
'datatable' => (object) [
|
|
'per_page' => self::$per_page,
|
|
'column_visibility' => (object)[
|
|
'name' => true,
|
|
'contact' => true,
|
|
'email' => true,
|
|
'client_created_at' => true,
|
|
'last_login' => true,
|
|
'balance' => true,
|
|
'custom_value1' => false,
|
|
'custom_value2' => true,
|
|
'custom_value3' => false,
|
|
'custom_value4' => false,
|
|
]
|
|
]
|
|
];
|
|
|
|
}
|
|
|
|
} |