Commit Graph
94470 Commits
Author SHA1 Message Date
Jérome Maes eb5de33eac [FIX] im_livechat : add a cookie to prevent the automatic opening on a auto-popup page. Each time the page is refresh, the auto-popup was triggered, which can be very intrusive for users. The cookie remember the auto-popup is desactivate for an hour, for every page. The button stay displayed on page. 2015-03-31 13:19:16 +02:00
Jérome Maes 4f7f47988a [FIX] rating : change default mode of graph view 2015-03-31 13:19:03 +02:00
Jeremy Kersten 36ae07ed15 [FIX] website_forum: don't use span with style for forum
Forum sanitize the content before to be inserted in db.
So all tags style are removed...

Disabling the option styleWithSpan, will let summernote to use <b>, <u>, <i>
to allow the end user to change the style from an answer / question.
2015-03-31 12:19:57 +02:00
Raphael Collet 3c1036f029 [IMP] ir_ui_view: remove useless ormcache decorator on method get_view_id
The decorator is not really useful, since it calls an already cached method.
Moreover, it causes cache errors because of its `context` parameter that occurs
in the cache key.
2015-03-30 15:35:02 +02:00
Arthur Maniet 342f82c50a [FIX] account: bank statement reconciliation: don't display negative amount for already reconciled lines in currency 2015-03-30 09:14:47 +02:00
Josse Colpaert d969e60699 [IMP] Change the naming of pull rule to procurement rule 2015-03-27 18:30:38 +01:00
Denis Ledoux 2e60513c15 [FIX] website_links: linker access rights
Links shortener is a tool needed by Website managers,
restricting this tool to ERP manager is a bit too restrictive.

Website managers is probably too restrictive as well,
maybe all employees should be able to access
this feature. Before having a real use case,
giving this tool to website managers is enough at this time.

opw-631511
2015-03-27 17:39:24 +01:00
Olivier Dony 26abbf676d [FIX] website_mail: remove unused alert div, fixes look of input-group-btn
Bootstrap's CSS depends on the input-group-btn
element being the first/last child of its parent.
This was not the case because of the invisible
and useless alert.
2015-03-27 17:23:04 +01:00
Arthur Maniet 62bc5c8123 [FIX] account bank statement import ofx: fix amounts used in test case 2015-03-27 16:59:59 +01:00
Denis Ledoux ade57d1a6f [FIX] website_event_questions: inability to delete quotation line linked to a event.registration.answer.
On the ecommerce, when ordering a place for an event,
and answering to an event.registration.answer,
it wasn't possible to delete the quotation line
(missing ON DELETE CASCADE)

opw-631619
2015-03-27 16:56:13 +01:00
Arthur Maniet b577e16411 [FIX] account bank statement import ofx: use provided balance as end balance instead of start balance 2015-03-27 16:08:05 +01:00
Josse Colpaert ba435bc3a9 [IMP] stock: adapt views of current inventory valuation and stock level forecast
The stock level forecast view should have inverse columns and rows.  The line graph
is also better by default.

The stock valuation view should only be in reporting (removed the graph part) and is replaced by a pivot and
graph view of the quants in the warehouse menu.  We only group by location by default.

Use date_expected instead of date in stock level forecast and group dates by week by default.
2015-03-27 15:59:31 +01:00
Christophe Simonis 2f29acf9c5 [FIX] account: correct contract_count value.
Use `child_of` operator to match the search that will be done by the
search view.
2015-03-27 15:49:58 +01:00
Olivier Dony d555fdac0c [IMP] tools.ustr: speed up average call by short-circuiting common cases
Direct type comparison is significantly faster than
isinstance/issubclass calls, so it is worth using
in a method that is very frequently called.

The extra call to getencoding() also causes a significant
overhead, so we try to spare it by tring the hint_encoding
first. If all fails, the default behavior still applies.

