mirror of
https://github.com/IT4Change/gradido.git
synced 2025-12-13 07:45:54 +00:00
add missing file and email config
This commit is contained in:
parent
8911bf761c
commit
425fed9835
@ -10,6 +10,14 @@ DB_PORT=3306
|
||||
DB_USER=root
|
||||
DB_PASSWORD=
|
||||
DB_DATABASE=gradido_community
|
||||
|
||||
#EMAIL=true
|
||||
#EMAIL_USERNAME=
|
||||
#EMAIL_SENDER=
|
||||
#EMAIL_PASSWORD=
|
||||
#EMAIL_SMTP_URL=
|
||||
#EMAIL_SMTP_PORT=587
|
||||
|
||||
#KLICKTIPP_USER=
|
||||
#KLICKTIPP_PASSWORD=
|
||||
#KLICKTIPP_APIKEY_DE=
|
||||
|
||||
@ -29,6 +29,7 @@
|
||||
"jsonwebtoken": "^8.5.1",
|
||||
"libsodium-wrappers": "^0.7.9",
|
||||
"mysql2": "^2.3.0",
|
||||
"nodemailer": "^6.6.5",
|
||||
"reflect-metadata": "^0.1.13",
|
||||
"ts-jest": "^27.0.5",
|
||||
"type-graphql": "^1.1.1",
|
||||
|
||||
@ -30,9 +30,18 @@ const klicktipp = {
|
||||
KLICKTIPP_APIKEY_EN: process.env.KLICKTIPP_APIKEY_EN || 'SomeFakeKeyEN',
|
||||
}
|
||||
|
||||
const email = {
|
||||
EMAIL: process.env.EMAIL === 'true' || false,
|
||||
EMAIL_USERNAME: process.env.EMAIL_USERNAME || 'gradido_email',
|
||||
EMAIL_SENDER: process.env.EMAIL_SENDER || 'info@gradido.net',
|
||||
EMAIL_PASSWORD: process.env.EMAIL_PASSWORD || 'xxx',
|
||||
EMAIL_SMTP_URL: process.env.EMAIL_SMTP_URL || 'gmail.com',
|
||||
EMAIL_SMTP_PORT: process.env.EMAIL_SMTP_PORT || 587,
|
||||
}
|
||||
|
||||
// This is needed by graphql-directive-auth
|
||||
process.env.APP_SECRET = server.JWT_SECRET
|
||||
|
||||
const CONFIG = { ...server, ...database, ...klicktipp }
|
||||
const CONFIG = { ...server, ...database, ...klicktipp, ...email }
|
||||
|
||||
export default CONFIG
|
||||
|
||||
@ -8,30 +8,22 @@ import { LoginViaVerificationCode } from '../model/LoginViaVerificationCode'
|
||||
import { SendPasswordResetEmailResponse } from '../model/SendPasswordResetEmailResponse'
|
||||
import { UpdateUserInfosResponse } from '../model/UpdateUserInfosResponse'
|
||||
import { User } from '../model/User'
|
||||
import {
|
||||
UserSettingRepository,
|
||||
UserSettingRepository,
|
||||
UserSettingRepository,
|
||||
} from '../../typeorm/repository/UserSettingRepository'
|
||||
import { UserSettingRepository } from '../../typeorm/repository/UserSettingRepository'
|
||||
import encode from '../../jwt/encode'
|
||||
import ChangePasswordArgs from '../arg/ChangePasswordArgs'
|
||||
import { Setting } from '../../types'
|
||||
import {
|
||||
ChangePasswordArgs,
|
||||
CheckUsernameArgs,
|
||||
CreateUserArgs,
|
||||
UnsecureLoginArgs,
|
||||
UpdateUserInfosArgs,
|
||||
} from '../inputs/LoginUserInput'
|
||||
import { apiPost, apiGet } from '../../apis/HttpRequest'
|
||||
import {
|
||||
klicktippRegistrationMiddleware,
|
||||
klicktippNewsletterStateMiddleware,
|
||||
} from '../../middleware/klicktippMiddleware'
|
||||
import { CheckEmailResponse } from '../model/CheckEmailResponse'
|
||||
import { getCustomRepository, getCustomRepository, getCustomRepository } from 'typeorm'
|
||||
import { getCustomRepository } from 'typeorm'
|
||||
import { Setting } from '../enum/Setting'
|
||||
import { UserRepository } from '../../typeorm/repository/User'
|
||||
import UnsecureLoginArgs from '../arg/UnsecureLoginArgs'
|
||||
import CreateUserArgs from '../arg/CreateUserArgs'
|
||||
import ChangePasswordArgs from '../arg/ChangePasswordArgs'
|
||||
import UpdateUserInfosArgs from '../arg/UpdateUserInfosArgs'
|
||||
import CheckUsernameArgs from '../arg/CheckUsernameArgs'
|
||||
|
||||
@Resolver()
|
||||
export class UserResolver {
|
||||
|
||||
21
backend/src/typeorm/entity/TransactionSignature.ts
Normal file
21
backend/src/typeorm/entity/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
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user