입금관리 수정

This commit is contained in:
이담 정 2022-07-25 02:36:06 +00:00
parent 7c94200594
commit 605f0f5ef4
6 changed files with 181 additions and 238 deletions

View File

@ -33,7 +33,7 @@ export class BankDepositMockApi {
.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);
@ -42,7 +42,7 @@ export class BankDepositMockApi {
let deposits: any[] | null = cloneDeep(this._deposits);
// Sort the deposits
if (sort === 'sku' || sort === 'name' || sort === 'active') {
if (sort === 'signinId' || sort === 'nickname' || sort === 'state') {
deposits.sort((a, b) => {
const fieldA = a[sort].toString().toUpperCase();
const fieldB = b[sort].toString().toUpperCase();

View File

@ -2,11 +2,12 @@
export const deposits = [
{
id: '7eb7c859-1347-4317-96b6-9476a7e2ba3c',
rank: '회원',
level: 4,
id: 'aa100',
signinId: 'aa100',
nickname: 'aa100',
paymentDue: 50000,
depositAmount: 50000,
calculateType: '롤링',
accountHolder: '광주은행2sss',
note: '@',
@ -20,11 +21,12 @@ export const deposits = [
state: '신청',
},
{
id: '00b0292f-3d50-4669-a0c4-7a9d85efc98d',
rank: '회원',
level: 1,
id: 'onon6',
signinId: 'onon6',
nickname: '가가가',
paymentDue: 100000,
depositAmount: 100000,
calculateType: '롤링',
accountHolder: '가가가',
note: '',
@ -38,11 +40,12 @@ export const deposits = [
state: '완료',
},
{
id: 'b899ec30-b85a-40ab-bb1f-18a596d5c6de',
rank: '회원',
level: 1,
id: 'onon6',
signinId: 'onon6',
nickname: '가가가',
paymentDue: 100000,
depositAmount: 100000,
calculateType: '롤링',
accountHolder: '가가가',
note: '',

View File

@ -10,16 +10,39 @@
<mat-progress-bar [mode]="'indeterminate'"></mat-progress-bar>
</div>
<!-- Title -->
<div class="text-4xl font-extrabold tracking-tight">Deposit</div>
<div class="text-4xl font-extrabold tracking-tight">입금관리</div>
<!-- Actions -->
<div class="flex shrink-0 items-center mt-6 sm:mt-0 sm:ml-4">
<!-- Search -->
<button mat-icon-button (click)="__onClickSearch()">
<mat-icon [svgIcon]="'heroicons_outline:search'"></mat-icon>
</button>
</div>
</div>
<!-- Memo -->
<mat-form-field>
<input matInput type="text" />
<!-- <div
class="relative flex flex-col sm:flex-row flex-0 sm:items-center sm:justify-between py-4 px-6 md:px-8 border-b"
>
<mat-form-field
class="bet-mat-form-field-wrapper-mb-0 mr-2"
style="width: 100%"
>
<textarea matInput cdkTextareaAutosize cdkAutosizeMinRows="2"></textarea>
</mat-form-field>
<button mat-flat-button [color]="'primary'">메모저장</button>
</div> -->
<!-- Search -->
<div
*ngIf="__isSearchOpened"
class="relative flex flex-col sm:flex-row flex-0 sm:items-center sm:justify-between py-4 px-6 md:px-8 border-b"
>
<!-- Actions -->
<div fxLayout="row wrap" class="items-center mt-6 sm:mt-0 sm:ml-0">
<!-- SelectBox -->
<mat-form-field>
<mat-form-field fxFlex class="bet-mat-form-field-wrapper-mb-0 mr-2">
<mat-select placeholder="내용">
<mat-option value="">카지노콤프</mat-option>
<mat-option value="">슬롯콤프</mat-option>
@ -27,7 +50,7 @@
<mat-option value="">첫충콤프</mat-option>
</mat-select>
</mat-form-field>
<mat-form-field>
<mat-form-field fxFlex class="bet-mat-form-field-wrapper-mb-0 mr-2">
<mat-select placeholder="아이디">
<mat-option value="">아이디</mat-option>
<mat-option value="">닉네임</mat-option>
@ -38,7 +61,8 @@
</mat-form-field>
<!-- Search -->
<mat-form-field
class="fuse-mat-dense fuse-mat-no-subscript fuse-mat-rounded min-w-64"
fxFlex
class="fuse-mat-rounded min-w-64 bet-mat-form-field-wrapper-mb-0 mr-2"
>
<mat-icon
class="icon-size-5"
@ -49,28 +73,34 @@
matInput
[formControl]="searchInputControl"
[autocomplete]="'off'"
[placeholder]="'Search'"
[placeholder]="'Search user'"
/>
</mat-form-field>
<!-- Search button -->
<!-- Add user button -->
<button
class="ml-4"
fxFlex
mat-flat-button
style="position: fixed; margin-top: 4px"
[color]="'primary'"
(click)="__createProduct()"
>
<!-- <mat-icon [svgIcon]="'heroicons_outline:plus'"></mat-icon> -->
<span class="ml-2 mr-1">검색하기</span>
<mat-icon [svgIcon]="'heroicons_outline:search'"></mat-icon>
<span class="ml-2 mr-1">Search</span>
</button>
</div>
</div>
<div class="hidden md:block">
<button mat-flat-button class="bet-mat-small-8" [color]="'primary'">
입금처리
</button>
</div>
<div class="hidden md:block">
<button mat-flat-button class="bet-mat-small-8" [color]="'primary'">
대기처리
</button>
</div>
<!-- Main -->
<div class="flex flex-auto overflow-hidden">
<div class="hidden sm:block truncate">
<button mat-flat-button [color]="'primary'">입금 처리</button>
<button mat-flat-button [color]="'primary'">대기 처리</button>
</div>
<!-- Products list -->
<div
class="flex flex-col flex-auto sm:mb-18 overflow-hidden sm:overflow-y-auto"
@ -81,39 +111,38 @@
<!-- Header -->
<div
class="inventory-grid z-10 sticky top-0 grid gap-4 py-4 px-6 md:px-8 shadow text-md font-semibold text-secondary bg-gray-50 dark:bg-black dark:bg-opacity-5"
matSort
matSortDisableClear
>
<div></div>
<div class="hidden sm:block">등급</div>
<div class="hidden sm:block">레벨</div>
<div class="hidden sm:block">아이디</div>
<div class="hidden sm:block">닉네임</div>
<div class="hidden sm:block">입금예정금액</div>
<div class="hidden sm:block">정산종류</div>
<div class="hidden sm:block">회원정보</div>
<div class="hidden sm:block">비고</div>
<div class="hidden sm:block">등록날짜</div>
<div class="hidden sm:block">처리날짜</div>
<div class="hidden sm:block">입금출금</div>
<div class="hidden sm:block">게임중머니</div>
<div class="hidden sm:block">카지노->캐쉬</div>
<div class="hidden sm:block">상위</div>
<div class="hidden sm:block">상태</div>
<div class="hidden sm:block">배팅정보</div>
<div class="hidden sm:block">삭제</div>
<!-- <div class="hidden md:block" [mat-sort-header]="'sku'">SKU</div>
<div [mat-sort-header]="'name'">Name</div>
<div class="hidden sm:block" [mat-sort-header]="'price'">
Price
<div>
<mat-checkbox></mat-checkbox>
</div>
<div class="hidden lg:block" [mat-sort-header]="'stock'">
Stock
<div>상부</div>
<div>
아이디
<hr style="margin: 7px 0px" />
닉네임
<hr style="margin: 7px 0px" />
상태
</div>
<div class="hidden lg:block" [mat-sort-header]="'active'">
Active
<div>
등급
<hr style="margin: 7px 0px" />
레벨
</div>
<div class="hidden sm:block">Details</div> -->
<div class="hidden sm:block">예금주</div>
<div>정산종류</div>
<div>비고</div>
<div>입금예정금액</div>
<div class="hidden md:block">
등록날짜
<hr style="margin: 7px 0px" />
처리날짜
</div>
<div class="hidden md:block">입금출금</div>
<div class="hidden md:block">게임중머니</div>
<div class="hidden lg:block">카지노->캐쉬</div>
<div class="hidden lg:block">회원정보</div>
<div class="hidden lg:block">배팅정보</div>
<div class="hidden lg:block">삭제</div>
</div>
<!-- Rows -->
<ng-container *ngIf="deposits$ | async as deposits">
@ -123,198 +152,87 @@
<div
class="inventory-grid grid items-center gap-4 py-3 px-6 md:px-8 border-b"
>
<!-- rank -->
<div class="hidden sm:block truncate">
{{ deposit.rank }}
<div>
<mat-checkbox></mat-checkbox>
</div>
<!-- level -->
<div class="hidden sm:block truncate">
LV.{{ deposit.level }}
</div>
<!-- id -->
<ng-container *ngIf="users$ | async as users">
<ng-container
*ngFor="let user of users; trackBy: __trackByFn"
>
<div class="hidden sm:block truncate">
{{ deposit.id }}
</div>
</ng-container>
</ng-container>
<!-- nickname -->
<div class="hidden sm:block truncate">
<div>{{ deposit.highRank }}</div>
<div>
{{ deposit.signinId }}
<hr style="margin: 7px 0px" />
{{ deposit.nickname }}
<hr style="margin: 7px 0px" />
{{ deposit.state }}
</div>
<!-- paymentDue -->
<div class="hidden sm:block truncate">
{{ deposit.paymentDue }}원
<div>
{{ deposit.rank }}
<hr style="margin: 7px 0px" />
LV{{ deposit.level }}
</div>
<!-- calculateType -->
<div class="hidden sm:block truncate">
{{ deposit.calculateType }}
</div>
<!-- accountHolder -->
<div class="hidden sm:block truncate">
<div class="hidden sm:block">
{{ deposit.accountHolder }}
</div>
<!-- note -->
<div class="hidden sm:block truncate">
{{ deposit.note }}
</div>
<!-- registrationDate -->
<div class="hidden sm:block truncate">
<div>{{ deposit.calculateType }}</div>
<div>{{ deposit.note }}</div>
<div>{{ deposit.depositAmount }}</div>
<div class="hidden md:block">
{{ deposit.registrationDate }}
</div>
<!-- processDate -->
<div class="hidden sm:block truncate">
<hr style="margin: 7px 0px" />
{{ deposit.processDate }}
</div>
<!-- depositWithdrawal -->
<div class="hidden sm:block truncate">
{{ deposit.deposit }}원 {{ deposit.withdraw }}원
{{ deposit.total }}원
<div class="hidden md:block">
입금{{ deposit.deposit }}
<hr style="margin: 7px 0px" />
출금{{ deposit.withdraw }}
<hr style="margin: 7px 0px" />
계{{ deposit.total }}
</div>
<!-- gameMoney -->
<div class="hidden sm:block truncate">
<div class="hidden md:block">
{{ deposit.gameMoney }}
</div>
<!-- casinoCash -->
<div class="hidden sm:block truncate">
<button mat-flat-button [color]="'primary'">
<div class="hidden lg:block">
<button
mat-flat-button
class="bet-mat-small-8"
[color]="'primary'"
>
게임머니확인
</button>
<button mat-flat-button [color]="'primary'">
<hr style="margin: 7px 0px" />
<button
mat-flat-button
class="bet-mat-small-8"
[color]="'primary'"
>
게임머니회수
</button>
</div>
<!-- highRank -->
<div class="hidden sm:block truncate">
<button mat-flat-button [color]="'primary'">
{{ deposit.highRank }}
</button>
</div>
<!-- state -->
<div class="hidden sm:block truncate">
{{ deposit.state }}
</div>
<!-- bettingInformation -->
<div class="hidden sm:block truncate">
<button mat-flat-button [color]="'primary'">
배팅리스트
</button>
</div>
<!-- delete -->
<div class="hidden sm:block truncate">
<button mat-flat-button [color]="'primary'">취소</button>
</div>
<!-- Image -->
<!-- <div class="flex items-center">
<div
class="relative flex flex-0 items-center justify-center w-12 h-12 mr-6 rounded overflow-hidden border"
>
<img
class="w-8"
*ngIf="user.thumbnail"
[alt]="'Product thumbnail image'"
[src]="user.thumbnail"
/>
<div
class="flex items-center justify-center w-full h-full text-xs font-semibold leading-none text-center uppercase"
*ngIf="!user.thumbnail"
>
NO THUMB
</div>
</div>
</div> -->
<!-- SKU -->
<!-- <div class="hidden md:block truncate">
{{ user.sku }}
</div> -->
<!-- Name -->
<!-- <div class="truncate">
{{ user.name }}
</div> -->
<!-- Price -->
<!-- <div class="hidden sm:block">
{{ user.price | currency: "USD":"symbol":"1.2-2" }}
</div> -->
<!-- Stock -->
<!-- <div class="hidden lg:flex items-center">
<div class="min-w-4">{{ user.stock }}</div> -->
<!-- Low stock -->
<!-- <div
class="flex items-end ml-2 w-1 h-4 bg-red-200 rounded overflow-hidden"
*ngIf="user.stock < 20"
>
<div class="flex w-full h-1/3 bg-red-600"></div>
</div> -->
<!-- Medium stock -->
<!-- <div
class="flex items-end ml-2 w-1 h-4 bg-orange-200 rounded overflow-hidden"
*ngIf="user.stock >= 20 && user.stock < 30"
>
<div class="flex w-full h-2/4 bg-orange-400"></div>
</div> -->
<!-- High stock -->
<!-- <div
class="flex items-end ml-2 w-1 h-4 bg-green-100 rounded overflow-hidden"
*ngIf="user.stock >= 30"
>
<div class="flex w-full h-full bg-green-400"></div>
</div>
</div> -->
<!-- Active -->
<!-- <div class="hidden lg:block">
<ng-container *ngIf="user.active">
<mat-icon
class="text-green-400 icon-size-5"
[svgIcon]="'heroicons_solid:check'"
></mat-icon>
</ng-container>
<ng-container *ngIf="!user.active">
<mat-icon
class="text-gray-400 icon-size-5"
[svgIcon]="'heroicons_solid:x'"
></mat-icon>
</ng-container>
</div> -->
<!-- Details button -->
<!-- <div>
<div class="hidden lg:block">
<button
class="min-w-10 min-h-7 h-7 px-2 leading-6"
mat-stroked-button
(click)="__toggleDetails(user.id)"
mat-flat-button
class="bet-mat-small-8"
[color]="'primary'"
>
<mat-icon
class="icon-size-5"
[svgIcon]="
selectedUser?.id === user.id
? 'heroicons_solid:chevron-up'
: 'heroicons_solid:chevron-down'
"
></mat-icon>
회원정보
</button>
</div> -->
</div>
<div class="hidden lg:block">
<button
mat-flat-button
class="bet-mat-small-8"
[color]="'primary'"
>
배팅정보
</button>
</div>
<div class="hidden lg:block">
<button
mat-flat-button
class="bet-mat-small-8"
[color]="'primary'"
>
취소
</button>
</div>
</div>
</ng-container>
</ng-container>
@ -340,9 +258,15 @@
</div>
</ng-template>
</div>
<div class="hidden sm:block truncate">
<button mat-flat-button [color]="'primary'">입금 처리</button>
<button mat-flat-button [color]="'primary'">대기 처리</button>
</div>
</div>
<div class="hidden md:block">
<button mat-flat-button class="bet-mat-small-8" [color]="'primary'">
입금처리
</button>
</div>
<div class="hidden md:block">
<button mat-flat-button class="bet-mat-small-8" [color]="'primary'">
대기처리
</button>
</div>
</div>

View File

@ -41,18 +41,22 @@ import { DepositService } from '../services/deposit.service';
/* language=SCSS */
`
.inventory-grid {
grid-template-columns: 60px auto 40px;
/* CB 상부 아이디 등급 예금주 정산종류 */
grid-template-columns: 20px 100px 100px 80px auto 40px;
@screen sm {
grid-template-columns: 60px auto 60px 72px;
/* CB 상부 아이디 등급 예금주 정산종류 비고 예정 등록*/
grid-template-columns: 20px 100px 100px 80px auto 40px 20px 140px 140px;
}
@screen md {
grid-template-columns: 60px 60px auto 112px 72px;
/* CB 상부 아이디 등급 예금주 정산종류 비고 예정 등록 입금출금 */
grid-template-columns: 20px 100px 100px 80px auto 40px 20px 100px 100px 100px;
}
@screen lg {
grid-template-columns: 60px 60px auto 112px 96px 96px 72px;
/* CB 상부 아이디 등급 예금주 정산종류 비고 예정 등록 입금출금 게임중 카지노 회원 배팅 삭제*/
grid-template-columns: 20px 100px 100px 80px auto 40px 20px 140px 140px 140px 100px 100px 100px 100px 100px;
}
}
`,
@ -68,6 +72,7 @@ export class ListComponent implements OnInit, AfterViewInit, OnDestroy {
deposits$!: Observable<Deposit[] | undefined>;
users$!: Observable<User[] | undefined>;
__isSearchOpened = false;
isLoading = false;
searchInputControl = new FormControl();
selectedDeposit?: Deposit;
@ -180,6 +185,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
*

View File

@ -11,6 +11,7 @@ import { MatRippleModule } from '@angular/material/core';
import { MatSortModule } from '@angular/material/sort';
import { MatSelectModule } from '@angular/material/select';
import { MatTooltipModule } from '@angular/material/tooltip';
import { MatCheckboxModule } from '@angular/material/checkbox';
import { TranslocoModule } from '@ngneat/transloco';
@ -37,6 +38,7 @@ import { depositRoutes } from './deposit.routing';
MatSortModule,
MatSelectModule,
MatTooltipModule,
MatCheckboxModule,
],
})
export class DepositModule {}

View File

@ -1,9 +1,10 @@
export interface Deposit {
id?: string;
id: string;
signinId?: string;
rank?: string;
level?: string;
nickname?: string;
paymentDue?: number;
depositAmount?: number; // 입금예정금액
calculateType?: string;
accountHolder?: string;
note?: string;