@yolo-croket-dev/amqp-access 0.7.309-sj2 → 0.7.310

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yolo-croket-dev/amqp-access",
3
- "version": "0.7.309-sj2",
3
+ "version": "0.7.310",
4
4
  "main": "index.js",
5
5
  "author": "Yolo Co., Ltd.",
6
6
  "description": "크로켓 amqp-access npm",
@@ -22,8 +22,8 @@
22
22
  "@yolo-croket-dev/core": "^1.9.3",
23
23
  "@yolo-croket-dev/domain": "0.2.47",
24
24
  "@yolo-croket-dev/dto-v2": "0.2.23",
25
- "@yolo-croket-dev/entity": "0.2.106-sj",
26
- "@yolo-croket-dev/entity-v2": "0.3.39",
25
+ "@yolo-croket-dev/entity": "0.2.106",
26
+ "@yolo-croket-dev/entity-v2": "0.3.40",
27
27
  "class-transformer": "^0.5.1",
28
28
  "class-validator": "^0.13.2",
29
29
  "dotenv": "^16.3.1"
@@ -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/interfaces").Type<Pick<AdCenterSettle, "_id" | "sellerId" | "publicId" | "couponInfo" | "pastStoreInfo" | "expectedSettleDateString" | "adType" | "adCenterStartDateString" | "adCenterEndDateString" | "actualSettleDateString" | "PInfoId" | "transactionInfo" | "subtractionSettleAmountInfo" | "bizMemo" | "financeMemo" | "settlementManagerInfo" | "googleSheetInfo">>;
3
+ declare const AdCenterSettleForGoogleSheet_base: import("@nestjs/common").Type<Pick<AdCenterSettle, "_id" | "sellerId" | "publicId" | "couponInfo" | "pastStoreInfo" | "expectedSettleDateString" | "adType" | "adCenterStartDateString" | "adCenterEndDateString" | "actualSettleDateString" | "PInfoId" | "transactionInfo" | "subtractionSettleAmountInfo" | "bizMemo" | "financeMemo" | "settlementManagerInfo" | "googleSheetInfo">>;
4
4
  /** 구글 시트용 광고센터정산 데이터 */
