cms/app-client/mirage/serializers/dateminmax.js
author ymh <ymh.work@gmail.com>
Tue, 22 Nov 2016 18:50:50 +0100
changeset 435 c53b87b00ea3
parent 424 feb0d3e0fef9
child 532 1190ea937f2d
permissions -rw-r--r--
version 0.0.13

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

import _ from 'lodash/lodash';

export default JSONAPISerializer.extend({
    serialize(response) {
        return {'dateminmax': _(response.models).map((dateinfo) => { return parseInt(dateinfo.id);}).value()};
    }
});