[FIX]: fix Required Field problem in sugarcrm
bzr revid: atp@tinyerp.com-20110404115521-r3zsnwybk5j1izcx
This commit is contained in:
@@ -490,7 +490,6 @@ MAP_FIELDS = {'Opportunities': #Object Mapping name
|
||||
{'dependencies' : ['Users'], #Object to import before this table
|
||||
'process' : import_partners,
|
||||
},
|
||||
|
||||
'Users':
|
||||
{'dependencies' : [],
|
||||
'process' : import_users,
|
||||
|
||||
@@ -23,9 +23,9 @@ def sugarcrm_fields_mapp(dict_sugar, openerp_dict):
|
||||
fields=[]
|
||||
data_lst = []
|
||||
for key,val in openerp_dict.items():
|
||||
if key not in fields and dict_sugar.get(isinstance(val, list) and val[0] or val):
|
||||
if key not in fields and dict_sugar:
|
||||
fields.append(key)
|
||||
if isinstance(val, list):
|
||||
if isinstance(val, list) and val:
|
||||
data_lst.append(' '.join(map(lambda x : dict_sugar[x], val)))
|
||||
else:
|
||||
data_lst.append(dict_sugar.get(val,''))
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
<label string="" colspan="2"/>
|
||||
<button icon="gtk-cancel" special="cancel" string="_Cancel"/>
|
||||
<button name="open_import" string="_Login"
|
||||
type="object" icon="gtk-ok"/>
|
||||
type="object" icon="terp-camera_test"/>
|
||||
</group>
|
||||
</form>
|
||||
</field>
|
||||
|
||||
Reference in New Issue
Block a user