cms/app-client/mirage/serializers/datestat.js
author ymh <ymh.work@gmail.com>
Sun, 02 Oct 2016 16:50:11 +0200
changeset 309 6ab16926b675
parent 307 07b44a378ad8
child 319 78990a8a069b
permissions -rw-r--r--
update maps to use geonames ids

import { JSONAPISerializer } from 'ember-cli-mirage';

import _ from 'lodash/lodash';

export default JSONAPISerializer.extend({
    serialize(response) {
        return _(response.models).map((dateinfo) => { return [dateinfo.id, dateinfo.count];}).object().value();
    }
});