mirror of
https://github.com/IT4Change/gradido.git
synced 2025-12-13 07:45:54 +00:00
entity model
This commit is contained in:
parent
5ae9d8b663
commit
c3fe8b90dd
21
database/entity/0001-init_db/TransactionSignature.ts
Normal file
21
database/entity/0001-init_db/TransactionSignature.ts
Normal file
@ -0,0 +1,21 @@
|
||||
import { BaseEntity, Entity, PrimaryGeneratedColumn, Column, ManyToOne, JoinColumn } from 'typeorm'
|
||||
import { Transaction } from './Transaction'
|
||||
|
||||
@Entity('transaction_signatures')
|
||||
export class TransactionSignature extends BaseEntity {
|
||||
@PrimaryGeneratedColumn()
|
||||
id: number
|
||||
|
||||
@Column({ name: 'transaction_id' })
|
||||
transactionId: number
|
||||
|
||||
@Column({ type: 'binary', length: 64 })
|
||||
signature: Buffer
|
||||
|
||||
@Column({ type: 'binary', length: 32 })
|
||||
pubkey: Buffer
|
||||
|
||||
@ManyToOne(() => Transaction)
|
||||
@JoinColumn({ name: 'transaction_id' })
|
||||
transaction: Transaction
|
||||
}
|
||||
1
database/entity/TransactionSignature.ts
Normal file
1
database/entity/TransactionSignature.ts
Normal file
@ -0,0 +1 @@
|
||||
export { TransactionSignature } from './0001-init_db/TransactionSignature'
|
||||
Loading…
x
Reference in New Issue
Block a user