Thursday, January 17, 2019
7 changes · master
Enhancements to existing features
Purchase requisitions can now be used for service purchases without requiring inventory features. Stock-related purchase agreement behavior has been moved into a separate bridge module, keeping service workflows simpler while preserving inventory-based requisition options for companies that need them.
Original PR description
https://www.odoo.com/web#id=1851286&action=333&active_id=131&model=project.task&view_type=form&menu_id=4720 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
The web editor was reworked to make editing website pages and mass mailing emails faster, more reliable, and easier to test. This also supports updating the underlying editor library and improves email rendering by separating editable content from the version sent to recipients.
Original PR description
_Task #1878502_ - The refactoring allows for the update of the _Summernote_ library. - A new structure was created by transforming all the plugins in the library using the odoo inheritance system.…
_Task #1878502_
- The refactoring allows for the update of the _Summernote_ library.
- A new structure was created by transforming all the plugins in the library using the odoo inheritance system. Plugins are easier to implement with the `AbstractPlugin` to add Odoo behaviors.
- The cleanup allowed us to remove some of the code that was in `web_editor` but only used in `website` or in `mass_mailing`. Some parts are still in `web_editor` but will be moved at a later time.
- The refactoring also had to be done in order to create a set of unit tests. Each behavior can be tested, including the behaviors performed as a consequence of keyboard interactions (for instance: Enter, Tab...).
- From now on, the methods of the library (in this case _Summernote_) can no longer be called by other modules or files. Only the `wysiwyg` widgets can access it, to simplify the updating process. The `wysiwyg` object serves as an interface. A lot of tests are done, ensuring the consistency of outside behavior.
- Depending on the options the snippets will be loaded or not, the editor will be in an iframe or not... all of this is transparent from the outside.
- Regarding iframes, all controllers related to editing have been removed: the new API no longer needs them. This speeds up loading, eases testing and removes complexity for the same features.
**PUBLIC FEATURES**
There are several public methods on the `Wysiwyg` class:
- `Wysiwyg.prepare (WidgetParent)` which returns a deferred resolved when the library (xml, lazy, assets...) is loaded.
- `Wysiwyg.getRange (DOM)` returns the range (selection in the dom)
- `Wysiwyg.setRange (startNode, startOffset, endNode, endOffset)` which creates a range (selection in the dom)
- `Wysiwyg.setRangeFromNode (DOM, options)` that creates a range from an element (option available to select all, start or end)
A jQuery selector was added: `:o_editable`, which indicates whether the current element is editable. That is, if it is contained in a tag with the attribute `contentEditable = "true"` or in a tag with the class `o_editable`.
Several methods are also present:
- `focusIn`: makes a focus and places the cursor at the beginning of the element
- `focusInEnd`: makes a focus and places the cursor at the end of the element
- `selectContent`: makes a focus and selects the content
**HTML FIELD**
The HTML field can receive different options:
- `style-inline:` {boolean} transforms a class into an inline style when saving and vice versa when reading.
- `no-attachment`: {boolean} prevents the use of attachments (in media dialog)
- `cssEdit`: {xml_id} to use a template containing the css to loaded in an iframe when editing
- `cssReadonly`: {xml_id} to use a template containing the css to load into an iframe when viewing in readonly
- `snippets`: {xml_id} snippets template (can be used with or without `cssEdit`)
- `wrapper`: {template} qweb static template (containing a tag: `id = "wrapper"`) that will include the content during editing (removed on save)
**MASS MAILING**
A widget was created for `mass mailing`. There are now two fields: `body_html` and `body_arch`.
`body_arch` contains the code with the class without conversion into inline style, useful when editing and one with the inline style that is visible in readonly mode and sent by email.
Advantage: no spreading errors, able to update css/theme, able to do more changes when converting to inline style so that a maximum of mail clients have an impeccable rendering.
**REMAINING KNOW ISSUES**
These will be fixed in a subsequent commit.
- A few committed changes made during the development of this refactoring were lost in the process and should be reapplied.
- Some minor (mostly range) issues remain with Firefox.
--
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-prMass mailing now shows related leads, quotations, and invoice value buttons consistently, regardless of mailing stage or recipient type. Lead and opportunity counts now include archived records too, giving teams a more complete view of campaign impact.
Original PR description
…ity) Task #1907952 Purpose ======= The number of generated leads/opportunities from the mass mailing on the stat button should count both active and archived leads/opportunities. The stat buttons on mass mailing added by sales and crm apps should appear on every stage of the mass mailing (draft/in queue/sending/sent) to showcase the feature. It should also appear on every selected 'model' for the recipients (a mass mailing sent to 'leads' can generate sales). Specs ======= Opportunity stat button: - double check that the number is based on both leads or opportunities, active or archived Stat buttons Leads #, Quotations #, Invoice Amount should appear on the form all the time for showcase purposes Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Marketing teams can now give each mailing an internal name that is different from the subject line customers see. This makes it easier to organize, filter, and report on campaigns without exposing internal labels or disrupting tracking when subject lines are adjusted.
Original PR description
Task: https://www.odoo.com/web#id=1917602&action=333&active_id=965&model=project.task&view_type=form&menu_id=4720
Project and timesheet screens were refined to make it easier for new users to understand what to do next. The update improves labels, reduces unnecessary fields, prevents accidental project creation from tasks, and adds helpful visual guidance for creating the first kanban items.
Original PR description
This merge provides many little changes to improve the usability and the onboarding of users in project and timesheet applications. This mostly contains labels renaming, restruration of views, ... but some new mecanism appears like the "ghost kanban examples", and improvements of the kanban examples modal. Task-1893021
The timesheet entry popup now shows date and duration fields directly, making it easier for users to record work accurately. In Enterprise, settings labels are updated from “Task logs” to “Timesheets” to match the product naming and reduce confusion.
Original PR description
This commit - (re)changes for the 34th time the modal "Add a line" on timesheet grid view - provides the project_enterprise module to change a label in timesheet settings Task-1893021
This update adapts Odoo Studio and related website editing features to work with recent changes in the underlying web editor. It helps keep report editing, website forms, marketing emails, and related editing experiences stable and consistent for users.