Commit 20be15f2 authored by Jérome Perrin's avatar Jérome Perrin

also encode path in utf8

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@22603 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 7d86cb2e
...@@ -247,7 +247,10 @@ for table_name in spreadsheets.keys():\n ...@@ -247,7 +247,10 @@ for table_name in spreadsheets.keys():\n
absolut_path_element_list.append(element[\'value\'])\n absolut_path_element_list.append(element[\'value\'])\n
# Get the next depth\n # Get the next depth\n
break\n break\n
category_properties[\'path\'] = \'/\'.join([base_category_id,] + absolut_path_element_list[::-1])\n path = \'/\'.join([base_category_id,] + absolut_path_element_list[::-1])\n
if same_type(path, u\'\'):\n
path = path.encode(\'utf8\')\n
category_properties[\'path\'] = path\n
\n \n
# Save the current raw path item value as title if no title column defined\n # Save the current raw path item value as title if no title column defined\n
if \'title\' not in category_properties.keys():\n if \'title\' not in category_properties.keys():\n
...@@ -285,6 +288,12 @@ return categories_spreadsheet_mapping\n ...@@ -285,6 +288,12 @@ return categories_spreadsheet_mapping\n
<none/> <none/>
</value> </value>
</item> </item>
<item>
<key> <string>_owner</string> </key>
<value>
<none/>
</value>
</item>
<item> <item>
<key> <string>_params</string> </key> <key> <string>_params</string> </key>
<value> <string>import_file</string> </value> <value> <string>import_file</string> </value>
...@@ -368,6 +377,7 @@ return categories_spreadsheet_mapping\n ...@@ -368,6 +377,7 @@ return categories_spreadsheet_mapping\n
<string>range</string> <string>range</string>
<string>searched_depth</string> <string>searched_depth</string>
<string>element</string> <string>element</string>
<string>path</string>
<string>clean_title</string> <string>clean_title</string>
</tuple> </tuple>
</value> </value>
...@@ -387,6 +397,12 @@ return categories_spreadsheet_mapping\n ...@@ -387,6 +397,12 @@ return categories_spreadsheet_mapping\n
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>Base_getCategoriesSpreadSheetMapping</string> </value> <value> <string>Base_getCategoriesSpreadSheetMapping</string> </value>
</item> </item>
<item>
<key> <string>uid</string> </key>
<value>
<none/>
</value>
</item>
<item> <item>
<key> <string>warnings</string> </key> <key> <string>warnings</string> </key>
<value> <value>
......
912 913
\ No newline at end of file \ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment