Commit Graph

14648 Commits

Author SHA1 Message Date
Tom Byers
01b97986f6 Update diff-dom package to 3.1.0
Since it moved to ES Modules in version 2.3.1,
diff-dom stopped including the `diffDOM.js` file
in its NPM package.

We don't do any kind of bundling in our build yet,
just concatenation of our scripts and some
minification of the results so we can't take
advantage of this yet.

The `diffDOM.js` file is still available in the
Github release so this moves to referencing that
in the `package.json` instead, until we start
using a bundler.

I opened an issue to check this is what the author
intended:

https://github.com/fiduswriter/diffDOM/issues/84

The latest version also adds Rollup as a peer
dependency.
2019-04-12 15:36:57 +01:00
Tom Byers
05f3cb6797 Bump JSHint 2019-04-12 15:36:57 +01:00
Tom Byers
fed3381209 Bump Babel to 7.4.0
Requires replacing `babel-preset-es2015` for
`babel-preset-env` as Babel switched to this as of
version 6:

https://babeljs.io/docs/en/babel-preset-es2015

Note: this also moves all Babel packages to using
the scoped packages syntax, descended from the
`@babel` namespace.

https://docs.npmjs.com/about-scopes
2019-04-12 15:36:57 +01:00
Tom Byers
71463182f1 Stop using Babel to transpile gulpfile
Bumping NodeJS to 10.15.3 removes the need to
transpile `gulpfile.js` as this version includes
all the ES6 features used..

Also removes .babelrc file. This was included to
ensure the gulpfile was transpiled correctly so it
is no longer needed.
2019-04-12 15:36:57 +01:00
Tom Byers
b83053ddd1 Fix sass-lint
Sass-lint was bumped when gulp-sass-lint was
bumped. This brought in a new version which
changed the interface of `sassLint.format`.

It doesn't look like the `sassLint.format` method
ever defined any arguments or did anything with
the `arguments` variable. That being the case, our
sending it an instance of the 'stylish' ESLint
reporter did nothing in the previous version but
this wasn't obvious because sass-lint defaults to
'stylish' for its output styling.

The latest version (1.4.0) introduced an argument
of a writable stream which, if defined, will be
used to write the output to. This caused a problem
with our sending in the instance of 'stylish'.

