Odoo is the world's easiest all-in-one management software. It includes hundreds of business apps:
CRM | e-Commerce | Accounting | Inventory | PoS | Project management | MRP | etc.
I've an invoice, and want to change it's status from draft to open
I'm using this class: https://github.com/tejastank/openerp-php-connector
So this is my code:
$odoo->workflow('account.invoice', 'invoice_open', 70 ); // 70 is my invoice id
But the result is always false.
This is the workflow method:
$client = new xmlrpc_client($this->server."object");
$client->return_type = 'phpvals';
$msg = new xmlrpcmsg('exec_workflow');
$msg->addParam(new xmlrpcval($this->database, "string")); //* database name */
$msg->addParam(new xmlrpcval($this->uid, "int")); /* useid */
$msg->addParam(new xmlrpcval($this->password, "string"));/** password */
$msg->addParam(new xmlrpcval('account.invoice', "string"));/** model name where operation will held * */
$msg->addParam(new xmlrpcval('invoice_open', "string"));/** method which u like to execute */
$msg->addParam(new xmlrpcval('70', "int"));/** parameters of the methods with values.... */
$resp = $client->send($msg);
I think i'm missing something because all the other functions works great, any advise on this?
Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!
About This Community
This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.Register
Odoo Training Center
Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.Test it now
|Asked: 2/19/15, 12:44 PM|
|Seen: 881 times|
|Last updated: 3/16/15, 8:10 AM|