diff options
| author | Thibault Delavallée <tde@openerp.com> | 2012-02-08 17:42:29 +0100 |
|---|---|---|
| committer | Thibault Delavallée <tde@openerp.com> | 2012-02-08 17:42:29 +0100 |
| commit | 5363de0632070e03d91efccab4a4930ffbdd5bbc (patch) | |
| tree | 0044305a20db73dc3ae1c2b73cae4be77072253a /addons/mail/static/src | |
| parent | a80f887e5b6dfbc43ed3d62da51a177effdef378 (diff) | |
[ADD] Added menu entry for the wall; refactored menu name, ids and code in files; added js definition for the wall
bzr revid: tde@openerp.com-20120208164229-esmg4pv5qjn8s8o1
Diffstat (limited to 'addons/mail/static/src')
| -rw-r--r-- | addons/mail/static/src/js/mail.js | 18 | ||||
| -rw-r--r-- | addons/mail/static/src/xml/mail.xml | 3 |
2 files changed, 19 insertions, 2 deletions
diff --git a/addons/mail/static/src/js/mail.js b/addons/mail/static/src/js/mail.js index 4157aef5a33..184f4fbada5 100644 --- a/addons/mail/static/src/js/mail.js +++ b/addons/mail/static/src/js/mail.js @@ -1,13 +1,14 @@ openerp.mail = function(session) { var mail = session.mail = {}; - + + /* Add ThreadView widget to registry */ session.web.form.widgets.add( 'ThreadView', 'openerp.mail.ThreadView'); session.web.page.readonly.add( 'ThreadView', 'openerp.mail.ThreadView'); - /* ThreadView Widget: thread of comments */ + /* ThreadView widget: thread of comments */ mail.ThreadView = session.web.form.Field.extend({ // QWeb template to use when rendering the object template: 'ThreadView', @@ -86,6 +87,19 @@ openerp.mail = function(session) { }, }); + /* Add WallView widget to registry */ + session.web.client_actions.add('mail.all_feeds', 'session.mail.WallView'); + + /* WallView widget: a wall of messages */ + mail.WallView = session.web.Widget.extend({ + // QWeb template to use when rendering the object + template: 'WallView', + + init: function() { + this._super.apply(this, arguments); + alert('Cacaboudin !!'); + }, + }); }; // vim:et fdc=0 fdl=0 foldnestmax=3 fdm=syntax: diff --git a/addons/mail/static/src/xml/mail.xml b/addons/mail/static/src/xml/mail.xml index 376e8042a06..e9895ce4c7b 100644 --- a/addons/mail/static/src/xml/mail.xml +++ b/addons/mail/static/src/xml/mail.xml @@ -35,5 +35,8 @@ </p> </div> </t> + + <div t-name="WallView" class="oe_mail_wall"> + </div> </template>
\ No newline at end of file |
