Odoo Help

0

I want to store the remote Ip address(client) in my DB

By
khudrath ali baig
on 1/18/14, 3:00 AM 1,089 views

I want to store the remote Ip address(client) in my DB. or I now that http.py has client ip address but how can i get the client ip address in my customized py file

------------------------------ in xml file --------------------------------

<script> $(document).ready(function(){ $(document).delegate(".oe_form_button_edit , .oe_list_add , .oe_form_button_create ",'click',function() { ipfill(); });

function ipfill() { $.getJSON("http://smart-ip.net/geoip-json?callback=?", function(data){ $('.ipcaptuaring').children().val(data.host); }); } ipfill(); }); </script>

<field name="ipaddress" class="ipcaptuaring"/>

---------------------in py file -----------------------------------

'ipaddress':fields.char('ip Address')

pradeep
on 1/18/14, 8:16 AM

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

Question tools

0 follower(s)

Stats

Asked: 1/18/14, 3:00 AM
Seen: 1089 times
Last updated: 3/16/15, 8:10 AM