Commit Graph
98611 Commits
Author SHA1 Message Date
Raphael Collet 5232fb9e24 [IMP] base: adapt binary fields to store images in attachments 2015-09-28 15:19:47 +02:00
Raphael Collet 1bb61c970e [ADD] fields: add option to store binary fields into attachments
Such a field is declared as:

    image = fields.Binary("Image", attachment=True)

With this option, the value of a binary field F is stored in an attachment with
`res_field=F`.  When attachments are stored into the filestore, binary fields
are consequently stored in the filestore as well.  Note that the option does
not work on old-API function fields.

By default searching on `ir.attachment` filters out attachments for binary
fields: the condition `res_field=False` is added to the domain unless a
condition on field `id` or `res_field` is already present.  The client uses
`search_read` with a domain like `[('id', 'in', ids)]` for reading the data on
a form view.  In that case, we should not filter out attachments that store
binary fields.

Also, do not filter search results for the superuser.
2015-09-28 15:19:47 +02:00
Simon Lejeune 6327cda0a7 [FIX] ir_qweb: assets: write in ir.attachment outside of main transaction
If, in the same transaction, we need to render a template and read its
associated assets, they are unreachable because the writes in
ir.attachment are not yet commited. Workaround this issue by commiting
manually with new cursors.

This issue occurs when you want to print a pdf report for the first
time.
2015-09-28 14:35:26 +02:00
Simon Lejeune 2e16296099 [REF] base, report: preview internal/external qweb reports
Added two dummy reports to print an empty internal and external report
and added direct link to edit header/footers template in the form view
(in technical features) for convenience.

