parent
0c61ff457d
commit
b8fbb72fa0
|
@ -2,7 +2,7 @@ import {
|
|||
IsInt,
|
||||
IsNotEmpty
|
||||
} from "class-validator";
|
||||
import { Entity, ManyToOne, PrimaryGeneratedColumn, TableInheritance } from "typeorm";
|
||||
import { Column, Entity, ManyToOne, PrimaryGeneratedColumn, TableInheritance } from "typeorm";
|
||||
import { ResponseDonation } from '../responses/ResponseDonation';
|
||||
import { Donor } from './Donor';
|
||||
|
||||
|
@ -34,6 +34,13 @@ export abstract class Donation {
|
|||
*/
|
||||
public abstract get amount(): number;
|
||||
|
||||
/**
|
||||
* The donation's payed amount in cents (or whatever your currency's smallest unit is.).
|
||||
* Used to mark donations as payed.
|
||||
*/
|
||||
@Column({ nullable: true })
|
||||
@IsInt()
|
||||
payedAmount: number;
|
||||
|
||||
/**
|
||||
* Turns this entity into it's response class.
|
||||
|
|
Loading…
Reference in New Issue