mirror of
https://github.com/inventree/InvenTree.git
synced 2025-06-18 13:05:42 +00:00
Project Responsible (#5944)
* Add "responsible owner" to project code table * Update project code serializer * Update CUI project code table * Update PUI project code table * Update API version
This commit is contained in:
@ -145,6 +145,25 @@ onPanelLoad('project-codes', function() {
|
||||
sortable: true,
|
||||
title: '{% trans "Project Code" %}',
|
||||
},
|
||||
{
|
||||
field: 'responsible',
|
||||
title: '{% trans "Responsible" %}',
|
||||
formatter: function(value, row) {
|
||||
if (!row.responsible_detail) {
|
||||
return '-';
|
||||
}
|
||||
|
||||
var html = row.responsible_detail.name;
|
||||
|
||||
if (row.responsible_detail.label == '{% trans "group" %}') {
|
||||
html += `<span class='float-right fas fa-users'></span>`;
|
||||
} else {
|
||||
html += `<span class='float-right fas fa-user'></span>`;
|
||||
}
|
||||
|
||||
return html;
|
||||
}
|
||||
},
|
||||
{
|
||||
field: 'description',
|
||||
sortable: false,
|
||||
@ -171,6 +190,7 @@ onPanelLoad('project-codes', function() {
|
||||
fields: {
|
||||
code: {},
|
||||
description: {},
|
||||
responsible: {},
|
||||
},
|
||||
refreshTable: '#project-code-table',
|
||||
});
|
||||
|
Reference in New Issue
Block a user