@dgpholdings/greatoak-shared 1.0.46 → 1.0.48
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.
|
@@ -52,11 +52,3 @@ export type TApiListExercisesReq = null;
|
|
|
52
52
|
export type TApiListExercisesRes = {
|
|
53
53
|
data: TExercise[];
|
|
54
54
|
};
|
|
55
|
-
export type TApiGetOneExerciseReq = {
|
|
56
|
-
exerciseId: string;
|
|
57
|
-
};
|
|
58
|
-
export type TApiGetOneExerciseRes = TExercise & {
|
|
59
|
-
isActive: boolean;
|
|
60
|
-
records: TRecord[];
|
|
61
|
-
exerciseNote: string;
|
|
62
|
-
};
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import { TExercise } from "./TApiExercise";
|
|
2
|
+
export type TTemplate = {
|
|
3
|
+
name: string;
|
|
4
|
+
templateId: string;
|
|
5
|
+
exerciseIds?: string[];
|
|
6
|
+
lastUsed?: Date;
|
|
7
|
+
createdAt?: string;
|
|
8
|
+
};
|
|
9
|
+
export type TTemplateExercise = {
|
|
10
|
+
template: TTemplate;
|
|
11
|
+
exercise: TExercise[];
|
|
12
|
+
};
|
|
13
|
+
export type TApiTemplateCreateReq = {
|
|
14
|
+
name: string;
|
|
15
|
+
};
|
|
16
|
+
export type TApiTemplateCreateRes = {
|
|
17
|
+
status: number;
|
|
18
|
+
success?: boolean;
|
|
19
|
+
message?: string;
|
|
20
|
+
};
|
|
21
|
+
export type TApiTemplateUpdateReq = {
|
|
22
|
+
templateId: string;
|
|
23
|
+
name: string;
|
|
24
|
+
exerciseIds: string[];
|
|
25
|
+
};
|
|
26
|
+
export type TApiTemplateUpdateRes = {
|
|
27
|
+
status: number;
|
|
28
|
+
success?: boolean;
|
|
29
|
+
message?: string;
|
|
30
|
+
};
|
|
31
|
+
type TExerciseRecord = {
|
|
32
|
+
recordDate: Date;
|
|
33
|
+
exerciseNote?: string;
|
|
34
|
+
score: number;
|
|
35
|
+
records: {
|
|
36
|
+
kg?: number;
|
|
37
|
+
reps?: number;
|
|
38
|
+
durationSecs?: string;
|
|
39
|
+
goalDuration?: string;
|
|
40
|
+
}[];
|
|
41
|
+
};
|
|
42
|
+
type TTemplateData = Omit<TTemplate, "exerciseIds"> & {
|
|
43
|
+
exercises: {
|
|
44
|
+
exercise: TExercise;
|
|
45
|
+
latestRecord: TExerciseRecord;
|
|
46
|
+
}[];
|
|
47
|
+
};
|
|
48
|
+
export type TApiTemplatesRes = {
|
|
49
|
+
status: number;
|
|
50
|
+
templates: TTemplateData[];
|
|
51
|
+
msg?: string;
|
|
52
|
+
};
|
|
53
|
+
export type TApiTemplatesReq = {
|
|
54
|
+
specificTemplateIds?: string[];
|
|
55
|
+
};
|
|
56
|
+
export {};
|
package/dist/types/index.d.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
export type * from "./TApiAuth";
|
|
2
2
|
export type * from "./TApiExercise";
|
|
3
3
|
export type * from "./TApiExerciseRecord";
|
|
4
|
-
export type * from "./TApiTemplate";
|
|
5
4
|
export type * from "./adminApi/TApiAttachment";
|
|
6
|
-
export type * from "./
|
|
5
|
+
export type * from "./TApiTemplateData";
|