Skip to content

Commit 4b1949b

Browse files
authored
Merge pull request #90 from flutter-news-app-full-source-code/refactor/remove-status-column-from-content-tables
Refactor/remove status column from content tables
2 parents 0cd4ce3 + d27c4b4 commit 4b1949b

File tree

3 files changed

+5
-14
lines changed

3 files changed

+5
-14
lines changed

lib/content_management/view/headlines_page.dart

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -74,17 +74,15 @@ class _HeadlinesPageState extends State<HeadlinesPage> {
7474
),
7575
DataColumn2(
7676
label: Text(l10n.sourceName),
77-
size: ColumnSize.M,
77+
size: ColumnSize.S,
7878
),
79-
DataColumn2(label: Text(l10n.status), size: ColumnSize.S),
8079
DataColumn2(
8180
label: Text(l10n.lastUpdated),
82-
size: ColumnSize.M,
81+
size: ColumnSize.S,
8382
),
8483
DataColumn2(
8584
label: Text(l10n.actions),
8685
size: ColumnSize.S,
87-
fixedWidth: 120,
8886
),
8987
],
9088
source: _HeadlinesDataSource(
@@ -164,7 +162,6 @@ class _HeadlinesDataSource extends DataTableSource {
164162
),
165163
),
166164
DataCell(Text(headline.source.name)),
167-
DataCell(Text(headline.status.l10n(context))),
168165
DataCell(
169166
Text(
170167
DateFormat('dd-MM-yyyy').format(headline.updatedAt.toLocal()),

lib/content_management/view/sources_page.dart

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -75,17 +75,15 @@ class _SourcesPageState extends State<SourcesPage> {
7575
),
7676
DataColumn2(
7777
label: Text(l10n.sourceType),
78-
size: ColumnSize.M,
78+
size: ColumnSize.S,
7979
),
80-
DataColumn2(label: Text(l10n.status), size: ColumnSize.S),
8180
DataColumn2(
8281
label: Text(l10n.lastUpdated),
83-
size: ColumnSize.M,
82+
size: ColumnSize.S,
8483
),
8584
DataColumn2(
8685
label: Text(l10n.actions),
8786
size: ColumnSize.S,
88-
fixedWidth: 120,
8987
),
9088
],
9189
source: _SourcesDataSource(
@@ -165,7 +163,6 @@ class _SourcesDataSource extends DataTableSource {
165163
),
166164
),
167165
DataCell(Text(source.sourceType.localizedName(l10n))),
168-
DataCell(Text(source.status.l10n(context))),
169166
DataCell(
170167
Text(
171168
// TODO(fulleni): Make date format configurable by admin.

lib/content_management/view/topics_page.dart

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -72,15 +72,13 @@ class _TopicPageState extends State<TopicPage> {
7272
label: Text(l10n.topicName),
7373
size: ColumnSize.L,
7474
),
75-
DataColumn2(label: Text(l10n.status), size: ColumnSize.S),
7675
DataColumn2(
7776
label: Text(l10n.lastUpdated),
78-
size: ColumnSize.M,
77+
size: ColumnSize.S,
7978
),
8079
DataColumn2(
8180
label: Text(l10n.actions),
8281
size: ColumnSize.S,
83-
fixedWidth: 120,
8482
),
8583
],
8684
source: _TopicsDataSource(
@@ -158,7 +156,6 @@ class _TopicsDataSource extends DataTableSource {
158156
overflow: TextOverflow.ellipsis,
159157
),
160158
),
161-
DataCell(Text(topic.status.l10n(context))),
162159
DataCell(
163160
Text(
164161
// TODO(fulleni): Make date format configurable by admin.

0 commit comments

Comments
 (0)