travis-web/app/serializers/repo.coffee
Piotr Sarnacki d9cff6e8b4 Create adapters and serializers working with v3 and v2 APIs
This commit adds adapters and serializers for v3, but also a fallback
serializer for v2, which allows to handle v2 and v3 payloads at the same
time. This is needed, because when we use v3 endpoint for one of the
models (in this case repo), we can also get embedded records of other
types (like branch or build).
2015-12-08 10:18:02 +01:00

11 lines
264 B
CoffeeScript

`import Ember from 'ember'`
`import V2FallbackSerializer from 'travis/serializers/v2_fallback'`
Serializer = V2FallbackSerializer.extend
isNewSerializerAPI: true
attrs: {
_lastBuildDuration: { key: 'last_build_duration' }
}
`export default Serializer`