Commit Graph
104566 Commits
Author SHA1 Message Date
Josse Colpaert bf8ac7c9d3 [FIX] mrp: default product when creating lots in produce wizard 2016-09-28 12:38:13 +02:00
Josse Colpaert 153a6d0814 [FIX] mrp: correct interpretation of explode's quantity parameter
In previous versions, the quantity passed to the bom_explode was the number
of times you needed to count the BoM.  If the BoM was for 2 dozens and you pass
48 units, 2 was passed to the bom_explode method.  We are now doing the same
for the explode method and we check it is called this way everywhere.
2016-09-28 12:38:13 +02:00
Josse Colpaert fbab021a9b [FIX] mrp: extra move should split move lots also and take into account procurement
When you produce or consume more than foreseen in a production order,
the system creates extra moves.  Before, in case of tracking, it did this without
transferring the stock.move.lots resulting in a wrong stock.  That is why now,
when we split moves, we also split the stock.move.lots

For the finished move, it is also important to split between the quantities
of the original procurement and what is extra as the extra might use a push rule e.g.
2016-09-28 12:38:13 +02:00
Josse Colpaert 24a16f5db5 [FIX] mrp, mrp_byproduct: updating the quantity of production orders fixes
When updating quantity, it should take use a similar
method as for generating the moves, but with
the quantity already produced (and posted) deduced.
The parameters for these method needed to be changed.

When all the moves are posted,
we should create the necessary extra moves.
If the quantity is put back to the quantity posted, it
might also need to delete moves.
In byproduct, it should take into account the subproduct factor.

When the quantity produced  on the work orders has reached the quantity to do,
it should not allow anymore to use the "Done" button on work orders, but
rather use the Finish button instead.  With the Update button on the manufacturing order
it is possible to do more.
2016-09-28 12:38:13 +02:00
Josse Colpaert 3e95e4e58e [IMP] mrp: help message for the explaining the Next Operation field on the routing 2016-09-28 12:38:13 +02:00
Josse Colpaert 219809a5a8 [FIX] stock: do not propagate changing of quantities of moves to the next move anymore
In v7, it could be in handy that when altering the quantities of a move, it would automatically
update the next chained move as you could change quantities on the fly without any relation
to the original documents.
From v8, this is all being handled by extra moves which might e.g. follow
a different route, so you still know what is related to the original procurement.
But the functionality stayed in the code for who would still need it.
In v10 and in previous versions, manufacturing orders however still use these moves.

