{function getFieldId value=''}{foreach from=$allValues item='v' key='fieldId'}{if $value|md5 == $v}{{$fieldId}}{break}{/if}{/foreach}{/function} {function getXPath}{$path}{/function} {function xmlattr level=0} {assign var='_path' value=$path} {foreach from=$data key='name' item='value'} {if $_path != ''} {assign var='path' value=$_path|cat:"/@"|cat:$name} {else} {assign var='path' value='@'|cat:$name} {/if} {include file="../helpers/config_matchxml_dbfield.tpl" fieldId={getXPath path=$path} matched=$matched elem="{getXPath path=$path}" db_tables=$db_tables val=($own[0]|cat:'.'|cat:$own[1])} {/foreach} {/function} {function xmltag level=0 path=''} {assign var='_path' value=$path} {if $level == 0} {assign 'lastTag' value=($object_tag|substr:(($object_tag|strpos:",")+(($object_tag|explode:",")|count)-1):100)} {xmlattr data=$data->attributes() tag=$lastTag} {/if} {foreach from=$data key='name' item='value'} {if $_path != ''} {assign var='path' value=$_path|cat:"/"|cat:$name} {else} {assign var='path' value=$name} {/if} {if !is_string($value)} {xmlattr data=$value->attributes() tag=$name level=$level+1} {include file="../helpers/config_matchxml_dbfield.tpl" fieldId={getXPath path=$path} matched=$matched elem="{getXPath path=$path}" db_tables=$db_tables val=($own[0]|cat:'.'|cat:$own[1])} {/if} {if $value|count != 0} {xmlattr data=$value->attributes() tag=$name level=$level+1} {xmltag data=$value level=$level+1 path=$path} {/if} {/foreach} {if $level == 0} {/if} {/function}

{l s='Merge the same fields' mod='pshowimporter'}

{l s='You can match two or more the same fields to merge data.' mod='pshowimporter'}

{l s='For example select twice \'product name\' and check \'merge\' field to merge two file fields into product name.' mod='pshowimporter'}

{l s='Prepend' mod='pshowimporter'} - {l s='This allows you to add some value before the value from file.' mod='pshowimporter'}

{l s='Append' mod='pshowimporter'} - {l s='This allows you to add some value after the value from file.' mod='pshowimporter'}

{l s='Cut from start' mod='pshowimporter'} - {l s='This allows you to cut letters from start of value from file.' mod='pshowimporter'}

{l s='Cut from end' mod='pshowimporter'} - {l s='This allows you to cut letters from end of value from file.' mod='pshowimporter'}

{xmltag data=$data level=0 object_tag=$objectTag fieldId=0}
{l s='XML field path' mod='pshowimporter'} {l s='PrestaShop field' mod='pshowimporter'} {l s='Merge' mod='pshowimporter'} {l s='Prepend' mod='pshowimporter'} {l s='Append' mod='pshowimporter'} {l s='Cut from start' mod='pshowimporter'} {l s='Cut from end' mod='pshowimporter'}