Commit Graph
37 Commits
Author SHA1 Message Date
Rémy Voet (ryv) 7d3c334948 [IMP] stock: add populate script 2020-11-30 12:50:09 +00:00
Adrian Torres 1daf8eb127 [FIX] *: set ondelete policy of required Selection fields
With this commit, Selection fields with `required=True` which are
extended via `selection_add` are given proper ondelete policies to
ensure the cleanup of records containing these extended options during
uninstall of the extending module.

This commit also cleans up leftover uninstall hooks that were being used
to handle the same set of problems prior to the ondelete mechanism being
implemented for Selection fields.

closes odoo/odoo#46325

Related: odoo/enterprise#9117
Signed-off-by: Raphael Collet (rco) <rco@openerp.com>
2020-03-30 13:42:04 +00:00
Adrian Torres b08729267b [FIX] stock: reset product.template records to default type
Stock introduces the option 'product' for the field `type` of the
`product.template` model.

If there exists records for this model with the aforementioned option
selected when the stock module is uninstalled, the records will remain
in the database for an indefinite amount of time, all while pointing to
an option that does no longer exist (except if the record was created by
the stock module itself), making the registry inconsistent and
eventually leading to a crash.

This is a known limitation of the ORM regarding Selection fields and
more specifically the `selection_add` mechanism, no "generic" solution
has been chosen thus far because it is not always clear which approach
should be taken:

    1) Delete the record?
    2) Set the option to a fallback, base option?
    3) Something else handled by the module itself?
    ...

In this case the second approach has been chosen and whenever the module
stock is uninstalled, all remaining product.template records of `type`
'product' will be reset to the default option defined by the field,
which as of this commit is 'consu'.

See opw#2193814

closes odoo/odoo#45341

X-original-commit: a84b2829c5fac9e2b0d8cb49a4e7aa73f7e0e2b2
Signed-off-by: Adrian Torres (adt) <adt@odoo.com>
2020-02-13 17:13:03 +00:00
jbm-odoo c230cfa0fe [ADD] stock_sms: Integration with stock pickings
The user can already send a confirmation email when the
Stock Picking is done. It'd be great to communicate the
same information by SMS.

In addition, the current mailing tool requires a manual
action. The idea is to automate the process via a
Setting instead.

id=1972567

closes odoo/odoo#35662

Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2019-08-21 10:04:54 +00:00
Pierre Masereel 5df621f665 [REF] stock: missing warehouse creation
We move the code from the 'post_init_hook' into a function tag, to be
consistent with the way we populate missing data when stock module is
installed.

TASK-ID: 1882269
2018-11-14 10:52:03 +00:00
Pierre Masereel cc62784924 [IMP] stock: create warehouse on existing companies
If companies are created before the installation of module stock, the
warehouses of those companes won't be created when stock module is
installed.

So we've created a post init hook to create the warehouses for the
existing companies.

TASK-ID: 58645
2018-08-30 15:32:42 +02:00
Christophe Simonis 5ad55264e4 [MERGE] forward port branch saas-15 up to b04c8eae6b 2018-03-01 18:02:30 +01:00
Adrian Torres 30db4cdd75 [FIX] stock: remove existing demo data on reinstall
Previous to this rev.:
    *Install stock w/ demo data
    *Uninstall stock
    *Reinstall stock

Result: Boom! Installation crashes.

Reason: The demo data installed with stock is not properly deleted after
the module is uninstalled, which causes issues/conflicts upon
reinstallation of the same demo data.

Solution: Remove any demo data of stock models upon installation if any
exist through a pre_init_hook, ideally this would be done by overriding
the unlink() of the affected models / setting some ondelete='cascade',
or even a uninstall_hook, however these solutions prove insufficient for
databases that are currently affected by the problem.

Fixes #22243
2018-02-26 15:12:25 +01:00
xmo-odoo b4429c2a91 [FIX] Various P3-related import changes
* LDAP import: python-ldap is not python3-compatible, pyldap is

  Warning: only supported from debian Stretch (current testing)?
  https://packages.debian.org/search?searchon=names&keywords=pyldap

* implicitly relative imports
* imports of moved or removed stdlib modules

issue #8530
2017-04-28 09:06:53 +02:00
Thibault Delavallée 69c4c87090 [MOV] stock: stock_incoterms
Incoterms models and views are moved in their own file. Impacted:

 - stock.incoterms

This commit only moves files. No change is done.

This last commit is done by renaming the remaining code in stock.py file. We
hope this helps keeping a bit of history by being able to retrieve the original
stock.py file.
2016-04-29 12:18:47 +02:00
Thibault Delavallée e28b83603b [MOV] stock: barcode, procurement, product, res_*
Move models not located in stock.py file and their views:

 - barcode
 - procurement
 - product
 - product.putaway, product.removal and stock.fixed.putaway.strat are
   extracted from product.py to their own product_strategy file
   to separate product and product.template code from stock specific
   code related to products
 - res_*
 - settings
 - web_planner

This commit only moves files. No change is done.
2016-04-29 12:18:36 +02:00
Yannick Tivisse ae9b29510a [MOV] stock: create res_company.py file from the overridden part in res_config 2016-02-04 11:19:09 +01:00
Darshan Kalola 7afe1b0a03 [ADD]stock: added new planner for inventory. 2015-08-27 11:37:07 +02:00
Olivier Dony 0bd4545348 [LEGAL] Use global LICENSE/COPYRIGHT files, remove boilerplate text
- Preserved explicit 3rd-party copyright notices
- Explicit boilerplate should not be necessary - copyright law applies
  automatically in all countries thanks to Berne Convention + WTO rules,
  and a reference to the applicable license is clear enough.
