Commit Graph
809 Commits
Author SHA1 Message Date
Christophe Simonis eb672d81e6 [MERGE] forward port branch saas-11 up to b5b8239870 2017-04-24 11:09:52 +02:00
Christophe Simonis b5b8239870 [MERGE] forward port branch 9.0 up to 9e6860a228 2017-04-24 11:07:55 +02:00
Nicolas Martinelli 9e6860a228 [FIX] web: make DB name more flexible 2017-04-24 08:02:22 +02:00
Christophe Simonis 814c550913 [MERGE] forward port branch saas-11 up to a0ff1f2ad8 2017-04-21 14:34:11 +02:00
Christophe Simonis a0ff1f2ad8 [MERGE] forward port branch 9.0 up to 8de514f805 2017-04-21 14:19:05 +02:00
Christophe Simonis 144ff9a61a Revert "[FIX] web: refuse DB name with space"
This is too restrictive.

This reverts commit 606712a5d2.
2017-04-21 14:02:58 +02:00
Christophe Simonis 9e159ef204 [MERGE] forward port branch saas-11 up to f830c7c3e3 2017-04-12 18:51:16 +02:00
Christophe Simonis aea68e4730 [MERGE] forward port branch 9.0 up to 51fe54dd8d 2017-04-07 17:34:51 +02:00
Nicolas Martinelli 606712a5d2 [FIX] web: refuse DB name with space
In v8, it was not allowed to create a DB with a name containing a space.
This should still be the case from v9 since it causes issuesfor backup
scripts, for example.

Reintroduces 1a0e9063d4

opw-727613
2017-04-07 14:53:01 +02:00
Nicolas Martinelli 7a03f9ce93 [FIX] web, sale, account: company logo
The notification mail template of a SO and an Invoice displays the logo
of the company. However, the logo is always the logo of the superuser's
company.

When accessing the logo from an email client, the UID is not defined.
Therefore, we fall back on the superuser, and display the logo of his
company.

We add the support of a `company` key in the kwargs, so we can force the
company from which we retrieve the logo. Note that this key was used
elsewhere, such as:

addons/web/static/src/js/web_client.js

opw-705420
2017-02-14 12:14:23 +01:00
Aaron Bohy f4bb9bc976 [FIX] im_livechat,web: partial revert of 7f8fe10766
Proxy.load is required by the livechat when it is embedded in an
external page, so that it is able to get the static xml files
(with the correct base_url).

opw-706497
2017-01-31 10:52:08 +01:00
Christophe Simonis 6804085b8c [MERGE] forward port branch saas-11 up to b9374d5c21 2017-01-23 13:56:18 +01:00
Nicolas Lempereur 734d9b56da [FIX] web: conserve /id for saved export list
With 003d85b instead of getting the name of the relation
field_relation we get field_relation/id.

But the data about the related fields are not gotten all at once when
opening the export modal. They are gotten by clicking on the arrow of
the related record.

So we need to have these /id information saved in the export list,
otherwise for example the related records can be missing when exporting
from an export list, whilst everything was OK without using the saved
export list.

With the previous change, an export list could contain an id and .id
fields for the same relational field, so a change must also be done in
fields_info method used when getting a saved list.

opw-665994
opw-693535

note: adapted forward-port of 8.0's 29be9ae80 which was lost when
merging web enterprise onto web community.
2017-01-19 16:24:53 +01:00
Dharmang Soni ef96bd0669 [ADD] web: Added database list controller 2016-10-03 18:20:25 +02:00
Simon Lejeune 5c6087e38e [FIX] web: dropping a database leads to an unusable cursor
Explicitly remove the cursor of the request. Dropping a database
is not transactional and if overrides of ir_http's dispatch worked
with the database (for example, utm), we are not able to commit
the changes at the end of the request.

It worked nice before rev 40561b0fb6 that changed the use of self.pool
by request.env. Note: a cursor is always attached to an environment. Since
the call to super possibly broke the cursor (for example by dropping the
database), the end of the dispatch operation that try to commit and/or close
the cursor could possibly result in the traceback 'unable to close a closed
cursor' with request.env. With self.pool, it didn't happen because the
code actually called in the utm's dispatch override doesn't use a cr
and so there's nothing to close.
2016-09-21 15:56:59 +02:00
Christophe Simonis 298e2032ea [MERGE] forward port branch saas-12 up to 9f28139 2016-09-09 18:13:31 +02:00
Christophe Simonis 7a02b90e17 [MERGE] forward port branch saas-11 up to dc4d6b6 2016-09-09 15:43:06 +02:00
Christophe Simonis dc4d6b6a7a [MERGE] forward port branch saas-10 up to e1bd405 2016-09-09 15:14:39 +02:00
Christophe Simonis e1bd405d8c [MERGE] forward port branch 9.0 up to af87c57 2016-09-09 11:49:48 +02:00
Christophe Simonis af87c57e51 [MERGE] forward port branch saas-6 up to f98665f 2016-09-09 11:26:15 +02:00
Christophe Simonis f98665f9b6 [MERGE] forward port branch 8.0 up to b17b2a2 2016-09-09 10:52:34 +02:00
Olivier Dony b17b2a2eb7 [FIX] http: do not allow passing spaces around db in URL param
Until 9.0 our psycopg2 DSN connection strings do not allow having
spaces within the db name, and passing some can cause duplicate
registries to be loaded.

Stripping spaces is a simple workaround until we actually support
spaces within db names.

