From 2ccbbe8c9346e18877b26d17ecf9e49ab5d535bb Mon Sep 17 00:00:00 2001 From: Rushabh Mehta Date: Wed, 9 Apr 2014 19:15:19 +0530 Subject: [PATCH] multiple fixes --- frappe/public/css/appframe.css | 1 + frappe/public/css/bootstrap.css | 7 ++++-- frappe/public/js/frappe/form/comments.js | 28 +++++++++++----------- frappe/templates/base.html | 20 +++++++++------- frappe/templates/includes/breadcrumbs.html | 10 ++++---- frappe/templates/pages/contact.py | 26 ++++++++++---------- frappe/templates/pages/desk.html | 3 ++- frappe/widgets/form/utils.py | 12 ++++------ 8 files changed, 58 insertions(+), 49 deletions(-) diff --git a/frappe/public/css/appframe.css b/frappe/public/css/appframe.css index 8c965e9259..d87ff19eaa 100644 --- a/frappe/public/css/appframe.css +++ b/frappe/public/css/appframe.css @@ -29,6 +29,7 @@ white-space: nowrap; overflow: hidden; text-overflow: ellipsis; + padding: 7px 0px; margin: 0px; } diff --git a/frappe/public/css/bootstrap.css b/frappe/public/css/bootstrap.css index 95f7a0fd3b..49a9f383a1 100644 --- a/frappe/public/css/bootstrap.css +++ b/frappe/public/css/bootstrap.css @@ -1,3 +1,4 @@ + /*! * Bootstrap v3.1.0 (http://getbootstrap.com) * Copyright 2011-2014 Twitter, Inc. @@ -5,6 +6,7 @@ */ /*! normalize.css v3.0.0 | MIT License | git.io/normalize */ + html { font-family: sans-serif; -webkit-text-size-adjust: 100%; @@ -273,9 +275,10 @@ html { -webkit-tap-highlight-color: rgba(0, 0, 0, 0); } body { - font-family: Helvetica, Arial, sans-serif; + font-family: "Open Sans", Helvetica, Arial, sans-serif; font-size: 14px; - line-height: 1.42857143; + line-height: 1.6; + /*line-height: 1.42857143;*/ color: #333; background-color: #fff; } diff --git a/frappe/public/js/frappe/form/comments.js b/frappe/public/js/frappe/form/comments.js index bc4b29f795..aa30e4d442 100644 --- a/frappe/public/js/frappe/form/comments.js +++ b/frappe/public/js/frappe/form/comments.js @@ -47,7 +47,7 @@ frappe.ui.form.Comments = Class.extend({ c.image = frappe.user_info(c.comment_by).image; c.comment_on = dateutil.comment_when(c.creation); c.fullname = frappe.user_info(c.comment_by).fullname; - + $(repl('
\
\
\ @@ -65,13 +65,13 @@ frappe.ui.form.Comments = Class.extend({ me.delete_comment(name); return false; }) - + }); }, add_comment: function(btn) { var me = this, txt = me.input.val(); - + if(txt) { var comment = { doctype: "Comment", @@ -80,17 +80,17 @@ frappe.ui.form.Comments = Class.extend({ comment: txt, comment_by: user }; - + return frappe.call({ method: "frappe.widgets.form.utils.add_comment", args: { - doclist:[comment] + doc:comment }, btn: btn, callback: function(r) { if(!r.exc) { - me.frm.get_docinfo().comments = - r.message.concat(me.get_comments()); + me.frm.get_docinfo().comments = + [r.message].concat(me.get_comments()); me.frm.toolbar.show_infobar(); me.input.val(""); me.refresh(); @@ -109,17 +109,17 @@ frappe.ui.form.Comments = Class.extend({ }, callback: function(r) { if(!r.exc) { - me.frm.get_docinfo().comments = - $.map(me.frm.get_docinfo().comments, - function(v) { - if(v.name==name) return null; - else return v; + me.frm.get_docinfo().comments = + $.map(me.frm.get_docinfo().comments, + function(v) { + if(v.name==name) return null; + else return v; } ); me.refresh(); me.frm.toolbar.show_infobar(); } } - }); + }); } -}) \ No newline at end of file +}) diff --git a/frappe/templates/base.html b/frappe/templates/base.html index 3719823f15..458d5efba9 100644 --- a/frappe/templates/base.html +++ b/frappe/templates/base.html @@ -1,4 +1,8 @@ + @@ -6,7 +10,7 @@ {{ title }} - + {%- block head_include %}{% endblock -%} @@ -14,15 +18,15 @@ {%- if meta_description is defined %} {%- endif -%} - + {%- for link in web_include_js %} {%- endfor -%} - + {%- for link in web_include_css %} {%- endfor -%} - + {%- block style %}