Using micro-benchmarks, the execution time of
ustr() on an already-unicode string is cut in
half (no conversion is needed), and the overhead
for converting utf-8 bytestrings is also
cut in half (the conversion itself is O(n) on
the string length, obviously)
2015-03-27 14:44:56 +01:00
Christophe Simonis cd08281979 [IMP] web: debug menu extra actions available to users in "Configuration" group 2015-03-27 13:14:46 +01:00
Géry Debongnie a35badc00b [FIX] web: graph view should respect graph type
The graph view is supposed to load in a given mode, as described by the
type attribute ('bar', 'line', 'pie').  However, the type attribute in
the fieldviewget was ignored, which means that the graph view was
always loaded in bar mode.
2015-03-27 10:05:11 +01:00
Raphael Collet 58d6bb30ab [FIX] ormcache: fix calls to ormcache with unexpected context parameter
The implementation of ormcache does not work on methods that take a context
parameter. Because of the decorator decorator, the arguments of the call are
passed positionally to the method ormcache.lookup, and positional arguments
are used in the cache key.

The fix consists in removing the context parameter from the faulty methods,
either directly, or by caching a private method called by the public method.
2015-03-26 18:44:51 +01:00
Christophe Simonis 313acf87a2 [MERGE] forward port of branch 8.0 up to d780014 2015-03-26 18:44:22 +01:00
Christophe Simonis d780014248 [MERGE] forward port of branch saas-3 up to ce69064 2015-03-26 18:00:06 +01:00
Christophe Simonis ce690649e9 [MERGE] forward port of branch 7.0 up to 2a0c018 2015-03-26 17:56:05 +01:00
Christophe Simonis 12416eb35f [FIX] google_*: set a timeout when contacting google servers 2015-03-26 17:48:25 +01:00
FalcoBolger 95b921d0f7 [FIX] website: move support for ir.attachment resources to web module
Commit 540b753bf8 introduced
support for resources stored as ir.attachment records in
asset bundles too.
This is specifically useful for customizations.

However the HTTP route for reaching those resources
when they are *not* in a bundle was originally created
in the `website` module (as a special handling for
404 requests)

This means that these dynamic resources would only
be partially supported when `website` is not installed,
causing various problems:
 - missing resources in debug mode where bundles are skipped
 - errors when trying to define new client-side Qweb templates
   via XML resources - which are loaded with a direct request
 - ...

This commit moves back the supporting code to the web module.

The `mimetype` column is not present in ir.attachment without
the `website` module, but sniffing it based on the attachment
name works fine at serving time too.

Closes #6002
2015-03-26 17:33:19 +01:00
Nicolas Lempereur 2a0c018043 [FIX] kanban: search more when DataSetStatic
When showing a kanban, there is differences between dataset of types:

* DataSetStatic: self.view.dataset===self.dataset, their ids attributes are the entire ids list,
* DataSet and DataSetSearch: self.view.dataset.ids are the already in the view ids, self.dataset.ids are the last gotten ids.

Hence with DataSetStatic dataset, when self.view.dataset.ids.splice(0) is done
self.dataset.ids is also emptied. And in the read_slice function, the slice is
done on that (now empty) array.

This fix removes the splicing of this ids array (which doesn't change a thing
since the array is overwritten latter), a _.difference is used to remove
eventual duplicates since in the DataSetStatic case, the same array is being
concatenated to itself

opw-630654 opw-617090 opw-619563
2015-03-26 17:28:02 +01:00
Raphael Collet c58121e8f1 [FIX] method ir_model.check now decorated with ormcache_context
The method needs the `context` parameter to translate the error message in case
the access is denied and an exception is raised.
2015-03-26 17:14:42 +01:00
han-odoo cec7a02fdd [FIX] POS: invoices taxes according to fiscal position
Fix the issue of taxes not being mapped
according to fiscal postion

opw-615167
2015-03-26 17:08:33 +01:00
Raphael Collet 0beb14f0d2 [FIX] ormcache: fix calls to ormcache with unexpected context parameter
The implementation of `ormcache` does not work on methods that take a `context`
parameter.  Because of the decorator `decorator`, the arguments of the call are
passed positionally to the method `ormcache.lookup`, and positional arguments
are used in the cache key.

