Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat/accept invite #53

Merged
merged 37 commits into from
Jul 11, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
9861ed0
feat: InviteInfo 테이블 추가
yoon-junseo Jun 22, 2024
8e8aa1e
feat: 초대권 생성 기능 구현
yoon-junseo Jun 22, 2024
bd28fb7
feat: trpcModule, userModule에 inviteModule 추가
yoon-junseo Jun 22, 2024
b9ca01e
feat: 회원가입시 초대권 생성 코드 추가
yoon-junseo Jun 22, 2024
57499b8
chore: 코드 포맷팅 및 console.log 제거
yoon-junseo Jun 22, 2024
1caf19e
chore: 줄 띄어쓰기 추가
yoon-junseo Jun 22, 2024
9a0e5f7
feat: 내 초대권 조회 기능 추가
yoon-junseo Jun 22, 2024
35ca08b
feat: trpc router에 InviteController 연결
yoon-junseo Jun 22, 2024
1e2d451
feat: controller에서 사용하는 모듈들을 상대경로로 import 변경
yoon-junseo Jun 22, 2024
61982bc
feat: 내 초대권 조회 기능 테스트 추가
yoon-junseo Jun 22, 2024
69c14d6
feat: code를 uid에서 랜덤 6자로 변경
yoon-junseo Jun 22, 2024
a514640
refactor: 불필요한 기본값 설정 제거
yoon-junseo Jun 22, 2024
d2fd0f2
refactor: 초대한 수 기록하는 변수에 기본값 설정 제거
yoon-junseo Jun 22, 2024
b94c236
wip migration 필요해서 브랜치를 옮기기 위한 커밋
11t518s Jun 22, 2024
8f5c2bb
feat: add user type for non invite user
11t518s Jun 22, 2024
487110f
[#46] 초대권 생성 기능 구현 (#48)
yoon-junseo Jun 22, 2024
e258e71
feat: add user type for non invite user
11t518s Jun 22, 2024
fa927bf
fix: default userType변경 및 inviteCode에 unique 추가
11t518s Jun 22, 2024
0b765c0
fix: default userType변경 및 inviteCode에 unique 추가
11t518s Jun 22, 2024
8157839
fix: inviteUser 테이블에 User relation연결
11t518s Jun 22, 2024
01b28ee
fix: inviteUser 테이블에 User relation연결
11t518s Jun 22, 2024
6c6edec
feat: ctx에 user 타입 캐스팅 해두기
11t518s Jun 22, 2024
dcb0cc5
feat: add inviteRecord table
11t518s Jun 22, 2024
d3fd51a
feat: add inviteRecord table
11t518s Jun 22, 2024
3995609
fix: 연결관계 추가 및 인덱스 추가
11t518s Jun 22, 2024
11a5b13
fix: 연결관계 추가 및 인덱스 추가
11t518s Jun 22, 2024
bcc104e
fix: test
11t518s Jun 30, 2024
b855f81
fix: test
11t518s Jun 30, 2024
c5ce916
Merge branch 'dev-migration' into feat/accept-invite
11t518s Jun 30, 2024
6ec8730
wip
11t518s Jul 3, 2024
8bc707d
fix: 회원가입 시 초대권이 생성되지 않고, 초대 시 생성되도록 변경
11t518s Jul 5, 2024
c58e2c9
feat: 클립보드 라이브러리 추가 및 패키지 고정
11t518s Jul 5, 2024
550290f
feat: 초대 승인 기능
11t518s Jul 5, 2024
ec15167
fix: 코드 수정
11t518s Jul 5, 2024
15a1ce8
fix: default 설정을 받을 수 있는
bongsu-rapportlabs Jul 6, 2024
bfa4cc7
wip
11t518s Jul 7, 2024
5db0b00
fix: inviteUser 테이블에 User relation연결
bongsu-rapportlabs Jul 11, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions apps/server/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
"scripts": {
"build": "nest build",
"format": "prettier --write \"src/**/*.ts\" \"test/**/*.ts\"",
"create-migration-sql": "pnpx prisma migrate dev --create-only",
"migration-deploy": "pnpx prisma migrate deploy",
"start": "nest start",
"start:dev": "nest start --watch",
"start:debug": "nest start --debug --watch",
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
-- AlterTable
ALTER TABLE `User` MODIFY `type` ENUM('USER_NOT_INVITED', 'USER', 'ADMIN') NOT NULL DEFAULT 'USER';
14 changes: 2 additions & 12 deletions apps/server/prisma/schema.prisma
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ model User {
deletedAt DateTime?
updatedAt DateTime @default(now())
uid String @id
type Type @default(USER)
type User_type @default(USER)
}

model GoogleProfile {
Expand Down Expand Up @@ -51,18 +51,8 @@ model InviteInfo {
tier String
}

enum Type {
enum User_type {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

별건 아닌데 enum은 UserType 요런식으로 쓰면 어떨까

USER_NOT_INVITED
USER
ADMIN
}

model InviteInfo {
uid String @id
code String
createdAt DateTime @default(now())
updatedAt DateTime @default(now())
availableInviteCount Int
inviteHistoryCount Int @default(0)
tier String
}