When I try to import a csv file Sales - sales/ customers (listview) the buttons "Validate" and "Import" stay grey instead of red after I have selected my csv file.
I have installed trunk (v8) on ubuntu 13.10 in a vmware 64 bits
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
When I try to import a csv file Sales - sales/ customers (listview) the buttons "Validate" and "Import" stay grey instead of red after I have selected my csv file.
I have installed trunk (v8) on ubuntu 13.10 in a vmware 64 bits
A patch exist for it : bugs.launchpad.net/openobject-addons/+bug/1302815/+attachment/4072225/+files/controller.patch
See this bug report : bugs.launchpad.net/openobject-addons/+bug/1302815
Finally, how to solve itï¼
If you know how to edit a python script ( .py ) and how to update modules in openerp, you can use the link I have posted above. Else, you will have to wait for them to fix it and put it in a nightly.
I use the online odoo version and my .csv seems well prepared (based on product export from Odoo which did work) but nothing happens after pressing the load button. A popup with the text "loading" shows up for a couple of seconds but afterwards the imported products are not available.
This issue can be resolved by making changes in addons/base_import/controller.py file and upgrading base_import module.
___________________________________
import simplejson
from openerp.http import Controller, route, request
class ImportController(Controller):
@route('/base_import/set_file')
def set_file(self, file, import_id, jsonp='callback'):
import_id = int(import_id)
written = request.session.model('base_import.import').write(import_id, {
'file': file.read(),
'file_name': file.filename,
'file_type': file.content_type,
}, request.context)
return 'window.top.%s(%s)' % (
jsonp, simplejson.dumps({'result': written}))
----------------------------------------
If you make a fake record in OpenERP, export it, delete it in OpenERP and then reimport the exported file, do the buttons still stay greyed out?
Yes, I have create a customer, exported that customer, deleted him and reimported te export file. Buttons still stay grey.
I do have the same issue. Tried with products, contacts and no luck.
It is a bug in the base.import module, when you select a file to import, it will throw an error. Would post it on the launchpad but did not found how. Here is the text of the error thrown:
2014-04-06 01:11:44,818 1573 ERROR EKYRAIL werkzeug: Error on request: Traceback (most recent call last): ....... File "/usr/share/pyshared/openerp/http.py", line 292, in checked_call return self.endpoint(a, *kw) File "/usr/share/pyshared/openerp/http.py", line 635, in __call__ return self.method(args, *kw) File "/usr/share/pyshared/openerp/http.py", line 338, in response_wrap response = f(args, *kw) TypeError: set_file() takes at least 4 arguments (4 given)