Also moved the 'preview rml report' under the rml configuration and
tried to make the company form as clean as possible but i think it's
failed.
2015-09-28 14:35:22 +02:00
Simon Lejeune 62cd475293 [REF] base_setup: remove rml configuration
Everything has already been moved (read: duplicated) under "company >
report configuration" and only appears in technical features, plus
displaying "Report Font" in "general settings" is really confusing, as
it is a deprecated field.
2015-09-28 14:32:31 +02:00
Simon Lejeune f26988cf7a [REF] report: use assets
Three assets: assets_common for shared assets (html/pdf), assets_editor
for editor styles and scripts, assets_pdf to tweak only the pdf output
2015-09-28 14:32:31 +02:00
Simon Lejeune 0e304bf77e [HACK] report: return html when a pdf is requested with a test cursor 2015-09-28 14:32:31 +02:00
Richard Mathot c02ff8aebd [FIX] sale_stock: reintroduce field sale_id on stock.picking
This field has been removed by e57ac16476
(let's break everything, it is more fun!). But some people needeed it...

This patch proposes thus a new-API version of the sale_id field.
2015-09-28 12:44:37 +02:00
Arthur Maniet 4530e5d61c [FIX] account: deleting a bank journal also deletes its bank account
Fixes #8739
2015-09-28 11:40:04 +02:00
Leonardo Rochael Almeida bf4b47c94d [IMP] JSONDecodeError > ValueError
JSONDecodeError extends ValueError, and is not available in the Python
Standard Library.
2015-09-28 10:53:53 +02:00
Leonardo Rochael Almeida 60af7cac02 [IMP] replace simplejson with stdlib json
The stdlib version of the json library is more recent than the 3.5.3
version we are pinning in `requirements.txt`

There is no reason to use it.

Closes #6940
2015-09-28 10:53:32 +02:00
Leonardo Rochael Almeida 06b3026bcd [IMP] unittest2 > unittest
The `unittest2` package is simply a backport of `unittest` from the
Standard Library of Python 2.7 to previous versions.

There is no reason to use it any longer.

Closes #6941
2015-09-28 10:37:27 +02:00
Martin Trigaux 864ac67905 [FIX] base: missing spaces in help message 2015-09-28 10:26:13 +02:00
Yannick Tivisse 0f16318f1e [IMP] mass_mailing: Add a setting to enable the popup snippet on the website
[FIX] mass_mailing: Display attachments in a proper way
[IMP] mass_mailing: set default value for popup_redirect_url, as it's sometimes required
2015-09-28 10:19:51 +02:00
Yannick Tivisse 432c01c076 [IMP] project: count the project tasks correctly
Also, we should be able to set a customer on a project, whatever the access rights,
for example, if we're managing services by using internal projects.
2015-09-28 10:19:51 +02:00
Yannick Tivisse c543e1be8b [IMP] web_settings_dashboard: Jump on Apps or Users view by clicking on the fa icon 2015-09-28 10:19:51 +02:00
Yannick Tivisse 0d0c4802c9 [REM] base: Remove Companies Structure tree view.
Modify test test_ir_values.py also, as the action was used in it.
2015-09-28 10:19:50 +02:00
Yannick Tivisse 833ebdcdb9 [IMP] base: lang in context when creating a contact for a partner 2015-09-28 09:59:50 +02:00
Joren Van Onder f0f45c8fa2 [FIX] point_of_sale: set taxes when creating pos_order from form view
When creating pos_orders from the form view, tax_ids on the
pos_order_lines were never set.

This was kind of fixed in 5327869356. But
in there it was in onchange_qty, because the way the fiscal position was
taken into account required it to be. Because we take the fiscal
position into account in a different way now we can assign the taxes in
onchange_product_id which makes a bit more sense.
2015-09-28 09:00:21 +02:00
Joren Van Onder 358e285fd8 [IMP] point_of_sale: fiscal position per pos_order
Allows a user to set multiple fiscal positions per pos_config. Orders
created on that config can then be assigned one of these fiscal
positions. In the POS this can be done through a button that will appear
above the numpad when fiscal positions are set on the pos_config.
2015-09-28 09:00:21 +02:00
Joren Van Onder a208007502 Revert "[IMP]point of sale: added fiscal_position_id field in pos config to set fiscal postion on each shop."
This reverts commit 5327869356.

Reverting this because we would rather want to be able to set a fiscal
position per pos_order, not per pos_config.
2015-09-28 09:00:21 +02:00
Odoo Translation Bot 3dec9e5804 [I18N] Update translation terms from Transifex 2015-09-27 03:07:16 +02:00
Fabien Pinckaers e49d0cd74d [IMP] Typo 2015-09-26 11:34:18 -07:00
Fabien Pinckaers adbfed5bbb [IMP] typo 2015-09-26 08:26:23 -07:00
qsm-odoo 5209bb255d [FIX] mrp: remove useless layout-breaking group
* Adding a new group in a group of fields is breaking enterprise layout
* Moreover the group was useless: useless colspan, unique field with
colspan>>>col in it, double access-right, ...
2015-09-25 18:10:55 +02:00
qsm-odoo 4e20e44303 [FIX] web_calendar: calendar height
Calendar height was again a problem since the introduction of the
bootstrap layout (the .row had not height 100% and thus the calendar
was not able to compute its height anymore).
2015-09-25 18:10:55 +02:00
qdp-odoo 9091c5efc0 [FIX] account: 'invoiced' button on partner now opens the tree view of customer invoices instead of the vendor one 2015-09-25 17:40:33 +02:00
Tanguy Charlier 93e9a4dce7 [IMP] res_partner : optimize name_get 2015-09-25 17:11:49 +02:00
qdp-odoo c078f71646 [FIX] account: allow supplier bills and refunds to share the same reference 2015-09-25 17:01:49 +02:00
Thibault Delavallée dec333d8a4 [FIX] hr_equipment: rename from it assets to equipments
This is a partial revert of 132dcc9786. Indeed the
hr_equipment module can be used to track any kind of equipment, not only
IT assets.
2015-09-25 16:30:12 +02:00
Thibault Delavallée a4869fce23 [FIX] hr_equipment: form view
Category is a classic m2o, not a statusbar. Moreover fixed category_id being twice
in the form, leading to one of them being impossible to use.
2015-09-25 16:28:38 +02:00
Christophe Matthieu 1acd86a45d [FIX] website_blog: display cover and cover options 2015-09-25 16:06:21 +02:00
Christophe Matthieu 4ba0232bf8 [FIX] web_editor: apply o_dirty class on change
Before: if a user blur a editable area without editing, the editor is removed and all bind are remove.
The 'content_changed' bind are removed and the 'o_dirty' class is never apply.
2015-09-25 16:06:21 +02:00
Christophe Matthieu 743f26a796 [FIX] web_editor: display editable area placeholder 2015-09-25 16:06:21 +02:00
Christophe Matthieu 7ffd1954e4 [FIX] im_livechat: display live chat button in one line 2015-09-25 16:06:21 +02:00
Christophe Matthieu b9d9e44582 [FIX] web_editor: use parser from dateutil for datatime qweb field value 2015-09-25 16:06:21 +02:00
Jérome Maes 8ffca19680 [FIX] web : attachment controller got unexpected args
On webclient, on 'Attachment(s)' dropdown (form view) when clicking on an attachment to download it, a request is sent to /web/content/ with a param 't' containing the current date. This param wasn't used neither before the new controller, but the old one accept additional kwargs. The new controller crashes, and since the t parameter is not used, removing it seems better.
2015-09-25 16:05:44 +02:00
Jérome Maes 3c97dbf1e1 [FIX] website_blog : use website_mail mechanism to post message
Using website_mail mecanism will prevent to transform POST params into GET params when redirecting. This will reasure xmo ;)
2015-09-25 16:04:27 +02:00
Jérome Maes 6bba311d8c [FIX] website_mail : force login to post comment
Transform POST param into GET param when redirecting to login page can cause security issues. Now, instead of displaying textarea (even if public user) and the redirect to login page keeping written comment, we display the login button with a redirection to the page to comment.
The redirection happen before commenting, avoiding to remenber param such comment text, rating, ...

