mirror of
https://github.com/IT4Change/gradido.git
synced 2026-03-01 12:44:43 +00:00
Merge branch 'master' into query-transaction-link
This commit is contained in:
commit
70780878f5
@ -27,6 +27,9 @@ export class TransactionLink {
|
||||
@Field(() => Decimal)
|
||||
amount: Decimal
|
||||
|
||||
@Field(() => Decimal)
|
||||
holdAvailableAmount: Decimal
|
||||
|
||||
@Field(() => String)
|
||||
memo: string
|
||||
|
||||
@ -36,6 +39,9 @@ export class TransactionLink {
|
||||
@Field(() => Date)
|
||||
createdAt: Date
|
||||
|
||||
@Field(() => Date, { nullable: true })
|
||||
deletedAt: Date | null
|
||||
|
||||
@Field(() => Date)
|
||||
validUntil: Date
|
||||
|
||||
|
||||
@ -12,7 +12,7 @@ import CONFIG from '@/config'
|
||||
import { sendAccountActivationEmail } from '@/mailer/sendAccountActivationEmail'
|
||||
// import { klicktippSignIn } from '@/apis/KlicktippController'
|
||||
|
||||
jest.setTimeout(10000)
|
||||
jest.setTimeout(1000000)
|
||||
|
||||
jest.mock('@/mailer/sendAccountActivationEmail', () => {
|
||||
return {
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
import Decimal from 'decimal.js-light'
|
||||
import { BaseEntity, Entity, PrimaryGeneratedColumn, Column } from 'typeorm'
|
||||
import { BaseEntity, Entity, PrimaryGeneratedColumn, Column, DeleteDateColumn } from 'typeorm'
|
||||
import { DecimalTransformer } from '../../src/typeorm/DecimalTransformer'
|
||||
|
||||
@Entity('transaction_links')
|
||||
@ -19,22 +19,33 @@ export class TransactionLink extends BaseEntity {
|
||||
})
|
||||
amount: Decimal
|
||||
|
||||
@Column({
|
||||
type: 'decimal',
|
||||
name: 'hold_available_amount',
|
||||
precision: 40,
|
||||
scale: 20,
|
||||
nullable: false,
|
||||
transformer: DecimalTransformer,
|
||||
})
|
||||
holdAvailableAmount: Decimal
|
||||
|
||||
@Column({ length: 255, nullable: false, collation: 'utf8mb4_unicode_ci' })
|
||||
memo: string
|
||||
|
||||
@Column({ length: 96, nullable: false, collation: 'utf8mb4_unicode_ci' })
|
||||
@Column({ length: 24, nullable: false, collation: 'utf8mb4_unicode_ci' })
|
||||
code: string
|
||||
|
||||
@Column({
|
||||
type: 'datetime',
|
||||
default: () => 'CURRENT_TIMESTAMP',
|
||||
nullable: false,
|
||||
})
|
||||
createdAt: Date
|
||||
|
||||
@DeleteDateColumn()
|
||||
deletedAt?: Date | null
|
||||
|
||||
@Column({
|
||||
type: 'datetime',
|
||||
default: () => 'CURRENT_TIMESTAMP',
|
||||
nullable: false,
|
||||
})
|
||||
validUntil: Date
|
||||
@ -48,7 +59,6 @@ export class TransactionLink extends BaseEntity {
|
||||
|
||||
@Column({
|
||||
type: 'datetime',
|
||||
default: () => 'CURRENT_TIMESTAMP',
|
||||
nullable: true,
|
||||
})
|
||||
redeemedAt?: Date | null
|
||||
|
||||
@ -9,9 +9,11 @@ export async function upgrade(queryFn: (query: string, values?: any[]) => Promis
|
||||
\`id\` int UNSIGNED NOT NULL AUTO_INCREMENT,
|
||||
\`userId\` int UNSIGNED NOT NULL,
|
||||
\`amount\` DECIMAL(40,20) NOT NULL,
|
||||
\`hold_available_amount\` DECIMAL(40,20) NOT NULL,
|
||||
\`memo\` varchar(255) NOT NULL,
|
||||
\`code\` varchar(96) NOT NULL,
|
||||
\`code\` varchar(24) NOT NULL,
|
||||
\`createdAt\` datetime NOT NULL,
|
||||
\`deletedAt\` datetime DEFAULT NULL,
|
||||
\`validUntil\` datetime NOT NULL,
|
||||
\`showEmail\` boolean NOT NULL DEFAULT false,
|
||||
\`redeemedAt\` datetime,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user