[feat] solution/frontend: 사이트관리 방문 통계 — 방문/크롤링 하위 탭, 실시간 30초 갱신
- 전체 통계 탭과 사이트별 통계 페이지에 "방문 / 크롤링" 하위 탭(KindTabs). 사람 방문과 봇 크롤링은 세는 방법이 달라 한 화면에 섞지 않는다. 기본은 방문 - 방문 패널: 실시간 방문자(최근 5분) · 페이지뷰 · 방문자 · 마지막 방문 → 일별 방문자·페이지뷰 차트 → (전체) 방문이 많은 사이트 / (사이트별) 많이 본 페이지·캠페인(utm) → 유입 도메인 · 기기 - 실시간 숫자는 화면을 열어 둔 채 보는 값이라 30초마다 다시 부른다. 보이는 탭의 쿼리만 켠다 - VisitDailyChart 는 lazy() — recharts 는 차트 청크에만 있고 사장님 화면 첫 로딩 스크립트에는 없다 - CrawlerStatsPanel 의 Stat·Section·Table 을 export 해 방문 패널이 같이 쓴다 - orval 재생성(useVisitStats·useSiteVisitStats) — 줄바꿈만 바뀐 생성 파일은 되돌리고 실제 변경분만 담았다 lint(typegen·tsc·eslint)·build 통과. 통계 API 는 임시 개발자 계정으로 nginx·5173 경유 호출 확인.
This commit is contained in:
1 parent
5c5b07d375
commit
d15c8185b6
24 files changed
+735
-16
No files matched your search
@@ -401,6 +401,10 @@ export * from "./resVerifyCandidates";
|
||||
export * from "./resVerifyCandidatesMsg";
|
||||
export * from "./resVerifyCandidatesReason";
|
||||
export * from "./resVerifyCandidatesSource";
|
||||
export * from "./resVisitStats";
|
||||
export * from "./resVisitStatsDateFrom";
|
||||
export * from "./resVisitStatsDateTo";
|
||||
export * from "./resVisitStatsMsg";
|
||||
export * from "./resWeather";
|
||||
export * from "./resWeatherMsg";
|
||||
export * from "./resWeatherWeather";
|
||||
@@ -424,6 +428,7 @@ export * from "./siteVersionData";
|
||||
export * from "./siteVersionDataBuildError";
|
||||
export * from "./siteVersionDataBuiltAt";
|
||||
export * from "./siteVersionDataCreatedAt";
|
||||
export * from "./siteVisitStatsParams";
|
||||
export * from "./sourceType";
|
||||
export * from "./testPost";
|
||||
export * from "./unitData";
|
||||
@@ -433,6 +438,15 @@ export * from "./validationError";
|
||||
export * from "./validationErrorCtx";
|
||||
export * from "./validationErrorLocItem";
|
||||
export * from "./verifyCandidatesParams";
|
||||
export * from "./visitDaily";
|
||||
export * from "./visitDeviceRow";
|
||||
export * from "./visitPathRow";
|
||||
export * from "./visitReferrerRow";
|
||||
export * from "./visitSiteRow";
|
||||
export * from "./visitStatsParams";
|
||||
export * from "./visitSummary";
|
||||
export * from "./visitSummaryLastAt";
|
||||
export * from "./visitUtmRow";
|
||||
export * from "./weatherData";
|
||||
export * from "./weatherDataTimezone";
|
||||
export * from "./weatherDataWindSpeed";
|
||||
@@ -0,0 +1,35 @@
|
||||
/**
|
||||
* Generated by orval v7.21.0 🍺
|
||||
* Do not edit manually.
|
||||
* Web4Ai API
|
||||
* OpenAPI spec version: 0.1.0
|
||||
*/
|
||||
import type { ErrorInfo } from "./errorInfo";
|
||||
import type { ResVisitStatsMsg } from "./resVisitStatsMsg";
|
||||
import type { ResVisitStatsDateFrom } from "./resVisitStatsDateFrom";
|
||||
import type { ResVisitStatsDateTo } from "./resVisitStatsDateTo";
|
||||
import type { VisitSummary } from "./visitSummary";
|
||||
import type { VisitDaily } from "./visitDaily";
|
||||
import type { VisitSiteRow } from "./visitSiteRow";
|
||||
import type { VisitPathRow } from "./visitPathRow";
|
||||
import type { VisitReferrerRow } from "./visitReferrerRow";
|
||||
import type { VisitUtmRow } from "./visitUtmRow";
|
||||
import type { VisitDeviceRow } from "./visitDeviceRow";
|
||||
|
||||
/**
|
||||
* 전체(sites)와 사이트별(pages·utm)이 같은 모델을 쓴다 — 해당 없는 칸은 비어 있다.
|
||||
*/
|
||||
export interface ResVisitStats {
|
||||
result?: ErrorInfo;
|
||||
msg?: ResVisitStatsMsg;
|
||||
date_from?: ResVisitStatsDateFrom;
|
||||
date_to?: ResVisitStatsDateTo;
|
||||
realtime?: number;
|
||||
summary?: VisitSummary;
|
||||
daily?: VisitDaily[];
|
||||
sites?: VisitSiteRow[];
|
||||
pages?: VisitPathRow[];
|
||||
referrers?: VisitReferrerRow[];
|
||||
utm?: VisitUtmRow[];
|
||||
devices?: VisitDeviceRow[];
|
||||
}
|
||||
@@ -0,0 +1,8 @@
|
||||
/**
|
||||
* Generated by orval v7.21.0 🍺
|
||||
* Do not edit manually.
|
||||
* Web4Ai API
|
||||
* OpenAPI spec version: 0.1.0
|
||||
*/
|
||||
|
||||
export type ResVisitStatsDateFrom = string | null;
|
||||
@@ -0,0 +1,8 @@
|
||||
/**
|
||||
* Generated by orval v7.21.0 🍺
|
||||
* Do not edit manually.
|
||||
* Web4Ai API
|
||||
* OpenAPI spec version: 0.1.0
|
||||
*/
|
||||
|
||||
export type ResVisitStatsDateTo = string | null;
|
||||
@@ -0,0 +1,8 @@
|
||||
/**
|
||||
* Generated by orval v7.21.0 🍺
|
||||
* Do not edit manually.
|
||||
* Web4Ai API
|
||||
* OpenAPI spec version: 0.1.0
|
||||
*/
|
||||
|
||||
export type ResVisitStatsMsg = string | null;
|
||||
@@ -0,0 +1,17 @@
|
||||
/**
|
||||
* Generated by orval v7.21.0 🍺
|
||||
* Do not edit manually.
|
||||
* Web4Ai API
|
||||
* OpenAPI spec version: 0.1.0
|
||||
*/
|
||||
|
||||
export type SiteVisitStatsParams = {
|
||||
/**
|
||||
* KST 날짜, 기본 to-6일
|
||||
*/
|
||||
from?: string | null;
|
||||
/**
|
||||
* KST 날짜, 기본 오늘
|
||||
*/
|
||||
to?: string | null;
|
||||
};
|
||||
@@ -0,0 +1,12 @@
|
||||
/**
|
||||
* Generated by orval v7.21.0 🍺
|
||||
* Do not edit manually.
|
||||
* Web4Ai API
|
||||
* OpenAPI spec version: 0.1.0
|
||||
*/
|
||||
|
||||
export interface VisitDaily {
|
||||
day: string;
|
||||
views: number;
|
||||
visitors: number;
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
/**
|
||||
* Generated by orval v7.21.0 🍺
|
||||
* Do not edit manually.
|
||||
* Web4Ai API
|
||||
* OpenAPI spec version: 0.1.0
|
||||
*/
|
||||
|
||||
export interface VisitDeviceRow {
|
||||
device: string;
|
||||
views: number;
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
/**
|
||||
* Generated by orval v7.21.0 🍺
|
||||
* Do not edit manually.
|
||||
* Web4Ai API
|
||||
* OpenAPI spec version: 0.1.0
|
||||
*/
|
||||
|
||||
export interface VisitPathRow {
|
||||
path: string;
|
||||
views: number;
|
||||
visitors: number;
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
/**
|
||||
* Generated by orval v7.21.0 🍺
|
||||
* Do not edit manually.
|
||||
* Web4Ai API
|
||||
* OpenAPI spec version: 0.1.0
|
||||
*/
|
||||
|
||||
export interface VisitReferrerRow {
|
||||
domain: string;
|
||||
views: number;
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
/**
|
||||
* Generated by orval v7.21.0 🍺
|
||||
* Do not edit manually.
|
||||
* Web4Ai API
|
||||
* OpenAPI spec version: 0.1.0
|
||||
*/
|
||||
|
||||
export interface VisitSiteRow {
|
||||
site_id: string;
|
||||
place_id: string;
|
||||
name: string;
|
||||
views: number;
|
||||
visitors: number;
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
/**
|
||||
* Generated by orval v7.21.0 🍺
|
||||
* Do not edit manually.
|
||||
* Web4Ai API
|
||||
* OpenAPI spec version: 0.1.0
|
||||
*/
|
||||
|
||||
export type VisitStatsParams = {
|
||||
/**
|
||||
* KST 날짜, 기본 to-6일
|
||||
*/
|
||||
from?: string | null;
|
||||
/**
|
||||
* KST 날짜, 기본 오늘
|
||||
*/
|
||||
to?: string | null;
|
||||
};
|
||||
@@ -0,0 +1,13 @@
|
||||
/**
|
||||
* Generated by orval v7.21.0 🍺
|
||||
* Do not edit manually.
|
||||
* Web4Ai API
|
||||
* OpenAPI spec version: 0.1.0
|
||||
*/
|
||||
import type { VisitSummaryLastAt } from "./visitSummaryLastAt";
|
||||
|
||||
export interface VisitSummary {
|
||||
views?: number;
|
||||
visitors?: number;
|
||||
last_at?: VisitSummaryLastAt;
|
||||
}
|
||||
@@ -0,0 +1,8 @@
|
||||
/**
|
||||
* Generated by orval v7.21.0 🍺
|
||||
* Do not edit manually.
|
||||
* Web4Ai API
|
||||
* OpenAPI spec version: 0.1.0
|
||||
*/
|
||||
|
||||
export type VisitSummaryLastAt = string | null;
|
||||
@@ -0,0 +1,11 @@
|
||||
/**
|
||||
* Generated by orval v7.21.0 🍺
|
||||
* Do not edit manually.
|
||||
* Web4Ai API
|
||||
* OpenAPI spec version: 0.1.0
|
||||
*/
|
||||
|
||||
export interface VisitUtmRow {
|
||||
source: string;
|
||||
views: number;
|
||||
}
|
||||
Reference in new issue
Block a user