Discussion:
[Erp5-dev] [PATCH] Problems with importing by CSV (Base_importCsvLine)
Łukasz Nowak
2006-11-30 13:26:40 UTC
Permalink
Hello,

Tomasz Brzezina send in erp5-users[1] problem report for CSV importing.
This patch is based on his suggestions.

Bye,
Luke
[1]http://thread.gmane.org/gmane.comp.python.zope.erp5.general/592/focus=597
--
?ukasz Nowak R&D Ventis http://www.ventis.com.pl/
tel: +48 32 392 10 60 int 37 fax: +48 32 392 10 61
https://ssl.ventis.com.pl/keys/lukasz.nowak.pub.asc
``Use the Source, Luke...''
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Base_importCsvLine.xml.patch
Type: text/x-patch
Size: 1436 bytes
Desc: not available
URL: <http://mail.tiolive.com/pipermail/erp5-dev/attachments/20061130/be8cbdd7/attachment.bin>
Yoshinori Okuji
2006-11-30 13:47:02 UTC
Permalink
Post by Łukasz Nowak
Tomasz Brzezina send in erp5-users[1] problem report for CSV importing.
This patch is based on his suggestions.
Isn't it better to use:

uid = object_property_dict.get('uid')
if uid is None:
...

YO
--
Yoshinori Okuji, Nexedi CTO
Nexedi: Consulting and Development of Free / Open Source Software
http://www.nexedi.com
ERP5: Full Featured High End Open Source ERP
http://www.erp5.com
ERP5 Wiki: Developer Zone for ERP5 Community
http://www.erp5.org
Tomasz Brzezina
2006-11-30 14:07:51 UTC
Permalink
Post by Yoshinori Okuji
Post by Łukasz Nowak
Tomasz Brzezina send in erp5-users[1] problem report for CSV importing.
This patch is based on his suggestions.
uid = object_property_dict.get('uid')
...
No, because we don't need uid at all. We only need to know if there is
uid or there is not. And if there is we connect to that object. If not -
we create a new object.
--
Tomasz Brzezina
Loading...