fixes in calendar event display on desktop

This commit is contained in:
Anand Doshi 2013-03-01 14:41:32 +05:30
parent 57f83ed36b
commit a6acdda094
2 changed files with 4 additions and 3 deletions

View File

@ -23,9 +23,10 @@ erpnext.desktop.render = function() {
module.name = m;
module.label = wn._(module.label);
module.gradient_css = wn.get_gradient_css(module.color, 45);
module._link = module.link.toLowerCase().replace("/", "-");
$module_icon = $(repl('\
<div id="module-icon-%(link)s" class="case-wrapper" \
<div id="module-icon-%(_link)s" class="case-wrapper" \
data-name="%(name)s" data-link="%(link)s">\
<div class="case-border" style="%(gradient_css)s">\
<i class="%(icon)s"></i>\
@ -84,7 +85,7 @@ erpnext.desktop.show_pending_notifications = function() {
add_circle('module-icon-messages', 'unread_messages', 'Unread Messages');
add_circle('module-icon-support-home', 'open_support_tickets', 'Open Support Tickets');
add_circle('module-icon-todo', 'things_todo', 'Things To Do');
add_circle('module-icon-calendar', 'todays_events', 'Todays Events');
add_circle('module-icon-calendar-event', 'todays_events', 'Todays Events');
add_circle('module-icon-projects-home', 'open_tasks', 'Open Tasks');
add_circle('module-icon-questions', 'unanswered_questions', 'Unanswered Questions');
add_circle('module-icon-selling-home', 'open_leads', 'Open Leads');

View File

@ -55,7 +55,7 @@ def get_todays_events():
SELECT COUNT(*) FROM `tabEvent`
WHERE owner = %s
AND event_type != 'Cancel'
AND event_date = %s""", (
AND %s between date(starts_on) and date(ends_on)""", (
webnotes.session.user, nowdate()))
return todays_events[0][0]