mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-09 03:14:30 -04:00
Minor fixes for client required fields
This commit is contained in:
parent
b88b410c1c
commit
5673cae467
@ -28,7 +28,7 @@ class ClientFactory
|
||||
$client->public_notes = '';
|
||||
$client->balance = 0;
|
||||
$client->paid_to_date = 0;
|
||||
// $client->country_id = 4;
|
||||
$client->country_id = 840;
|
||||
$client->is_deleted = 0;
|
||||
$client->client_hash = Str::random(40);
|
||||
$client->settings = ClientSettings::defaults();
|
||||
|
@ -141,7 +141,7 @@ class RequiredClientInfo extends Component
|
||||
$_field = $this->mappings[$field['name']];
|
||||
|
||||
if (Str::startsWith($field['name'], 'client_')) {
|
||||
if (empty($this->contact->client->{$_field}) || is_null($this->contact->client->{$_field})) {
|
||||
if (empty($this->contact->client->{$_field}) || is_null($this->contact->client->{$_field}) || $this->contact->client->{$_field} = 840) {
|
||||
$this->show_form = true;
|
||||
} else {
|
||||
$this->fields[$index]['filled'] = true;
|
||||
@ -149,7 +149,7 @@ class RequiredClientInfo extends Component
|
||||
}
|
||||
|
||||
if (Str::startsWith($field['name'], 'contact_')) {
|
||||
if ((empty($this->contact->{$_field}) || is_null($this->contact->{$_field}))) {
|
||||
if ((empty($this->contact->{$_field}) || is_null($this->contact->{$_field})) || $this->contact->client->{$_field} = 840) {
|
||||
$this->show_form = true;
|
||||
} else {
|
||||
$this->fields[$index]['filled'] = true;
|
||||
|
Loading…
x
Reference in New Issue
Block a user