From 2268b4b4b2a4bc501ef5c15f697d8fe17cfaeec4 Mon Sep 17 00:00:00 2001 From: "Collin M. Barrett" Date: Sun, 18 Feb 2018 14:27:59 -0600 Subject: [PATCH] add subscribe back to main grid on large screens per https://github.com/collinbarrett/FilterLists/commit/cfecd906c1cb46679f39f687c4ca05ced11829fc#commitcomment-27637294 --- .../FilterListService/FilterListSummaryDto.cs | 1 + .../ClientApp/components/Home.tsx | 20 +++++++++++++++++++ 2 files changed, 21 insertions(+) diff --git a/src/FilterLists.Services/FilterListService/FilterListSummaryDto.cs b/src/FilterLists.Services/FilterListService/FilterListSummaryDto.cs index 9a7d4039e..0558d1484 100644 --- a/src/FilterLists.Services/FilterListService/FilterListSummaryDto.cs +++ b/src/FilterLists.Services/FilterListService/FilterListSummaryDto.cs @@ -4,5 +4,6 @@ public class FilterListSummaryDto { public int Id { get; set; } public string Name { get; set; } + public string ViewUrl { get; set; } } } \ No newline at end of file diff --git a/src/FilterLists.Web/ClientApp/components/Home.tsx b/src/FilterLists.Web/ClientApp/components/Home.tsx index 8114595cf..7380a4a9a 100644 --- a/src/FilterLists.Web/ClientApp/components/Home.tsx +++ b/src/FilterLists.Web/ClientApp/components/Home.tsx @@ -49,6 +49,16 @@ export class Home extends React.Component, IFilterListsS Cell: (row: any) => , style: { textAlign: "center" }, width: 100 + }, + { + Header: "Subscribe", + accessor: "viewUrl", + sortable: false, + Cell: (row: any) => , + style: { textAlign: "center" }, + width: 100, + headerClassName: "hidden-xs", + className: "hidden-xs" } ]}/>; } @@ -57,4 +67,14 @@ export class Home extends React.Component, IFilterListsS interface IFilterListSummaryDto { id: number; name: string; + viewUrl: string; +} + +//TODO: deduplicate function (maybe to a utils.js) also in ListDetailsModal.tsx +function SubscribeUrl(props: any) { + return + Subscribe + ; } \ No newline at end of file