|
|
@ -47,25 +47,29 @@ openerp.web_last_viewed_records = function(instance){ |
|
|
|
save_last_viewed_history: function(data){ |
|
|
|
localStorage[this.last_viewed_history_var] = JSON.stringify(data); |
|
|
|
}, |
|
|
|
// icon map: http://bistro.convergencecms.co/entypo
|
|
|
|
// icon map: http://fortawesome.github.io/Font-Awesome/icons/
|
|
|
|
_model2icon: { |
|
|
|
'res.partner':'+', |
|
|
|
'crm.lead':'4', |
|
|
|
'sale.order':'l', |
|
|
|
'account.analytic.account':'7', |
|
|
|
'crm.phonecall':'!', |
|
|
|
'hr.employee':'.', |
|
|
|
'hr.applicant':'-', |
|
|
|
'project.project':'t', |
|
|
|
'project.task':'W', |
|
|
|
'account.invoice':'h', |
|
|
|
'ir.module.module':'Z', |
|
|
|
'hr_timesheet_sheet.sheet': 'N', |
|
|
|
'res.groups': ',', |
|
|
|
'res.company': '_', |
|
|
|
'res.user': 'ó', |
|
|
|
'gamification.challenge':'è', |
|
|
|
'gamification.badge':'8', |
|
|
|
'account.analytic.account':'fa-book', |
|
|
|
'account.invoice':'fa-pencil-square-o', |
|
|
|
'calendar.event':'fa-calendar', |
|
|
|
'crm.lead':'fa-star', |
|
|
|
'crm.phonecall':'fa-phone', |
|
|
|
'hr.employee':'fa-male', |
|
|
|
'hr.payslip':'fa-money', |
|
|
|
'hr_timesheet_sheet.sheet': 'fa-clock-o', |
|
|
|
'ir.attachment': 'fa-file-o', |
|
|
|
'ir.module.module':'fa-plus-circle', |
|
|
|
'product.product': 'fa-sitemap', |
|
|
|
'project.issue':'fa-bug', |
|
|
|
'project.project':'fa-folder', |
|
|
|
'project.task':'fa-tasks', |
|
|
|
'purchase.order':'fa-shopping-cart', |
|
|
|
'purchase.order.line':'fa-shopping-cart', |
|
|
|
'res.company': 'fa-building-o', |
|
|
|
'res.groups': 'fa-users', |
|
|
|
'res.partner':'fa-user', |
|
|
|
'res.user': 'fa-user-plus', |
|
|
|
'sale.order':'fa-strikethrough', |
|
|
|
}, |
|
|
|
get_last_viewed_title: function(){ |
|
|
|
var titles = []; |
|
|
@ -82,7 +86,7 @@ openerp.web_last_viewed_records = function(instance){ |
|
|
|
if (!icon && /\.settings/.test(model)) |
|
|
|
icon = 'c'; |
|
|
|
if (icon) |
|
|
|
icon = _.str.sprintf('<span class="oe_last_viewed_icon">%s</span>', icon); |
|
|
|
icon = _.str.sprintf('<span class="oe_last_viewed_icon fa %s"></span>', icon); |
|
|
|
titles.push(_.str.sprintf('<a title="%s" href="#%s" class="oe_last_viewed_item %s">%s %s <span class="oe_e %s"/></a>', |
|
|
|
title, |
|
|
|
url, |
|
|
|