Commit Graph

7170 Commits

Author SHA1 Message Date
Chris Hill-Scott
4c1ce7bb24 Add Islington council to domain list
Not sure why they were missing…
2018-12-12 13:38:36 +00:00
Chris Hill-Scott
9a70f6a7f4 Don’t let non-government users request to go live
Only users who work for government can accept the terms of use. This
will save us from having to email these requesters back telling them
they need to find someone else to submit the request.
2018-12-12 12:56:13 +00:00
Chris Hill-Scott
72584572e7 Mark agreement signed by Halton Borough Council 2018-12-12 12:50:55 +00:00
Pea (Malgorzata Tyczynska)
1e3be7d640 Merge pull request #2577 from alphagov/disable_ajax_if_inactive
Page stops auto-refreshing when it's not active
2018-12-12 12:32:52 +00:00
Chris Hill-Scott
126db71de6 Refactor government user check onto model 2018-12-12 12:29:08 +00:00
Chris Hill-Scott
688bdd1d7a Note existing live services in go live ticket
It’s useful for analysing our growth to know if someone who’s requesting
to go live is already a live user of Notify.
2018-12-12 12:22:38 +00:00
Pea Tyczynska
b65f5abf92 Page stops auto-refreshing when it's not active 2018-12-12 11:42:54 +00:00
Chris Hill-Scott
e23d306db5 Update services and organisation count 2018-12-12 11:11:13 +00:00
Chris Hill-Scott
37f73e48a6 Merge pull request #2573 from alphagov/fix-sticky-shim
Fix sticky shim having zero height
2018-12-12 10:44:20 +00:00
Chris Hill-Scott
3cb0b164e8 Strip commas from estimated volumes
We suggest people format their numbers with commas when telling us how
many things they’re going to send.

This causes problems when we paste these values into a spreadsheet,
because the commas get interpreted as column separators.
2018-12-11 10:47:28 +00:00
Chris Hill-Scott
ce86604a49 Only trigger clear/cancel buttons on certain keys
It’s annoying having these buttons triggered by the tab or command keys.
2018-12-10 17:32:36 +00:00
Chris Hill-Scott
0c71ca0f0e Move cancel buttons alongside submit buttons
This is better because it saves vertical space for the contents of the
pop-up menu.

This commit also adds some padding to the cancel and clear buttons, to
make them easier targets to hit.
2018-12-10 17:11:01 +00:00
Chris Hill-Scott
4b305376f7 Add counter of selected templates and folders
Being able to see how many things you have selected gives you positive
feedback that reinforces that what you’ve done has been recognised. It
helps you understand the implications of your actions (ie you see ‘3
selected’ before you press the ‘Move’ button). And it gives you an
escape hatch the get out of the state you’re in by providing the ‘Clear’
button.

We also found in prototyping that having a ‘Nothing selected’ message
helps draws people’s attention to the checkboxes when they first
encounter the folders feature.

This commit implements the counter and the cancel button. It tries to
follow the existing patterns for this module.
2018-12-10 16:53:12 +00:00
Chris Hill-Scott
cac2ce661b Fix sticky shim having zero height
We ‘shim’ the sticky element so that its space in the page is reserved
while it is sticky.

This means the shim have have the same height as the sticky element.
It’s height was not getting set because of a missing semicolon in the
shim element’s `style` attribute.
2018-12-10 16:03:37 +00:00
Pea (Malgorzata Tyczynska)
77c61238e9 Merge pull request #2565 from alphagov/update_fields_csv_report
Add sender email to downloadable csv reports for notifications
2018-12-10 14:10:59 +00:00
Chris Hill-Scott
28d60124c2 Merge pull request #2568 from alphagov/fix-typod-test-name
Fix beheaded test name
2018-12-07 13:58:58 +00:00
Chris Hill-Scott
c036a91cb1 Merge pull request #2571 from alphagov/valid-feedback-email
Use email fields for feedback form
2018-12-07 13:58:52 +00:00
Chris Hill-Scott
184a9fa605 Use email fields for feedback form
Otherwise we can end up collecting invalid email addresses…

