[MERGE] Merge parents
bzr revid: rim@openerp.com-20131224160005-xjwwptj9bdq3ys0p
This commit is contained in:
@@ -22,9 +22,8 @@ OpenERP Website CMS
|
||||
],
|
||||
'demo': [
|
||||
'data/website_demo.xml',
|
||||
'data/website_homepage_demo.xml',
|
||||
],
|
||||
'js': ['static/src/js/website.backend.js'],
|
||||
'qweb': ['static/src/xml/website.backend.xml'],
|
||||
'qweb' : ['static/src/xml/website.backend.xml'],
|
||||
'css': ['static/src/css/website.backend.css'],
|
||||
}
|
||||
|
||||
@@ -1,124 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<openerp>
|
||||
<data>
|
||||
|
||||
<template id="website_homepage_demo" inherit_id="website.homepage" name="Homepage for Website">
|
||||
|
||||
<xpath expr="//div[@id='wrap']" position="attributes">
|
||||
<attribute name="class">oe_structure</attribute>
|
||||
</xpath>
|
||||
|
||||
<xpath expr="//div[@id='wrap']" position="inside">
|
||||
<section data-snippet-id="title" class="mt32 mb32">
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-md-12" data-snippet-id="colmd">
|
||||
<h1 class="text-center">Build Great Website</h1>
|
||||
<h3 class="text-muted text-center">Super Easy. Fully Inline Edition.</h3>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section data-snippet-id="image-text" class="mt32 mb32 dark">
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-md-6 mt16 mb16" data-snippet-id="colmd">
|
||||
<img src="/website/static/src/img/image_text.jpg" class="img-responsive shadow"/>
|
||||
</div>
|
||||
<div class="col-md-6 mt32" data-snippet-id="colmd">
|
||||
<h3>A Section Subtitle</h3>
|
||||
<p>
|
||||
Write one or two paragraphs describing your product,
|
||||
services or a specific feature. To be successful
|
||||
your content needs to be useful to your readers.
|
||||
</p>
|
||||
<p>
|
||||
Start with the customer – find out what they want
|
||||
and give it to them.
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<div data-snippet-id="parallax">
|
||||
<div style="background-image: url('/website/static/src/img/banner/greenfields.jpg')" class="parallax oe_structure mt32 mb32 oe_big">
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-md-12 mt128 mb32" data-snippet-id="colmd">
|
||||
<h1 class="text-center">
|
||||
<b>A Great Title</b>
|
||||
</h1>
|
||||
<h3 class="text-center">
|
||||
And a motivating subtitle
|
||||
</h3>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<section class="mt32 mb32" data-snippet-id="three-columns">
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-md-12 text-center mt16 mb16" data-snippet-id="colmd">
|
||||
<h2>A Great Title</h2>
|
||||
<h3 class="text-muted">And a good subtitle</h3>
|
||||
</div>
|
||||
<div class="col-md-4" data-snippet-id="colmd">
|
||||
<img src="/website/static/src/img/china_thumb.jpg" class="img-rounded img-responsive"/>
|
||||
<h4 class="mt16">Streamline Recruitments</h4>
|
||||
<p>
|
||||
Post job offers and keep track of each application
|
||||
received. Follow applicants in your recruitment process
|
||||
with the smart kanban view.
|
||||
</p><p>
|
||||
Save time by automating some communications with email
|
||||
templates. Resumes are indexed automatically, allowing
|
||||
you to easily find for specific profiles.
|
||||
</p>
|
||||
</div>
|
||||
<div class="col-md-4" data-snippet-id="colmd">
|
||||
<img src="/website/static/src/img/desert_thumb.jpg" class="img-rounded img-responsive"/>
|
||||
<h4 class="mt16">Enterprise Social Network</h4>
|
||||
<p>
|
||||
Break down information silos. Share knowledge and best
|
||||
practices amongst all employees. Follow specific people
|
||||
or documents and join groups of interests to share
|
||||
expertise and documents.
|
||||
</p><p>
|
||||
Interact with your collegues in real time with live chat.
|
||||
</p>
|
||||
</div>
|
||||
<div class="col-md-4" data-snippet-id="colmd">
|
||||
<img src="/website/static/src/img/deers_thumb.jpg" class="img-rounded img-responsive"/>
|
||||
<h4 class="mt16">Leaves Management</h4>
|
||||
<p>
|
||||
Keep track of the vacation days accrued by each
|
||||
employee. Employees enter their requests (paid
|
||||
holidays, sick leave, etc), for managers to approve and
|
||||
validate. It's all done in just a few clicks. The
|
||||
agenda of each employee is updated accordingly.
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section class="mt32 mb32" data-snippet-id="cta">
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-md-12 text-center mt16 mb16" data-snippet-id="colmd">
|
||||
<a href="/page/website.aboutus" class="btn btn-info btn-lg">About us</a>
|
||||
<a href="/page/website.contactus" class="btn btn-primary btn-lg">Contact us</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
</xpath>
|
||||
|
||||
</template>
|
||||
|
||||
</data>
|
||||
</openerp>
|
||||
@@ -21,8 +21,7 @@ Online Events
|
||||
],
|
||||
'qweb': ['static/src/xml/*.xml'],
|
||||
'demo': [
|
||||
'data/event_demo.xml',
|
||||
'data/website_event_homepage_demo.xml',
|
||||
'data/event_demo.xml'
|
||||
],
|
||||
'installable': True,
|
||||
}
|
||||
|
||||
@@ -1,43 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<openerp>
|
||||
<data>
|
||||
|
||||
<!-- Events banner for homepage -->
|
||||
|
||||
<template id="website_event_homepage" inherit_id="website_sale.website_sale_homepage" name="Event banner for Homepage">
|
||||
|
||||
<xpath expr="//div[@id='shop_banner']/div" position="before">
|
||||
<ol class="carousel-indicators">
|
||||
<li data-slide-to="0" data-target="#shop_banner" class="active"></li>
|
||||
<li data-target="#shop_banner" data-slide-to="1" class=""></li>
|
||||
</ol>
|
||||
</xpath>
|
||||
|
||||
<xpath expr="//div[@id='shop_banner']/div" position="inside">
|
||||
<div style="background-image: url(/website/static/src/img/banner/aqua.jpg);" class="item text_only">
|
||||
<div class="container">
|
||||
<div contenteditable="false" class="carousel-caption content">
|
||||
<h2>Promote Your Events</h2>
|
||||
|
||||
<h3>Sell Tickets Online</h3>
|
||||
|
||||
<p><a href="/event" class="btn btn-success btn-large">Sample of Events</a></p>
|
||||
</div>
|
||||
|
||||
<div class="carousel-image hidden-xs">
|
||||
<img src="/website/static/src/img/banner/banner_picture.png" alt="Banner OpenERP Image" contenteditable="true"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</xpath>
|
||||
|
||||
<xpath expr="//*[@id='shop_banner']/div" position="after">
|
||||
<a data-slide="prev" href="#shop_banner" style="width: 10%" class="carousel-control left"><span class="glyphicon glyphicon-chevron-left"><span class="hidden">.</span></span></a>
|
||||
<a data-slide="next" href="#shop_banner" style="width: 10%" class="carousel-control right"><span class="glyphicon glyphicon-chevron-right"><span class="hidden">.</span></span></a>
|
||||
</xpath>
|
||||
|
||||
|
||||
</template>
|
||||
|
||||
</data>
|
||||
</openerp>
|
||||
@@ -19,7 +19,6 @@ OpenERP E-Commerce
|
||||
],
|
||||
'demo': [
|
||||
'data/website_sale_demo.xml',
|
||||
'data/website_sale_homepage_demo.xml',
|
||||
],
|
||||
'qweb': ['static/src/xml/*.xml'],
|
||||
'installable': True,
|
||||
|
||||
@@ -533,7 +533,7 @@ class Ecommerce(http.Controller):
|
||||
billing_info = dict(checkout)
|
||||
billing_info['parent_id'] = company_id
|
||||
|
||||
if not request.uid == request.registry['website'].get_public_user(cr, uid, context):
|
||||
if request.uid != request.registry['website'].get_public_user(cr, uid, context):
|
||||
partner_id = orm_user.browse(cr, uid, uid, context=context).partner_id.id
|
||||
orm_parter.write(cr, uid, [partner_id], billing_info, context=context)
|
||||
else:
|
||||
@@ -569,7 +569,9 @@ class Ecommerce(http.Controller):
|
||||
'partner_invoice_id': partner_id,
|
||||
'partner_shipping_id': shipping_id or partner_id
|
||||
}
|
||||
order_info.update(registry.get('sale.order').onchange_partner_id(cr, SUPERUSER_ID, [], order.partner_id.id, context=context)['value'])
|
||||
print order_info
|
||||
order_info.update(registry.get('sale.order').onchange_partner_id(cr, SUPERUSER_ID, [], partner_id, context=context)['value'])
|
||||
print order_info
|
||||
|
||||
order_line_obj.write(cr, SUPERUSER_ID, [order.id], order_info, context=context)
|
||||
|
||||
@@ -599,18 +601,15 @@ class Ecommerce(http.Controller):
|
||||
if tx and not tx.state == 'draft':
|
||||
return request.redirect('/shop/confirmation/%s' % order.id)
|
||||
|
||||
partner_id = False
|
||||
shipping_partner_id = False
|
||||
if order:
|
||||
if order.partner_id.id:
|
||||
partner_id = order.partner_id.id
|
||||
shipping_partner_id = order.partner_id.id
|
||||
if order.partner_shipping_id.id:
|
||||
shipping_partner_id = order.partner_shipping_id.id
|
||||
else:
|
||||
shipping_partner_id = order.partner_invoice_id.id
|
||||
|
||||
values = {
|
||||
'partner': partner_id,
|
||||
'order': order
|
||||
'order': request.registry['sale.order'].browse(cr, SUPERUSER_ID, order.id, context=context)
|
||||
}
|
||||
values.update(request.registry.get('sale.order')._get_website_data(cr, uid, order, context))
|
||||
|
||||
@@ -624,7 +623,7 @@ class Ecommerce(http.Controller):
|
||||
for acquirer in values['acquirers']:
|
||||
render_ctx['tx_url'] = '/shop/payment/transaction/%s' % acquirer.id
|
||||
acquirer.button = payment_obj.render(
|
||||
cr, uid, acquirer.id,
|
||||
cr, SUPERUSER_ID, acquirer.id,
|
||||
order.name,
|
||||
order.amount_total,
|
||||
order.pricelist_id.currency_id.id,
|
||||
@@ -660,7 +659,7 @@ class Ecommerce(http.Controller):
|
||||
# find an already existing transaction
|
||||
tx = context.get('website_sale_transaction')
|
||||
if not tx:
|
||||
tx_id = transaction_obj.create(cr, uid, {
|
||||
tx_id = transaction_obj.create(cr, SUPERUSER_ID, {
|
||||
'acquirer_id': acquirer_id,
|
||||
'type': 'form',
|
||||
'amount': order.amount_total,
|
||||
@@ -735,11 +734,6 @@ class Ecommerce(http.Controller):
|
||||
# cancel the quotation
|
||||
sale_order_obj.action_cancel(cr, SUPERUSER_ID, [order.id], context=request.context)
|
||||
|
||||
if email_act:
|
||||
create_ctx = email_act.get('context', context)
|
||||
compose_id = request.registry['mail.compose.message'].create(cr, uid, {}, context=create_ctx)
|
||||
request.registry['mail.compose.message'].send_mail(cr, uid, [compose_id], context=create_ctx)
|
||||
|
||||
# clean context and session, then redirect to the confirmation page
|
||||
request.registry['website'].ecommerce_reset(cr, uid, context=context)
|
||||
|
||||
|
||||
@@ -1,36 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<openerp>
|
||||
<data noupdate="1">
|
||||
|
||||
<!-- Shop Banner for homepage -->
|
||||
|
||||
<template id="website_sale_homepage" inherit_id="website.homepage" name="Shop banner for Homepage">
|
||||
<xpath expr="//div[@id='wrap']/section" position="before">
|
||||
|
||||
<div id="shop_banner" contenteditable="false" class="oe_snippet_body carousel slide oe_medium mb32" data-snippet-id="carousel">
|
||||
<div class="carousel-inner">
|
||||
<div style="background-image: url('/website/static/src/img/banner/color_splash.jpg')" class="item text_only active">
|
||||
<div class="container">
|
||||
<div contenteditable="false" class="carousel-caption content">
|
||||
<h2>OpenERP e-Commerce</h2>
|
||||
|
||||
<h3>An Awesome Shopping Experience</h3>
|
||||
|
||||
<p>
|
||||
<a href="/shop" class="btn btn-success btn-large">Visit Shop</a>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div class="carousel-image hidden-xs">
|
||||
<img src="/website/static/src/img/banner/banner_picture.png" alt="Banner OpenERP Image" contenteditable="true"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</xpath>
|
||||
</template>
|
||||
|
||||
</data>
|
||||
</openerp>
|
||||
@@ -888,7 +888,7 @@
|
||||
</div>
|
||||
<div class="col-lg-3 col-lg-offset-1 col-sm-3 text-muted" id="right_column">
|
||||
<h4>Bill To:</h4>
|
||||
<div t-field="website_sale_order.partner_invoice_id" t-field-options='{
|
||||
<div t-field="order.partner_invoice_id" t-field-options='{
|
||||
"widget": "contact",
|
||||
"fields": ["address", "name", "phone", "email"]
|
||||
}'/>
|
||||
@@ -897,10 +897,12 @@
|
||||
</div>
|
||||
|
||||
<h4 class="mt32">Ship To:</h4>
|
||||
<div t-if="website_sale_order.partner_shipping_id.id != website_sale_order.partner_invoice_id.id" t-field="website_sale_order.partner_shipping_id" t-field-options='{
|
||||
<t t-if="website_sale_order.partner_shipping_id and website_sale_order.partner_shipping_id.id != website_sale_order.partner_invoice_id.id">
|
||||
<div t-field="order.partner_shipping_id" t-field-options='{
|
||||
"widget": "contact",
|
||||
"fields": ["address", "name", "phone"]
|
||||
}'/>
|
||||
</t>
|
||||
<address t-if="website_sale_order.partner_shipping_id.id == website_sale_order.partner_invoice_id.id">Ship to the same address</address>
|
||||
<div class="mb32">
|
||||
<a href="/shop/checkout"><span class="fa fa-arrow-right"/> Change Address</a>
|
||||
|
||||
Reference in New Issue
Block a user