[IMP] Our Team Page
bzr revid: fp@openerp.com-20130929212431-e833rd9kvf40eepj
This commit is contained in:
parent
9f5a163bcb
commit
0ab6dfd448
|
@ -316,7 +316,7 @@
|
||||||
</t>
|
</t>
|
||||||
<div id="wrap" class="oe_structure">
|
<div id="wrap" class="oe_structure">
|
||||||
<div class="container mb32">
|
<div class="container mb32">
|
||||||
<div class="row">
|
<div class="row col-wrap" id="aboutus">
|
||||||
<div class="col-sm-12 text-center">
|
<div class="col-sm-12 text-center">
|
||||||
<h1>About us</h1>
|
<h1>About us</h1>
|
||||||
<h3 class="text-muted">A passion for great products</h3>
|
<h3 class="text-muted">A passion for great products</h3>
|
||||||
|
|
|
@ -9,7 +9,7 @@ class website_hr(http.Controller):
|
||||||
@website.route(['/page/website.aboutus'], type='http', auth="public", multilang=True)
|
@website.route(['/page/website.aboutus'], type='http', auth="public", multilang=True)
|
||||||
def blog(self, **post):
|
def blog(self, **post):
|
||||||
hr_obj = request.registry['hr.employee']
|
hr_obj = request.registry['hr.employee']
|
||||||
employee_ids = hr_obj.search(request.cr, request.uid, [(1, "=", 1)],
|
employee_ids = hr_obj.search(request.cr, request.uid, [('website_published', '=', True)],
|
||||||
context=request.context)
|
context=request.context)
|
||||||
values = {
|
values = {
|
||||||
'employee_ids': hr_obj.browse(request.cr, request.uid, employee_ids,
|
'employee_ids': hr_obj.browse(request.cr, request.uid, employee_ids,
|
||||||
|
|
|
@ -11,4 +11,4 @@ class hr(osv.osv):
|
||||||
}
|
}
|
||||||
|
|
||||||
def img(self, cr, uid, ids, field='image_small', context=None):
|
def img(self, cr, uid, ids, field='image_small', context=None):
|
||||||
return "/website/image?model=%s&field=%s&id=%s" % (self._name, field, ids[0])
|
return "/web/binary/image?model=%s&field=%s&id=%s" % (self._name, field, ids[0])
|
||||||
|
|
|
@ -0,0 +1,4 @@
|
||||||
|
.col-wrap .colsize {
|
||||||
|
height: 300px;
|
||||||
|
}
|
||||||
|
|
|
@ -22,29 +22,24 @@
|
||||||
|
|
||||||
|
|
||||||
<template id="aboutus" inherit_id="website.aboutus">
|
<template id="aboutus" inherit_id="website.aboutus">
|
||||||
<xpath expr="//div[@class='row']" position="inside">
|
<xpath expr="//div[@id='aboutus']" position="inside">
|
||||||
<t t-set="head">
|
<t t-set="head">
|
||||||
|
<link rel='stylesheet' href='/website_hr/static/src/css/website_hr.css'/>
|
||||||
<t t-raw="head or ''"/>
|
<t t-raw="head or ''"/>
|
||||||
</t>
|
</t>
|
||||||
<div class="col-sm-12 text-center">
|
<div class="clearfix"/>
|
||||||
<h2>Our team</h2>
|
<div class="col-sm-12 text-center" t-if="len(employee_ids)">
|
||||||
|
<h2>Our Team</h2>
|
||||||
</div>
|
</div>
|
||||||
<div t-foreach="employee_ids" t-as="employee" class="col-md-4 mt16">
|
<div t-foreach="employee_ids" t-as="employee" class="col-sm-3 col-lg-2 mt16 text-center colsize">
|
||||||
<div class="img-rounded" data-publish="">
|
<t t-call="website.publish_management"><t t-set="object" t-value="employee"/></t>
|
||||||
<t t-call="website.publish_management"><t t-set="object" t-value="employee"/></t>
|
<div class="clearfix"/>
|
||||||
<a class="pull-left" href="#">
|
<img t-att-src="employee.img('image_medium')" class="img shadow img-rounded"/>
|
||||||
<img t-att-src="employee.img('image_small')"/>
|
<div class="mt8">
|
||||||
</a>
|
<strong t-field="employee.name"></strong>
|
||||||
<div style="min-height: 64px; min-width: 130px;">
|
|
||||||
<h5 t-field="employee.name"/>
|
|
||||||
<div t-field="employee.department_id"/>
|
|
||||||
<div t-field="employee.job_id"/>
|
|
||||||
<div t-field="employee.work_location"/>
|
|
||||||
<div t-field="employee.work_phone"/>
|
|
||||||
<div t-field="employee.work_email"/>
|
|
||||||
<div t-field="employee.public_info"> </field>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
|
<div t-field="employee.job_id"/>
|
||||||
|
<div t-field="employee.public_info" class="text-muted mt16"/>
|
||||||
</div>
|
</div>
|
||||||
</xpath>
|
</xpath>
|
||||||
</template>
|
</template>
|
||||||
|
|
Loading…
Reference in New Issue