Odoo Help

Welcome!

This community 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.

0

Mobile Web Application - JQuery XML-RPC

By
John
on 5/12/14, 12:57 PM 2,376 views

Hello, I want to make an OpenERP[saas-X][v8.0] mobile access from a web application My implementation choice could be JQuery Mobile or other JS language but most certainly will be into JS

I've notice that xml-rpc request from JQuery or JS are not accepted.

Is there a build-in API into OpenERP to make a connection?

many thanks

0
sharjeel ali shaukat
On 8/22/14, 3:03 AM

<script src="js/jquery.xmlrpc.min.js"></script> 

var user = 'admin';
            var password = 'admin';
            var dbname = 'openerpdemo';
            var authority = 'http://';
            var server = 'localhost';
            var port = '8069';
            var server_url = authority + server + ':' + port + '/xmlrpc/';

            var forcedUserValue = $.xmlrpc.force('string', user);
            var forcedPasswordValue = $.xmlrpc.force('string', password);
            var forcedDbNameValue = $.xmlrpc.force('string', dbname);

            $.xmlrpc({
                url: server_url + 'common',
                methodName: 'login',
                dataType: 'jsonrpc',
                params: [forcedDbNameValue, forcedUserValue, forcedPasswordValue],
                success: function(response, status, jqXHR) {
                     debugger;
                     alert("response:"+response+"\n"+"status:"+status+"\n"+"jqXHR:"+jqXHR+"\n");
                     
                },
                error: function(jqXHR, status, error) {
                     alert(jqXHR + '-' + status + '-' + error);
                }
            });

 

and run browser without security

u can seeexample for chrome

"chrome.exe --disable-web-security"

0
nick2474
On 11/12/14, 12:41 AM

Maybe this link can help you: http://thierry-godin.developpez.com/openerp/openerp-xmlrpc-php-en i m trying todo something from codeigniter with jquerymobile too.

Your Answer

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 community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

0 follower(s)

Stats

Asked: 5/12/14, 12:57 PM
Seen: 2376 times
Last updated: 3/16/15, 8:10 AM