* [task#134397,doing,0.3h] add render cell.
This commit is contained in:
@@ -21,3 +21,30 @@ $(document).off('click','.dtable-footer .batch-btn-repo').on('click', '.dtable-f
|
||||
data: postData
|
||||
});
|
||||
});
|
||||
|
||||
window.renderTaskCell = function(result, info)
|
||||
{
|
||||
const task = info.row.data;
|
||||
if(info.col.name == 'name' && result)
|
||||
{
|
||||
let html = '';
|
||||
if(task.mode)
|
||||
{
|
||||
html += "<span class='label gray-pale rounded p-0 size-sm whitespace-nowrap'>" + multipleAB + "</span>";
|
||||
}
|
||||
|
||||
if(task.isParent > 0)
|
||||
{
|
||||
html += "<span class='label gray-pale rounded p-0 size-sm whitespace-nowrap'>" + parentAB + "</span>";
|
||||
}
|
||||
else if(task.parent > 0)
|
||||
{
|
||||
html += "<span class='label gray-pale rounded p-0 size-sm whitespace-nowrap'>" + childrenAB + "</span>";
|
||||
}
|
||||
|
||||
if(task.color) result[0].props.style = 'color: ' + task.color;
|
||||
if(html) result.unshift({html});
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user