[BREAK] a bit more

bzr revid: fme@openerp.com-20130702115808-8j0xbgnswa5yyetp
This commit is contained in:
Fabien Meghazi 2013-07-02 13:58:08 +02:00
parent 915670afb5
commit fe95430451
3 changed files with 5 additions and 6 deletions

View File

@ -10,13 +10,12 @@ instance.website.EditorBar = instance.web.Widget.extend({
start: function() {
var self = this;
var r = this._super.apply(this, arguments);
this.$container = $(this.container);
// this.$container.addClass('oe_website_editor_container');
Aloha.ready(function() {
self.$container.find('[data-oe-model]').aloha(); //.attr('contentEditable', 'true').addClass('oe_editable');
Aloha.jQuery('[data-oe-model]').aloha(); //.attr('contentEditable', 'true').addClass('oe_editable');
self.$('button').prop('disabled', true);
Aloha.bind('aloha-editable-activated', function (ev, args) {
debugger
console.log(ev, args);
});
});
// .click(function (e) {

View File

@ -1,4 +1,4 @@
(function() {
Aloha.ready(function() {
// Init headless webclient
// TODO: Webclient research : use iframe embedding mode
// Meanwhile, let's HACK !!!
@ -29,4 +29,4 @@
editor.prependTo($('body'));
$('body').css('padding-top', editor.$el.outerHeight());
});
})();
});

View File

@ -14,7 +14,6 @@
<link rel='stylesheet' href='//fonts.googleapis.com/css?family=Open+Sans:300italic,400italic,600italic,700italic,400,300,600,700'/>
<t t-raw="script"/>
<t t-if="editable">
<script type="text/javascript" src="/website/static/src/js/website_bootstrap.js"></script>
<link href="http://cdn.aloha-editor.org/latest/css/aloha.css" rel="stylesheet" type="text/css" />
<script>
openerp.$ = jQuery;
@ -31,6 +30,7 @@
Aloha.jQuery('.editable').aloha();
});
</script>
<script type="text/javascript" src="/website/static/src/js/website_bootstrap.js"></script>
</t>
</head>
<body class="oe_website">