1
0
Fork 0

[node] begin the great typescript rewrite

This commit is contained in:
Julien Dessaux 2024-03-21 17:08:37 +01:00
parent 3b61a9694d
commit d668eac4a6
Signed by: adyxax
GPG key ID: F92E51B86E07177E
31 changed files with 879 additions and 666 deletions

22
nodejs/model/contract.ts Normal file
View file

@ -0,0 +1,22 @@
export type Contract = {
id: string;
factionSymbol: string;
type: string;
terms: {
deadline: Date;
payment: {
onAccepted: number;
onFulfilled: number;
},
deliver: Array<{
tradeSymbol: string;
destinationSymbol: string;
unitsRequired: number;
unitsFulfilled: number;
}>;
};
accepted: boolean;
fulfilled: boolean;
expiration: Date;
deadlineToAccept: Date;
};