diff --git a/imweb/imweb-members.html b/imweb/imweb-members.html
index 5da986b..2f87e70 100644
--- a/imweb/imweb-members.html
+++ b/imweb/imweb-members.html
@@ -477,7 +477,7 @@
신청 유입 상위
- 최근 30일 · 신청 직전 유입 기준
+ 최근 30일 · 신청 때 유입 기준
@@ -571,8 +571,7 @@
-
-
+
@@ -593,7 +592,7 @@
| 신청일시 | 신청자 | 연락처 | 상품 | 업체 | 카톡 버튼 |
- 신청 때 유입 | 가입 경로 |
+ 신청 때 유입 | 가입 경로 |
@@ -900,7 +899,7 @@
app: {
range: 'all', mode: 'product', group: null, groupLabel: '',
cursor: null, loading: false, seq: 0, groupsSeq: 0,
- basis: 'apply_last', statsGroup: 'source', statsSeq: 0, inflowFilter: null,
+ basis: 'apply_first', statsGroup: 'source', statsSeq: 0, inflowFilter: null,
rows: {}
},
// 업체 링크
@@ -1445,7 +1444,6 @@
['외부 리퍼러', esc(inf.referrer)],
['첫 랜딩', esc(inf.landingPath) + (inf.productId ? ' #' + esc(inf.productId) + '' : '')],
['최초 유입일', esc(inf.firstTouchDate)],
- ['최종 유입', esc(inf.lastTouch)],
['기록일', esc(inf.recordedDate)]
]) + '';
}
@@ -1480,7 +1478,7 @@
setKpi('join-week', num(c.atJoin + c.afterJoin + c.none));
}).catch(errorNotice);
- api('GET', '/admin/applications/inflow-stats' + toQuery(Object.assign({ basis: 'apply_last', groupBy: 'source' }, periodQuery('30', 'appliedFrom', 'appliedTo')))).then(function (s) {
+ api('GET', '/admin/applications/inflow-stats' + toQuery(Object.assign({ basis: 'apply_first', groupBy: 'source' }, periodQuery('30', 'appliedFrom', 'appliedTo')))).then(function (s) {
$('[data-role="ov-app-bars"]').innerHTML = barsHtml(s.items.slice(0, TOP_SIZE), true, null, '건');
}).catch(errorNotice);
@@ -1501,12 +1499,12 @@
$('[data-role="ov-recent-rows"]').innerHTML = page.items.length ? page.items.map(function (a) {
state.app.rows[a.id] = a;
var m = a.member;
- var last = a.lastInflow && a.lastInflow.source ? a.lastInflow : a.inflow;
+ var inf = a.inflow;
return '' +
'| ' + whenCell(a.appliedAt) + ' | ' +
'' + personCell(m ? m.name : a.memberUid, '') + ' | ' +
'' + dash(a.productName) + ' | ' +
- '' + (a.partner ? '' + esc(a.partner.name) + '' : (last && last.source ? esc(last.source) : '-')) + ' | ' +
+ '' + (a.partner ? '' + esc(a.partner.name) + '' : (inf && inf.source ? esc(inf.source) : '-')) + ' | ' +
'
';
}).join('') : '| 아직 신청이 없습니다. |
';
}).catch(errorNotice);
@@ -1519,7 +1517,7 @@
$('[data-role="ov-app-bars"]').addEventListener('click', function (e) {
var bar = closest(e.target, '.mgm-bar');
if (!bar || bar.disabled) return;
- openApplications({ range: '30', inflowFilter: { basis: 'apply_last', field: 'source', value: bar.getAttribute('data-key') } });
+ openApplications({ range: '30', inflowFilter: { basis: 'apply_first', field: 'source', value: bar.getAttribute('data-key') } });
});
$('[data-role="ov-join-bars"]').addEventListener('click', function (e) {
var bar = closest(e.target, '.mgm-bar');
@@ -1537,7 +1535,7 @@
/* ===================== 신청 내역 ===================== */
var appForm = $('[data-role="app-filter"]');
- var APP_BASIS_LABEL = { apply_last: '신청 직전', apply_first: '신청 때 최초', join: '가입 경로' };
+ var APP_BASIS_LABEL = { apply_first: '신청 때 유입', join: '가입 경로' };
var APP_GROUP_LABEL = { source: '유입원', medium: '매체', campaign: '캠페인', content: '콘텐츠' };
// 다른 화면에서 신청 내역 열기 — 기간·유입 필터를 미리 채운다
@@ -1631,18 +1629,6 @@
$('[data-role="app-chips"]').innerHTML = chips.join('');
}
- // 신청 때 유입 칸 — 최종 유입을 보여주고, 첫 경로가 다르면 '최초'로 함께 적는다
- function applyInflowCell(a) {
- var first = a.inflow, last = a.lastInflow && a.lastInflow.source ? a.lastInflow : first;
- var html = inflowText(last);
- if (first && first.source && last && last.source &&
- (first.source !== last.source || first.medium !== last.medium || first.campaign !== last.campaign)) {
- html += '최초: ' +
- esc(first.source) + (first.medium ? ' / ' + esc(first.medium) : '') + '';
- }
- return html;
- }
-
function appRowHtml(a) {
var m = a.member;
state.app.rows[a.id] = a;
@@ -1655,7 +1641,7 @@
'' + (a.kakaoClickedAt
? '클릭'
: '-') + ' | ' +
- '' + applyInflowCell(a) + ' | ' +
+ '' + inflowText(a.inflow) + ' | ' +
'' + joinInflowCell(m) + ' | ' +
'';
}
@@ -1698,8 +1684,7 @@
function openApplicationDrawer(id) {
var a = state.app.rows[id];
if (!a) return;
- var first = a.inflow, last = a.lastInflow && a.lastInflow.source ? a.lastInflow : first;
- var sameTouch = !first || !first.source || (first.source === last.source && first.medium === last.medium && first.campaign === last.campaign);
+ var inf = a.inflow || {};
var html = '신청
' + dlHtml([
['상품', dash(a.productName) + ' #' + esc(a.productIdx) + ''],
['신청일시', esc(kstDateTime(a.appliedAt))],
@@ -1707,10 +1692,10 @@
['카톡 버튼', a.kakaoClickedAt ? '눌렀음 · ' + esc(kstDateTime(a.kakaoClickedAt)) + ' (실제 입장 여부는 알 수 없음)' : '누르지 않음']
]) + '' +
'신청 때 유입
' + dlHtml([
- ['신청 직전', last && last.source ? esc(last.source) + (last.medium ? ' / ' + esc(last.medium) : '') : ''],
- ['캠페인', esc(last && last.campaign)],
- ['콘텐츠', esc(last && last.content)],
- ['최초 유입', sameTouch ? '신청 직전과 같음' : esc(first.source) + (first.medium ? ' / ' + esc(first.medium) : '') + (first.campaign ? ' · ' + esc(first.campaign) : '')]
+ ['유입원', esc(inf.source)],
+ ['매체', esc(inf.medium)],
+ ['캠페인', esc(inf.campaign)],
+ ['콘텐츠', esc(inf.content)]
]) + '' + memberSectionsHtml(a.member);
openDrawer((a.member ? a.member.name : a.memberUid) + ' 님의 신청', html);
}