[minor] [fix] price list table

This commit is contained in:
Anand Doshi 2013-10-02 16:14:30 +05:30
parent 6f817b58ea
commit c49986f092
2 changed files with 14 additions and 0 deletions

View File

@ -0,0 +1,7 @@
.table-grid tbody tr {
cursor: pointer;
}
.table-grid thead tr {
height: 50px;
}

View File

@ -188,6 +188,13 @@ wn.ui.form.TableGrid = Class.extend({
if(!docname && row) docname = $(row).attr("data-docname");
$.each(me.fields, function(i, df) {
var val = me.dialog.get_values()[df.fieldname];
if(["Currency", "Float"].indexOf(df.fieldtype)!==-1) {
val = flt(val);
} else if(["Int", "Check"].indexOf(df.fieldtype)!==-1) {
val = cint(val);
}
wn.model.set_value(me.table_field.options, docname,
df.fieldname, val);