1 | "use strict";
|
2 |
|
3 | Object.defineProperty(exports, "__esModule", {
|
4 | value: true
|
5 | });
|
6 | exports.clearAsyncExceptPageReduction = exports.delAsyncReductionFromAsyncKeyProp = exports.delAsyncPageReduction = exports.delAsyncReduction = exports.setAsyncCustomReductionFromProps = exports.setAsyncFailureReductionFromAsyncKeyProp = exports.setAsyncFailureReduction = exports.setAsyncSuccessReductionFromAsyncKeyProp = exports.setAsyncSuccessReduction = exports.setAsyncRequestReductionFromAsyncKeyProp = exports.setAsyncRequestReduction = exports.setAsyncTrueReductionFromAsyncKeyProp = exports.setAsyncPageTrueReduction = exports.setAsyncTrueReduction = exports.FAILURE = exports.SUCCESS = exports.REQUEST = void 0;
|
7 |
|
8 | var _asyncOperations = require("./async-operations");
|
9 |
|
10 | var REQUEST = 'REQUEST';
|
11 | exports.REQUEST = REQUEST;
|
12 | var SUCCESS = 'SUCCESS';
|
13 | exports.SUCCESS = SUCCESS;
|
14 | var FAILURE = 'FAILURE';
|
15 | exports.FAILURE = FAILURE;
|
16 |
|
17 | var setAsyncTrueReduction = function setAsyncTrueReduction(key) {
|
18 | return function (state) {
|
19 | return (0, _asyncOperations.setAsyncOperation)(state, key);
|
20 | };
|
21 | };
|
22 |
|
23 | exports.setAsyncTrueReduction = setAsyncTrueReduction;
|
24 |
|
25 | var setAsyncPageTrueReduction = function setAsyncPageTrueReduction() {
|
26 | return function (state) {
|
27 | return (0, _asyncOperations.setAsyncOperation)(state, 'page');
|
28 | };
|
29 | };
|
30 |
|
31 | exports.setAsyncPageTrueReduction = setAsyncPageTrueReduction;
|
32 |
|
33 | var setAsyncTrueReductionFromAsyncKeyProp = function setAsyncTrueReductionFromAsyncKeyProp(payload) {
|
34 | return function (state) {
|
35 | return (0, _asyncOperations.setAsyncOperation)(state, payload.asyncKey);
|
36 | };
|
37 | };
|
38 |
|
39 | exports.setAsyncTrueReductionFromAsyncKeyProp = setAsyncTrueReductionFromAsyncKeyProp;
|
40 |
|
41 | var setAsyncRequestReduction = function setAsyncRequestReduction(key) {
|
42 | return function (state) {
|
43 | return (0, _asyncOperations.setAsyncOperation)(state, key, REQUEST);
|
44 | };
|
45 | };
|
46 |
|
47 | exports.setAsyncRequestReduction = setAsyncRequestReduction;
|
48 |
|
49 | var setAsyncRequestReductionFromAsyncKeyProp = function setAsyncRequestReductionFromAsyncKeyProp(payload) {
|
50 | return function (state) {
|
51 | return (0, _asyncOperations.setAsyncOperation)(state, payload.asyncKey, REQUEST);
|
52 | };
|
53 | };
|
54 |
|
55 | exports.setAsyncRequestReductionFromAsyncKeyProp = setAsyncRequestReductionFromAsyncKeyProp;
|
56 |
|
57 | var setAsyncSuccessReduction = function setAsyncSuccessReduction(key) {
|
58 | return function (state) {
|
59 | return (0, _asyncOperations.setAsyncOperation)(state, key, SUCCESS);
|
60 | };
|
61 | };
|
62 |
|
63 | exports.setAsyncSuccessReduction = setAsyncSuccessReduction;
|
64 |
|
65 | var setAsyncSuccessReductionFromAsyncKeyProp = function setAsyncSuccessReductionFromAsyncKeyProp(payload) {
|
66 | return function (state) {
|
67 | return (0, _asyncOperations.setAsyncOperation)(state, payload.asyncKey, SUCCESS);
|
68 | };
|
69 | };
|
70 |
|
71 | exports.setAsyncSuccessReductionFromAsyncKeyProp = setAsyncSuccessReductionFromAsyncKeyProp;
|
72 |
|
73 | var setAsyncFailureReduction = function setAsyncFailureReduction(key) {
|
74 | return function (state) {
|
75 | return (0, _asyncOperations.setAsyncOperation)(state, key, FAILURE);
|
76 | };
|
77 | };
|
78 |
|
79 | exports.setAsyncFailureReduction = setAsyncFailureReduction;
|
80 |
|
81 | var setAsyncFailureReductionFromAsyncKeyProp = function setAsyncFailureReductionFromAsyncKeyProp(payload) {
|
82 | return function (state) {
|
83 | return (0, _asyncOperations.setAsyncOperation)(state, payload.asyncKey, FAILURE);
|
84 | };
|
85 | };
|
86 |
|
87 | exports.setAsyncFailureReductionFromAsyncKeyProp = setAsyncFailureReductionFromAsyncKeyProp;
|
88 |
|
89 | var setAsyncCustomReductionFromProps = function setAsyncCustomReductionFromProps(payload) {
|
90 | return function (state) {
|
91 | return (0, _asyncOperations.setAsyncOperation)(state, payload.asyncKey, payload.asyncValue);
|
92 | };
|
93 | };
|
94 |
|
95 | exports.setAsyncCustomReductionFromProps = setAsyncCustomReductionFromProps;
|
96 |
|
97 | var delAsyncReduction = function delAsyncReduction(key) {
|
98 | return function (state) {
|
99 | return (0, _asyncOperations.delAsyncOperation)(state, key);
|
100 | };
|
101 | };
|
102 |
|
103 | exports.delAsyncReduction = delAsyncReduction;
|
104 |
|
105 | var delAsyncPageReduction = function delAsyncPageReduction() {
|
106 | return function (state) {
|
107 | return (0, _asyncOperations.delAsyncOperation)(state, 'page');
|
108 | };
|
109 | };
|
110 |
|
111 | exports.delAsyncPageReduction = delAsyncPageReduction;
|
112 |
|
113 | var delAsyncReductionFromAsyncKeyProp = function delAsyncReductionFromAsyncKeyProp(payload) {
|
114 | return function (state) {
|
115 | return (0, _asyncOperations.delAsyncOperation)(state, payload.asyncKey);
|
116 | };
|
117 | };
|
118 |
|
119 | exports.delAsyncReductionFromAsyncKeyProp = delAsyncReductionFromAsyncKeyProp;
|
120 |
|
121 | var clearAsyncExceptPageReduction = function clearAsyncExceptPageReduction() {
|
122 | return function (state) {
|
123 | return (0, _asyncOperations.clearAsyncOperation)(state, 'page');
|
124 | };
|
125 | };
|
126 |
|
127 | exports.clearAsyncExceptPageReduction = clearAsyncExceptPageReduction; |
\ | No newline at end of file |