mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-09 03:14:30 -04:00
Fixes for transforming vendor contacts
This commit is contained in:
parent
59f5eca578
commit
43718dc139
@ -1 +1 @@
|
||||
5.5.17
|
||||
5.5.18
|
@ -139,9 +139,14 @@ class Request extends FormRequest
|
||||
$input['invitations'][$key]['id'] = $this->decodePrimaryKey($input['invitations'][$key]['id']);
|
||||
}
|
||||
|
||||
if (is_string($input['invitations'][$key]['client_contact_id'])) {
|
||||
if (array_key_exists('client_contact_id', $input['invitations'][$key]) && is_string($input['invitations'][$key]['client_contact_id'])) {
|
||||
$input['invitations'][$key]['client_contact_id'] = $this->decodePrimaryKey($input['invitations'][$key]['client_contact_id']);
|
||||
}
|
||||
|
||||
if (array_key_exists('vendor_contact_id', $input['invitations'][$key]) && is_string($input['invitations'][$key]['vendor_contact_id'])) {
|
||||
$input['invitations'][$key]['vendor_contact_id'] = $this->decodePrimaryKey($input['invitations'][$key]['vendor_contact_id']);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -129,7 +129,7 @@ class BaseTransformer
|
||||
*/
|
||||
public function hasVendor($name)
|
||||
{
|
||||
return Vendor::where('company_id', $this->company)
|
||||
return Vendor::where('company_id', $this->company->id)
|
||||
->where('is_deleted', false)
|
||||
->whereRaw("LOWER(REPLACE(`name`, ' ' ,'')) = ?", [
|
||||
strtolower(str_replace(' ', '', $name)),
|
||||
|
@ -14,8 +14,8 @@ return [
|
||||
'require_https' => env('REQUIRE_HTTPS', true),
|
||||
'app_url' => rtrim(env('APP_URL', ''), '/'),
|
||||
'app_domain' => env('APP_DOMAIN', 'invoicing.co'),
|
||||
'app_version' => '5.5.17',
|
||||
'app_tag' => '5.5.17',
|
||||
'app_version' => '5.5.18',
|
||||
'app_tag' => '5.5.18',
|
||||
'minimum_client_version' => '5.0.16',
|
||||
'terms_version' => '1.0.1',
|
||||
'api_secret' => env('API_SECRET', ''),
|
||||
|
Loading…
x
Reference in New Issue
Block a user