[FIX] editable listview test: set_editable was removed, pass editable as option when creating listview

bzr revid: xmo@openerp.com-20120801123449-e65apxliok8fsrvq
This commit is contained in:
Xavier Morel 2012-08-01 14:34:49 +02:00
parent 901d45b4e7
commit 8a7428d731
1 changed files with 3 additions and 6 deletions

View File

@ -240,8 +240,7 @@ $(document).ready(function () {
};
var ds = new instance.web.DataSetStatic(null, 'demo', null, [1]);
var l = new instance.web.ListView({}, ds);
l.set_editable(true);
var l = new instance.web.ListView({}, ds, false, {editable: 'top'});
l.appendTo($fix)
.pipe(l.proxy('reload_content'))
@ -305,8 +304,7 @@ $(document).ready(function () {
counter: 0,
onEvent: function (e) { this.counter++; }
};
var l = new instance.web.ListView({}, ds);
l.set_editable(true);
var l = new instance.web.ListView({}, ds, false, {editable: 'top'});
l.on('edit:before edit:after', o, o.onEvent);
l.appendTo($fix)
.pipe(l.proxy('reload_content'))
@ -326,8 +324,7 @@ $(document).ready(function () {
asyncTest('edition events: cancelling', 3, function () {
var edit_after = false;
var ds = new instance.web.DataSetStatic(null, 'demo', null, [1]);
var l = new instance.web.ListView({}, ds);
l.set_editable(true);
var l = new instance.web.ListView({}, ds, false, {editable: 'top'});
l.on('edit:before', {}, function (e) {
e.cancel = true;
});