summaryrefslogtreecommitdiff
path: root/addons/gamification/static/src/xml/gamification.xml
diff options
context:
space:
mode:
authorMartin Trigaux <mat@openerp.com>2013-03-25 16:39:53 +0100
committerMartin Trigaux <mat@openerp.com>2013-03-25 16:39:53 +0100
commit364612d0be52e6677a26f8a083d58b52d81c7f0a (patch)
treefe732214c784cc83794c117b0a786d7b6ade6cbb /addons/gamification/static/src/xml/gamification.xml
parent0ef116ce06e6795af661d924a211938f198a4289 (diff)
[IMP] use board view for sidebar
bzr revid: mat@openerp.com-20130325153953-zch12sfx62s5i6xc
Diffstat (limited to 'addons/gamification/static/src/xml/gamification.xml')
-rw-r--r--addons/gamification/static/src/xml/gamification.xml25
1 files changed, 23 insertions, 2 deletions
diff --git a/addons/gamification/static/src/xml/gamification.xml b/addons/gamification/static/src/xml/gamification.xml
index 2019a9f86c8..be287bdccaf 100644
--- a/addons/gamification/static/src/xml/gamification.xml
+++ b/addons/gamification/static/src/xml/gamification.xml
@@ -5,7 +5,8 @@
<t t-name="gamification.goal_list_to_do">
<div t-foreach="widget.goals_info.info" t-as="plan">
<h3><t t-esc="plan.name"/></h3>
- <ul class="oe_goals_list">
+ <t t-if="plan.visibility_mode == 'progressbar'">
+ <ul class="oe_goals_list">
<li t-foreach="plan.goals" t-as="goal">
<a class="oe_goal_action" t-att-id="goal.id">
<strong t-attf-class="#{goal.state == 'reached' ? 'oe_goal_reached' : goal.state == 'failed' ? 'oe_goal_failed' : ''}"><t t-esc="goal.type_name" /></strong>
@@ -26,7 +27,27 @@
</a>
</p>
</li>
- </ul>
+ </ul>
+ </t>
+ <t t-if="plan.visibility_mode == 'board'">
+ <table width="100%" border="1" t-foreach="plan.planlines" t-as="planline">
+ <tr>
+ <th colspan="4"><t t-esc="planline.goal_type"/></th>
+ </tr>
+ <tr>
+ <th>#</th>
+ <th>Pers.</th>
+ <th>compl.</th>
+ <th>Current</th>
+ </tr>
+ <tr t-foreach="planline.goals" t-as="goal" t-attf-class="#{goal.completness >= 100 ? 'oe_bold' : ''}">
+ <td><t t-esc="goal.rank" /></td>
+ <td><t t-esc="goal.user_name" /></td>
+ <td><progress t-att-value="goal.completeness" max="100" /></td>
+ <td><t t-esc="goal.current" />/<t t-esc="goal.target_goal" /></td>
+ </tr>
+ </table>
+ </t>
</div>
</t>