/** * @covers Gacela\DataSource\Adapter\Salesforce::load */ public function testLoadGuid() { $meta = $this->object->load('Account'); $id = $meta['columns']['Id']; $this->assertAttributeEquals('guid', 'type', $id); $this->assertAttributeSame(true, 'primary', $id); $this->assertAttributeSame(18, 'length', $id); $this->assertAttributeSame(false, 'default', $id); }
public function __construct($id = false, $table = null, $ds = null) { $this->name = "Lead"; parent::__construct($id, $table, $ds); }
public function __construct($message = "", $code = 0, $fields = array()) { parent::__construct($message, $code); $this->fields = is_array($fields) ? $fields : array(); }
<?php /* |-------------------------------------------------------------------------- | Application Routes |-------------------------------------------------------------------------- | | Here is where you can register all of the routes for an application. | It's a breeze. Simply tell Laravel the URIs it should respond to | and give it the Closure to execute when that URI is requested. | */ Route::get('/', function () { return View::make('home'); }); Route::resource('orders', 'OrdersController'); Route::resource('users', 'UsersController'); Route::resource('accounts', 'AccountsController'); Route::resource('products', 'ProductsController'); Route::get('/test', function () { try { $account = Salesforce::describeLayout('Account'); // print_r(Salesforce::describeLayout('Account')); return View::make('home')->with('account', $account); // return View::make('accounts.index', compact('accounts')); } catch (Exception $e) { Log::error($e->getMessage()); die($e->getMessage() . $e->getTraceAsString()); } });
public function post($uri, $data) { $url = 'https://' . SalesforceConfig::get('salesforce.api.domain') . '/services/apexrest/' . $uri; return $this->oauth2Client->rawPostRequest($url, $data); }