To post a comment, the user must:
- be connected
- have a token
- or have a sha_sign
2015-09-25 16:03:49 +02:00
Jérome Maes c436c56148 Revert "[FIX] website_mail, website_sale : redirect to login page to post comment"
This reverts commit 7974bf5441.
2015-09-25 16:03:40 +02:00
Thibault Delavallée 26f6a0c3f9 [FIX] hr_recruitment: domain for documents on jobs 2015-09-25 15:05:17 +02:00
Josse Colpaert 50477f4019 [FIX] stock: lots (re)reserving should handle quantities correctly and better handling of reserved quants without lot
When moving pack operation with lots:
The system will still take the quants that are reserved with lots first.
What changed, is that, secondly, it will take reserved quants without lots.
Afterwards it can use the traditional methods to check the non-reserved quants for every lot.
2015-09-25 14:49:46 +02:00
Tanguy Charlier fe4c9bb3a9 [IMP] res_partner : name field is now optional for addresses.
The name_get has been updated accordingly : if an address has no name, we now show parent_name, res_partner.type.
The contact template shows the name when it exists, and the parent_name if it does not. This should produce cleaner reports.

Though the name field is no longer required on the res.partner model,
"required" attribute in views and an sql contraint enforce that all contacts have a name.
2015-09-25 14:06:29 +02:00
Arthur Maniet 0ead074211 [IMP] stock: report to print locations barcodes
Print 4 barcodes per page, in a disposition that is practical to print on stickers.
2015-09-25 13:36:15 +02:00
Thibault Delavallée 42d015f2b0 [IMP] mail: tracking values in mail message view 2015-09-25 13:30:07 +02:00
Thibault Delavallée aded9bf839 [FIX] event :
- dates are editable even in confirm state. Only events in done states are
  not editable.
- the print badge button is actually a button to edit badges, so let us udpate
  the name
2015-09-25 13:30:07 +02:00
Joren Van Onder 97b0723722 [ADD] pos_cache: add pos_cache ported to v9 from odoo-extra
Originally written by Nicolas Seinlet <nse@odoo.com>. Provides
pos.config with a product.product cache.

This adds a ported and refactored pos_cache from odoo-extra:

- Adapt to changes in web and point_of_sale since 8.0
- Refactor the load_server_data function, so it isn't copy pasted but
  cleanly patched into the load_server_data super.
- Make the cron inactive by default.
- Also remove retrying the write 5 times, when it fails we'll just have
  to wait until the cron triggers again (an hour from then).
- Store the product.product fields and domain on pos_cache. When cache
  is requested from the pos with a different field or domain it'll
  automatically recompute. Necessary for when someone would install a
  module that modifies these things in the pos after a cache has been
  generated.
- Have multiple caches per pos_config per user
- Make the module adhere to the Odoo Coding Guidelines.
2015-09-25 12:47:29 +02:00
Josse Colpaert 9a42baa7e2 [IMP] stock: on picking form inverse done and to do fields on operations and lots input
Also check for plus sign only to be visible when necessary,
which makes quantity unnecessary when handling serial numbers
2015-09-25 12:00:29 +02:00
Nicolas Martinelli 5eb681bd03 [FIX] website_sale_digital: properly loop on self 2015-09-25 11:34:01 +02:00
Nicolas Martinelli 9577f4e419 [REF] product: do not use selected_seller_id
The function field selected_seller_id is removed  and must be replaced
by a direct call to method `_select_seller`. This is more conventional
than the previous 'browse with context' way of doing.
2015-09-25 11:34:01 +02:00