The fix consists in removing the `context` parameter from the faulty methods,
either directly, or by caching a private method called by the public method.
2015-03-26 16:42:10 +01:00
Goffin Simon 3eda25119f [FIX] account: Invoiced doesn't take into account cancelled invoices
"Invoiced" stat button on the res.partner form view must not include cancelled and draft invoices.
The button triggered an action which shows a tree view with invoices where:
type in ['out_invoice'] and all states.
Now the button triggers a tree view with invoices where: type in ['out_invoice' , 'out_refund']
and state not in ['draft', 'cancel'].

opw:472318
2015-03-26 16:27:27 +01:00
Arthur Maniet e221a6e590 [FIX] account: coda unique transaction number was utterly wrong, leading to unhappiness for Christine 2015-03-26 15:56:03 +01:00
Jérome Maes f89c4cd78d [FIX] document : keep order during the search of ir.attachment
Backport of 16fa24d522
2015-03-26 14:48:18 +01:00
Goffin Simon b83f5a8ef9 [FIX] ir_filters: filters not in the language of the user
the context must be passed to the get_filters function to take into account
the language of the user.

opw:630057
2015-03-26 14:41:54 +01:00
Adrien Peiffer (ACSONE) 8b2c8dc0d1 [IMP] account_payment: display amount of transaction on payment line
Was changed on the form view at ab640d2, applying the same to tre view
2015-03-26 14:28:36 +01:00
Goffin Simon d79a1622bb [FIX] base: ir_filters: filters not in the language of the user
the context of the user must be used in get_filters to take into account
the language of the user.

opw:630057
2015-03-26 13:18:19 +01:00
Jeremy Kersten b9adcc7598 [IMP] base_import: match column names withtout check the case
If you try to import a file with a header 'Parent_id/id'
_match_header will not match Parent_id with parent_id
because it was comparing with case sensitive.

It's not a bug, but in most cases this new behaviour (non
sensitive case search) is what the end user was expected.

Hate Excel and the auto correct capitalization !
2015-03-26 11:34:22 +01:00
Richard Mathot 6ef068a811 [FIX] doc: exception for date/datetime in kanban views 2015-03-26 11:13:05 +01:00
Laurent Mignon 2faf4b7747 [IMP] Display the line note in the details
When reconciling, it's sometimes useful to have access to the note since the note can be filled with some information by the parser.
2015-03-26 09:57:56 +01:00
Denis Ledoux 8e48eb625d [FIX] mrp: ability to search BOM on BOM lines containing ...
In BOM, when performing an advanced search
on "BOM Lines" contains "a name"
all lines were returned, whatever the lines content.

This was due to the simple fact no field 'name'
was set on the mrp.bom.line model.

We set "product_id" as _rec_name, it seems the more
logical choice.

opw-631335
2015-03-26 09:55:24 +01:00
Géry Debongnie 9333c88d71 [IMP] web: pivot view should allow explicitely defined measures
In some rare cases (non stored functional fields), the pivot view should
allow it as a valid measure.  This commit changes the pivot view in such
a way that any explicitely defined measure will be added to the list,
even if it should not work, like for the non stored functional fields.

The pivot view has no way to know if a generic model has overrided the
read group method in a correct way to make it work, it is up to the
developer to make sure that measures defined in the xml are valid.
2015-03-26 09:46:18 +01:00
Nicolas Lempereur aaf9badbce [FIX] account: context/domain in move line tree
On a line write in a account.move.line tree view, the on_write return all the
sibling move lines of the written move line. The lines are then displayed even
if they do not match the current search domain.

This fix adds the context on the given on_write callback request, and in
on_create_write use a on_write_domain in this context to filter the returned ids.

fixes #3161, closes #5727

opw-630093
2015-03-26 08:59:23 +01:00
Goffin Simon e3ae3650de [FIX] website_quote: Accept button displayed in an expired quotation
The accept button must be hidden if the quotation is expired.

