diff --git a/src/app/mock-api/apps/board/popup/api.ts b/src/app/mock-api/apps/board/popup/api.ts
index 2cdc93a..b9dd8dc 100644
--- a/src/app/mock-api/apps/board/popup/api.ts
+++ b/src/app/mock-api/apps/board/popup/api.ts
@@ -42,19 +42,19 @@ export class BoardPopupMockApi {
let popups: any[] | null = cloneDeep(this._popups);
// Sort the popups
- if (sort === 'sku' || sort === 'name' || sort === 'active') {
- popups.sort((a, b) => {
- const fieldA = a[sort].toString().toUpperCase();
- const fieldB = b[sort].toString().toUpperCase();
- return order === 'asc'
- ? fieldA.localeCompare(fieldB)
- : fieldB.localeCompare(fieldA);
- });
- } else {
- popups.sort((a, b) =>
- order === 'asc' ? a[sort] - b[sort] : b[sort] - a[sort]
- );
- }
+ // if (sort === 'sku' || sort === 'name' || sort === 'active') {
+ // popups.sort((a, b) => {
+ // const fieldA = a[sort].toString().toUpperCase();
+ // const fieldB = b[sort].toString().toUpperCase();
+ // return order === 'asc'
+ // ? fieldA.localeCompare(fieldB)
+ // : fieldB.localeCompare(fieldA);
+ // });
+ // } else {
+ // popups.sort((a, b) =>
+ // order === 'asc' ? a[sort] - b[sort] : b[sort] - a[sort]
+ // );
+ // }
// If search exists...
if (search) {
diff --git a/src/app/mock-api/apps/board/popup/data.ts b/src/app/mock-api/apps/board/popup/data.ts
index 05cfd91..cd154e0 100644
--- a/src/app/mock-api/apps/board/popup/data.ts
+++ b/src/app/mock-api/apps/board/popup/data.ts
@@ -2,6 +2,7 @@
export const popups = [
{
+ id: '1',
index: 10,
title: '악성배팅 제제 안내',
widthSize: 500,
@@ -10,5 +11,66 @@ export const popups = [
leftMargin: 100,
site: 'all',
useOrNot: 'N',
+ content: 'test',
+ },
+ {
+ id: '2',
+ index: 10,
+ title: '악성배팅 제제 안내2',
+ widthSize: 500,
+ heightSize: 830,
+ topMargin: 100,
+ leftMargin: 100,
+ site: 'all',
+ useOrNot: 'N',
+ content: 'test',
+ },
+ {
+ id: '3',
+ index: 10,
+ title: '악성배팅 제제 안내3',
+ widthSize: 500,
+ heightSize: 830,
+ topMargin: 100,
+ leftMargin: 100,
+ site: 'all',
+ useOrNot: 'N',
+ content: 'test',
+ },
+ {
+ id: '4',
+ index: 10,
+ title: '악성배팅 제제 안내4',
+ widthSize: 500,
+ heightSize: 830,
+ topMargin: 100,
+ leftMargin: 100,
+ site: 'all',
+ useOrNot: 'N',
+ content: 'test',
+ },
+ {
+ id: '5',
+ index: 10,
+ title: '악성배팅 제제 안내5',
+ widthSize: 500,
+ heightSize: 830,
+ topMargin: 100,
+ leftMargin: 100,
+ site: 'all',
+ useOrNot: 'N',
+ content: 'test',
+ },
+ {
+ id: '6',
+ index: 10,
+ title: '악성배팅 제제 안내6',
+ widthSize: 500,
+ heightSize: 830,
+ topMargin: 100,
+ leftMargin: 100,
+ site: 'all',
+ useOrNot: 'N',
+ content: 'test',
},
];
diff --git a/src/app/mock-api/apps/report/daily-partner/api.ts b/src/app/mock-api/apps/report/daily-partner/api.ts
index 4981939..6c6d045 100644
--- a/src/app/mock-api/apps/report/daily-partner/api.ts
+++ b/src/app/mock-api/apps/report/daily-partner/api.ts
@@ -29,16 +29,36 @@ export class ReportDailyPartnerMockApi {
// @ DailyPartners - GET
// -----------------------------------------------------------------------------------------------------
this._fuseMockApiService
- .onGet('api/apps/report/daily-partner', 300)
+ .onGet('api/apps/report/daily-partners', 300)
.reply(({ request }) => {
// Get available queries
const search = request.params.get('search');
- const sort = request.params.get('sort') || 'name';
+ const sort = request.params.get('sort') || 'lastDayHoldingMoney';
const order = request.params.get('order') || 'asc';
+ const page = parseInt(request.params.get('page') ?? '1', 10);
+ const size = parseInt(request.params.get('size') ?? '10', 10);
// Clone the dailyPartners
let dailyPartners: any[] | null = cloneDeep(this._dailyPartners);
+ // Sort the dailys
+ if (
+ sort === 'lastDayHoldingMoney' ||
+ sort === 'memberCharge' ||
+ sort === 'memberExchange'
+ ) {
+ dailyPartners.sort((a, b) => {
+ const fieldA = a[sort].toString().toUpperCase();
+ const fieldB = b[sort].toString().toUpperCase();
+ return order === 'asc'
+ ? fieldA.localeCompare(fieldB)
+ : fieldB.localeCompare(fieldA);
+ });
+ } else {
+ dailyPartners.sort((a, b) =>
+ order === 'asc' ? a[sort] - b[sort] : b[sort] - a[sort]
+ );
+ }
// If search exists...
if (search) {
// Filter the dailyPartners
@@ -49,6 +69,41 @@ export class ReportDailyPartnerMockApi {
);
}
+ // Paginate - Start
+ const dailysLength = dailyPartners.length;
+
+ // Calculate pagination details
+ const begin = page * size;
+ const end = Math.min(size * (page + 1), dailysLength);
+ const lastPage = Math.max(Math.ceil(dailysLength / size), 1);
+
+ // Prepare the pagination object
+ let pagination = {};
+
+ // If the requested page number is bigger than
+ // the last possible page number, return null for
+ // dailys but also send the last possible page so
+ // the app can navigate to there
+ if (page > lastPage) {
+ dailyPartners = null;
+ pagination = {
+ lastPage,
+ };
+ } else {
+ // Paginate the results by size
+ dailyPartners = dailyPartners.slice(begin, end);
+
+ // Prepare the pagination mock-api
+ pagination = {
+ length: dailysLength,
+ size: size,
+ page: page,
+ lastPage: lastPage,
+ startIndex: begin,
+ endIndex: end - 1,
+ };
+ }
+
// Return the response
return [
200,
@@ -61,21 +116,21 @@ export class ReportDailyPartnerMockApi {
// -----------------------------------------------------------------------------------------------------
// @ DailyPartner - GET
// -----------------------------------------------------------------------------------------------------
- // this._fuseMockApiService
- // .onGet('api/apps/report/daily-partner')
- // .reply(({ request }) => {
- // // Get the id from the params
- // const id = request.params.get('id');
+ this._fuseMockApiService
+ .onGet('api/apps/report/daily-partner')
+ .reply(({ request }) => {
+ // Get the id from the params
+ const id = request.params.get('id');
- // // Clone the dailyPartners
- // const dailyPartners = cloneDeep(this._dailyPartners);
+ // Clone the dailyPartners
+ const dailyPartners = cloneDeep(this._dailyPartners);
- // // Find the dailyPartner
- // const dailyPartner = dailyPartners.find((item: any) => item.id === id);
+ // Find the dailyPartner
+ const dailyPartner = dailyPartners.find((item: any) => item.id === id);
- // // Return the response
- // return [200, dailyPartner];
- // });
+ // Return the response
+ return [200, dailyPartner];
+ });
// -----------------------------------------------------------------------------------------------------
// @ DailyPartner - POST
diff --git a/src/app/mock-api/apps/report/daily-partner/data.ts b/src/app/mock-api/apps/report/daily-partner/data.ts
index 2fd6c65..f64a447 100644
--- a/src/app/mock-api/apps/report/daily-partner/data.ts
+++ b/src/app/mock-api/apps/report/daily-partner/data.ts
@@ -1,545 +1,551 @@
/* eslint-disable */
export const dailyPartners = [
+ {
+ id: '8fcce528-d878-4cc8-99f7-bd3451ed5402',
+ processDate: '2022-06-20',
+ lastDayHoldingMoney: 22846133,
+ memberCharge: 0,
+ memberExchange: 0,
+ memberProfitLoss: 0,
+ partnerCharge: 0,
+ partnerExchange: 0,
+ partnerProfitLoss: 0,
+ totalProfitLoss: 0,
+ passiveMoney: 0,
+ passiveComp: 0,
+ casinoBetting: 0,
+ casinoTie: 0,
+ casinoCancel: 0,
+ casinoAvailable: 0,
+ casinoWinning: 0,
+ casinoWinLoss: 0,
+ casinoCommission: 0,
+ casinoBetWinCalculate: 0,
+ slotBetting: 160000,
+ slotCancel: 0,
+ slotAvailable: 160000,
+ slotWinning: 90280,
+ slotWinLoss: 69720,
+ slotCommission: 8000,
+ slotBetWinCalculate: 61720,
+ powerballBetting: 0,
+ powerballWinning: 0,
+ powerballWinLoss: 0,
+ powerballCommission: 0,
+ powerballBetWinCalculate: 0,
+ totalBetWinCalculate: 61720,
+ },
// {
- // id: 'on00',
- // totalPartnerCount: '5',
- // totalHoldingMoney: 303675,
- // totalComp: 108933,
- // total: 412608,
- // branchCount: 1,
- // divisionCount: 1,
- // officeCount: 1,
- // storeCount: 1,
- // memberCount: 1,
- // nickname: 'on00',
- // accountHolder: '11',
- // phoneNumber: '010-1111-1111',
- // calculateType: '롤링',
- // ownCash: 50000,
- // ownComp: 1711,
- // ownCoupon: 50000,
- // gameMoney: 0,
- // todayComp: 0,
- // totalDeposit: 0,
- // totalWithdraw: 0,
- // balance: 0,
- // registDate: '2022-06-12 15:38',
- // finalSigninDate: '',
- // ip: '',
- // state: '정상',
- // note: '',
+ // user: {
+ // id: '1',
+ // signinId: 'kgon1',
+ // type: '본사',
+ // parentId: 0,
+ // },
+ // bank: {
+ // users: {
+ // deposit: '0',
+ // withdraw: '0',
+ // netProfit: 0,
+ // },
+ // parthners: {
+ // deposit: '0',
+ // withdraw: '0',
+ // netProfit: '0',
+ // },
+ // totalNetProfit: '0',
+ // passiveMoney: '0',
+ // passiveComp: '0',
+ // casino: {
+ // betting: '382,000',
+ // bettingTie: '33,000',
+ // bettingCancel: '0',
+ // bettingValid: '351,000',
+ // bettingWin: '357,050',
+ // winLoss: '26,950',
+ // commission: {
+ // total: '7,020',
+ // partner: '5,265',
+ // me: '1,755',
+ // },
+ // betWinSettle: '19,930',
+ // },
+ // slot: {
+ // betting: '382,000',
+ // bettingCancel: '0',
+ // bettingValid: '351,000',
+ // bettingWin: '357,050',
+ // winLoss: '26,950',
+ // commission: {
+ // total: '7,020',
+ // partner: '5,265',
+ // me: '1,755',
+ // },
+ // betWinSettle: '19,930',
+ // },
+ // powerball: {
+ // betting: '0',
+ // bettingCancel: '0',
+ // bettingValid: '0',
+ // bettingWin: '0',
+ // winLoss: '0',
+ // commission: {
+ // total: '0',
+ // partner: '0',
+ // me: '0',
+ // },
+ // betWinSettle: '19,930',
+ // },
+ // },
+ // totalBetSettle: '119,400',
+ // },
+ // {
+ // user: {
+ // id: '2',
+ // signinId: 'kgon2',
+ // type: '대본',
+ // parentId: 1,
+ // },
+ // bank: {
+ // users: {
+ // deposit: '0',
+ // withdraw: '0',
+ // netProfit: 0,
+ // },
+ // parthners: {
+ // deposit: '0',
+ // withdraw: '0',
+ // netProfit: '0',
+ // },
+ // totalNetProfit: '0',
+ // passiveMoney: '0',
+ // passiveComp: '0',
+ // casino: {
+ // betting: '382,000',
+ // bettingTie: '33,000',
+ // bettingCancel: '0',
+ // bettingValid: '351,000',
+ // bettingWin: '357,050',
+ // winLoss: '26,950',
+ // commission: {
+ // total: '7,020',
+ // partner: '5,265',
+ // me: '1,755',
+ // },
+ // betWinSettle: '19,930',
+ // },
+ // slot: {
+ // betting: '382,000',
+ // bettingCancel: '0',
+ // bettingValid: '351,000',
+ // bettingWin: '357,050',
+ // winLoss: '26,950',
+ // commission: {
+ // total: '7,020',
+ // partner: '5,265',
+ // me: '1,755',
+ // },
+ // betWinSettle: '19,930',
+ // },
+ // powerball: {
+ // betting: '0',
+ // bettingCancel: '0',
+ // bettingValid: '0',
+ // bettingWin: '0',
+ // winLoss: '0',
+ // commission: {
+ // total: '0',
+ // partner: '0',
+ // me: '0',
+ // },
+ // betWinSettle: '19,930',
+ // },
+ // },
+ // totalBetSettle: '119,400',
+ // },
+ // {
+ // user: {
+ // id: '3',
+ // signinId: 'kgon1',
+ // type: '본사',
+ // parentId: 2,
+ // },
+ // bank: {
+ // users: {
+ // deposit: '0',
+ // withdraw: '0',
+ // netProfit: 0,
+ // },
+ // parthners: {
+ // deposit: '0',
+ // withdraw: '0',
+ // netProfit: '0',
+ // },
+ // totalNetProfit: '0',
+ // passiveMoney: '0',
+ // passiveComp: '0',
+ // casino: {
+ // betting: '382,000',
+ // bettingTie: '33,000',
+ // bettingCancel: '0',
+ // bettingValid: '351,000',
+ // bettingWin: '357,050',
+ // winLoss: '26,950',
+ // commission: {
+ // total: '7,020',
+ // partner: '5,265',
+ // me: '1,755',
+ // },
+ // betWinSettle: '19,930',
+ // },
+ // slot: {
+ // betting: '382,000',
+ // bettingCancel: '0',
+ // bettingValid: '351,000',
+ // bettingWin: '357,050',
+ // winLoss: '26,950',
+ // commission: {
+ // total: '7,020',
+ // partner: '5,265',
+ // me: '1,755',
+ // },
+ // betWinSettle: '19,930',
+ // },
+ // powerball: {
+ // betting: '0',
+ // bettingCancel: '0',
+ // bettingValid: '0',
+ // bettingWin: '0',
+ // winLoss: '0',
+ // commission: {
+ // total: '0',
+ // partner: '0',
+ // me: '0',
+ // },
+ // betWinSettle: '19,930',
+ // },
+ // },
+ // totalBetSettle: '119,400',
+ // },
+ // {
+ // user: {
+ // id: '4',
+ // signinId: 'kgon1',
+ // type: '부본',
+ // parentId: 3,
+ // },
+ // bank: {
+ // users: {
+ // deposit: '0',
+ // withdraw: '0',
+ // netProfit: 0,
+ // },
+ // parthners: {
+ // deposit: '0',
+ // withdraw: '0',
+ // netProfit: '0',
+ // },
+ // totalNetProfit: '0',
+ // passiveMoney: '0',
+ // passiveComp: '0',
+ // casino: {
+ // betting: '382,000',
+ // bettingTie: '33,000',
+ // bettingCancel: '0',
+ // bettingValid: '351,000',
+ // bettingWin: '357,050',
+ // winLoss: '26,950',
+ // commission: {
+ // total: '7,020',
+ // partner: '5,265',
+ // me: '1,755',
+ // },
+ // betWinSettle: '19,930',
+ // },
+ // slot: {
+ // betting: '382,000',
+ // bettingCancel: '0',
+ // bettingValid: '351,000',
+ // bettingWin: '357,050',
+ // winLoss: '26,950',
+ // commission: {
+ // total: '7,020',
+ // partner: '5,265',
+ // me: '1,755',
+ // },
+ // betWinSettle: '19,930',
+ // },
+ // powerball: {
+ // betting: '0',
+ // bettingCancel: '0',
+ // bettingValid: '0',
+ // bettingWin: '0',
+ // winLoss: '0',
+ // commission: {
+ // total: '0',
+ // partner: '0',
+ // me: '0',
+ // },
+ // betWinSettle: '19,930',
+ // },
+ // },
+ // totalBetSettle: '119,400',
+ // },
+ // {
+ // user: {
+ // id: '5',
+ // signinId: 'kgon1',
+ // type: '본사',
+ // parentId: 0,
+ // },
+ // bank: {
+ // users: {
+ // deposit: '0',
+ // withdraw: '0',
+ // netProfit: 0,
+ // },
+ // parthners: {
+ // deposit: '0',
+ // withdraw: '0',
+ // netProfit: '0',
+ // },
+ // totalNetProfit: '0',
+ // passiveMoney: '0',
+ // passiveComp: '0',
+ // casino: {
+ // betting: '382,000',
+ // bettingTie: '33,000',
+ // bettingCancel: '0',
+ // bettingValid: '351,000',
+ // bettingWin: '357,050',
+ // winLoss: '26,950',
+ // commission: {
+ // total: '7,020',
+ // partner: '5,265',
+ // me: '1,755',
+ // },
+ // betWinSettle: '19,930',
+ // },
+ // slot: {
+ // betting: '382,000',
+ // bettingCancel: '0',
+ // bettingValid: '351,000',
+ // bettingWin: '357,050',
+ // winLoss: '26,950',
+ // commission: {
+ // total: '7,020',
+ // partner: '5,265',
+ // me: '1,755',
+ // },
+ // betWinSettle: '19,930',
+ // },
+ // powerball: {
+ // betting: '0',
+ // bettingCancel: '0',
+ // bettingValid: '0',
+ // bettingWin: '0',
+ // winLoss: '0',
+ // commission: {
+ // total: '0',
+ // partner: '0',
+ // me: '0',
+ // },
+ // betWinSettle: '19,930',
+ // },
+ // },
+ // totalBetSettle: '119,400',
+ // },
+ // {
+ // user: {
+ // id: '6',
+ // signinId: 'kgon1',
+ // type: '본사',
+ // parentId: 0,
+ // },
+ // bank: {
+ // users: {
+ // deposit: '0',
+ // withdraw: '0',
+ // netProfit: 0,
+ // },
+ // parthners: {
+ // deposit: '0',
+ // withdraw: '0',
+ // netProfit: '0',
+ // },
+ // totalNetProfit: '0',
+ // passiveMoney: '0',
+ // passiveComp: '0',
+ // casino: {
+ // betting: '382,000',
+ // bettingTie: '33,000',
+ // bettingCancel: '0',
+ // bettingValid: '351,000',
+ // bettingWin: '357,050',
+ // winLoss: '26,950',
+ // commission: {
+ // total: '7,020',
+ // partner: '5,265',
+ // me: '1,755',
+ // },
+ // betWinSettle: '19,930',
+ // },
+ // slot: {
+ // betting: '382,000',
+ // bettingCancel: '0',
+ // bettingValid: '351,000',
+ // bettingWin: '357,050',
+ // winLoss: '26,950',
+ // commission: {
+ // total: '7,020',
+ // partner: '5,265',
+ // me: '1,755',
+ // },
+ // betWinSettle: '19,930',
+ // },
+ // powerball: {
+ // betting: '0',
+ // bettingCancel: '0',
+ // bettingValid: '0',
+ // bettingWin: '0',
+ // winLoss: '0',
+ // commission: {
+ // total: '0',
+ // partner: '0',
+ // me: '0',
+ // },
+ // betWinSettle: '19,930',
+ // },
+ // },
+ // totalBetSettle: '119,400',
+ // },
+ // {
+ // user: {
+ // id: '7',
+ // signinId: 'kgon1',
+ // type: '본사',
+ // parentId: 0,
+ // },
+ // bank: {
+ // users: {
+ // deposit: '0',
+ // withdraw: '0',
+ // netProfit: 0,
+ // },
+ // parthners: {
+ // deposit: '0',
+ // withdraw: '0',
+ // netProfit: '0',
+ // },
+ // totalNetProfit: '0',
+ // passiveMoney: '0',
+ // passiveComp: '0',
+ // casino: {
+ // betting: '382,000',
+ // bettingTie: '33,000',
+ // bettingCancel: '0',
+ // bettingValid: '351,000',
+ // bettingWin: '357,050',
+ // winLoss: '26,950',
+ // commission: {
+ // total: '7,020',
+ // partner: '5,265',
+ // me: '1,755',
+ // },
+ // betWinSettle: '19,930',
+ // },
+ // slot: {
+ // betting: '382,000',
+ // bettingCancel: '0',
+ // bettingValid: '351,000',
+ // bettingWin: '357,050',
+ // winLoss: '26,950',
+ // commission: {
+ // total: '7,020',
+ // partner: '5,265',
+ // me: '1,755',
+ // },
+ // betWinSettle: '19,930',
+ // },
+ // powerball: {
+ // betting: '0',
+ // bettingCancel: '0',
+ // bettingValid: '0',
+ // bettingWin: '0',
+ // winLoss: '0',
+ // commission: {
+ // total: '0',
+ // partner: '0',
+ // me: '0',
+ // },
+ // betWinSettle: '19,930',
+ // },
+ // },
+ // totalBetSettle: '119,400',
+ // },
+ // {
+ // user: {
+ // id: '8',
+ // signinId: 'kgon1',
+ // type: '본사',
+ // parentId: 0,
+ // },
+ // bank: {
+ // users: {
+ // deposit: '0',
+ // withdraw: '0',
+ // netProfit: 0,
+ // },
+ // parthners: {
+ // deposit: '0',
+ // withdraw: '0',
+ // netProfit: '0',
+ // },
+ // totalNetProfit: '0',
+ // passiveMoney: '0',
+ // passiveComp: '0',
+ // casino: {
+ // betting: '382,000',
+ // bettingTie: '33,000',
+ // bettingCancel: '0',
+ // bettingValid: '351,000',
+ // bettingWin: '357,050',
+ // winLoss: '26,950',
+ // commission: {
+ // total: '7,020',
+ // partner: '5,265',
+ // me: '1,755',
+ // },
+ // betWinSettle: '19,930',
+ // },
+ // slot: {
+ // betting: '382,000',
+ // bettingCancel: '0',
+ // bettingValid: '351,000',
+ // bettingWin: '357,050',
+ // winLoss: '26,950',
+ // commission: {
+ // total: '7,020',
+ // partner: '5,265',
+ // me: '1,755',
+ // },
+ // betWinSettle: '19,930',
+ // },
+ // powerball: {
+ // betting: '0',
+ // bettingCancel: '0',
+ // bettingValid: '0',
+ // bettingWin: '0',
+ // winLoss: '0',
+ // commission: {
+ // total: '0',
+ // partner: '0',
+ // me: '0',
+ // },
+ // betWinSettle: '19,930',
+ // },
+ // },
+ // totalBetSettle: '119,400',
// },
- {
- user: {
- id: '1',
- signinId: 'kgon1',
- type: '본사',
- parentId: 0,
- },
- bank: {
- users: {
- deposit: '0',
- withdraw: '0',
- netProfit: 0,
- },
- parthners: {
- deposit: '0',
- withdraw: '0',
- netProfit: '0',
- },
- totalNetProfit: '0',
- passiveMoney: '0',
- passiveComp: '0',
- casino: {
- betting: '382,000',
- bettingTie: '33,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- slot: {
- betting: '382,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- powerball: {
- betting: '0',
- bettingCancel: '0',
- bettingValid: '0',
- bettingWin: '0',
- winLoss: '0',
- commission: {
- total: '0',
- partner: '0',
- me: '0',
- },
- betWinSettle: '19,930',
- },
- },
- totalBetSettle: '119,400',
- },
- {
- user: {
- id: '2',
- signinId: 'kgon2',
- type: '대본',
- parentId: 1,
- },
- bank: {
- users: {
- deposit: '0',
- withdraw: '0',
- netProfit: 0,
- },
- parthners: {
- deposit: '0',
- withdraw: '0',
- netProfit: '0',
- },
- totalNetProfit: '0',
- passiveMoney: '0',
- passiveComp: '0',
- casino: {
- betting: '382,000',
- bettingTie: '33,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- slot: {
- betting: '382,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- powerball: {
- betting: '0',
- bettingCancel: '0',
- bettingValid: '0',
- bettingWin: '0',
- winLoss: '0',
- commission: {
- total: '0',
- partner: '0',
- me: '0',
- },
- betWinSettle: '19,930',
- },
- },
- totalBetSettle: '119,400',
- },
- {
- user: {
- id: '3',
- signinId: 'kgon1',
- type: '본사',
- parentId: 2,
- },
- bank: {
- users: {
- deposit: '0',
- withdraw: '0',
- netProfit: 0,
- },
- parthners: {
- deposit: '0',
- withdraw: '0',
- netProfit: '0',
- },
- totalNetProfit: '0',
- passiveMoney: '0',
- passiveComp: '0',
- casino: {
- betting: '382,000',
- bettingTie: '33,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- slot: {
- betting: '382,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- powerball: {
- betting: '0',
- bettingCancel: '0',
- bettingValid: '0',
- bettingWin: '0',
- winLoss: '0',
- commission: {
- total: '0',
- partner: '0',
- me: '0',
- },
- betWinSettle: '19,930',
- },
- },
- totalBetSettle: '119,400',
- },
- {
- user: {
- id: '4',
- signinId: 'kgon1',
- type: '부본',
- parentId: 3,
- },
- bank: {
- users: {
- deposit: '0',
- withdraw: '0',
- netProfit: 0,
- },
- parthners: {
- deposit: '0',
- withdraw: '0',
- netProfit: '0',
- },
- totalNetProfit: '0',
- passiveMoney: '0',
- passiveComp: '0',
- casino: {
- betting: '382,000',
- bettingTie: '33,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- slot: {
- betting: '382,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- powerball: {
- betting: '0',
- bettingCancel: '0',
- bettingValid: '0',
- bettingWin: '0',
- winLoss: '0',
- commission: {
- total: '0',
- partner: '0',
- me: '0',
- },
- betWinSettle: '19,930',
- },
- },
- totalBetSettle: '119,400',
- },
- {
- user: {
- id: '5',
- signinId: 'kgon1',
- type: '본사',
- parentId: 0,
- },
- bank: {
- users: {
- deposit: '0',
- withdraw: '0',
- netProfit: 0,
- },
- parthners: {
- deposit: '0',
- withdraw: '0',
- netProfit: '0',
- },
- totalNetProfit: '0',
- passiveMoney: '0',
- passiveComp: '0',
- casino: {
- betting: '382,000',
- bettingTie: '33,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- slot: {
- betting: '382,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- powerball: {
- betting: '0',
- bettingCancel: '0',
- bettingValid: '0',
- bettingWin: '0',
- winLoss: '0',
- commission: {
- total: '0',
- partner: '0',
- me: '0',
- },
- betWinSettle: '19,930',
- },
- },
- totalBetSettle: '119,400',
- },
- {
- user: {
- id: '6',
- signinId: 'kgon1',
- type: '본사',
- parentId: 0,
- },
- bank: {
- users: {
- deposit: '0',
- withdraw: '0',
- netProfit: 0,
- },
- parthners: {
- deposit: '0',
- withdraw: '0',
- netProfit: '0',
- },
- totalNetProfit: '0',
- passiveMoney: '0',
- passiveComp: '0',
- casino: {
- betting: '382,000',
- bettingTie: '33,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- slot: {
- betting: '382,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- powerball: {
- betting: '0',
- bettingCancel: '0',
- bettingValid: '0',
- bettingWin: '0',
- winLoss: '0',
- commission: {
- total: '0',
- partner: '0',
- me: '0',
- },
- betWinSettle: '19,930',
- },
- },
- totalBetSettle: '119,400',
- },
- {
- user: {
- id: '7',
- signinId: 'kgon1',
- type: '본사',
- parentId: 0,
- },
- bank: {
- users: {
- deposit: '0',
- withdraw: '0',
- netProfit: 0,
- },
- parthners: {
- deposit: '0',
- withdraw: '0',
- netProfit: '0',
- },
- totalNetProfit: '0',
- passiveMoney: '0',
- passiveComp: '0',
- casino: {
- betting: '382,000',
- bettingTie: '33,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- slot: {
- betting: '382,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- powerball: {
- betting: '0',
- bettingCancel: '0',
- bettingValid: '0',
- bettingWin: '0',
- winLoss: '0',
- commission: {
- total: '0',
- partner: '0',
- me: '0',
- },
- betWinSettle: '19,930',
- },
- },
- totalBetSettle: '119,400',
- },
- {
- user: {
- id: '8',
- signinId: 'kgon1',
- type: '본사',
- parentId: 0,
- },
- bank: {
- users: {
- deposit: '0',
- withdraw: '0',
- netProfit: 0,
- },
- parthners: {
- deposit: '0',
- withdraw: '0',
- netProfit: '0',
- },
- totalNetProfit: '0',
- passiveMoney: '0',
- passiveComp: '0',
- casino: {
- betting: '382,000',
- bettingTie: '33,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- slot: {
- betting: '382,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- powerball: {
- betting: '0',
- bettingCancel: '0',
- bettingValid: '0',
- bettingWin: '0',
- winLoss: '0',
- commission: {
- total: '0',
- partner: '0',
- me: '0',
- },
- betWinSettle: '19,930',
- },
- },
- totalBetSettle: '119,400',
- },
];
diff --git a/src/app/mock-api/apps/report/statistics/data.ts b/src/app/mock-api/apps/report/statistics/data.ts
index 96ccddf..ab7f328 100644
--- a/src/app/mock-api/apps/report/statistics/data.ts
+++ b/src/app/mock-api/apps/report/statistics/data.ts
@@ -2,32 +2,35 @@
export const statisticss = [
{
- id: 'on00',
- totalPartnerCount: '5',
- totalHoldingMoney: 303675,
- totalComp: 108933,
- total: 412608,
- branchCount: 1,
- divisionCount: 1,
- officeCount: 1,
- storeCount: 1,
- memberCount: 1,
- nickname: 'on00',
- accountHolder: '11',
- phoneNumber: '010-1111-1111',
- calculateType: '롤링',
- ownCash: 50000,
- ownComp: 1711,
- ownCoupon: 50000,
- gameMoney: 0,
- todayComp: 0,
- totalDeposit: 0,
- totalWithdraw: 0,
- balance: 0,
- registDate: '2022-06-12 15:38',
- finalSigninDate: '',
- ip: '',
- state: '정상',
- note: '',
+ id: '7eb7c859-1347-4317-96b6-9476a7e2ba3c',
+ casinoUse: 2,
+ casinoBetting: 1183000,
+ casinoCancel: 10000,
+ casinoAvailable: 1140000,
+ casinoWinning: 979050,
+ casinoWinLoss: 193950,
+ casinoCommission: 14810,
+ casinoBetWinCalculate: 179140,
+ slotUse: 2,
+ slotBetting: 225000,
+ slotCancel: 0,
+ slotAvailable: 225000,
+ slotWinning: 114280,
+ slotWinLoss: 110720,
+ slotTotalCommission: 11250,
+ slotBetWinCalculate: 99470,
+ powerballUse: 0,
+ powerballBetting: 0,
+ powerballWinning: 0,
+ powerballWinLoss: 0,
+ powerballCommission: 0,
+ powerballBetWinCalculate: 0,
+ totalUse: 4,
+ totalAvailable: 1365000,
+ totalBetting: 1408000,
+ totalCancel: 10000,
+ totalWinLoss: 304670,
+ totalCommission: 26060,
+ totalBetWinCalculate: 278610,
},
];
diff --git a/src/app/mock-api/apps/report/today-bet/api.ts b/src/app/mock-api/apps/report/today-bet/api.ts
index 583a03f..722e1f6 100644
--- a/src/app/mock-api/apps/report/today-bet/api.ts
+++ b/src/app/mock-api/apps/report/today-bet/api.ts
@@ -2,7 +2,6 @@ import { Injectable } from '@angular/core';
import { assign, cloneDeep } from 'lodash-es';
import { FuseMockApiService, FuseMockApiUtils } from '@fuse/lib/mock-api';
import { todayBets as todayBetsData } from './data';
-import { contacts } from '../../chat/data';
@Injectable({
providedIn: 'root',
@@ -34,12 +33,29 @@ export class ReportTodayBetMockApi {
.reply(({ request }) => {
// Get available queries
const search = request.params.get('search');
- const sort = request.params.get('sort') || 'name';
+ const sort = request.params.get('sort') || 'signinId';
const order = request.params.get('order') || 'asc';
+ const page = parseInt(request.params.get('page') ?? '1', 10);
+ const size = parseInt(request.params.get('size') ?? '10', 10);
// Clone the todayBets
let todayBets: any[] | null = cloneDeep(this._todayBets);
+ // Sort the todayBets
+ if (sort === 'signinId' || sort === 'nickname' || sort === 'rank') {
+ todayBets.sort((a, b) => {
+ const fieldA = a[sort].toString().toUpperCase();
+ const fieldB = b[sort].toString().toUpperCase();
+ return order === 'asc'
+ ? fieldA.localeCompare(fieldB)
+ : fieldB.localeCompare(fieldA);
+ });
+ } else {
+ todayBets.sort((a, b) =>
+ order === 'asc' ? a[sort] - b[sort] : b[sort] - a[sort]
+ );
+ }
+
// If search exists...
if (search) {
// Filter the todayBets
@@ -50,11 +66,47 @@ export class ReportTodayBetMockApi {
);
}
+ // Paginate - Start
+ const todayBetsLength = todayBets.length;
+
+ // Calculate pagination details
+ const begin = page * size;
+ const end = Math.min(size * (page + 1), todayBetsLength);
+ const lastPage = Math.max(Math.ceil(todayBetsLength / size), 1);
+
+ // Prepare the pagination object
+ let pagination = {};
+
+ // If the requested page number is bigger than
+ // the last possible page number, return null for
+ // todayBets but also send the last possible page so
+ // the app can navigate to there
+ if (page > lastPage) {
+ todayBets = null;
+ pagination = {
+ lastPage,
+ };
+ } else {
+ // Paginate the results by size
+ todayBets = todayBets.slice(begin, end);
+
+ // Prepare the pagination mock-api
+ pagination = {
+ length: todayBetsLength,
+ size: size,
+ page: page,
+ lastPage: lastPage,
+ startIndex: begin,
+ endIndex: end - 1,
+ };
+ }
+
// Return the response
return [
200,
{
todayBets,
+ pagination,
},
];
});
diff --git a/src/app/mock-api/apps/report/today-bet/data.ts b/src/app/mock-api/apps/report/today-bet/data.ts
index d998fcd..caeba1f 100644
--- a/src/app/mock-api/apps/report/today-bet/data.ts
+++ b/src/app/mock-api/apps/report/today-bet/data.ts
@@ -2,518 +2,40 @@
export const todayBets = [
{
- user: {
- id: '1',
- signinId: 'kgon1',
- type: '본사',
- parentId: 0,
- rank: '회원',
- level: '4',
- nickname: 'aa100',
- },
- bank: {
- users: {
- deposit: '0',
- withdraw: '0',
- netProfit: 0,
- },
- parthners: {
- deposit: '0',
- withdraw: '0',
- netProfit: '0',
- },
- totalNetProfit: '0',
- passiveMoney: '0',
- passiveComp: '0',
- casino: {
- betting: '382,000',
- bettingTie: '33,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- slot: {
- betting: '382,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- powerball: {
- betting: '0',
- bettingCancel: '0',
- bettingValid: '0',
- bettingWin: '0',
- winLoss: '0',
- commission: {
- total: '0',
- partner: '0',
- me: '0',
- },
- betWinSettle: '19,930',
- },
- },
- totalBetSettle: '119,400',
- },
- {
- user: {
- id: '2',
- signinId: 'kgon2',
- type: '대본',
- parentId: 1,
- },
- bank: {
- users: {
- deposit: '0',
- withdraw: '0',
- netProfit: 0,
- },
- parthners: {
- deposit: '0',
- withdraw: '0',
- netProfit: '0',
- },
- totalNetProfit: '0',
- passiveMoney: '0',
- passiveComp: '0',
- casino: {
- betting: '382,000',
- bettingTie: '33,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- slot: {
- betting: '382,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- powerball: {
- betting: '0',
- bettingCancel: '0',
- bettingValid: '0',
- bettingWin: '0',
- winLoss: '0',
- commission: {
- total: '0',
- partner: '0',
- me: '0',
- },
- betWinSettle: '19,930',
- },
- },
- totalBetSettle: '119,400',
- },
- {
- user: {
- id: '3',
- signinId: 'kgon1',
- type: '본사',
- parentId: 2,
- },
- bank: {
- users: {
- deposit: '0',
- withdraw: '0',
- netProfit: 0,
- },
- parthners: {
- deposit: '0',
- withdraw: '0',
- netProfit: '0',
- },
- totalNetProfit: '0',
- passiveMoney: '0',
- passiveComp: '0',
- casino: {
- betting: '382,000',
- bettingTie: '33,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- slot: {
- betting: '382,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- powerball: {
- betting: '0',
- bettingCancel: '0',
- bettingValid: '0',
- bettingWin: '0',
- winLoss: '0',
- commission: {
- total: '0',
- partner: '0',
- me: '0',
- },
- betWinSettle: '19,930',
- },
- },
- totalBetSettle: '119,400',
- },
- {
- user: {
- id: '4',
- signinId: 'kgon1',
- type: '부본',
- parentId: 3,
- },
- bank: {
- users: {
- deposit: '0',
- withdraw: '0',
- netProfit: 0,
- },
- parthners: {
- deposit: '0',
- withdraw: '0',
- netProfit: '0',
- },
- totalNetProfit: '0',
- passiveMoney: '0',
- passiveComp: '0',
- casino: {
- betting: '382,000',
- bettingTie: '33,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- slot: {
- betting: '382,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- powerball: {
- betting: '0',
- bettingCancel: '0',
- bettingValid: '0',
- bettingWin: '0',
- winLoss: '0',
- commission: {
- total: '0',
- partner: '0',
- me: '0',
- },
- betWinSettle: '19,930',
- },
- },
- totalBetSettle: '119,400',
- },
- {
- user: {
- id: '5',
- signinId: 'kgon1',
- type: '본사',
- parentId: 0,
- },
- bank: {
- users: {
- deposit: '0',
- withdraw: '0',
- netProfit: 0,
- },
- parthners: {
- deposit: '0',
- withdraw: '0',
- netProfit: '0',
- },
- totalNetProfit: '0',
- passiveMoney: '0',
- passiveComp: '0',
- casino: {
- betting: '382,000',
- bettingTie: '33,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- slot: {
- betting: '382,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- powerball: {
- betting: '0',
- bettingCancel: '0',
- bettingValid: '0',
- bettingWin: '0',
- winLoss: '0',
- commission: {
- total: '0',
- partner: '0',
- me: '0',
- },
- betWinSettle: '19,930',
- },
- },
- totalBetSettle: '119,400',
- },
- {
- user: {
- id: '6',
- signinId: 'kgon1',
- type: '본사',
- parentId: 0,
- },
- bank: {
- users: {
- deposit: '0',
- withdraw: '0',
- netProfit: 0,
- },
- parthners: {
- deposit: '0',
- withdraw: '0',
- netProfit: '0',
- },
- totalNetProfit: '0',
- passiveMoney: '0',
- passiveComp: '0',
- casino: {
- betting: '382,000',
- bettingTie: '33,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- slot: {
- betting: '382,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- powerball: {
- betting: '0',
- bettingCancel: '0',
- bettingValid: '0',
- bettingWin: '0',
- winLoss: '0',
- commission: {
- total: '0',
- partner: '0',
- me: '0',
- },
- betWinSettle: '19,930',
- },
- },
- totalBetSettle: '119,400',
- },
- {
- user: {
- id: '7',
- signinId: 'kgon1',
- type: '본사',
- parentId: 0,
- },
- bank: {
- users: {
- deposit: '0',
- withdraw: '0',
- netProfit: 0,
- },
- parthners: {
- deposit: '0',
- withdraw: '0',
- netProfit: '0',
- },
- totalNetProfit: '0',
- passiveMoney: '0',
- passiveComp: '0',
- casino: {
- betting: '382,000',
- bettingTie: '33,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- slot: {
- betting: '382,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- powerball: {
- betting: '0',
- bettingCancel: '0',
- bettingValid: '0',
- bettingWin: '0',
- winLoss: '0',
- commission: {
- total: '0',
- partner: '0',
- me: '0',
- },
- betWinSettle: '19,930',
- },
- },
- totalBetSettle: '119,400',
- },
- {
- user: {
- id: '8',
- signinId: 'kgon1',
- type: '본사',
- parentId: 0,
- },
- bank: {
- users: {
- deposit: '0',
- withdraw: '0',
- netProfit: 0,
- },
- parthners: {
- deposit: '0',
- withdraw: '0',
- netProfit: '0',
- },
- totalNetProfit: '0',
- passiveMoney: '0',
- passiveComp: '0',
- casino: {
- betting: '382,000',
- bettingTie: '33,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- slot: {
- betting: '382,000',
- bettingCancel: '0',
- bettingValid: '351,000',
- bettingWin: '357,050',
- winLoss: '26,950',
- commission: {
- total: '7,020',
- partner: '5,265',
- me: '1,755',
- },
- betWinSettle: '19,930',
- },
- powerball: {
- betting: '0',
- bettingCancel: '0',
- bettingValid: '0',
- bettingWin: '0',
- winLoss: '0',
- commission: {
- total: '0',
- partner: '0',
- me: '0',
- },
- betWinSettle: '19,930',
- },
- },
- totalBetSettle: '119,400',
+ id: '8fcce528-d878-4cc8-99f7-bd3451ed5402',
+ signinId: 'aa100',
+ rank: '회원',
+ level: '4',
+ nickname: 'aa100',
+ memberCharge: 40100000,
+ memberExchange: 19000000,
+ memberProfitLoss: 21100000,
+ partnerCharge: 0,
+ partnerExchange: 0,
+ partnerProfitLoss: 0,
+ totalProfitLoss: 21100000,
+ passiveMoney: -20002000,
+ passiveComp: 0,
+ casinoBetting: 13648000,
+ casinoTie: 314000,
+ casinoCancel: 0,
+ casinoAvailable: 13334000,
+ casinoWinning: 12649500,
+ casinoWinLoss: 998500,
+ casinoCommission: 83347,
+ casinoBetWinCalculate: 915153,
+ slotBetting: 1159511,
+ slotCancel: 0,
+ slotAvailable: 1159511,
+ slotWinning: 897768,
+ slotWinLoss: 261743,
+ slotCommission: 6800,
+ slotBetWinCalculate: 254943,
+ powerballBetting: 0,
+ powerballWinning: 0,
+ powerballWinLoss: 0,
+ powerballCommission: 0,
+ powerballBetWinCalculate: 0,
+ totalBetWinCalculate: 0,
},
];
diff --git a/src/app/modules/admin/bank/deposit/components/list.component.html b/src/app/modules/admin/bank/deposit/components/list.component.html
index 15d1aee..78d79a5 100644
--- a/src/app/modules/admin/bank/deposit/components/list.component.html
+++ b/src/app/modules/admin/bank/deposit/components/list.component.html
@@ -89,18 +89,18 @@
-
-
-
-
-
-
+
+
+
+
+
+
-
-
-
-
-
-
+
+
+
+
+
+
diff --git a/src/app/modules/admin/bank/withdraw/components/list.component.html b/src/app/modules/admin/bank/withdraw/components/list.component.html
index aa31f9b..eb636fc 100644
--- a/src/app/modules/admin/bank/withdraw/components/list.component.html
+++ b/src/app/modules/admin/bank/withdraw/components/list.component.html
@@ -89,23 +89,23 @@
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
diff --git a/src/app/modules/admin/board/popup/components/index.ts b/src/app/modules/admin/board/popup/components/index.ts
index d187813..dfb4808 100644
--- a/src/app/modules/admin/board/popup/components/index.ts
+++ b/src/app/modules/admin/board/popup/components/index.ts
@@ -1,4 +1,5 @@
import { ListComponent } from './list.component';
+import { ViewComponent } from './view.component';
import { ReditComponent } from './redit.component';
-export const COMPONENTS = [ListComponent, ReditComponent];
+export const COMPONENTS = [ListComponent, ViewComponent, ReditComponent];
diff --git a/src/app/modules/admin/board/popup/components/list.component.html b/src/app/modules/admin/board/popup/components/list.component.html
index d300d76..376bda2 100644
--- a/src/app/modules/admin/board/popup/components/list.component.html
+++ b/src/app/modules/admin/board/popup/components/list.component.html
@@ -28,7 +28,12 @@
제목 |
-
+ |
{{ info.title }}
@@ -98,7 +103,12 @@
| 비고 |
- |
diff --git a/src/app/modules/admin/board/popup/components/list.component.ts b/src/app/modules/admin/board/popup/components/list.component.ts
index 8180d66..7be1a98 100644
--- a/src/app/modules/admin/board/popup/components/list.component.ts
+++ b/src/app/modules/admin/board/popup/components/list.component.ts
@@ -179,14 +179,24 @@ export class ListComponent implements OnInit, AfterViewInit, OnDestroy {
// @ Public methods
// -----------------------------------------------------------------------------------------------------
- viewUserDetail(id: string): void {
- let url: string = 'member/user/' + id;
- this.router.navigateByUrl(url);
- }
// -----------------------------------------------------------------------------------------------------
// @ Private methods
// -----------------------------------------------------------------------------------------------------
+ __viewPopupDetail(id: string): void {
+ let url: string = 'board/popup/view/' + id;
+ this.router.navigateByUrl(url);
+ }
+
+ __createPopup(): void {
+ let url: string = 'board/popup/redit/';
+ this.router.navigateByUrl(url);
+ }
+
+ __modifyPopup(id: string): void {
+ let url: string = 'board/popup/redit/' + id;
+ this.router.navigateByUrl(url);
+ }
/**
* Create product
*/
diff --git a/src/app/modules/admin/board/popup/components/redit.component.html b/src/app/modules/admin/board/popup/components/redit.component.html
index 844b557..f64a01b 100644
--- a/src/app/modules/admin/board/popup/components/redit.component.html
+++ b/src/app/modules/admin/board/popup/components/redit.component.html
@@ -1,260 +1,127 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
- 수정
-
-
-
- 삭제
-
-
-
-
-
-
-
-
-
사이트선택
-
{{ contact.title }}
-
-
-
-
-
-
-
-
팝업사이즈
-
-
-
-
- •
- {{ email.label }}
-
-
- •
- 180
-
-
-
-
-
-
-
-
-
-
-
-
팝업좌표
-
-
-
-
- •
- {{
- phoneNumber.phoneNumber
- }}
-
-
- •
- 180
-
-
-
-
-
-
-
-
-
-
-
팝업제목
-
{{ contact.address }}
-
-
-
-
-
- 팝업내용
-
-
-
-
-
-
-
사용여부
-
- {{ contact.birthday | date: "longDate" }}
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/app/modules/admin/board/popup/components/redit.component.ts b/src/app/modules/admin/board/popup/components/redit.component.ts
index 25c34cc..cb8f2f3 100644
--- a/src/app/modules/admin/board/popup/components/redit.component.ts
+++ b/src/app/modules/admin/board/popup/components/redit.component.ts
@@ -8,6 +8,8 @@ import {
ViewChild,
ViewEncapsulation,
} from '@angular/core';
+
+import { ActivatedRoute, Router } from '@angular/router';
import { FormBuilder, FormControl, FormGroup } from '@angular/forms';
import { MatPaginator } from '@angular/material/paginator';
import { MatSort } from '@angular/material/sort';
@@ -15,7 +17,8 @@ import { Subject, takeUntil } from 'rxjs';
import { fuseAnimations } from '@fuse/animations';
import { FuseConfirmationService } from '@fuse/services/confirmation';
-import { ActivatedRoute, Router } from '@angular/router';
+import { Popup } from '../models/popup';
+import { PopupService } from '../services/popup.service';
@Component({
selector: 'popup-redit',
@@ -50,10 +53,11 @@ export class ReditComponent implements OnInit, AfterViewInit, OnDestroy {
isLoading = false;
searchInputControl = new FormControl();
- contactForm!: FormGroup;
+ popupForm!: FormGroup;
editMode: boolean = false;
contact = contacts[0];
categories = categories;
+ popup: Popup | undefined;
private _unsubscribeAll: Subject = new Subject();
@@ -65,7 +69,8 @@ export class ReditComponent implements OnInit, AfterViewInit, OnDestroy {
private _fuseConfirmationService: FuseConfirmationService,
private _formBuilder: FormBuilder,
private _route: ActivatedRoute,
- private _router: Router
+ private _router: Router,
+ private _popupService: PopupService
) {}
// -----------------------------------------------------------------------------------------------------
@@ -77,18 +82,32 @@ export class ReditComponent implements OnInit, AfterViewInit, OnDestroy {
*/
ngOnInit(): void {
// Create the contact form
- this.contactForm = this._formBuilder.group({
+ this.popupForm = this._formBuilder.group({
id: [''],
- name: [''],
- emails: this._formBuilder.array([]),
- phoneNumbers: this._formBuilder.array([]),
+ index: [''],
title: [''],
- company: [''],
- birthday: [null],
- address: [null],
- notes: [null],
- tags: [[]],
+ widthSize: [''],
+ heightSize: [''],
+ topMargin: [''],
+ leftMargin: [''],
+ site: [''],
+ useOrNot: [''],
+ content: [''],
});
+
+ this._popupService.popup$
+ .pipe(takeUntil(this._unsubscribeAll))
+ .subscribe((popup: Popup | undefined) => {
+ if (!popup) {
+ return;
+ }
+
+ this.popup = popup;
+ this.popupForm.patchValue(popup);
+
+ // Mark for check
+ this._changeDetectorRef.markForCheck();
+ });
}
/**
diff --git a/src/app/modules/admin/board/popup/components/view.component.html b/src/app/modules/admin/board/popup/components/view.component.html
new file mode 100644
index 0000000..d51a50d
--- /dev/null
+++ b/src/app/modules/admin/board/popup/components/view.component.html
@@ -0,0 +1,143 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 수정
+
+
+
+ 삭제
+
+
+
+
+
+
+
+
+
사이트선택
+
{{ popup?.site }}
+
+
+
+
+
+
+
+
팝업사이즈
+
+
+
+ •
+ 가로
+
+
+ •
+ {{ popup?.widthSize }}
+
+
+
+
+ •
+ 세로
+
+
+ •
+ {{ popup?.heightSize }}
+
+
+
+
+
+
+
+
+
+
+
팝업좌표
+
+
+
+ •
+ TOP
+
+
+ •
+ {{ popup?.topMargin }}
+
+
+
+
+ •
+ LEFT
+
+
+ •
+ {{ popup?.leftMargin }}
+
+
+
+
+
+
+
+
+
+
팝업제목
+
{{ popup?.title }}
+
+
+
+
+
+ 팝업내용
+
+
+
+
+
+
+
사용여부
+
+ {{ popup?.useOrNot }}
+
+
+
+
+
+
+
diff --git a/src/app/modules/admin/board/popup/components/view.component.ts b/src/app/modules/admin/board/popup/components/view.component.ts
new file mode 100644
index 0000000..fa064ae
--- /dev/null
+++ b/src/app/modules/admin/board/popup/components/view.component.ts
@@ -0,0 +1,116 @@
+import {
+ AfterViewInit,
+ ChangeDetectionStrategy,
+ ChangeDetectorRef,
+ Component,
+ OnDestroy,
+ OnInit,
+ ViewEncapsulation,
+} from '@angular/core';
+import { FormBuilder } from '@angular/forms';
+import { Subject, takeUntil } from 'rxjs';
+import { fuseAnimations } from '@fuse/animations';
+import { FuseConfirmationService } from '@fuse/services/confirmation';
+
+import { Popup } from '../models/popup';
+import { PopupService } from '../services/popup.service';
+import { Router } from '@angular/router';
+
+@Component({
+ selector: 'popup-view',
+ templateUrl: './view.component.html',
+ styles: [
+ /* language=SCSS */
+ `
+ .inventory-grid {
+ grid-template-columns: 60px auto 40px;
+
+ @screen sm {
+ grid-template-columns: 60px 60px 60px 60px 60px 60px auto 60px;
+ }
+
+ @screen md {
+ grid-template-columns: 60px 60px 60px 60px 60px 60px auto 60px 60px;
+ }
+
+ @screen lg {
+ grid-template-columns: 60px 70px 70px 70px 70px 100px 60px 60px auto 60px 60px 60px 60px;
+ }
+ }
+ `,
+ ],
+ encapsulation: ViewEncapsulation.None,
+ changeDetection: ChangeDetectionStrategy.OnPush,
+ animations: fuseAnimations,
+})
+export class ViewComponent implements OnInit, AfterViewInit, OnDestroy {
+ isLoading = false;
+
+ private _unsubscribeAll: Subject = new Subject();
+
+ popup: Popup | undefined;
+
+ /**
+ * Constructor
+ */
+ constructor(
+ private _changeDetectorRef: ChangeDetectorRef,
+ private _fuseConfirmationService: FuseConfirmationService,
+ private _formBuilder: FormBuilder,
+ private _popupService: PopupService,
+ private router: Router
+ ) {}
+
+ // -----------------------------------------------------------------------------------------------------
+ // @ Lifecycle hooks
+ // -----------------------------------------------------------------------------------------------------
+
+ /**
+ * On init
+ */
+ ngOnInit(): void {
+ this._popupService.popup$
+ .pipe(takeUntil(this._unsubscribeAll))
+ .subscribe((popup: Popup | undefined) => {
+ if (!popup) {
+ return;
+ }
+
+ this.popup = popup;
+ // Mark for check
+ this._changeDetectorRef.markForCheck();
+ });
+ }
+
+ /**
+ * After view init
+ */
+ ngAfterViewInit(): void {}
+
+ /**
+ * On destroy
+ */
+ ngOnDestroy(): void {
+ // Unsubscribe from all subscriptions
+ this._unsubscribeAll.next(null);
+ this._unsubscribeAll.complete();
+ }
+
+ // -----------------------------------------------------------------------------------------------------
+ // @ Public methods
+ // -----------------------------------------------------------------------------------------------------
+
+ // -----------------------------------------------------------------------------------------------------
+ // @ Private methods
+ // -----------------------------------------------------------------------------------------------------
+
+ /**
+ * Toggle edit mode
+ *
+ * @param editMode
+ */
+ __modifyPopup(): void {
+ let url: string = 'board/popup/redit/' + this.popup?.id;
+ this.router.navigateByUrl(url);
+ }
+}
diff --git a/src/app/modules/admin/board/popup/models/popup.ts b/src/app/modules/admin/board/popup/models/popup.ts
index 7c342ce..9747767 100644
--- a/src/app/modules/admin/board/popup/models/popup.ts
+++ b/src/app/modules/admin/board/popup/models/popup.ts
@@ -2,6 +2,7 @@ export interface Popup {
id?: string;
index?: number;
title?: string;
+ content?: string;
widthSize?: number;
heightSize?: number;
topMargin?: number;
diff --git a/src/app/modules/admin/board/popup/popup.routing.ts b/src/app/modules/admin/board/popup/popup.routing.ts
index 6492012..91e20c9 100644
--- a/src/app/modules/admin/board/popup/popup.routing.ts
+++ b/src/app/modules/admin/board/popup/popup.routing.ts
@@ -2,9 +2,9 @@ import { Route } from '@angular/router';
import { ListComponent } from './components/list.component';
-import { PopupsResolver } from './resolvers/popup.resolver';
-import { UserResolver } from '../../member/user/resolvers/user.resolver';
+import { PopupsResolver, PopupResolver } from './resolvers/popup.resolver';
import { ReditComponent } from './components/redit.component';
+import { ViewComponent } from './components/view.component';
export const popupRoutes: Route[] = [
{
@@ -24,6 +24,21 @@ export const popupRoutes: Route[] = [
path: 'redit',
component: ReditComponent,
},
+ {
+ path: 'redit/:id',
+ component: ReditComponent,
+ resolve: {
+ popup: PopupResolver,
+ },
+ },
+
+ {
+ path: 'view/:id',
+ component: ViewComponent,
+ resolve: {
+ popup: PopupResolver,
+ },
+ },
// {
// path: 'redit',
diff --git a/src/app/modules/admin/member/unconnected/components/list.component.html b/src/app/modules/admin/member/unconnected/components/list.component.html
index 9e2db1f..204e4ad 100644
--- a/src/app/modules/admin/member/unconnected/components/list.component.html
+++ b/src/app/modules/admin/member/unconnected/components/list.component.html
@@ -276,15 +276,15 @@
-
-
-
- 탈퇴
-
-
-
-
- 휴면
-
+
+
+ 탈퇴
+
+
+
+
+ 휴면
+
+
diff --git a/src/app/modules/admin/member/user/components/list.component.html b/src/app/modules/admin/member/user/components/list.component.html
index 4a18d18..e06f7e6 100644
--- a/src/app/modules/admin/member/user/components/list.component.html
+++ b/src/app/modules/admin/member/user/components/list.component.html
@@ -266,7 +266,6 @@
IP{{ user.ip }}
-
@@ -292,35 +291,35 @@
-
-
-
- 정상
-
-
-
-
- 대기
-
-
-
-
- 탈퇴
-
-
-
-
- 휴면
-
-
-
-
- 블랙
-
-
-
-
- 정지
-
+
+
+ 정상
+
+
+
+
+ 대기
+
+
+
+
+ 탈퇴
+
+
+
+
+ 휴면
+
+
+
+
+ 블랙
+
+
+
+
+ 정지
+
+
diff --git a/src/app/modules/admin/report/daily-partner/components/list.component.html b/src/app/modules/admin/report/daily-partner/components/list.component.html
index 4e72342..6b300f4 100644
--- a/src/app/modules/admin/report/daily-partner/components/list.component.html
+++ b/src/app/modules/admin/report/daily-partner/components/list.component.html
@@ -1,348 +1,230 @@
-
-
-
-
-
-
-
- 파트너일일현황
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 전체
+ 파워볼
+ 카지노
+ 슬롯
+
+
+
+
+
+
+ Search
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
- {{
- roleSelect.value | titlecase
- }}
-
-
-
- {{ role.label }}
-
-
-
-
+
+
+ 어제
+
+
+
+
+ 오늘
+
+
+
+
+ 7일
+
+
+
+
+
+
+
+
+
+ 0; else noDailyPartner">
+
+
+
+
요율
+
상부
+
+ 아이디
+
+ 닉네임
+
+ 연락처
-
-
-
-
-
-
-
+
+ 등급
+
+ 레벨
-
-
-
-
-
-
-
-
-
-
-
-
-
- 검색하기
-
-
-
- 어제
-
-
-
- 오늘
-
-
-
- 7일
-
-
+
예금주
+
보유금
+
+ 게임중머니
+
+ 금일콤프
+
총입출
+
카지노->캐쉬
-
-
-
+
+
요율
+
+ {{ dailyPartner.highRank }}
+
+
+ {{ dailyPartner.signinId }}
+
+ {{ dailyPartner.nickname }}
+
+ {{ dailyPartner.phoneNumber }}
+
+
+ {{ dailyPartner.rank }}
+
+ LV{{ dailyPartner.level }}
+
+
+ {{ dailyPartner.accountHolder }}
+
+
+ 캐쉬{{ dailyPartner.ownCash }}
+
+ 콤프{{ dailyPartner.ownComp }}P
+
+ 쿠폰{{ dailyPartner.ownCoupon }}
+
+
+ {{ dailyPartner.gameMoney }}
+
+ {{ dailyPartner.todayComp }}P
+
+
+ 입금{{ dailyPartner.totalDeposit }}
+
+ 출금{{ dailyPartner.totalWithdraw }}
+
+ 차익{{ dailyPartner.balance }}
+
+
+
+ 게임머니확인
+
+
+
+ 게임머니회수
+
+
+
+
+
+
+
+
+
+
+
+
+ There are no data!
-
+
diff --git a/src/app/modules/admin/report/daily-partner/components/list.component.ts b/src/app/modules/admin/report/daily-partner/components/list.component.ts
index aa499ab..f0c216e 100644
--- a/src/app/modules/admin/report/daily-partner/components/list.component.ts
+++ b/src/app/modules/admin/report/daily-partner/components/list.component.ts
@@ -14,7 +14,8 @@ import {
FormGroup,
Validators,
} from '@angular/forms';
-
+import { MatPaginator } from '@angular/material/paginator';
+import { MatSort } from '@angular/material/sort';
import {
debounceTime,
map,
@@ -24,9 +25,6 @@ import {
switchMap,
takeUntil,
} from 'rxjs';
-
-import { MatTableDataSource } from '@angular/material/table';
-
import { fuseAnimations } from '@fuse/animations';
import { FuseConfirmationService } from '@fuse/services/confirmation';
@@ -64,46 +62,20 @@ import { Router } from '@angular/router';
animations: fuseAnimations,
})
export class ListComponent implements OnInit, AfterViewInit, OnDestroy {
+ @ViewChild(MatPaginator) private _paginator!: MatPaginator;
+ @ViewChild(MatSort) private _sort!: MatSort;
+
dailyPartners$!: Observable
;
users$!: Observable;
+ __isSearchOpened = false;
isLoading = false;
searchInputControl = new FormControl();
selectedDailyPartner?: DailyPartner;
+ pagination?: DailyPartnerPagination;
- dailyParthnerForm!: FormGroup;
-
- dailyPartnerDataSource: MatTableDataSource = new MatTableDataSource();
- dailyPartnerTableColumns: string[] = [
- 'partnerInfo',
- 'expansionBtn',
- 'depositDetails',
- 'depositPartnerDetails',
- 'totalProfit',
- 'passiveMoney',
- 'passiveComp',
- 'casinoBetDetails',
- 'casinoWinningDetails',
- 'casinoWinLoss',
- 'casinoCommission',
- 'casinoSettle',
- 'slotBetDetails',
- 'slotWinningDetails',
- 'slotWinLoss',
- 'slotCommission',
- 'slotSettle',
- 'powerballBetDetails',
- 'powerballWinningDetails',
- 'powerballWinLoss',
- 'powerballCommission',
- 'powerballSettle',
- 'totalBetWinSettle',
- ];
private _unsubscribeAll: Subject = new Subject();
- roles: any[];
- roles2: any[];
-
/**
* Constructor
*/
@@ -113,37 +85,7 @@ export class ListComponent implements OnInit, AfterViewInit, OnDestroy {
private _formBuilder: FormBuilder,
private _dailyPartnerService: DailyPartnerService,
private router: Router
- ) {
- this.roles = [
- {
- label: '전체',
- value: '전체',
- },
- {
- label: '파워볼',
- value: '파워볼',
- },
- {
- label: '카지노',
- value: '카지노',
- },
-
- {
- label: '슬롯',
- value: '슬롯',
- },
- ];
- this.roles2 = [
- {
- label: '회원아이디',
- value: '전체',
- },
- {
- label: '닉네임',
- value: '파워볼',
- },
- ];
- }
+ ) {}
// -----------------------------------------------------------------------------------------------------
// @ Lifecycle hooks
@@ -153,27 +95,63 @@ export class ListComponent implements OnInit, AfterViewInit, OnDestroy {
* On init
*/
ngOnInit(): void {
- this.dailyParthnerForm = this._formBuilder.group({
- bankName: [''],
- accountNumber: [''],
- accountHolder: [''],
- });
// Get the pagination
- this._dailyPartnerService
- .getDailyPartners()
+ this._dailyPartnerService.pagination$
.pipe(takeUntil(this._unsubscribeAll))
- .subscribe((dailyPartners: any) => {
+ .subscribe((pagination: DailyPartnerPagination | undefined) => {
+ // Update the pagination
+ this.pagination = pagination;
+
// Mark for check
- this.dailyPartnerDataSource = dailyPartners.dailyPartners;
- console.log(dailyPartners);
this._changeDetectorRef.markForCheck();
});
+
+ // Get the products
+ this.dailyPartners$ = this._dailyPartnerService.dailyPartners$;
}
/**
* After view init
*/
- ngAfterViewInit(): void {}
+ ngAfterViewInit(): void {
+ if (this._sort && this._paginator) {
+ // Set the initial sort
+ this._sort.sort({
+ id: 'lastDayHoldingMoney',
+ start: 'asc',
+ disableClear: true,
+ });
+
+ // Mark for check
+ this._changeDetectorRef.markForCheck();
+
+ // If the daily changes the sort order...
+ this._sort.sortChange
+ .pipe(takeUntil(this._unsubscribeAll))
+ .subscribe(() => {
+ // Reset back to the first page
+ this._paginator.pageIndex = 0;
+ });
+
+ // Get products if sort or page changes
+ merge(this._sort.sortChange, this._paginator.page)
+ .pipe(
+ switchMap(() => {
+ this.isLoading = true;
+ return this._dailyPartnerService.getDailyPartners(
+ this._paginator.pageIndex,
+ this._paginator.pageSize,
+ this._sort.active,
+ this._sort.direction
+ );
+ }),
+ map(() => {
+ this.isLoading = false;
+ })
+ )
+ .subscribe();
+ }
+ }
/**
* On destroy
@@ -208,6 +186,14 @@ export class ListComponent implements OnInit, AfterViewInit, OnDestroy {
*/
__toggleDetails(productId: string): void {}
+ /**
+ * toggle the search
+ * Used in 'bar'
+ */
+ __onClickSearch(): void {
+ this.__isSearchOpened = !this.__isSearchOpened;
+ }
+
/**
* Track by function for ngFor loops
*
@@ -217,7 +203,4 @@ export class ListComponent implements OnInit, AfterViewInit, OnDestroy {
__trackByFn(index: number, item: any): any {
return item.id || index;
}
- __testData(info: any): any {
- console.log(info);
- }
}
diff --git a/src/app/modules/admin/report/daily-partner/models/daily-partner.ts b/src/app/modules/admin/report/daily-partner/models/daily-partner.ts
index 623b465..edf6229 100644
--- a/src/app/modules/admin/report/daily-partner/models/daily-partner.ts
+++ b/src/app/modules/admin/report/daily-partner/models/daily-partner.ts
@@ -1,29 +1,38 @@
export interface DailyPartner {
- id?: string;
- totalPartnerCount?: number;
- totalHoldingMoney?: number;
- totalComp?: number;
- total?: number;
- branchCount?: number;
- divisionCount?: number;
- officeCount?: number;
- storeCount?: number;
- memberCount?: number;
+ id: string;
+ signinId?: string;
+ rank?: string;
nickname?: string;
- accountHolder?: string;
- phoneNumber?: string;
- calculateType?: string;
- ownCash?: number;
- ownComp?: number;
- ownCoupon?: number;
- gameMoney?: number;
- todayComp?: number;
- totalDeposit?: number;
- totalWithdraw?: number;
- balance?: number;
- registDate?: string;
- finalSigninDate?: string;
- ip?: string;
- state?: string;
- note?: string;
+ memberCharge?: number; // 회원충전
+ memberExchange?: number; // 회원환전
+ memberProfitLoss?: number; // 회원손익
+ partnerCharge?: number; // 파트너충전
+ partnerExchange?: number; // 파트너환전
+ partnerProfitLoss?: number; // 파트너손익
+ totalProfitLoss?: number; // 전체손익
+ passiveMoney?: number;
+ passiveComp?: number;
+ casinoBetting?: number; // 카지노배팅
+ casinoTie?: number; // 카지노타이
+ casinoCancel?: number; // 카지노취소
+ casinoAvailable?: number; // 카지노유효
+ casinoWinning?: number; // 카지노당첨
+ casinoWinLoss?: number; // 카지노윈로스(A)
+ casinoCommission?: number; // 카지노수수료(B)
+ casinoBetWinCalculate?: number; // 카지노벳윈정산 (A-B)
+ slotBetting?: number; // 슬롯배팅
+ slotCancel?: number; // 슬롯취소
+ slotAvailable?: number; // 슬롯유효
+ slotWinning?: number; // 슬롯당첨
+ slotWinLoss?: number; // 슬롯윈로스(D)
+ slotTotalCommission?: number; // 슬롯전체수수료(E)
+ slotBottomCommission?: number; // 슬롯하부수수료(E)
+ slotOwnCommission?: number; // 슬롯본인수수료(E)
+ slotBetWinCalculate?: number; // 슬롯벳윈정산(D-E)
+ powerballBetting?: number; // 파워볼배팅
+ powerballWinning?: number; // 파워볼당첨
+ powerballWinLoss?: number; // 파워볼윈로스(H)
+ powerballCommission?: number; // 파워볼수수료(I)
+ powerballBetWinCalculate?: number; // 파워볼벳윈정산(H-I)
+ totalBetWinCalculate?: number; // 총벳윈정산
}
diff --git a/src/app/modules/admin/report/daily-partner/resolvers/daily-partner.resolver.ts b/src/app/modules/admin/report/daily-partner/resolvers/daily-partner.resolver.ts
index f9ed4e7..dd62c7d 100644
--- a/src/app/modules/admin/report/daily-partner/resolvers/daily-partner.resolver.ts
+++ b/src/app/modules/admin/report/daily-partner/resolvers/daily-partner.resolver.ts
@@ -81,8 +81,9 @@ export class DailyPartnersResolver implements Resolve {
route: ActivatedRouteSnapshot,
state: RouterStateSnapshot
): Observable<{
+ pagination: DailyPartnerPagination;
dailyPartners: DailyPartner[];
}> {
- return this._dailyPartnerService.getDailyPartners('');
+ return this._dailyPartnerService.getDailyPartners();
}
}
diff --git a/src/app/modules/admin/report/daily-partner/services/daily-partner.service.ts b/src/app/modules/admin/report/daily-partner/services/daily-partner.service.ts
index 92cefa6..1af2647 100644
--- a/src/app/modules/admin/report/daily-partner/services/daily-partner.service.ts
+++ b/src/app/modules/admin/report/daily-partner/services/daily-partner.service.ts
@@ -74,19 +74,32 @@ export class DailyPartnerService {
* @param order
* @param search
*/
- getDailyPartners(search: string = ''): Observable<{
- dailyPartners: any;
+ getDailyPartners(
+ page: number = 0,
+ size: number = 10,
+ sort: string = 'name',
+ order: 'asc' | 'desc' | '' = 'asc',
+ search: string = ''
+ ): Observable<{
+ pagination: DailyPartnerPagination;
+ dailyPartners: DailyPartner[];
}> {
return this._httpClient
.get<{
- dailyPartners: any;
- }>('api/apps/report/daily-partner', {
+ pagination: DailyPartnerPagination;
+ dailyPartners: DailyPartner[];
+ }>('api/apps/report/daily-partners', {
params: {
+ page: '' + page,
+ size: '' + size,
+ sort,
+ order,
search,
},
})
.pipe(
tap((response) => {
+ this.__pagination.next(response.pagination);
this.__dailyPartners.next(response.dailyPartners);
})
);
diff --git a/src/app/modules/admin/report/monthly/components/list.component.html b/src/app/modules/admin/report/monthly/components/list.component.html
index 17a7572..29bb75c 100644
--- a/src/app/modules/admin/report/monthly/components/list.component.html
+++ b/src/app/modules/admin/report/monthly/components/list.component.html
@@ -7,9 +7,7 @@
class="sm:col-span-6 flex flex-col flex-auto p-6 bg-card shadow rounded-2xl overflow-hidden"
>
-
+
-
-
-
-
-
-
- 40
- 60
- 80
- 100
-
-
-
-
- LV.1
- LV.2
- LV.3
- LV.4
-
-
-
-
- 정상
- 대기
- 탈퇴
- 휴면
- 블랙
- 정지
-
-
-
-
- 카지노제한
- 슬롯제한
-
-
-
-
- 계좌입금
-
-
-
-
- 카지노콤프
- 슬롯콤프
- 배팅콤프
- 첫충콤프
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
-
- 검색하기
+
+ Search
- 엑셀저장
- 카지노머니확인
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -151,182 +82,100 @@
-
- 0; else noStatistics">
+
+ 0; else noStatistics">
-
-
요율
-
상부트리
-
관리
-
매장수
-
회원수
-
아이디
-
닉네임
+
요율
+
+
카지노->캐쉬
-
+
-
-
+
요율
+
-
+
+ {{ dailyPartner.signinId }}
+
+ {{ dailyPartner.nickname }}
+
+ {{ dailyPartner.phoneNumber }}
+
+
+ {{ dailyPartner.rank }}
+
+ LV{{ dailyPartner.level }}
+
+
+ {{ dailyPartner.accountHolder }}
+
+
+ 캐쉬{{ dailyPartner.ownCash }}
+
+ 콤프{{ dailyPartner.ownComp }}P
+
+ 쿠폰{{ dailyPartner.ownCoupon }}
+
+
+ {{ dailyPartner.gameMoney }}
+
+ {{ dailyPartner.todayComp }}P
+
+
+ 입금{{ dailyPartner.totalDeposit }}
+
+ 출금{{ dailyPartner.totalWithdraw }}
+
+ 차익{{ dailyPartner.balance }}
+ -->
+
- 요율
-
-
-
-
-
-
- 보유금지급/회수
- 수수료설정
- 콤프지급/회수
- 쿠폰머니지급/회수
- 쪽지보내기
- 베팅리스트
- 강제로그아웃
-
-
-
-
-
-
-
-
- {{ statistics.branchCount }}
-
-
- {{ statistics.divisionCount }}
-
-
- {{ statistics.officeCount }}
-
-
- {{ statistics.storeCount }}
-
-
-
-
-
- {{ statistics.memberCount }}
-
-
-
-
-
-
- {{ statistics.id }}
-
-
-
-
-
- {{ statistics.nickname }}
-
-
-
- {{ statistics.accountHolder }}
-
-
-
- {{ statistics.phoneNumber }}
-
-
-
- {{ statistics.calculateType }}
-
-
-
- 캐쉬{{ statistics.ownCash }} 콤프{{
- statistics.ownComp
- }}
- 쿠폰{{ statistics.ownCoupon }}
-
-
-
- {{ statistics.gameMoney }}
-
-
-
-
게임머니확인
-
+
+
게임머니회수
-
-
- {{ statistics.todayComp }}P
-
-
-
- 입금{{ statistics.totalDeposit }} 출금{{
- statistics.totalWithdraw
- }}
- 차익{{ statistics.balance }}
-
-
-
- 가입{{ statistics.registDate }} 최종{{
- statistics.finalSigninDate
- }}
- IP{{ statistics.ip }}
-
-
-
- {{ statistics.state }}
-
-
-
- {{ statistics.memberCount }}
-
-
-
-
- {{ statistics.note }}
-
-
@@ -348,7 +197,7 @@
- There are no statisticss!
+ There are no data!
diff --git a/src/app/modules/admin/report/statistics/components/list.component.ts b/src/app/modules/admin/report/statistics/components/list.component.ts
index 73af6f2..dac93d0 100644
--- a/src/app/modules/admin/report/statistics/components/list.component.ts
+++ b/src/app/modules/admin/report/statistics/components/list.component.ts
@@ -69,6 +69,7 @@ export class ListComponent implements OnInit, AfterViewInit, OnDestroy {
statisticss$!: Observable
;
users$!: Observable;
+ __isSearchOpened = false;
isLoading = false;
searchInputControl = new FormControl();
selectedStatistics?: Statistics;
@@ -117,7 +118,7 @@ export class ListComponent implements OnInit, AfterViewInit, OnDestroy {
if (this._sort && this._paginator) {
// Set the initial sort
this._sort.sort({
- id: 'name',
+ id: 'casinoUse',
start: 'asc',
disableClear: true,
});
@@ -186,6 +187,14 @@ export class ListComponent implements OnInit, AfterViewInit, OnDestroy {
*/
__toggleDetails(productId: string): void {}
+ /**
+ * toggle the search
+ * Used in 'bar'
+ */
+ __onClickSearch(): void {
+ this.__isSearchOpened = !this.__isSearchOpened;
+ }
+
/**
* Track by function for ngFor loops
*
diff --git a/src/app/modules/admin/report/statistics/models/statistics.ts b/src/app/modules/admin/report/statistics/models/statistics.ts
index a3219a9..1d95e1e 100644
--- a/src/app/modules/admin/report/statistics/models/statistics.ts
+++ b/src/app/modules/admin/report/statistics/models/statistics.ts
@@ -1,29 +1,32 @@
export interface Statistics {
- id?: string;
- totalPartnerCount?: number;
- totalHoldingMoney?: number;
- totalComp?: number;
- total?: number;
- branchCount?: number;
- divisionCount?: number;
- officeCount?: number;
- storeCount?: number;
- memberCount?: number;
- nickname?: string;
- accountHolder?: string;
- phoneNumber?: string;
- calculateType?: string;
- ownCash?: number;
- ownComp?: number;
- ownCoupon?: number;
- gameMoney?: number;
- todayComp?: number;
- totalDeposit?: number;
- totalWithdraw?: number;
- balance?: number;
- registDate?: string;
- finalSigninDate?: string;
- ip?: string;
- state?: string;
- note?: string;
+ id: string;
+ casinoUse?: number;
+ slotUse?: number;
+ powerballUse?: number;
+ casinoBetting?: number; // 카지노배팅
+ casinoCancel?: number; // 카지노취소
+ casinoAvailable?: number; // 카지노유효
+ casinoWinning?: number; // 카지노당첨
+ casinoWinLoss?: number; // 카지노윈로스(A)
+ casinoCommission?: number; // 카지노수수료(B)
+ casinoBetWinCalculate?: number; // 카지노벳윈정산 (A-B)
+ slotBetting?: number; // 슬롯배팅
+ slotCancel?: number; // 슬롯취소
+ slotAvailable?: number; // 슬롯유효
+ slotWinning?: number; // 슬롯당첨
+ slotWinLoss?: number; // 슬롯윈로스(D)
+ slotTotalCommission?: number; // 슬롯전체수수료(E)
+ slotBetWinCalculate?: number; // 슬롯벳윈정산(D-E)
+ powerballBetting?: number; // 파워볼배팅
+ powerballWinning?: number; // 파워볼당첨
+ powerballWinLoss?: number; // 파워볼윈로스(H)
+ powerballCommission?: number; // 파워볼수수료(I)
+ powerballBetWinCalculate?: number; // 파워볼벳윈정산(H-I)
+ totalUse?: number; // 총이용회원
+ totalAvailable?: number; // 총유효배팅
+ totalBetting?: number; // 총배팅
+ totalCancel?: number; // 총취소
+ totalWinLoss?: number; // 총윈로스
+ totalCommission?: number; // 총수수료
+ totalBetWinCalculate?: number; // 총벳윈정산
}
diff --git a/src/app/modules/admin/report/statistics/statistics.module.ts b/src/app/modules/admin/report/statistics/statistics.module.ts
index 737a47c..8222b33 100644
--- a/src/app/modules/admin/report/statistics/statistics.module.ts
+++ b/src/app/modules/admin/report/statistics/statistics.module.ts
@@ -12,9 +12,7 @@ import { MatSortModule } from '@angular/material/sort';
import { MatSelectModule } from '@angular/material/select';
import { MatTooltipModule } from '@angular/material/tooltip';
import { MatGridListModule } from '@angular/material/grid-list';
-import { MatSlideToggleModule } from '@angular/material/slide-toggle';
-import { MatRadioModule } from '@angular/material/radio';
-import { MatCheckboxModule } from '@angular/material/checkbox';
+import { MatDatepickerModule } from '@angular/material/datepicker';
import { TranslocoModule } from '@ngneat/transloco';
@@ -42,9 +40,7 @@ import { statisticsRoutes } from './statistics.routing';
MatSelectModule,
MatTooltipModule,
MatGridListModule,
- MatSlideToggleModule,
- MatRadioModule,
- MatCheckboxModule,
+ MatDatepickerModule,
],
})
export class StatisticsModule {}
diff --git a/src/app/modules/admin/report/today-bet/components/list.component.html b/src/app/modules/admin/report/today-bet/components/list.component.html
index a3f0820..83d1421 100644
--- a/src/app/modules/admin/report/today-bet/components/list.component.html
+++ b/src/app/modules/admin/report/today-bet/components/list.component.html
@@ -1,325 +1,303 @@
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 전체
+ 파워볼
+ 카지노
+ 슬롯
+
+
+
+
+ 회원아이디
+ 닉네임
+
+
+
+
+
-
- 금일배팅자목록
-
-
-
-
-
-
-
-
-
-
- {{
- roleSelect.value | titlecase
- }}
-
-
-
- {{ role.label }}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- {{
- roleSelect.value | titlecase
- }}
-
-
-
- {{ role.label }}
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Search
+
+
+
+ 검색하기
+
+
+
+
+ 어제
+
+
+
+
+ 오늘
+
+
+
+
+ 7일
+
+
+
+
+ 엑셀저장
+
+
+
+
+
+
+
+ 0; else noTodayBet">
+
+
+
+
+ 아이디
+
+ 닉네임
+
+
+ 등급
+
+ 레벨
+
+
회원입출금
+
파트너입출금
+
전체손익
+
수동머니
+
수동콤프
+
카-배팅
+
카-당첨
+
카-윈로스(A)
+
카-수수료(B)
+
카-벳윈정산(A-B)
+
슬-배팅
+
슬-당첨
+
슬-윈로스(D)
+
슬-수수료(E)
+
슬-벳윈정산(D-E)
+
파-배팅
+
파-당첨
+
파-윈로스(H)
+
파-수수료(I)
+
파-벳윈정산(H-I)
+
총벳윈정산
+
+
+
+
+
+
+ {{ todayBet.signinId }}
+
+ {{ todayBet.nickname }}
+
+
+ {{ todayBet.rank }}
+
+ {{ todayBet.level }}
+
+
+ 충전{{ todayBet.memberCharge }}
+
+ 환전{{ todayBet.memberExchange }}
+
+ 손익{{ todayBet.memberProfitLoss }}
+
+
+ 충전{{ todayBet.partnerCharge }}
+
+ 환전{{ todayBet.partnerExchange }}
+
+ 손익{{ todayBet.partnerProfitLoss }}
+
+
+ {{ todayBet.totalProfitLoss }}
+
+
{{ todayBet.passiveMoney }}
+
+ {{ todayBet.passiveComp }}
+
+
+ 배팅{{ todayBet.casinoBetting }}
+
+ 타이{{ todayBet.casinoTie }}
+
+ 취소{{ todayBet.casinoCancel }}
+
+ 유효{{ todayBet.casinoAvailable }}
+
+
+ {{ todayBet.casinoWinning }}
+
+
+ {{ todayBet.casinoWinLoss }}
+
+
+ {{ todayBet.casinoCommission }}
+
+
+ {{ todayBet.casinoBetWinCalculate }}
+
+
+ 배팅{{ todayBet.slotBetting }}
+
+ 취소{{ todayBet.slotCancel }}
+
+ 유효{{ todayBet.slotAvailable }}
+
+
+ {{ todayBet.slotWinning }}
+
+
+ {{ todayBet.slotWinLoss }}
+
+
+ {{ todayBet.slotCommission }}
+
+
+ {{ todayBet.slotBetWinCalculate }}
+
+
+ 배팅{{ todayBet.powerballBetting }}
+
+
+ {{ todayBet.powerballWinning }}
+
+
+ {{ todayBet.powerballWinLoss }}
+
+
+ {{ todayBet.powerballCommission }}
+
+
+ {{ todayBet.powerballBetWinCalculate }}
+
+
+ {{ todayBet.totalBetWinCalculate }}
+
+
+
+
+
+
+
+
+
+
+
+
+ There are no data!
+
+
+
+
diff --git a/src/app/modules/admin/report/today-bet/components/list.component.ts b/src/app/modules/admin/report/today-bet/components/list.component.ts
index 542cfb4..440eff0 100644
--- a/src/app/modules/admin/report/today-bet/components/list.component.ts
+++ b/src/app/modules/admin/report/today-bet/components/list.component.ts
@@ -34,7 +34,6 @@ import { TodayBet } from '../models/today-bet';
import { TodayBetPagination } from '../models/today-bet-pagination';
import { TodayBetService } from '../services/today-bet.service';
import { Router } from '@angular/router';
-import { MatTableDataSource } from '@angular/material/table';
@Component({
selector: 'today-bet-list',
@@ -43,18 +42,22 @@ import { MatTableDataSource } from '@angular/material/table';
/* language=SCSS */
`
.inventory-grid {
- grid-template-columns: 60px auto 40px;
+ /* 아이디 등급 회원 */
+ grid-template-columns: 40px auto 30px;
@screen sm {
- grid-template-columns: 60px 60px 60px 60px 60px 60px auto 60px;
+ /* 아이디 등급 회원 파트너 손익 머니 콤프 카배팅 */
+ grid-template-columns: 40px auto 30px 30px 30px 30px 30px 30px;
}
@screen md {
- grid-template-columns: 60px 60px 60px 60px 60px 60px auto 60px 60px;
+ /* 아이디 등급 회원 파트너 손익 머니 콤프 카배팅 카당첨 */
+ grid-template-columns: 40px auto 30px 30px 30px 30px 30px 30px 30px;
}
@screen lg {
- grid-template-columns: 60px 70px 70px 70px 70px 100px 60px 60px auto 60px 60px 60px 60px;
+ /* 아이디 등급 회원 파트너 손익 머니 콤프 카배팅 카당첨 카윈로스 카수수료 카정산 슬배팅 슬당첨 슬윈로스 슬수수료 슬정산 파배팅 파당첨 파윈로스 파수수료 파정산 총정산 */
+ grid-template-columns: 40px auto 30px 30px 30px 30px 30px 30px 30px 30px 30px 30px 30px 30px 30px 30px 30px 30px 30px 30px 30px 30px 30px;
}
}
`,
@@ -64,48 +67,20 @@ import { MatTableDataSource } from '@angular/material/table';
animations: fuseAnimations,
})
export class ListComponent implements OnInit, AfterViewInit, OnDestroy {
+ @ViewChild(MatPaginator) private _paginator!: MatPaginator;
+ @ViewChild(MatSort) private _sort!: MatSort;
+
todayBets$!: Observable
;
users$!: Observable;
+ __isSearchOpened = false;
isLoading = false;
searchInputControl = new FormControl();
selectedTodayBet?: TodayBet;
+ pagination?: TodayBetPagination;
- todayBetForm!: FormGroup;
-
- todayBetDataSource: MatTableDataSource = new MatTableDataSource();
- todayBetTableColumns: string[] = [
- 'rank',
- 'level',
- 'signinId',
- 'nickname',
- 'depositDetails',
- 'depositPartnerDetails',
- 'totalProfit',
- 'passiveMoney',
- 'passiveComp',
- 'casinoBetDetails',
- 'casinoWinningDetails',
- 'casinoWinLoss',
- 'casinoCommission',
- 'casinoSettle',
- 'slotBetDetails',
- 'slotWinningDetails',
- 'slotWinLoss',
- 'slotCommission',
- 'slotSettle',
- 'powerballBetDetails',
- 'powerballWinningDetails',
- 'powerballWinLoss',
- 'powerballCommission',
- 'powerballSettle',
- 'totalBetWinSettle',
- ];
private _unsubscribeAll: Subject = new Subject();
- roles1: any[];
- roles2: any[];
-
/**
* Constructor
*/
@@ -115,36 +90,7 @@ export class ListComponent implements OnInit, AfterViewInit, OnDestroy {
private _formBuilder: FormBuilder,
private _todayBetService: TodayBetService,
private router: Router
- ) {
- this.roles1 = [
- {
- label: '전체',
- value: '전체',
- },
- {
- label: '파워볼',
- value: '파워볼',
- },
- {
- label: '카지노',
- value: '카지노',
- },
- {
- label: '슬롯',
- value: '슬롯',
- },
- ];
- this.roles2 = [
- {
- label: '회원아이디',
- value: '회원아이디',
- },
- {
- label: '닉네임',
- value: '닉네임',
- },
- ];
- }
+ ) {}
// -----------------------------------------------------------------------------------------------------
// @ Lifecycle hooks
@@ -154,19 +100,14 @@ export class ListComponent implements OnInit, AfterViewInit, OnDestroy {
* On init
*/
ngOnInit(): void {
- this.todayBetForm = this._formBuilder.group({
- bankName: [''],
- accountNumber: [''],
- accountHolder: [''],
- });
// Get the pagination
- this._todayBetService
- .getTodayBets()
+ this._todayBetService.pagination$
.pipe(takeUntil(this._unsubscribeAll))
- .subscribe((todayBets: any) => {
+ .subscribe((pagination: TodayBetPagination | undefined) => {
+ // Update the pagination
+ this.pagination = pagination;
+
// Mark for check
- this.todayBetDataSource = todayBets.todayBets;
- console.log(todayBets);
this._changeDetectorRef.markForCheck();
});
@@ -177,7 +118,45 @@ export class ListComponent implements OnInit, AfterViewInit, OnDestroy {
/**
* After view init
*/
- ngAfterViewInit(): void {}
+ ngAfterViewInit(): void {
+ if (this._sort && this._paginator) {
+ // Set the initial sort
+ this._sort.sort({
+ id: 'signinId',
+ start: 'asc',
+ disableClear: true,
+ });
+
+ // Mark for check
+ this._changeDetectorRef.markForCheck();
+
+ // If the todayBet changes the sort order...
+ this._sort.sortChange
+ .pipe(takeUntil(this._unsubscribeAll))
+ .subscribe(() => {
+ // Reset back to the first page
+ this._paginator.pageIndex = 0;
+ });
+
+ // Get products if sort or page changes
+ merge(this._sort.sortChange, this._paginator.page)
+ .pipe(
+ switchMap(() => {
+ this.isLoading = true;
+ return this._todayBetService.getTodayBets(
+ this._paginator.pageIndex,
+ this._paginator.pageSize,
+ this._sort.active,
+ this._sort.direction
+ );
+ }),
+ map(() => {
+ this.isLoading = false;
+ })
+ )
+ .subscribe();
+ }
+ }
/**
* On destroy
@@ -212,6 +191,14 @@ export class ListComponent implements OnInit, AfterViewInit, OnDestroy {
*/
__toggleDetails(productId: string): void {}
+ /**
+ * toggle the search
+ * Used in 'bar'
+ */
+ __onClickSearch(): void {
+ this.__isSearchOpened = !this.__isSearchOpened;
+ }
+
/**
* Track by function for ngFor loops
*
@@ -221,7 +208,4 @@ export class ListComponent implements OnInit, AfterViewInit, OnDestroy {
__trackByFn(index: number, item: any): any {
return item.id || index;
}
- __testData(info: any): any {
- console.log(info);
- }
}
diff --git a/src/app/modules/admin/report/today-bet/models/today-bet.ts b/src/app/modules/admin/report/today-bet/models/today-bet.ts
index ff7c9ce..42936c7 100644
--- a/src/app/modules/admin/report/today-bet/models/today-bet.ts
+++ b/src/app/modules/admin/report/today-bet/models/today-bet.ts
@@ -1,29 +1,39 @@
+import { StringNullableChain } from 'lodash';
+
export interface TodayBet {
- id?: string;
- totalPartnerCount?: number;
- totalHoldingMoney?: number;
- totalComp?: number;
- total?: number;
- branchCount?: number;
- divisionCount?: number;
- officeCount?: number;
- storeCount?: number;
- memberCount?: number;
+ id: string;
+ signinId?: string;
+ rank?: string;
+ level?: string;
nickname?: string;
- accountHolder?: string;
- phoneNumber?: string;
- calculateType?: string;
- ownCash?: number;
- ownComp?: number;
- ownCoupon?: number;
- gameMoney?: number;
- todayComp?: number;
- totalDeposit?: number;
- totalWithdraw?: number;
- balance?: number;
- registDate?: string;
- finalSigninDate?: string;
- ip?: string;
- state?: string;
- note?: string;
+ memberCharge?: number; // 회원충전
+ memberExchange?: number; // 회원환전
+ memberProfitLoss?: number; // 회원손익
+ partnerCharge?: number; // 파트너충전
+ partnerExchange?: number; // 파트너환전
+ partnerProfitLoss?: number; // 파트너손익
+ totalProfitLoss?: number; // 전체손익
+ passiveMoney?: number;
+ passiveComp?: number;
+ casinoBetting?: number; // 카지노배팅
+ casinoTie?: number; // 카지노타이
+ casinoCancel?: number; // 카지노취소
+ casinoAvailable?: number; // 카지노유효
+ casinoWinning?: number; // 카지노당첨
+ casinoWinLoss?: number; // 카지노윈로스(A)
+ casinoCommission?: number; // 카지노수수료(B)
+ casinoBetWinCalculate?: number; // 카지노벳윈정산 (A-B)
+ slotBetting?: number; // 슬롯배팅
+ slotCancel?: number; // 슬롯취소
+ slotAvailable?: number; // 슬롯유효
+ slotWinning?: number; // 슬롯당첨
+ slotWinLoss?: number; // 슬롯윈로스(D)
+ slotCommission?: number; // 슬롯수수료(E)
+ slotBetWinCalculate?: number; // 슬롯벳윈정산(D-E)
+ powerballBetting?: number; // 파워볼배팅
+ powerballWinning?: number; // 파워볼당첨
+ powerballWinLoss?: number; // 파워볼윈로스(H)
+ powerballCommission?: number; // 파워볼수수료(I)
+ powerballBetWinCalculate?: number; // 파워볼벳윈정산(H-I)
+ totalBetWinCalculate?: number; // 총벳윈정산
}
diff --git a/src/app/modules/admin/report/today-bet/services/today-bet.service.ts b/src/app/modules/admin/report/today-bet/services/today-bet.service.ts
index 513819a..72b6ba6 100644
--- a/src/app/modules/admin/report/today-bet/services/today-bet.service.ts
+++ b/src/app/modules/admin/report/today-bet/services/today-bet.service.ts
@@ -70,19 +70,32 @@ export class TodayBetService {
* @param order
* @param search
*/
- getTodayBets(search: string = ''): Observable<{
+ getTodayBets(
+ page: number = 0,
+ size: number = 10,
+ sort: string = 'name',
+ order: 'asc' | 'desc' | '' = 'asc',
+ search: string = ''
+ ): Observable<{
+ pagination: TodayBetPagination;
todayBets: TodayBet[];
}> {
return this._httpClient
.get<{
+ pagination: TodayBetPagination;
todayBets: TodayBet[];
}>('api/apps/report/today-bet/today-bets', {
params: {
+ page: '' + page,
+ size: '' + size,
+ sort,
+ order,
search,
},
})
.pipe(
tap((response) => {
+ this.__pagination.next(response.pagination);
this.__todayBets.next(response.todayBets);
})
);