@heliofi/common 0.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +20 -0
- package/src/__tests__/index.test.ts +5 -0
- package/src/domain/constants/index.ts +2 -0
- package/src/domain/index.ts +3 -0
- package/src/domain/model/apiKey/dtos/createApiKeyDto.ts +15 -0
- package/src/domain/model/apiKey/dtos/index.ts +2 -0
- package/src/domain/model/apiKey/dtos/updateApiKeyDto.ts +11 -0
- package/src/domain/model/apiKey/entities/ApiKey.ts +11 -0
- package/src/domain/model/apiKey/entities/index.ts +1 -0
- package/src/domain/model/apiKey/index.ts +2 -0
- package/src/domain/model/approve-transaction/dtos/approveTransactionDto.ts +62 -0
- package/src/domain/model/approve-transaction/dtos/index.ts +1 -0
- package/src/domain/model/approve-transaction/index.ts +1 -0
- package/src/domain/model/attachment/dtos/createAttachmentDto.ts +22 -0
- package/src/domain/model/attachment/dtos/index.ts +1 -0
- package/src/domain/model/attachment/entities/Attachment.ts +6 -0
- package/src/domain/model/attachment/entities/AttachmentType.enum.ts +3 -0
- package/src/domain/model/attachment/entities/BaseAttachment.ts +11 -0
- package/src/domain/model/attachment/entities/ShallowEnrichedAttachment.ts +6 -0
- package/src/domain/model/attachment/entities/index.ts +4 -0
- package/src/domain/model/attachment/index.ts +2 -0
- package/src/domain/model/auth/dtos/index.ts +1 -0
- package/src/domain/model/auth/dtos/signOnDto.ts +14 -0
- package/src/domain/model/auth/entities/AuthResponse.ts +9 -0
- package/src/domain/model/auth/entities/AuthUser.ts +13 -0
- package/src/domain/model/auth/entities/index.ts +2 -0
- package/src/domain/model/auth/index.ts +2 -0
- package/src/domain/model/blockchain/constants/Cluster.ts +5 -0
- package/src/domain/model/blockchain/constants/index.ts +1 -0
- package/src/domain/model/blockchain/dtos/blockchainDto.ts +11 -0
- package/src/domain/model/blockchain/dtos/index.ts +1 -0
- package/src/domain/model/blockchain/entities/Blockchain.ts +9 -0
- package/src/domain/model/blockchain/entities/index.ts +1 -0
- package/src/domain/model/blockchain/index.ts +3 -0
- package/src/domain/model/company/dtos/createCompanyDto.ts +29 -0
- package/src/domain/model/company/dtos/index.ts +2 -0
- package/src/domain/model/company/dtos/updateCompanyDto.ts +29 -0
- package/src/domain/model/company/entities/Company.ts +18 -0
- package/src/domain/model/company/entities/index.ts +1 -0
- package/src/domain/model/company/index.ts +2 -0
- package/src/domain/model/content/dtos/contentDto.ts +11 -0
- package/src/domain/model/content/dtos/index.ts +1 -0
- package/src/domain/model/content/entities/Content.ts +7 -0
- package/src/domain/model/content/entities/index.ts +1 -0
- package/src/domain/model/content/index.ts +2 -0
- package/src/domain/model/currency/dtos/createCurrency.ts +33 -0
- package/src/domain/model/currency/dtos/index.ts +2 -0
- package/src/domain/model/currency/dtos/updateCurrency.ts +39 -0
- package/src/domain/model/currency/entities/BaseCurrency.ts +17 -0
- package/src/domain/model/currency/entities/Currency.ts +6 -0
- package/src/domain/model/currency/entities/index.ts +2 -0
- package/src/domain/model/currency/index.ts +2 -0
- package/src/domain/model/customer-details/dtos/CustomerDetailsDto.ts +32 -0
- package/src/domain/model/customer-details/dtos/index.ts +1 -0
- package/src/domain/model/customer-details/entities/CustomerDetails.ts +17 -0
- package/src/domain/model/customer-details/entities/index.ts +1 -0
- package/src/domain/model/customer-details/index.ts +2 -0
- package/src/domain/model/discordDetails/dtos/createDiscordDetails.ts +21 -0
- package/src/domain/model/discordDetails/dtos/index.ts +2 -0
- package/src/domain/model/discordDetails/dtos/updateDiscordDetails.ts +19 -0
- package/src/domain/model/discordDetails/entities/BaseDiscordDetails.ts +11 -0
- package/src/domain/model/discordDetails/entities/DiscordDetails.ts +6 -0
- package/src/domain/model/discordDetails/entities/index.ts +2 -0
- package/src/domain/model/discordDetails/index.ts +2 -0
- package/src/domain/model/email/dtos/emailDto.ts +46 -0
- package/src/domain/model/email/dtos/index.ts +1 -0
- package/src/domain/model/email/index.ts +1 -0
- package/src/domain/model/entity/Entity.ts +15 -0
- package/src/domain/model/entity/index.ts +1 -0
- package/src/domain/model/index.ts +20 -0
- package/src/domain/model/link-features/dtos/index.ts +1 -0
- package/src/domain/model/link-features/dtos/linkFeaturesDto.ts +39 -0
- package/src/domain/model/link-features/entities/LinkFeatures.ts +7 -0
- package/src/domain/model/link-features/entities/index.ts +1 -0
- package/src/domain/model/link-features/index.ts +2 -0
- package/src/domain/model/paylink/dtos/createPaylinkDto.ts +81 -0
- package/src/domain/model/paylink/dtos/index.ts +2 -0
- package/src/domain/model/paylink/dtos/updatePaylinkDto.ts +80 -0
- package/src/domain/model/paylink/entities/BasePaylink.ts +9 -0
- package/src/domain/model/paylink/entities/OnlyContentPaylink.ts +6 -0
- package/src/domain/model/paylink/entities/Paylink.ts +9 -0
- package/src/domain/model/paylink/entities/ShallowEnrichedPaylink.ts +9 -0
- package/src/domain/model/paylink/entities/index.ts +4 -0
- package/src/domain/model/paylink/index.ts +2 -0
- package/src/domain/model/paylink-tx/dtos/createPaylinkTxDto.ts +24 -0
- package/src/domain/model/paylink-tx/dtos/index.ts +2 -0
- package/src/domain/model/paylink-tx/dtos/updatePaylinkTxDto.ts +7 -0
- package/src/domain/model/paylink-tx/entities/BasePaylinkTx.ts +7 -0
- package/src/domain/model/paylink-tx/entities/PaylinkTx.ts +9 -0
- package/src/domain/model/paylink-tx/entities/ShallowEnrichedPaylinkTx.ts +9 -0
- package/src/domain/model/paylink-tx/entities/index.ts +3 -0
- package/src/domain/model/paylink-tx/index.ts +2 -0
- package/src/domain/model/payment-request/entities/BasePaymentRequest.ts +21 -0
- package/src/domain/model/payment-request/entities/PaymentRequest.ts +15 -0
- package/src/domain/model/payment-request/entities/ShallowEnrichedPaymentRequest.ts +15 -0
- package/src/domain/model/payment-request/entities/index.ts +3 -0
- package/src/domain/model/payment-request/index.ts +1 -0
- package/src/domain/model/payment-request-features/entities/PaymentRequestFeatures.ts +17 -0
- package/src/domain/model/payment-request-features/entities/index.ts +1 -0
- package/src/domain/model/payment-request-features/index.ts +1 -0
- package/src/domain/model/role/dtos/createRoleDto.ts +20 -0
- package/src/domain/model/role/dtos/index.ts +2 -0
- package/src/domain/model/role/dtos/updateRoleDto.ts +10 -0
- package/src/domain/model/role/entities/BaseRole.ts +8 -0
- package/src/domain/model/role/entities/Role.ts +9 -0
- package/src/domain/model/role/entities/RoleType.ts +5 -0
- package/src/domain/model/role/entities/ShallowEnrichedRole.ts +9 -0
- package/src/domain/model/role/entities/index.ts +4 -0
- package/src/domain/model/role/index.ts +2 -0
- package/src/domain/model/slug/dtos/index.ts +1 -0
- package/src/domain/model/slug/dtos/slug.ts +20 -0
- package/src/domain/model/slug/entities/Slug.ts +15 -0
- package/src/domain/model/slug/entities/SlugObjectType.ts +5 -0
- package/src/domain/model/slug/entities/index.ts +2 -0
- package/src/domain/model/slug/index.ts +2 -0
- package/src/domain/model/transaction-meta/dtos/CreateTransactionMetaDto.ts +34 -0
- package/src/domain/model/transaction-meta/dtos/index.ts +1 -0
- package/src/domain/model/transaction-meta/entities/BaseTransactionMeta.ts +16 -0
- package/src/domain/model/transaction-meta/entities/ShallowEnrichedTransactionMeta.ts +6 -0
- package/src/domain/model/transaction-meta/entities/TransactionMeta.ts +6 -0
- package/src/domain/model/transaction-meta/entities/index.ts +3 -0
- package/src/domain/model/transaction-meta/index.ts +2 -0
- package/src/domain/model/user/dtos/CreateUserDto.ts +19 -0
- package/src/domain/model/user/dtos/UpdateUserDto.ts +24 -0
- package/src/domain/model/user/dtos/index.ts +2 -0
- package/src/domain/model/user/entities/BaseUser.ts +13 -0
- package/src/domain/model/user/entities/ShallowEnrichedUser.ts +9 -0
- package/src/domain/model/user/entities/User.ts +9 -0
- package/src/domain/model/user/entities/index.ts +3 -0
- package/src/domain/model/user/index.ts +2 -0
- package/src/domain/model/wallet/dtos/UpdateWalletDto.ts +8 -0
- package/src/domain/model/wallet/dtos/index.ts +1 -0
- package/src/domain/model/wallet/entities/BaseWallet.ts +7 -0
- package/src/domain/model/wallet/entities/Wallet.ts +6 -0
- package/src/domain/model/wallet/entities/index.ts +2 -0
- package/src/domain/model/wallet/index.ts +2 -0
- package/src/domain/services/EmailService.ts +6 -0
- package/src/domain/services/index.ts +1 -0
- package/src/index.ts +1 -0
- package/tsconfig.json +8 -0
package/package.json
ADDED
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@heliofi/common",
|
|
3
|
+
"private": false,
|
|
4
|
+
"version": "0.0.1",
|
|
5
|
+
"description": "Common package",
|
|
6
|
+
"main": "dist/index.js",
|
|
7
|
+
"types": "./dist/index.d.ts",
|
|
8
|
+
"scripts": {
|
|
9
|
+
"test": "echo \"todo\""
|
|
10
|
+
},
|
|
11
|
+
"license": "ISC",
|
|
12
|
+
"dependencies": {
|
|
13
|
+
"@nestjs/swagger": "^6.0.4",
|
|
14
|
+
"@solana/web3.js": "^1.44.0",
|
|
15
|
+
"class-transformer": "^0.5.1",
|
|
16
|
+
"class-validator": "^0.13.2",
|
|
17
|
+
"moment": "^2.29.4"
|
|
18
|
+
},
|
|
19
|
+
"gitHead": "eb22d4b93272a162689fb87e7b9bd7cf80aaee94"
|
|
20
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { IsString, IsNumber, IsOptional, IsNotEmpty } from 'class-validator';
|
|
2
|
+
|
|
3
|
+
export class CreateApiKeyDto {
|
|
4
|
+
@IsString()
|
|
5
|
+
@IsNotEmpty()
|
|
6
|
+
secretHash: string;
|
|
7
|
+
|
|
8
|
+
@IsNumber()
|
|
9
|
+
@IsNotEmpty()
|
|
10
|
+
expiration: number;
|
|
11
|
+
|
|
12
|
+
@IsOptional()
|
|
13
|
+
@IsString()
|
|
14
|
+
publicKey?: string;
|
|
15
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './ApiKey';
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import {
|
|
2
|
+
IsEmail,
|
|
3
|
+
IsNotEmpty,
|
|
4
|
+
IsNotEmptyObject,
|
|
5
|
+
IsNumber,
|
|
6
|
+
IsString,
|
|
7
|
+
ValidateNested,
|
|
8
|
+
} from 'class-validator';
|
|
9
|
+
import { ApiProperty } from '@nestjs/swagger';
|
|
10
|
+
import { Type } from 'class-transformer';
|
|
11
|
+
import { CustomerDetailsDto } from '../../customer-details';
|
|
12
|
+
|
|
13
|
+
export class ApproveTransactionDto {
|
|
14
|
+
@ApiProperty()
|
|
15
|
+
@IsString()
|
|
16
|
+
@IsNotEmpty()
|
|
17
|
+
transactionSignature: string;
|
|
18
|
+
|
|
19
|
+
@ApiProperty()
|
|
20
|
+
@IsString()
|
|
21
|
+
@IsNotEmpty()
|
|
22
|
+
paymentRequestId: string;
|
|
23
|
+
|
|
24
|
+
@ApiProperty()
|
|
25
|
+
@IsEmail()
|
|
26
|
+
@IsNotEmpty()
|
|
27
|
+
sender: string;
|
|
28
|
+
|
|
29
|
+
@ApiProperty()
|
|
30
|
+
@IsEmail()
|
|
31
|
+
@IsNotEmpty()
|
|
32
|
+
recipient: string;
|
|
33
|
+
|
|
34
|
+
@ApiProperty()
|
|
35
|
+
@IsNotEmpty()
|
|
36
|
+
amount: bigint;
|
|
37
|
+
|
|
38
|
+
@ApiProperty()
|
|
39
|
+
@IsNumber()
|
|
40
|
+
@IsNotEmpty()
|
|
41
|
+
quantity: number;
|
|
42
|
+
|
|
43
|
+
@ApiProperty()
|
|
44
|
+
@IsString()
|
|
45
|
+
@IsNotEmpty()
|
|
46
|
+
product: string;
|
|
47
|
+
|
|
48
|
+
@ApiProperty()
|
|
49
|
+
@IsString()
|
|
50
|
+
@IsNotEmpty()
|
|
51
|
+
currency: string;
|
|
52
|
+
|
|
53
|
+
@ApiProperty()
|
|
54
|
+
@IsString()
|
|
55
|
+
@IsNotEmpty()
|
|
56
|
+
time: string;
|
|
57
|
+
|
|
58
|
+
@IsNotEmptyObject()
|
|
59
|
+
@Type(() => CustomerDetailsDto)
|
|
60
|
+
@ValidateNested()
|
|
61
|
+
customerDetails: CustomerDetailsDto;
|
|
62
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './approveTransactionDto';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './dtos';
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { IsString, IsNotEmpty, IsOptional } from 'class-validator';
|
|
2
|
+
import { ApiProperty } from '@nestjs/swagger';
|
|
3
|
+
|
|
4
|
+
export class CreateAttachmentDto {
|
|
5
|
+
@ApiProperty()
|
|
6
|
+
@IsString()
|
|
7
|
+
@IsNotEmpty()
|
|
8
|
+
name: string;
|
|
9
|
+
|
|
10
|
+
@ApiProperty({ type: 'string', format: 'binary' })
|
|
11
|
+
file: Express.Multer.File;
|
|
12
|
+
|
|
13
|
+
@ApiProperty()
|
|
14
|
+
@IsString()
|
|
15
|
+
@IsOptional()
|
|
16
|
+
attachableType: string;
|
|
17
|
+
|
|
18
|
+
@ApiProperty()
|
|
19
|
+
@IsString()
|
|
20
|
+
@IsOptional()
|
|
21
|
+
attachableId: string;
|
|
22
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './createAttachmentDto';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './signOnDto';
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { IsNotEmpty, IsString } from 'class-validator';
|
|
2
|
+
import { ApiProperty } from '@nestjs/swagger';
|
|
3
|
+
|
|
4
|
+
export class SignOnDto {
|
|
5
|
+
@ApiProperty()
|
|
6
|
+
@IsString()
|
|
7
|
+
@IsNotEmpty()
|
|
8
|
+
publicKey: string;
|
|
9
|
+
|
|
10
|
+
@ApiProperty()
|
|
11
|
+
@IsString()
|
|
12
|
+
@IsNotEmpty()
|
|
13
|
+
signature: string;
|
|
14
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './Cluster';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './blockchainDto';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './Blockchain';
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { IsString, IsOptional, IsNotEmpty } from 'class-validator';
|
|
2
|
+
import { ApiProperty } from '@nestjs/swagger';
|
|
3
|
+
|
|
4
|
+
export class CreateCompanyDto {
|
|
5
|
+
@ApiProperty()
|
|
6
|
+
@IsString()
|
|
7
|
+
@IsNotEmpty()
|
|
8
|
+
name: string;
|
|
9
|
+
|
|
10
|
+
@ApiProperty()
|
|
11
|
+
@IsOptional()
|
|
12
|
+
@IsString()
|
|
13
|
+
logoId?: string;
|
|
14
|
+
|
|
15
|
+
@ApiProperty()
|
|
16
|
+
@IsOptional()
|
|
17
|
+
@IsString()
|
|
18
|
+
websiteUrl?: string;
|
|
19
|
+
|
|
20
|
+
@ApiProperty()
|
|
21
|
+
@IsOptional()
|
|
22
|
+
@IsString()
|
|
23
|
+
twitterUsername?: string;
|
|
24
|
+
|
|
25
|
+
@ApiProperty()
|
|
26
|
+
@IsOptional()
|
|
27
|
+
@IsString()
|
|
28
|
+
discordUsername?: string;
|
|
29
|
+
}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { IsOptional, IsString } from 'class-validator';
|
|
2
|
+
import { ApiProperty } from '@nestjs/swagger';
|
|
3
|
+
|
|
4
|
+
export class UpdateCompanyDto {
|
|
5
|
+
@ApiProperty()
|
|
6
|
+
@IsOptional()
|
|
7
|
+
@IsString()
|
|
8
|
+
name?: string;
|
|
9
|
+
|
|
10
|
+
@ApiProperty()
|
|
11
|
+
@IsOptional()
|
|
12
|
+
@IsString()
|
|
13
|
+
logoId?: string;
|
|
14
|
+
|
|
15
|
+
@ApiProperty()
|
|
16
|
+
@IsOptional()
|
|
17
|
+
@IsString()
|
|
18
|
+
websiteUrl?: string;
|
|
19
|
+
|
|
20
|
+
@ApiProperty()
|
|
21
|
+
@IsOptional()
|
|
22
|
+
@IsString()
|
|
23
|
+
twitterUsername?: string;
|
|
24
|
+
|
|
25
|
+
@ApiProperty()
|
|
26
|
+
@IsOptional()
|
|
27
|
+
@IsString()
|
|
28
|
+
discordUsername?: string;
|
|
29
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { ApiKey } from '../../apiKey';
|
|
2
|
+
import { Entity } from '../../entity';
|
|
3
|
+
|
|
4
|
+
export class Company extends Entity {
|
|
5
|
+
id: string;
|
|
6
|
+
|
|
7
|
+
name: string;
|
|
8
|
+
|
|
9
|
+
logoId?: string;
|
|
10
|
+
|
|
11
|
+
websiteUrl?: string;
|
|
12
|
+
|
|
13
|
+
twitterUsername?: string;
|
|
14
|
+
|
|
15
|
+
discordUsername?: string;
|
|
16
|
+
|
|
17
|
+
apiKeys?: ApiKey[];
|
|
18
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './Company';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './contentDto';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './Content';
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { IsOptional, IsString, IsNumber } from 'class-validator';
|
|
2
|
+
import { ApiProperty } from '@nestjs/swagger';
|
|
3
|
+
|
|
4
|
+
export class CreateCurrencyDto {
|
|
5
|
+
@ApiProperty()
|
|
6
|
+
@IsString()
|
|
7
|
+
symbol: string;
|
|
8
|
+
|
|
9
|
+
@ApiProperty()
|
|
10
|
+
@IsString()
|
|
11
|
+
name: string;
|
|
12
|
+
|
|
13
|
+
@ApiProperty()
|
|
14
|
+
@IsString()
|
|
15
|
+
mintAddress: string;
|
|
16
|
+
|
|
17
|
+
@ApiProperty()
|
|
18
|
+
@IsString()
|
|
19
|
+
blockchain: string;
|
|
20
|
+
|
|
21
|
+
@ApiProperty()
|
|
22
|
+
@IsNumber()
|
|
23
|
+
decimals: number;
|
|
24
|
+
|
|
25
|
+
@ApiProperty()
|
|
26
|
+
@IsOptional()
|
|
27
|
+
@IsString()
|
|
28
|
+
symbolPrefix?: string;
|
|
29
|
+
|
|
30
|
+
@ApiProperty()
|
|
31
|
+
@IsNumber()
|
|
32
|
+
order: number;
|
|
33
|
+
}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { IsOptional, IsString, IsNumber } from 'class-validator';
|
|
2
|
+
import { ApiProperty } from '@nestjs/swagger';
|
|
3
|
+
|
|
4
|
+
export class UpdateCurrencyDto {
|
|
5
|
+
@ApiProperty()
|
|
6
|
+
@IsOptional()
|
|
7
|
+
@IsString()
|
|
8
|
+
symbol?: string;
|
|
9
|
+
|
|
10
|
+
@ApiProperty()
|
|
11
|
+
@IsOptional()
|
|
12
|
+
@IsString()
|
|
13
|
+
name?: string;
|
|
14
|
+
|
|
15
|
+
@ApiProperty()
|
|
16
|
+
@IsOptional()
|
|
17
|
+
@IsString()
|
|
18
|
+
mintAddress?: string;
|
|
19
|
+
|
|
20
|
+
@ApiProperty()
|
|
21
|
+
@IsOptional()
|
|
22
|
+
@IsString()
|
|
23
|
+
blockchain?: string;
|
|
24
|
+
|
|
25
|
+
@ApiProperty()
|
|
26
|
+
@IsOptional()
|
|
27
|
+
@IsNumber()
|
|
28
|
+
decimals?: number;
|
|
29
|
+
|
|
30
|
+
@ApiProperty()
|
|
31
|
+
@IsOptional()
|
|
32
|
+
@IsString()
|
|
33
|
+
symbolPrefix?: string;
|
|
34
|
+
|
|
35
|
+
@ApiProperty()
|
|
36
|
+
@IsOptional()
|
|
37
|
+
@IsNumber()
|
|
38
|
+
order?: number;
|
|
39
|
+
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { IsEmail, IsOptional, IsString } from 'class-validator';
|
|
2
|
+
|
|
3
|
+
export class CustomerDetailsDto {
|
|
4
|
+
@IsString()
|
|
5
|
+
@IsOptional()
|
|
6
|
+
@IsEmail()
|
|
7
|
+
email?: string;
|
|
8
|
+
|
|
9
|
+
@IsString()
|
|
10
|
+
@IsOptional()
|
|
11
|
+
discordUsername?: string;
|
|
12
|
+
|
|
13
|
+
@IsString()
|
|
14
|
+
@IsOptional()
|
|
15
|
+
twitterUsername?: string;
|
|
16
|
+
|
|
17
|
+
@IsString()
|
|
18
|
+
@IsOptional()
|
|
19
|
+
fullName?: string;
|
|
20
|
+
|
|
21
|
+
@IsString()
|
|
22
|
+
@IsOptional()
|
|
23
|
+
country?: string;
|
|
24
|
+
|
|
25
|
+
@IsString()
|
|
26
|
+
@IsOptional()
|
|
27
|
+
deliveryAddress?: string;
|
|
28
|
+
|
|
29
|
+
@IsString()
|
|
30
|
+
@IsOptional()
|
|
31
|
+
phoneNumber?: string;
|
|
32
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './CustomerDetailsDto';
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { Entity } from '../../entity';
|
|
2
|
+
|
|
3
|
+
export class CustomerDetails extends Entity {
|
|
4
|
+
email?: string;
|
|
5
|
+
|
|
6
|
+
discordUsername?: string;
|
|
7
|
+
|
|
8
|
+
twitterUsername?: string;
|
|
9
|
+
|
|
10
|
+
fullName?: string;
|
|
11
|
+
|
|
12
|
+
country?: string;
|
|
13
|
+
|
|
14
|
+
deliveryAddress?: string;
|
|
15
|
+
|
|
16
|
+
phoneNumber?: string;
|
|
17
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './CustomerDetails';
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { IsOptional, IsString, IsBoolean } from 'class-validator';
|
|
2
|
+
import { ApiProperty } from '@nestjs/swagger';
|
|
3
|
+
|
|
4
|
+
export class CreateDiscordDetailsDto {
|
|
5
|
+
@ApiProperty()
|
|
6
|
+
@IsString()
|
|
7
|
+
serverId: string;
|
|
8
|
+
|
|
9
|
+
@ApiProperty()
|
|
10
|
+
@IsString()
|
|
11
|
+
roleId: string;
|
|
12
|
+
|
|
13
|
+
@ApiProperty()
|
|
14
|
+
@IsBoolean()
|
|
15
|
+
@IsOptional()
|
|
16
|
+
active?: boolean;
|
|
17
|
+
|
|
18
|
+
@ApiProperty()
|
|
19
|
+
@IsString()
|
|
20
|
+
company?: string;
|
|
21
|
+
}
|