opw:630342
2015-03-26 08:50:23 +01:00
Christophe Simonis c2b4766860 [MERGE] forward port of branch 8.0 up to c54d83e 2015-03-25 18:39:17 +01:00
Christophe Simonis c54d83ebd5 [FIX] mail: column read -> is_read
This is the reverse patch of 132afa981b
2015-03-25 18:36:52 +01:00
Christophe Simonis 3540ec53e4 [MERGE] forward port of branch saas-3 up to 6b70b80 2015-03-25 18:00:08 +01:00
Christophe Simonis 6b70b80a0e [MERGE] forward port of branch 7.0 up to 881c10b 2015-03-25 17:41:53 +01:00
Loïc BELLIER 881c10b8ec [FIX] mrp: group attribute position
group_mrp_properties is intended for the property_ids field only, not the other
parts in the "Properties" page (probably wrongly named)
2015-03-25 15:25:22 +01:00
Denis Ledoux 0cf87d1671 [FIX] website_sale_options: keep website language on cart addition
In the ecommerce, when adding a product to the cart
while having website_sale_options installed
the product was added in the cart within the
website default language, not in the current
language of the visitor. The description of the product
was in the default website language (for instance, English)
instead of being in the visitor language (for instance, French).

The reason is quite simple: With website_sale_options, routes
are called in javascript, and these calls do not include the
website language within the url to the route
(e.g., call to '/shop/modal' instead of '/fr_FR/shop/modal)
and the language in the request context is therefore
the website default language.

The solution proposed here is probably not the cleanest possible,
a cleaner solution would be to define a new utility
JS function within website javascript to perform
Ajax calls, automatically adding the language to the url path
according to the current visitor language.

Another solution would be to set the lang of the session context
to the visitor language, and to use this lang instead of the
lang within request.context.

Nevertheless, none of the two above solutions can be performed in
stable releases, such as 8.0, to avoid any risks.

opw-631400
2015-03-25 14:33:33 +01:00
Olivier Dony 287b293283 [FIX] stock_account: valuation entry for reconciled neg quant not always possible
Skip the creation of the corrective valuation entry
when a negative quant is reconciled with an incoming
shipment, when:
 - the cost has not changed, so the journal entry would
   be useless (credit/debit = 0)
 - or, when the accounting period for the move causing
   the negative quant is already closed, and must not be
   updated (presumably the valuation was manually
   set before closing that period)
2015-03-25 12:38:17 +01:00
Thibault Delavallée ad1870b1eb [FIX] website_forum: fixes :
- do not show the popup about sharing on twitter if the post fails
due to karma for example
- added forgotten karma_required classes on post a link / post a
topic; those are missing since the forum update has been merged
without review a few month ago.
2015-03-25 11:51:42 +01:00
Antony Lesuisse f090652c99 [FIX] product: allow active pricelist version copy
Always set active false when copy is used to prevent the overlapping
version constraint.

Closes #5822
2015-03-24 23:11:25 +01:00
Denis Ledoux a93ef48a70 [FIX] base: access to preferences menu for portal users
Since revs 53582c2ea6 & f65c913027,
this was no more possible for portal users to read groups
on purpose, for privacy reasons.

fields_get of res.users model is overriden, for
the access rights form view features
(The groups selections and checkboxes).
At each call to fields_get, which happens at each call
to fields_view_get on the res.users model, operations are
done on the model res.groups (basically, to
build the selection groups and checkboxes). So,
each time a view of model res.users is displayed,
whatever the view, operations on res.group model were performed.

The thing is, these operations on res.groups
are actually needed only for the user access rights
view, or at least only for users having the group
Administration > Access rights. These group operations
aren't needed for the preferences view, nor for portal users.

We therefore avoid to do these if the user is not part of the
Administration > Access rights group, which lead to
performances improvment, and solves the fact
portal users couldn't access their user preferences view.

opw-627391
2015-03-24 18:25:13 +01:00
Christophe Matthieu 3587bcd305 [FIX] website summernote: create justify methods to align the text because the browser default method fail. 2015-03-24 16:24:34 +01:00