mirror of
https://github.com/grocy/grocy.git
synced 2025-08-20 12:20:22 +00:00
Show chore description on chorecard (closes #1759)
This commit is contained in:
@@ -202,3 +202,8 @@ function CleanFileName(fileName)
|
||||
// Umlaute seem to cause problems on Linux...
|
||||
return fileName.toLowerCase().replaceAll(/ä/g, 'ae').replaceAll(/ö/g, 'oe').replaceAll(/ü/g, 'ue').replaceAll(/ß/g, 'ss');
|
||||
}
|
||||
|
||||
function nl2br(s)
|
||||
{
|
||||
return s.replace(/([^>\r\n]?)(\r\n|\n\r|\r|\n)/g, "$1<br>$2");
|
||||
}
|
||||
|
@@ -6,6 +6,7 @@ Grocy.Components.ChoreCard.Refresh = function(choreId)
|
||||
function(choreDetails)
|
||||
{
|
||||
$('#chorecard-chore-name').text(choreDetails.chore.name);
|
||||
$('#chorecard-chore-description').html(nl2br(choreDetails.chore.description));
|
||||
$('#chorecard-chore-last-tracked').text((choreDetails.last_tracked || __t('never')));
|
||||
$('#chorecard-chore-last-tracked-timeago').attr("datetime", choreDetails.last_tracked || '');
|
||||
$('#chorecard-chore-tracked-count').text((choreDetails.tracked_count || '0'));
|
||||
|
Reference in New Issue
Block a user