@yolo-croket-dev/amqp-access 0.7.380-beta.1 → 0.7.380-beta.2
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/excel-upload-server/dto/naver-search-ad.modules/naver-search-ad-excel/command/index.d.ts +0 -1
- package/excel-upload-server/dto/naver-search-ad.modules/naver-search-ad-excel/command/index.js +0 -1
- package/excel-upload-server/dto/naver-search-ad.modules/naver-search-ad-excel/index.d.ts +0 -1
- package/excel-upload-server/dto/naver-search-ad.modules/naver-search-ad-excel/index.js +0 -1
- package/excel-upload-server/services/naver-search-ad.modules/amqp.naver-search-ad-excel.service.d.ts +1 -7
- package/excel-upload-server/services/naver-search-ad.modules/amqp.naver-search-ad-excel.service.js +0 -12
- package/order-server/amqp.order-server.module.js +3 -0
- package/order-server/dto/buyma-order/command/buyma-order.dto.d.ts +106 -0
- package/order-server/dto/buyma-order/command/buyma-order.dto.js +450 -0
- package/order-server/dto/buyma-order/index.d.ts +2 -0
- package/{excel-upload-server/dto/naver-search-ad.modules/naver-search-ad-excel/query → order-server/dto/buyma-order}/index.js +2 -2
- package/order-server/dto/buyma-order/query/buyma-order.dto.d.ts +64 -0
- package/order-server/dto/buyma-order/query/buyma-order.dto.js +115 -0
- package/order-server/dto/index.d.ts +1 -0
- package/order-server/dto/index.js +1 -0
- package/order-server/services/amqp.buyma-order.service.d.ts +17 -0
- package/order-server/services/amqp.buyma-order.service.js +60 -0
- package/order-server/services/index.d.ts +1 -0
- package/order-server/services/index.js +1 -0
- package/package.json +2 -2
- package/payment-service/dto/ad-center-settle/query/get-ad-center-settles-for-google-sheet.dto.d.ts +1 -1
- package/excel-upload-server/dto/naver-search-ad.modules/naver-search-ad-excel/command/create-naver-search-ad-excel-job.dto.d.ts +0 -14
- package/excel-upload-server/dto/naver-search-ad.modules/naver-search-ad-excel/command/create-naver-search-ad-excel-job.dto.js +0 -28
- package/excel-upload-server/dto/naver-search-ad.modules/naver-search-ad-excel/query/get-naver-search-ad-excel-external-job.dto.d.ts +0 -9
- package/excel-upload-server/dto/naver-search-ad.modules/naver-search-ad-excel/query/get-naver-search-ad-excel-external-job.dto.js +0 -29
- package/excel-upload-server/dto/naver-search-ad.modules/naver-search-ad-excel/query/get-naver-search-ad-excel-job.dto.d.ts +0 -26
- package/excel-upload-server/dto/naver-search-ad.modules/naver-search-ad-excel/query/get-naver-search-ad-excel-job.dto.js +0 -43
- package/excel-upload-server/dto/naver-search-ad.modules/naver-search-ad-excel/query/index.d.ts +0 -2
package/excel-upload-server/dto/naver-search-ad.modules/naver-search-ad-excel/command/index.d.ts
CHANGED
|
@@ -2,4 +2,3 @@ export * from './generate-naver-search-ad-excel.dto';
|
|
|
2
2
|
export * from './run-naver-search-ad-excel-full-process.dto';
|
|
3
3
|
export * from './create-naver-search-ad-power-link-bulk.dto';
|
|
4
4
|
export * from './delete-naver-search-ad-adgroup-bulk.dto';
|
|
5
|
-
export * from './create-naver-search-ad-excel-job.dto';
|
package/excel-upload-server/dto/naver-search-ad.modules/naver-search-ad-excel/command/index.js
CHANGED
|
@@ -18,4 +18,3 @@ __exportStar(require("./generate-naver-search-ad-excel.dto"), exports);
|
|
|
18
18
|
__exportStar(require("./run-naver-search-ad-excel-full-process.dto"), exports);
|
|
19
19
|
__exportStar(require("./create-naver-search-ad-power-link-bulk.dto"), exports);
|
|
20
20
|
__exportStar(require("./delete-naver-search-ad-adgroup-bulk.dto"), exports);
|
|
21
|
-
__exportStar(require("./create-naver-search-ad-excel-job.dto"), exports);
|
package/excel-upload-server/services/naver-search-ad.modules/amqp.naver-search-ad-excel.service.d.ts
CHANGED
|
@@ -1,18 +1,12 @@
|
|
|
1
1
|
import { ClientProxy } from '@nestjs/microservices';
|
|
2
2
|
import { AbstractParam } from '@yolo-croket-dev/core/interfaces';
|
|
3
3
|
import { CreateNaverSearchAdPowerLinkBulkPayload, DeleteNaverSearchAdAdgroupBulkPayload } from '@yolo-croket-dev/amqp-access/excel-upload-server/dto/naver-search-ad.modules';
|
|
4
|
-
import { GenerateNaverSearchAdExcelPayload, GenerateNaverSearchAdExcelResult, RunNaverSearchAdExcelFullProcessPayload
|
|
4
|
+
import { GenerateNaverSearchAdExcelPayload, GenerateNaverSearchAdExcelResult, RunNaverSearchAdExcelFullProcessPayload } from '../../dto/naver-search-ad.modules/naver-search-ad-excel';
|
|
5
5
|
export declare class AmqpNaverSearchAdExcelService {
|
|
6
6
|
private readonly client;
|
|
7
7
|
private readonly amqpManager;
|
|
8
8
|
constructor(client: ClientProxy);
|
|
9
9
|
generateNaverSearchAdExcel(payload: GenerateNaverSearchAdExcelPayload, param: AbstractParam): Promise<GenerateNaverSearchAdExcelResult>;
|
|
10
|
-
/** @description 리포트 큐 등록이 성공한 후 작업 ID를 반환합니다. */
|
|
11
|
-
createNaverSearchAdExcelJob(payload: CreateNaverSearchAdExcelJobPayload, param: AbstractParam): Promise<CreateNaverSearchAdExcelJobResult>;
|
|
12
|
-
/** @description 작업 상태와 완료된 다운로드 URL을 조회합니다. */
|
|
13
|
-
getNaverSearchAdExcelJob(payload: GetNaverSearchAdExcelJobPayload, param: AbstractParam): Promise<GetNaverSearchAdExcelJobResult>;
|
|
14
|
-
/** @description 구버전 서버가 권한 범위를 무시하지 않도록 자동화 조회 라우트를 분리합니다. */
|
|
15
|
-
getNaverSearchAdExcelExternalJob(payload: GetNaverSearchAdExcelExternalJobPayload, param: AbstractParam): Promise<GetNaverSearchAdExcelJobResult>;
|
|
16
10
|
/**
|
|
17
11
|
* 네이버 검색광고 엑셀 전체 프로세스 실행 요청 (fire & forget)
|
|
18
12
|
* excel-upload-server가 order-server를 직접 호출하여 처리
|
package/excel-upload-server/services/naver-search-ad.modules/amqp.naver-search-ad-excel.service.js
CHANGED
|
@@ -24,18 +24,6 @@ let AmqpNaverSearchAdExcelService = class AmqpNaverSearchAdExcelService {
|
|
|
24
24
|
async generateNaverSearchAdExcel(payload, param) {
|
|
25
25
|
return this.amqpManager.call('네이버 검색 광고 엑셀 생성', 'naver-search-ad-excel.generate.excel', payload, param, { isErrorThrowing: true });
|
|
26
26
|
}
|
|
27
|
-
/** @description 리포트 큐 등록이 성공한 후 작업 ID를 반환합니다. */
|
|
28
|
-
async createNaverSearchAdExcelJob(payload, param) {
|
|
29
|
-
return this.amqpManager.call('네이버 SA 리포트 작업 등록', 'naver-search-ad-excel.create.job', payload, param, { isErrorThrowing: true });
|
|
30
|
-
}
|
|
31
|
-
/** @description 작업 상태와 완료된 다운로드 URL을 조회합니다. */
|
|
32
|
-
async getNaverSearchAdExcelJob(payload, param) {
|
|
33
|
-
return this.amqpManager.call('네이버 SA 리포트 작업 조회', 'naver-search-ad-excel.get.job', payload, param, { isErrorThrowing: true });
|
|
34
|
-
}
|
|
35
|
-
/** @description 구버전 서버가 권한 범위를 무시하지 않도록 자동화 조회 라우트를 분리합니다. */
|
|
36
|
-
async getNaverSearchAdExcelExternalJob(payload, param) {
|
|
37
|
-
return this.amqpManager.call('네이버 SA 자동화 리포트 작업 조회', 'naver-search-ad-excel.get.external-job', payload, param, { isErrorThrowing: true });
|
|
38
|
-
}
|
|
39
27
|
/**
|
|
40
28
|
* 네이버 검색광고 엑셀 전체 프로세스 실행 요청 (fire & forget)
|
|
41
29
|
* excel-upload-server가 order-server를 직접 호출하여 처리
|
|
@@ -8,6 +8,7 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
8
8
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
9
|
exports.AmqpOrderServerModule = void 0;
|
|
10
10
|
const common_1 = require("@nestjs/common");
|
|
11
|
+
const amqp_buyma_order_service_1 = require("./services/amqp.buyma-order.service");
|
|
11
12
|
const amqp_admin_settlement_limit_service_1 = require("./services/amqp.admin-settlement-limit.service");
|
|
12
13
|
const amqp_order_server_provider_1 = require("./amqp.order-server.provider");
|
|
13
14
|
const amqp_order_server_service_1 = require("./amqp.order-server.service");
|
|
@@ -18,6 +19,7 @@ exports.AmqpOrderServerModule = AmqpOrderServerModule;
|
|
|
18
19
|
exports.AmqpOrderServerModule = AmqpOrderServerModule = __decorate([
|
|
19
20
|
(0, common_1.Module)({
|
|
20
21
|
providers: [
|
|
22
|
+
amqp_buyma_order_service_1.AmqpBuymaOrderService,
|
|
21
23
|
amqp_admin_settlement_limit_service_1.AmqpAdminSettlementLimitService,
|
|
22
24
|
amqp_order_server_provider_1.OrderServerProvider,
|
|
23
25
|
amqp_order_server_service_1.AmqpOrderServer,
|
|
@@ -48,6 +50,7 @@ exports.AmqpOrderServerModule = AmqpOrderServerModule = __decorate([
|
|
|
48
50
|
services_1.AmqpCustomsService,
|
|
49
51
|
],
|
|
50
52
|
exports: [
|
|
53
|
+
amqp_buyma_order_service_1.AmqpBuymaOrderService,
|
|
51
54
|
amqp_admin_settlement_limit_service_1.AmqpAdminSettlementLimitService,
|
|
52
55
|
amqp_order_server_provider_1.OrderServerProvider,
|
|
53
56
|
amqp_order_server_service_1.AmqpOrderServer,
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
import { BuymaOrderEntity, BuymaOrderStatus, BuymaProcurementWorkStatus } from '@yolo-croket-dev/entity-v2';
|
|
2
|
+
export declare class BuymaMoneyPayload {
|
|
3
|
+
amount: number;
|
|
4
|
+
currency: string;
|
|
5
|
+
}
|
|
6
|
+
export declare class BuymaRecipientPayload {
|
|
7
|
+
name?: string | null;
|
|
8
|
+
phone?: string | null;
|
|
9
|
+
countryCode?: string | null;
|
|
10
|
+
postalCode?: string | null;
|
|
11
|
+
address1?: string | null;
|
|
12
|
+
address2?: string | null;
|
|
13
|
+
address3?: string | null;
|
|
14
|
+
address4?: string | null;
|
|
15
|
+
}
|
|
16
|
+
export declare class BuymaProductMetadataPayload {
|
|
17
|
+
storeName?: string | null;
|
|
18
|
+
sourceCountry?: string | null;
|
|
19
|
+
croketName?: string | null;
|
|
20
|
+
buymaName?: string | null;
|
|
21
|
+
brandName?: string | null;
|
|
22
|
+
optionName?: string | null;
|
|
23
|
+
weightGrams?: number | null;
|
|
24
|
+
croketItemUrl?: string | null;
|
|
25
|
+
buymaItemUrl?: string | null;
|
|
26
|
+
}
|
|
27
|
+
export declare class BuymaLocalShipmentPayload {
|
|
28
|
+
invoiceRegisteredAt?: string | null;
|
|
29
|
+
carrierName?: string | null;
|
|
30
|
+
trackingNumber?: string | null;
|
|
31
|
+
}
|
|
32
|
+
export declare class BuymaProcurementDetailsPayload {
|
|
33
|
+
croketProductPrice?: BuymaMoneyPayload | null;
|
|
34
|
+
croketShippingCost?: BuymaMoneyPayload | null;
|
|
35
|
+
purchaseCost?: BuymaMoneyPayload | null;
|
|
36
|
+
sellerSettlementCost?: BuymaMoneyPayload | null;
|
|
37
|
+
sourceStatus?: string | null;
|
|
38
|
+
localShipment?: BuymaLocalShipmentPayload | null;
|
|
39
|
+
}
|
|
40
|
+
export declare class BuymaInternationalShipmentPayload {
|
|
41
|
+
carrierName: string;
|
|
42
|
+
trackingNumber: string;
|
|
43
|
+
trackingUrl?: string | null;
|
|
44
|
+
shippingCost?: BuymaMoneyPayload | null;
|
|
45
|
+
}
|
|
46
|
+
export declare class BuymaManualFieldsPayload {
|
|
47
|
+
buyerName?: string | null;
|
|
48
|
+
recipient?: BuymaRecipientPayload;
|
|
49
|
+
productMetadata?: BuymaProductMetadataPayload;
|
|
50
|
+
productRevenue?: BuymaMoneyPayload | null;
|
|
51
|
+
shippingRevenue?: BuymaMoneyPayload | null;
|
|
52
|
+
reportedTotalRevenue?: BuymaMoneyPayload | null;
|
|
53
|
+
procurementWorkStatus?: BuymaProcurementWorkStatus;
|
|
54
|
+
procurementDetails?: BuymaProcurementDetailsPayload;
|
|
55
|
+
internationalShipment?: BuymaInternationalShipmentPayload | null;
|
|
56
|
+
stockSecuredNotified?: boolean | null;
|
|
57
|
+
forwarderDispatchNotified?: boolean | null;
|
|
58
|
+
holdReason?: string | null;
|
|
59
|
+
memo?: string | null;
|
|
60
|
+
slackThreadUrls?: string[];
|
|
61
|
+
}
|
|
62
|
+
export declare class BuymaOrderCommandPayload {
|
|
63
|
+
orderId: string;
|
|
64
|
+
expectedRevision: number;
|
|
65
|
+
/** Gateway가 인증된 관리자에서 채운다. HTTP body의 값은 사용하지 않는다. */
|
|
66
|
+
actorId: string;
|
|
67
|
+
reason: string;
|
|
68
|
+
}
|
|
69
|
+
export declare class UpdateBuymaOrderPayload extends BuymaOrderCommandPayload {
|
|
70
|
+
fields: BuymaManualFieldsPayload;
|
|
71
|
+
}
|
|
72
|
+
export declare class ConfirmBuymaPaymentPayload extends BuymaOrderCommandPayload {
|
|
73
|
+
paidAt?: string | null;
|
|
74
|
+
}
|
|
75
|
+
export declare class ConnectBuymaProcurementPayload extends BuymaOrderCommandPayload {
|
|
76
|
+
source: 'CROKET' | 'MANUAL';
|
|
77
|
+
orderUrl: string;
|
|
78
|
+
purchasedInfoId?: string;
|
|
79
|
+
alternative?: boolean;
|
|
80
|
+
productAndOptionConfirmed: boolean;
|
|
81
|
+
purchaseCost?: BuymaMoneyPayload | null;
|
|
82
|
+
}
|
|
83
|
+
export declare class ChangeBuymaOrderStatusPayload extends BuymaOrderCommandPayload {
|
|
84
|
+
orderStatus: Exclude<BuymaOrderStatus, 'REFUNDED'>;
|
|
85
|
+
fullQuantityDelivered?: boolean;
|
|
86
|
+
deliveredAt?: string | null;
|
|
87
|
+
}
|
|
88
|
+
export declare class RecordBuymaRefundPayload extends BuymaOrderCommandPayload {
|
|
89
|
+
amount: BuymaMoneyPayload;
|
|
90
|
+
refundedAt: string;
|
|
91
|
+
fullRefundConfirmed: boolean;
|
|
92
|
+
}
|
|
93
|
+
export declare class ReceiveBuymaWebhookPayload {
|
|
94
|
+
buymaAccountId: string;
|
|
95
|
+
eventType: 'order/create' | 'order/update';
|
|
96
|
+
rawJson: string;
|
|
97
|
+
rawSha256: string;
|
|
98
|
+
}
|
|
99
|
+
export interface UpdateBuymaOrderResult {
|
|
100
|
+
item: BuymaOrderEntity;
|
|
101
|
+
}
|
|
102
|
+
export interface ReceiveBuymaWebhookResult {
|
|
103
|
+
orderId: string;
|
|
104
|
+
duplicate: boolean;
|
|
105
|
+
result: 'APPLIED' | 'EXCLUDED';
|
|
106
|
+
}
|
|
@@ -0,0 +1,450 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.ReceiveBuymaWebhookPayload = exports.RecordBuymaRefundPayload = exports.ChangeBuymaOrderStatusPayload = exports.ConnectBuymaProcurementPayload = exports.ConfirmBuymaPaymentPayload = exports.UpdateBuymaOrderPayload = exports.BuymaOrderCommandPayload = exports.BuymaManualFieldsPayload = exports.BuymaInternationalShipmentPayload = exports.BuymaProcurementDetailsPayload = exports.BuymaLocalShipmentPayload = exports.BuymaProductMetadataPayload = exports.BuymaRecipientPayload = exports.BuymaMoneyPayload = void 0;
|
|
13
|
+
/** @author jun @description Buyma 변경 계약. @process 허용 필드·수정 버전·담당자·근거를 명시한다. */
|
|
14
|
+
const class_transformer_1 = require("class-transformer");
|
|
15
|
+
const class_validator_1 = require("class-validator");
|
|
16
|
+
const entity_v2_1 = require("@yolo-croket-dev/entity-v2");
|
|
17
|
+
class BuymaMoneyPayload {
|
|
18
|
+
}
|
|
19
|
+
exports.BuymaMoneyPayload = BuymaMoneyPayload;
|
|
20
|
+
__decorate([
|
|
21
|
+
(0, class_validator_1.IsNumber)({
|
|
22
|
+
allowNaN: false,
|
|
23
|
+
allowInfinity: false,
|
|
24
|
+
}),
|
|
25
|
+
(0, class_validator_1.Min)(0),
|
|
26
|
+
(0, class_validator_1.Max)(Number.MAX_SAFE_INTEGER),
|
|
27
|
+
__metadata("design:type", Number)
|
|
28
|
+
], BuymaMoneyPayload.prototype, "amount", void 0);
|
|
29
|
+
__decorate([
|
|
30
|
+
(0, class_validator_1.IsString)(),
|
|
31
|
+
(0, class_validator_1.Matches)(/^[A-Z]{3}$/),
|
|
32
|
+
__metadata("design:type", String)
|
|
33
|
+
], BuymaMoneyPayload.prototype, "currency", void 0);
|
|
34
|
+
class BuymaRecipientPayload {
|
|
35
|
+
}
|
|
36
|
+
exports.BuymaRecipientPayload = BuymaRecipientPayload;
|
|
37
|
+
__decorate([
|
|
38
|
+
(0, class_validator_1.IsOptional)(),
|
|
39
|
+
(0, class_validator_1.IsString)(),
|
|
40
|
+
(0, class_validator_1.MaxLength)(200),
|
|
41
|
+
__metadata("design:type", Object)
|
|
42
|
+
], BuymaRecipientPayload.prototype, "name", void 0);
|
|
43
|
+
__decorate([
|
|
44
|
+
(0, class_validator_1.IsOptional)(),
|
|
45
|
+
(0, class_validator_1.IsString)(),
|
|
46
|
+
(0, class_validator_1.MaxLength)(100),
|
|
47
|
+
__metadata("design:type", Object)
|
|
48
|
+
], BuymaRecipientPayload.prototype, "phone", void 0);
|
|
49
|
+
__decorate([
|
|
50
|
+
(0, class_validator_1.IsOptional)(),
|
|
51
|
+
(0, class_validator_1.IsString)(),
|
|
52
|
+
(0, class_validator_1.MaxLength)(30),
|
|
53
|
+
__metadata("design:type", Object)
|
|
54
|
+
], BuymaRecipientPayload.prototype, "countryCode", void 0);
|
|
55
|
+
__decorate([
|
|
56
|
+
(0, class_validator_1.IsOptional)(),
|
|
57
|
+
(0, class_validator_1.IsString)(),
|
|
58
|
+
(0, class_validator_1.MaxLength)(50),
|
|
59
|
+
__metadata("design:type", Object)
|
|
60
|
+
], BuymaRecipientPayload.prototype, "postalCode", void 0);
|
|
61
|
+
__decorate([
|
|
62
|
+
(0, class_validator_1.IsOptional)(),
|
|
63
|
+
(0, class_validator_1.IsString)(),
|
|
64
|
+
(0, class_validator_1.MaxLength)(500),
|
|
65
|
+
__metadata("design:type", Object)
|
|
66
|
+
], BuymaRecipientPayload.prototype, "address1", void 0);
|
|
67
|
+
__decorate([
|
|
68
|
+
(0, class_validator_1.IsOptional)(),
|
|
69
|
+
(0, class_validator_1.IsString)(),
|
|
70
|
+
(0, class_validator_1.MaxLength)(500),
|
|
71
|
+
__metadata("design:type", Object)
|
|
72
|
+
], BuymaRecipientPayload.prototype, "address2", void 0);
|
|
73
|
+
__decorate([
|
|
74
|
+
(0, class_validator_1.IsOptional)(),
|
|
75
|
+
(0, class_validator_1.IsString)(),
|
|
76
|
+
(0, class_validator_1.MaxLength)(500),
|
|
77
|
+
__metadata("design:type", Object)
|
|
78
|
+
], BuymaRecipientPayload.prototype, "address3", void 0);
|
|
79
|
+
__decorate([
|
|
80
|
+
(0, class_validator_1.IsOptional)(),
|
|
81
|
+
(0, class_validator_1.IsString)(),
|
|
82
|
+
(0, class_validator_1.MaxLength)(500),
|
|
83
|
+
__metadata("design:type", Object)
|
|
84
|
+
], BuymaRecipientPayload.prototype, "address4", void 0);
|
|
85
|
+
class BuymaProductMetadataPayload {
|
|
86
|
+
}
|
|
87
|
+
exports.BuymaProductMetadataPayload = BuymaProductMetadataPayload;
|
|
88
|
+
__decorate([
|
|
89
|
+
(0, class_validator_1.IsOptional)(),
|
|
90
|
+
(0, class_validator_1.IsString)(),
|
|
91
|
+
(0, class_validator_1.MaxLength)(200),
|
|
92
|
+
__metadata("design:type", Object)
|
|
93
|
+
], BuymaProductMetadataPayload.prototype, "storeName", void 0);
|
|
94
|
+
__decorate([
|
|
95
|
+
(0, class_validator_1.IsOptional)(),
|
|
96
|
+
(0, class_validator_1.IsString)(),
|
|
97
|
+
(0, class_validator_1.MaxLength)(100),
|
|
98
|
+
__metadata("design:type", Object)
|
|
99
|
+
], BuymaProductMetadataPayload.prototype, "sourceCountry", void 0);
|
|
100
|
+
__decorate([
|
|
101
|
+
(0, class_validator_1.IsOptional)(),
|
|
102
|
+
(0, class_validator_1.IsString)(),
|
|
103
|
+
(0, class_validator_1.MaxLength)(1000),
|
|
104
|
+
__metadata("design:type", Object)
|
|
105
|
+
], BuymaProductMetadataPayload.prototype, "croketName", void 0);
|
|
106
|
+
__decorate([
|
|
107
|
+
(0, class_validator_1.IsOptional)(),
|
|
108
|
+
(0, class_validator_1.IsString)(),
|
|
109
|
+
(0, class_validator_1.MaxLength)(1000),
|
|
110
|
+
__metadata("design:type", Object)
|
|
111
|
+
], BuymaProductMetadataPayload.prototype, "buymaName", void 0);
|
|
112
|
+
__decorate([
|
|
113
|
+
(0, class_validator_1.IsOptional)(),
|
|
114
|
+
(0, class_validator_1.IsString)(),
|
|
115
|
+
(0, class_validator_1.MaxLength)(200),
|
|
116
|
+
__metadata("design:type", Object)
|
|
117
|
+
], BuymaProductMetadataPayload.prototype, "brandName", void 0);
|
|
118
|
+
__decorate([
|
|
119
|
+
(0, class_validator_1.IsOptional)(),
|
|
120
|
+
(0, class_validator_1.IsString)(),
|
|
121
|
+
(0, class_validator_1.MaxLength)(500),
|
|
122
|
+
__metadata("design:type", Object)
|
|
123
|
+
], BuymaProductMetadataPayload.prototype, "optionName", void 0);
|
|
124
|
+
__decorate([
|
|
125
|
+
(0, class_validator_1.IsOptional)(),
|
|
126
|
+
(0, class_validator_1.IsNumber)(),
|
|
127
|
+
(0, class_validator_1.Min)(0),
|
|
128
|
+
(0, class_validator_1.Max)(1000000),
|
|
129
|
+
__metadata("design:type", Object)
|
|
130
|
+
], BuymaProductMetadataPayload.prototype, "weightGrams", void 0);
|
|
131
|
+
__decorate([
|
|
132
|
+
(0, class_validator_1.IsOptional)(),
|
|
133
|
+
(0, class_validator_1.IsString)(),
|
|
134
|
+
(0, class_validator_1.MaxLength)(1000),
|
|
135
|
+
__metadata("design:type", Object)
|
|
136
|
+
], BuymaProductMetadataPayload.prototype, "croketItemUrl", void 0);
|
|
137
|
+
__decorate([
|
|
138
|
+
(0, class_validator_1.IsOptional)(),
|
|
139
|
+
(0, class_validator_1.IsString)(),
|
|
140
|
+
(0, class_validator_1.MaxLength)(1000),
|
|
141
|
+
__metadata("design:type", Object)
|
|
142
|
+
], BuymaProductMetadataPayload.prototype, "buymaItemUrl", void 0);
|
|
143
|
+
class BuymaLocalShipmentPayload {
|
|
144
|
+
}
|
|
145
|
+
exports.BuymaLocalShipmentPayload = BuymaLocalShipmentPayload;
|
|
146
|
+
__decorate([
|
|
147
|
+
(0, class_validator_1.IsOptional)(),
|
|
148
|
+
(0, class_validator_1.IsString)(),
|
|
149
|
+
(0, class_validator_1.MaxLength)(40),
|
|
150
|
+
__metadata("design:type", Object)
|
|
151
|
+
], BuymaLocalShipmentPayload.prototype, "invoiceRegisteredAt", void 0);
|
|
152
|
+
__decorate([
|
|
153
|
+
(0, class_validator_1.IsOptional)(),
|
|
154
|
+
(0, class_validator_1.IsString)(),
|
|
155
|
+
(0, class_validator_1.MaxLength)(100),
|
|
156
|
+
__metadata("design:type", Object)
|
|
157
|
+
], BuymaLocalShipmentPayload.prototype, "carrierName", void 0);
|
|
158
|
+
__decorate([
|
|
159
|
+
(0, class_validator_1.IsOptional)(),
|
|
160
|
+
(0, class_validator_1.IsString)(),
|
|
161
|
+
(0, class_validator_1.MaxLength)(200),
|
|
162
|
+
__metadata("design:type", Object)
|
|
163
|
+
], BuymaLocalShipmentPayload.prototype, "trackingNumber", void 0);
|
|
164
|
+
class BuymaProcurementDetailsPayload {
|
|
165
|
+
}
|
|
166
|
+
exports.BuymaProcurementDetailsPayload = BuymaProcurementDetailsPayload;
|
|
167
|
+
__decorate([
|
|
168
|
+
(0, class_validator_1.IsOptional)(),
|
|
169
|
+
(0, class_validator_1.ValidateNested)(),
|
|
170
|
+
(0, class_transformer_1.Type)(() => BuymaMoneyPayload),
|
|
171
|
+
__metadata("design:type", Object)
|
|
172
|
+
], BuymaProcurementDetailsPayload.prototype, "croketProductPrice", void 0);
|
|
173
|
+
__decorate([
|
|
174
|
+
(0, class_validator_1.IsOptional)(),
|
|
175
|
+
(0, class_validator_1.ValidateNested)(),
|
|
176
|
+
(0, class_transformer_1.Type)(() => BuymaMoneyPayload),
|
|
177
|
+
__metadata("design:type", Object)
|
|
178
|
+
], BuymaProcurementDetailsPayload.prototype, "croketShippingCost", void 0);
|
|
179
|
+
__decorate([
|
|
180
|
+
(0, class_validator_1.IsOptional)(),
|
|
181
|
+
(0, class_validator_1.ValidateNested)(),
|
|
182
|
+
(0, class_transformer_1.Type)(() => BuymaMoneyPayload),
|
|
183
|
+
__metadata("design:type", Object)
|
|
184
|
+
], BuymaProcurementDetailsPayload.prototype, "purchaseCost", void 0);
|
|
185
|
+
__decorate([
|
|
186
|
+
(0, class_validator_1.IsOptional)(),
|
|
187
|
+
(0, class_validator_1.ValidateNested)(),
|
|
188
|
+
(0, class_transformer_1.Type)(() => BuymaMoneyPayload),
|
|
189
|
+
__metadata("design:type", Object)
|
|
190
|
+
], BuymaProcurementDetailsPayload.prototype, "sellerSettlementCost", void 0);
|
|
191
|
+
__decorate([
|
|
192
|
+
(0, class_validator_1.IsOptional)(),
|
|
193
|
+
(0, class_validator_1.IsString)(),
|
|
194
|
+
(0, class_validator_1.MaxLength)(100),
|
|
195
|
+
__metadata("design:type", Object)
|
|
196
|
+
], BuymaProcurementDetailsPayload.prototype, "sourceStatus", void 0);
|
|
197
|
+
__decorate([
|
|
198
|
+
(0, class_validator_1.IsOptional)(),
|
|
199
|
+
(0, class_validator_1.ValidateNested)(),
|
|
200
|
+
(0, class_transformer_1.Type)(() => BuymaLocalShipmentPayload),
|
|
201
|
+
__metadata("design:type", Object)
|
|
202
|
+
], BuymaProcurementDetailsPayload.prototype, "localShipment", void 0);
|
|
203
|
+
class BuymaInternationalShipmentPayload {
|
|
204
|
+
}
|
|
205
|
+
exports.BuymaInternationalShipmentPayload = BuymaInternationalShipmentPayload;
|
|
206
|
+
__decorate([
|
|
207
|
+
(0, class_validator_1.IsString)(),
|
|
208
|
+
(0, class_validator_1.MaxLength)(100),
|
|
209
|
+
__metadata("design:type", String)
|
|
210
|
+
], BuymaInternationalShipmentPayload.prototype, "carrierName", void 0);
|
|
211
|
+
__decorate([
|
|
212
|
+
(0, class_validator_1.IsString)(),
|
|
213
|
+
(0, class_validator_1.MaxLength)(200),
|
|
214
|
+
__metadata("design:type", String)
|
|
215
|
+
], BuymaInternationalShipmentPayload.prototype, "trackingNumber", void 0);
|
|
216
|
+
__decorate([
|
|
217
|
+
(0, class_validator_1.IsOptional)(),
|
|
218
|
+
(0, class_validator_1.IsString)(),
|
|
219
|
+
(0, class_validator_1.MaxLength)(1000),
|
|
220
|
+
__metadata("design:type", Object)
|
|
221
|
+
], BuymaInternationalShipmentPayload.prototype, "trackingUrl", void 0);
|
|
222
|
+
__decorate([
|
|
223
|
+
(0, class_validator_1.IsOptional)(),
|
|
224
|
+
(0, class_validator_1.ValidateNested)(),
|
|
225
|
+
(0, class_transformer_1.Type)(() => BuymaMoneyPayload),
|
|
226
|
+
__metadata("design:type", Object)
|
|
227
|
+
], BuymaInternationalShipmentPayload.prototype, "shippingCost", void 0);
|
|
228
|
+
class BuymaManualFieldsPayload {
|
|
229
|
+
}
|
|
230
|
+
exports.BuymaManualFieldsPayload = BuymaManualFieldsPayload;
|
|
231
|
+
__decorate([
|
|
232
|
+
(0, class_validator_1.IsOptional)(),
|
|
233
|
+
(0, class_validator_1.IsString)(),
|
|
234
|
+
(0, class_validator_1.MaxLength)(200),
|
|
235
|
+
__metadata("design:type", Object)
|
|
236
|
+
], BuymaManualFieldsPayload.prototype, "buyerName", void 0);
|
|
237
|
+
__decorate([
|
|
238
|
+
(0, class_validator_1.IsOptional)(),
|
|
239
|
+
(0, class_validator_1.ValidateNested)(),
|
|
240
|
+
(0, class_transformer_1.Type)(() => BuymaRecipientPayload),
|
|
241
|
+
__metadata("design:type", BuymaRecipientPayload)
|
|
242
|
+
], BuymaManualFieldsPayload.prototype, "recipient", void 0);
|
|
243
|
+
__decorate([
|
|
244
|
+
(0, class_validator_1.IsOptional)(),
|
|
245
|
+
(0, class_validator_1.ValidateNested)(),
|
|
246
|
+
(0, class_transformer_1.Type)(() => BuymaProductMetadataPayload),
|
|
247
|
+
__metadata("design:type", BuymaProductMetadataPayload)
|
|
248
|
+
], BuymaManualFieldsPayload.prototype, "productMetadata", void 0);
|
|
249
|
+
__decorate([
|
|
250
|
+
(0, class_validator_1.IsOptional)(),
|
|
251
|
+
(0, class_validator_1.ValidateNested)(),
|
|
252
|
+
(0, class_transformer_1.Type)(() => BuymaMoneyPayload),
|
|
253
|
+
__metadata("design:type", Object)
|
|
254
|
+
], BuymaManualFieldsPayload.prototype, "productRevenue", void 0);
|
|
255
|
+
__decorate([
|
|
256
|
+
(0, class_validator_1.IsOptional)(),
|
|
257
|
+
(0, class_validator_1.ValidateNested)(),
|
|
258
|
+
(0, class_transformer_1.Type)(() => BuymaMoneyPayload),
|
|
259
|
+
__metadata("design:type", Object)
|
|
260
|
+
], BuymaManualFieldsPayload.prototype, "shippingRevenue", void 0);
|
|
261
|
+
__decorate([
|
|
262
|
+
(0, class_validator_1.IsOptional)(),
|
|
263
|
+
(0, class_validator_1.ValidateNested)(),
|
|
264
|
+
(0, class_transformer_1.Type)(() => BuymaMoneyPayload),
|
|
265
|
+
__metadata("design:type", Object)
|
|
266
|
+
], BuymaManualFieldsPayload.prototype, "reportedTotalRevenue", void 0);
|
|
267
|
+
__decorate([
|
|
268
|
+
(0, class_validator_1.IsOptional)(),
|
|
269
|
+
(0, class_validator_1.IsIn)(entity_v2_1.BUYMA_PROCUREMENT_WORK_STATUSES),
|
|
270
|
+
__metadata("design:type", String)
|
|
271
|
+
], BuymaManualFieldsPayload.prototype, "procurementWorkStatus", void 0);
|
|
272
|
+
__decorate([
|
|
273
|
+
(0, class_validator_1.IsOptional)(),
|
|
274
|
+
(0, class_validator_1.ValidateNested)(),
|
|
275
|
+
(0, class_transformer_1.Type)(() => BuymaProcurementDetailsPayload),
|
|
276
|
+
__metadata("design:type", BuymaProcurementDetailsPayload)
|
|
277
|
+
], BuymaManualFieldsPayload.prototype, "procurementDetails", void 0);
|
|
278
|
+
__decorate([
|
|
279
|
+
(0, class_validator_1.IsOptional)(),
|
|
280
|
+
(0, class_validator_1.ValidateNested)(),
|
|
281
|
+
(0, class_transformer_1.Type)(() => BuymaInternationalShipmentPayload),
|
|
282
|
+
__metadata("design:type", Object)
|
|
283
|
+
], BuymaManualFieldsPayload.prototype, "internationalShipment", void 0);
|
|
284
|
+
__decorate([
|
|
285
|
+
(0, class_validator_1.IsOptional)(),
|
|
286
|
+
(0, class_validator_1.IsBoolean)(),
|
|
287
|
+
__metadata("design:type", Object)
|
|
288
|
+
], BuymaManualFieldsPayload.prototype, "stockSecuredNotified", void 0);
|
|
289
|
+
__decorate([
|
|
290
|
+
(0, class_validator_1.IsOptional)(),
|
|
291
|
+
(0, class_validator_1.IsBoolean)(),
|
|
292
|
+
__metadata("design:type", Object)
|
|
293
|
+
], BuymaManualFieldsPayload.prototype, "forwarderDispatchNotified", void 0);
|
|
294
|
+
__decorate([
|
|
295
|
+
(0, class_validator_1.IsOptional)(),
|
|
296
|
+
(0, class_validator_1.IsString)(),
|
|
297
|
+
(0, class_validator_1.MaxLength)(2000),
|
|
298
|
+
__metadata("design:type", Object)
|
|
299
|
+
], BuymaManualFieldsPayload.prototype, "holdReason", void 0);
|
|
300
|
+
__decorate([
|
|
301
|
+
(0, class_validator_1.IsOptional)(),
|
|
302
|
+
(0, class_validator_1.IsString)(),
|
|
303
|
+
(0, class_validator_1.MaxLength)(10000),
|
|
304
|
+
__metadata("design:type", Object)
|
|
305
|
+
], BuymaManualFieldsPayload.prototype, "memo", void 0);
|
|
306
|
+
__decorate([
|
|
307
|
+
(0, class_validator_1.IsOptional)(),
|
|
308
|
+
(0, class_validator_1.IsArray)(),
|
|
309
|
+
(0, class_validator_1.ArrayMaxSize)(20),
|
|
310
|
+
(0, class_validator_1.ArrayUnique)(),
|
|
311
|
+
(0, class_validator_1.IsString)({ each: true }),
|
|
312
|
+
(0, class_validator_1.MaxLength)(1000, { each: true }),
|
|
313
|
+
__metadata("design:type", Array)
|
|
314
|
+
], BuymaManualFieldsPayload.prototype, "slackThreadUrls", void 0);
|
|
315
|
+
class BuymaOrderCommandPayload {
|
|
316
|
+
}
|
|
317
|
+
exports.BuymaOrderCommandPayload = BuymaOrderCommandPayload;
|
|
318
|
+
__decorate([
|
|
319
|
+
(0, class_validator_1.IsMongoId)(),
|
|
320
|
+
__metadata("design:type", String)
|
|
321
|
+
], BuymaOrderCommandPayload.prototype, "orderId", void 0);
|
|
322
|
+
__decorate([
|
|
323
|
+
(0, class_validator_1.IsInt)(),
|
|
324
|
+
(0, class_validator_1.Min)(0),
|
|
325
|
+
(0, class_validator_1.Max)(Number.MAX_SAFE_INTEGER),
|
|
326
|
+
__metadata("design:type", Number)
|
|
327
|
+
], BuymaOrderCommandPayload.prototype, "expectedRevision", void 0);
|
|
328
|
+
__decorate([
|
|
329
|
+
(0, class_validator_1.IsMongoId)(),
|
|
330
|
+
__metadata("design:type", String)
|
|
331
|
+
], BuymaOrderCommandPayload.prototype, "actorId", void 0);
|
|
332
|
+
__decorate([
|
|
333
|
+
(0, class_validator_1.IsString)(),
|
|
334
|
+
(0, class_validator_1.MaxLength)(2000),
|
|
335
|
+
__metadata("design:type", String)
|
|
336
|
+
], BuymaOrderCommandPayload.prototype, "reason", void 0);
|
|
337
|
+
class UpdateBuymaOrderPayload extends BuymaOrderCommandPayload {
|
|
338
|
+
}
|
|
339
|
+
exports.UpdateBuymaOrderPayload = UpdateBuymaOrderPayload;
|
|
340
|
+
__decorate([
|
|
341
|
+
(0, class_validator_1.IsDefined)(),
|
|
342
|
+
(0, class_validator_1.ValidateNested)(),
|
|
343
|
+
(0, class_transformer_1.Type)(() => BuymaManualFieldsPayload),
|
|
344
|
+
__metadata("design:type", BuymaManualFieldsPayload)
|
|
345
|
+
], UpdateBuymaOrderPayload.prototype, "fields", void 0);
|
|
346
|
+
class ConfirmBuymaPaymentPayload extends BuymaOrderCommandPayload {
|
|
347
|
+
}
|
|
348
|
+
exports.ConfirmBuymaPaymentPayload = ConfirmBuymaPaymentPayload;
|
|
349
|
+
__decorate([
|
|
350
|
+
(0, class_validator_1.IsOptional)(),
|
|
351
|
+
(0, class_validator_1.IsString)(),
|
|
352
|
+
(0, class_validator_1.MaxLength)(40),
|
|
353
|
+
__metadata("design:type", Object)
|
|
354
|
+
], ConfirmBuymaPaymentPayload.prototype, "paidAt", void 0);
|
|
355
|
+
class ConnectBuymaProcurementPayload extends BuymaOrderCommandPayload {
|
|
356
|
+
}
|
|
357
|
+
exports.ConnectBuymaProcurementPayload = ConnectBuymaProcurementPayload;
|
|
358
|
+
__decorate([
|
|
359
|
+
(0, class_validator_1.IsIn)([
|
|
360
|
+
'CROKET',
|
|
361
|
+
'MANUAL',
|
|
362
|
+
]),
|
|
363
|
+
__metadata("design:type", String)
|
|
364
|
+
], ConnectBuymaProcurementPayload.prototype, "source", void 0);
|
|
365
|
+
__decorate([
|
|
366
|
+
(0, class_validator_1.IsString)(),
|
|
367
|
+
(0, class_validator_1.MaxLength)(1000),
|
|
368
|
+
__metadata("design:type", String)
|
|
369
|
+
], ConnectBuymaProcurementPayload.prototype, "orderUrl", void 0);
|
|
370
|
+
__decorate([
|
|
371
|
+
(0, class_validator_1.IsOptional)(),
|
|
372
|
+
(0, class_validator_1.IsMongoId)(),
|
|
373
|
+
__metadata("design:type", String)
|
|
374
|
+
], ConnectBuymaProcurementPayload.prototype, "purchasedInfoId", void 0);
|
|
375
|
+
__decorate([
|
|
376
|
+
(0, class_validator_1.IsOptional)(),
|
|
377
|
+
(0, class_validator_1.IsBoolean)(),
|
|
378
|
+
__metadata("design:type", Boolean)
|
|
379
|
+
], ConnectBuymaProcurementPayload.prototype, "alternative", void 0);
|
|
380
|
+
__decorate([
|
|
381
|
+
(0, class_validator_1.IsBoolean)(),
|
|
382
|
+
__metadata("design:type", Boolean)
|
|
383
|
+
], ConnectBuymaProcurementPayload.prototype, "productAndOptionConfirmed", void 0);
|
|
384
|
+
__decorate([
|
|
385
|
+
(0, class_validator_1.IsOptional)(),
|
|
386
|
+
(0, class_validator_1.ValidateNested)(),
|
|
387
|
+
(0, class_transformer_1.Type)(() => BuymaMoneyPayload),
|
|
388
|
+
__metadata("design:type", Object)
|
|
389
|
+
], ConnectBuymaProcurementPayload.prototype, "purchaseCost", void 0);
|
|
390
|
+
class ChangeBuymaOrderStatusPayload extends BuymaOrderCommandPayload {
|
|
391
|
+
}
|
|
392
|
+
exports.ChangeBuymaOrderStatusPayload = ChangeBuymaOrderStatusPayload;
|
|
393
|
+
__decorate([
|
|
394
|
+
(0, class_validator_1.IsIn)(entity_v2_1.BUYMA_ORDER_STATUSES.filter((value) => value !== 'REFUNDED')),
|
|
395
|
+
__metadata("design:type", Object)
|
|
396
|
+
], ChangeBuymaOrderStatusPayload.prototype, "orderStatus", void 0);
|
|
397
|
+
__decorate([
|
|
398
|
+
(0, class_validator_1.IsOptional)(),
|
|
399
|
+
(0, class_validator_1.IsBoolean)(),
|
|
400
|
+
__metadata("design:type", Boolean)
|
|
401
|
+
], ChangeBuymaOrderStatusPayload.prototype, "fullQuantityDelivered", void 0);
|
|
402
|
+
__decorate([
|
|
403
|
+
(0, class_validator_1.IsOptional)(),
|
|
404
|
+
(0, class_validator_1.IsString)(),
|
|
405
|
+
(0, class_validator_1.MaxLength)(40),
|
|
406
|
+
__metadata("design:type", Object)
|
|
407
|
+
], ChangeBuymaOrderStatusPayload.prototype, "deliveredAt", void 0);
|
|
408
|
+
class RecordBuymaRefundPayload extends BuymaOrderCommandPayload {
|
|
409
|
+
}
|
|
410
|
+
exports.RecordBuymaRefundPayload = RecordBuymaRefundPayload;
|
|
411
|
+
__decorate([
|
|
412
|
+
(0, class_validator_1.IsDefined)(),
|
|
413
|
+
(0, class_validator_1.ValidateNested)(),
|
|
414
|
+
(0, class_transformer_1.Type)(() => BuymaMoneyPayload),
|
|
415
|
+
__metadata("design:type", BuymaMoneyPayload)
|
|
416
|
+
], RecordBuymaRefundPayload.prototype, "amount", void 0);
|
|
417
|
+
__decorate([
|
|
418
|
+
(0, class_validator_1.IsString)(),
|
|
419
|
+
(0, class_validator_1.MaxLength)(40),
|
|
420
|
+
__metadata("design:type", String)
|
|
421
|
+
], RecordBuymaRefundPayload.prototype, "refundedAt", void 0);
|
|
422
|
+
__decorate([
|
|
423
|
+
(0, class_validator_1.IsBoolean)(),
|
|
424
|
+
__metadata("design:type", Boolean)
|
|
425
|
+
], RecordBuymaRefundPayload.prototype, "fullRefundConfirmed", void 0);
|
|
426
|
+
class ReceiveBuymaWebhookPayload {
|
|
427
|
+
}
|
|
428
|
+
exports.ReceiveBuymaWebhookPayload = ReceiveBuymaWebhookPayload;
|
|
429
|
+
__decorate([
|
|
430
|
+
(0, class_validator_1.IsString)(),
|
|
431
|
+
(0, class_validator_1.MaxLength)(100),
|
|
432
|
+
__metadata("design:type", String)
|
|
433
|
+
], ReceiveBuymaWebhookPayload.prototype, "buymaAccountId", void 0);
|
|
434
|
+
__decorate([
|
|
435
|
+
(0, class_validator_1.IsIn)([
|
|
436
|
+
'order/create',
|
|
437
|
+
'order/update',
|
|
438
|
+
]),
|
|
439
|
+
__metadata("design:type", String)
|
|
440
|
+
], ReceiveBuymaWebhookPayload.prototype, "eventType", void 0);
|
|
441
|
+
__decorate([
|
|
442
|
+
(0, class_validator_1.IsString)(),
|
|
443
|
+
(0, class_validator_1.MaxLength)(2000000),
|
|
444
|
+
__metadata("design:type", String)
|
|
445
|
+
], ReceiveBuymaWebhookPayload.prototype, "rawJson", void 0);
|
|
446
|
+
__decorate([
|
|
447
|
+
(0, class_validator_1.IsString)(),
|
|
448
|
+
(0, class_validator_1.Matches)(/^[a-f0-9]{64}$/),
|
|
449
|
+
__metadata("design:type", String)
|
|
450
|
+
], ReceiveBuymaWebhookPayload.prototype, "rawSha256", void 0);
|
|
@@ -14,5 +14,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./
|
|
18
|
-
__exportStar(require("./
|
|
17
|
+
__exportStar(require("./query/buyma-order.dto"), exports);
|
|
18
|
+
__exportStar(require("./command/buyma-order.dto"), exports);
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import { BuymaMoney, BuymaOrderEntity, BuymaOrderEventEntity, BuymaOrderStatus, BuymaPaymentStatus } from '@yolo-croket-dev/entity-v2';
|
|
2
|
+
export declare class GetBuymaOrdersPayload {
|
|
3
|
+
buymaAccountId?: string;
|
|
4
|
+
search?: string;
|
|
5
|
+
paymentStatus?: BuymaPaymentStatus;
|
|
6
|
+
orderStatus?: BuymaOrderStatus;
|
|
7
|
+
procurement?: 'LINKED' | 'UNLINKED';
|
|
8
|
+
review?: 'true' | 'false';
|
|
9
|
+
trackingNumber?: string;
|
|
10
|
+
page: number;
|
|
11
|
+
limit: number;
|
|
12
|
+
}
|
|
13
|
+
export declare class GetBuymaOrderPayload {
|
|
14
|
+
orderId: string;
|
|
15
|
+
}
|
|
16
|
+
export declare class GetBuymaOrderHistoryPayload extends GetBuymaOrderPayload {
|
|
17
|
+
cursor?: string;
|
|
18
|
+
limit: number;
|
|
19
|
+
}
|
|
20
|
+
export declare class GetBuymaProcurementCandidatesPayload extends GetBuymaOrderPayload {
|
|
21
|
+
orderUrl: string;
|
|
22
|
+
}
|
|
23
|
+
export interface BuymaOrderListItem extends Pick<BuymaOrderEntity, '_id' | 'buymaAccountId' | 'buymaOrderNumber' | 'createdAt' | 'quantity' | 'productRevenue' | 'orderStatus' | 'holdReason'> {
|
|
24
|
+
productSnapshot: Pick<BuymaOrderEntity['productSnapshot'], 'buymaName' | 'croketName' | 'optionName'>;
|
|
25
|
+
payment: Pick<BuymaOrderEntity['payment'], 'status'>;
|
|
26
|
+
procurement: Pick<NonNullable<BuymaOrderEntity['procurement']>, 'source' | 'croketPurchasedInfoPublicId'> | null;
|
|
27
|
+
internationalShipment: Pick<NonNullable<BuymaOrderEntity['internationalShipment']>, 'trackingNumber'> | null;
|
|
28
|
+
}
|
|
29
|
+
export interface BuymaSharedTrackingOrder extends Pick<BuymaOrderEntity, '_id' | 'buymaOrderNumber' | 'quantity'> {
|
|
30
|
+
internationalShipment: Pick<NonNullable<BuymaOrderEntity['internationalShipment']>, 'shippingCost'> | null;
|
|
31
|
+
}
|
|
32
|
+
export interface GetBuymaOrdersResult {
|
|
33
|
+
items: BuymaOrderListItem[];
|
|
34
|
+
total: number;
|
|
35
|
+
page: number;
|
|
36
|
+
limit: number;
|
|
37
|
+
}
|
|
38
|
+
export interface GetBuymaOrderResult {
|
|
39
|
+
item: BuymaOrderEntity;
|
|
40
|
+
sharedTrackingOrders: BuymaSharedTrackingOrder[];
|
|
41
|
+
}
|
|
42
|
+
export interface GetBuymaOrderHistoryResult {
|
|
43
|
+
items: BuymaOrderEventEntity[];
|
|
44
|
+
nextCursor: string | null;
|
|
45
|
+
}
|
|
46
|
+
export interface BuymaProcurementCandidate {
|
|
47
|
+
purchaseReceiptId: string;
|
|
48
|
+
purchasedInfoId: string;
|
|
49
|
+
publicId: string | null;
|
|
50
|
+
itemId: string;
|
|
51
|
+
itemName: string | null;
|
|
52
|
+
optionName: string | null;
|
|
53
|
+
quantity: number;
|
|
54
|
+
paymentStatus: string | null;
|
|
55
|
+
sourceStatus: string | null;
|
|
56
|
+
productPrice: BuymaMoney | null;
|
|
57
|
+
shippingCost: BuymaMoney | null;
|
|
58
|
+
eligible: boolean;
|
|
59
|
+
blockingReasons: string[];
|
|
60
|
+
reviewReasons: string[];
|
|
61
|
+
}
|
|
62
|
+
export interface GetBuymaProcurementCandidatesResult {
|
|
63
|
+
items: BuymaProcurementCandidate[];
|
|
64
|
+
}
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.GetBuymaProcurementCandidatesPayload = exports.GetBuymaOrderHistoryPayload = exports.GetBuymaOrderPayload = exports.GetBuymaOrdersPayload = void 0;
|
|
13
|
+
/** @author jun @description Buyma 관리자 조회 계약. @process 페이지 상한과 정확한 구매 건 후보를 공개한다. */
|
|
14
|
+
const class_transformer_1 = require("class-transformer");
|
|
15
|
+
const class_validator_1 = require("class-validator");
|
|
16
|
+
const entity_v2_1 = require("@yolo-croket-dev/entity-v2");
|
|
17
|
+
class GetBuymaOrdersPayload {
|
|
18
|
+
constructor() {
|
|
19
|
+
this.page = 1;
|
|
20
|
+
this.limit = 30;
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
exports.GetBuymaOrdersPayload = GetBuymaOrdersPayload;
|
|
24
|
+
__decorate([
|
|
25
|
+
(0, class_validator_1.IsOptional)(),
|
|
26
|
+
(0, class_validator_1.IsString)(),
|
|
27
|
+
(0, class_validator_1.MaxLength)(100),
|
|
28
|
+
__metadata("design:type", String)
|
|
29
|
+
], GetBuymaOrdersPayload.prototype, "buymaAccountId", void 0);
|
|
30
|
+
__decorate([
|
|
31
|
+
(0, class_validator_1.IsOptional)(),
|
|
32
|
+
(0, class_validator_1.IsString)(),
|
|
33
|
+
(0, class_validator_1.MaxLength)(120),
|
|
34
|
+
__metadata("design:type", String)
|
|
35
|
+
], GetBuymaOrdersPayload.prototype, "search", void 0);
|
|
36
|
+
__decorate([
|
|
37
|
+
(0, class_validator_1.IsOptional)(),
|
|
38
|
+
(0, class_validator_1.IsIn)(entity_v2_1.BUYMA_PAYMENT_STATUSES),
|
|
39
|
+
__metadata("design:type", String)
|
|
40
|
+
], GetBuymaOrdersPayload.prototype, "paymentStatus", void 0);
|
|
41
|
+
__decorate([
|
|
42
|
+
(0, class_validator_1.IsOptional)(),
|
|
43
|
+
(0, class_validator_1.IsIn)(entity_v2_1.BUYMA_ORDER_STATUSES),
|
|
44
|
+
__metadata("design:type", String)
|
|
45
|
+
], GetBuymaOrdersPayload.prototype, "orderStatus", void 0);
|
|
46
|
+
__decorate([
|
|
47
|
+
(0, class_validator_1.IsOptional)(),
|
|
48
|
+
(0, class_validator_1.IsIn)([
|
|
49
|
+
'LINKED',
|
|
50
|
+
'UNLINKED',
|
|
51
|
+
]),
|
|
52
|
+
__metadata("design:type", String)
|
|
53
|
+
], GetBuymaOrdersPayload.prototype, "procurement", void 0);
|
|
54
|
+
__decorate([
|
|
55
|
+
(0, class_validator_1.IsOptional)(),
|
|
56
|
+
(0, class_validator_1.IsIn)([
|
|
57
|
+
'true',
|
|
58
|
+
'false',
|
|
59
|
+
]),
|
|
60
|
+
__metadata("design:type", String)
|
|
61
|
+
], GetBuymaOrdersPayload.prototype, "review", void 0);
|
|
62
|
+
__decorate([
|
|
63
|
+
(0, class_validator_1.IsOptional)(),
|
|
64
|
+
(0, class_validator_1.IsString)(),
|
|
65
|
+
(0, class_validator_1.MaxLength)(100),
|
|
66
|
+
__metadata("design:type", String)
|
|
67
|
+
], GetBuymaOrdersPayload.prototype, "trackingNumber", void 0);
|
|
68
|
+
__decorate([
|
|
69
|
+
(0, class_transformer_1.Type)(() => Number),
|
|
70
|
+
(0, class_validator_1.IsInt)(),
|
|
71
|
+
(0, class_validator_1.Min)(1),
|
|
72
|
+
(0, class_validator_1.Max)(10000),
|
|
73
|
+
__metadata("design:type", Number)
|
|
74
|
+
], GetBuymaOrdersPayload.prototype, "page", void 0);
|
|
75
|
+
__decorate([
|
|
76
|
+
(0, class_transformer_1.Type)(() => Number),
|
|
77
|
+
(0, class_validator_1.IsInt)(),
|
|
78
|
+
(0, class_validator_1.Min)(1),
|
|
79
|
+
(0, class_validator_1.Max)(100),
|
|
80
|
+
__metadata("design:type", Number)
|
|
81
|
+
], GetBuymaOrdersPayload.prototype, "limit", void 0);
|
|
82
|
+
class GetBuymaOrderPayload {
|
|
83
|
+
}
|
|
84
|
+
exports.GetBuymaOrderPayload = GetBuymaOrderPayload;
|
|
85
|
+
__decorate([
|
|
86
|
+
(0, class_validator_1.IsMongoId)(),
|
|
87
|
+
__metadata("design:type", String)
|
|
88
|
+
], GetBuymaOrderPayload.prototype, "orderId", void 0);
|
|
89
|
+
class GetBuymaOrderHistoryPayload extends GetBuymaOrderPayload {
|
|
90
|
+
constructor() {
|
|
91
|
+
super(...arguments);
|
|
92
|
+
this.limit = 30;
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
exports.GetBuymaOrderHistoryPayload = GetBuymaOrderHistoryPayload;
|
|
96
|
+
__decorate([
|
|
97
|
+
(0, class_validator_1.IsOptional)(),
|
|
98
|
+
(0, class_validator_1.IsMongoId)(),
|
|
99
|
+
__metadata("design:type", String)
|
|
100
|
+
], GetBuymaOrderHistoryPayload.prototype, "cursor", void 0);
|
|
101
|
+
__decorate([
|
|
102
|
+
(0, class_transformer_1.Type)(() => Number),
|
|
103
|
+
(0, class_validator_1.IsInt)(),
|
|
104
|
+
(0, class_validator_1.Min)(1),
|
|
105
|
+
(0, class_validator_1.Max)(100),
|
|
106
|
+
__metadata("design:type", Number)
|
|
107
|
+
], GetBuymaOrderHistoryPayload.prototype, "limit", void 0);
|
|
108
|
+
class GetBuymaProcurementCandidatesPayload extends GetBuymaOrderPayload {
|
|
109
|
+
}
|
|
110
|
+
exports.GetBuymaProcurementCandidatesPayload = GetBuymaProcurementCandidatesPayload;
|
|
111
|
+
__decorate([
|
|
112
|
+
(0, class_validator_1.IsString)(),
|
|
113
|
+
(0, class_validator_1.MaxLength)(1000),
|
|
114
|
+
__metadata("design:type", String)
|
|
115
|
+
], GetBuymaProcurementCandidatesPayload.prototype, "orderUrl", void 0);
|
|
@@ -26,3 +26,4 @@ __exportStar(require("./customs"), exports);
|
|
|
26
26
|
__exportStar(require("./p-info-pending-settle"), exports);
|
|
27
27
|
__exportStar(require("./store-item-pending-settle"), exports);
|
|
28
28
|
__exportStar(require("./admin-settlement-limit"), exports);
|
|
29
|
+
__exportStar(require("./buyma-order"), exports);
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { ClientProxy } from '@nestjs/microservices';
|
|
2
|
+
import { AbstractParam } from '@yolo-croket-dev/core';
|
|
3
|
+
import * as DTO from '../dto/buyma-order';
|
|
4
|
+
export declare class AmqpBuymaOrderService {
|
|
5
|
+
private readonly manager;
|
|
6
|
+
constructor(client: ClientProxy);
|
|
7
|
+
getList(payload: DTO.GetBuymaOrdersPayload, param: AbstractParam): Promise<DTO.GetBuymaOrdersResult>;
|
|
8
|
+
getDetail(payload: DTO.GetBuymaOrderPayload, param: AbstractParam): Promise<DTO.GetBuymaOrderResult>;
|
|
9
|
+
getHistory(payload: DTO.GetBuymaOrderHistoryPayload, param: AbstractParam): Promise<DTO.GetBuymaOrderHistoryResult>;
|
|
10
|
+
getCandidates(payload: DTO.GetBuymaProcurementCandidatesPayload, param: AbstractParam): Promise<DTO.GetBuymaProcurementCandidatesResult>;
|
|
11
|
+
update(payload: DTO.UpdateBuymaOrderPayload, param: AbstractParam): Promise<DTO.UpdateBuymaOrderResult>;
|
|
12
|
+
confirmPayment(payload: DTO.ConfirmBuymaPaymentPayload, param: AbstractParam): Promise<DTO.UpdateBuymaOrderResult>;
|
|
13
|
+
connectProcurement(payload: DTO.ConnectBuymaProcurementPayload, param: AbstractParam): Promise<DTO.UpdateBuymaOrderResult>;
|
|
14
|
+
changeStatus(payload: DTO.ChangeBuymaOrderStatusPayload, param: AbstractParam): Promise<DTO.UpdateBuymaOrderResult>;
|
|
15
|
+
recordRefund(payload: DTO.RecordBuymaRefundPayload, param: AbstractParam): Promise<DTO.UpdateBuymaOrderResult>;
|
|
16
|
+
receiveWebhook(payload: DTO.ReceiveBuymaWebhookPayload, param: AbstractParam): Promise<DTO.ReceiveBuymaWebhookResult>;
|
|
17
|
+
}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
+
};
|
|
11
|
+
var __param = (this && this.__param) || function (paramIndex, decorator) {
|
|
12
|
+
return function (target, key) { decorator(target, key, paramIndex); }
|
|
13
|
+
};
|
|
14
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
|
+
exports.AmqpBuymaOrderService = void 0;
|
|
16
|
+
/** @author jun @description Buyma 관리 RPC. @process 원문 인증 이후의 주문 업무를 order-server에 위임한다. */
|
|
17
|
+
const common_1 = require("@nestjs/common");
|
|
18
|
+
const microservices_1 = require("@nestjs/microservices");
|
|
19
|
+
const core_1 = require("@yolo-croket-dev/core");
|
|
20
|
+
let AmqpBuymaOrderService = class AmqpBuymaOrderService {
|
|
21
|
+
constructor(client) {
|
|
22
|
+
this.manager = new core_1.AmqpManagement(client);
|
|
23
|
+
}
|
|
24
|
+
getList(payload, param) {
|
|
25
|
+
return this.manager.call('Buyma 주문 목록', 'buyma-order.get.list', payload, param, { isErrorThrowing: true });
|
|
26
|
+
}
|
|
27
|
+
getDetail(payload, param) {
|
|
28
|
+
return this.manager.call('Buyma 주문 상세', 'buyma-order.get.detail', payload, param, { isErrorThrowing: true });
|
|
29
|
+
}
|
|
30
|
+
getHistory(payload, param) {
|
|
31
|
+
return this.manager.call('Buyma 변경 이력', 'buyma-order.get.history', payload, param, { isErrorThrowing: true });
|
|
32
|
+
}
|
|
33
|
+
getCandidates(payload, param) {
|
|
34
|
+
return this.manager.call('Buyma 사입 후보', 'buyma-order.get.procurement-candidates', payload, param, { isErrorThrowing: true });
|
|
35
|
+
}
|
|
36
|
+
update(payload, param) {
|
|
37
|
+
return this.manager.call('Buyma 정보 정정', 'buyma-order.update.fields', payload, param, { isErrorThrowing: true });
|
|
38
|
+
}
|
|
39
|
+
confirmPayment(payload, param) {
|
|
40
|
+
return this.manager.call('Buyma 입금 확인', 'buyma-order.confirm.payment', payload, param, { isErrorThrowing: true });
|
|
41
|
+
}
|
|
42
|
+
connectProcurement(payload, param) {
|
|
43
|
+
return this.manager.call('Buyma 사입 연결', 'buyma-order.connect.procurement', payload, param, { isErrorThrowing: true });
|
|
44
|
+
}
|
|
45
|
+
changeStatus(payload, param) {
|
|
46
|
+
return this.manager.call('Buyma 상태 기록', 'buyma-order.update.status', payload, param, { isErrorThrowing: true });
|
|
47
|
+
}
|
|
48
|
+
recordRefund(payload, param) {
|
|
49
|
+
return this.manager.call('Buyma 전체 환불 기록', 'buyma-order.record.refund', payload, param, { isErrorThrowing: true });
|
|
50
|
+
}
|
|
51
|
+
receiveWebhook(payload, param) {
|
|
52
|
+
return this.manager.call('Buyma 웹훅 접수', 'buyma-order.receive.webhook', payload, param, { isErrorThrowing: true });
|
|
53
|
+
}
|
|
54
|
+
};
|
|
55
|
+
exports.AmqpBuymaOrderService = AmqpBuymaOrderService;
|
|
56
|
+
exports.AmqpBuymaOrderService = AmqpBuymaOrderService = __decorate([
|
|
57
|
+
(0, common_1.Injectable)(),
|
|
58
|
+
__param(0, (0, common_1.Inject)('ORDER_SERVER_PROVIDER')),
|
|
59
|
+
__metadata("design:paramtypes", [microservices_1.ClientProxy])
|
|
60
|
+
], AmqpBuymaOrderService);
|
|
@@ -34,3 +34,4 @@ __exportStar(require("./amqp.customs.service"), exports);
|
|
|
34
34
|
__exportStar(require("./amqp.p-info-pending-settle.service"), exports);
|
|
35
35
|
__exportStar(require("./amqp.store-item-pending-settle.service"), exports);
|
|
36
36
|
__exportStar(require("./amqp.admin-settlement-limit.service"), exports);
|
|
37
|
+
__exportStar(require("./amqp.buyma-order.service"), exports);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@yolo-croket-dev/amqp-access",
|
|
3
|
-
"version": "0.7.380-beta.
|
|
3
|
+
"version": "0.7.380-beta.2",
|
|
4
4
|
"main": "index.js",
|
|
5
5
|
"author": "Yolo Co., Ltd.",
|
|
6
6
|
"description": "크로켓 amqp-access npm",
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
"@yolo-croket-dev/domain": "0.2.50",
|
|
25
25
|
"@yolo-croket-dev/dto-v2": "0.2.35",
|
|
26
26
|
"@yolo-croket-dev/entity": "0.2.110",
|
|
27
|
-
"@yolo-croket-dev/entity-v2": "0.3.58",
|
|
27
|
+
"@yolo-croket-dev/entity-v2": "0.3.58-beta.1",
|
|
28
28
|
"class-transformer": "^0.5.1",
|
|
29
29
|
"class-validator": "^0.13.2",
|
|
30
30
|
"dotenv": "^16.3.1"
|
package/payment-service/dto/ad-center-settle/query/get-ad-center-settles-for-google-sheet.dto.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { AdCenterSettle } from '@yolo-croket-dev/entity/src/ad-center-settle/ad-center-settle.schema';
|
|
2
2
|
import { BusinessInfo } from '@yolo-croket-dev/entity/src/store';
|
|
3
|
-
declare const AdCenterSettleForGoogleSheet_base: import("@nestjs/common").Type<Pick<AdCenterSettle, "_id" | "sellerId" | "
|
|
3
|
+
declare const AdCenterSettleForGoogleSheet_base: import("@nestjs/common").Type<Pick<AdCenterSettle, "_id" | "sellerId" | "publicId" | "couponInfo" | "pastStoreInfo" | "PInfoId" | "expectedSettleDateString" | "adType" | "adCenterStartDateString" | "adCenterEndDateString" | "transactionInfo" | "bizMemo" | "subtractionSettleAmountInfo" | "settlementManagerInfo" | "googleSheetInfo" | "actualSettleDateString" | "financeMemo">>;
|
|
4
4
|
/** 구글 시트용 광고센터정산 데이터 */
|
|
5
5
|
export declare class AdCenterSettleForGoogleSheet extends AdCenterSettleForGoogleSheet_base {
|
|
6
6
|
storeInfo: {
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { RunNaverSearchAdExcelFullProcessPayload } from './run-naver-search-ad-excel-full-process.dto';
|
|
2
|
-
/**
|
|
3
|
-
* @author jun
|
|
4
|
-
* @description 기존 조회 조건으로 네이버 SA 리포트 작업을 등록합니다.
|
|
5
|
-
* @process 조건 검증 → 큐 등록 → 작업 ID 반환
|
|
6
|
-
*/
|
|
7
|
-
export declare class CreateNaverSearchAdExcelJobPayload extends RunNaverSearchAdExcelFullProcessPayload {
|
|
8
|
-
/** Gateway 인증 결과에서만 채우는 자동화 서비스 식별자입니다. 관리자 작업에는 없습니다. */
|
|
9
|
-
reportClientId?: string;
|
|
10
|
-
}
|
|
11
|
-
export interface CreateNaverSearchAdExcelJobResult {
|
|
12
|
-
jobId: string;
|
|
13
|
-
status: 'queued';
|
|
14
|
-
}
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
-
};
|
|
8
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.CreateNaverSearchAdExcelJobPayload = void 0;
|
|
13
|
-
const class_validator_1 = require("class-validator");
|
|
14
|
-
const run_naver_search_ad_excel_full_process_dto_1 = require("./run-naver-search-ad-excel-full-process.dto");
|
|
15
|
-
/**
|
|
16
|
-
* @author jun
|
|
17
|
-
* @description 기존 조회 조건으로 네이버 SA 리포트 작업을 등록합니다.
|
|
18
|
-
* @process 조건 검증 → 큐 등록 → 작업 ID 반환
|
|
19
|
-
*/
|
|
20
|
-
class CreateNaverSearchAdExcelJobPayload extends run_naver_search_ad_excel_full_process_dto_1.RunNaverSearchAdExcelFullProcessPayload {
|
|
21
|
-
}
|
|
22
|
-
exports.CreateNaverSearchAdExcelJobPayload = CreateNaverSearchAdExcelJobPayload;
|
|
23
|
-
__decorate([
|
|
24
|
-
(0, class_validator_1.IsOptional)(),
|
|
25
|
-
(0, class_validator_1.IsString)(),
|
|
26
|
-
(0, class_validator_1.Matches)(/^[a-zA-Z0-9_-]{1,64}$/),
|
|
27
|
-
__metadata("design:type", String)
|
|
28
|
-
], CreateNaverSearchAdExcelJobPayload.prototype, "reportClientId", void 0);
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { GetNaverSearchAdExcelJobPayload, NaverSearchAdExcelJobAccessPayload } from './get-naver-search-ad-excel-job.dto';
|
|
2
|
-
/**
|
|
3
|
-
* @author jun
|
|
4
|
-
* @description 자동화 조회 RPC는 인증 범위를 필수로 받습니다.
|
|
5
|
-
* @process 별도 라우팅 → 필수 권한 범위 검증 → 작업 소유자·계정 확인
|
|
6
|
-
*/
|
|
7
|
-
export declare class GetNaverSearchAdExcelExternalJobPayload extends GetNaverSearchAdExcelJobPayload {
|
|
8
|
-
reportAccess: NaverSearchAdExcelJobAccessPayload;
|
|
9
|
-
}
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
-
};
|
|
8
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.GetNaverSearchAdExcelExternalJobPayload = void 0;
|
|
13
|
-
const class_validator_1 = require("class-validator");
|
|
14
|
-
const class_transformer_1 = require("class-transformer");
|
|
15
|
-
const get_naver_search_ad_excel_job_dto_1 = require("./get-naver-search-ad-excel-job.dto");
|
|
16
|
-
/**
|
|
17
|
-
* @author jun
|
|
18
|
-
* @description 자동화 조회 RPC는 인증 범위를 필수로 받습니다.
|
|
19
|
-
* @process 별도 라우팅 → 필수 권한 범위 검증 → 작업 소유자·계정 확인
|
|
20
|
-
*/
|
|
21
|
-
class GetNaverSearchAdExcelExternalJobPayload extends get_naver_search_ad_excel_job_dto_1.GetNaverSearchAdExcelJobPayload {
|
|
22
|
-
}
|
|
23
|
-
exports.GetNaverSearchAdExcelExternalJobPayload = GetNaverSearchAdExcelExternalJobPayload;
|
|
24
|
-
__decorate([
|
|
25
|
-
(0, class_validator_1.IsDefined)(),
|
|
26
|
-
(0, class_validator_1.ValidateNested)(),
|
|
27
|
-
(0, class_transformer_1.Type)(() => get_naver_search_ad_excel_job_dto_1.NaverSearchAdExcelJobAccessPayload),
|
|
28
|
-
__metadata("design:type", get_naver_search_ad_excel_job_dto_1.NaverSearchAdExcelJobAccessPayload)
|
|
29
|
-
], GetNaverSearchAdExcelExternalJobPayload.prototype, "reportAccess", void 0);
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import { NaverSearchAdAccountEnum } from '@yolo-croket-dev/entity-v2/naver-search-ad.modules/naver-search-ad-excel';
|
|
2
|
-
/** @author jun @description Gateway 인증 결과에 따른 자동화 리포트 조회 범위입니다. @process 인증 → 작업 소유자·계정 확인 */
|
|
3
|
-
export declare class NaverSearchAdExcelJobAccessPayload {
|
|
4
|
-
clientId: string;
|
|
5
|
-
accounts: NaverSearchAdAccountEnum[];
|
|
6
|
-
}
|
|
7
|
-
/**
|
|
8
|
-
* @author jun
|
|
9
|
-
* @description 네이버 SA 리포트 작업의 상태와 완료된 파일 주소를 조회합니다.
|
|
10
|
-
* @process 작업 ID 검증 → 상태 조회 → 공개 응답 반환
|
|
11
|
-
*/
|
|
12
|
-
export declare class GetNaverSearchAdExcelJobPayload {
|
|
13
|
-
jobId: string;
|
|
14
|
-
}
|
|
15
|
-
export type NaverSearchAdExcelJobStatus = 'queued' | 'processing' | 'completed' | 'failed';
|
|
16
|
-
export interface GetNaverSearchAdExcelJobResult {
|
|
17
|
-
jobId: string;
|
|
18
|
-
status: NaverSearchAdExcelJobStatus;
|
|
19
|
-
/** 파일 업로드가 완료된 경우에만 반환합니다. */
|
|
20
|
-
downloadUrl?: string;
|
|
21
|
-
/** 작업 실패 시 공개 가능한 코드와 안내 문구만 반환합니다. */
|
|
22
|
-
error?: {
|
|
23
|
-
code: string;
|
|
24
|
-
message: string;
|
|
25
|
-
};
|
|
26
|
-
}
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
-
};
|
|
8
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.GetNaverSearchAdExcelJobPayload = exports.NaverSearchAdExcelJobAccessPayload = void 0;
|
|
13
|
-
const class_validator_1 = require("class-validator");
|
|
14
|
-
const naver_search_ad_excel_1 = require("@yolo-croket-dev/entity-v2/naver-search-ad.modules/naver-search-ad-excel");
|
|
15
|
-
/** @author jun @description Gateway 인증 결과에 따른 자동화 리포트 조회 범위입니다. @process 인증 → 작업 소유자·계정 확인 */
|
|
16
|
-
class NaverSearchAdExcelJobAccessPayload {
|
|
17
|
-
}
|
|
18
|
-
exports.NaverSearchAdExcelJobAccessPayload = NaverSearchAdExcelJobAccessPayload;
|
|
19
|
-
__decorate([
|
|
20
|
-
(0, class_validator_1.IsString)(),
|
|
21
|
-
(0, class_validator_1.Matches)(/^[a-zA-Z0-9_-]{1,64}$/),
|
|
22
|
-
__metadata("design:type", String)
|
|
23
|
-
], NaverSearchAdExcelJobAccessPayload.prototype, "clientId", void 0);
|
|
24
|
-
__decorate([
|
|
25
|
-
(0, class_validator_1.IsArray)(),
|
|
26
|
-
(0, class_validator_1.ArrayNotEmpty)(),
|
|
27
|
-
(0, class_validator_1.IsEnum)(naver_search_ad_excel_1.NaverSearchAdAccountEnum, { each: true }),
|
|
28
|
-
__metadata("design:type", Array)
|
|
29
|
-
], NaverSearchAdExcelJobAccessPayload.prototype, "accounts", void 0);
|
|
30
|
-
/**
|
|
31
|
-
* @author jun
|
|
32
|
-
* @description 네이버 SA 리포트 작업의 상태와 완료된 파일 주소를 조회합니다.
|
|
33
|
-
* @process 작업 ID 검증 → 상태 조회 → 공개 응답 반환
|
|
34
|
-
*/
|
|
35
|
-
class GetNaverSearchAdExcelJobPayload {
|
|
36
|
-
}
|
|
37
|
-
exports.GetNaverSearchAdExcelJobPayload = GetNaverSearchAdExcelJobPayload;
|
|
38
|
-
__decorate([
|
|
39
|
-
(0, class_validator_1.IsString)(),
|
|
40
|
-
(0, class_validator_1.IsNotEmpty)(),
|
|
41
|
-
(0, class_validator_1.MaxLength)(128),
|
|
42
|
-
__metadata("design:type", String)
|
|
43
|
-
], GetNaverSearchAdExcelJobPayload.prototype, "jobId", void 0);
|