@open-tender/cloud 0.1.87 → 0.1.88
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -190,6 +190,7 @@ exports.submitOrderPay = (0, toolkit_1.createAsyncThunk)(CheckoutActionType.Subm
|
|
|
190
190
|
}
|
|
191
191
|
try {
|
|
192
192
|
const completedOrder = yield api.postOrder(preparedOrder, token);
|
|
193
|
+
console.log('completedOrder', completedOrder);
|
|
193
194
|
const auth = getState().customer.account.auth;
|
|
194
195
|
const { email, password } = preparedOrder.customer || {};
|
|
195
196
|
if (password && !auth) {
|
|
@@ -282,17 +283,6 @@ const checkoutSlice = (0, toolkit_1.createSlice)({
|
|
|
282
283
|
state.loading = 'idle';
|
|
283
284
|
state.submitting = false;
|
|
284
285
|
state.errors = action.payload || {};
|
|
285
|
-
})
|
|
286
|
-
.addCase(exports.submitOrderPay.fulfilled, (_, action) => {
|
|
287
|
-
return Object.assign(Object.assign({}, initialState), { completedOrder: action.payload });
|
|
288
|
-
})
|
|
289
|
-
.addCase(exports.submitOrderPay.pending, state => {
|
|
290
|
-
state.loading = 'pending';
|
|
291
|
-
})
|
|
292
|
-
.addCase(exports.submitOrderPay.rejected, (state, action) => {
|
|
293
|
-
state.loading = 'idle';
|
|
294
|
-
state.submitting = false;
|
|
295
|
-
state.errors = action.payload || {};
|
|
296
286
|
});
|
|
297
287
|
}
|
|
298
288
|
});
|
|
@@ -186,6 +186,7 @@ export const submitOrderPay = createAsyncThunk(CheckoutActionType.SubmitOrderPay
|
|
|
186
186
|
}
|
|
187
187
|
try {
|
|
188
188
|
const completedOrder = yield api.postOrder(preparedOrder, token);
|
|
189
|
+
console.log('completedOrder', completedOrder);
|
|
189
190
|
const auth = getState().customer.account.auth;
|
|
190
191
|
const { email, password } = preparedOrder.customer || {};
|
|
191
192
|
if (password && !auth) {
|
|
@@ -278,17 +279,6 @@ const checkoutSlice = createSlice({
|
|
|
278
279
|
state.loading = 'idle';
|
|
279
280
|
state.submitting = false;
|
|
280
281
|
state.errors = action.payload || {};
|
|
281
|
-
})
|
|
282
|
-
.addCase(submitOrderPay.fulfilled, (_, action) => {
|
|
283
|
-
return Object.assign(Object.assign({}, initialState), { completedOrder: action.payload });
|
|
284
|
-
})
|
|
285
|
-
.addCase(submitOrderPay.pending, state => {
|
|
286
|
-
state.loading = 'pending';
|
|
287
|
-
})
|
|
288
|
-
.addCase(submitOrderPay.rejected, (state, action) => {
|
|
289
|
-
state.loading = 'idle';
|
|
290
|
-
state.submitting = false;
|
|
291
|
-
state.errors = action.payload || {};
|
|
292
282
|
});
|
|
293
283
|
}
|
|
294
284
|
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@open-tender/cloud",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.88",
|
|
4
4
|
"description": "A library of hooks, reducers, utility functions, and types for use with Open Tender applications that utilize our cloud-based Order API.",
|
|
5
5
|
"main": "./dist/cjs/index.js",
|
|
6
6
|
"module": "./dist/esm/index.js",
|