From 11fe35901d8df7e2daccf4294650b71a6f5042cf Mon Sep 17 00:00:00 2001 From: "Collin M. Barrett" Date: Sat, 29 Sep 2018 18:48:47 -0500 Subject: [PATCH] add links to Licenses in table --- .../home/components/listsTable/columns/License.tsx | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/src/FilterLists.Web/ClientApp/modules/home/components/listsTable/columns/License.tsx b/src/FilterLists.Web/ClientApp/modules/home/components/listsTable/columns/License.tsx index cf4143e8d..71a8f7d2e 100644 --- a/src/FilterLists.Web/ClientApp/modules/home/components/listsTable/columns/License.tsx +++ b/src/FilterLists.Web/ClientApp/modules/home/components/listsTable/columns/License.tsx @@ -56,9 +56,11 @@ const sortMethod = (a: number, b: number, licenses: ILicense[]) => { } }; -const Cell = (licenseId: number, licenses: ILicense[]) => - licenseId - ?
- {licenses.filter((l: ILicense) => licenseId === l.id)[0].name} -
- : null; \ No newline at end of file +const Cell = (licenseId: number, licenses: ILicense[]) => { + const license = licenses.filter((l: ILicense) => licenseId === l.id)[0]; + return license + ?
+ {license.descriptionUrl ? {license.name} : license.name} +
+ : null; +}; \ No newline at end of file