Commit Graph

30 Commits

Author SHA1 Message Date
Chris Hill-Scott
2de17bd415 Make precompiled template name bold
To match template link.
2018-05-15 13:06:36 +01:00
Ken Tsang
1d5f8ce15e Remove template link from precompiled letters from dashboard 2018-03-07 23:13:36 +00:00
Chris Hill-Scott
9f20ea4b7e Revert "Merge pull request #1336 from alphagov/revert-show-notifications"
This reverts commit 7e354ff341, reversing
changes made to 6f3bcff32f.
2017-06-30 14:01:18 +01:00
Chris Hill-Scott
b450a349a3 Revert "Merge pull request #1328 from alphagov/notification-page-reworked"
This reverts commit 1797162248, reversing
changes made to 95b4d9eb31.
2017-06-23 15:56:25 +01:00
Chris Hill-Scott
010886e5be Make clickable areas bigger on tables with links
Generally, bigger click areas are better[1], as long as they don’t cause
ambiguity or accidental clicks.

This commit expands the clickable area of tables where the left-hand
column is a link to include the meta information under the link.

We can’t make the whole row clickable, because sometimes we have links
in the right hand column which go to a different place

This commit also removes the CSS for `.spark-bar-label`, because these
elements are visually identical to `file-list`s now.

1. https://en.wikipedia.org/wiki/Fitts%27s_law
2017-06-21 17:57:21 +01:00
Chris Hill-Scott
2f68dc613c Put template IDs back on the dashboard
Removed as part of refactoring the code to generate the graphs of
template usage on the dashboard:
4a226a7a29 (diff-cf78cb5c29a2d3c4d45b61d8617824b7L29)

Didn’t realise that they were used by the functional tests.

This commit puts them back while keeping the code reuse.
2017-03-20 12:27:37 +00:00
Chris Hill-Scott
4a226a7a29 Show template usage broken down by month
This follows on from:
- https://github.com/alphagov/notifications-admin/pull/1094
- https://github.com/alphagov/notifications-admin/pull/1109

It depends on:
- [ ] https://github.com/alphagov/notifications-api/pull/829

A year is too long. Month-by-month is a better timeframe for making
decisions or seeing patterns in your usage.
2017-03-16 14:04:37 +00:00
Chris Hill-Scott
6404997b93 Don’t right align template stats for one template
We don’t show the graph if a user has only used one template.
2017-02-15 14:01:52 +00:00
Chris Hill-Scott
008b9b4cef Make template usage graph take up 100% of width
The bars were sitting in a table cell with some right padding, so they
never extended all the way to the right. Making it right-aligned removes
this padding, then setting the text to left aligned keeps things looking
the same.
2017-02-15 13:24:21 +00:00
Imdad Ahad
d099a080e6 Add ids for dashboard numbers and stats to be used by the functional tests 2016-10-13 10:52:09 +01:00
Martyn Inglis
55c4443a05 Admin app uses the new API response formats. 2016-08-18 15:30:57 +01:00
Chris Hill-Scott
fa7345e9d0 Make template statistics on the dashboard a table
It was a `<dl>` before which is kinda weird. Especially when the jobs
table was a real `<table>`.

It also means we can give it column headings so that new and invited
users have a better idea of what it is.
2016-06-17 16:30:02 +01:00
Chris Hill-Scott
a0f6956eab Give headline numbers a blue, not black background
These numbers don’t look very clickable white-on-black.

Blue is the colour of links, so lets see if they are more clickable in
blue.

The same clicking-a-big-number thing is also happening on the activity
page, so this commit also changes the activity page to look the same.
2016-06-14 11:00:56 +01:00
Chris Hill-Scott
e5d2514846 Make template graphs look consistent with page
The graphs of template usage feel a bit weird to me now.

1. They are counts of messages, but the numbers are very small
   not big like we do everywhere else (eg the counts on a job)

2. There’s a lot of blue, especially for something that you can’t
   click

This commit makes the numbers bigger and the bar chart grey.
2016-06-14 11:00:56 +01:00
Chris Hill-Scott
c3d78f5652 Show template stats even if there’s only 1 row
If you’re only ever sending one template it’s really useful to be able
to jump straight to that template from the dashboard. So this commit:
- shows the template stats even if there’s only one row
- hides the bar chart if there’s only one row (because it will always be
  100%, and won’t be obvious what it is without its siblings)
