--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/cms/app-client/app/serializers/theme.js Mon May 30 23:58:34 2016 +0200
@@ -0,0 +1,22 @@
+import DS from 'ember-data';
+
+export default DS.JSONSerializer.extend({
+
+ normalizeResponse: function(store, primaryModelClass, payload, id, requestType) {
+ var data = [];
+ Object.keys(payload).forEach(function(key) {
+ data.push({
+ 'id': key,
+ 'type': 'theme',
+ 'attributes': {
+ 'label': payload[key].label,
+ 'count': payload[key].count
+ }
+ });
+ });
+ return {
+ 'data': data
+ };
+ }
+
+});
\ No newline at end of file