summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDharmraj Jhala <dja@openerp.com>2015-06-24 12:23:45 +0530
committerDavid Monjoie <dmo@odoo.com>2015-08-14 10:22:39 +0200
commit67a74ebe2b242501f2828fe1f2d588392dce31e5 (patch)
tree797cfb93c0bef2c62c37791accac2537a7a2e570
parent36e62924668bcd0d19b0ef4712349848251ad1ef (diff)
[IMP] website_hr: usability improvements
- Added module description - Added public_info field to employee form view - Fixed bootstrap columns height issue on About Us page
-rw-r--r--addons/website_hr/models/hr.py2
-rw-r--r--addons/website_hr/static/description/index.html16
-rw-r--r--addons/website_hr/static/description/team_page.pngbin0 -> 503704 bytes
-rw-r--r--addons/website_hr/static/src/less/website_hr.less4
-rw-r--r--addons/website_hr/views/website_hr.xml11
-rw-r--r--addons/website_hr/views/website_hr_view.xml5
6 files changed, 34 insertions, 4 deletions
diff --git a/addons/website_hr/models/hr.py b/addons/website_hr/models/hr.py
index d202331218c..3f60e298756 100644
--- a/addons/website_hr/models/hr.py
+++ b/addons/website_hr/models/hr.py
@@ -8,7 +8,7 @@ class hr_employee(osv.osv):
_inherit = ['hr.employee', 'website.published.mixin']
_columns = {
- 'public_info': fields.text('Public Info'),
+ 'public_info': fields.char('Public Info'),
}
def _website_url(self, cr, uid, ids, field_name, arg, context=None):
diff --git a/addons/website_hr/static/description/index.html b/addons/website_hr/static/description/index.html
new file mode 100644
index 00000000000..c8861eb8642
--- /dev/null
+++ b/addons/website_hr/static/description/index.html
@@ -0,0 +1,16 @@
+<section class="oe_container">
+ <div class="oe_row oe_spaced">
+ <h2 class="oe_slogan">Our Team Page</h2>
+ <h3 class="oe_slogan">Share your employees details on website</h3>
+ <div class="oe_span6">
+ <div class="oe_big_img">
+ <img class="oe_picture oe_screenshot" src="team_page.png">
+ </div>
+ </div>
+ <div class="oe_span6">
+ <p class="oe_mt32">
+ Publish your employees public information on your "About Us" website page.
+ </p>
+ </div>
+ </div>
+</section>
diff --git a/addons/website_hr/static/description/team_page.png b/addons/website_hr/static/description/team_page.png
new file mode 100644
index 00000000000..d21ea17d890
--- /dev/null
+++ b/addons/website_hr/static/description/team_page.png
Binary files differ
diff --git a/addons/website_hr/static/src/less/website_hr.less b/addons/website_hr/static/src/less/website_hr.less
new file mode 100644
index 00000000000..8259b54833e
--- /dev/null
+++ b/addons/website_hr/static/src/less/website_hr.less
@@ -0,0 +1,4 @@
+
+.o_avatar_info_container {
+ height: 250px;
+}
diff --git a/addons/website_hr/views/website_hr.xml b/addons/website_hr/views/website_hr.xml
index 4d8be6e3b6e..db6ff086f26 100644
--- a/addons/website_hr/views/website_hr.xml
+++ b/addons/website_hr/views/website_hr.xml
@@ -2,6 +2,11 @@
<openerp>
<data>
<!-- Page -->
+<template id="assets_frontend" inherit_id="website.assets_frontend" name="website_hr_assets">
+ <xpath expr="." position="inside">
+ <link rel='stylesheet' type="text/less" href='/website_hr/static/src/less/website_hr.less'/>
+ </xpath>
+</template>
<template id="aboutus" inherit_id="website.aboutus" customize_show="True" name="Our Team">
<xpath expr="//div[@class='oe_structure']" position="after">
@@ -9,8 +14,8 @@
<div class="col-sm-12 text-center" t-if="len(employee_ids)">
<h2>Our Team</h2>
</div>
- <div t-foreach="employee_ids" t-as="employee" class="col-sm-3 col-lg-2 mt16 text-center colsize">
- <t t-call="website.publish_management">
+ <div t-foreach="employee_ids" t-as="employee" class="col-sm-3 col-lg-2 mt16 text-center o_avatar_info_container">
+ <t t-call="website.publish_management" class="text-center">
<t t-set="object" t-value="employee"/>
<t t-set="publish_edit" t-value="True"/>
</t>
@@ -20,7 +25,7 @@
<strong t-field="employee.name"></strong>
</div>
<div t-field="employee.job_id"/>
- <div t-field="employee.public_info" class="text-muted mt16"/>
+ <div t-field="employee.public_info" class="text-muted mt16 center-block"/>
</div>
</section>
</xpath>
diff --git a/addons/website_hr/views/website_hr_view.xml b/addons/website_hr/views/website_hr_view.xml
index 3abfb9d85b4..4d0b31cc1b9 100644
--- a/addons/website_hr/views/website_hr_view.xml
+++ b/addons/website_hr/views/website_hr_view.xml
@@ -13,6 +13,11 @@
<field name="website_published" widget="website_button"/>
</button>
</div>
+ <xpath expr="//page[@name='public']/group" position="inside">
+ <group>
+ <field name="public_info"/>
+ </group>
+ </xpath>
</field>
</record>