Commit Graph

3665 Commits

Author SHA1 Message Date
Chris Hill-Scott
12cfd45f60 Merge pull request #1319 from alphagov/bump-utils
Bump utils
2017-06-15 11:27:04 +01:00
Chris Hill-Scott
bde6226bb8 Merge pull request #1317 from alphagov/ease-in-fixed
Ease fixed-position elements into place
2017-06-15 11:26:58 +01:00
Chris Hill-Scott
cbeade0380 Ease fixed-position elements into place
The transition between something being static in the page and fixed to
the top of the viewport is a bit jarring.

This commit adds a bit of animation so that, as elements become fixed,
they appear to catch up with the scrolling of the page.
2017-06-15 11:14:30 +01:00
Chris Hill-Scott
09b1e2eb6a Bump utils
Brings in:
- [ ] https://github.com/alphagov/notifications-utils/pull/168/files
2017-06-15 11:12:26 +01:00
Chris Hill-Scott
4301e1265c Merge pull request #1318 from alphagov/disable-autofill-one-off
Disable autofill on one-off messages
2017-06-15 11:07:35 +01:00
Chris Hill-Scott
afaf41f7ae Disable autofill on one-off messages
Not good to be storing people’s phone numbers in browser autocomplete.

And increases the chance of accidentally sending the wrong thing to the
wrong person.
2017-06-15 11:06:14 +01:00
Chris Hill-Scott
de4b2e6413 Merge pull request #1316 from alphagov/outbound-body
Look at `body`, not `template` in outbound texts
2017-06-15 09:52:10 +01:00
Chris Hill-Scott
7e8471f21f Look at body, not template in outbound texts
As of this PR we don’t return the template content any more:
https://github.com/alphagov/notifications-api/pull/1015
2017-06-14 17:44:50 +01:00
Chris Hill-Scott
cebfa6cff6 Merge pull request #1315 from alphagov/feature
Adding first pass of the new features page
2017-06-14 17:03:56 +01:00
Chris Hill-Scott
f6f05a384d Content fixes 2017-06-14 17:01:16 +01:00
Chris Hill-Scott
86b4a27ca3 Fix the problems 2017-06-14 16:53:16 +01:00
Chris Hill-Scott
c60917d0e4 Merge pull request #1291 from alphagov/two-way
Add page to show two-way conversation
2017-06-14 16:42:46 +01:00
Chris Hill-Scott
a2e3dbaca5 Merge pull request #1314 from alphagov/remove-phone-numbers-urls
Stop putting phone numbers and email addresses in URLs
2017-06-14 16:42:37 +01:00
Pete Herlihy
b999378251 New features page 2017-06-14 16:41:52 +01:00
Chris Hill-Scott
7411256fc2 Add hidden form to re-post AJAX requests
Serializing the search box form is bad, because the AJAX thing submit
any changes that the user makes to the contents of the box. This results
in unexpected behaviour.
2017-06-14 16:25:20 +01:00
Pete Herlihy
314e3690ca Moving roadmap next to features in the footer 2017-06-14 16:18:36 +01:00
Pete Herlihy
7c5873c5b0 Adding features to the admin template
Bumped features and pricing to the banner for non logged in users too.
2017-06-14 16:14:16 +01:00
Pete Herlihy
b466b266df Adding test for routing to features page 2017-06-14 16:07:34 +01:00
Pete Herlihy
11215a0c16 Adding route for new features page 2017-06-14 16:05:20 +01:00
Chris Hill-Scott
fd3f6f920f Refactor conversation test to not re-request page
There’s no need to request the page once for each message on it. Quicker
to load the page once and then loop through the messages.

Still need this as an integration test because it’s testing the ordering
and threading of the message.
2017-06-14 15:43:42 +01:00
Chris Hill-Scott
eabd3f551a Add tests for getting a user’s phone number
Also makes the code a bit more specific by not squashing any exception,
only `HTTPError`s.
2017-06-14 15:37:57 +01:00
Chris Hill-Scott
681cea1d34 Make AJAX requests on activity page POST not GET
See parent commit for the reason we’re doing this.

Currently our AJAX requests only work as `GET` requests. So this commit
does a bit of work to make them work as `POST` requests. This is
optional behaviour, and will only happen when the element in the page
that should be updated with AJAX has the `data-form` attribute set. It
will take the form that has the corresponding `id`, serialise it, and
use that data as the body of the post request. If not form is specified
it will not do the serialisation, and submit as a `GET` request as
before.
2017-06-13 12:15:04 +01:00
Chris Hill-Scott
e65dcbe199 Make search by recipient form POST not GET
Phone numbers and email addresses are showing up in URLs where we let
users search for sent notifications by phone number or email address.

`GET` requests put the form data as a query string in the URL. This is
problematic when people are searching by a recipient’s phone number or
email address, because the URL may show up:
- in our server logs
- in our analytics
- in the user’s browser history

This is bad because these are all places where we don’t want
people’s personal information. It’s not too bad when this is happening
a handful of times. But it would be bad if we kept aggregating this
information because it would allow us to track users across services.