This required some refactoring to allow our email fields to be optional
(but not by default).
2018-12-07 13:11:41 +00:00
Chris Hill-Scott
7c4b292770 Merge pull request #2570 from alphagov/fix-spacing-upload-link
Fix spacing on upload link when not inside sticky
2018-12-07 11:52:19 +00:00
Chris Hill-Scott
7fa377ab76 Fix spacing on upload link when not inside sticky
We adjust the spacing under the textbox when doing the send one off
flow. This was based on the assumption that there would always be a
sticky header in the send one off flow.

This assumption is no longer true, so this commit implements the same
spacing in an independent way.
2018-12-07 11:45:40 +00:00
Chris Hill-Scott
c9db349550 Merge pull request #2569 from alphagov/no-folder-icon-templates
Don’t put folder icon on templates ‘folder’
2018-12-07 11:28:08 +00:00
Pea Tyczynska
1858ee93fd Notifications CSV Report now also shows sender email address 2018-12-07 11:20:20 +00:00
Chris Hill-Scott
ee1c8ccf53 Don’t put folder icon on templates ‘folder’
After showing this to a few people the consensus seems to be that
‘Templates’ isn’t itself a folder. Therefore it shouldn’t have a folder
icon.

This has the advantage of disambiguating between being in a folder:
> [screenshot]

…and being in a subfolder:
> [screenshot]
2018-12-07 11:12:32 +00:00
Chris Hill-Scott
7390f49c4b Merge pull request #2567 from alphagov/dont-stick-on-sms
Remove sticky textbox for one-off text messages
2018-12-07 10:55:35 +00:00
Chris Hill-Scott
950cfe46bc Merge pull request #2566 from alphagov/ie8-folders
Add PNG versions of the folder icons for IE8 users
2018-12-07 10:55:29 +00:00
Chris Hill-Scott
b0ca82c0bd Fix beheaded test name
Tests wont run unless the function name starts with the word `test`.

Was accidentally deleted here:
de92950d8e (diff-3f993e348666469cc699ac3bf0e0cc5bR543)
2018-12-07 10:39:41 +00:00
Chris Hill-Scott
60f7aef3f7 Remove sticky textbox for one-off text messages
The idea behind the sticky textbox on this page is so you can scroll
through a long email or letter to find where in the message the
placeholder appears, while still being able to see the textbox you
should be typing in.

With text messages, they’re hardly ever long enough for anything to be
off the screen – ie no scrolling is required.

However if the user does scroll, they can end up covering the message
content with the sticky top panel. Which then looks like the message
has disappeared, so they click ‘back’ in the browser, then click into
the message again to make the page reload.

This commit removes the stickyness when sending from a text message
template.
2018-12-07 10:34:16 +00:00
Chris Hill-Scott
9a884a38d7 Add PNG versions of the folder icons for IE8 users
IE8 doesn’t support SVG images as CSS backgrounds. We still have users
on IE8, as I saw yesterday.

This commit adds fallback PNG images for these users. The images are
rendered at 1x (because no-one is using IE8 on a retina screen) and
have been run through `pngcrush -brute` for the smallest possible file
size.
2018-12-07 10:32:08 +00:00
Chris Hill-Scott
3eea729c07 Merge pull request #2463 from alphagov/pensionprotectionfund.org.uk
Add Pension Protection Fund to domains list
2018-12-07 10:12:48 +00:00
Chris Hill-Scott
a1f78abe43 Merge pull request #2564 from alphagov/style-template-management-controls
Style template management controls
2018-12-05 17:04:13 +00:00
Chris Hill-Scott
b0f89f7fe9 Style cancel link and make it keyboard navigable
So that it looks and behaves like a normal link.
2018-12-05 16:47:45 +00:00
Chris Hill-Scott
971c64a0a9 Merge pull request #2553 from alphagov/better-live-search-team
Scope live search on team page to name and email
2018-12-05 16:46:15 +00:00
Chris Hill-Scott
eb7f421716 Remove redundant list call (sorted returns a list) 2018-12-05 16:39:23 +00:00
Chris Hill-Scott
5db1de3bbb Style the manage folder link
Right-aligned so it lines up with the right edge of the page.

Moved down so its baseline aligns with the folder title.

