Showing posts with label Odoo Studio. Show all posts
Showing posts with label Odoo Studio. Show all posts

Tuesday, 7 March 2017

How to access new version of Odoo studio ?

New versions of Odoo studio are hosted at http://runbot.odoo.com
The version after the current version (which today is version 10) is called master.

1. Select the Enterprise Edition in the dropdown:











2. Select a green build:


How to call a wizard from js in odoo ?

this.do_action({

                   type: 'ir.actions.act_window',

                  res_model: 'Model name',

                 view_mode: 'form',

                 view_type: 'form',

                 views: [[false, 'form']],

                 target: 'new',

                 context:{}
});

Tuesday, 21 February 2017

How to Make Custom Keyboard shortcuts for odoo ?

Here, i will show you some example to get custom shortcuts works in odoo. you can also override default shortcuts in odoo. as you can see for that we have to create one js file in out module. the path of the file is module / static / src / js / file_js.js
and put the below code into file .


$.shortcut = function(key, callback, args) {
    $(document).keydown(function(e) {
        if(!args) args=[]; // IE barks when args is null
        console.log(e.keyCode)
        if((e.keyCode == key.charCodeAt(0) || e.keyCode == key)) {
            callback.apply(this, args);
            return false;
        }
    });
};

                    //Edit the current object F2
$.shortcut('113', function() {
$('.oe_form_button_edit').each(function() {
if($(this).parents('div:hidden').length == 0){
$(this).trigger('click');
}
});
});


with this user can save the record with F2 button.
so as simple way we can also create record, delete record, make tree view to unlimited , remove the filter , open calendar and so many things using key board key.