summaryrefslogtreecommitdiff
path: root/addons/im_livechat/static/src/xml
AgeCommit message (Collapse)Author
2019-01-31[FIX] mail: show pinned livechats on discuss app sidebarAlexandre Kühn
Revision on https://github.com/odoo/odoo/commit/a669d89565ad9904d07886b00665e3940ce04665 The commit above changed the template of the Discuss app in order to add some features, such as the channel "quick search". The livechat module extends Discuss app to support livechats. However, the commit above didn't update it correctly. As a result, pinned livechats were not shown in the sidebar. This commit fixes the issue, so pinned livechats should now always be visible in the sidebar. closes odoo/odoo#30738
2018-07-09[FIX] *: fix some side-effects of ↵qsm-odoo
https://github.com/odoo/odoo/commit/9de1bc0eef6f5bfaa2a8d745431caa361ae91548 - JS Modals were not correctly built anymore, their .modal-body element was duplicated and many without-effect JS lines were introduced (as a side effect, the form view design was broken when inside modals) - Tests were changed to make bugs go unnoticed. For example, the media dialog functionnality was entirely broken because the .modal-dialog element was not receiving the correct class anymore. - The JS translation function is _t, not _ - Do not use the <title/> tag as a regular DOM element, it is meant to be unique, in the <head/> section - CSS rules were added to the utils.scss file, which is meant to contain functions and mixins, otherwise, the rule is duplicated in every asset - Some icons were still broken, as missed by https://github.com/odoo/odoo/commit/f90cf060a3cfeb37a67bec83264c0aaab8892b56 - Tests were changed to use [role="dialog"]/footer/header in their selectors without any reason, this commit restores some of that to avoid rebase conflicts with the BS4 work. - ... Note: other elements should still be discussed, like the direct use of the 'o_form_label' class in views definition... but those do not cause direct problems.
2018-07-02[REF] mail: JS mail refactoringAlexandre Kühn
---------------------- Summary ---------------------- The purpose of this commit is to improve the JS code of the `mail` module. It applies the new coding guidelines and makes some changes on the design of some modules, such as the old ChatManager module. Here is a short summary of the changes that have been made: 1. New coding guidelines - snake_case to camelCase - prefix private attributes and methods with '_' - jsdoc on most methods - one class per module 2. Rename/Merge some classes - 'chat manager' becomes 'mail manager' (internal) and 'mail service' (external) - 'chat window manager' is now included in mail manager - 'thread' widget now named 'thread widget' 3. New model abstraction for mail objects: - modules 'mail.model.*' - modeling: 0..1 0..1 * * ThreadWindow <------> Thread <-------> Message / \ / \ Thread With Cache Document Thread / | \ / | \ Mailbox Channel Support Channel | | DM - Thread: the superclass of threads. - ThreadWindow: the window component of a thread. - Message: mail objects representing messages. - Thread With Cache: threads that can be used with search view (Discuss app compatible). - Document Thread: represents the thread part of a chatter. - Mailbox: represents what was previously called 'static' channel, e.g. 'Inbox'. - Channel: mail objects representing channels, including livechat. - DM: special kind of Channel for 1:1 communication in the backend. - Support Channel: special channel for im_support module. This new modeling approach let us easily add features on all threads, such as the possibility to put any thread in a small window. ---------------------- Known issues ---------------------- [Already Present in Master] 1. When the Discuss app is in the background with 'Inbox' as the selected Thread, when clicking on a document thread preview in the messaging menu of the systray, the rainbow man appears. 2. When a document with the chatter is in the background, when receiving an inbox notification from this document thread, the document thread is automatically marked as read, which removes the notification right away. 3. Sometimes, opening a DM window from the "blank" thread window does not work. 4. Reply-to feature on Inbox is not working: no message is sent in the document thread. 5. On the first login of admin user with demo data, the inbox counter is wrong (it displays 6, instead of 3). Explanation after investigation: > On page load, it fetches the correct number of Inbox messages (3), but the server notifies of 3 needaction messages right away, so it wrongly assumes these are new needaction messages. > Not possible for web client to detect that these messages should not increment the Inbox counter while keeping same API. 6. Notifications for new document thread messages only work when the user sets 'handle with Odoo' for the Notification Management in the preferences. > due to notifications on the longpoll bus for document thread messages that come from needaction notifications. > requires server-side changes to send notification on the longpoll bus to mentionned user. [New] 7. When receiving a message on a unjoined channel, thread window flickers ('open' > 'close' > 'open') Explanation after investigation: > JS logic: a) On auto-join, ask server to join the channel and get channel infos. b) The info tells the channel is not detached, but JS code makes decision to detach it, and tells server the channel is now detached. c) From (a), server notifies on longpoll bus the state of channel, which is not detached. The web client thinks that the window state of the channel has been changed somewhere else, and the channel is now closed. d) From (b), server notifies on longpoll bus the state of channel, which is detached. The web client opens the thread window of this channel. > The flicker didn't occur before refactoring because the web client was only updating the model of channel when it receives the longpoll notification. > Server behaviour on 1st longpoll notification is necessary for cross-tab synchronization for channel window state. > New design implies that model and view should be synchronized, hence the issue now. > Solution: remove server-side thread window synchronization and replace with client-side synchronization. ---------------------- Hacks ---------------------- The module `im_livechat` now uses mail objects that are compatible with Message and Window objects: Modeling for messages: AbstractMessage / \ / \ LivechatMessage Message - AbstractMessage: message compatible with the thread widget. - LivechatMessage: message used by im_livechat. - Message: message used with the mail manager. Modeling for thread windows: AbstractThreadWindow / \ / \ LivechatWindow ThreadWindow - AbstractThreadWindow: behaviour share between all types of thread windows. - LivechatWindow: window used by im_livechat. - ThreadWindow: window used with mail_manager. The reason for these hacks are twofold: 1. Use the thread widget in the frontend and livechat external lib bundles. 2. Do not have a dependency with the mail manager in the frontend and external lib bundles.
2018-06-27[MOV] web,im_livechat: Move clipboard widget to webYannick Tivisse
2018-06-22[IMP] Improve compatibility with screen readers (accessibility) (#24574)kujiu
Today, Odoo is really tricky to use without seeing the screen, it must be improved to be usable. This PR forbid to use labels without a "for" attribute, add some title, rule and aria attributes in HTML. With that, Odoo will be fully usable with a screen reader. * [IMP] Labels must have a for attribute. Improve accessibility. * [IMP] Better error message when trying to read a missing cached value * [FIX] Add some aria-label and title attributes for screen readers. * [FIX] Template name is not included in the error message in case of SyntaxError in QWeb * [FIX] Improve the Tour failed at step error message to be more explicit. * [IMP] Add aria-labels * [FIX] Add missing aria-label on failing test * [IMP] aria-hidden means hidden. Fix all bad aria-hidden and hide aria-hidden for all. * [IMP] Color names on kanban views and many2many tags * [IMP] Add some checks on views for accessibility. * [IMP] Add `alt` attribute on `img` tags. * [IMP] Add aria-label and title on non-described icons * [IMP] Add button role to widgets with btn class * [IMP] Translate aria and formatted attributes. * [IMP] Remove wrong aria-labelledby * [IMP] Add menu role on dropdowns * [IMP] Buttons must be focusable * [IMP] Add aria attributes on progress bars * [IMP] Improve accessibility of basic widgets * [IMP] Change main layout to more semantic tags * [IMP] Add menuitem role when missing * [IMP] Remove wrong role='presentation' * [IMP] Improve accessibility of tab panels * [IMP] Add aria-invalid on invalid fields * [IMP] Add aria-sort on ordered columns * [IMP] Add role on alerts * [IMP] Use dialog role, header, main and footer tags for modals * [IMP] Add labels on o_status * [IMP] Improve accessibility of kanban view with feeds and articles * [IMP] Add alerts in case of new messages * [IMP] Add widget, navigation or img role to aria-labelled items
2018-05-18[IMP] im_livechat: improve live chat rating screenPrakash Prajapati
Currently, layout for rating a chat is not looking so well. This commit improves the rating layout. It will - Center the content (including smileys) - Enlarge the fonts (a little bit) - Underline the link instead of using italics (more intuitive) Task : 1838321 PR : #24413
2018-02-01[REF][IMP] *: mail js refactoringAaron Bohy
This commit improves the JS code of the mail module, which comes maily from the new coding guidelines and the addition of "JS services". JS services are important objects that do not fit well in the component tree, such as chat_manager or ajax. The benefits of JS services are improved readability of the code, reduced coupling, and more testable modules. In particular, discuss was hard to Summary of the changes: - ClientAction has been renamed into Discuss - Clear instantiation of chatManager - New coding guidelines in most mail modules - JS Services can interact with each other - Chat Manager and Window Manager are services - Window Manager renamed to Chat Window Manager - bus.bus is now encapsulated in Bus Service (a service) - The test infrastructure has been tweaked with JS Services - Chat Mixin has been removed A future improvement would be to translate some 'trigger' into 'trigger_up'.
2017-10-02[FIX] mail: do not translate channel_iconsMartin Trigaux
2017-09-15[IMP] im_livechat, mail: Discuss UI in mobileAaron Bohy
- Extract mobile specific code for the client action to a specific file - Massive clean of less rules - Unify channels preview of the systray dropdown and the mobile UI of Discuss - Ensure to only load the last message of each channel in mobile, as this is not used in desktop (unless the user opens the systray menu) - Make livechat available in Discuss mobile UI
2017-09-14[IMP] im_livechat: add copy to clipboard for the website live chat widget codeMitali Patel
This commit adds 2 buttons to copy directly the code needed to add the livechat in the website.
2016-11-16[FIX] im_livechat: correct rating smiley and value for bad ratingJérome Maes
2015-12-29[FIX] im_livechat,mail: don't translate html data-type argumentAaron Bohy
as it is only there for a technical purpose (used in JS to bind event handlers)
2015-12-11[IMP] im_livechat: allow to close chat without feedbackNicolas Martinelli
opw-658973
2015-10-16[IMP] mail,im_livechat: client action sidebar: 'unsubcribe' crossAaron Bohy
displayed for all channels
2015-10-06[FIX] im_livechat: livechat restored after refactoring of mailAaron Bohy
Refactoring of the livechat itself and integration in the new architecture of mail since its large refactoring. Joint work with ged
2015-10-01[FIX] im_livechat: temporarily disable client codeGéry Debongnie
This is done because of large mail refactoring and the need of quick release. We will rewrite it asap.
2015-09-01[IMP] im_livechat : refactoring + improving performance by removing rpc callJérome Maes
2015-09-01[FIX] mail,im_livechat: terminology: untoggle -> closeAaron Bohy
2015-09-01[REF] im_livechat : refactoring, make it compatbile with the nw mail module, ↵Jérome Maes
change reporting sql view (split them in 2), adapt view, ...
2015-03-05[FIX] im_livechat : display the rating smileys from the origin serverJérome Maes
2015-02-26[FIX] im_livechat : remove the cookie when close anonymous conversation, and ↵Jérome Maes
prefix image link by server url in template
2015-02-04[IMP] livechat : when rating conversation, click on smiley save the rating ↵Jérome Maes
value. Only display texterea when clicking on red smiley.
2015-01-08[IMP] im_livechat : make the feedback for livechat a standart feature using ↵Jérome Maes
the rating mixin. Create a dependancy to rating.
2014-10-03[IMP] im_chat, im_livechat : add reporting view, quit conversation, option ↵Jérome Maes
dropdown menu, feedback for live support, better access rules and shortcode model.
2014-06-29MERGE] odoo bus, im_chat and im_livechatAntony Lesuisse
Add a generic bus for instant communication based on postgres LISTEN/NOTIFY and HTTP comet. Both threaded and gevent greenlet mode are supported. Chat should now work on every platform. im_chat improvements - proper support for multiple windows - present, away and offline status - improved data model for multi user chat session im_livechat improvements - standard css js assets are now used - qweb templates are now used instead of jinnja