combinedReducers.tpl 1.19 KB
Newer Older
1
2
3
4
5
6
7
8
9
10
// WARNING
// THIS FILE HAS BEEN AUTOMATICALLY GENERATED
// WITH /frontend/generate/generate_frontend_files.js
// MODIFY THE FILE ABOVE IF YOUR NOT SATISFIED 
// THIS WARNING DOESN'T APPLY TO .tpl FILES...

import { combineReducers } from 'redux';

import {
{% for obj in data %}
Florent Chehab's avatar
Florent Chehab committed
11
  {{obj.name}}Invalidated,
12
13
  {{obj.name}}HasError,
  {{obj.name}}IsLoading,
Florent Chehab's avatar
Florent Chehab committed
14
  {{obj.name}}Fetched,
Florent Chehab's avatar
Florent Chehab committed
15
16

  {{obj.name}}ElInvalidated,
Florent Chehab's avatar
Florent Chehab committed
17
18
19
20
21
  {{obj.name}}ElHasError,
  {{obj.name}}ElIsLoading,
  {{obj.name}}ElFetched,

{% if 'read_only' not in obj or not obj.read_only %}
Florent Chehab's avatar
Florent Chehab committed
22
23
  {{obj.name}}ElIsSaving,
  {{obj.name}}ElSaved,
Florent Chehab's avatar
Florent Chehab committed
24
{% endif %}
Florent Chehab's avatar
Florent Chehab committed
25

26
27
28
29
30
{% endfor %}
} from './reducers';

{% for obj in data %}
export const {{obj.name}}Reducers = combineReducers({
Florent Chehab's avatar
Florent Chehab committed
31
  invalidated: {{obj.name}}Invalidated,
32
33
  hasError: {{obj.name}}HasError,
  isLoading: {{obj.name}}IsLoading,
Florent Chehab's avatar
Florent Chehab committed
34
  fetched: {{obj.name}}Fetched,
Florent Chehab's avatar
Florent Chehab committed
35
36
37
38
39
40
41
42
43
44
45
46
47
})

export const {{obj.name}}ElReducers = combineReducers({
  invalidated: {{obj.name}}ElInvalidated,
  hasError: {{obj.name}}ElHasError,
  isLoading: {{obj.name}}ElIsLoading,
  fetched: {{obj.name}}ElFetched,

{% if 'read_only' not in obj or not obj.read_only %}
  isSaving: {{obj.name}}ElIsSaving,
  isSaved: {{obj.name}}ElSaved,
{% endif %}

Florent Chehab's avatar
Florent Chehab committed
48

49
})
Florent Chehab's avatar
Florent Chehab committed
50
51
52



53
{% endfor %}