2015-06-02 03:16:04 +02:00
Leonardo Donelli 4a0b13ed92 [REF] remove vim modelines and resulting trailing blank lines
Let 2015 be a year without modelines!
cf #4174
2014-12-31 15:52:13 +01:00
Cedric Snauwaert 8e779fa761 [FIX]stock_barcode_interface: rework of the barcode interface to use bootstrap only
bzr revid: csn@openerp.com-20140226161003-kzgg5xfcrn8ucspx
2014-02-26 17:10:03 +01:00
Fabien Pinckaers c522a3d440 [IMP] Invoice on picking cleaned
bzr revid: fp@openerp.com-20130804115325-ejsbn2qoawnrgaic
2013-08-04 13:53:25 +02:00
Josse Colpaert ef8b995e2a [WIP] Make module stock work, for stock_location check removal strategy, journal_id, ...
bzr revid: jco@openerp.com-20130701191308-0ztvfe7bq4kfrqv8
2013-07-01 21:13:08 +02:00
Fabien Pinckaers 863ef7cf7a [IMP] WIP: big cleaning
bzr revid: fp@tinyerp.com-20130629221703-ti4qqcc8e3pc0ddh
2013-06-30 00:17:03 +02:00
Josse Colpaert 0ee90d26e1 [FIX] Put stock_fifo_lifo.py before report import in init.py
bzr revid: jco@openerp.com-20130517162114-3p7boe3km5zb01bn
2013-05-17 18:21:14 +02:00
Josse Colpaert 2397c71f43 [IMP] Put price computation (price calculation) to action_done and merge separate module in other modules
bzr revid: jco@openerp.com-20130513115942-flyx6wiuv79dtgln
2013-05-13 13:59:42 +02:00
Turkesh Patel (Open ERP) ba86cd5b55 [ADD] added new configuration view of warehouse
bzr revid: tpa@tinyerp.com-20120305132047-vzchsc9d5kb8z2xr
2012-03-05 18:50:47 +05:30
Harry (OpenERP) e087243c24 [REVIEW] account: rename file name of edi_invoice_action_data
bzr revid: hmo@tinyerp.com-20110714105716-xn54phkryzjuc94e
2011-07-14 16:27:16 +05:30
Hardik Ansodariy (OpenERP) d1ce89e2a5 [IMP]:Adding stock picking in edi
bzr revid: han@tinyerp.com-20110708093022-qm22kull5wq1vvmi
2011-07-08 15:00:22 +05:30
Mustufa Rangwala c47792af54 [REF]
bzr revid: mra@mra-laptop-20100706115632-ar3g22cjjqfo331i
2010-07-06 17:26:32 +05:30
mso fe28258171 [IMP]: stock:unused import removed which was causing server failure
bzr revid: mso@mso-20100318100813-zqhn6scrdekcz316
2010-03-18 15:38:13 +05:30
apa-tiny 606f433ba6 [MOVE]:stock:moved the report.py and report_view.xml in report folder.
bzr revid: apa@tinyerp.com-20100312114045-fi3tpjvynoqktmy3
2010-03-12 17:10:45 +05:30
rpa (Open ERP) 819f2a33fe [IMP]: stock: Improvement for wizards of consume and scrap moves + converted simple wizards to osv_memory wizards
bzr revid: rpa@openerp.co.in-20100219105145-f9pvx6g8ua9fjq0r
2010-02-19 16:21:45 +05:30
Stephane Wirtel fb3ef7a2f4 [FIX] Change the year of the copyright
bzr revid: stephane@openerp.com-20100112091839-a6p7tenhb4e4zxyx
2010-01-12 10:18:39 +01:00
PSO(OpenERP) eb0b928cc0 Changed licencing terms
bzr revid: hda@tinyerp.com-20091014111534-1vtk21rz8byhszzf
2009-10-14 16:45:34 +05:30
ChristopheChauvet(syleam) 41e8ed59ef changed encoding to coding in all py files
lp bug: https://launchpad.net/bugs/357182 fixed

bzr revid: hda@tinyerp.com-20091013055837-3ntnbe8b938xmk97
2009-10-13 11:28:37 +05:30
Stephane Wirtel 21f104a506 [IMP] Update the copyright to 2009
bzr revid: stephane@tinyerp.com-20090104221250-55q32ayj2t8kzb2k
2009-01-04 23:12:50 +01:00
Christophe Simonis f5fad0ba30 passing modules in GPL-3
bzr revid: christophe@tinyerp.com-20081103191856-jhcivvwb16fvz2os
2008-11-03 20:18:56 +01:00
Fabien Pinckaers 6345cd70a0 merge
bzr revid: fp@tinyerp.com-20080916103753-x2velfo42zzk2lb7
2008-09-16 12:37:53 +02:00
Christophe Simonis 3e3d897e88 add encoding comment and vim comment
bzr revid: christophe@tinyerp.com-20080723144147-77o5t9adx26a84lt
2008-07-23 16:41:47 +02:00
stw 0feb782c6a add Copyright and GPL license into the Header of Python files
bzr revid: stw-d9a6d631f7cfdab5a120a6b0104ce2dbf8644841
2008-06-16 11:00:21 +00:00
pinky a83dce15e0 New trunk
bzr revid: pinky-dedd7f8a42bd4557112a0513082691b8590ad6cc
2006-12-07 13:41:40 +00:00