.
This commit is contained in:
1 parent
6609098037
commit
b38cc03a71
2 files changed
+3
-6
No files matched your search
@@ -610,7 +610,7 @@ export class LegacyImportService {
|
|||||||
const overrideStart = this.parseOptionalDate(override?.startTime);
|
const overrideStart = this.parseOptionalDate(override?.startTime);
|
||||||
const overrideEnd = this.parseOptionalDate(override?.endTime);
|
const overrideEnd = this.parseOptionalDate(override?.endTime);
|
||||||
const activeEnd = user.isActivated ? windowEnd : user.updatedAt;
|
const activeEnd = user.isActivated ? windowEnd : user.updatedAt;
|
||||||
const startTime = this.maxDate(windowStart, user.createdAt, overrideStart);
|
const startTime = overrideStart ?? windowStart;
|
||||||
const endTime = this.minDate(windowEnd, activeEnd, overrideEnd);
|
const endTime = this.minDate(windowEnd, activeEnd, overrideEnd);
|
||||||
return {
|
return {
|
||||||
userId: user._id,
|
userId: user._id,
|
||||||
@@ -643,10 +643,6 @@ export class LegacyImportService {
|
|||||||
return parsed;
|
return parsed;
|
||||||
}
|
}
|
||||||
|
|
||||||
private maxDate(...values: Array<Date | undefined>): Date {
|
|
||||||
return new Date(Math.max(...values.filter(Boolean).map((date) => date!.getTime())));
|
|
||||||
}
|
|
||||||
|
|
||||||
private minDate(...values: Array<Date | undefined>): Date {
|
private minDate(...values: Array<Date | undefined>): Date {
|
||||||
return new Date(Math.min(...values.filter(Boolean).map((date) => date!.getTime())));
|
return new Date(Math.min(...values.filter(Boolean).map((date) => date!.getTime())));
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -307,7 +307,8 @@ export default function LegacyImportPage() {
|
|||||||
<div className="px-4 py-3 border-b border-base-content/10">
|
<div className="px-4 py-3 border-b border-base-content/10">
|
||||||
<h2 className="text-sm font-bold">멤버별 윈도우</h2>
|
<h2 className="text-sm font-bold">멤버별 윈도우</h2>
|
||||||
<p className="mt-1 text-[11px] text-base-content/35">
|
<p className="mt-1 text-[11px] text-base-content/35">
|
||||||
기본 시작일은 max(2024-05-01, 가입일), 비활성 멤버는 종료일이 마지막 업데이트 시각으로 잡힙니다.
|
기본 시작일은 2024-05-01이며, 필요하면 멤버별 시작/종료 시간을 조정할 수 있습니다.
|
||||||
|
비활성 멤버는 종료일이 마지막 업데이트 시각으로 잡힙니다.
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
<div className="overflow-x-auto">
|
<div className="overflow-x-auto">
|
||||||
|
|||||||
Reference in new issue
Block a user