2013-02-05 13:47:11 +00:00
|
|
|
|
2013-08-19 12:24:59 +00:00
|
|
|
(function() {
|
|
|
|
|
|
|
|
var tmpQWeb2 = window.QWeb2;
|
|
|
|
|
2013-02-05 13:47:11 +00:00
|
|
|
require.config({
|
|
|
|
context: "oelivesupport",
|
2013-08-12 15:10:36 +00:00
|
|
|
baseUrl: {{url | json}},
|
|
|
|
paths: {
|
|
|
|
jquery: "im_livechat/static/ext/static/lib/jquery/jquery",
|
|
|
|
underscore: "im_livechat/static/ext/static/lib/underscore/underscore",
|
|
|
|
qweb2: "im_livechat/static/ext/static/lib/qweb/qweb2",
|
|
|
|
openerp: "web/static/src/js/openerpframework",
|
2013-08-12 15:21:02 +00:00
|
|
|
"jquery.achtung": "im_livechat/static/ext/static/lib/jquery-achtung/src/ui.achtung",
|
2013-08-12 15:10:36 +00:00
|
|
|
livesupport: "im_livechat/static/ext/static/js/livesupport",
|
2013-08-19 14:09:08 +00:00
|
|
|
im_common: "im/static/src/js/im_common"
|
2013-08-12 15:10:36 +00:00
|
|
|
},
|
2013-02-05 13:47:11 +00:00
|
|
|
shim: {
|
|
|
|
underscore: {
|
|
|
|
init: function() {
|
|
|
|
return _.noConflict();
|
|
|
|
},
|
|
|
|
},
|
2013-08-12 15:10:36 +00:00
|
|
|
qweb2: {
|
|
|
|
init: function() {
|
2013-08-19 12:24:59 +00:00
|
|
|
var QWeb2 = window.QWeb2;
|
|
|
|
window.QWeb2 = tmpQWeb2;
|
2013-08-12 15:10:36 +00:00
|
|
|
return QWeb2;
|
|
|
|
},
|
|
|
|
},
|
2013-02-12 14:13:35 +00:00
|
|
|
"jquery.achtung": {
|
|
|
|
deps: ['jquery'],
|
|
|
|
},
|
2013-02-05 13:47:11 +00:00
|
|
|
},
|
|
|
|
})(["livesupport", "jquery"], function(livesupport, jQuery) {
|
|
|
|
jQuery.noConflict();
|
2013-08-14 14:31:15 +00:00
|
|
|
console.log("loaded live support");
|
2013-07-26 09:04:45 +00:00
|
|
|
livesupport.main({{url | json}}, {{db | json}}, "public", "public", {{channel | json}}, {
|
2013-02-11 09:55:10 +00:00
|
|
|
buttonText: {{buttonText | json}},
|
|
|
|
inputPlaceholder: {{inputPlaceholder | json}},
|
|
|
|
defaultMessage: {{(defaultMessage or None) | json}},
|
2013-03-15 11:21:53 +00:00
|
|
|
auto: window.oe_im_livechat_auto || false,
|
2013-02-12 15:57:56 +00:00
|
|
|
userName: {{userName | json}} || undefined,
|
2013-02-11 09:55:10 +00:00
|
|
|
});
|
2013-02-05 13:47:11 +00:00
|
|
|
});
|
2013-08-19 12:24:59 +00:00
|
|
|
|
|
|
|
})();
|