Enabled getting email from customer, added url() for a base url
This commit is contained in:
parent
1567806b87
commit
59302bd3e8
@ -32,6 +32,13 @@ final class API
|
|||||||
Log::debug(sprintf('%s:Intuit API for id [%s]',static::LOGKEY,$token->realm_id));
|
Log::debug(sprintf('%s:Intuit API for id [%s]',static::LOGKEY,$token->realm_id));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* STATIC */
|
||||||
|
|
||||||
|
public static function url(bool $tryprod=FALSE): string
|
||||||
|
{
|
||||||
|
return (config('app.env') == 'local' && ! $tryprod) ? 'https://app.sandbox.qbo.intuit.com/app' : 'https://app.qbo.intuit.com/app';
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Convert an Array to Curl Headers
|
* Convert an Array to Curl Headers
|
||||||
*
|
*
|
||||||
|
@ -66,6 +66,8 @@ final class Customer extends Model
|
|||||||
return object_get($this->getAttribute('MetaData'),'CreateTime');
|
return object_get($this->getAttribute('MetaData'),'CreateTime');
|
||||||
case 'updated_at':
|
case 'updated_at':
|
||||||
return object_get($this->getAttribute('MetaData'),'LastUpdatedTime');
|
return object_get($this->getAttribute('MetaData'),'LastUpdatedTime');
|
||||||
|
case 'email':
|
||||||
|
return object_get($this->getAttribute('PrimaryEmailAddr'),'Address');
|
||||||
|
|
||||||
default:
|
default:
|
||||||
return parent::__get(Arr::get($keymap,$key,$key));
|
return parent::__get(Arr::get($keymap,$key,$key));
|
||||||
|
Loading…
Reference in New Issue
Block a user