odoo/addons/website_mail/views/website_email_designer.xml

72 lines
3.1 KiB
XML
Raw Normal View History

<?xml version="1.0" encoding="utf-8"?>
<openerp>
<data>
<!-- Email Designer main page -->
<template id="designer_index" name="Email Designer">
<t t-call="website.layout">
<t t-set="head">
<script type="text/javascript" src="/website_mail/static/src/js/website_email_designer.js"></script>
</t>
<div id="wrap" class="container" t-ignore="True">
<div id="email_template" t-att-style="(object.body_html and len(templates)&gt;0) and 'display: none'" class="mb32">
<a class="mt16 btn btn-default pull-right"
t-attf-href="/web#return_label=Website&amp;model=#{model}&amp;id=#{res_id}&amp;view_type=form">
Back
</a>
<h1 class="page-header mt16">
Choose an Email Template
</h1>
<div class="row">
<div class="col-md-3 col-sm-4 text-center img-border">
<div class="email_preview_border">
<div class="email_preview js_content"/>
</div>
<h4>New Template</h4>
<button class="btn btn-primary js_template_set">Select</button>
</div>
<div t-foreach="templates" t-as="template" class="col-md-3 col-sm-4 text-center">
<div class="email_preview_border">
<div t-field="template.body_html" class="email_preview js_content"/>
</div>
<h4 t-field="template.name"/>
<button class="btn btn-primary js_template_set">Select</button>
</div>
</div>
</div>
<div id="email_designer" t-att-style="not (object.body_html and len(templates)&gt; 0) and 'display: none'" class="mb32">
<a class="mt16 btn btn-primary pull-right"
t-attf-href="/web#return_label=Website&amp;model=#{model}&amp;id=#{res_id}&amp;view_type=form">
Save and Continue
</a>
<h1 class="page-header mt16">
Design Your Email
</h1>
<div class="form-horizontal">
<div class="form-group">
<label class="col-sm-2 control-label">From:</label>
<div class="col-sm-7">
<span t-field="object.email_from" class="form-control"/>
</div>
</div>
<div class="form-group">
<label class="col-sm-2 control-label">Subject:</label>
<div class="col-sm-7">
<span t-field="object.name" class="form-control"/>
</div>
</div>
</div>
<hr/>
<div t-field="object.body_html" id="email_body"/>
</div>
</div>
</t>
<t t-set="website.footer"></t>
</template>
</data>
</openerp>