In a narrower column so there’s more space for the folder title.
2018-12-05 16:37:48 +00:00
Chris Hill-Scott
76e8a8f4ed Space out the buttons in the sticky footer 2018-12-05 16:37:47 +00:00
Chris Hill-Scott
224630a790 Merge pull request #2561 from alphagov/always-show-checked-search
Always show checked items in live search
2018-12-05 16:36:22 +00:00
Chris Hill-Scott
d81af78977 Merge pull request #2559 from alphagov/template-js
Template folder form smart JS
2018-12-05 16:36:12 +00:00
Katie Smith
31956999e2 Merge pull request #2562 from alphagov/allow-letters-to-be-cancelled
Allow letters to be cancelled
2018-12-05 16:07:46 +00:00
Leo Hemsted
827b58e7ac remove the unknown button in js
When you hit enter while an input in a form is in focus, your browser
finds the first button in the form, and carries out that action. So,
for non-js users, we added a hidden submit button with a value of
"unknown" to reflect that we don't know the intention of the user.

However, with JS enabled, this ambiguity doesn't exist - there's only
submit button and forms to fill in at a time, and non-visible fields
aren't even submitted at all. We can remove the unknown button,
supporting enter as submit properly. If the user is on one of the grey
button states, with no submit, it'll press the first button, and go to
the new template / move to existing folder dialog. That's fine enough.
2018-12-05 13:48:07 +00:00
Leo Hemsted
f1dffd1cb8 if state is unknown on load, then work out which action buttons to show
previously, it'd always show nothing-selected-buttons - however, if
some items were checked (due to being selected previously, and loading
with a form error message), it would be showing the wrong buttons.

Now, if the state is unknown, work out which state to show by counting
checkboxes, the same as when someone presses the cancel button.
2018-12-05 12:01:02 +00:00
Chris Hill-Scott
58a25e1e9e Merge pull request #2560 from alphagov/fix-none-email-branding-preview
Fix email branding preview for no branding
2018-12-05 11:59:48 +00:00
Chris Hill-Scott
f50ddc3322 Merge pull request #2563 from alphagov/use-normal-radios-add-template
Use normal radio field for add template choices
2018-12-05 11:59:43 +00:00
Chris Hill-Scott
d4a9fb52a5 Use normal radio field for add template choices
It doesn’t have a ‘none’ option.
2018-12-05 11:31:02 +00:00
Chris Hill-Scott
c7f34cc211 Fix email branding preview for no branding
The value that means no branding (in the form) has changed from `'None'`
to `'__NONE__'`.

This commit:
- accounts for that value
- makes sure that no branding (ie plain GOV.UK) is still displayed when
  no query argument is given
2018-12-05 11:28:10 +00:00
Chris Hill-Scott
b7e9c1a3e4 Always show checked items in live search
If you’ve searched to select an item and then you want to perform an
action on it it’s confusing when it goes away if you change your search.

It should always be clear which items you’re performing an action on.
This means that checked items should always be visible, no matter what
your search term is.
2018-12-05 11:24:16 +00:00
Katie Smith
5406efa0cc Add link to cancel letters
Added a link to cancel letters from the letter notification pages if the
letter is still able to be cancelled. Clicking on this link will show a
confirmation box, and will then cancel the letter if the user confirms.
2018-12-05 11:12:05 +00:00
Katie Smith
429a23934d Display cancelled letters show as failed
In the long term, we don't want to show cancelled letters. But for now,
this changes cancelled letters to display in the same way that letters
with a status of permanent-failure, since we are currently giving
letters that we want to cancel the status of permanent failure.
2018-12-05 11:03:59 +00:00
Katie Smith
1ee972bd04 Add endpoint for cancelling letters to NotificationApiClient 2018-12-05 11:03:59 +00:00
Leo Hemsted
17cc262ea3 preserve previous state on form error
the html now contains a `data-prev-state` attribute which contains the
previous state, taken from the `operation` value in the form data (from
the submit button). This is used to seed the `currentState` of the
templateFolderForm. If not specified (or 'unknown', because the user
hit enter last time round), then set it to nothingSelectedButtons.
2018-12-04 16:41:47 +00:00
Leo Hemsted
97f663f99e change operations to kebab-case
so that they better align with the front-end, where they'll be used in
data attributes. Also, making the kebab case is nice because it doesn't
give favouritism to either JS or python naming conventions
2018-12-04 16:41:47 +00:00