So, while it’s not especially RESTful, it’s better for the search form
to submit as a `POST` request. This way the phone number or email
address goes in the body of the request and does not show up in the URL.
2017-06-13 12:15:03 +01:00
Chris Hill-Scott
b7b4d38330 Merge pull request #1313 from alphagov/split-activity-tests
Split activity page tests into their own file
2017-06-13 11:47:00 +01:00
Chris Hill-Scott
ff83c7090f Split activity page tests into their own file
It’s not intuitive for these tests to be lumped in with the tests for
the job page.
2017-06-13 10:33:56 +01:00
Leo Hemsted
eb27a44d13 Merge pull request #1312 from alphagov/csrf-err
Add better logging when CSRF handler fails
2017-06-13 09:44:29 +01:00
Leo Hemsted
61ead87fc9 Add better logging when CSRF handler fails 2017-06-12 17:32:47 +01:00
Chris Hill-Scott
cafe946871 Merge pull request #1310 from alphagov/roadmap-update
Updated roadmap for June 2017
2017-06-12 10:35:31 +01:00
Chris Hill-Scott
c38f1335d0 Merge pull request #1311 from alphagov/54-55
54-55 for National Helpline (DfE)
2017-06-12 10:35:26 +01:00
Chris Hill-Scott
036ff9228e Merge pull request #1308 from alphagov/inbound-sms-setting
Add settings page for inbound SMS
2017-06-12 10:35:19 +01:00
Chris Hill-Scott
bff9365d1b Let users send inbound emoji
Implements:
- [ ] https://github.com/alphagov/notifications-utils/pull/167

Required some refactoring to be able to defined the `is_inbound`
variable.
2017-06-10 12:03:37 +01:00
Chris Hill-Scott
085f5f9b22 Stick H1 at top of page on conversation view
You’ll quite often be landing half way down this page. So the context
afforded by being able to see the phone number gives you some
reassurance that you’ve landed in the right place.
2017-06-10 12:03:10 +01:00
Chris Hill-Scott
e7ed1c1cfe Line up linked message in viewport
We anchor link to the relevant message in a thread. Which is good, but
it leaves the messages hard against the top edge of the viewport. This
looks sloppy. So this commit:

- makes each message focusable
- shifts the focused message with CSS to sit away from the viewport
2017-06-10 12:03:10 +01:00
Chris Hill-Scott
f6d8e55579 Add two-way messaging view
> Once an inbound message has been received, there should be a way to
> see the other messages in the system from the same service to the same
> number. Both in and outbound. Nice inbox/whatsapp stylee view or some
> such. This way the context of the reply is understood.
>
> Initially will only see the outbound template, not the actual message,
> but we’re going to change this for the rest (soon), so that you can
> always see the full message for all outbound.
2017-06-10 12:03:10 +01:00
Pete Herlihy
bdca1f4395 54-55 for National Helpline (DfE) 2017-06-09 12:59:30 +01:00
Pete Herlihy
442b25143a Updated roadmap for June 2017 2017-06-08 15:25:37 +01:00
minglis
183c324f9a Merge pull request #1309 from alphagov/reinstate-new-rate-api
Reinstate new rate api
2017-06-08 14:07:33 +01:00
minglis
834c255195 Fixed typos 2017-06-08 13:55:13 +01:00
Chris Hill-Scott
d9a46a67bb Merge pull request #1306 from alphagov/roll-up-inbox
Roll up messages in inbox
2017-06-07 16:24:22 +01:00
Chris Hill-Scott
f150e2be12 Refactor on/off table fields into component
There’s a lot of repeated code in our Jinja templates for the settings
page.

We already have a `boolean_field` component, but it’s not used anywhere
(it was just lifted from Digital Marketplace).

So this commit changes the `boolean_field` component to be useful for
our on/off use case, and wires it into the settings page.
2017-06-07 15:07:20 +01:00
Chris Hill-Scott
363a3e1864 Add settings page for inbound SMS
Users might be interested in inbound SMS. And when it’s fully
available, they’ll probably be able to control whether it’s on/off for
their service.

Until they point, the only way of getting it is to ask us. So let’s make
an in-the-meantime page that directs them to ask us, from the place
where they’d be able to do it themselves.
2017-06-07 15:07:20 +01:00
Chris Hill-Scott
3a218c8c51 Fix page title on international page
It doesn’t match the `<H1>`
2017-06-07 15:06:40 +01:00
Martyn Inglis
784be721f4 Merge branch 'master' into reinstate-new-rate-api
Conflicts:
	app/main/views/dashboard.py
2017-06-07 14:44:27 +01:00
Martyn Inglis
d2ecd2121e Wired in the free limit from the API 2017-06-07 14:26:00 +01:00
Chris Hill-Scott
2b164733d8 Merge pull request #1307 from alphagov/quis-patch-1
Add handler for old feedback form
2017-06-07 12:36:03 +01:00
Chris Hill-Scott
4259fb02ba Add handler for old feedback form
Cool URIs don’t change 😎

https://www.w3.org/Provider/Style/URI

We still have links to `/feedback` in our emails. These will live in people’s inboxes forever.
2017-06-07 12:25:33 +01:00
Chris Hill-Scott
313f669690 Roll up messages in inbox
The inbox should work a bit like the one on your phone. You shouldn’t
see all the messages, but the latest one from each of your ‘contacts’
only.
2017-06-06 15:15:36 +01:00
Chris Hill-Scott
a49e1b4f75 Merge pull request #1305 from alphagov/fix-key-inbound
Fix timestamp of latest inbound text on dashboard
2017-06-06 12:47:31 +01:00
Chris Hill-Scott
67137f5570 Fix timestamp of latest inbound text on dashboard
Key was misnamed.
2017-06-06 12:44:59 +01:00
Chris Hill-Scott
9d0d74cce4 Merge pull request #1304 from alphagov/53-54
53-54
2017-06-06 12:23:58 +01:00