Fixes #13078
2016-09-09 09:28:10 +02:00
Christophe Simonis 1a77d9d02a [MERGE] forward port branch saas-12 up to 476cb5a0 2016-09-03 23:57:57 +02:00
Christophe Simonis 55d2e4b7cf [MERGE] forward port branch saas-11 up to bde7f88 2016-09-02 17:23:34 +02:00
Christophe Simonis 54e5bbdf35 [MERGE] forward port branch saas-10 up to 897b9b8 2016-09-02 16:28:28 +02:00
Christophe Simonis 897b9b8fc0 [MERGE] forward port branch 9.0 up to cb1ae53 2016-09-02 15:19:39 +02:00
Pierre Masereel 665bb3cb62 [FIX] web: correctly redirect after database creation
When a database is created, we are not auto-logged in to the new
database anymore because the login passed to the authentication request
is 'admin' instead of the one set in the creation form.

To fix this issue, we used the login parameter from the creation form
in the authentication request. We also set the login field to
required in the create database form view.

This bug comes from rev https://github.com/odoo/odoo/commit/903733a32
2016-09-01 15:23:57 +02:00
Raphael Collet a7445b4053 [REF] registry: move functionalities from RegistryManager to Registry
The API of `Registry` has been modified as follows:
 - `Registry(name)` returns the registry of the given database
 - `Registry.new(name)` forces the creation of a new `Registry` object
 - `Registry.delete(name)` discards the given registry
 - `Registry.delete_all()` discards all registries
 - `registry.setup_signaling()` initializes the signaling for `registry`
 - `registry.check_signaling()` returns an up-to-date `registry`
 - `registry.signal_registry_change()` notifies that `registry` has changed
 - `registry.signal_caches_change()` notifies potential cache invalidation
2016-09-01 13:43:45 +02:00
Raphael Collet 75dc39e042 [REF] openerp.http: make request.context consistent with request.env.context 2016-08-31 17:21:58 +02:00
Raphael Collet 4033ccc129 [REM] openerp.http: discard deprecated methods and properties 2016-08-31 17:21:57 +02:00
Raphael Collet 72afd28230 [FIX] remove or convert old-API calls 2016-08-31 17:21:55 +02:00
Raphael Collet 16696b2a05 [FIX] openerp, web: make execute and call_kw invoke methods in the new API
Also refactor the test to prevent private methods to be remotely called.
2016-08-31 17:21:55 +02:00
Christophe Simonis f4738e7bb5 [MERGE] forward port branch saas-12 up to 78e9c7f 2016-08-26 18:06:17 +02:00
Christophe Simonis de0d503421 [MERGE] forward port branch saas-11 up to f0c8224 2016-08-26 16:59:45 +02:00
Christophe Simonis 717a4a51a5 [MERGE] forward port branch saas-10 up to 7a4116c 2016-08-26 14:57:43 +02:00
Christophe Simonis 5c2025a3af [MERGE] forward port branch 9.0 up to c578fb7 2016-08-25 18:23:47 +02:00
Raphael Collet 20b1a9bcaa [FIX] web: pass context in kwargs, otherwise it is taken as load 2016-08-23 16:04:43 +02:00
Jeremy Kersten 97b702a7b0 [FIX] web: fix mimetype for content_image
Since the commit odoo/odoo@36e875e which disable the second-guess from browser,
IE cannot display picture from Odoo where mimetype is wrong.
Before this commit, IE and probably other browser which one respect the header
'nosniff' don't display picture not_found and resized picutre via controller if
the original was not of type 'png'.

Eg: when we return the placholder 'not_found' if you don't have permission,
or when your resize the picture, ... we need to force the mime-type with the
new one and not keep the original mimetype.

This commit closes #13193
2016-08-22 16:25:52 +02:00
Christophe Simonis 235ed4b2c1 [MERGE] forward port branch saas-12 up to 9ad5f26 2016-08-20 18:08:19 +02:00
Christophe Simonis 9ad5f26b3f [MERGE] forward port branch saas-11 up to 3a2147d 2016-08-20 17:18:31 +02:00
Christophe Simonis 3a2147d95c [MERGE] forward port branch saas-10 up to bc1a0a3 2016-08-20 16:57:36 +02:00
Jeremy Kersten 54e4f3f96b [FIX] web: allow to use content_disposable without registry
When a user connect to /web/database/manager directly without the
login page before, the request don't have registry.
When the user click to backup a db, a traceback was raised:
    return request.registry['ir.http'].content_disposition(filename)
    TypeError: 'NoneType' object has no attribute 'getitem'
Because it was impossible to call content_diposable from ir_http
without registry.

Now content disposable has been moved in http.py and is callable from
anywhere.

This commit closes #13192
This commit closes #11583
2016-08-19 18:31:01 +02:00
Christophe Simonis bc1a0a32ca [MERGE] forward port branch 9.0 up to 58cbcba 2016-08-19 16:59:29 +02:00
Martin Trigaux 0122c05eff [FIX] web: avoid report with invalid sheet name
This commit does not fix any bug in odoo/odoo but helps fixing #12788
Needed for odoo/enterprise#433
2016-08-19 15:28:27 +02:00
fwi-odoo f88a889409 [MIG] web: migrate controllers to new API 2016-08-03 13:42:05 +02:00
fwi-odoo 7d487c00a6 [IMP] web: remove void file, replace openerp tags, add license, clean imports 2016-08-03 13:42:00 +02:00
Christophe Simonis cfb0c0dead [MERGE] forward port branch saas-11 up to 7ae5121 2016-07-25 17:17:15 +02:00
Christophe Simonis 7ae5121877 [MERGE] forward port branch saas-10 up to fc0f023 2016-07-25 16:06:15 +02:00
Christophe Simonis fc0f023053 [MERGE] forward port branch 9.0 up to 1089dcf 2016-07-25 15:07:47 +02:00
Christophe Simonis 1089dcf15c [MERGE] forward port branch saas-6 up to 7df4ea5 2016-07-25 14:33:15 +02:00