Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

base_import_async: properly register the module with connector framework #13

Merged
merged 4 commits into from
Apr 21, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
35 changes: 30 additions & 5 deletions base_import_async/README.md → base_import_async/README.rst
Original file line number Diff line number Diff line change
@@ -1,9 +1,16 @@
# Odoo Asynchronous import module
.. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg
:alt: License: AGPL-3

Odoo Asynchronous import module
===============================

This module extends the standard CSV import functionality
to import files in the background using the OCA/connector
framework.

Usage
=====

The user is presented with a new checkbox in the import
screen. When selected, the import is delayed in a background
job.
Expand All @@ -18,8 +25,6 @@ being imported is stored as an attachment to the job, making
it easy to download it, fix it and run a new import, possibly
in synchronous mode since the chunks are small.

## Scope

Any file that can be imported by the standard import mechanism
can also be imported in the background.

Expand All @@ -36,14 +41,19 @@ Other modules may benefit from this infrastructure in the following way
(`header`, `encoding`, `separator`, `quoting`,
`use_connector`, `chunk_size`).

## Known limitations
Known issues / Roadmap
======================

* There is currently no user interface to control the chunk size,
which is currently 100 by default. Should this proves to be an issue,
it is easy to add an option to extend the import screen.
* Validation cannot be run in the background.

## Credits
Credits
=======

Contributors
------------

Sébastien Beau (Akretion) authored the initial prototype.

Expand All @@ -57,3 +67,18 @@ Other contributors include:
* David Béal (Akretion)
* Jonathan Nemry (ACSONE)
* Laurent Mignon (ACSONE)

Maintainer
----------

.. image:: http://odoo-community.org/logo.png
:alt: Odoo Community Association
:target: http://odoo-community.org

This module is maintained by the OCA.

OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.

To contribute to this module, please visit http://odoo-community.org.
3 changes: 2 additions & 1 deletion base_import_async/__init__.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
###############################################################################
#
# Module for OpenERP
# Module for Odoo
# Copyright (C) 2014 ACSONE SA/NV (http://acsone.eu).
# Copyright (C) 2013 Akretion (http://www.akretion.com).
# @author Stéphane Bidoul <stephane.bidoul@acsone.eu>
Expand All @@ -23,3 +23,4 @@
###############################################################################

from . import models
from . import connector
2 changes: 1 addition & 1 deletion base_import_async/__openerp__.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
###############################################################################
#
# Module for OpenERP
# Module for Odoo
# Copyright (C) 2014 ACSONE SA/NV (http://acsone.eu).
# Copyright (C) 2013 Akretion (http://www.akretion.com).
# @author Stéphane Bidoul <stephane.bidoul@acsone.eu>
Expand Down
27 changes: 27 additions & 0 deletions base_import_async/connector.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# -*- coding: utf-8 -*-
###############################################################################
#
# Module for Odoo
# Copyright (C) 2014 ACSONE SA/NV (http://acsone.eu).
# Copyright (C) 2013 Akretion (http://www.akretion.com).
# @author Stéphane Bidoul <stephane.bidoul@acsone.eu>
# @author Sébastien BEAU <sebastien.beau@akretion.com>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundation, either version 3 of the
# License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
###############################################################################

from openerp.addons.connector.connector import install_in_connector

install_in_connector()
2 changes: 1 addition & 1 deletion base_import_async/models/__init__.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
###############################################################################
#
# Module for OpenERP
# Module for Odoo
# Copyright (C) 2014 ACSONE SA/NV (http://acsone.eu).
# Copyright (C) 2013 Akretion (http://www.akretion.com).
# @author Stéphane Bidoul <stephane.bidoul@acsone.eu>
Expand Down
2 changes: 1 addition & 1 deletion base_import_async/models/base_import_async.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
###############################################################################
#
# Module for OpenERP
# Module for Odoo
# Copyright (C) 2014 ACSONE SA/NV (http://acsone.eu).
# Copyright (C) 2013 Akretion (http://www.akretion.com).
# @author Stéphane Bidoul <stephane.bidoul@acsone.eu>
Expand Down