This moves the selection of stylish into the
sass-lint config, as described in the
[sass-lint docs](https://github.com/sasstools/gulp-sass-lint/tree/master#sasslintformatwritable).
2019-04-12 15:36:57 +01:00
Tom Byers
c3a1e6ed59 Bump Gulp to 4.0.0
Brings in a new API which is a breaking change:

https://github.com/gulpjs/gulp/blob/master/CHANGELOG.md#400

Requires gulpfile.babel.js to be a CommonJS module
and for all tasks to be exported.

Replaces using ES6 modules for the CommonJS to
include other packages to match the type of module
the gulpfile now is.

Updates to 4.0.0 include `series` and `parallel`
methods which remove the need for the
`run-sequence` package.

Also bumps gulp-specific libraries.
2019-04-12 15:36:57 +01:00
Tom Byers
c7f3b688cd Bump version of NodeJS to 10.15.3
Updates the README to reference this.

If running this locally, it's recommended to use
the 'n' NPM package to manage your version of
NodeJS, as described in the README:

https://github.com/alphagov/notifications-admin#first-time-setup
2019-04-12 15:36:57 +01:00
Chris Hill-Scott
3212915a51 Simplifying code for checking email domains
Since this code isn’t trying to inherit from the code that also looked
up domain names in `domains.yml` it can go back to being a lot simpler.

This code is thoroughly tested already here:
a249382e69/tests/app/main/test_validators.py (L74-L155)
2019-04-12 15:23:08 +01:00
Chris Hill-Scott
07c7544049 Use crown not crown_status as prop name
It’s confusing having a property name which is different from the
attribute returned in the JSON from the API.
2019-04-12 15:23:08 +01:00
Chris Hill-Scott
5d091b214a Remove domains.yml file
Since we’ve now removed the code that reads this file, it can safely be
deleted.
2019-04-12 15:23:08 +01:00
Chris Hill-Scott
9d99c78c3a Remove code that reads domains.yml
Since we’ve removed calls to this code from the rest of the app, it can
safely be removed now.
2019-04-12 15:23:08 +01:00
Chris Hill-Scott
470b8a2912 Remove domains from branding forms
We’re deprecating storing the domain as text on a branding in favour of
a database relationship between branding and organisation.

We need to do this now in order to remove the validation on these fields
(which depends on the data in `domains.yml`)
2019-04-12 15:23:07 +01:00
Chris Hill-Scott
9684e962ae Refactor go live tags into service model
Since this function only takes one argument, a service, it might as well
be a method of the service.
2019-04-12 15:19:32 +01:00
Chris Hill-Scott
3565ffc33f Remove dependence on domains.yml from settings
Settings looked at `domains.yml` when users were making go live requests
or email branding requests.

This will allow us to remove the `domains.yml` file, by using
information about organisations that is now stored in the database
instead.
2019-04-12 15:19:31 +01:00
Chris Hill-Scott
b41c3779c4 Merge pull request #2906 from alphagov/auto-service-counts
Automate counting of live services and orgs
2019-04-12 14:15:41 +01:00
Chris Hill-Scott
835d11d8d6 Remove domains.yml dependence from agreement pages
This will allow us to remove the `domains.yml` file, by using
information about organisations that is now stored in the database
instead.
2019-04-12 14:12:10 +01:00
Chris Hill-Scott
98249158cb Stop trying to infer branding when adding services
The API handles this now.
2019-04-12 14:08:33 +01:00
Chris Hill-Scott
72f49a9a1e Remove dependence on domains.yml from static pages
This will allow us to remove the `domains.yml` file, by using
information about organisations that is now stored in the database
instead.
2019-04-12 14:05:00 +01:00
Chris Hill-Scott
718f440720 Get info about organisations from database table
This is the first step of replacing the `domains.yml` file.

In order to replicate the same functionality we get from the
`domains.yml` file and its associated code this commit adds a
`Organisation` model. This model copies a lot of methods from the
`AgreementInfo` class which wrapped the `domains.yml` file.

It factors out some stuff that would otherwise be duplicated between the
`Organisation` and `Service` model, in such a way that could be reused
for making other models in the future.

This commit doesn’t change other parts of the code to make use of this
new model yet – that will come in subsequent commits.
2019-04-12 14:01:14 +01:00
Chris Hill-Scott
9863aa3c48 Automate counting of live services and orgs
Returns the data calculated by the API. Stored in Redis against a
hardcoded key so that no-one hammering the home page is directly hitting
the database.
2019-04-12 13:59:33 +01:00
karlchillmaid
747b68a272 Remove reference to scheduling
Remove reference to scheduling
2019-04-12 11:48:06 +01:00
karlchillmaid
ea00f901fb Clarify scheduling information
Clarify scheduling information
2019-04-12 11:47:38 +01:00
Alexey Bezhan
df1a1b5b66 Merge pull request #2905 from alphagov/pin-gunicorn-pyup
Stop pyup from trying to upgrade gunicorn
2019-04-12 10:21:21 +01:00
karlchillmaid
d53499ed11 Correct 'message status' nav label 2019-04-11 16:32:48 +01:00
karlchillmaid
2c62409dbd Update status information 2019-04-11 16:32:02 +01:00
Chris Hill-Scott
278317b222 Merge pull request #2907 from alphagov/no-go-live-without-checklist
Block incomplete requests to go live
2019-04-11 16:23:55 +01:00
karlchillmaid
f997b446ff Update app/templates/views/service-settings/request-to-go-live.html
Co-Authored-By: quis <me@quis.cc>
2019-04-11 15:44:28 +01:00
Chris Hill-Scott
436d023722 Block incomplete requests to go live
Dealing with users who request to go live but haven’t completed all the
steps still represents a significant support overhead for our team.
We’ve made some improvements to the percentage of incomplete requests
with a better page design, but ultimately because it still shows the
button people think it’s OK to press the button while some of the items
on the page still say [Not completed].

We can do this now because organisations are in the database, which
means we can mark the agreement signed as soon as we get it back,
without having to deploy code.
2019-04-11 14:35:30 +01:00
Chris Hill-Scott
30504a8026 Fix tests 2019-04-11 12:00:37 +01:00
Chris Hill-Scott
fe204614ad Add new pages to navigation dictionaries 2019-04-11 11:47:09 +01:00
karlchillmaid
6f3af4a262 Update How to pay
Update How to pay
2019-04-11 10:31:33 +01:00
karlchillmaid
cf9001d6e8 Amends based on 2i
Amends based on 2i
2019-04-11 10:31:33 +01:00
karlchillmaid
cd1d6d7994 Amends based on 2i
Amends based on 2i
2019-04-11 10:31:32 +01:00
karlchillmaid
eb63761dda Amends based on 2i
Amends based on 2i
2019-04-11 10:31:32 +01:00
karlchillmaid
f399151a2e Amends based on 2i
Amends based on 2i
2019-04-11 10:31:32 +01:00
karlchillmaid
e95777b9e0 Remove GOV.UK 2019-04-11 10:31:32 +01:00
karlchillmaid
3dd4b5d96c Content amends
Content amends based on Roz's feedback
2019-04-11 10:31:32 +01:00
karlchillmaid
298ae25eab Update introduction and text message content
Make 'Create account' intro text dependent on sign in.

Add a line about trial mode.

Remove the 'Multiple services' section of Text messages
2019-04-11 10:31:32 +01:00
karlchillmaid
d98b676d9d Update letters list
Update letters list
2019-04-11 10:31:31 +01:00
karlchillmaid
00e2c214aa Reorder menu
Reorder menu, change 'status' to 'statuses'
2019-04-11 10:31:31 +01:00
karlchillmaid
0e315477f0 Remove status page link
Remove status page link - it makes more sense to only show this as part of the 'report a problem' flow.
2019-04-11 10:31:31 +01:00
karlchillmaid
1db4a1aa48 Update API status information
Update API status information
2019-04-11 10:31:31 +01:00
karlchillmaid
3573ea6fa3 Updated API status information
Updated API status information
2019-04-11 10:31:31 +01:00
karlchillmaid
6833a551b9 Update support information
Update support information
2019-04-11 10:31:30 +01:00
karlchillmaid
efd003e236 Reformatted tables
Reformatted tables to separate email and text message statuses
2019-04-11 10:31:30 +01:00
karlchillmaid
176ff47227 Add 'text' to message allowance
Add 'text' to message allowance
2019-04-11 10:31:30 +01:00
karlchillmaid
4b3083a715 Amend postage to post
Amend postage to post
2019-04-11 10:31:30 +01:00
karlchillmaid
0c0ffd8dee Update links
Update links
2019-04-11 10:31:30 +01:00
karlchillmaid
bb346006ee Add links to channel-specific pages
Add links to channel-specific pages
2019-04-11 10:31:30 +01:00
Chris Hill-Scott
d4dfaa1e17 Link to new pages from using Notify, specify that it shouldn’t be index by search engines any more (by setting HTTP status to 410 GONE) 2019-04-11 10:31:29 +01:00