When we update the quantity on a halfproduct (which we can do now all the time in v10,
it could change the consumption where it is used in the finished product (in MTO)
That is why it is better to remove this functionality.
(it might also speed up the split method on stock_move)

The propagation of quantities was something from v7, that now causes trouble in mrp for nothing
2016-09-28 12:38:13 +02:00
Josse Colpaert 631ae042fb [IMP] mrp: inventory moves stat button should also be visible when you cancelled a manufacturing order 2016-09-28 12:38:13 +02:00
Josse Colpaert 0239202be4 [FIX] mrp: problem with blocking times starting at server start time
The default of the date_start on the time records was a
result of the function fields.Datetime.now instead of the function itself
resulting in the start of each blocking time as the start of the server
2016-09-28 12:38:13 +02:00
Josse Colpaert ca7b15b58c [FIX] mrp: typo Produced Qty -> Quantity To Produce 2016-09-28 12:38:13 +02:00
Josse Colpaert 0efc835fa9 [FIX] mrp: correct workorder qty_producing onchange
When changing the quantity being produced on a work order and
serial numbers are consumed, we need to delete or add lines
for every serial number in function of the quantity through the onchange.

We changed the quantity_done to be set to quantity by default (automatically)
as otherwise we forgot to set it.  But for the onchange, it means
we need to take it into account otherwise the number of records
would not be diminished.
2016-09-28 12:38:13 +02:00
Josse Colpaert 777ea73f23 [FIX] mrp: make sure we see in mo from stat button when only one (was taking 2 domains) 2016-09-28 12:38:13 +02:00
Josse Colpaert d5284266d9 [IMP] mrp: no quick create on operation_id 2016-09-28 12:38:13 +02:00
Josse Colpaert 4475610b4d [FIX] mrp: only show produce button when not done, product readonly in produce wizard and move_id necessary to make onchanges work 2016-09-28 12:38:13 +02:00
Haresh Shyara 841c1c3adb [FIX] mrp:workcenter: blocked and productive time correction
The labels of the fields say that they store hours, but actually they store minutes. Correct the code to store hours.
Add digits to fload field for a better display in the webclient
2016-09-28 12:38:13 +02:00
Josse Colpaert 5043d77128 [IMP] mrp: mo view: date_planned_start, user_id and origin fields should be editable
date_planned_start should also be Start Deadline instead of Expected Start Date.
We don't want the Expected dates to function as a planning tool, but as
a priority for the planning of the workorders.
2016-09-28 12:38:13 +02:00
Josse Colpaert 8f44f38b84 [IMP] mrp: "produce" wizard should set MO to "in progress" state 2016-09-28 12:38:13 +02:00
Josse Colpaert 31b3073d4b [IMP] stock,mrp: origin of scrap move
If the user has not filled in the origin in the scrap object,
we set it to be its associated picking or production order if any.
2016-09-28 12:38:13 +02:00
Denis Vermylen (dve) 88e379cd27 [FIX] project_issue: correct onchange_project_id (2)
amend to d78256e76c

We wish to keep the email address if no partner is assigned.
2016-09-28 10:44:34 +02:00
Denis Vermylen (dve) d78256e76c [FIX] project_issue: correct _onchange_project_id
the onchange changed the partners of the ticket when the ticket changed project
to the project's partner, but if the ticket already has a partner it shouldn't
change.
2016-09-27 17:28:40 +02:00
qsm-odoo 5f98040430 [FIX] website, *: properly process saving from editor dialogs
* web_editor, website_blog

Since recent refactoring, web editor dialogs automatically trigger
an event when closed (saved or cancel). The problem is that there
still was manual trigger of those events or variants ("save" instead
of "saved").

To prevent multi-saving and be consistent, all save events are now
automatically triggered on save/close (no more manual) and the event
name is "save".
2016-09-27 15:42:31 +02:00
Denis Vermylen (dve) 52ba0552a4 [FIX] portal: remove ensure_one()
a random ensure_one() was added during the migration causing an error when
modifying portal access management for partners with more than one contact.

Removing it.
2016-09-26 17:32:16 +02:00
Thibault Delavallée fcd6813dc9 [FIX][IMP] various: unsudo mail/view controller and get_access_action
This is a backport of saas-13 commit a9bd9ab160.

mail/view controller is a generic controller that redirects the user to a
given view, depending on the record and the user. Users may be redirected
to the backend form view, or to a website view. This is done notably by
calling get_access_action method that gives the action to perform (act_window
or url).

Previously this method was called using SUPERUSER. However it was therefore
impossible to know who the user was. This method is now called using the
current user. Various overrides of get_access_action have been updated to
add some logic and access rights check directly in the method allowing
more fine-grain behavior of the access action.
2016-09-26 14:42:25 +02:00
Martin Trigaux d59d95107e [I18N] Update master translation terms from Transifex 2016-09-26 11:44:55 +02:00
Jeremy Kersten 5f90769f41 [FIX] website_sale: SignIn url if SignUp not allowed 2016-09-23 14:46:48 +02:00
Jeremy Kersten 0ee98f4b42 [FIX] website_sale: fix display price in cart. 2016-09-23 13:21:08 +02:00
Jeremy Kersten 81447ca711 [FIX] website_sale: set payment_term_immediate by default in shop 2016-09-23 13:21:08 +02:00
Christophe Simonis b1b700adb1 [MERGE] forward port branch saas-11 up to 6854887 2016-09-22 14:23:07 +02:00
qsm-odoo 5a0a29b528 [FIX] web_editor: prevent crash when deleting multiple snippets in one deletion
Since saas-12, when deleting contents, parents are deleted too if they
become empty (while it was not possible to delete contents in that case
before). The problem here was that the history was recorded multiple
times if one deletion made multiple snippets be deleted and this
sometimes could crash.

Now the history is recorded only on first deletion when the user ask
for it.
2016-09-22 13:44:06 +02:00
Christophe Simonis 6854887ade [MERGE] forward port branch saas-10 up to 477482e 2016-09-22 13:41:33 +02:00
Christophe Simonis 477482ed9f [MERGE] forward port branch 9.0 up to 78f6117 2016-09-22 13:05:29 +02:00
Christophe Simonis 78f6117db0 [MERGE] forward port branch saas-6 up to 6a67e5c 2016-09-22 12:52:35 +02:00
Christophe Simonis 6a67e5cf42 [MERGE] forward port branch 8.0 up to e083d72 2016-09-22 12:46:30 +02:00
Raphael Collet 16a0b3b249 [FIX] models: do not delete ir.model.fields in _field_create (#13565)
Following 5c5d0865b9, apparently unused records
are simply deleted after updating existing ones.  This causes an issue when a
module is installed or upgraded.  The inspection of `ir.model.fields` records
is based on a *partial* registry (not all modules loaded); therefore records
will be deleted and recreated afterwards.  This triggers inconsistencies in
other models that refer to `ir.model.fields`, like server actions, base action
rules, mail templates, etc.: many2one fields will be set to null!
2016-09-22 12:29:24 +02:00
Nicolas Martinelli be8bbc2396 [FIX] base: traceback in read_group
An issue originally occurs in the Event module.
- Go to Events >> Reports >> Events
- Add a "Group By" in the search view: "Event Month"
- A mighty traceback pops up

This is because the rows and the columns are grouped by the same field
(`event_date:month`).

In method `_read_group_format_result`, a group_by of type "date" or
"datetime" is replaced by a "(range_start/range_end, label)" tuple. The
first element of the loop on `annotated_groupbys` is handled correctly,
but the next identical element will crash on `value + gb['interval']`,
since `value` is now a tuple and not a date/datetime anymore.

opw-686242
2016-09-22 10:21:10 +02:00
qsm-odoo 9ea6861d7e [FIX] web_editor: allow editing t-field links
There is a hackish feature in the web_editor which forces the
contenteditable to true on links which are clicked and removes it
anywhere else in the page so that only the link is editable after
click. This allows to add text at the end of a link without adding it
outside of the link by mistake.

The feature was badly implemented because, if the link was editable
without having any parent which is editable, the contenteditable was
forced to true, then immediatly forced to false when forcing to false
every page element. This was the case for lots of t-field. By example
the product categories in eCommerce are t-field links which are in non
editable <li/> elements...
2016-09-22 09:41:39 +02:00
Nicolas Lempereur e083d720a9 [FIX] website_blog: blog pager page issue
When we are on the page:

 /blog/myblog-1/page/2

the link to page 3 is:

 /blog/myblog-1/page/3

So we need to give /blog/our-blog-1 as source url of pager.

Previously in this instance, since 4faed0b7 the page 3 url
in this scenario would erroneously be:

 /blog/myblog-1/page/2/page/3

opw-688681
2016-09-22 08:05:20 +02:00
Jeremy Kersten e72b852015 [FIX] website_crm, website_hr_recruitment: remove useless token
This token will be added automatically at posting (by ajax.js from framework)
2016-09-21 21:34:11 +02:00
Wolfgang Taferner 71fd0829ef [FIX] anonymization: intercept exception in case of removed models and fields 2016-09-21 21:34:11 +02:00
Olivier Laurent 5bd0b05c22 [FIX] doc: typo in upgrade_api 2016-09-21 16:27:02 +02:00
Jeremy Kersten 6dc985b0ad [FIX] website_crm_partner_assign: allow partner to be uninteressed for a lead.
Avoid traceback "'int' object has no attribute 'partner_id'"
uid is the id and not the browser record of 'user'

Avoid traceback: Database fetch misses ids (u'<id>') and has extra ids (<id>),
 may be caused by a type incoherence in a previous request.
JS call with id as string.

Avoid traceback: Invalid value res.partner(x,y,z) in domain term ('partner_id', 'in', res.partner(x,y,z))
Search in new api return browseRecord now

Avoid to write on a lead without the right on it.
2016-09-21 16:21:51 +02:00
Christophe Matthieu ab06013e30 [FIX] mass_mailing: can't change color button snippet when edit mass mailing 2016-09-21 16:14:49 +02:00
Thomas Binsfeld (ACSONE) 69a4bf7a43 [IMP] hr: add tree view in Departments action window (#13418)
Tree view was removed to hide the different view types display in enterprise as it was "cleaner" for a dashboard. Re-adding for import button.

Future versions will not display departments as dashboard but employees anyway.
2016-09-21 14:56:38 +02:00
Denis Ledoux 5b4c1d405d [FIX] mrp: fix partner ref and so number in mrp report
These fields are no longer in the model `._columns`
since their migration to the new API.

Courtesy of Daniel Dico
https://github.com/ddico

opw-688768
2016-09-21 13:23:49 +02:00
Denis Ledoux 7233add42b [FIX] point_of_sale: picking creation after payment
Since the below revision:
32b5515a8f

It was no longer possible to create a payment
for a pos order without picking.

Indeed, if `picking_type` is not set,
`picking_id`, which is initialized to `False`,
remains as `False`, and you therefore can't
ask it's `.id` (`picking_id.id`).

opw-687597
2016-09-21 12:23:33 +02:00
Jeremy Kersten 8b41933a9e [FIX] web_graph: force row title to be string
If the title was 'true' or 'false', the export failed, because we are tying to
concat bool and str. TypeError: cannot concatenate 'str' and 'bool' objects

How to reproduce, install sale, be sure to have one order with delivered = True
In Reporting / Sale analysis, add a group by 'shipped' filed to have 'true' as
title.

This commit closes issue odoo/odoo#13425
2016-09-21 10:59:39 +02:00
Stéphane Bidoul (ACSONE) dbd4114d38 [FIX] l10n_lu: fix reconcile flag in accounts template csv
Changes f -> FALSE and t -> TRUE, otherwise when installing the l10n_lu
COA, the reconcile flag is wrong.

Closes #13282
opw-688957
2016-09-20 17:46:13 +02:00
Richard deMeester 4f0ca6d923 [FIX] base: res.config name_get fix (#13513)
name_get function needs to ensure that read passes the required
ids as a list, not a single value.  This is very important if
the method is inherited.
2016-09-20 16:19:46 +02:00
Raphael Collet 5c5d0865b9 [FIX] models: reflect inherited (by _inherits) custom fields
When a custom field is created, it now appears in `ir.model.fields` on the
model's children models (by `_inherits`).  This makes the reflection more
accurate (inherited custom fields are visible), although not perfect (they
appear as "base" fields and thus cannot be overridden).

The reflection of fields in `ir.model.fields` has been improved to deal with
custom field creation, modification and suppression.

Note that custom fields are still not inherited through `_inherit` relations.

opw-687626
opw-645065
2016-09-20 14:08:55 +02:00
Christophe Matthieu 12a6889088 [FIX] website_sale: wrong help menu name to create new product.
Issue: Missing Menu on E-commerce because the user click on the wrong menu
opw-681201
2016-09-20 13:53:57 +02:00
qsm-odoo c4784fc75b [FIX] web_editor: activate autoplay feature for videos
The checkbox was there to activate autoplay... but was not doing
anything since the web_editor/website split.
2016-09-20 13:40:53 +02:00