summaryrefslogtreecommitdiff
path: root/addons/web/static/src
diff options
context:
space:
mode:
authorXavier Morel <xmo@openerp.com>2012-02-13 12:52:20 +0100
committerXavier Morel <xmo@openerp.com>2012-02-13 12:52:20 +0100
commit9552dbc215425a6490e871f244eb2fcbb8d25abb (patch)
tree33bbb6650300de6604aa813d90dc714fbce371f4 /addons/web/static/src
parentb1f1ca0ea1745503924b139594ac715780a64b72 (diff)
[FIX] replace :first-of-type by custom class in treeview styles, so open/close arrows appear in MSIE8
lp bug: https://launchpad.net/bugs/927631 fixed bzr revid: xmo@openerp.com-20120213115220-dt147bo51q2zqrnp
Diffstat (limited to 'addons/web/static/src')
-rw-r--r--addons/web/static/src/css/base.css8
-rw-r--r--addons/web/static/src/xml/base.xml5
2 files changed, 7 insertions, 6 deletions
diff --git a/addons/web/static/src/css/base.css b/addons/web/static/src/css/base.css
index 9cc03668fdc..c1ec5dfdf32 100644
--- a/addons/web/static/src/css/base.css
+++ b/addons/web/static/src/css/base.css
@@ -1916,14 +1916,14 @@ label.error {
white-space: nowrap;
display: block;
}
-.treeview-tr:first-of-type {
+.treeview-tr.oe-treeview-first {
background: transparent url(/web/static/src/img/expand.gif) 0 50% no-repeat;
}
-.oe-open .treeview-tr:first-of-type {
+.oe-open .treeview-tr.oe-treeview-first {
background-image: url(/web/static/src/img/collapse.gif);
}
-.treeview-tr:first-of-type span,
-.treeview-td:first-of-type span {
+.treeview-tr.oe-treeview-first span,
+.treeview-td.oe-treeview-first span {
margin-left: 16px;
}
diff --git a/addons/web/static/src/xml/base.xml b/addons/web/static/src/xml/base.xml
index 34313106399..c324d5ed5b1 100644
--- a/addons/web/static/src/xml/base.xml
+++ b/addons/web/static/src/xml/base.xml
@@ -579,20 +579,21 @@
t-att-data-id="record.id" t-att-data-level="level + 1">
<t t-set="children" t-value="record[children_field]"/>
<t t-set="class" t-value="children and children.length ? 'treeview-tr' : 'treeview-td'"/>
+ <t t-set="rank" t-value="'oe-treeview-first'"/>
<t t-set="style" t-value="'background-position: ' + 19*level + 'px; padding-left: ' + 19*level + 'px;'"/>
<td t-foreach="fields_view" t-as="field"
t-if="!field.attrs.modifiers.tree_invisible"
t-att-data-id="record.id"
t-att-style="color_for(record) + style "
- t-att-class="(fields[field.attrs.name].type === 'float') or (fields[field.attrs.name].type === 'integer')
- ? (class +' ' +'oe-number') : class">
+ t-attf-class="#{class} #{rank} #{(fields[field.attrs.name].type === 'float') or (fields[field.attrs.name].type === 'integer') ? 'oe-number' : ''}">
<span t-if="!field.attrs.modifiers.invisible" >
<t t-esc="render(record[field.attrs.name], fields[field.attrs.name])" />
</span>
<t t-set="class" t-value="'treeview-td'"/>
+ <t t-set="rank" t-value="''"/>
<t t-set="style" t-value="''"/>
</td>
</tr>