my email templaes like this ï¼
<!-- Email template for holiday -->
<record id="holidays_require_email" model="email.template">
<field name="name">holiday require</field>
<field name="model_id" ref="hr_holidays.model_hr_holidays"/>
<field name="email_from">holiday@test.com</field>
<field name="email_to">
<![CDATA[
% if len(object.employee_id.parent_id):
'codefans3@gmail.com '
% endif
% for p_id in object.employee_id.parent_id:
${p_id.work_email}
% endfor
]]>
</field>
<field name="subject">Holiday require</field>
<field name="body_html"><![CDATA[
${object.user_id.partner_id.name} have a leave action, please login in opnerp to comfirm
but this did not work.
the field parent_id is many2many
how can i do with this
thanks