2016-05-13 10:26:57 +01:00
Chris Hill-Scott
8a4b0ba88c Add a message count component
The logic to say ‘1 email sent’ vs ‘12 text messages sent’ is repeated
all over the place. So this commit adds a component to put it in one
place.
2016-05-13 10:26:57 +01:00
Chris Hill-Scott
3dc349c8a7 Include template type in bar graph label
It’s possible that users will have email and SMS templates with similar
names, and will send them depending on their users’ contact preferences.

So it’s useful to be able to compare how many emails vs SMS you’re
sending, even if the template names are similar.
2016-05-13 10:19:46 +01:00
Chris Hill-Scott
1b8236f5f8 Make template usage on dashboard easier to scan
The dashboard looked a bit table-y. This commit makes four main changes:

- show a bar chart (drawn in CSS) for template usage (only shown if
  you’ve used more than one template recently)
- only break down template usage by template name, not template type
  (because that’s happening with the big numbers)
- change the style of the ‘show more’ links under each section so that
  they are all consistent, and a little less busy (one less keyline)
- remove the ‘recent templates‘ title so that the first two sections of
  the page group under ‘in the last 7 days’
2016-05-13 09:59:41 +01:00
Chris Hill-Scott
50427ecd3f Add a page to show delivery rates week-by-week
Implements
https://github.com/alphagov/notifications-api/pull/286

Will always show weeks as Monday to Sunday.
2016-05-05 10:56:20 +01:00
Chris Hill-Scott
0080bce562 Say ‘sent’ rather than ‘processed’
Hopefully users understand that sent != delivered
2016-04-20 15:32:02 +01:00
Chris Hill-Scott
09491e880e Show template usage for all time on it’s own page
> We show the last weeks template usage on the dashboard, which is
> great, but if you're looking for longer term trends, you're out of
> luck...

> So, let's let you see more on a more detailed page (linked from the
> dashboard). Initially this should just show you all templates that you
> have used ever and the count for each. Order same as dashboard, most
> popular first.

https://www.pivotaltracker.com/story/show/117614585
2016-04-20 15:31:42 +01:00
Chris Hill-Scott
5bf0d8fe70 Show all statistics fetched on the dashboard
We want to align all our stats to be for the last 7 days.

This means summing up the stats response from the API to make the Big
Number. Previously the big number was counting sent notifications as
successful. This commit changes it to only look at delivered
notifications.

Right now, the API doesn’t have a way of filtering to only show the last
7 days. So for the moment the dashboard will show statistics for all
time.

The upshot of this is that we can link from the dashboard to the
activity page when there are failures.
2016-04-19 15:57:53 +01:00
Chris Hill-Scott
c81b8c39f6 Add view for a single template
> At the moment, we have an all email templates page, and an edit an
> individual page.
>
> This gets messy when we refer to templates like the dashboard and the
> activity views. We solve this currently by using anchor links to the
> list page, but this is clunky.
>
> So lets add it, then update the links on the dash and activity to the
> new view page.
>
> Should be a link from the view a single template page, to the template
> hub page.

https://www.pivotaltracker.com/story/show/117349227
2016-04-13 13:41:53 +01:00
Chris Hill-Scott
7e54703e2f Reword ‘recent templates’ section of dashboard 2016-04-11 10:08:03 +01:00
Adam Shimali
d7c59fa8d7 Aggregation of template stats in admin app.
Individual templates stats items fetched from admin.
2016-04-07 10:55:21 +01:00
Adam Shimali
2dbf522932 Add date field back into template stats 2016-04-06 15:06:02 +01:00
Chris Hill-Scott
39e94ac8ec Add row numbers to tables
When a table is showing the contents of a CSV file, it should look
something like a spreadsheet.

The minimally skeuomorphic way to do this is by adding row numbers.

This commit doesn’t
- make the row numbers monospace (it’s barely noticeable and doesn’t
  reflect what actual spreadsheets do)
- make the first column heading ‘Row’ (again, doesn’t reflect how actual
  spreadsheets work, and takes up more valuable space)
2016-04-06 11:31:37 +01:00
Adam Shimali
dc7964efd7 Fix service id bug in template. Use current_service instead 2016-04-05 14:12:18 +01:00
Adam Shimali
eade0ef971 Added test for template stats client.
Removed date column from recently used templates table.
2016-04-05 13:50:42 +01:00
Adam Shimali
159fe60c1a Template statistics now surfaced on dashboard.
Job list removed.

Template statistics retrieved at same time as
notification stats.
2016-04-05 11:47:24 +01:00