[ADD] Added some imgs to draw the stagesbar accordingly to the new design, very awful (just for testing)).
bzr revid: vta@openerp.com-20120806122150-sqq650v7vmvy34i6
This commit is contained in:
Binary file not shown.
|
After Width: | Height: | Size: 412 B |
Binary file not shown.
|
After Width: | Height: | Size: 424 B |
Binary file not shown.
|
After Width: | Height: | Size: 544 B |
Binary file not shown.
|
After Width: | Height: | Size: 652 B |
@@ -4702,7 +4702,8 @@ instance.web.form.FieldStatus = instance.web.form.AbstractField.extend({
|
||||
_.each(elemts, function(element){
|
||||
$item = $(element);
|
||||
if ($item.attr("data-id") != self.selected_value) {
|
||||
$item.attr("style", "cursor: pointer;");
|
||||
$item.attr("style", "cursor: pointer; background: #ba3d37;");
|
||||
$item.parent().attr("style", "background: #ba3d37;");
|
||||
$item.click(function(event){
|
||||
var data_id = parseInt($(this).attr("data-id"))
|
||||
self.view.dataset.call('stage_set', [[self.view.datarecord.id],data_id]).then(function() {
|
||||
@@ -4710,14 +4711,15 @@ instance.web.form.FieldStatus = instance.web.form.AbstractField.extend({
|
||||
});
|
||||
});
|
||||
} else {
|
||||
$item.addClass('oe_highlight');
|
||||
$item.attr("style", "background: #8a89ba;");
|
||||
$item.parent().attr("style", "background: #8a89ba;");
|
||||
}
|
||||
});
|
||||
}
|
||||
var colors = JSON.parse((this.node.attrs || {}).statusbar_colors || "{}");
|
||||
var color = colors[this.selected_value];
|
||||
if (color) {
|
||||
var elem = this.$element.find("li.oe_form_steps_active button");
|
||||
var elem = this.$element.find("li.oe_form_steps_active span");
|
||||
elem.css("color", color);
|
||||
}
|
||||
},
|
||||
|
||||
@@ -1032,8 +1032,11 @@
|
||||
<t t-set="size" t-value="widget.to_show.length"/>
|
||||
<t t-foreach="_.range(size)" t-as="i">
|
||||
<li t-att-class="widget.to_show[i][0] === widget.selected_value ? 'oe_form_steps_active' : ''">
|
||||
<button class="oe_form_steps_item" t-att-data-id="widget.to_show[i][0]"><t t-esc="widget.to_show[i][1]"/></button>
|
||||
<img t-att-src='_s + "/web/static/src/img/form_steps.png"' class="oe_form_steps_arrow" t-if="i < size - 1"/>
|
||||
<span class="oe_form_steps_item" t-att-data-id="widget.to_show[i][0]"><t t-esc="widget.to_show[i][1]"/></span>
|
||||
<span>
|
||||
<img t-att-src='_s + "/web/static/src/img/form_steps_separator_v2.png"' style="position: relative; left: 10px; top: 1px;" class="oe_form_steps_arrow" t-if="i < size - 1"/>
|
||||
</span>
|
||||
<!-- <img t-att-src='_s + "/web/static/src/img/form_steps_separator.png"' class="oe_form_steps_arrow" t-if="i < size - 1"/> -->
|
||||
</li>
|
||||
</t>
|
||||
</t>
|
||||
|
||||
Reference in New Issue
Block a user