added crypto history

This commit is contained in:
Kevsl
2024-06-07 15:55:20 +02:00
parent 73fd9bf8a1
commit f4abd98d8c
5 changed files with 57 additions and 2 deletions

View File

@@ -117,6 +117,12 @@ export class TradeService {
}
const newValue = crypto.value * 1.1;
await this.prisma.cryptoHistory.create({
data: {
id_crypto: crypto.id,
value: newValue,
},
});
await this.prisma.crypto.update({
where: {