roykin/erp/config.php
2017-06-14 11:41:31 +02:00

50 lines
1.1 KiB
PHP
Executable File

<?php
if (!defined('ERP_ENABLED') || !ERP_ENABLED) {
die('erp disabled');
}
if (!defined('ERP_URL') || !defined('ERP_DB') || !defined('ERP_USERNAME') || !defined('ERP_PASSWORD')) {
die('ERP not found');
}
ini_set("memory_limit","256M");
// CONFIGURATION
// $url = 'http://roykin.erp-odoo.fr:8069';
// $url = 'http://137.74.168.224:8069';
// $db = 'roykin';
// $username = 'admin';
// $password = 'AdmiROYkin2016';
$url = ERP_URL;
$db = ERP_DB;
$username = ERP_USERNAME;
$password = ERP_PASSWORD;
// Load Demo Data
// $info = ripcord::client('https://demo.odoo.com/start')->start();
// list($url, $db, $username, $password) = array($info['host'], $info['database'], $info['user'], $info['password']);
$common = ripcord::client("$url/xmlrpc/2/common");
$common->version();
$uid = $common->authenticate($db, $username, $password, array());
$assoc_attr = [
1 => 26,
3 => 28,
4 => 29,
5 => 30,
6 => 31,
10 => 27,
28 => 26,
27 => 28,
26 => 29,
25 => 30,
24 => 31,
40 => 26,
35 => 27,
44 => 29,
46 => 31,
43 => 28
];