migrate transaction edit page to composition API and typescript

This commit is contained in:
MaysWind
2025-02-05 00:02:40 +08:00
parent 3e7b3297aa
commit 833e767e6c
12 changed files with 1979 additions and 2264 deletions
+12
View File
@@ -23,6 +23,18 @@ export class TransactionTemplate extends Transaction implements TransactionTempl
this.hidden = hidden;
}
public from(other: TransactionTemplate): void {
this.templateType = other.templateType;
this.name = other.name;
if (this.templateType === TemplateType.Schedule.type) {
this.scheduledFrequencyType = other.scheduledFrequencyType;
this.scheduledFrequency = other.scheduledFrequency;
this.utcOffset = other.utcOffset;
this.timeZone = undefined;
}
}
public toTemplateCreateRequest(clientSessionId: string): TransactionTemplateCreateRequest {
return {
templateType: this.templateType,