5
5
  export declare class AdCenterSettleForGoogleSheet extends AdCenterSettleForGoogleSheet_base {
6
6
  storeInfo: {
@@ -28,3 +28,4 @@ export * from './stop-selling-bulk.dto';
28
28
  export * from './used-selling-bulk.dto';
29
29
  export * from './refresh-shipping-lead-time-stats.dto';
30
30
  export * from './create-additional-payment-store-item.dto';
31
+ export * from './instant-selection-sync.dto';
@@ -44,3 +44,4 @@ __exportStar(require("./stop-selling-bulk.dto"), exports);
44
44
  __exportStar(require("./used-selling-bulk.dto"), exports);
45
45
  __exportStar(require("./refresh-shipping-lead-time-stats.dto"), exports);
46
46
  __exportStar(require("./create-additional-payment-store-item.dto"), exports);
47
+ __exportStar(require("./instant-selection-sync.dto"), exports);
@@ -0,0 +1,45 @@
1
+ import { StoreItemInstantSelectionSyncReasonEnum, StoreItemInstantSelectionSyncStateEnum } from '@yolo-croket-dev/entity-v2/store-item';
2
+ export declare enum InstantSelectionSyncRunOutcomeEnum {
3
+ SUCCESS = "SUCCESS",
4
+ FAILED = "FAILED",
5
+ SKIPPED = "SKIPPED",
6
+ ALREADY_PROCESSED = "ALREADY_PROCESSED",
7
+ NOT_ELIGIBLE = "NOT_ELIGIBLE",
8
+ NOT_FOUND = "NOT_FOUND",
9
+ CLAIM_LOST = "CLAIM_LOST",
10
+ DISABLED = "DISABLED"
11
+ }
12
+ export declare class RunInstantSelectionSyncPayload {
13
+ storeItemId: string;
14
+ }
15
+ export declare class RunInstantSelectionSyncResult {
16
+ storeItemId: string;
17
+ outcome: InstantSelectionSyncRunOutcomeEnum;
18
+ state?: StoreItemInstantSelectionSyncStateEnum;
19
+ selectionFrameId?: string;
20
+ reason?: StoreItemInstantSelectionSyncReasonEnum;
21
+ }
22
+ export declare class BackfillInstantSelectionSyncPayload {
23
+ limit: 20 | 50 | 100;
24
+ searchAfter?: string;
25
+ }
26
+ export declare class BackfillInstantSelectionSyncResult {
27
+ disabled: boolean;
28
+ scannedCount: number;
29
+ successCount: number;
30
+ failedCount: number;
31
+ skippedCount: number;
32
+ ignoredCount: number;
33
+ failedStoreItemIds: string[];
34
+ skippedStoreItemIds: string[];
35
+ nextSearchAfter: string | null;
36
+ }
37
+ export declare class ResetInstantSelectionSyncPayload {
38
+ storeItemIds: string[];
39
+ }
40
+ export declare class ResetInstantSelectionSyncResult {
41
+ disabled: boolean;
42
+ requestedCount: number;
43
+ resetCount: number;
44
+ unchangedCount: number;
45
+ }
@@ -0,0 +1,74 @@
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.ResetInstantSelectionSyncResult = exports.ResetInstantSelectionSyncPayload = exports.BackfillInstantSelectionSyncResult = exports.BackfillInstantSelectionSyncPayload = exports.RunInstantSelectionSyncResult = exports.RunInstantSelectionSyncPayload = exports.InstantSelectionSyncRunOutcomeEnum = void 0;
13
+ const class_validator_1 = require("class-validator");
14
+ const class_transformer_1 = require("class-transformer");
15
+ var InstantSelectionSyncRunOutcomeEnum;
16
+ (function (InstantSelectionSyncRunOutcomeEnum) {
17
+ InstantSelectionSyncRunOutcomeEnum["SUCCESS"] = "SUCCESS";
18
+ InstantSelectionSyncRunOutcomeEnum["FAILED"] = "FAILED";
19
+ InstantSelectionSyncRunOutcomeEnum["SKIPPED"] = "SKIPPED";
20
+ InstantSelectionSyncRunOutcomeEnum["ALREADY_PROCESSED"] = "ALREADY_PROCESSED";
21
+ InstantSelectionSyncRunOutcomeEnum["NOT_ELIGIBLE"] = "NOT_ELIGIBLE";
22
+ InstantSelectionSyncRunOutcomeEnum["NOT_FOUND"] = "NOT_FOUND";
23
+ InstantSelectionSyncRunOutcomeEnum["CLAIM_LOST"] = "CLAIM_LOST";
24
+ InstantSelectionSyncRunOutcomeEnum["DISABLED"] = "DISABLED";
25
+ })(InstantSelectionSyncRunOutcomeEnum || (exports.InstantSelectionSyncRunOutcomeEnum = InstantSelectionSyncRunOutcomeEnum = {}));
26
+ class RunInstantSelectionSyncPayload {
27
+ }
28
+ exports.RunInstantSelectionSyncPayload = RunInstantSelectionSyncPayload;
29
+ __decorate([
30
+ (0, class_validator_1.IsMongoId)(),
31
+ __metadata("design:type", String)
32
+ ], RunInstantSelectionSyncPayload.prototype, "storeItemId", void 0);
33
+ class RunInstantSelectionSyncResult {
34
+ }
35
+ exports.RunInstantSelectionSyncResult = RunInstantSelectionSyncResult;
36
+ class BackfillInstantSelectionSyncPayload {
37
+ constructor() {
38
+ this.limit = 20;
39
+ }
40
+ }
41
+ exports.BackfillInstantSelectionSyncPayload = BackfillInstantSelectionSyncPayload;
42
+ __decorate([
43
+ (0, class_validator_1.IsOptional)(),
44
+ (0, class_transformer_1.Type)(() => Number),
45
+ (0, class_validator_1.IsInt)(),
46
+ (0, class_validator_1.IsIn)([
47
+ 20,
48
+ 50,
49
+ 100,
50
+ ]),
51
+ __metadata("design:type", Number)
52
+ ], BackfillInstantSelectionSyncPayload.prototype, "limit", void 0);
53
+ __decorate([
54
+ (0, class_validator_1.IsOptional)(),
55
+ (0, class_validator_1.IsString)(),
56
+ __metadata("design:type", String)
57
+ ], BackfillInstantSelectionSyncPayload.prototype, "searchAfter", void 0);
58
+ class BackfillInstantSelectionSyncResult {
59
+ }
60
+ exports.BackfillInstantSelectionSyncResult = BackfillInstantSelectionSyncResult;
61
+ class ResetInstantSelectionSyncPayload {
62
+ }
63
+ exports.ResetInstantSelectionSyncPayload = ResetInstantSelectionSyncPayload;
64
+ __decorate([
65
+ (0, class_validator_1.IsArray)(),
66
+ (0, class_validator_1.ArrayMinSize)(1),
67
+ (0, class_validator_1.ArrayMaxSize)(100),
68
+ (0, class_validator_1.ArrayUnique)(),
69
+ (0, class_validator_1.IsMongoId)({ each: true }),
70
+ __metadata("design:type", Array)
71
+ ], ResetInstantSelectionSyncPayload.prototype, "storeItemIds", void 0);
72
+ class ResetInstantSelectionSyncResult {
73
+ }
74
+ exports.ResetInstantSelectionSyncResult = ResetInstantSelectionSyncResult;
@@ -1,10 +1,16 @@
1
1
  import { ClientProxy } from '@nestjs/microservices';
2
2
  import { AbstractParam } from '@yolo-croket-dev/core';
3
- import { GetStoreItemLegaciesPayload, GetStoreItemLegaciesResult, GetSellingItemIdsByStoreIdPayload, GetSellingItemIdsByStoreIdResult, SearchSellingStoreItemsPayload, SearchSellingStoreItemsResult, SearchNormalSellingStoreItemsForBulkStopPayload, SearchNormalSellingStoreItemsForBulkStopResult, GetStoreItemsForESPayload, GetStoreItemsForESResult, GetLegacyStoreItemsByAtlasSearchPayload, GetLegacyStoreItemsByAtlasSearchResult, GetStoreItemIdsByAtlasSearchPayload, GetStoreItemIdsByAtlasSearchResult, GetStoreItemInfoByIdPayload, GetStoreItemInfoByIdResult, GetSellingItemIdsByThemeIdPayload, GetSellingItemIdsByThemeIdResult, SearchStoreItemNameByIdPayload, SearchStoreItemNameByIdResult, GetItemGroupNumsPayload, GetItemGroupNumsResult, GetRandomItemIdsPayload, GetRandomItemIdsResult, GetUsedImgItemIdsPayload, GetUsedImgItemIdsResult, GetUsedImgsItemIdsPayload, GetUsedImgsItemIdsResult, GetSellingItemIdsByCatagoryPayload, GetSellingItemIdsByCatagoryResult, PatchSoldOutItemOptionsPayload, PatchSoldOutItemOptionsResult, RegStoreItemPayload, RegStoreItemResult, EditStoreItemPayload, EditItemResult, GetStoreItemsForUpdateBrandPayload, GetStoreItemsForUpdateBrandResult, RegStoreItemBulkPayload, RegStoreItemBulkResult, GetStoreItemInfoByIdsPayload, GetStoreItemInfoByIdsResult, SearchStoreItemsForSeduceAddCartPayload, SearchStoreItemsForSeduceAddCartResult, GetStoreItemBindIssuedCouponForPaymentPayload, GetStoreItemBindIssuedCouponForPaymentResult, GetStaleStoreItemsForExcelResult, GetStaleStoreItemsForExcelPayload, GetStoreItemTooltipForCartPayload, GetStoreItemTooltipForCartResult, GetStoreItemsByBrandNamePayload, GetStoreItemsByBrandNameResult, SearchStoreItemsForTestApiPayload, SearchStoreItemsForTestApiResult, UpdateBrandNameBulkPayload, UpdateBrandEngNameBulkPayload, DeleteBrandInfoBulkPayload, DalphaUpdateBrandNameBulkPayload, PatchStoreItemOptionRemainCountByChangePurchasedOptionPayload, PatchStoreItemOptionRemainCountByChangePurchasedOptionResult, UpdateIsSellingBulkPayload, GetAreaResult, GetCityPayload, GetCityResult, GetNationPayload, GetNationResult, GetStoreItemsForExtractionByTypeResult, ResizeItemImgPayload, GetStoreInfosByItemIdsPayload, GetStoreInfosByItemIdsResult, CopyStoreItemPayload, CopyStoreItemListPayload, GetCouponCodesBySellingItemPayload, GetCouponCodesBySellingItemResult, UpdateStoreItemSecretPayload, GetSellingStoreItemsForChatPayload, GetSellingStoreItemsForChatResult, GetStoreItemsByPreBlackFridayIdPayload, GetStoreItemsByPreBlackFridayIdResult, UpdateBrandInfosPayload, UpdateBrandInfosResult, SearchRegularPriceItemsForAdminResult, SearchRegularPriceItemsForAdminPayload, UpdateRegularPriceByAdminPayload, RegRegularPriceBulkByAdminPayload, DeleteRegularPriceByAdminPayload, SearchSecretItemsForAdminPayload, SearchSecretItemsForAdminResult, RegItemNameEngBulkByAdminPayload, UpdateStoreItemGlobalInfoBulkPayload, UpdateNaverEnabledBulkPayload, UpdateIsRequiredPCCCBulkPayload, UpdateIsRequiredPCCCBulkResult, UpdateStoreItemSellerMemoPayload, UpdateStoreItemSellerMemoResult, GetStoreItemSellerMemoPayload, GetStoreItemSellerMemoResult, ResumeSellingSelectedBulkPayload, ResumeSellingAllBulkPayload, ResumeSellingBulkResult, StopSellingSelectedBulkPayload, StopSellingAllBulkPayload, StopSellingBulkResult, UsedSellingSelectedBulkPayload, UsedSellingAllBulkPayload, UsedSellingBulkResult, GetCroCareStoreItemInfoPayload, GetCroCareStoreItemInfoResult, GetStoreItemsForProductFeedPayload, GetStoreItemsForProductFeedResult, GetMetaProductFeedSyncStatusByItemIdsPayload, GetMetaProductFeedSyncStatusByItemIdsResult, UpdateItemKeywordsBulkPayload, UpdateItemKeywordsBulkResult, SearchStoreItemsForEnuriSummaryEpPayload, SearchStoreItemsForEnuriSummaryEpResult, RefreshShippingLeadTimeStatsPayload, GetAbroadShippingStoreItemExistsResult, CreateAdditionalPaymentStoreItemPayload, CreateAdditionalPaymentStoreItemResult, GetUsedStoreItemsByBrandCategoryPayload, GetUsedStoreItemsByBrandCategoryResult } from '../dto/store-item';
3
+ import { GetStoreItemLegaciesPayload, GetStoreItemLegaciesResult, GetSellingItemIdsByStoreIdPayload, GetSellingItemIdsByStoreIdResult, SearchSellingStoreItemsPayload, SearchSellingStoreItemsResult, SearchNormalSellingStoreItemsForBulkStopPayload, SearchNormalSellingStoreItemsForBulkStopResult, GetStoreItemsForESPayload, GetStoreItemsForESResult, GetLegacyStoreItemsByAtlasSearchPayload, GetLegacyStoreItemsByAtlasSearchResult, GetStoreItemIdsByAtlasSearchPayload, GetStoreItemIdsByAtlasSearchResult, GetStoreItemInfoByIdPayload, GetStoreItemInfoByIdResult, GetSellingItemIdsByThemeIdPayload, GetSellingItemIdsByThemeIdResult, SearchStoreItemNameByIdPayload, SearchStoreItemNameByIdResult, GetItemGroupNumsPayload, GetItemGroupNumsResult, GetRandomItemIdsPayload, GetRandomItemIdsResult, GetUsedImgItemIdsPayload, GetUsedImgItemIdsResult, GetUsedImgsItemIdsPayload, GetUsedImgsItemIdsResult, GetSellingItemIdsByCatagoryPayload, GetSellingItemIdsByCatagoryResult, PatchSoldOutItemOptionsPayload, PatchSoldOutItemOptionsResult, RegStoreItemPayload, RegStoreItemResult, EditStoreItemPayload, EditItemResult, GetStoreItemsForUpdateBrandPayload, GetStoreItemsForUpdateBrandResult, RegStoreItemBulkPayload, RegStoreItemBulkResult, GetStoreItemInfoByIdsPayload, GetStoreItemInfoByIdsResult, SearchStoreItemsForSeduceAddCartPayload, SearchStoreItemsForSeduceAddCartResult, GetStoreItemBindIssuedCouponForPaymentPayload, GetStoreItemBindIssuedCouponForPaymentResult, GetStaleStoreItemsForExcelResult, GetStaleStoreItemsForExcelPayload, GetStoreItemTooltipForCartPayload, GetStoreItemTooltipForCartResult, GetStoreItemsByBrandNamePayload, GetStoreItemsByBrandNameResult, SearchStoreItemsForTestApiPayload, SearchStoreItemsForTestApiResult, UpdateBrandNameBulkPayload, UpdateBrandEngNameBulkPayload, DeleteBrandInfoBulkPayload, DalphaUpdateBrandNameBulkPayload, PatchStoreItemOptionRemainCountByChangePurchasedOptionPayload, PatchStoreItemOptionRemainCountByChangePurchasedOptionResult, UpdateIsSellingBulkPayload, GetAreaResult, GetCityPayload, GetCityResult, GetNationPayload, GetNationResult, GetStoreItemsForExtractionByTypeResult, ResizeItemImgPayload, GetStoreInfosByItemIdsPayload, GetStoreInfosByItemIdsResult, CopyStoreItemPayload, CopyStoreItemListPayload, GetCouponCodesBySellingItemPayload, GetCouponCodesBySellingItemResult, UpdateStoreItemSecretPayload, GetSellingStoreItemsForChatPayload, GetSellingStoreItemsForChatResult, GetStoreItemsByPreBlackFridayIdPayload, GetStoreItemsByPreBlackFridayIdResult, UpdateBrandInfosPayload, UpdateBrandInfosResult, SearchRegularPriceItemsForAdminResult, SearchRegularPriceItemsForAdminPayload, UpdateRegularPriceByAdminPayload, RegRegularPriceBulkByAdminPayload, DeleteRegularPriceByAdminPayload, SearchSecretItemsForAdminPayload, SearchSecretItemsForAdminResult, RegItemNameEngBulkByAdminPayload, UpdateStoreItemGlobalInfoBulkPayload, UpdateNaverEnabledBulkPayload, UpdateIsRequiredPCCCBulkPayload, UpdateIsRequiredPCCCBulkResult, UpdateStoreItemSellerMemoPayload, UpdateStoreItemSellerMemoResult, GetStoreItemSellerMemoPayload, GetStoreItemSellerMemoResult, ResumeSellingSelectedBulkPayload, ResumeSellingAllBulkPayload, ResumeSellingBulkResult, StopSellingSelectedBulkPayload, StopSellingAllBulkPayload, StopSellingBulkResult, UsedSellingSelectedBulkPayload, UsedSellingAllBulkPayload, UsedSellingBulkResult, GetCroCareStoreItemInfoPayload, GetCroCareStoreItemInfoResult, GetStoreItemsForProductFeedPayload, GetStoreItemsForProductFeedResult, GetMetaProductFeedSyncStatusByItemIdsPayload, GetMetaProductFeedSyncStatusByItemIdsResult, UpdateItemKeywordsBulkPayload, UpdateItemKeywordsBulkResult, SearchStoreItemsForEnuriSummaryEpPayload, SearchStoreItemsForEnuriSummaryEpResult, RefreshShippingLeadTimeStatsPayload, GetAbroadShippingStoreItemExistsResult, CreateAdditionalPaymentStoreItemPayload, CreateAdditionalPaymentStoreItemResult, GetUsedStoreItemsByBrandCategoryPayload, GetUsedStoreItemsByBrandCategoryResult, RunInstantSelectionSyncPayload, RunInstantSelectionSyncResult, BackfillInstantSelectionSyncPayload, BackfillInstantSelectionSyncResult, ResetInstantSelectionSyncPayload, ResetInstantSelectionSyncResult } from '../dto/store-item';
4
4
  export declare class AmqpStoreItemService {
5
5
  private readonly client;
6
6
  private readonly amqpManager;
7
7
  constructor(client: ClientProxy);
8
+ /** ZOZO USED 상품 한 건의 즉시 셀렉션 연결을 실행한다. */
9
+ runInstantSelectionSync(payload: RunInstantSelectionSyncPayload, param: AbstractParam): Promise<RunInstantSelectionSyncResult>;
10
+ /** 즉시 셀렉션 연결 대상을 조회해 제한된 건수만 처리한다. */
11
+ backfillInstantSelectionSync(payload: BackfillInstantSelectionSyncPayload, param: AbstractParam): Promise<BackfillInstantSelectionSyncResult>;
12
+ /** 실패·스킵·장기 처리 중인 즉시 셀렉션 상태를 대기 상태로 되돌린다. */
13
+ resetInstantSelectionSync(payload: ResetInstantSelectionSyncPayload, param: AbstractParam): Promise<ResetInstantSelectionSyncResult>;
8
14
  /**
9
15
  * @author jun
10
16
  * @description 브랜드와 카테고리가 정확히 일치하는 구매 가능한 중고상품을 조회한다.
@@ -21,6 +21,18 @@ let AmqpStoreItemService = class AmqpStoreItemService {
21
21
  this.client = client;
22
22
  this.amqpManager = new functions_1.AmqpManagement(this.client);
23
23
  }
24
+ /** ZOZO USED 상품 한 건의 즉시 셀렉션 연결을 실행한다. */
25
+ async runInstantSelectionSync(payload, param) {
26
+ return this.amqpManager.call('즉시 셀렉션 연결 실행', 'store-item.instant-selection-sync.run', payload, param, { isErrorThrowing: true });
27
+ }
28
+ /** 즉시 셀렉션 연결 대상을 조회해 제한된 건수만 처리한다. */
29
+ async backfillInstantSelectionSync(payload, param) {
30
+ return this.amqpManager.call('즉시 셀렉션 연결 backfill', 'store-item.instant-selection-sync.backfill', payload, param, { isErrorThrowing: true });
31
+ }
32
+ /** 실패·스킵·장기 처리 중인 즉시 셀렉션 상태를 대기 상태로 되돌린다. */
33
+ async resetInstantSelectionSync(payload, param) {
34
+ return this.amqpManager.call('즉시 셀렉션 연결 상태 초기화', 'store-item.instant-selection-sync.reset', payload, param, { isErrorThrowing: true });
35
+ }
24
36
  /**
25
37
  * @author jun
26
38
  * @description 브랜드와 카테고리가 정확히 일치하는 구매 가능한 중고상품을 조회한다.