@projectcaluma/ember-testing 11.0.0-beta.26 → 11.0.0-beta.27
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.
|
@@ -31,16 +31,21 @@ export default class WorkItemMock extends BaseMock {
|
|
|
31
31
|
handleRedoWorkItem(_, { input }) {
|
|
32
32
|
const { id } = deserialize(input);
|
|
33
33
|
const workItem = this.collection.find(id);
|
|
34
|
+
const caseId = workItem?.childCaseId;
|
|
34
35
|
|
|
35
36
|
if (workItem.taskId === "distribution") {
|
|
36
|
-
const caseId = workItem.childCaseId;
|
|
37
|
-
|
|
38
37
|
this.collection
|
|
39
38
|
.where({ caseId, taskId: "complete-distribution" })
|
|
40
39
|
.update({ status: "READY" });
|
|
41
40
|
this.collection
|
|
42
41
|
.where({ caseId, taskId: "create-inquiry" })
|
|
43
42
|
.update({ status: "READY" });
|
|
43
|
+
} else if (workItem.taskId === "inquiry") {
|
|
44
|
+
this.server.create("work-item", {
|
|
45
|
+
caseId,
|
|
46
|
+
status: "READY",
|
|
47
|
+
taskId: "adjust-inquiry-answer",
|
|
48
|
+
});
|
|
44
49
|
}
|
|
45
50
|
|
|
46
51
|
return this.handleSavePayload.fn.call(this, _, {
|
|
@@ -81,7 +86,7 @@ export default class WorkItemMock extends BaseMock {
|
|
|
81
86
|
.update({ status: "CANCELED" });
|
|
82
87
|
this.collection
|
|
83
88
|
.findBy({ childCaseId: caseId })
|
|
84
|
-
.update({ status: "COMPLETED" });
|
|
89
|
+
.update({ status: "COMPLETED", isRedoable: true });
|
|
85
90
|
this.schema.cases.find(caseId).update({ status: "COMPLETED" });
|
|
86
91
|
} else if (taskId === "revise-inquiry-answer") {
|
|
87
92
|
this.collection
|
|
@@ -193,7 +193,7 @@ export function answerInquiry(server, { inquiry, status, reason, hint }) {
|
|
|
193
193
|
}
|
|
194
194
|
|
|
195
195
|
export function confirmInquiry({ inquiry }) {
|
|
196
|
-
inquiry.update({ status: "COMPLETED" });
|
|
196
|
+
inquiry.update({ status: "COMPLETED", isRedoable: true });
|
|
197
197
|
inquiry.childCase.update({
|
|
198
198
|
status: "COMPLETED",
|
|
199
199
|
closedAt: faker.date.recent(),
|