@yolo-croket-dev/amqp-access 0.7.232 → 0.7.234
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/ad-performance-report/command/create-ad-performance-report-excel.dto.d.ts +32 -0
- package/excel-upload-server/dto/ad-performance-report/command/create-ad-performance-report-excel.dto.js +73 -0
- package/excel-upload-server/dto/ad-performance-report/command/create-sns-roas-report-excel-result.dto.d.ts +15 -0
- package/excel-upload-server/dto/ad-performance-report/command/create-sns-roas-report-excel-result.dto.js +2 -0
- package/excel-upload-server/dto/ad-performance-report/command/index.d.ts +1 -0
- package/excel-upload-server/dto/ad-performance-report/command/index.js +1 -0
- package/excel-upload-server/dto/ad-performance-report/command/sns-roas-source-row.dto.d.ts +10 -0
- package/excel-upload-server/dto/ad-performance-report/command/sns-roas-source-row.dto.js +38 -0
- package/excel-upload-server/services/amqp.ad-performance-report.service.d.ts +2 -1
- package/excel-upload-server/services/amqp.ad-performance-report.service.js +3 -0
- package/order-server/dto/purchased-info.modules/purchased-info-admin/command/upsert-invoice-bulk-for-admin.dto.d.ts +34 -0
- package/order-server/dto/purchased-info.modules/purchased-info-admin/command/upsert-invoice-bulk-for-admin.dto.js +56 -0
- package/package.json +2 -2
- package/.claude/settings.local.json +0 -11
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @author jun
|
|
3
|
+
* @description 채널별 광고 성과 통합 엑셀 생성 AMQP 요청 DTO
|
|
4
|
+
* @process 조회 기간과 선택적인 광고 계정·캠페인 설정을 Excel Upload Server에 전달합니다.
|
|
5
|
+
*/
|
|
6
|
+
export declare class CreateAdPerformanceReportExcelPayload {
|
|
7
|
+
startDate?: string;
|
|
8
|
+
endDate?: string;
|
|
9
|
+
naverSearchAdCampaignId?: string;
|
|
10
|
+
naverSearchAdCampaignName?: string;
|
|
11
|
+
kakaoMomentAdAccountId?: string;
|
|
12
|
+
kakaoMomentCampaignIds?: string[];
|
|
13
|
+
metaAdAccountId?: string;
|
|
14
|
+
metaCampaignIds?: string[];
|
|
15
|
+
}
|
|
16
|
+
export interface AdPerformanceReportExcelSheetResult {
|
|
17
|
+
name: string;
|
|
18
|
+
rowCount: number;
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* @author jun
|
|
22
|
+
* @description 채널별 광고 성과 통합 엑셀 생성 AMQP 응답 DTO
|
|
23
|
+
* @process 생성 파일의 다운로드 정보, 시트별 행 수와 채널 조회 경고를 반환합니다.
|
|
24
|
+
*/
|
|
25
|
+
export interface CreateAdPerformanceReportExcelResult {
|
|
26
|
+
startDate: string;
|
|
27
|
+
endDate: string;
|
|
28
|
+
fileName: string;
|
|
29
|
+
downloadUrl: string;
|
|
30
|
+
sheets: AdPerformanceReportExcelSheetResult[];
|
|
31
|
+
warnings: string[];
|
|
32
|
+
}
|
|
@@ -0,0 +1,73 @@
|
|
|
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.CreateAdPerformanceReportExcelPayload = void 0;
|
|
13
|
+
const class_validator_1 = require("class-validator");
|
|
14
|
+
/**
|
|
15
|
+
* @author jun
|
|
16
|
+
* @description 채널별 광고 성과 통합 엑셀 생성 AMQP 요청 DTO
|
|
17
|
+
* @process 조회 기간과 선택적인 광고 계정·캠페인 설정을 Excel Upload Server에 전달합니다.
|
|
18
|
+
*/
|
|
19
|
+
class CreateAdPerformanceReportExcelPayload {
|
|
20
|
+
}
|
|
21
|
+
exports.CreateAdPerformanceReportExcelPayload = CreateAdPerformanceReportExcelPayload;
|
|
22
|
+
__decorate([
|
|
23
|
+
(0, class_validator_1.IsOptional)(),
|
|
24
|
+
(0, class_validator_1.IsDateString)({ strict: true }),
|
|
25
|
+
(0, class_validator_1.Matches)(/^\d{4}-\d{2}-\d{2}$/),
|
|
26
|
+
__metadata("design:type", String)
|
|
27
|
+
], CreateAdPerformanceReportExcelPayload.prototype, "startDate", void 0);
|
|
28
|
+
__decorate([
|
|
29
|
+
(0, class_validator_1.IsOptional)(),
|
|
30
|
+
(0, class_validator_1.IsDateString)({ strict: true }),
|
|
31
|
+
(0, class_validator_1.Matches)(/^\d{4}-\d{2}-\d{2}$/),
|
|
32
|
+
__metadata("design:type", String)
|
|
33
|
+
], CreateAdPerformanceReportExcelPayload.prototype, "endDate", void 0);
|
|
34
|
+
__decorate([
|
|
35
|
+
(0, class_validator_1.IsOptional)(),
|
|
36
|
+
(0, class_validator_1.IsString)(),
|
|
37
|
+
(0, class_validator_1.IsNotEmpty)(),
|
|
38
|
+
__metadata("design:type", String)
|
|
39
|
+
], CreateAdPerformanceReportExcelPayload.prototype, "naverSearchAdCampaignId", void 0);
|
|
40
|
+
__decorate([
|
|
41
|
+
(0, class_validator_1.IsOptional)(),
|
|
42
|
+
(0, class_validator_1.IsString)(),
|
|
43
|
+
(0, class_validator_1.IsNotEmpty)(),
|
|
44
|
+
__metadata("design:type", String)
|
|
45
|
+
], CreateAdPerformanceReportExcelPayload.prototype, "naverSearchAdCampaignName", void 0);
|
|
46
|
+
__decorate([
|
|
47
|
+
(0, class_validator_1.IsOptional)(),
|
|
48
|
+
(0, class_validator_1.IsString)(),
|
|
49
|
+
(0, class_validator_1.IsNotEmpty)(),
|
|
50
|
+
__metadata("design:type", String)
|
|
51
|
+
], CreateAdPerformanceReportExcelPayload.prototype, "kakaoMomentAdAccountId", void 0);
|
|
52
|
+
__decorate([
|
|
53
|
+
(0, class_validator_1.IsOptional)(),
|
|
54
|
+
(0, class_validator_1.IsArray)(),
|
|
55
|
+
(0, class_validator_1.ArrayUnique)(),
|
|
56
|
+
(0, class_validator_1.IsString)({ each: true }),
|
|
57
|
+
(0, class_validator_1.IsNotEmpty)({ each: true }),
|
|
58
|
+
__metadata("design:type", Array)
|
|
59
|
+
], CreateAdPerformanceReportExcelPayload.prototype, "kakaoMomentCampaignIds", void 0);
|
|
60
|
+
__decorate([
|
|
61
|
+
(0, class_validator_1.IsOptional)(),
|
|
62
|
+
(0, class_validator_1.IsString)(),
|
|
63
|
+
(0, class_validator_1.IsNotEmpty)(),
|
|
64
|
+
__metadata("design:type", String)
|
|
65
|
+
], CreateAdPerformanceReportExcelPayload.prototype, "metaAdAccountId", void 0);
|
|
66
|
+
__decorate([
|
|
67
|
+
(0, class_validator_1.IsOptional)(),
|
|
68
|
+
(0, class_validator_1.IsArray)(),
|
|
69
|
+
(0, class_validator_1.ArrayUnique)(),
|
|
70
|
+
(0, class_validator_1.IsString)({ each: true }),
|
|
71
|
+
(0, class_validator_1.IsNotEmpty)({ each: true }),
|
|
72
|
+
__metadata("design:type", Array)
|
|
73
|
+
], CreateAdPerformanceReportExcelPayload.prototype, "metaCampaignIds", void 0);
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @author jun
|
|
3
|
+
* @description SNS ROAS 엑셀 생성 AMQP 응답입니다.
|
|
4
|
+
* @process 생성된 파일과 처리 범위 및 처리 건수를 호출 서버에 반환합니다.
|
|
5
|
+
*/
|
|
6
|
+
export interface CreateSnsRoasReportExcelResult {
|
|
7
|
+
downloadUrl: string;
|
|
8
|
+
endDate: string;
|
|
9
|
+
exchangeRateKrwPerUsd: number;
|
|
10
|
+
fileName: string;
|
|
11
|
+
resultRowCount: number;
|
|
12
|
+
sourceRowCount: number;
|
|
13
|
+
startDate: string;
|
|
14
|
+
transactionCount: number;
|
|
15
|
+
}
|
|
@@ -14,4 +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("./create-ad-performance-report-excel.dto"), exports);
|
|
17
18
|
__exportStar(require("./create-sns-roas-report-excel.dto"), exports);
|
|
@@ -0,0 +1,38 @@
|
|
|
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.SnsRoasSourceRow = void 0;
|
|
13
|
+
const class_validator_1 = require("class-validator");
|
|
14
|
+
/**
|
|
15
|
+
* @author jun
|
|
16
|
+
* @description SNS ROAS 엑셀 생성에 사용할 광고 소재별 일자 광고비입니다.
|
|
17
|
+
* @process 광고 소재명, 일자, USD 광고비의 형식과 범위를 검증합니다.
|
|
18
|
+
*/
|
|
19
|
+
class SnsRoasSourceRow {
|
|
20
|
+
}
|
|
21
|
+
exports.SnsRoasSourceRow = SnsRoasSourceRow;
|
|
22
|
+
__decorate([
|
|
23
|
+
(0, class_validator_1.IsString)(),
|
|
24
|
+
(0, class_validator_1.IsNotEmpty)(),
|
|
25
|
+
__metadata("design:type", String)
|
|
26
|
+
], SnsRoasSourceRow.prototype, "adName", void 0);
|
|
27
|
+
__decorate([
|
|
28
|
+
(0, class_validator_1.IsDateString)({ strict: true }),
|
|
29
|
+
__metadata("design:type", String)
|
|
30
|
+
], SnsRoasSourceRow.prototype, "date", void 0);
|
|
31
|
+
__decorate([
|
|
32
|
+
(0, class_validator_1.IsNumber)({
|
|
33
|
+
allowInfinity: false,
|
|
34
|
+
allowNaN: false,
|
|
35
|
+
}),
|
|
36
|
+
(0, class_validator_1.Min)(0),
|
|
37
|
+
__metadata("design:type", Number)
|
|
38
|
+
], SnsRoasSourceRow.prototype, "spendUsd", void 0);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ClientProxy } from '@nestjs/microservices';
|
|
2
2
|
import { AbstractParam } from '@yolo-croket-dev/core';
|
|
3
|
-
import { CreateSnsRoasReportExcelPayload, CreateSnsRoasReportExcelResult } from '../dto';
|
|
3
|
+
import { CreateAdPerformanceReportExcelPayload, CreateAdPerformanceReportExcelResult, CreateSnsRoasReportExcelPayload, CreateSnsRoasReportExcelResult } from '../dto';
|
|
4
4
|
/**
|
|
5
5
|
* @author jun
|
|
6
6
|
* @description Excel Upload Server의 광고 성과 리포트 생성 기능을 호출합니다.
|
|
@@ -10,5 +10,6 @@ export declare class AmqpAdPerformanceReportService {
|
|
|
10
10
|
private readonly client;
|
|
11
11
|
private readonly amqpManager;
|
|
12
12
|
constructor(client: ClientProxy);
|
|
13
|
+
createAdPerformanceReportExcel(payload: CreateAdPerformanceReportExcelPayload, param: AbstractParam): Promise<CreateAdPerformanceReportExcelResult>;
|
|
13
14
|
createSnsRoasReportExcel(payload: CreateSnsRoasReportExcelPayload, param: AbstractParam): Promise<CreateSnsRoasReportExcelResult>;
|
|
14
15
|
}
|
|
@@ -26,6 +26,9 @@ let AmqpAdPerformanceReportService = class AmqpAdPerformanceReportService {
|
|
|
26
26
|
this.client = client;
|
|
27
27
|
this.amqpManager = new functions_1.AmqpManagement(this.client);
|
|
28
28
|
}
|
|
29
|
+
async createAdPerformanceReportExcel(payload, param) {
|
|
30
|
+
return this.amqpManager.call('채널별 광고 성과 통합 엑셀 생성', 'ad-performance-report.create-excel', payload, param, { isErrorThrowing: true });
|
|
31
|
+
}
|
|
29
32
|
async createSnsRoasReportExcel(payload, param) {
|
|
30
33
|
return this.amqpManager.call('SNS ROAS 광고 성과 엑셀 생성', 'ad-performance-report.create-sns-roas-excel', payload, param, { isErrorThrowing: true });
|
|
31
34
|
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/** @description 관리자용 일괄 송장 등록/수정 개별 처리 결과 */
|
|
2
|
+
export interface UpsertInvoiceBulkForAdminResultItem {
|
|
3
|
+
pInfoId: string;
|
|
4
|
+
failType?: string;
|
|
5
|
+
reason?: string;
|
|
6
|
+
}
|
|
7
|
+
/**
|
|
8
|
+
* @author jun
|
|
9
|
+
* @description 관리자용 일괄 송장 등록/수정 payload
|
|
10
|
+
*/
|
|
11
|
+
export declare class UpsertInvoiceBulkForAdminPayload {
|
|
12
|
+
/** 송장을 등록하거나 수정할 결제정보 ID 목록 */
|
|
13
|
+
pInfoIds: string[];
|
|
14
|
+
/** 택배사명 */
|
|
15
|
+
SCompany: string;
|
|
16
|
+
/** 송장번호 */
|
|
17
|
+
invoice: string;
|
|
18
|
+
/** 배송 조회 URL */
|
|
19
|
+
invoiceUrl?: string;
|
|
20
|
+
/** 택배사 직접 입력 여부 */
|
|
21
|
+
isDirectInput: boolean;
|
|
22
|
+
/** 구매자 알림 발송 여부 */
|
|
23
|
+
isNoti: boolean;
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* @author jun
|
|
27
|
+
* @description 관리자용 일괄 송장 등록/수정 결과
|
|
28
|
+
*/
|
|
29
|
+
export declare class UpsertInvoiceBulkForAdminResult {
|
|
30
|
+
allCount: number;
|
|
31
|
+
successCount: number;
|
|
32
|
+
failCount: number;
|
|
33
|
+
results: UpsertInvoiceBulkForAdminResultItem[];
|
|
34
|
+
}
|
|
@@ -0,0 +1,56 @@
|
|
|
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.UpsertInvoiceBulkForAdminResult = exports.UpsertInvoiceBulkForAdminPayload = void 0;
|
|
13
|
+
const class_validator_1 = require("class-validator");
|
|
14
|
+
/**
|
|
15
|
+
* @author jun
|
|
16
|
+
* @description 관리자용 일괄 송장 등록/수정 payload
|
|
17
|
+
*/
|
|
18
|
+
class UpsertInvoiceBulkForAdminPayload {
|
|
19
|
+
}
|
|
20
|
+
exports.UpsertInvoiceBulkForAdminPayload = UpsertInvoiceBulkForAdminPayload;
|
|
21
|
+
__decorate([
|
|
22
|
+
(0, class_validator_1.IsArray)(),
|
|
23
|
+
(0, class_validator_1.ArrayMinSize)(1),
|
|
24
|
+
(0, class_validator_1.ArrayMaxSize)(50),
|
|
25
|
+
(0, class_validator_1.ArrayUnique)(),
|
|
26
|
+
(0, class_validator_1.IsMongoId)({ each: true }),
|
|
27
|
+
__metadata("design:type", Array)
|
|
28
|
+
], UpsertInvoiceBulkForAdminPayload.prototype, "pInfoIds", void 0);
|
|
29
|
+
__decorate([
|
|
30
|
+
(0, class_validator_1.IsString)(),
|
|
31
|
+
__metadata("design:type", String)
|
|
32
|
+
], UpsertInvoiceBulkForAdminPayload.prototype, "SCompany", void 0);
|
|
33
|
+
__decorate([
|
|
34
|
+
(0, class_validator_1.IsString)(),
|
|
35
|
+
__metadata("design:type", String)
|
|
36
|
+
], UpsertInvoiceBulkForAdminPayload.prototype, "invoice", void 0);
|
|
37
|
+
__decorate([
|
|
38
|
+
(0, class_validator_1.IsOptional)(),
|
|
39
|
+
(0, class_validator_1.IsString)(),
|
|
40
|
+
__metadata("design:type", String)
|
|
41
|
+
], UpsertInvoiceBulkForAdminPayload.prototype, "invoiceUrl", void 0);
|
|
42
|
+
__decorate([
|
|
43
|
+
(0, class_validator_1.IsBoolean)(),
|
|
44
|
+
__metadata("design:type", Boolean)
|
|
45
|
+
], UpsertInvoiceBulkForAdminPayload.prototype, "isDirectInput", void 0);
|
|
46
|
+
__decorate([
|
|
47
|
+
(0, class_validator_1.IsBoolean)(),
|
|
48
|
+
__metadata("design:type", Boolean)
|
|
49
|
+
], UpsertInvoiceBulkForAdminPayload.prototype, "isNoti", void 0);
|
|
50
|
+
/**
|
|
51
|
+
* @author jun
|
|
52
|
+
* @description 관리자용 일괄 송장 등록/수정 결과
|
|
53
|
+
*/
|
|
54
|
+
class UpsertInvoiceBulkForAdminResult {
|
|
55
|
+
}
|
|
56
|
+
exports.UpsertInvoiceBulkForAdminResult = UpsertInvoiceBulkForAdminResult;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@yolo-croket-dev/amqp-access",
|
|
3
|
-
"version": "0.7.
|
|
3
|
+
"version": "0.7.234",
|
|
4
4
|
"main": "index.js",
|
|
5
5
|
"author": "Yolo Co., Ltd.",
|
|
6
6
|
"description": "크로켓 amqp-access npm",
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
"@yolo-croket-dev/domain": "0.2.40",
|
|
24
24
|
"@yolo-croket-dev/dto-v2": "0.2.22",
|
|
25
25
|
"@yolo-croket-dev/entity": "0.2.94",
|
|
26
|
-
"@yolo-croket-dev/entity-v2": "0.3.7
|
|
26
|
+
"@yolo-croket-dev/entity-v2": "0.3.7",
|
|
27
27
|
"class-transformer": "^0.5.1",
|
|
28
28
|
"class-validator": "^0.13.2",
|
|
29
29
|
"dotenv": "^16.3.1"
|