* ui: Reconciliate ember-data store when records are deleted via blocking
Currently we are barely using the ember-data store/cache, but it will
still cache records in the store even though technically we aren't using
it.
This adds a SyncTime to every record that uses blocking queries so we
can delete older records from the ember-data cache to prevent them
building up
* ui: Add basic timestamp method we can access from tests, fixup tests
Adds a timestamp method that we can access from within tests so we can
test that the SyncTime is being set.
There is probably a better way to do this, but this is also probably the
simplest approach - we are also likely to revisit this at a later date
This commit includes several pieces of functionality to enable services
to be removed and the page to present information that this has happened
but also keep the deleted information on the page. Along with the more
usual blocking query based listing.
To enable this:
1. Implements `meta` on the model (only available on collections in
ember)
2. Adds new `catchable` ComputedProperty alongside a `listen` helper for
working with specific errors that can be thrown from EventSources in an
ember-like way. Briefly, normal computed properties update when a
property changes, EventSources can additionally throw errors so we can
catch them and show different visuals based on that.
Repositories are a class of services to help with CRUD actions, most of
the functionality is reused across various Models. This creates a new
repository service that centralizes all this reused functionality.
Inheritance via ember `Service.extend` is used as opposed to
decorating via Mixins.
1. Move all repository services (and their tests) to a
services/repository folder
2. Standardize on a singular name format 'node vs nodes'
3. Create a new 'repository' service to centralize functionality. This
should be extended by 'repository' services
2018-10-26 17:36:15 +01:00
Renamed from ui-v2/tests/integration/services/services-test.js (Browse further)